[Devel] [PATCH] Use task_pgrp() and task_session in binfmt
sukadev at us.ibm.com
sukadev at us.ibm.com
Thu Feb 22 15:31:17 PST 2007
From: Sukadev Bhattiprolu <sukadev at us.ibm.com>
Subject: [PATCH] Use task_pgrp() and task_session in binfmt
Use container friendly interfaces task_pgrp() and task_session() in
binfmt files
Signed-off-by: Sukadev Bhattiprolu <sukadev at us.ibm.com>
Cc: Cedric Le Goater <clg at fr.ibm.com>
Cc: Dave Hansen <haveblue at us.ibm.com>
Cc: Serge Hallyn <serue at us.ibm.com>
Cc: containers at lists.osdl.org
---
fs/binfmt_elf.c | 8 ++++----
fs/binfmt_elf_fdpic.c | 8 ++++----
2 files changed, 8 insertions(+), 8 deletions(-)
Index: lx26-20-mm1/fs/binfmt_elf.c
===================================================================
--- lx26-20-mm1.orig/fs/binfmt_elf.c 2007-02-16 14:32:50.000000000 -0800
+++ lx26-20-mm1/fs/binfmt_elf.c 2007-02-16 15:42:26.000000000 -0800
@@ -1319,8 +1319,8 @@ static void fill_prstatus(struct elf_prs
prstatus->pr_sighold = p->blocked.sig[0];
prstatus->pr_pid = p->pid;
prstatus->pr_ppid = p->parent->pid;
- prstatus->pr_pgrp = process_group(p);
- prstatus->pr_sid = process_session(p);
+ prstatus->pr_pgrp = pid_nr(task_pgrp(p));
+ prstatus->pr_sid = pid_nr(task_session(p));
if (thread_group_leader(p)) {
/*
* This is the record for the group leader. Add in the
@@ -1365,8 +1365,8 @@ static int fill_psinfo(struct elf_prpsin
psinfo->pr_pid = p->pid;
psinfo->pr_ppid = p->parent->pid;
- psinfo->pr_pgrp = process_group(p);
- psinfo->pr_sid = process_session(p);
+ psinfo->pr_pgrp = pid_nr(task_pgrp(p));
+ psinfo->pr_sid = pid_nr(task_session(p));
i = p->state ? ffz(~p->state) + 1 : 0;
psinfo->pr_state = i;
Index: lx26-20-mm1/fs/binfmt_elf_fdpic.c
===================================================================
--- lx26-20-mm1.orig/fs/binfmt_elf_fdpic.c 2007-02-16 14:32:50.000000000 -0800
+++ lx26-20-mm1/fs/binfmt_elf_fdpic.c 2007-02-16 15:42:26.000000000 -0800
@@ -1321,8 +1321,8 @@ static void fill_prstatus(struct elf_prs
prstatus->pr_sighold = p->blocked.sig[0];
prstatus->pr_pid = p->pid;
prstatus->pr_ppid = p->parent->pid;
- prstatus->pr_pgrp = process_group(p);
- prstatus->pr_sid = process_session(p);
+ prstatus->pr_pgrp = pid_nr(task_pgrp(p));
+ prstatus->pr_sid = pid_nr(task_session(p));
if (thread_group_leader(p)) {
/*
* This is the record for the group leader. Add in the
@@ -1370,8 +1370,8 @@ static int fill_psinfo(struct elf_prpsin
psinfo->pr_pid = p->pid;
psinfo->pr_ppid = p->parent->pid;
- psinfo->pr_pgrp = process_group(p);
- psinfo->pr_sid = process_session(p);
+ psinfo->pr_pgrp = pid_nr(task_pgrp(p));
+ psinfo->pr_sid = pid_nr(task_session(p));
i = p->state ? ffz(~p->state) + 1 : 0;
psinfo->pr_state = i;
_______________________________________________
Containers mailing list
Containers at lists.osdl.org
https://lists.osdl.org/mailman/listinfo/containers
More information about the Devel
mailing list