From: Alexander Duyck <alexander.h.duyck@intel.com>
To: Thomas Graf <tgraf@suug.ch>
Cc: "davem@davemloft.net" <davem@davemloft.net>,
"netdev@vger.kernel.org" <netdev@vger.kernel.org>
Subject: Re: [RESEND 2.6.27] netlink: Remove compat API for nested attributes
Date: Tue, 02 Sep 2008 14:46:28 -0700 [thread overview]
Message-ID: <48BDB434.1040805@intel.com> (raw)
In-Reply-To: <20080828140527.GC20815@postel.suug.ch>
Thomas Graf wrote:
> Removes all _nested_compat() functions from the API. The prio qdisc
> no longer requires them and netem has its own format anyway. Their
> existance is only confusing.
>
> Resend: Also remove the wrapper macro.
>
> Signed-off-by: Thomas Graf <tgraf@suug.ch>
>
I don't think we need to do anything as drastic as completely throwing
out this part of the Kernel ABI. This is what I have been trying to get
at all along. All we need to do is revert the two patches that we
talked about earlier and everything goes back to working.
> Index: net-2.6/net/sched/sch_prio.c
> ===================================================================
> --- net-2.6.orig/net/sched/sch_prio.c 2008-08-28 12:52:07.000000000 +0200
> +++ net-2.6/net/sched/sch_prio.c 2008-08-28 15:33:14.000000000 +0200
> @@ -254,16 +254,12 @@
> {
> struct prio_sched_data *q = qdisc_priv(sch);
> unsigned char *b = skb_tail_pointer(skb);
> - struct nlattr *nest;
> struct tc_prio_qopt opt;
>
> opt.bands = q->bands;
> memcpy(&opt.priomap, q->prio2band, TC_PRIO_MAX+1);
>
> - nest = nla_nest_compat_start(skb, TCA_OPTIONS, sizeof(opt), &opt);
> - if (nest == NULL)
> - goto nla_put_failure;
> - nla_nest_compat_end(skb, nest);
> + NLA_PUT(skb, TCA_OPTIONS, sizeof(opt), &opt);
>
> return skb->len;
This is the one section of this patch that I do completely agree with.
There is no need to generate a nested compat attribute when there is
nothing there to nest. Since "multiqueue" is gone, this change can be
made to just clean up the netlink portion of prio.
Thanks,
Alex
next prev parent reply other threads:[~2008-09-02 21:46 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-08-28 14:00 [PATCH 2.6.27] netlink: Remove compat API for nested attributes Thomas Graf
2008-08-28 14:05 ` [RESEND " Thomas Graf
2008-09-02 21:46 ` Alexander Duyck [this message]
2008-09-02 23:04 ` David Miller
2008-09-02 23:20 ` Thomas Graf
2008-09-03 0:27 ` Alexander Duyck
2008-09-03 0:34 ` David Miller
2008-09-03 0:30 ` David Miller
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=48BDB434.1040805@intel.com \
--to=alexander.h.duyck@intel.com \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=tgraf@suug.ch \
/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).