[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220607171949.764e3286@kernel.org>
Date: Tue, 7 Jun 2022 17:19:49 -0700
From: Jakub Kicinski <kuba@...nel.org>
To: Jonathan Toppins <jtoppins@...hat.com>
Cc: netdev@...r.kernel.org, Jay Vosburgh <j.vosburgh@...il.com>,
Veaceslav Falico <vfalico@...il.com>,
Andy Gospodarek <andy@...yhouse.net>,
"David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>,
Paolo Abeni <pabeni@...hat.com>, linux-kernel@...r.kernel.org
Subject: Re: [net-next 1/2] bonding: netlink error message support for
options
On Mon, 6 Jun 2022 11:26:52 -0400 Jonathan Toppins wrote:
> Add support for reporting errors via extack in both bond_newlink
> and bond_changelink.
>
> Instead of having to look in the kernel log for why an option was not
> correct just report the error to the user via the extack variable.
>
> What is currently reported today:
> ip link add bond0 type bond
> ip link set bond0 up
> ip link set bond0 type bond mode 4
> RTNETLINK answers: Device or resource busy
>
> After this change:
> ip link add bond0 type bond
> ip link set bond0 up
> ip link set bond0 type bond mode 4
> Error: unable to set option because the bond is up.
>
> Signed-off-by: Jonathan Toppins <jtoppins@...hat.com>
> ---
>
> Notes:
> Removed the printf support and just added static messages for various
> error events.
Thanks! nit, missing kdoc:
drivers/net/bonding/bond_options.c:729: warning: Function parameter or member 'bad_attr' not described in '__bond_opt_set'
drivers/net/bonding/bond_options.c:729: warning: Function parameter or member 'extack' not described in '__bond_opt_set'
Powered by blists - more mailing lists