bus/vmbus: fix resource leak on error
authorStephen Hemminger <stephen@networkplumber.org>
Wed, 17 Apr 2019 18:45:06 +0000 (11:45 -0700)
committerThomas Monjalon <thomas@monjalon.net>
Mon, 22 Apr 2019 12:39:17 +0000 (14:39 +0200)
commit26ed007067e86bb3d587c048d130cd13bee6b07a
tree2b5be8d35f0d8c42ff917bf7e81cdb191d590a50
parent2aa0db405fb6eafa6ece76e3c5221dc142e872ff
bus/vmbus: fix resource leak on error

If secondary process attempt to mmap the resource resulted in
the wrong address, then it would leave behind the bad mmap.

Coverity issue: 337675, 337664
Fixes: 2a28a502c607 ("bus/vmbus: map ring in secondary process")

Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com>
drivers/bus/vmbus/linux/vmbus_uio.c
drivers/bus/vmbus/vmbus_common_uio.c