Skip to content

Commit

Permalink
w100fb: fix compile warnings
Browse files Browse the repository at this point in the history
Fix compile warnings from w100fb.c.  Attribute registration failure doesn't
stop the driver working so just warn about it.

Signed-off-by: Richard Purdie <rpurdie@rpsys.net>
Signed-off-by: Antonino Daplas <adaplas@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Richard Purdie authored and Linus Torvalds committed May 24, 2007
1 parent 2686ba8 commit a01fbbd
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions drivers/video/w100fb.c
Original file line number Diff line number Diff line change
Expand Up @@ -660,7 +660,7 @@ int __init w100fb_probe(struct platform_device *pdev)
err = -ENODEV;
goto out;
}
printk(" at 0x%08lx.\n", mem->start+W100_CFG_BASE);
printk(" at 0x%08lx.\n", (unsigned long) mem->start+W100_CFG_BASE);

/* Remap the framebuffer */
remapped_fbuf = ioremap_nocache(mem->start+MEM_WINDOW_BASE, MEM_WINDOW_SIZE);
Expand Down Expand Up @@ -753,10 +753,14 @@ int __init w100fb_probe(struct platform_device *pdev)
goto out;
}

device_create_file(&pdev->dev, &dev_attr_fastpllclk);
device_create_file(&pdev->dev, &dev_attr_reg_read);
device_create_file(&pdev->dev, &dev_attr_reg_write);
device_create_file(&pdev->dev, &dev_attr_flip);
err = device_create_file(&pdev->dev, &dev_attr_fastpllclk);
err |= device_create_file(&pdev->dev, &dev_attr_reg_read);
err |= device_create_file(&pdev->dev, &dev_attr_reg_write);
err |= device_create_file(&pdev->dev, &dev_attr_flip);

if (err != 0)
printk(KERN_WARNING "fb%d: failed to register attributes (%d)\n",
info->node, err);

printk(KERN_INFO "fb%d: %s frame buffer device\n", info->node, info->fix.id);
return 0;
Expand Down

0 comments on commit a01fbbd

Please sign in to comment.