hv_netvsc: Use HV_HYP_PAGE_SIZE for Hyper-V communication
authorBoqun Feng <boqun.feng@gmail.com>
Wed, 16 Sep 2020 03:48:13 +0000 (11:48 +0800)
committerWei Liu <wei.liu@kernel.org>
Mon, 28 Sep 2020 08:55:13 +0000 (08:55 +0000)
commit11d8620e0867cb21313aa66ff6ce0172e28f68ff
treeade19dd759c15c042e1eea5c72cdeea9710c71b0
parent106dee08408118c5b50387817e74419436e8b651
hv_netvsc: Use HV_HYP_PAGE_SIZE for Hyper-V communication

When communicating with Hyper-V, HV_HYP_PAGE_SIZE should be used since
that's the page size used by Hyper-V and Hyper-V expects all
page-related data using the unit of HY_HYP_PAGE_SIZE, for example, the
"pfn" in hv_page_buffer is actually the HV_HYP_PAGE (i.e. the Hyper-V
page) number.

In order to support guest whose page size is not 4k, we need to make
hv_netvsc always use HV_HYP_PAGE_SIZE for Hyper-V communication.

Signed-off-by: Boqun Feng <boqun.feng@gmail.com>
Reviewed-by: Michael Kelley <mikelley@microsoft.com>
Link: https://lore.kernel.org/r/20200916034817.30282-8-boqun.feng@gmail.com
Signed-off-by: Wei Liu <wei.liu@kernel.org>
drivers/net/hyperv/netvsc.c
drivers/net/hyperv/netvsc_drv.c
drivers/net/hyperv/rndis_filter.c