diff options
author | Gwenhael Goavec-Merou <gwe@trabucayre.com> | 2013-01-13 16:56:43 +0100 |
---|---|---|
committer | Shawn Guo <shawn.guo@linaro.org> | 2013-01-14 08:16:18 +0800 |
commit | afc10301f70350b490ca518ceb793928854b5453 (patch) | |
tree | c6430549ad63a1bce13d49127e9d768ebca9adba /drivers/video/imxfb.c | |
parent | 006e792ba5f60c59d8bc5ac5628c54e021e8580f (diff) | |
download | linux-3.10-afc10301f70350b490ca518ceb793928854b5453.tar.gz linux-3.10-afc10301f70350b490ca518ceb793928854b5453.tar.bz2 linux-3.10-afc10301f70350b490ca518ceb793928854b5453.zip |
video: imxfb: fix imxfb_info configuration order
The devtype field for fbi (struct imxfb_info) must be set after memset call to
avoid some wrong behaviour (pixel size).
Signed-off-by: Gwenhael Goavec-Merou <gwenhael.goavec-merou@armadeus.com>
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Diffstat (limited to 'drivers/video/imxfb.c')
-rw-r--r-- | drivers/video/imxfb.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/video/imxfb.c b/drivers/video/imxfb.c index e501dbc966b..8435c5d601a 100644 --- a/drivers/video/imxfb.c +++ b/drivers/video/imxfb.c @@ -729,6 +729,8 @@ static int __init imxfb_init_fbinfo(struct platform_device *pdev) memset(fbi, 0, sizeof(struct imxfb_info)); + fbi->devtype = pdev->id_entry->driver_data; + strlcpy(info->fix.id, IMX_NAME, sizeof(info->fix.id)); info->fix.type = FB_TYPE_PACKED_PIXELS; @@ -789,7 +791,6 @@ static int __init imxfb_probe(struct platform_device *pdev) return -ENOMEM; fbi = info->par; - fbi->devtype = pdev->id_entry->driver_data; if (!fb_mode) fb_mode = pdata->mode[0].mode.name; |