diff options
Diffstat (limited to 'drivers/char/agp/parisc-agp.c')
-rw-r--r-- | drivers/char/agp/parisc-agp.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/char/agp/parisc-agp.c b/drivers/char/agp/parisc-agp.c index 1c129211302d..94821ab01c6d 100644 --- a/drivers/char/agp/parisc-agp.c +++ b/drivers/char/agp/parisc-agp.c | |||
@@ -19,6 +19,7 @@ | |||
19 | #include <linux/klist.h> | 19 | #include <linux/klist.h> |
20 | #include <linux/agp_backend.h> | 20 | #include <linux/agp_backend.h> |
21 | #include <linux/log2.h> | 21 | #include <linux/log2.h> |
22 | #include <linux/slab.h> | ||
22 | 23 | ||
23 | #include <asm/parisc-device.h> | 24 | #include <asm/parisc-device.h> |
24 | #include <asm/ropes.h> | 25 | #include <asm/ropes.h> |
@@ -358,8 +359,12 @@ parisc_agp_setup(void __iomem *ioc_hpa, void __iomem *lba_hpa) | |||
358 | bridge->dev = fake_bridge_dev; | 359 | bridge->dev = fake_bridge_dev; |
359 | 360 | ||
360 | error = agp_add_bridge(bridge); | 361 | error = agp_add_bridge(bridge); |
362 | if (error) | ||
363 | goto fail; | ||
364 | return 0; | ||
361 | 365 | ||
362 | fail: | 366 | fail: |
367 | kfree(fake_bridge_dev); | ||
363 | return error; | 368 | return error; |
364 | } | 369 | } |
365 | 370 | ||