]> git.kernelconcepts.de Git - karo-tx-uboot.git/blobdiff - drivers/video/tegra.c
common/lcd.c: cleanup use of global variables
[karo-tx-uboot.git] / drivers / video / tegra.c
index 750a2834383f035109ed2f6bd012f63bbfc64243..00d855356f4c782a2f855f5837d3b17ea47a3697 100644 (file)
@@ -61,8 +61,6 @@ enum {
 };
 
 int lcd_line_length;
-int lcd_color_fg;
-int lcd_color_bg;
 
 void *lcd_base;                        /* Start of framebuffer memory  */
 void *lcd_console_address;     /* Start of console buffer      */
@@ -108,7 +106,7 @@ void lcd_toggle_cursor(void)
 
                for (i = 0; i < lcd_cursor_width; ++i) {
                        color = *d;
-                       color ^= lcd_color_fg;
+                       color ^= lcd_getfgcolor();
                        *d = color;
                        ++d;
                }
@@ -145,8 +143,8 @@ static void update_panel_size(struct fdt_disp_config *config)
 
 void lcd_ctrl_init(void *lcdbase)
 {
-       int line_length, size;
        int type = DCACHE_OFF;
+       int size;
 
        assert(disp_config);
 
@@ -160,7 +158,7 @@ void lcd_ctrl_init(void *lcdbase)
                        && disp_config->height <= LCD_MAX_HEIGHT
                        && disp_config->log2_bpp <= LCD_MAX_LOG2_BPP)
                update_panel_size(disp_config);
-       size = lcd_get_size(&line_length);
+       size = lcd_get_size(&lcd_line_length);
 
        /* Set up the LCD caching as requested */
        if (config.cache_type & FDT_LCD_CACHE_WRITE_THROUGH)