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: <1242165051-6636-11-git-send-email-jeremy@goop.org>
Date:	Tue, 12 May 2009 14:50:51 -0700
From:	Jeremy Fitzhardinge <jeremy@...p.org>
To:	Ingo Molnar <mingo@...e.hu>
Cc:	the arch/x86 maintainers <x86@...nel.org>,
	Matthew Wilcox <willy@...ux.intel.com>,
	Joerg Roedel <joerg.roedel@....com>,
	FUJITA Tomonori <fujita.tomonori@....ntt.co.jp>,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	Xen-devel <xen-devel@...ts.xensource.com>,
	Jeremy Fitzhardinge <jeremy.fitzhardinge@...rix.com>
Subject: [PATCH 10/10] xen/swiotlb: define xen_wants_swiotlb when PCI_XEN is not enabled

From: Jeremy Fitzhardinge <jeremy.fitzhardinge@...rix.com>

If CONFIG_PCI is disabled, CONFIG_SWIOTLB can still be enabled on x86-64,
which calls xen_wants_swiotlb().  Define a stub version when CONFIG_PCI
(and, implicitly, CONFIG_PCI_XEN) is not enabled.

[ Impact: compile fix with !CONFIG_PCI ]
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@...rix.com>
---
 include/xen/swiotlb.h |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/include/xen/swiotlb.h b/include/xen/swiotlb.h
index f35183b..75d1da1 100644
--- a/include/xen/swiotlb.h
+++ b/include/xen/swiotlb.h
@@ -5,6 +5,14 @@ extern void xen_swiotlb_fixup(void *buf, size_t size, unsigned long nslabs);
 extern phys_addr_t xen_bus_to_phys(dma_addr_t daddr);
 extern dma_addr_t xen_phys_to_bus(phys_addr_t paddr);
 extern int xen_range_needs_mapping(phys_addr_t phys, size_t size);
+
+#ifdef CONFIG_PCI_XEN
 extern int xen_wants_swiotlb(void);
+#else
+static inline int xen_wants_swiotlb(void)
+{
+	return 0;
+}
+#endif
 
 #endif /* _XEN_SWIOTLB_H */
-- 
1.6.0.6

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ