All of lore.kernel.org
 help / color / mirror / Atom feed
From: Evgeny Budilovsky <budevg@gmail.com>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Andreas Dilger <andreas.dilger@intel.com>,
	Oleg Drokin <green@linuxhacker.ru>, Peng Tao <bergwolf@gmail.com>,
	Lai Siyao <lai.siyao@intel.com>,
	devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org
Subject: [PATCH] staging/lustre: use rcu_dereference to access rcu protected current->real_parent field
Date: Wed, 6 Aug 2014 21:22:43 +0300	[thread overview]
Message-ID: <87k36ltoob.fsf@gmail.com> (raw)



Signed-off-by: Evgeny Budilovsky <budevg@gmail.com>
---
 drivers/staging/lustre/lustre/llite/lproc_llite.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/lustre/lustre/llite/lproc_llite.c b/drivers/staging/lustre/lustre/llite/lproc_llite.c
index 77f68b5..7e61468 100644
--- a/drivers/staging/lustre/lustre/llite/lproc_llite.c
+++ b/drivers/staging/lustre/lustre/llite/lproc_llite.c
@@ -910,7 +910,8 @@ void ll_stats_ops_tally(struct ll_sb_info *sbi, int op, int count)
 		 sbi->ll_stats_track_id == current->pid)
 		lprocfs_counter_add(sbi->ll_stats, op, count);
 	else if (sbi->ll_stats_track_type == STATS_TRACK_PPID &&
-		 sbi->ll_stats_track_id == current->real_parent->pid)
+		 sbi->ll_stats_track_id ==
+			rcu_dereference(current->real_parent)->pid)
 		lprocfs_counter_add(sbi->ll_stats, op, count);
 	else if (sbi->ll_stats_track_type == STATS_TRACK_GID &&
 		 sbi->ll_stats_track_id ==
-- 
1.8.1.2


             reply	other threads:[~2014-08-06 19:15 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-06 18:22 Evgeny Budilovsky [this message]
2014-08-06 21:42 ` [PATCH] staging/lustre: use rcu_dereference to access rcu protected current->real_parent field Greg Kroah-Hartman
2014-08-07 11:13   ` Evgeny Budilovsky
2014-08-08  3:49     ` Greg Kroah-Hartman
2014-08-08  4:03       ` Oleg Drokin
2014-08-08  4:42         ` Greg Kroah-Hartman
2014-08-08  5:06           ` Oleg Drokin
2014-08-08  5:32             ` Greg Kroah-Hartman
2014-08-09 11:05               ` Peng Tao
2014-08-09 14:04                 ` Greg Kroah-Hartman
2014-08-09 14:34                   ` Oleg Drokin
2014-08-09 15:47                     ` Greg Kroah-Hartman
2014-08-12  1:44                       ` Oleg Drokin
2014-08-12  2:39                         ` Greg Kroah-Hartman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87k36ltoob.fsf@gmail.com \
    --to=budevg@gmail.com \
    --cc=andreas.dilger@intel.com \
    --cc=bergwolf@gmail.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=green@linuxhacker.ru \
    --cc=gregkh@linuxfoundation.org \
    --cc=lai.siyao@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.