diff options
author | Greg KH <gregkh@suse.de> | 2005-09-12 12:10:59 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2005-09-12 12:10:59 -0700 |
commit | ad2c10f8f00d3fe2e37dd8a107e7cf4ac0459489 (patch) | |
tree | 5571f6a5784f51efddf9c1ee0408894cd63a460f /drivers/video/savage/savagefb-i2c.c | |
parent | 6b7839007098a6b5612d31690e11277d4242e6ae (diff) | |
parent | 2ade81473636b33aaac64495f89a7dc572c529f0 (diff) | |
download | linux-ad2c10f8f00d3fe2e37dd8a107e7cf4ac0459489.tar.bz2 |
Merge ../torvalds-2.6/
Diffstat (limited to 'drivers/video/savage/savagefb-i2c.c')
-rw-r--r-- | drivers/video/savage/savagefb-i2c.c | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/drivers/video/savage/savagefb-i2c.c b/drivers/video/savage/savagefb-i2c.c index 847698b5cfe7..959404ad68f4 100644 --- a/drivers/video/savage/savagefb-i2c.c +++ b/drivers/video/savage/savagefb-i2c.c @@ -259,8 +259,9 @@ static u8 *savage_do_probe_i2c_edid(struct savagefb_i2c_chan *chan) return buf; } -int savagefb_probe_i2c_connector(struct savagefb_par *par, u8 **out_edid) +int savagefb_probe_i2c_connector(struct fb_info *info, u8 **out_edid) { + struct savagefb_par *par = info->par; u8 *edid = NULL; int i; @@ -270,12 +271,19 @@ int savagefb_probe_i2c_connector(struct savagefb_par *par, u8 **out_edid) if (edid) break; } + + if (!edid) { + /* try to get from firmware */ + edid = kmalloc(EDID_LENGTH, GFP_KERNEL); + if (edid) + memcpy(edid, fb_firmware_edid(info->device), + EDID_LENGTH); + } + if (out_edid) *out_edid = edid; - if (!edid) - return 1; - return 0; + return (edid) ? 0 : 1; } MODULE_LICENSE("GPL"); |