From: Michal Swiatkowski <michal.swiatkowski@linux.intel.com>
To: Jiri Pirko <jiri@resnulli.us>
Cc: karthiksundaravel <ksundara@redhat.com>,
jesse.brandeburg@intel.com, anthony.l.nguyen@intel.com,
davem@davemloft.net, edumazet@google.com, kuba@kernel.org,
pabeni@redhat.com, intel-wired-lan@lists.osuosl.org,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
rjarry@redhat.com, aharivel@redhat.com, vchundur@redhat.com,
cfontain@redhat.com
Subject: Re: [PATCH] ice: Add get/set hw address for VF representor ports
Date: Thu, 1 Feb 2024 07:55:26 +0100 [thread overview]
Message-ID: <ZbtAXuLtrhrbYjEw@mev-dev> (raw)
In-Reply-To: <Zbo2RJErBsD0Sc_z@nanopsycho>
On Wed, Jan 31, 2024 at 01:00:04PM +0100, Jiri Pirko wrote:
> Wed, Jan 31, 2024 at 11:43:44AM CET, michal.swiatkowski@linux.intel.com wrote:
> >On Wed, Jan 31, 2024 at 01:38:47PM +0530, karthiksundaravel wrote:
> >> Changing the mac address of the VF representor ports are not
> >> available via devlink. Add the function handlers to set and get
> >> the HW address for the VF representor ports.
> >>
> >> Signed-off-by: karthiksundaravel <ksundara@redhat.com>
> >> ---
> >> drivers/net/ethernet/intel/ice/ice_devlink.c | 134 ++++++++++++++++++-
> >> 1 file changed, 132 insertions(+), 2 deletions(-)
> >>
> >> diff --git a/drivers/net/ethernet/intel/ice/ice_devlink.c b/drivers/net/ethernet/intel/ice/ice_devlink.c
> >> index 80dc5445b50d..56d81836c469 100644
> >> --- a/drivers/net/ethernet/intel/ice/ice_devlink.c
> >> +++ b/drivers/net/ethernet/intel/ice/ice_devlink.c
> >> @@ -9,6 +9,8 @@
> >
> >As Jiri already wrote, you are not changing MAC of VF in your code. Try
> >to look at ice_set_vf_mac in ice_sriov.c. In current implementation you
> >nedd to set new MAC value for VF and reset it. You shouldn't use PF VSI.
> >
> >Pointer to VF you can get from representor struct (through parent VSI).
>
> What if it is in a different host? Would you still be able to change the
> mac?
>
In current VF MAC changing implementation yes, because it is done by
resetting the VF. After the reset new MAC will be sent via virtchnl.
But I think resetting VF may be incorrect here, as it leads to reset
also port representor.
>
> >
> >You shouldn't manage the rules during MAC changing, as in switchdev
> >slow-path there shouldn't be VF MAC rules. It can be problematic as user
> >already can have MAC + sth rule (which also needs to be change). I will
> >leave it to user (most probably the MAC change happens before adding any
> >rules).
>
> Rules are on the representor, not the VF, correct? Seems unrelated to
> me.
>
I pointed it out because it was in the code. Rules added on representor
points to corresponding VF. My point was that there shouldn't be any
changes to rules after changing MAC.
>
> >
> >In few days we will send patchset for subfunction support where the
> >subfunction MAC chaning is implementing from devlink API. I will add you
> >to the CC.
> >
> >Thanks for working on it, it is a gap in our solution.
> >
> >Thanks,
> >Michal
> >
next prev parent reply other threads:[~2024-02-01 6:55 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-31 8:08 [PATCH] ice: Add get/set hw address for VF representor ports karthiksundaravel
2024-01-31 8:55 ` Jiri Pirko
2024-01-31 10:43 ` Michal Swiatkowski
2024-01-31 12:00 ` Jiri Pirko
2024-02-01 6:55 ` Michal Swiatkowski [this message]
2024-01-31 16:15 ` [Intel-wired-lan] " Paul Menzel
2024-02-01 7:40 ` Jiri Pirko
2024-02-01 8:00 ` Paul Menzel
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=ZbtAXuLtrhrbYjEw@mev-dev \
--to=michal.swiatkowski@linux.intel.com \
--cc=aharivel@redhat.com \
--cc=anthony.l.nguyen@intel.com \
--cc=cfontain@redhat.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=intel-wired-lan@lists.osuosl.org \
--cc=jesse.brandeburg@intel.com \
--cc=jiri@resnulli.us \
--cc=ksundara@redhat.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=rjarry@redhat.com \
--cc=vchundur@redhat.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).