diff options
-rw-r--r-- | drivers/video/xilinxfb.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/drivers/video/xilinxfb.c b/drivers/video/xilinxfb.c index e63cbd1acfd2..9aa754a25218 100644 --- a/drivers/video/xilinxfb.c +++ b/drivers/video/xilinxfb.c | |||
@@ -225,14 +225,14 @@ xilinxfb_drv_probe(struct device *dev) | |||
225 | if (!regs_res || (regs_res->end - regs_res->start + 1 < 8)) { | 225 | if (!regs_res || (regs_res->end - regs_res->start + 1 < 8)) { |
226 | dev_err(dev, "Couldn't get registers resource\n"); | 226 | dev_err(dev, "Couldn't get registers resource\n"); |
227 | retval = -EFAULT; | 227 | retval = -EFAULT; |
228 | goto failed1; | 228 | goto err_region; |
229 | } | 229 | } |
230 | 230 | ||
231 | if (!request_mem_region(regs_res->start, 8, DRIVER_NAME)) { | 231 | if (!request_mem_region(regs_res->start, 8, DRIVER_NAME)) { |
232 | dev_err(dev, "Couldn't lock memory region at 0x%08X\n", | 232 | dev_err(dev, "Couldn't lock memory region at 0x%08X\n", |
233 | regs_res->start); | 233 | regs_res->start); |
234 | retval = -EBUSY; | 234 | retval = -EBUSY; |
235 | goto failed1; | 235 | goto err_region; |
236 | } | 236 | } |
237 | drvdata->regs = (u32 __iomem*) ioremap(regs_res->start, 8); | 237 | drvdata->regs = (u32 __iomem*) ioremap(regs_res->start, 8); |
238 | drvdata->regs_phys = regs_res->start; | 238 | drvdata->regs_phys = regs_res->start; |
@@ -243,7 +243,7 @@ xilinxfb_drv_probe(struct device *dev) | |||
243 | if (!drvdata->fb_virt) { | 243 | if (!drvdata->fb_virt) { |
244 | dev_err(dev, "Could not allocate frame buffer memory\n"); | 244 | dev_err(dev, "Could not allocate frame buffer memory\n"); |
245 | retval = -ENOMEM; | 245 | retval = -ENOMEM; |
246 | goto failed2; | 246 | goto err_fbmem; |
247 | } | 247 | } |
248 | 248 | ||
249 | /* Clear (turn to black) the framebuffer */ | 249 | /* Clear (turn to black) the framebuffer */ |
@@ -270,7 +270,7 @@ xilinxfb_drv_probe(struct device *dev) | |||
270 | dev_err(dev, "Fail to allocate colormap (%d entries)\n", | 270 | dev_err(dev, "Fail to allocate colormap (%d entries)\n", |
271 | PALETTE_ENTRIES_NO); | 271 | PALETTE_ENTRIES_NO); |
272 | retval = -EFAULT; | 272 | retval = -EFAULT; |
273 | goto failed3; | 273 | goto err_cmap; |
274 | } | 274 | } |
275 | 275 | ||
276 | drvdata->info.flags = FBINFO_DEFAULT; | 276 | drvdata->info.flags = FBINFO_DEFAULT; |
@@ -284,7 +284,7 @@ xilinxfb_drv_probe(struct device *dev) | |||
284 | if (register_framebuffer(&drvdata->info) < 0) { | 284 | if (register_framebuffer(&drvdata->info) < 0) { |
285 | dev_err(dev, "Could not register frame buffer\n"); | 285 | dev_err(dev, "Could not register frame buffer\n"); |
286 | retval = -EINVAL; | 286 | retval = -EINVAL; |
287 | goto failed4; | 287 | goto err_regfb; |
288 | } | 288 | } |
289 | 289 | ||
290 | /* Put a banner in the log (for DEBUG) */ | 290 | /* Put a banner in the log (for DEBUG) */ |
@@ -294,10 +294,10 @@ xilinxfb_drv_probe(struct device *dev) | |||
294 | (void*)drvdata->fb_phys, drvdata->fb_virt, FB_SIZE); | 294 | (void*)drvdata->fb_phys, drvdata->fb_virt, FB_SIZE); |
295 | return 0; /* success */ | 295 | return 0; /* success */ |
296 | 296 | ||
297 | failed4: | 297 | err_regfb: |
298 | fb_dealloc_cmap(&drvdata->info.cmap); | 298 | fb_dealloc_cmap(&drvdata->info.cmap); |
299 | 299 | ||
300 | failed3: | 300 | err_cmap: |
301 | dma_free_coherent(dev, PAGE_ALIGN(FB_SIZE), drvdata->fb_virt, | 301 | dma_free_coherent(dev, PAGE_ALIGN(FB_SIZE), drvdata->fb_virt, |
302 | drvdata->fb_phys); | 302 | drvdata->fb_phys); |
303 | 303 | ||
@@ -305,10 +305,10 @@ failed3: | |||
305 | xilinx_fb_out_be32(drvdata, REG_CTRL, 0); | 305 | xilinx_fb_out_be32(drvdata, REG_CTRL, 0); |
306 | iounmap(drvdata->regs); | 306 | iounmap(drvdata->regs); |
307 | 307 | ||
308 | failed2: | 308 | err_fbmem: |
309 | release_mem_region(regs_res->start, 8); | 309 | release_mem_region(regs_res->start, 8); |
310 | 310 | ||
311 | failed1: | 311 | err_region: |
312 | kfree(drvdata); | 312 | kfree(drvdata); |
313 | dev_set_drvdata(dev, NULL); | 313 | dev_set_drvdata(dev, NULL); |
314 | 314 | ||