From: Wei Huang <wei.huang2@amd.com>
To: "Panicker, Manoj" <Manoj.Panicker2@amd.com>,
Jakub Kicinski <kuba@kernel.org>
Cc: "linux-pci@vger.kernel.org" <linux-pci@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"linux-doc@vger.kernel.org" <linux-doc@vger.kernel.org>,
"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
"Jonathan.Cameron@Huawei.com" <Jonathan.Cameron@Huawei.com>,
"helgaas@kernel.org" <helgaas@kernel.org>,
"corbet@lwn.net" <corbet@lwn.net>,
"davem@davemloft.net" <davem@davemloft.net>,
"edumazet@google.com" <edumazet@google.com>,
"pabeni@redhat.com" <pabeni@redhat.com>,
"alex.williamson@redhat.com" <alex.williamson@redhat.com>,
"gospo@broadcom.com" <gospo@broadcom.com>,
"michael.chan@broadcom.com" <michael.chan@broadcom.com>,
"ajit.khaparde@broadcom.com" <ajit.khaparde@broadcom.com>,
"somnath.kotur@broadcom.com" <somnath.kotur@broadcom.com>,
"andrew.gospodarek@broadcom.com" <andrew.gospodarek@broadcom.com>,
"VanTassell, Eric" <Eric.VanTassell@amd.com>,
"vadim.fedorenko@linux.dev" <vadim.fedorenko@linux.dev>,
"horms@kernel.org" <horms@kernel.org>,
"bagasdotme@gmail.com" <bagasdotme@gmail.com>,
"bhelgaas@google.com" <bhelgaas@google.com>,
"lukas@wunner.de" <lukas@wunner.de>,
"paul.e.luse@intel.com" <paul.e.luse@intel.com>,
"jing2.liu@intel.com" <jing2.liu@intel.com>
Subject: Re: [PATCH V7 4/5] bnxt_en: Add TPH support in BNXT driver
Date: Tue, 15 Oct 2024 14:50:39 -0500 [thread overview]
Message-ID: <341139a9-a2d0-465e-bdd3-bdd009b78589@amd.com> (raw)
In-Reply-To: <MN0PR12MB6174E0F2572E7BFC65EA464BAF792@MN0PR12MB6174.namprd12.prod.outlook.com>
[These question are for both Jakub and Bjorn]
Any suggestions on how to proceed? I can send out a V8 patchset if Jakub
is OK with Manoj's solution? Or only a new patch #4 is needed since the
rest are intact.
Thanks,
-Wei
On 10/11/24 13:35, Panicker, Manoj wrote:
> [AMD Official Use Only - AMD Internal Distribution Only]
>
> Hello Jakub,
>
> Thanks for the feedback. We'll update the patch to cover the code under the rtnl_lock.
>
> About the empty function, there are no actions to perform when the driver's notify.release function is called. The IRQ notifier is only registered once and there are no older IRQ notifiers for the driver that could get called back. We also followed the precedent seen from other drivers in the kernel tree that follow the same mechanism .
>
> See code:
> From drivers/net/ethernet/intel/i40e/i40e_main.c
> static void i40e_irq_affinity_release(struct kref *ref) {}
>
>
> From drivers/net/ethernet/intel/iavf/iavf_main.c
> static void iavf_irq_affinity_release(struct kref *ref) {}
>
>
> From drivers/net/ethernet/fungible/funeth/funeth_main.c
> static void fun_irq_aff_release(struct kref __always_unused *ref)
> {
> }
>
>
> Thanks
> Manoj
>
> -----Original Message-----
> From: Jakub Kicinski <kuba@kernel.org>
> Sent: Tuesday, October 8, 2024 6:40 AM
> To: Huang2, Wei <Wei.Huang2@amd.com>
> Cc: linux-pci@vger.kernel.org; linux-kernel@vger.kernel.org; linux-doc@vger.kernel.org; netdev@vger.kernel.org; Jonathan.Cameron@Huawei.com; helgaas@kernel.org; corbet@lwn.net; davem@davemloft.net; edumazet@google.com; pabeni@redhat.com; alex.williamson@redhat.com; gospo@broadcom.com; michael.chan@broadcom.com; ajit.khaparde@broadcom.com; somnath.kotur@broadcom.com; andrew.gospodarek@broadcom.com; Panicker, Manoj <Manoj.Panicker2@amd.com>; VanTassell, Eric <Eric.VanTassell@amd.com>; vadim.fedorenko@linux.dev; horms@kernel.org; bagasdotme@gmail.com; bhelgaas@google.com; lukas@wunner.de; paul.e.luse@intel.com; jing2.liu@intel.com
> Subject: Re: [PATCH V7 4/5] bnxt_en: Add TPH support in BNXT driver
>
> Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.
>
>
> On Wed, 2 Oct 2024 11:59:53 -0500 Wei Huang wrote:
>> + if (netif_running(irq->bp->dev)) {
>> + rtnl_lock();
>> + err = netdev_rx_queue_restart(irq->bp->dev, irq->ring_nr);
>> + if (err)
>> + netdev_err(irq->bp->dev,
>> + "rx queue restart failed: err=%d\n", err);
>> + rtnl_unlock();
>> + }
>> +}
>> +
>> +static void __bnxt_irq_affinity_release(struct kref __always_unused
>> +*ref) { }
>
> An empty release function is always a red flag.
> How is the reference counting used here?
> Is irq_set_affinity_notifier() not synchronous?
> Otherwise the rtnl_lock() should probably cover the running check.
next prev parent reply other threads:[~2024-10-15 19:50 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-02 16:59 [PATCH V7 0/5] TPH and cache direct injection support Wei Huang
2024-10-02 16:59 ` [PATCH V7 1/5] PCI: Add TLP Processing Hints (TPH) support Wei Huang
2024-10-02 16:59 ` [PATCH V7 2/5] PCI/TPH: Add Steering Tag support Wei Huang
2025-02-04 18:33 ` Robin Murphy
2025-02-04 20:18 ` Wei Huang
2025-02-05 12:57 ` Robin Murphy
2024-10-02 16:59 ` [PATCH V7 3/5] PCI/TPH: Add TPH documentation Wei Huang
2024-10-02 16:59 ` [PATCH V7 4/5] bnxt_en: Add TPH support in BNXT driver Wei Huang
2024-10-08 13:39 ` Jakub Kicinski
2024-10-11 18:35 ` Panicker, Manoj
2024-10-15 19:50 ` Wei Huang [this message]
2024-10-15 23:45 ` Jakub Kicinski
2024-10-02 16:59 ` [PATCH V7 5/5] bnxt_en: Pass NQ ID to the FW when allocating RX/RX AGG rings Wei Huang
2024-10-02 21:35 ` [PATCH V7 0/5] TPH and cache direct injection support Bjorn Helgaas
2024-10-02 22:08 ` Michael Chan
2024-10-08 7:32 ` Paolo Abeni
2024-10-16 21:31 ` Bjorn Helgaas
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=341139a9-a2d0-465e-bdd3-bdd009b78589@amd.com \
--to=wei.huang2@amd.com \
--cc=Eric.VanTassell@amd.com \
--cc=Jonathan.Cameron@Huawei.com \
--cc=Manoj.Panicker2@amd.com \
--cc=ajit.khaparde@broadcom.com \
--cc=alex.williamson@redhat.com \
--cc=andrew.gospodarek@broadcom.com \
--cc=bagasdotme@gmail.com \
--cc=bhelgaas@google.com \
--cc=corbet@lwn.net \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=gospo@broadcom.com \
--cc=helgaas@kernel.org \
--cc=horms@kernel.org \
--cc=jing2.liu@intel.com \
--cc=kuba@kernel.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=lukas@wunner.de \
--cc=michael.chan@broadcom.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=paul.e.luse@intel.com \
--cc=somnath.kotur@broadcom.com \
--cc=vadim.fedorenko@linux.dev \
/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®