Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp4853176pxj; Wed, 9 Jun 2021 03:35:27 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyeUveVMZL0BgDOhU0ppMEQvl4yppbkpAwoH2pEMWoeIPdc+pla4pEwDNGcO5+CLnzVVz1T X-Received: by 2002:a17:906:53c9:: with SMTP id p9mr22151140ejo.419.1623234926837; Wed, 09 Jun 2021 03:35:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623234926; cv=none; d=google.com; s=arc-20160816; b=zzgp//437lsCrtUZlQ+LlyzbVWLH6ZMl7s+kEaPJfuISHxI7OJ2ufJqb30c5ao3lLY zuQRZn8J9rJ1Pyc02KWHJ1gsnkrvb4MkQ77BXdrjPyqE/4ANAxy/HFywJ5l9kxNEea7w sjaQ8rS4z4TxkzZRHg6Uhcr0V/39BW3fJWijaI+ek0NA9RGk3aB5G+bsMHBiAemlTbO8 4Y9fuAPcJiewKyHqm33X3yfsjj154NSFzeNraneD78GY2qEtZewC90barJQJr6fA4JRL 7ICA9Rj4fzX77+WpmWHYtf1hQzkr8LEqrkZLDlNgEA9Occp2Zvv9/ZBrgzs3wTuLDTS8 IWKg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=W86uw21YfKPYdpRi+4gnnVMhnvJhlXIJ/vpymcHnmJE=; b=dpbJHTmSX68aWD/8lcbttD2rDK3O98fz9GL/47JJYnAUYZJVqJt20I+SOLPvIJmvx8 SnRmXUiU1zxQlCq1rrEvXWfM42YUgb2QLeUC/ZpyRUQEas+vis/dT83tR1t1LGn9crkr +oy1rveDuetHBVMPO86nuSRKmEiyfBgu0xSTS1Xy4Do/ksQbCpcDL8XLa3r7pDzG6bRv GnhCo0x3z7ZAxIx9xdxiqZmaOaCFyAMUuBIvSdKKfxidmWLYD5xaaYjFsTmOJglbFIbF qcTkbH4xaVG1duXf/2R1pKHkfOHRhOIHfjTcqCjhENnXRrjCLEts0JTEHAN+Bpi6gNHL 0cUQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=z5+ym2PT; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t1si2100845edf.285.2021.06.09.03.35.03; Wed, 09 Jun 2021 03:35:26 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=z5+ym2PT; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235712AbhFHTJA (ORCPT + 99 others); Tue, 8 Jun 2021 15:09:00 -0400 Received: from mail.kernel.org ([198.145.29.99]:35352 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237351AbhFHTAX (ORCPT ); Tue, 8 Jun 2021 15:00:23 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id C80DB6162F; Tue, 8 Jun 2021 18:43:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1623177811; bh=hWSw338vaib2nmKg/NfWfYy527GoRmuHGQh+8qKetFI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=z5+ym2PTYJzc037DxqXsgyfgC2xdzmjiCbP6t5zbI7IZzeAev7F3Gut7iOmReyGq/ QQ2p+4wg0xtHE/5IN08tcbwCVYnnnkpn4eI1HmrvqGT/nvj9NmH8DXmhkolbU6Y7Fo yGvUf83Ri4KKnVoLRHvosQwg9VN9gPTy21pCdU6E= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Phil Elwell Subject: [PATCH 5.10 107/137] usb: dwc2: Fix build in periphal-only mode Date: Tue, 8 Jun 2021 20:27:27 +0200 Message-Id: <20210608175946.004461939@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210608175942.377073879@linuxfoundation.org> References: <20210608175942.377073879@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Phil Elwell In branches to which 24d209dba5a3 ("usb: dwc2: Fix hibernation between host and device modes.") has been back-ported, the bus_suspended member of struct dwc2_hsotg is only present in builds that support host-mode. To avoid having to pull in several more non-Fix commits in order to get it to compile, wrap the usage of the member in a macro conditional. Fixes: 24d209dba5a3 ("usb: dwc2: Fix hibernation between host and device modes.") Signed-off-by: Phil Elwell Signed-off-by: Greg Kroah-Hartman --- drivers/usb/dwc2/core_intr.c | 4 ++++ 1 file changed, 4 insertions(+) --- a/drivers/usb/dwc2/core_intr.c +++ b/drivers/usb/dwc2/core_intr.c @@ -707,7 +707,11 @@ static inline void dwc_handle_gpwrdn_dis dwc2_writel(hsotg, gpwrdn_tmp, GPWRDN); hsotg->hibernated = 0; + +#if IS_ENABLED(CONFIG_USB_DWC2_HOST) || \ + IS_ENABLED(CONFIG_USB_DWC2_DUAL_ROLE) hsotg->bus_suspended = 0; +#endif if (gpwrdn & GPWRDN_IDSTS) { hsotg->op_state = OTG_STATE_B_PERIPHERAL;