* [PATCH net-next] bonding: fix kstrtou8() return value verification in num_peer_notif
@ 2014-01-06 10:54 Veaceslav Falico
2014-01-06 17:02 ` Scott Feldman
2014-01-06 21:26 ` David Miller
0 siblings, 2 replies; 4+ messages in thread
From: Veaceslav Falico @ 2014-01-06 10:54 UTC (permalink / raw)
To: netdev; +Cc: Veaceslav Falico, sfeldma, Jay Vosburgh, Andy Gospodarek
It returns 0 in case of success, !0 error otherwise. Fix the improper error
verification.
Fixes: 2c9839c143bbc ("bonding: add num_grat_arp attribute netlink support")
CC: sfeldma@cumulusnetworks.com
CC: Jay Vosburgh <fubar@us.ibm.com>
CC: Andy Gospodarek <andy@greyhouse.net>
Signed-off-by: Veaceslav Falico <vfalico@redhat.com>
---
drivers/net/bonding/bond_sysfs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/bonding/bond_sysfs.c b/drivers/net/bonding/bond_sysfs.c
index 9a1ea4a..011f163 100644
--- a/drivers/net/bonding/bond_sysfs.c
+++ b/drivers/net/bonding/bond_sysfs.c
@@ -776,7 +776,7 @@ static ssize_t bonding_store_num_peer_notif(struct device *d,
int ret;
ret = kstrtou8(buf, 10, &new_value);
- if (!ret) {
+ if (ret) {
pr_err("%s: invalid value %s specified.\n",
bond->dev->name, buf);
return ret;
--
1.8.4
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH net-next] bonding: fix kstrtou8() return value verification in num_peer_notif
2014-01-06 10:54 [PATCH net-next] bonding: fix kstrtou8() return value verification in num_peer_notif Veaceslav Falico
@ 2014-01-06 17:02 ` Scott Feldman
2014-01-06 21:26 ` David Miller
2014-01-06 21:26 ` David Miller
1 sibling, 1 reply; 4+ messages in thread
From: Scott Feldman @ 2014-01-06 17:02 UTC (permalink / raw)
To: Veaceslav Falico; +Cc: Netdev, Jay Vosburgh, Andy Gospodarek
On Jan 6, 2014, at 2:54 AM, Veaceslav Falico <vfalico@redhat.com> wrote:
> It returns 0 in case of success, !0 error otherwise. Fix the improper error
> verification.
>
> Fixes: 2c9839c143bbc ("bonding: add num_grat_arp attribute netlink support")
> CC: sfeldma@cumulusnetworks.com
> CC: Jay Vosburgh <fubar@us.ibm.com>
> CC: Andy Gospodarek <andy@greyhouse.net>
> Signed-off-by: Veaceslav Falico <vfalico@redhat.com>
> ---
> drivers/net/bonding/bond_sysfs.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/bonding/bond_sysfs.c b/drivers/net/bonding/bond_sysfs.c
> index 9a1ea4a..011f163 100644
> --- a/drivers/net/bonding/bond_sysfs.c
> +++ b/drivers/net/bonding/bond_sysfs.c
> @@ -776,7 +776,7 @@ static ssize_t bonding_store_num_peer_notif(struct device *d,
> int ret;
>
> ret = kstrtou8(buf, 10, &new_value);
> - if (!ret) {
> + if (ret) {
> pr_err("%s: invalid value %s specified.\n",
> bond->dev->name, buf);
> return ret;
> --
> 1.8.4
Thanks!
Acked-by: Scott Feldman <sfeldma@cumulusnetworks.com>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH net-next] bonding: fix kstrtou8() return value verification in num_peer_notif
2014-01-06 10:54 [PATCH net-next] bonding: fix kstrtou8() return value verification in num_peer_notif Veaceslav Falico
2014-01-06 17:02 ` Scott Feldman
@ 2014-01-06 21:26 ` David Miller
1 sibling, 0 replies; 4+ messages in thread
From: David Miller @ 2014-01-06 21:26 UTC (permalink / raw)
To: vfalico; +Cc: netdev, sfeldma, fubar, andy
From: Veaceslav Falico <vfalico@redhat.com>
Date: Mon, 6 Jan 2014 11:54:40 +0100
> It returns 0 in case of success, !0 error otherwise. Fix the improper error
> verification.
>
> Fixes: 2c9839c143bbc ("bonding: add num_grat_arp attribute netlink support")
> CC: sfeldma@cumulusnetworks.com
> CC: Jay Vosburgh <fubar@us.ibm.com>
> CC: Andy Gospodarek <andy@greyhouse.net>
> Signed-off-by: Veaceslav Falico <vfalico@redhat.com>
Applied, thanks.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH net-next] bonding: fix kstrtou8() return value verification in num_peer_notif
2014-01-06 17:02 ` Scott Feldman
@ 2014-01-06 21:26 ` David Miller
0 siblings, 0 replies; 4+ messages in thread
From: David Miller @ 2014-01-06 21:26 UTC (permalink / raw)
To: sfeldma; +Cc: vfalico, netdev, fubar, andy
From: Scott Feldman <sfeldma@cumulusnetworks.com>
Date: Mon, 6 Jan 2014 09:02:18 -0800
> Acked-by: Scott Feldman <sfeldma@cumulusnetworks.com>--
Please put a newline at the end of your ACK next time so that
the posting footer doesn't become a part of it :-)
Thanks.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2014-01-06 21:26 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-01-06 10:54 [PATCH net-next] bonding: fix kstrtou8() return value verification in num_peer_notif Veaceslav Falico
2014-01-06 17:02 ` Scott Feldman
2014-01-06 21:26 ` David Miller
2014-01-06 21:26 ` David Miller
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).