patches for DPDK stable branches
 help / color / mirror / Atom feed
From: longli@linuxonhyperv.com
To: Stephen Hemminger <stephen@networkplumber.org>,
	Wei Hu <weh@microsoft.com>
Cc: dev@dpdk.org, Long Li <longli@microsoft.com>, stable@dpdk.org
Subject: [PATCH 2/4] bus/vmbus: Define Hyper-V page size
Date: Fri, 18 Apr 2025 12:32:48 -0700	[thread overview]
Message-ID: <1745004770-9795-3-git-send-email-longli@linuxonhyperv.com> (raw)
In-Reply-To: <1745004770-9795-1-git-send-email-longli@linuxonhyperv.com>

From: Long Li <longli@microsoft.com>

Hyper-V uses 4k page size, regardless of the system page size used. Define
Hyper-V page size for use in drivers.

Fixes: 831dba47bd ("bus/vmbus: add Hyper-V virtual bus support")
Cc: stable@dpdk.org
Signed-off-by: Long Li <longli@microsoft.com>
---
 drivers/bus/vmbus/bus_vmbus_driver.h | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/bus/vmbus/bus_vmbus_driver.h b/drivers/bus/vmbus/bus_vmbus_driver.h
index bc394208de..0a56275437 100644
--- a/drivers/bus/vmbus/bus_vmbus_driver.h
+++ b/drivers/bus/vmbus/bus_vmbus_driver.h
@@ -14,6 +14,10 @@
 extern "C" {
 #endif
 
+#define HYPERV_PAGE_SHIFT 12
+#define HYPERV_PAGE_SIZE (1 << HYPERV_PAGE_SHIFT)
+#define HYPERV_PAGE_MASK (HYPERV_PAGE_SIZE - 1)
+
 struct vmbus_channel;
 struct vmbus_mon_page;
 
-- 
2.34.1


  parent reply	other threads:[~2025-04-18 19:33 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1745004770-9795-1-git-send-email-longli@linuxonhyperv.com>
2025-04-18 19:32 ` [PATCH 1/4] bus/vmbus: Align ring buffer data region to system page boundary longli
2025-04-18 19:32 ` longli [this message]
2025-04-18 19:32 ` [PATCH 3/4] bus/vmbus: Use Hyper-V page size for mapping to UIO pages longli
2025-04-18 19:32 ` [PATCH 4/4] net/netvsc: Use Hyper-V page size for the driver longli

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1745004770-9795-3-git-send-email-longli@linuxonhyperv.com \
    --to=longli@linuxonhyperv.com \
    --cc=dev@dpdk.org \
    --cc=longli@microsoft.com \
    --cc=stable@dpdk.org \
    --cc=stephen@networkplumber.org \
    --cc=weh@microsoft.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).