summaryrefslogtreecommitdiffstats
path: root/drivers/char/agp/i460-agp.c
diff options
context:
space:
mode:
authorScott Thompson <postfail at hushmail.com>2007-08-25 18:14:00 +1000
committerDave Airlie <airlied@linux.ie>2007-08-25 18:14:00 +1000
commit5bdbc7dc2c07d507b41bffdadc2c8cc13b2d4326 (patch)
tree028f10ec31f041f97934c3fd6b66eabb81444ed8 /drivers/char/agp/i460-agp.c
parent32ddef98f232585f20bc8bdb891029a6a5f633d0 (diff)
downloadlinux-5bdbc7dc2c07d507b41bffdadc2c8cc13b2d4326.tar.bz2
agp: balance ioremap checks
patchset against 2.6.23-rc3. corrects missing ioremap return checks and balancing on iounmap calls, integrated changes per list recommendations on the original set of patches.. Signed-off-by: Scott Thompson <postfail <at> hushmail.com> Signed-off-by: Dave Airlie <airlied@linux.ie>
Diffstat (limited to 'drivers/char/agp/i460-agp.c')
-rw-r--r--drivers/char/agp/i460-agp.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/char/agp/i460-agp.c b/drivers/char/agp/i460-agp.c
index 53354bf83af7..75d2aca6353d 100644
--- a/drivers/char/agp/i460-agp.c
+++ b/drivers/char/agp/i460-agp.c
@@ -249,6 +249,10 @@ static int i460_create_gatt_table (struct agp_bridge_data *bridge)
num_entries = A_SIZE_8(temp)->num_entries;
i460.gatt = ioremap(INTEL_I460_ATTBASE, PAGE_SIZE << page_order);
+ if (!i460.gatt) {
+ printk(KERN_ERR PFX "ioremap failed\n");
+ return -ENOMEM;
+ }
/* These are no good, the should be removed from the agp_bridge strucure... */
agp_bridge->gatt_table_real = NULL;