]> git.karo-electronics.de Git - karo-tx-linux.git/commit
amd_iommu: fix nasty bug that caused ILLEGAL_DEVICE_TABLE_ENTRY errors
authorAndreas Herrmann <andreas.herrmann3@amd.com>
Thu, 23 Oct 2008 17:35:28 +0000 (17:35 +0000)
committerGreg Kroah-Hartman <gregkh@suse.de>
Sat, 25 Oct 2008 21:32:40 +0000 (14:32 -0700)
commit5880100d91db1337c6604bf704c08c3c3dd4bf13
tree6c410722363a44699cecb2344ba0a21a2c880be4
parent1ea93b4aadc022277ddf92cf2aaa9ab00ca9a9b1
amd_iommu: fix nasty bug that caused ILLEGAL_DEVICE_TABLE_ENTRY errors

commit f609891f428e1c20e270e7c350daf8c93cc459d7 upstream

We are on 64-bit so better use u64 instead of u32 to deal with
addresses:

static void __init iommu_set_device_table(struct amd_iommu *iommu)
{
        u64 entry;
  ...
        entry = virt_to_phys(amd_iommu_dev_table);
  ...

(I am wondering why gcc 4.2.x did not warn about the assignment
between u32 and unsigned long.)

Cc: iommu@lists.linux-foundation.org
Signed-off-by: Andreas Herrmann <andreas.herrmann3@amd.com>
Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
arch/x86/kernel/amd_iommu_init.c