mirror of
https://github.com/adulau/aha.git
synced 2024-12-27 19:26:25 +00:00
[PATCH] drivers/char/lcd.c: misc_register() can fail
Signed-off-by: Christophe Lucas <clucas@rotomalug.org> Signed-off-by: Domen Puncer <domen@coderock.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
parent
819a3eba42
commit
cf85d5ca88
1 changed files with 6 additions and 1 deletions
|
@ -613,10 +613,15 @@ static struct miscdevice lcd_dev = {
|
|||
|
||||
static int lcd_init(void)
|
||||
{
|
||||
int ret;
|
||||
unsigned long data;
|
||||
|
||||
pr_info("%s\n", LCD_DRIVER);
|
||||
misc_register(&lcd_dev);
|
||||
ret = misc_register(&lcd_dev);
|
||||
if (ret) {
|
||||
printk(KERN_WARNING LCD "Unable to register misc device.\n");
|
||||
return ret;
|
||||
}
|
||||
|
||||
/* Check region? Naaah! Just snarf it up. */
|
||||
/* request_region(RTC_PORT(0), RTC_IO_EXTENT, "lcd");*/
|
||||
|
|
Loading…
Reference in a new issue