From: Jingoo Han Date: Thu, 23 Feb 2012 08:26:33 +0000 (+0900) Subject: USB: ohci-exynos: replace hcd->state with ohci->rh_state X-Git-Tag: MMI-PSA29.97-13-9~17266^2~22^2~97 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=2b4ffe31a2380de7c893e345659b0730d6dc62d3;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git USB: ohci-exynos: replace hcd->state with ohci->rh_state This patch removes uses of hcd->state and replaces hcd->state with ohci->rh_state field. Signed-off-by: Jingoo Han Acked-by: Alan Stern Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/usb/host/ohci-exynos.c b/drivers/usb/host/ohci-exynos.c index 55aa35aa3d7b..37bb20ebb6fc 100644 --- a/drivers/usb/host/ohci-exynos.c +++ b/drivers/usb/host/ohci-exynos.c @@ -212,12 +212,10 @@ static int exynos_ohci_suspend(struct device *dev) * mark HW unaccessible, bail out if RH has been resumed. Use * the spinlock to properly synchronize with possible pending * RH suspend or resume activity. - * - * This is still racy as hcd->state is manipulated outside of - * any locks =P But that will be a different fix. */ spin_lock_irqsave(&ohci->lock, flags); - if (hcd->state != HC_STATE_SUSPENDED && hcd->state != HC_STATE_HALT) { + if (ohci->rh_state != OHCI_RH_SUSPENDED && + ohci->rh_state != OHCI_RH_HALTED) { rc = -EINVAL; goto fail; }