intel-iommu: Fix oops in device_to_iommu() when devices not found.
authorDavid Woodhouse <David.Woodhouse@intel.com>
Mon, 6 Apr 2009 20:30:01 +0000 (13:30 -0700)
committerDavid Woodhouse <David.Woodhouse@intel.com>
Mon, 6 Apr 2009 20:30:01 +0000 (13:30 -0700)
commit4958c5dc7bcb2e42d985cd26aeafd8a7eca9ab1e
tree7bad2dac396fef6cca7f72132078a30e912b2589
parent276dbf997043cbf38f0087624e0f9c51742c8885
intel-iommu: Fix oops in device_to_iommu() when devices not found.

It's possible for a device in the drhd->devices[] array to be NULL if
it wasn't found at boot time, which means we have to check for that
case.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
drivers/pci/intel-iommu.c