* [PATCH] iommu-helper: segment boundary limit should be a power of 2
@ 2008-02-16 9:09 FUJITA Tomonori
0 siblings, 0 replies; only message in thread
From: FUJITA Tomonori @ 2008-02-16 9:09 UTC (permalink / raw)
To: linux-kernel; +Cc: fujita.tomonori
The segment boundary limit should be a power of 2 so let's make it
clear.
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
---
lib/iommu-helper.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/lib/iommu-helper.c b/lib/iommu-helper.c
index 495575a..de0eced 100644
--- a/lib/iommu-helper.c
+++ b/lib/iommu-helper.c
@@ -54,6 +54,8 @@ unsigned long iommu_area_alloc(unsigned long *map, unsigned long size,
unsigned long align_mask)
{
unsigned long index;
+
+ BUG_ON(!is_power_of_2(boundary_size));
again:
index = find_next_zero_area(map, size, start, nr, align_mask);
if (index != -1) {
--
1.5.3.7
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2008-02-16 9:09 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-02-16 9:09 [PATCH] iommu-helper: segment boundary limit should be a power of 2 FUJITA Tomonori
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.