lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <48BDB434.1040805@intel.com>
Date:	Tue, 02 Sep 2008 14:46:28 -0700
From:	Alexander Duyck <alexander.h.duyck@...el.com>
To:	Thomas Graf <tgraf@...g.ch>
CC:	"davem@...emloft.net" <davem@...emloft.net>,
	"netdev@...r.kernel.org" <netdev@...r.kernel.org>
Subject: Re: [RESEND 2.6.27] netlink: Remove compat API for nested attributes

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@...g.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
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ