Refactoring/cleanup display driver