[Devel] Re: [RFC][v3][PATCH 6/7] Define do_fork_with_pids()

Amerigo Wang xiyou.wangcong at gmail.com
Thu Jun 4 00:21:12 PDT 2009


On Wed, Jun 03, 2009 at 11:07:40PM -0400, Oren Laadan wrote:
>On Tue, 2 Jun 2009, Sukadev Bhattiprolu wrote:
>
>> | >diff --git a/include/linux/types.h b/include/linux/types.h
>> | >index 5abe354..17ec186 100644
>> | >--- a/include/linux/types.h
>> | >+++ b/include/linux/types.h
>> | >@@ -204,6 +204,11 @@ struct ustat {
>> | > 	char			f_fpack[6];
>> | > };
>> | > 
>> | >+struct target_pid_set {
>> | >+	int num_pids;
>> | >+	pid_t *target_pids;
>> | >+};
>> | >+
>> | 
>> | A quick question: why not putting this definition into
>> | include/linux/pid.h?
>> 
>> Well, the data structure needs to be visible to applications so I
>> chose types.h since its already listed in fork(2) man page and the
>> related type, 'pid_t' is defined there.
>
>I don't recall linux/types.h mentioned in the manpage.

In fact, linux/types.h for userspace only has a few types
for endians...

>
>And, heh, it ended up within #ifdef __KERNEL__ there...
>In fact, the types defined in that header are for kernel use.

Yup, I believe Sukadev put it in a wrong position.

Thanks.
_______________________________________________
Containers mailing list
Containers at lists.linux-foundation.org
https://lists.linux-foundation.org/mailman/listinfo/containers




More information about the Devel mailing list