Skip to content

Commit 4fc8d3f

Browse files
committed
Merge tag 'irq-urgent-2026-01-24' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull irq fixes from Ingo Molnar: - Fix spurious interrupts during resume in the renesas-rzv2h driver - Fix a 32+ bit physical memory truncation bug in the gic-v3-its driver * tag 'irq-urgent-2026-01-24' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: irqchip/gic-v3-its: Avoid truncating memory addresses irqchip/renesas-rzv2h: Prevent TINT spurious interrupt during resume
2 parents 4a51fe9 + 8d76a7d commit 4fc8d3f

2 files changed

Lines changed: 12 additions & 5 deletions

File tree

drivers/irqchip/irq-gic-v3-its.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -709,7 +709,7 @@ static struct its_collection *its_build_mapd_cmd(struct its_node *its,
709709
struct its_cmd_block *cmd,
710710
struct its_cmd_desc *desc)
711711
{
712-
unsigned long itt_addr;
712+
phys_addr_t itt_addr;
713713
u8 size = ilog2(desc->its_mapd_cmd.dev->nr_ites);
714714

715715
itt_addr = virt_to_phys(desc->its_mapd_cmd.dev->itt);
@@ -879,7 +879,7 @@ static struct its_vpe *its_build_vmapp_cmd(struct its_node *its,
879879
struct its_cmd_desc *desc)
880880
{
881881
struct its_vpe *vpe = valid_vpe(its, desc->its_vmapp_cmd.vpe);
882-
unsigned long vpt_addr, vconf_addr;
882+
phys_addr_t vpt_addr, vconf_addr;
883883
u64 target;
884884
bool alloc;
885885

@@ -2477,10 +2477,10 @@ static int its_setup_baser(struct its_node *its, struct its_baser *baser,
24772477
baser->psz = psz;
24782478
tmp = indirect ? GITS_LVL1_ENTRY_SIZE : esz;
24792479

2480-
pr_info("ITS@%pa: allocated %d %s @%lx (%s, esz %d, psz %dK, shr %d)\n",
2480+
pr_info("ITS@%pa: allocated %d %s @%llx (%s, esz %d, psz %dK, shr %d)\n",
24812481
&its->phys_base, (int)(PAGE_ORDER_TO_SIZE(order) / (int)tmp),
24822482
its_base_type_string[type],
2483-
(unsigned long)virt_to_phys(base),
2483+
(u64)virt_to_phys(base),
24842484
indirect ? "indirect" : "flat", (int)esz,
24852485
psz / SZ_1K, (int)shr >> GITS_BASER_SHAREABILITY_SHIFT);
24862486

drivers/irqchip/irq-renesas-rzv2h.c

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -328,6 +328,7 @@ static int rzv2h_tint_set_type(struct irq_data *d, unsigned int type)
328328
u32 titsr, titsr_k, titsel_n, tien;
329329
struct rzv2h_icu_priv *priv;
330330
u32 tssr, tssr_k, tssel_n;
331+
u32 titsr_cur, tssr_cur;
331332
unsigned int hwirq;
332333
u32 tint, sense;
333334
int tint_nr;
@@ -376,12 +377,18 @@ static int rzv2h_tint_set_type(struct irq_data *d, unsigned int type)
376377
guard(raw_spinlock)(&priv->lock);
377378

378379
tssr = readl_relaxed(priv->base + priv->info->t_offs + ICU_TSSR(tssr_k));
380+
titsr = readl_relaxed(priv->base + priv->info->t_offs + ICU_TITSR(titsr_k));
381+
382+
tssr_cur = field_get(ICU_TSSR_TSSEL_MASK(tssel_n, priv->info->field_width), tssr);
383+
titsr_cur = field_get(ICU_TITSR_TITSEL_MASK(titsel_n), titsr);
384+
if (tssr_cur == tint && titsr_cur == sense)
385+
return 0;
386+
379387
tssr &= ~(ICU_TSSR_TSSEL_MASK(tssel_n, priv->info->field_width) | tien);
380388
tssr |= ICU_TSSR_TSSEL_PREP(tint, tssel_n, priv->info->field_width);
381389

382390
writel_relaxed(tssr, priv->base + priv->info->t_offs + ICU_TSSR(tssr_k));
383391

384-
titsr = readl_relaxed(priv->base + priv->info->t_offs + ICU_TITSR(titsr_k));
385392
titsr &= ~ICU_TITSR_TITSEL_MASK(titsel_n);
386393
titsr |= ICU_TITSR_TITSEL_PREP(sense, titsel_n);
387394

0 commit comments

Comments
 (0)