lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <IA1PR11MB624112E2C04D751315976D938B832@IA1PR11MB6241.namprd11.prod.outlook.com>
Date: Wed, 30 Apr 2025 05:07:45 +0000
From: "Rinitha, SX" <sx.rinitha@...el.com>
To: "Kitszel, Przemyslaw" <przemyslaw.kitszel@...el.com>,
	"intel-wired-lan@...ts.osuosl.org" <intel-wired-lan@...ts.osuosl.org>,
	"Nguyen, Anthony L" <anthony.l.nguyen@...el.com>
CC: Jiri Pirko <jiri@...nulli.us>, "Temerkhanov, Sergey"
	<sergey.temerkhanov@...el.com>, "netdev@...r.kernel.org"
	<netdev@...r.kernel.org>, "Loktionov, Aleksandr"
	<aleksandr.loktionov@...el.com>, "Kolacinski, Karol"
	<karol.kolacinski@...el.com>, "Kubiak, Michal" <michal.kubiak@...el.com>,
	Simon Horman <horms@...nel.org>, "Kitszel, Przemyslaw"
	<przemyslaw.kitszel@...el.com>, "Keller, Jacob E" <jacob.e.keller@...el.com>,
	Jakub Kicinski <kuba@...nel.org>
Subject: RE: [Intel-wired-lan] [PATCH iwl-net v4] ice: use DSN instead of PCI
 BDF for ice_adapter index

> -----Original Message-----
> From: Intel-wired-lan <intel-wired-lan-bounces@...osl.org> On Behalf Of Przemek Kitszel
> Sent: 14 April 2025 18:43
> To: intel-wired-lan@...ts.osuosl.org; Nguyen, Anthony L <anthony.l.nguyen@...el.com>
> Cc: Jiri Pirko <jiri@...nulli.us>; Temerkhanov, Sergey <sergey.temerkhanov@...el.com>; netdev@...r.kernel.org; Loktionov, Aleksandr <aleksandr.loktionov@...el.com>; Kolacinski, Karol <karol.kolacinski@...el.com>; Kubiak, > Michal <michal.kubiak@...el.com>; Simon Horman <horms@...nel.org>; Kitszel, Przemyslaw <przemyslaw.kitszel@...el.com>; Keller, Jacob E <jacob.e.keller@...el.com>; Jakub Kicinski <kuba@...nel.org>
> Subject: [Intel-wired-lan] [PATCH iwl-net v4] ice: use DSN instead of PCI BDF for ice_adapter index
>
> Use Device Serial Number instead of PCI bus/device/function for the index of struct ice_adapter.
>
> Functions on the same physical device should point to the very same ice_adapter instance, but with two PFs, when at least one of them is PCI-e passed-through to a VM, it is no longer the case - PFs will get seemingly random PCI BDF values, and thus indices, what finally leds to each of them being on their own instance of ice_adapter. That causes them to don't attempt any synchronization of the PTP HW clock usage, or any other future resources.
>
> DSN works nicely in place of the index, as it is "immutable" in terms of virtualization.
>
> Fixes: 0e2bddf9e5f9 ("ice: add ice_adapter for shared data across PFs on the same NIC")
> Suggested-by: Jacob Keller <jacob.e.keller@...el.com>
> Suggested-by: Jakub Kicinski <kuba@...nel.org>
> Suggested-by: Jiri Pirko <jiri@...nulli.us>
> Reviewed-by: Aleksandr Loktionov <aleksandr.loktionov@...el.com>
> Signed-off-by: Przemek Kitszel <przemyslaw.kitszel@...el.com>
> ---
> CC: Karol Kolacinski <karol.kolacinski@...el.com>
> CC: Grzegorz Nitka <grzegorz.nitka@...el.com>
> CC: Michal Schmidt <mschmidt@...hat.com>
> CC: Sergey Temerkhanov <sergey.temerkhanov@...el.com>
> CC: Michal Kubiak <michal.kubiak@...el.com>
> CC: Simon Horman <horms@...nel.org>
>
> v4:
> - Add fixes tag for real... (Simon)
> - extend commit message (Simon)
> - pass dsn to ice_adapter_new() to have simpler code
>   (I happened to do that as (local) followup) (me)
>
> v3:
> https://lore.kernel.org/intel-wired-lan/20250408134655.4287-1-przemyslaw.kitszel@intel.com/
> - Add fixes tag (Michal K)
> - add missing braces (lkp bot), turns out it's hard to purge C++ from your mind
> - (no changes in the collision handling on 32bit systems)
>
> v2:
> https://lore.kernel.org/intel-wired-lan/20250407112005.85468-1-przemyslaw.kitszel@intel.com/
> - target to -net (Jiri)
> - mix both halves of u64 DSN on 32bit systems (Jiri)
> - (no changes in terms of fallbacks for pre-prod HW)
> - warn when there is DSN collision after reducing to 32bit
>
> v1:
> https://lore.kernel.org/netdev/20250306211159.3697-2-przemyslaw.kitszel@intel.com
> ---
> drivers/net/ethernet/intel/ice/ice_adapter.h |  6 ++-  drivers/net/ethernet/intel/ice/ice_adapter.c | 47 ++++++++------------
> 2 files changed, 22 insertions(+), 31 deletions(-)
>

Tested-by: Rinitha S <sx.rinitha@...el.com> (A Contingent worker at Intel)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ