2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-18 02:04:05 +08:00

parport: dead code in pp_write

We always update bytes_written before we check signal_pending so it
follows that we can't get a signal return for 0 bytes so we don't
need to check in the singal path. The cases a signal causes an earlier
abort are handled before this and will not hit this path

Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
This commit is contained in:
Alan Cox 2012-10-01 16:24:17 +01:00 committed by Jiri Kosina
parent 1b61810d19
commit 5d0c3d4f3d

View File

@ -251,12 +251,8 @@ static ssize_t pp_write (struct file * file, const char __user * buf,
break;
}
if (signal_pending (current)) {
if (!bytes_written) {
bytes_written = -EINTR;
}
if (signal_pending (current))
break;
}
cond_resched();
}