kernel-ark/drivers/hv
Vitaly Kuznetsov c0bb03924f Drivers: hv: vmbus: Raise retry/wait limits in vmbus_post_msg()
DoS protection conditions were altered in WS2016 and now it's easy to get
-EAGAIN returned from vmbus_post_msg() (e.g. when we try changing MTU on a
netvsc device in a loop). All vmbus_post_msg() callers don't retry the
operation and we usually end up with a non-functional device or crash.

While host's DoS protection conditions are unknown to me my tests show that
it can take up to 10 seconds before the message is sent so doing udelay()
is not an option, we really need to sleep. Almost all vmbus_post_msg()
callers are ready to sleep but there is one special case:
vmbus_initiate_unload() which can be called from interrupt/NMI context and
we can't sleep there. I'm also not sure about the lonely
vmbus_send_tl_connect_request() which has no in-tree users but its external
users are most likely waiting for the host to reply so sleeping there is
also appropriate.

Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-01-10 21:46:40 +01:00
..
channel_mgmt.c Drivers: hv: vmbus: Raise retry/wait limits in vmbus_post_msg() 2017-01-10 21:46:40 +01:00
channel.c Drivers: hv: vmbus: Raise retry/wait limits in vmbus_post_msg() 2017-01-10 21:46:40 +01:00
connection.c Drivers: hv: vmbus: Raise retry/wait limits in vmbus_post_msg() 2017-01-10 21:46:40 +01:00
hv_balloon.c Drivers: hv: balloon: Fix info request to show max page count 2016-11-07 10:01:17 +01:00
hv_fcopy.c Drivers: hv: utils: fix a race on userspace daemons registration 2016-08-31 13:05:41 +02:00
hv_kvp.c Drivers: hv: utils: fix a race on userspace daemons registration 2016-08-31 13:05:41 +02:00
hv_snapshot.c Drivers: hv: vss: Operation timeouts should match host expectation 2016-11-07 10:01:17 +01:00
hv_util.c Drivers: hv: utils: Fix the mapping between host version and protocol to use 2016-11-07 10:01:17 +01:00
hv_utils_transport.c Drivers: hv: utils: fix a race on userspace daemons registration 2016-08-31 13:05:41 +02:00
hv_utils_transport.h Drivers: hv: utils: fix a race on userspace daemons registration 2016-08-31 13:05:41 +02:00
hv.c clocksource: Use a plain u64 instead of cycle_t 2016-12-25 11:04:12 +01:00
hyperv_vmbus.h Drivers: hv: vmbus: Raise retry/wait limits in vmbus_post_msg() 2017-01-10 21:46:40 +01:00
Kconfig
Makefile Drivers: hv: util: introduce hv_utils_transport abstraction 2015-05-24 12:17:41 -07:00
ring_buffer.c Drivers: hv: vmbus: On the read path cleanup the logic to interrupt the host 2016-11-07 10:01:18 +01:00
vmbus_drv.c vmbus: add support for dynamic device id's 2016-12-06 11:52:49 +01:00