From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A840742903D; Thu, 16 Jul 2026 13:49:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784209751; cv=none; b=mMKXoJwwZRsgb9ELYnTudr7eW+x6iFNExCrThNv14iAE4OoC80OcVNpMhXzBLmsy54O23B7Qas0utfLifRAkgqnJb0Tv04VfDaqzZxlm8RDJcSQ651Sz1CjaECSV+++xEbE1VkP7yBvF4OaCWOcr3W3pr/pPBOY38f+A0XiZWss= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784209751; c=relaxed/simple; bh=KzDAbAhR8khZGViI7KHA0BcSdU9hT1g6uoVUVzvPm4U=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=e4PCkQ6sA99mfYOfA8OjuVK+ydlbkJQv2kMepa4MZvN4UNbn94D3VNnMNvRMYggB3bXlazSLdZKSQem3NtRS3s0LZW1Ek+1+8qw4HSSC212scQ3WwAFPc18IKolkXdzdZzzMnj01uDuEiU0rfNXddrdLJAw8eqgozl/U3OlPJ50= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=e2HnS8iY; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="e2HnS8iY" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 59F461F00A3A; Thu, 16 Jul 2026 13:49:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1784209746; bh=ZxVF11+tSE17z2SVE5SH4bMPAbbs3OYR0rcPF57DXxE=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=e2HnS8iY7iGUPzPojc9kABdcQLMVQqDqfmopvOyEm/gQU60APd9B7qabQMd3Bekzn k8M/HcZeGNg65p2leNVhBKn+JWqUf/k6UAw4HldovXH2a62b/GGeVXFIZziiGfW/Ch 1JK0GfaJtiZ0LHjNon/4oA21Snm+9eZkN7kWJcgY= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, stable , Thinh Nguyen , Ben Dooks Subject: [PATCH 7.1 301/518] usb: dwc3: fix dwc3_readl() and dwc3_writel() calls in dwc3_ulpi_setup() Date: Thu, 16 Jul 2026 15:29:29 +0200 Message-ID: <20260716133054.404082812@linuxfoundation.org> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260716133047.772246337@linuxfoundation.org> References: <20260716133047.772246337@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 7.1-stable review patch. If anyone has any objections, please let me know. ------------------ From: Ben Dooks commit e0f844d9d74200d311c6438a0f04270834ba5365 upstream. The dwc3_ulpi_setup() calls the register read and write calls with dwc3->regs when both these calls take the dwc3 structure directly. Chnage these two calls to fix the following sparse warning, and possibly a nasty bug in the dwc3_ulpi_setup() code: drivers/usb/dwc3/core.c:796:45: warning: incorrect type in argument 1 (different address spaces) drivers/usb/dwc3/core.c:796:45: expected struct dwc3 *dwc drivers/usb/dwc3/core.c:796:45: got void [noderef] __iomem *regs drivers/usb/dwc3/core.c:798:40: warning: incorrect type in argument 1 (different address spaces) drivers/usb/dwc3/core.c:798:40: expected struct dwc3 *dwc drivers/usb/dwc3/core.c:798:40: got void [noderef] __iomem *regs Cc: stable Fixes: 9accc68b1cf0 ("usb: dwc3: Add dwc pointer to dwc3_readl/writel") Acked-by: Thinh Nguyen Signed-off-by: Ben Dooks Link: https://patch.msgid.link/20260703162033.2847599-1-ben.dooks@codethink.co.uk Signed-off-by: Greg Kroah-Hartman --- drivers/usb/dwc3/core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/drivers/usb/dwc3/core.c +++ b/drivers/usb/dwc3/core.c @@ -793,9 +793,9 @@ static void dwc3_ulpi_setup(struct dwc3 if (dwc->enable_usb2_transceiver_delay) { for (index = 0; index < dwc->num_usb2_ports; index++) { - reg = dwc3_readl(dwc->regs, DWC3_GUSB2PHYCFG(index)); + reg = dwc3_readl(dwc, DWC3_GUSB2PHYCFG(index)); reg |= DWC3_GUSB2PHYCFG_XCVRDLY; - dwc3_writel(dwc->regs, DWC3_GUSB2PHYCFG(index), reg); + dwc3_writel(dwc, DWC3_GUSB2PHYCFG(index), reg); } } }