From: David Miller <davem@davemloft.net>
To: mk.singh@oracle.com
Cc: netdev@vger.kernel.org, eric.dumazet@gmail.com, mkubecek@suse.cz,
j.vosburgh@gmail.com, vfalico@gmail.com, andy@greyhouse.net,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] bonding:avoid repeated display of same link status change
Date: Fri, 02 Nov 2018 23:31:38 -0700 (PDT) [thread overview]
Message-ID: <20181102.233138.738200505012734856.davem@davemloft.net> (raw)
In-Reply-To: <20181031105729.7442-1-mk.singh@oracle.com>
From: mk.singh@oracle.com
Date: Wed, 31 Oct 2018 16:27:28 +0530
> - if (slave->delay) {
> + if (slave->delay &&
> + !atomic64_read(&bond->rtnl_needed)) {
...
> + !atomic64_read(&bond->rtnl_needed)) {
...
> + atomic64_set(&bond->rtnl_needed, 1);
...
> + atomic64_set(&bond->rtnl_needed, 0);
...
> @@ -229,6 +229,7 @@ struct bonding {
> struct dentry *debug_dir;
> #endif /* CONFIG_DEBUG_FS */
> struct rtnl_link_stats64 bond_stats;
> + atomic64_t rtnl_needed;
There is nothing "atomic" about a value that is only set and read.
And using a full 64-bit value for something taking on only '0' and
'1' is unnecessary as well.
next prev parent reply other threads:[~2018-11-03 6:31 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-10-31 10:57 [PATCH] bonding:avoid repeated display of same link status change mk.singh
2018-11-03 6:31 ` David Miller [this message]
2018-11-04 19:41 ` Michal Kubecek
2018-11-20 10:41 ` Manish Kumar Singh
-- strict thread matches above, loose matches on Subject: below --
2018-10-23 15:29 mk.singh
2018-10-23 15:54 ` Mahesh Bandewar (महेश बंडेवार)
2018-10-23 16:10 ` Eric Dumazet
2018-10-23 16:26 ` Michal Kubecek
2018-10-23 16:38 ` Michal Kubecek
2018-10-25 9:21 ` Manish Kumar Singh
2018-10-25 9:29 ` Michal Kubecek
2018-10-26 6:49 ` Manish Kumar Singh
2018-10-23 18:08 ` David Miller
2018-09-17 7:20 [PATCH] bonding: avoid " mk.singh
2018-09-17 14:38 ` Eric Dumazet
2018-09-18 5:05 ` Manish Kumar Singh
2018-09-18 14:00 ` Eric Dumazet
2018-09-24 7:05 ` Manish Kumar Singh
2018-10-22 7:29 ` Manish Kumar Singh
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=20181102.233138.738200505012734856.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=andy@greyhouse.net \
--cc=eric.dumazet@gmail.com \
--cc=j.vosburgh@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mk.singh@oracle.com \
--cc=mkubecek@suse.cz \
--cc=netdev@vger.kernel.org \
--cc=vfalico@gmail.com \
/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).