netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andrew Lunn <andrew@lunn.ch>
To: "Csókás Bence" <csokas.bence@prolan.hu>
Cc: netdev@vger.kernel.org,
	Richard Cochran <richardcochran@gmail.com>,
	"David S. Miller" <davem@davemloft.net>,
	Jakub Kicinski <kuba@kernel.org>,
	qiangqing.zhang@nxp.com, kernel@pengutronix.de,
	Marc Kleine-Budde <mkl@pengutronix.de>
Subject: Re: [PATCH v2] net: fec: Use unlocked timecounter reads for saving state
Date: Tue, 30 Aug 2022 14:29:08 +0200	[thread overview]
Message-ID: <Yw4ClKHWACSP2EQ1@lunn.ch> (raw)
In-Reply-To: <20220830111516.82875-1-csokas.bence@prolan.hu>

> -	fec_ptp_gettime(&fep->ptp_caps, &fep->ptp_saved_state.ts_phc);
> +	if (preempt_count_equals(0)) {

~/linux/drivers$ grep -r preempt_count_equals *
~/linux/drivers$ 

No other driver plays games like this.

Why not unconditionally take the lock?

    Andrew

  reply	other threads:[~2022-08-30 12:29 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-30 11:15 [PATCH v2] net: fec: Use unlocked timecounter reads for saving state Csókás Bence
2022-08-30 12:29 ` Andrew Lunn [this message]
2022-08-30 15:05   ` Csókás Bence
2022-08-30 15:21     ` Andrew Lunn
2022-08-31 13:09       ` Csókás Bence
2022-08-31  3:41     ` Richard Cochran
2022-08-31 10:20 ` kernel test robot
2022-09-01 21:52 ` kernel test robot

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=Yw4ClKHWACSP2EQ1@lunn.ch \
    --to=andrew@lunn.ch \
    --cc=csokas.bence@prolan.hu \
    --cc=davem@davemloft.net \
    --cc=kernel@pengutronix.de \
    --cc=kuba@kernel.org \
    --cc=mkl@pengutronix.de \
    --cc=netdev@vger.kernel.org \
    --cc=qiangqing.zhang@nxp.com \
    --cc=richardcochran@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).