]> www.infradead.org Git - users/hch/configfs.git/commit
mlxsw: spectrum_fid: Extract SFMR packing into a helper
authorPetr Machata <petrm@nvidia.com>
Mon, 20 Nov 2023 18:25:29 +0000 (19:25 +0100)
committerJakub Kicinski <kuba@kernel.org>
Tue, 21 Nov 2023 22:53:09 +0000 (14:53 -0800)
commit2b7bccd1f167aa056206cc2551514b35c9fd30ab
treea5088a9ba50d7b7d2f133773da6f8aeded68ff98
parentb51c876c2297f8b32ca579712e3ab1490114d1ee
mlxsw: spectrum_fid: Extract SFMR packing into a helper

Both mlxsw_sp_fid_op() and mlxsw_sp_fid_edit_op() pack the core of SFMR the
same way. Extract the common code into a helper and call that. Extract out
of that a wrapper that just calls mlxsw_reg_sfmr_pack(), because it will
be useful for the dummy family later on.

Signed-off-by: Petr Machata <petrm@nvidia.com>
Reviewed-by: Amit Cohen <amcohen@nvidia.com>
Reviewed-by: Ido Schimmel <idosch@nvidia.com>
Link: https://lore.kernel.org/r/31f32b4d767183f6cb197148d0792feab2efadba.1700503644.git.petrm@nvidia.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/mellanox/mlxsw/spectrum_fid.c