android_kernel_xiaomi_sm8450/drivers/infiniband
Dragos Tatulea d217141345 IB/IPoIB: Fix queue count inconsistency for PKEY child interfaces
[ Upstream commit dbc94a0fb81771a38733c0e8f2ea8c4fa6934dc1 ]

There are 2 ways to create IPoIB PKEY child interfaces:
1) Writing a PKEY to /sys/class/net/<ib parent interface>/create_child.
2) Using netlink with iproute.

While with sysfs the child interface has the same number of tx and
rx queues as the parent, with netlink there will always be 1 tx
and 1 rx queue for the child interface. That's because the
get_num_tx/rx_queues() netlink ops are missing and the default value
of 1 is taken for the number of queues (in rtnl_create_link()).

This change adds the get_num_tx/rx_queues() ops which allows for
interfaces with multiple queues to be created over netlink. This
constant only represents the max number of tx and rx queues on that
net device.

Fixes: 9baa0b0364 ("IB/ipoib: Add rtnl_link_ops support")
Signed-off-by: Dragos Tatulea <dtatulea@nvidia.com>
Link: https://lore.kernel.org/r/f4a42c8aa43c02d5ae5559a60c3e5e0f18c82531.1670485816.git.leonro@nvidia.com
Signed-off-by: Leon Romanovsky <leon@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2023-01-14 10:15:54 +01:00
..
core RDMA/nldev: Fix failure to send large messages 2023-01-14 10:15:52 +01:00
hw RDMA/hns: Fix page size cap from firmware 2023-01-14 10:15:53 +01:00
sw RDMA/rxe: Fix NULL-ptr-deref in rxe_qp_do_cleanup() when socket create failed 2023-01-14 10:15:50 +01:00
ulp IB/IPoIB: Fix queue count inconsistency for PKEY child interfaces 2023-01-14 10:15:54 +01:00
Kconfig RMDA/sw: Don't allow drivers using dma_virt_ops on highmem configs 2020-11-12 13:27:41 -04:00
Makefile treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00