lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20240604050940.859909-5-mhklinux@outlook.com>
Date: Mon,  3 Jun 2024 22:09:32 -0700
From: mhkelley58@...il.com
To: kys@...rosoft.com,
	haiyangz@...rosoft.com,
	wei.liu@...nel.org,
	decui@...rosoft.com,
	tglx@...utronix.de,
	mingo@...hat.com,
	bp@...en8.de,
	dave.hansen@...ux.intel.com,
	x86@...nel.org,
	hpa@...or.com,
	lpieralisi@...nel.org,
	kw@...ux.com,
	robh@...nel.org,
	bhelgaas@...gle.com,
	James.Bottomley@...senPartnership.com,
	martin.petersen@...cle.com,
	arnd@...db.de,
	linux-hyperv@...r.kernel.org,
	linux-kernel@...r.kernel.org,
	linux-pci@...r.kernel.org,
	linux-scsi@...r.kernel.org,
	linux-arch@...r.kernel.org
Cc: maz@...nel.org,
	den@...inux.co.jp,
	jgowans@...zon.com,
	dawei.li@...ngroup.cn
Subject: [RFC 04/12] PCI: hv: Annotate the VMBus channel IRQ name

From: Michael Kelley <mhklinux@...look.com>

In preparation for assigning Linux IRQs to VMBus channels, annotate
the IRQ name in the single VMBus channel used for setup and teardown
of a virtual PCI device in a Hyper-V guest. The annotation adds the
16-bit PCI domain ID that the Hyper-V vPCI driver assigns to the
virtual PCI bus for the device.

Signed-off-by: Michael Kelley <mhklinux@...look.com>
---
 drivers/pci/controller/pci-hyperv.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/pci/controller/pci-hyperv.c b/drivers/pci/controller/pci-hyperv.c
index 5992280e8110..4f70cddb61dc 100644
--- a/drivers/pci/controller/pci-hyperv.c
+++ b/drivers/pci/controller/pci-hyperv.c
@@ -3705,6 +3705,9 @@ static int hv_pci_probe(struct hv_device *hdev,
 	hdev->channel->request_addr_callback = vmbus_request_addr;
 	hdev->channel->rqstor_size = HV_PCI_RQSTOR_SIZE;
 
+	snprintf(hdev->channel->irq_name, VMBUS_CHAN_IRQ_NAME_MAX,
+				"vpci:%04x", dom);
+
 	ret = vmbus_open(hdev->channel, pci_ring_size, pci_ring_size, NULL, 0,
 			 hv_pci_onchannelcallback, hbus);
 	if (ret)
@@ -4018,6 +4021,8 @@ static int hv_pci_resume(struct hv_device *hdev)
 	hdev->channel->next_request_id_callback = vmbus_next_request_id;
 	hdev->channel->request_addr_callback = vmbus_request_addr;
 	hdev->channel->rqstor_size = HV_PCI_RQSTOR_SIZE;
+	snprintf(hdev->channel->irq_name, VMBUS_CHAN_IRQ_NAME_MAX,
+				"vpci:%04x", hbus->bridge->domain_nr);
 
 	ret = vmbus_open(hdev->channel, pci_ring_size, pci_ring_size, NULL, 0,
 			 hv_pci_onchannelcallback, hbus);
-- 
2.25.1


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ