From: Eric Sesterhenn Date: Sun, 24 Sep 2006 22:56:53 +0000 (+0200) Subject: pciehp: Remove unnecessary check in pciehp_ctrl.c X-Git-Tag: v2.6.19-rc3~125^2~18 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9ef9977cabc1b2c1718ef6eb883caec8dcb80b4c;p=profile%2Fivi%2Fkernel-adaptation-intel-automotive.git 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 Signed-off-by: Greg Kroah-Hartman --- 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;