From: Patrick McHardy <kaber@trash.net>
To: Pablo Neira Ayuso <pablo@netfilter.org>
Cc: David Miller <davem@davemloft.net>,
netdev@vger.kernel.org, netfilter-devel@vger.kernel.org
Subject: Re: [RFC] netlink broadcast return value
Date: Thu, 12 Feb 2009 13:45:58 +0100 [thread overview]
Message-ID: <49941A06.6050006@trash.net> (raw)
In-Reply-To: <499417E3.5010304@netfilter.org>
Pablo Neira Ayuso wrote:
> Patrick McHardy wrote:
>> So you're returning an error when at least one of the "reliable"
>> sockets doesn't get its delivery.
>
> Patrick, I like it, I'm fine with this approach as soon as it let me add
> the "reliable" ctnetlink state-change reporting. I can add the following
> on top of the patch that David already applied:
>
> --- a/net/netlink/af_netlink.c
> +++ b/net/netlink/af_netlink.c
> [...]
> @@ -999,6 +1000,7 @@ static inline int do_one_broadcast(struct sock *sk,
> p->skb2 = NULL;
> } else if ((val = netlink_broadcast_deliver(sk, p->skb2)) < 0) {
> netlink_overrun(sk);
> + p->delivery_failure = 1;
> ^^^^^^^^^^^^^^^^^^^^^^^^
> Replace this by:
> + if (nlk->flags & NETLINK_HIGHLY_RELIABLE)
> + p->delivery_failure = 1;
>
> And include the flag definition and setsockopt() operations in the new
> patch, of course.
Sounds good. Maybe a nicer name for the flag :)
> Please, find the previous patch that was applied to net-next tree
> enclosed to save you some time in case that you don't know what patch I
> was refering to. I think that the changes (several drivers and such) are
> still useful, as they should ignore the return value of
> netlink_broadcast() since it's not of any use for them (as we already
> discussed, they printk the error, that's useless).
Agreed. The remaining question would be what to do about
xfrm_state. I think it can stay as it is if you add this
flag, *swan could use it if desired.
next prev parent reply other threads:[~2009-02-12 12:46 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-01 13:33 [RFC] netlink broadcast return value Pablo Neira Ayuso
2009-02-02 22:05 ` David Miller
2009-02-09 14:17 ` Patrick McHardy
2009-02-09 22:51 ` Pablo Neira Ayuso
2009-02-09 23:23 ` Patrick McHardy
2009-02-09 23:58 ` Pablo Neira Ayuso
2009-02-10 13:50 ` Patrick McHardy
2009-02-10 18:51 ` Pablo Neira Ayuso
2009-02-11 12:44 ` Patrick McHardy
2009-02-11 16:39 ` Pablo Neira Ayuso
2009-02-11 16:54 ` Patrick McHardy
2009-02-11 21:01 ` Pablo Neira Ayuso
2009-02-12 5:07 ` Patrick McHardy
2009-02-12 12:36 ` Pablo Neira Ayuso
2009-02-12 12:41 ` Pablo Neira Ayuso
2009-02-12 12:48 ` Patrick McHardy
2009-02-12 13:20 ` Pablo Neira Ayuso
2009-02-12 13:25 ` Patrick McHardy
2009-02-12 12:45 ` Patrick McHardy [this message]
2009-02-02 22:35 ` Inaky Perez-Gonzalez
2009-02-03 10:07 ` Pablo Neira Ayuso
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=49941A06.6050006@trash.net \
--to=kaber@trash.net \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=netfilter-devel@vger.kernel.org \
--cc=pablo@netfilter.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).