On 6/3/06, cheng long <kevinclcn@xxxxxxxxx> wrote:
Hi Cheng
no it isn't .. it's the receiver pid. this is an excerpt from the article you've pointed to:
"You also can send a multicast message. The following API delivers a netlink message to both the process specified by pid and the multicast groups specified by group:"
hope this helps
Hi, All !
int netlink_broadcast(struct sock *ssk, struct sk_buff *skb, u32 pid,
u32 group, int allocation);
What does the pid mean? Someone said that it is the pid of the receiver.
For example, Kevin He said it delivers a netlink message to both the
process specified by pid and the multicast groups specified by group
(http://www.linuxjournal.com/article/7356.)
But, in function do_one_broadcast() which is called in netlink_broadcast(),
there are some sentences like this:
744 struct netlink_opt *nlk = nlk_sk(sk);
750 if (nlk->pid == p->pid || !(nlk->groups & p->group))
751 goto out;
where p is a variable constructed from parameters of netlink_broadcast().
I think these sentences mean that the parameter pid of netlink_broadcast()
is the sender's pid?
Hi Cheng
no it isn't .. it's the receiver pid. this is an excerpt from the article you've pointed to:
"You also can send a multicast message. The following API delivers a netlink message to both the process specified by pid and the multicast groups specified by group:"
hope this helps
Am I right?
Thanks !
Regard,
Cheng
--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive: http://mail.nl.linux.org/kernelnewbies/
FAQ: http://kernelnewbies.org/faq/
--
MHD.Tayseer