* [PATCH] stating/lustre: fix misuse of current->parent.
@ 2014-07-18 5:39 NeilBrown
0 siblings, 0 replies; only message in thread
From: NeilBrown @ 2014-07-18 5:39 UTC (permalink / raw)
To: Greg Kroah-Hartman; +Cc: linux-kernel, Peng Tao, Andreas Dilger
[-- Attachment #1: Type: text/plain, Size: 1034 bytes --]
current->parent is used by ptrace to redirect some signal delivery
to the ptracer. It should only be used by 'ptrace' or 'signal' code.
All other users should use current->real_parent, which is the real
parent.
Signed-off-by: NeilBrown <neilb@suse.de>
diff --git a/drivers/staging/lustre/lustre/llite/lproc_llite.c b/drivers/staging/lustre/lustre/llite/lproc_llite.c
index 77ee9e58cf87..5c5d2d6470f1 100644
--- a/drivers/staging/lustre/lustre/llite/lproc_llite.c
+++ b/drivers/staging/lustre/lustre/llite/lproc_llite.c
@@ -909,7 +909,7 @@ 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->parent->pid)
+ sbi->ll_stats_track_id == 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 ==
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 828 bytes --]
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2014-07-18 5:39 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-07-18 5:39 [PATCH] stating/lustre: fix misuse of current->parent NeilBrown
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox