mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Ivan Vecera <ivecera@redhat.com>
To: Michal Schmidt <mschmidt@redhat.com>
Cc: netdev@vger.kernel.org, pawel.chmielewski@intel.com,
	aleksandr.loktionov@intel.com,
	Hugo Ferreira <hferreir@redhat.com>,
	Jesse Brandeburg <jesse.brandeburg@intel.com>,
	Tony Nguyen <anthony.l.nguyen@intel.com>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	"moderated list:INTEL ETHERNET DRIVERS"
	<intel-wired-lan@lists.osuosl.org>,
	open list <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH net] i40e: Enforce software interrupt during busy-poll exit
Date: Wed, 13 Mar 2024 16:15:51 +0100	[thread overview]
Message-ID: <3f934c7b-867c-4550-93ea-4f567807fa98@redhat.com> (raw)
In-Reply-To: <CADEbmW3NQ7SQpccOqTD=p_czpBbOY=41kS7krwx2ZEDmFfcgrg@mail.gmail.com>



On 13. 03. 24 14:47, Michal Schmidt wrote:
>> -/* a small macro to shorten up some long lines */
>> -#define INTREG I40E_PFINT_DYN_CTLN
>> +static inline u32 i40e_buildreg_swint(int type)
>> +{
>> +       u32 val;
>> +
>> +       /* 1. Enable the interrupt
>> +        * 2. Do not modify any ITR interval
>> +        * 3. Trigger a SW interrupt specified by type
>> +        */
>> +       val = I40E_PFINT_DYN_CTLN_INTENA_MASK |
>> +             I40E_PFINT_DYN_CTLN_ITR_INDX_MASK | /* set noitr */
>> +             I40E_PFINT_DYN_CTLN_SWINT_TRIG_MASK |
>> +             I40E_PFINT_DYN_CTLN_SW_ITR_INDX_ENA_MASK |
>> +             FIELD_PREP(I40E_PFINT_DYN_CTLN_SW_ITR_INDX_MASK, type);
>> +
>> +       return val;
>> +}
> This function is called only from one place and with a constant
> argument. Does it  really need to be a function, as opposed to a
> constant? Or are you going to add more callers soon?

This can be reused also from i40e_force_wb() but I didn't want to make 
such refactors in this fix. Lets do it later in -next.

Ivan


  reply	other threads:[~2024-03-13 15:15 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-13 12:54 Ivan Vecera
2024-03-13 13:47 ` Michal Schmidt
2024-03-13 15:15   ` Ivan Vecera [this message]
2024-03-15  0:53 ` Jesse Brandeburg
2024-03-15  9:19   ` Ivan Vecera

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=3f934c7b-867c-4550-93ea-4f567807fa98@redhat.com \
    --to=ivecera@redhat.com \
    --cc=aleksandr.loktionov@intel.com \
    --cc=anthony.l.nguyen@intel.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=hferreir@redhat.com \
    --cc=intel-wired-lan@lists.osuosl.org \
    --cc=jesse.brandeburg@intel.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mschmidt@redhat.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=pawel.chmielewski@intel.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

all inboxes | Powered by JetHome®