]> Git Repo - linux.git/commitdiff
drivers/video/backlight/s6e63m0.c: report ->gamma_table_count correctly
authorDan Carpenter <[email protected]>
Fri, 22 Feb 2013 00:44:01 +0000 (16:44 -0800)
committerLinus Torvalds <[email protected]>
Fri, 22 Feb 2013 01:22:25 +0000 (17:22 -0800)
gamma_table has 3 arrays which each hold MAX_GAMMA_LEVEL pointers to int.

The current code sets ->gamma_table_count to 6 on 64bit arches and to 3 on
32 bit arches.  It should be 3 on everything.

Signed-off-by: Dan Carpenter <[email protected]>
Cc: Jingoo Han <[email protected]>
Cc: Florian Tobias Schandinat <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
drivers/video/backlight/s6e63m0.c

index 2126b96ea603f4a7cc27a08dc1ad5feda82fba3d..9c2677f0ef7d8562643b001944865aec387a49b4 100644 (file)
@@ -766,7 +766,7 @@ static int s6e63m0_probe(struct spi_device *spi)
         * know that.
         */
        lcd->gamma_table_count =
-           sizeof(gamma_table) / (MAX_GAMMA_LEVEL * sizeof(int));
+           sizeof(gamma_table) / (MAX_GAMMA_LEVEL * sizeof(int *));
 
        ret = device_create_file(&(spi->dev), &dev_attr_gamma_mode);
        if (ret < 0)
This page took 0.050345 seconds and 4 git commands to generate.