diff options
author | Aidan MacDonald <aidanmacdonald.0x0@gmail.com> | 2022-06-23 22:14:17 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2022-06-29 18:13:14 +0100 |
commit | 9edd4f5aee8470dcfd0db04005908f61fbfae8e0 (patch) | |
tree | a27721deebef936e3ed7cb3fa173385f1c0f46d1 /drivers/base | |
parent | faa87ce9196dbb074d75bd4aecb8bacf18f19b4e (diff) | |
download | linux-9edd4f5aee8470dcfd0db04005908f61fbfae8e0.tar.gz linux-9edd4f5aee8470dcfd0db04005908f61fbfae8e0.tar.bz2 linux-9edd4f5aee8470dcfd0db04005908f61fbfae8e0.zip |
regmap-irq: Deprecate type registers and virtual registers
Config registers can be used to replace both type and virtual
registers, so mark both features are deprecated and issue a
warning if they're used.
Signed-off-by: Aidan MacDonald <aidanmacdonald.0x0@gmail.com>
Link: https://lore.kernel.org/r/20220623211420.918875-10-aidanmacdonald.0x0@gmail.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/base')
-rw-r--r-- | drivers/base/regmap/regmap-irq.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/base/regmap/regmap-irq.c b/drivers/base/regmap/regmap-irq.c index e3dbf55a561f..8cbc62c3d638 100644 --- a/drivers/base/regmap/regmap-irq.c +++ b/drivers/base/regmap/regmap-irq.c @@ -726,6 +726,12 @@ int regmap_add_irq_chip_fwnode(struct fwnode_handle *fwnode, return -EINVAL; } + if (chip->num_type_reg) + dev_warn(map->dev, "type registers are deprecated; use config registers instead"); + + if (chip->num_virt_regs || chip->virt_reg_base || chip->set_type_virt) + dev_warn(map->dev, "virtual registers are deprecated; use config registers instead"); + if (irq_base) { irq_base = irq_alloc_descs(irq_base, 0, chip->num_irqs, 0); if (irq_base < 0) { |