hc
2024-02-20 102a0743326a03cd1a1202ceda21e175b7d3575c
kernel/drivers/irqchip/irq-tegra.c
....@@ -1,3 +1,4 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * Driver code for Tegra's Legacy Interrupt Controller
34 *
....@@ -10,16 +11,6 @@
1011 * Colin Cross <ccross@android.com>
1112 *
1213 * Copyright (C) 2010,2013, NVIDIA Corporation
13
- *
14
- * This software is licensed under the terms of the GNU General Public
15
- * License version 2, as published by the Free Software Foundation, and
16
- * may be copied, distributed, and modified under those terms.
17
- *
18
- * This program is distributed in the hope that it will be useful,
19
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
20
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21
- * GNU General Public License for more details.
22
- *
2314 */
2415
2516 #include <linux/io.h>
....@@ -157,10 +148,10 @@
157148 lic->cop_iep[i] = readl_relaxed(ictlr + ICTLR_COP_IEP_CLASS);
158149
159150 /* Disable COP interrupts */
160
- writel_relaxed(~0ul, ictlr + ICTLR_COP_IER_CLR);
151
+ writel_relaxed(GENMASK(31, 0), ictlr + ICTLR_COP_IER_CLR);
161152
162153 /* Disable CPU interrupts */
163
- writel_relaxed(~0ul, ictlr + ICTLR_CPU_IER_CLR);
154
+ writel_relaxed(GENMASK(31, 0), ictlr + ICTLR_CPU_IER_CLR);
164155
165156 /* Enable the wakeup sources of ictlr */
166157 writel_relaxed(lic->ictlr_wake_mask[i], ictlr + ICTLR_CPU_IER_SET);
....@@ -181,12 +172,12 @@
181172
182173 writel_relaxed(lic->cpu_iep[i],
183174 ictlr + ICTLR_CPU_IEP_CLASS);
184
- writel_relaxed(~0ul, ictlr + ICTLR_CPU_IER_CLR);
175
+ writel_relaxed(GENMASK(31, 0), ictlr + ICTLR_CPU_IER_CLR);
185176 writel_relaxed(lic->cpu_ier[i],
186177 ictlr + ICTLR_CPU_IER_SET);
187178 writel_relaxed(lic->cop_iep[i],
188179 ictlr + ICTLR_COP_IEP_CLASS);
189
- writel_relaxed(~0ul, ictlr + ICTLR_COP_IER_CLR);
180
+ writel_relaxed(GENMASK(31, 0), ictlr + ICTLR_COP_IER_CLR);
190181 writel_relaxed(lic->cop_ier[i],
191182 ictlr + ICTLR_COP_IER_SET);
192183 }
....@@ -321,7 +312,7 @@
321312 lic->base[i] = base;
322313
323314 /* Disable all interrupts */
324
- writel_relaxed(~0UL, base + ICTLR_CPU_IER_CLR);
315
+ writel_relaxed(GENMASK(31, 0), base + ICTLR_CPU_IER_CLR);
325316 /* All interrupts target IRQ */
326317 writel_relaxed(0, base + ICTLR_CPU_IEP_CLASS);
327318