summaryrefslogtreecommitdiff
path: root/drivers/pci/hotplug
diff options
context:
space:
mode:
authorEric Sesterhenn <snakebyte@gmx.de>2006-09-24 22:56:53 (GMT)
committerGreg Kroah-Hartman <gregkh@suse.de>2006-10-18 18:36:10 (GMT)
commit9ef9977cabc1b2c1718ef6eb883caec8dcb80b4c (patch)
tree54ae4e1c2c42603da00ac8059b94bb6b4e8e38ee /drivers/pci/hotplug
parentdd5619cb4407e830a8921a93c949be37c81105b5 (diff)
downloadlinux-9ef9977cabc1b2c1718ef6eb883caec8dcb80b4c.tar.xz
pciehp: Remove unnecessary check in pciehp_ctrl.c
this was spotted by coverity (cid #819). We dereference p_slot earlier in the function, and i found no way it could become NULL anywhere. Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/pci/hotplug')
-rw-r--r--drivers/pci/hotplug/pciehp_ctrl.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/pci/hotplug/pciehp_ctrl.c b/drivers/pci/hotplug/pciehp_ctrl.c
index c206a3d..372c63e 100644
--- a/drivers/pci/hotplug/pciehp_ctrl.c
+++ b/drivers/pci/hotplug/pciehp_ctrl.c
@@ -797,8 +797,7 @@ int pciehp_enable_slot(struct slot *p_slot)
p_slot->hpc_ops->get_latch_status(p_slot, &getstatus);
}
- if (p_slot)
- update_slot_info(p_slot);
+ update_slot_info(p_slot);
mutex_unlock(&p_slot->ctrl->crit_sect);
return rc;