[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <f2eee17c-835c-b14e-6c96-4fd8fb7d18c9@cumulusnetworks.com>
Date: Mon, 17 Oct 2016 18:42:14 -0600
From: David Ahern <dsa@...ulusnetworks.com>
To: Stephen Hemminger <stephen@...workplumber.org>
Cc: jiri@...lanox.com, netdev@...r.kernel.org, davem@...emloft.net,
dledford@...hat.com, sean.hefty@...el.com,
hal.rosenstock@...il.com, linux-rdma@...r.kernel.org,
j.vosburgh@...il.com, vfalico@...il.com, andy@...yhouse.net,
jeffrey.t.kirsher@...el.com, intel-wired-lan@...ts.osuosl.org
Subject: Re: [PATCH net-next 02/11] net: Introduce new api for walking upper
and lower devices
On 10/17/16 6:21 AM, Stephen Hemminger wrote:
>
> No if/else needed. No cast of void * ptr need. Use const if possible?
>
so much of the stack does not use const and trying to add it for this API does not work -- the upper or lower device is passed to the callbacks and those callbacks invoke other apis. e.g., the bond patch calls vlan_get_encap_level, bond_verify_device_path and bond_confirm_addr and none of those accept a const dev.
v3 coming up with the more succinct versions, but const is not possible.
Powered by blists - more mailing lists