]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
hyperv/vmbus: Fix the multi-channel revoking on vmbus side.
authorSepherosa Ziehau <sephe@FreeBSD.org>
Thu, 24 Nov 2016 06:01:29 +0000 (06:01 +0000)
committerSepherosa Ziehau <sephe@FreeBSD.org>
Thu, 24 Nov 2016 06:01:29 +0000 (06:01 +0000)
commit91955558f58de990bbfb7266c1f4e750eb0ef2b4
treeb9dba04462f702a1b3b2824d5dcc28b36c06b78c
parentea596849775464b3f1daf698508227d4af0fb0c6
hyperv/vmbus: Fix the multi-channel revoking on vmbus side.

- Reference count the sub-channel when channel offer message is
  processed, so that immediate rescind message on the same channel
  will not race sub-channel open on driver side.
- Drop the above reference when sub-channel is closed, this closely
  mimics the hypervisor's reaction when primary channel is closed
  on the VM side.  No drivers use sub-channel after primary channel
  is closed.

MFC after: 1 week
Sponsored by: Microsoft
Differential Revision: https://reviews.freebsd.org/D8546
sys/dev/hyperv/vmbus/vmbus_chan.c
sys/dev/hyperv/vmbus/vmbus_chanvar.h