mirror of
https://github.com/torvalds/linux.git
synced 2024-12-27 13:22:23 +00:00
cpwatchdog: BKL pushdown
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
This commit is contained in:
parent
122bc5eaf8
commit
b05c9e6cd9
@ -279,6 +279,7 @@ static inline int wd_opt_timeout(void)
|
||||
|
||||
static int wd_open(struct inode *inode, struct file *f)
|
||||
{
|
||||
lock_kernel();
|
||||
switch(iminor(inode))
|
||||
{
|
||||
case WD0_MINOR:
|
||||
@ -291,6 +292,7 @@ static int wd_open(struct inode *inode, struct file *f)
|
||||
f->private_data = &wd_dev.watchdog[WD2_ID];
|
||||
break;
|
||||
default:
|
||||
unlock_kernel();
|
||||
return(-ENODEV);
|
||||
}
|
||||
|
||||
@ -304,11 +306,13 @@ static int wd_open(struct inode *inode, struct file *f)
|
||||
(void *)wd_dev.regs)) {
|
||||
printk("%s: Cannot register IRQ %d\n",
|
||||
WD_OBPNAME, wd_dev.irq);
|
||||
unlock_kernel();
|
||||
return(-EBUSY);
|
||||
}
|
||||
wd_dev.initialized = 1;
|
||||
}
|
||||
|
||||
unlock_kernel();
|
||||
return(nonseekable_open(inode, f));
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user