]> www.infradead.org Git - users/dwmw2/linux.git/commit
Drivers: hv: vmbus: Remove the useless API vmbus_get_outgoing_channel()
authorDexuan Cui <decui@microsoft.com>
Mon, 26 Nov 2018 02:17:56 +0000 (02:17 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 31 Jan 2019 07:15:45 +0000 (08:15 +0100)
commite4266dff05a0803ab0ea3952866a8734e9905739
treeeb7114425138821376d2e86c672179396f4232f5
parenta79c57d1118dd19c5109be962f31e78edd07837f
Drivers: hv: vmbus: Remove the useless API vmbus_get_outgoing_channel()

[ Upstream commit 4d3c5c69191f98c7f7e699ff08d2fd96d7070ddb ]

Commit d86adf482b84 ("scsi: storvsc: Enable multi-queue support") removed
the usage of the API in Jan 2017, and the API is not used since then.

netvsc and storvsc have their own algorithms to determine the outgoing
channel, so this API is useless.

And the API is potentially unsafe, because it reads primary->num_sc without
any lock held. This can be risky considering the RESCIND-OFFER message.

Let's remove the API.

Cc: Long Li <longli@microsoft.com>
Cc: Stephen Hemminger <sthemmin@microsoft.com>
Cc: K. Y. Srinivasan <kys@microsoft.com>
Cc: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Dexuan Cui <decui@microsoft.com>
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Dexuan Cui <decui@microsoft.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/hv/channel.c
drivers/hv/channel_mgmt.c
include/linux/hyperv.h