]> www.infradead.org Git - nvme.git/commitdiff
regmap: irq: Use one way of setting all bits in the register
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Thu, 6 Feb 2025 19:16:30 +0000 (21:16 +0200)
committerMark Brown <broonie@kernel.org>
Thu, 6 Feb 2025 20:46:09 +0000 (20:46 +0000)
Currently there are two ways of how we represent all bits set, i.e.
UINT_MAX and GENMASK(31, 0). Use the former as the single way of
doing that, which is crystal clear on how we fill the unsigned int
value.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://patch.msgid.link/20250206191644.1132869-1-andriy.shevchenko@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/base/regmap/regmap-irq.c

index 0bcd81389a29f8b39425f8ffe9fa3c94ec1eeead..e5631188d69277ce08ca5ddbf2d3648ce9c1f8df 100644 (file)
@@ -823,7 +823,7 @@ int regmap_add_irq_chip_fwnode(struct fwnode_handle *fwnode,
                /* Ack masked but set interrupts */
                if (d->chip->no_status) {
                        /* no status register so default to all active */
-                       d->status_buf[i] = GENMASK(31, 0);
+                       d->status_buf[i] = UINT_MAX;
                } else {
                        reg = d->get_irq_reg(d, d->chip->status_base, i);
                        ret = regmap_read(map, reg, &d->status_buf[i]);