netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Linus Lüssing" <linus.luessing@c0d3.blue>
To: Ben Greear <greearb@candelatech.com>
Cc: "Linus Lüssing" <ll@simonwunderlich.de>,
	ath10k@lists.infradead.org, "Kalle Valo" <kvalo@codeaurora.org>,
	"David S . Miller" <davem@davemloft.net>,
	"Simon Wunderlich" <sw@simonwunderlich.de>,
	linux-wireless@vger.kernel.org, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH net-next] ath10k: fix RX of frames with broken FCS in monitor mode
Date: Thu, 7 Nov 2019 15:03:31 +0100	[thread overview]
Message-ID: <20191107140149.GB19482@otheros> (raw)
In-Reply-To: <927cea69-7afc-5c35-df8d-9813392e8928@candelatech.com>

On Tue, Nov 05, 2019 at 09:19:20AM -0800, Ben Greear wrote:
> Thanks for adding the counter.  Since it us u32, I doubt you need the spin lock
> below?

Ok, I can remove the spin-lock.

Just for clarification though, if I recall correctly then an increment operator
is not guaranteed to work atomically. But you think it's unlikely
to race with a concurrent ++ and therefore it's fine for just a debug counter?
(and if it were racing, it'd just be a missed +1)

Or is there another mechanism that avoids concurrency in the
ath10k RX path?


> 
> --Ben
> 
> > +	if (!(ar->filter_flags & FIF_FCSFAIL) &&
> > +	    status->flag & RX_FLAG_FAILED_FCS_CRC) {
> > +		spin_lock_bh(&ar->data_lock);
> > +		ar->stats.rx_crc_err_drop++;
> > +		spin_unlock_bh(&ar->data_lock);
> > +
> > +		dev_kfree_skb_any(skb);
> > +		return;
> > +	}
> > +
> >   	ath10k_dbg(ar, ATH10K_DBG_DATA,
> >   		   "rx skb %pK len %u peer %pM %s %s sn %u %s%s%s%s%s%s %srate_idx %u vht_nss %u freq %u band %u flag 0x%x fcs-err %i mic-err %i amsdu-more %i\n",
> >   		   skb,
> > 
> 
> 
> -- 
> Ben Greear <greearb@candelatech.com>
> Candela Technologies Inc  http://www.candelatech.com
> 

  reply	other threads:[~2019-11-07 14:03 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-05 16:49 [PATCH net-next] ath10k: fix RX of frames with broken FCS in monitor mode Linus Lüssing
2019-11-05 17:19 ` Ben Greear
2019-11-07 14:03   ` Linus Lüssing [this message]
2019-11-07 15:24     ` Ben Greear

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=20191107140149.GB19482@otheros \
    --to=linus.luessing@c0d3.blue \
    --cc=ath10k@lists.infradead.org \
    --cc=davem@davemloft.net \
    --cc=greearb@candelatech.com \
    --cc=kvalo@codeaurora.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=ll@simonwunderlich.de \
    --cc=netdev@vger.kernel.org \
    --cc=sw@simonwunderlich.de \
    /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).