Skip to content

Commit

Permalink
x86/amd-iommu: Remove double NULL check in check_device
Browse files Browse the repository at this point in the history
dev was tested just above, so drop the second test.

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
  • Loading branch information
Julia Lawall authored and Joerg Roedel committed Mar 1, 2010
1 parent 60b341b commit 339d326
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/x86/kernel/amd_iommu.c
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ static bool check_device(struct device *dev)
return false;

/* No device or no PCI device */
if (!dev || dev->bus != &pci_bus_type)
if (dev->bus != &pci_bus_type)
return false;

devid = get_device_id(dev);
Expand Down

0 comments on commit 339d326

Please sign in to comment.