swiotlb=force fix

From: Muli Ben-Yehuda
Date: Thu Jul 27 2006 - 06:13:31 EST

Hi Andi,

I was looking at your swiotlb=force fix at

In general I agree with the patch (and thanks for fixing it).

> - if (!iommu_detected && !no_iommu &&
> - (end_pfn > MAX_DMA32_PFN || force_iommu))
> + if (!iommu_detected && !no_iommu && end_pfn > MAX_DMA32_PFN)
> swiotlb = 1;

what is the expected outcome if the user specifies 'iommu=force' with
no HW IOMMU in the machine and swiotlb compiled in? we thought the
path of least surprise is to enable swiotlb unconditionally in this
case. You removed the check for force_iommu here so now this set of
command line options will *not* turn on swiotlb unless there's more
than 4G in the machine, which can be surprising.

> +extern int swiotlb_force;
> +
> extern int swiotlb;
> #else
> #define swiotlb 0
> #endif

Any reason not to move this into the CONFIG_SWIOTLB bit the same way
'extern int swiotlb' is declared?

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