diff options
author | Bartosz Golaszewski <bgolaszewski@baylibre.com> | 2019-02-14 15:52:13 +0100 |
---|---|---|
committer | Sekhar Nori <nsekhar@ti.com> | 2019-02-19 19:55:18 +0530 |
commit | 882bed7298f14cc04a94934b4efa801b1c7873e0 (patch) | |
tree | c4d97e13c2b0b1d10fedb963ee94ee5d1a413acb /arch/arm/mach-davinci | |
parent | a6c0bba1fa5dfd5ff2a842c45dfd1d2ce63fa595 (diff) | |
download | linux-882bed7298f14cc04a94934b4efa801b1c7873e0.tar.gz linux-882bed7298f14cc04a94934b4efa801b1c7873e0.tar.bz2 linux-882bed7298f14cc04a94934b4efa801b1c7873e0.zip |
ARM: davinci: aintc: request memory region before remapping it
Add a missing call to request_mem_region() before calling ioremap() to
make sure the region is not being used by anyone else.
Reviewed-by: David Lechner <david@lechnology.com>
Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
Signed-off-by: Sekhar Nori <nsekhar@ti.com>
Diffstat (limited to 'arch/arm/mach-davinci')
-rw-r--r-- | arch/arm/mach-davinci/irq.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/arch/arm/mach-davinci/irq.c b/arch/arm/mach-davinci/irq.c index 2afaf19dc46c..2b6943731af9 100644 --- a/arch/arm/mach-davinci/irq.c +++ b/arch/arm/mach-davinci/irq.c @@ -86,9 +86,18 @@ davinci_aintc_handle_irq(struct pt_regs *regs) void __init davinci_aintc_init(const struct davinci_aintc_config *config) { unsigned int irq_off, reg_off, prio, shift; + void __iomem *req; int ret, irq_base; const u8 *prios; + req = request_mem_region(config->reg.start, + resource_size(&config->reg), + "davinci-cp-intc"); + if (!req) { + pr_err("%s: register range busy\n", __func__); + return; + } + davinci_aintc_base = ioremap(config->reg.start, resource_size(&config->reg)); if (!davinci_aintc_base) { |