48d0d3657e43db5a08a9b3890fcee5cedac52d06 Removing rcu_read_(lock, unlock) illegal operations . fs/fcntl.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/fs/fcntl.c b/fs/fcntl.c index 350a2c8..dc030a2 100644 --- a/fs/fcntl.c +++ b/fs/fcntl.c @@ -475,7 +475,7 @@ static void send_sigio_to_task(struct task_struct *p, reasons, otherwise we could leak kernel stack into userspace. */ BUG_ON((reason & __SI_MASK) != __SI_POLL); - if (reason - POLL_IN >= NSIGPOLL) + if ((reason - POLL_IN) >= NSIGPOLL) si.si_band = ~0L; else si.si_band = band_table[reason - POLL_IN]; @@ -580,7 +580,7 @@ int fasync_remove_entry(struct file *filp, struct fasync_struct **fapp) spin_lock(&filp->f_lock); spin_lock(&fasync_lock); - for (fp = fapp; (fa = *fp) != NULL; fp = &fa->fa_next) { + for (fp = fapp; ((fa = *fp) != NULL); fp = &fa->fa_next) { if (fa->fa_file != filp) continue; @@ -627,7 +627,7 @@ struct fasync_struct *fasync_insert_entry(int fd, struct file *filp, struct fasy spin_lock(&filp->f_lock); spin_lock(&fasync_lock); - for (fp = fapp; (fa = *fp) != NULL; fp = &fa->fa_next) { + for (fp = fapp; ((fa = *fp) != NULL); fp = &fa->fa_next) { if (fa->fa_file != filp) continue; @@ -713,7 +713,7 @@ static void kill_fasync_rcu(struct fasync_struct *fa, int sig, int band) /* Don't send SIGURG to processes which have not set a queued signum: SIGURG has its own default signalling mechanism. */ - if (!(sig == SIGURG && fown->signum == 0)) + if (!((sig == SIGURG) && (fown->signum == 0))) send_sigio(fown, fa->fa_fd, band); } spin_unlock_irqrestore(&fa->fa_lock, flags); @@ -727,9 +727,7 @@ void kill_fasync(struct fasync_struct **fp, int sig, int band) * the list is empty. */ if (*fp) { - rcu_read_lock(); kill_fasync_rcu(rcu_dereference(*fp), sig, band); - rcu_read_unlock(); } } EXPORT_SYMBOL(kill_fasync); -- 2.7.4