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: <20241216175632.4175-18-ilpo.jarvinen@linux.intel.com>
Date: Mon, 16 Dec 2024 19:56:24 +0200
From: Ilpo Järvinen <ilpo.jarvinen@...ux.intel.com>
To: Bjorn Helgaas <bhelgaas@...gle.com>,
	linux-pci@...r.kernel.org,
	Michał Winiarski <michal.winiarski@...el.com>,
	Igor Mammedov <imammedo@...hat.com>,
	linux-kernel@...r.kernel.org
Cc: Mika Westerberg <mika.westerberg@...ux.intel.com>,
	Ilpo Järvinen <ilpo.jarvinen@...ux.intel.com>,
	Yinghai Lu <yinghai@...nel.org>
Subject: [PATCH 17/25] PCI: Remove wrong comment from pci_reassign_resource()

The commit a4ac9fea016f ("PCI : Calculate right add_size") removed
including min_align into new_size in pci_reassign_resource() which is
correct thing to do. However, it also added a snakeoil comment that the
resource would already be aligned with min_align which is incorrect.

A resource that is assigned earlier is aligned with the old alignment,
NOT with the new requested alignment (min_align) until later deep
within the reassignment callchain. Thus, remove the incorrect comment.

Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@...ux.intel.com>
Cc: Yinghai Lu <yinghai@...nel.org>
---
 drivers/pci/setup-res.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/pci/setup-res.c b/drivers/pci/setup-res.c
index 79c7ef349856..a862b5d769dc 100644
--- a/drivers/pci/setup-res.c
+++ b/drivers/pci/setup-res.c
@@ -387,7 +387,6 @@ int pci_reassign_resource(struct pci_dev *dev, int resno,
 		return -EINVAL;
 	}
 
-	/* already aligned with min_align */
 	new_size = resource_size(res) + addsize;
 	ret = _pci_assign_resource(dev, resno, new_size, min_align);
 	if (ret) {
-- 
2.39.5


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ