diff options
| author | Nicolas Iooss <nicolas.iooss_linux@m4x.org> | 2016-06-26 04:33:29 -0400 |
|---|---|---|
| committer | Joerg Roedel <jroedel@suse.de> | 2016-06-27 07:24:46 -0400 |
| commit | 6082ee72e9d89e80a664418be06f47d728243e85 (patch) | |
| tree | fe245873dda4fc4cbe8f8439c3b3fb7300d80d39 /drivers | |
| parent | 3bd4f9112f87a9c65fe6e817272806167f0bc9ed (diff) | |
iommu/amd: Initialize devid variable before using it
Commit 2a0cb4e2d423 ("iommu/amd: Add new map for storing IVHD dev entry
type HID") added a call to DUMP_printk in init_iommu_from_acpi() which
used the value of devid before this variable was initialized.
Fixes: 2a0cb4e2d423 ('iommu/amd: Add new map for storing IVHD dev entry type HID')
Signed-off-by: Nicolas Iooss <nicolas.iooss_linux@m4x.org>
Signed-off-by: Joerg Roedel <jroedel@suse.de>
Diffstat (limited to 'drivers')
| -rw-r--r-- | drivers/iommu/amd_iommu_init.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/iommu/amd_iommu_init.c b/drivers/iommu/amd_iommu_init.c index 9e0034196e10..d091defc3426 100644 --- a/drivers/iommu/amd_iommu_init.c +++ b/drivers/iommu/amd_iommu_init.c | |||
| @@ -1107,13 +1107,13 @@ static int __init init_iommu_from_acpi(struct amd_iommu *iommu, | |||
| 1107 | break; | 1107 | break; |
| 1108 | } | 1108 | } |
| 1109 | 1109 | ||
| 1110 | devid = e->devid; | ||
| 1110 | DUMP_printk(" DEV_ACPI_HID(%s[%s])\t\tdevid: %02x:%02x.%x\n", | 1111 | DUMP_printk(" DEV_ACPI_HID(%s[%s])\t\tdevid: %02x:%02x.%x\n", |
| 1111 | hid, uid, | 1112 | hid, uid, |
| 1112 | PCI_BUS_NUM(devid), | 1113 | PCI_BUS_NUM(devid), |
| 1113 | PCI_SLOT(devid), | 1114 | PCI_SLOT(devid), |
| 1114 | PCI_FUNC(devid)); | 1115 | PCI_FUNC(devid)); |
| 1115 | 1116 | ||
| 1116 | devid = e->devid; | ||
| 1117 | flags = e->flags; | 1117 | flags = e->flags; |
| 1118 | 1118 | ||
| 1119 | ret = add_acpi_hid_device(hid, uid, &devid, false); | 1119 | ret = add_acpi_hid_device(hid, uid, &devid, false); |
