From: MD Danish Anwar <danishanwar@ti.com>
To: Andrew Lunn <andrew@lunn.ch>,
"Anwar, Md Danish" <a0501179@ti.com>,
Roger Quadros <rogerq@kernel.org>
Cc: Roger Quadros <rogerq@kernel.org>,
Dan Carpenter <dan.carpenter@linaro.org>,
Jan Kiszka <jan.kiszka@siemens.com>,
Javier Carrasco <javier.carrasco.cruz@gmail.com>,
Jacob Keller <jacob.e.keller@intel.com>,
Diogo Ivo <diogo.ivo@siemens.com>,
Simon Horman <horms@kernel.org>,
Richard Cochran <richardcochran@gmail.com>,
Paolo Abeni <pabeni@redhat.com>, Jakub Kicinski <kuba@kernel.org>,
Eric Dumazet <edumazet@google.com>,
"David S. Miller" <davem@davemloft.net>,
<linux-kernel@vger.kernel.org>, <netdev@vger.kernel.org>,
<linux-arm-kernel@lists.infradead.org>, <srk@ti.com>,
Vignesh Raghavendra <vigneshr@ti.com>
Subject: Re: [PATCH net-next v3 3/6] net: ti: icssg-prueth: Add support for HSR frame forward offload
Date: Tue, 3 Sep 2024 15:04:57 +0530 [thread overview]
Message-ID: <5a2d24d6-ebfb-4633-8548-8e9bffbbfb48@ti.com> (raw)
In-Reply-To: <f2598368-745f-4a83-abfc-b9609ebff6b0@lunn.ch>
On 02/09/24 6:32 pm, Andrew Lunn wrote:
>> Yes, and I have already added this in this series based on your feedback
>> on v2.
>>
>> I have one question though, in emac_ndo_set_features() should I change
>> these HSR related features irrespective of the current mode?
>>
>> AFAIK, if NETIF_F_HW_HSR_FWD is set, the forwarding is offloaded to HW.
>> If NETIF_F_HW_HSR_FWD is not set the forwarding is not offloaded to HW
>> and is done in SW.
>>
>> So, I don't see any need to enable this features if we are currently in
>> switch mode. Let me know what do you think. Should I still enable this
>> feature irrespective of current mode and later handle this in
>> prueth_hsr_port_link / unlink()?
>
> The user should not need to know about the different firmwares. So i
> would allow NETIF_F_HW_HSR_FWD at any time.
>
> The exception would be, if you look at all the other drivers which
> implement HSR offload, if they all return an error if the offloading
> cannot be enabled, then you should do the same.
>
Andrew, I looked at xrs700x dsa and microchip ksz dsa driver as an
example. The drivers return -EOPNOTSUPP whenever offloading is not
possible in the xrs700x_hsr_join / ksz_hsr_join api. I think the same
should be okay for ICSSG driver as well. ICSSG drivers equivalent API is
prueth_hsr_port_link() where I will return -EOPNOTSUPP whenever
offloading is not possible.
So in the .ndo_set_features() I will not add any check so that the user
wouldn't know about the current firmware and whether offloading is
supported or not. In the prueth_hsr_port_link() based on firmware
limitation we will error out.
Andrew, Roger, Let me know if this sounds good.
> Andrew
--
Thanks and Regards,
Danish
next prev parent reply other threads:[~2024-09-03 9:35 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-28 9:18 [PATCH net-next v3 0/6] Introduce HSR offload support for ICSSG MD Danish Anwar
2024-08-28 9:18 ` [PATCH net-next v3 1/6] net: ti: icss-iep: Move icss_iep structure MD Danish Anwar
2024-08-28 9:18 ` [PATCH net-next v3 2/6] net: ti: icssg-prueth: Stop hardcoding def_inc MD Danish Anwar
2024-08-28 9:18 ` [PATCH net-next v3 3/6] net: ti: icssg-prueth: Add support for HSR frame forward offload MD Danish Anwar
2024-08-30 13:27 ` Roger Quadros
2024-08-30 14:00 ` Andrew Lunn
2024-09-02 5:51 ` Anwar, Md Danish
2024-09-02 13:02 ` Andrew Lunn
2024-09-03 9:34 ` MD Danish Anwar [this message]
2024-09-02 5:28 ` Anwar, Md Danish
2024-08-30 14:07 ` Alexander Lobakin
2024-09-04 9:54 ` MD Danish Anwar
2024-08-28 9:18 ` [PATCH net-next v3 4/6] net: ti: icssg-prueth: Enable HSR Tx Packet duplication offload MD Danish Anwar
2024-08-30 13:30 ` Roger Quadros
2024-09-02 5:35 ` Anwar, Md Danish
2024-08-28 9:19 ` [PATCH net-next v3 5/6] net: ti: icssg-prueth: Add multicast filtering support in HSR mode MD Danish Anwar
2024-08-30 13:30 ` Roger Quadros
2024-08-28 9:19 ` [PATCH net-next v3 6/6] net: ti: icssg-prueth: Enable HSR Tx Tag and Rx Tag offload MD Danish Anwar
2024-08-30 13:36 ` Roger Quadros
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=5a2d24d6-ebfb-4633-8548-8e9bffbbfb48@ti.com \
--to=danishanwar@ti.com \
--cc=a0501179@ti.com \
--cc=andrew@lunn.ch \
--cc=dan.carpenter@linaro.org \
--cc=davem@davemloft.net \
--cc=diogo.ivo@siemens.com \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=jacob.e.keller@intel.com \
--cc=jan.kiszka@siemens.com \
--cc=javier.carrasco.cruz@gmail.com \
--cc=kuba@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=richardcochran@gmail.com \
--cc=rogerq@kernel.org \
--cc=srk@ti.com \
--cc=vigneshr@ti.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®