From: Sasha Levin <sashal@kernel.org>
To: linux-kernel@vger.kernel.org, stable@vger.kernel.org
Cc: Wayne Chang <waynec@nvidia.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Sasha Levin <sashal@kernel.org>,
balbi@kernel.org, thierry.reding@gmail.com, jonathanh@nvidia.com,
chunfeng.yun@mediatek.com, zhangqilong3@huawei.com,
yangyingliang@huawei.com, jakobkoschel@gmail.com,
rikard.falkeborn@gmail.com, linux-usb@vger.kernel.org,
linux-tegra@vger.kernel.org
Subject: [PATCH AUTOSEL 5.17 014/149] usb: gadget: tegra-xudc: Do not program SPARAM
Date: Fri, 1 Apr 2022 10:23:21 -0400 [thread overview]
Message-ID: <20220401142536.1948161-14-sashal@kernel.org> (raw)
In-Reply-To: <20220401142536.1948161-1-sashal@kernel.org>
From: Wayne Chang <waynec@nvidia.com>
[ Upstream commit 62fb61580eb48fc890b7bc9fb5fd263367baeca8 ]
According to the Tegra Technical Reference Manual, SPARAM
is a read-only register and should not be programmed in
the driver.
The change removes the wrong SPARAM usage.
Signed-off-by: Wayne Chang <waynec@nvidia.com>
Link: https://lore.kernel.org/r/20220107090443.149021-1-waynec@nvidia.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
drivers/usb/gadget/udc/tegra-xudc.c | 8 --------
1 file changed, 8 deletions(-)
diff --git a/drivers/usb/gadget/udc/tegra-xudc.c b/drivers/usb/gadget/udc/tegra-xudc.c
index 43f1b0d461c1..716d9ab2d2ff 100644
--- a/drivers/usb/gadget/udc/tegra-xudc.c
+++ b/drivers/usb/gadget/udc/tegra-xudc.c
@@ -32,9 +32,6 @@
#include <linux/workqueue.h>
/* XUSB_DEV registers */
-#define SPARAM 0x000
-#define SPARAM_ERSTMAX_MASK GENMASK(20, 16)
-#define SPARAM_ERSTMAX(x) (((x) << 16) & SPARAM_ERSTMAX_MASK)
#define DB 0x004
#define DB_TARGET_MASK GENMASK(15, 8)
#define DB_TARGET(x) (((x) << 8) & DB_TARGET_MASK)
@@ -3295,11 +3292,6 @@ static void tegra_xudc_init_event_ring(struct tegra_xudc *xudc)
unsigned int i;
u32 val;
- val = xudc_readl(xudc, SPARAM);
- val &= ~(SPARAM_ERSTMAX_MASK);
- val |= SPARAM_ERSTMAX(XUDC_NR_EVENT_RINGS);
- xudc_writel(xudc, val, SPARAM);
-
for (i = 0; i < ARRAY_SIZE(xudc->event_ring); i++) {
memset(xudc->event_ring[i], 0, XUDC_EVENT_RING_SIZE *
sizeof(*xudc->event_ring[i]));
--
2.34.1
next parent reply other threads:[~2022-04-01 14:26 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20220401142536.1948161-1-sashal@kernel.org>
2022-04-01 14:23 ` Sasha Levin [this message]
2022-04-01 14:23 ` [PATCH AUTOSEL 5.17 015/149] usb: gadget: tegra-xudc: Fix control endpoint's definitions Sasha Levin
2022-04-01 14:23 ` [PATCH AUTOSEL 5.17 016/149] usb: cdnsp: fix cdnsp_decode_trb function to properly handle ret value Sasha Levin
2022-04-01 14:24 ` [PATCH AUTOSEL 5.17 058/149] usb: ehci: add pci device support for Aspeed platforms Sasha Levin
2022-04-01 14:24 ` [PATCH AUTOSEL 5.17 077/149] usb: dwc3: pci: Set the swnode from inside dwc3_pci_quirks() Sasha Levin
2022-04-01 14:25 ` [PATCH AUTOSEL 5.17 136/149] usb: dwc3: omap: fix "unbalanced disables for smps10_out1" on omap5evm Sasha Levin
2022-04-01 14:25 ` [PATCH AUTOSEL 5.17 137/149] xen/usb: harden xen_hcd against malicious backends Sasha Levin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220401142536.1948161-14-sashal@kernel.org \
--to=sashal@kernel.org \
--cc=balbi@kernel.org \
--cc=chunfeng.yun@mediatek.com \
--cc=gregkh@linuxfoundation.org \
--cc=jakobkoschel@gmail.com \
--cc=jonathanh@nvidia.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tegra@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=rikard.falkeborn@gmail.com \
--cc=stable@vger.kernel.org \
--cc=thierry.reding@gmail.com \
--cc=waynec@nvidia.com \
--cc=yangyingliang@huawei.com \
--cc=zhangqilong3@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).