SoC changes for omaps for v5.7 merge window
A change to improve the warning output for device tree data mismatch as compared to legacy platform data for ti-sysc related interconnect target modules. And change omap1 to request_irq() instead of setup_irq(). -----BEGIN PGP SIGNATURE----- iQJFBAABCAAvFiEEkgNvrZJU/QSQYIcQG9Q+yVyrpXMFAl5icq8RHHRvbnlAYXRv bWlkZS5jb20ACgkQG9Q+yVyrpXNv6BAAy0vgp3GLme0tgTnKUev956IaxrJ68x3I L6USn7nuN8hZGuesylJn6CLQaZalNLTXAvELcI5/ulyYXYaaXx/O5KYi1+JMK8Y/ 6foHGQ/1EkqtqghYwX1OJVeMUUOPA9LOf2DEofXSa/4Nr1D9V7xvymKT8gJUxKNy Stf/MCyXuWit/MVSdnwFq77gQBPSl4tmNrE/wj+4Urr94A64TJjFu6e/v6x1FXWW hJBlva7MkKvaKR6MMOIvsHa436RKvsn2mogF0TbbzSEJ8Oh6w65TQYOkf3c7EknA OCkAG/cBPxsSrufiFDm9nYGUT7N+djufGUODlmkhSUA43AhNkJr+dUceQ+KW4+GR OpOJRD3i8Cc2pG2FntP7jF0ON750Cr3702R/VT0B01p5LFk7HPXsv53OJO6UyvnH qa4ctEXcfY3F1yff7TNHmPehHSBuLUupw5gnQY1GHqu+qgo++XIgLcLY5iHwbiVJ ZnRAuKJPZpvnxTLy+wm6PY6yXsBwIRSZrhQCeNCn7n8OJFFsFrmIRh1Gcf8RSF8W UCfJ9jKMgLEJjx4kCcxi6ONwxc2zh63Er861cEISUBJr31DnQ0q6XoHe8yanROFw buMQCAvj1ll5JwIbOrMF7/CBRu4isDcxLhevblc4Rc46VD641h3rA+tg7zPVj4qu 3wmD9VVWGYQ= =ikQD -----END PGP SIGNATURE----- Merge tag 'omap-for-v5.7/soc-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into arm/soc SoC changes for omaps for v5.7 merge window A change to improve the warning output for device tree data mismatch as compared to legacy platform data for ti-sysc related interconnect target modules. And change omap1 to request_irq() instead of setup_irq(). * tag 'omap-for-v5.7/soc-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap: ARM: OMAP: replace setup_irq() by request_irq() ARM: OMAP2+: Improve handling of ti-sysc related sysc_fields Link: https://lore.kernel.org/r/pull-1583511417-919838@atomide.com Signed-off-by: Arnd Bergmann <arnd@arndb.de>
This commit is contained in:
commit
6480e7b38d
|
@ -596,11 +596,6 @@ static irqreturn_t omap_wakeup_interrupt(int irq, void *dev)
|
|||
return IRQ_HANDLED;
|
||||
}
|
||||
|
||||
static struct irqaction omap_wakeup_irq = {
|
||||
.name = "peripheral wakeup",
|
||||
.handler = omap_wakeup_interrupt
|
||||
};
|
||||
|
||||
|
||||
|
||||
static const struct platform_suspend_ops omap_pm_ops = {
|
||||
|
@ -613,6 +608,7 @@ static const struct platform_suspend_ops omap_pm_ops = {
|
|||
static int __init omap_pm_init(void)
|
||||
{
|
||||
int error = 0;
|
||||
int irq;
|
||||
|
||||
if (!cpu_class_is_omap1())
|
||||
return -ENODEV;
|
||||
|
@ -656,9 +652,12 @@ static int __init omap_pm_init(void)
|
|||
arm_pm_idle = omap1_pm_idle;
|
||||
|
||||
if (cpu_is_omap7xx())
|
||||
setup_irq(INT_7XX_WAKE_UP_REQ, &omap_wakeup_irq);
|
||||
irq = INT_7XX_WAKE_UP_REQ;
|
||||
else if (cpu_is_omap16xx())
|
||||
setup_irq(INT_1610_WAKE_UP_REQ, &omap_wakeup_irq);
|
||||
irq = INT_1610_WAKE_UP_REQ;
|
||||
if (request_irq(irq, omap_wakeup_interrupt, 0, "peripheral wakeup",
|
||||
NULL))
|
||||
pr_err("Failed to request irq %d (peripheral wakeup)\n", irq);
|
||||
|
||||
/* Program new power ramp-up time
|
||||
* (0 for most boards since we don't lower voltage when in deep sleep)
|
||||
|
|
|
@ -155,15 +155,11 @@ static irqreturn_t omap_mpu_timer1_interrupt(int irq, void *dev_id)
|
|||
return IRQ_HANDLED;
|
||||
}
|
||||
|
||||
static struct irqaction omap_mpu_timer1_irq = {
|
||||
.name = "mpu_timer1",
|
||||
.flags = IRQF_TIMER | IRQF_IRQPOLL,
|
||||
.handler = omap_mpu_timer1_interrupt,
|
||||
};
|
||||
|
||||
static __init void omap_init_mpu_timer(unsigned long rate)
|
||||
{
|
||||
setup_irq(INT_TIMER1, &omap_mpu_timer1_irq);
|
||||
if (request_irq(INT_TIMER1, omap_mpu_timer1_interrupt,
|
||||
IRQF_TIMER | IRQF_IRQPOLL, "mpu_timer1", NULL))
|
||||
pr_err("Failed to request irq %d (mpu_timer1)\n", INT_TIMER1);
|
||||
omap_mpu_timer_start(0, (rate / HZ) - 1, 1);
|
||||
|
||||
clockevent_mpu_timer1.cpumask = cpumask_of(0);
|
||||
|
|
|
@ -148,15 +148,11 @@ static irqreturn_t omap_32k_timer_interrupt(int irq, void *dev_id)
|
|||
return IRQ_HANDLED;
|
||||
}
|
||||
|
||||
static struct irqaction omap_32k_timer_irq = {
|
||||
.name = "32KHz timer",
|
||||
.flags = IRQF_TIMER | IRQF_IRQPOLL,
|
||||
.handler = omap_32k_timer_interrupt,
|
||||
};
|
||||
|
||||
static __init void omap_init_32k_timer(void)
|
||||
{
|
||||
setup_irq(INT_OS_TIMER, &omap_32k_timer_irq);
|
||||
if (request_irq(INT_OS_TIMER, omap_32k_timer_interrupt,
|
||||
IRQF_TIMER | IRQF_IRQPOLL, "32KHz timer", NULL))
|
||||
pr_err("Failed to request irq %d(32KHz timer)\n", INT_OS_TIMER);
|
||||
|
||||
clockevent_32k_timer.cpumask = cpumask_of(0);
|
||||
clockevents_config_and_register(&clockevent_32k_timer,
|
||||
|
|
|
@ -3148,15 +3148,14 @@ static int omap_hwmod_check_sysc(struct device *dev,
|
|||
/**
|
||||
* omap_hwmod_init_regbits - init sysconfig specific register bits
|
||||
* @dev: struct device
|
||||
* @oh: module
|
||||
* @data: module data
|
||||
* @sysc_fields: new sysc configuration
|
||||
*/
|
||||
static int omap_hwmod_init_regbits(struct device *dev,
|
||||
static int omap_hwmod_init_regbits(struct device *dev, struct omap_hwmod *oh,
|
||||
const struct ti_sysc_module_data *data,
|
||||
struct sysc_regbits **sysc_fields)
|
||||
{
|
||||
*sysc_fields = NULL;
|
||||
|
||||
switch (data->cap->type) {
|
||||
case TI_SYSC_OMAP2:
|
||||
case TI_SYSC_OMAP2_TIMER:
|
||||
|
@ -3191,6 +3190,12 @@ static int omap_hwmod_init_regbits(struct device *dev,
|
|||
*sysc_fields = &omap_hwmod_sysc_type_usb_host_fs;
|
||||
break;
|
||||
default:
|
||||
*sysc_fields = NULL;
|
||||
if (!oh->class->sysc->sysc_fields)
|
||||
return 0;
|
||||
|
||||
dev_err(dev, "sysc_fields not found\n");
|
||||
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
|
@ -3356,9 +3361,9 @@ static int omap_hwmod_check_module(struct device *dev,
|
|||
if (!oh->class->sysc)
|
||||
return -ENODEV;
|
||||
|
||||
if (sysc_fields != oh->class->sysc->sysc_fields)
|
||||
dev_warn(dev, "sysc_fields %p != %p\n", sysc_fields,
|
||||
oh->class->sysc->sysc_fields);
|
||||
if (oh->class->sysc->sysc_fields &&
|
||||
sysc_fields != oh->class->sysc->sysc_fields)
|
||||
dev_warn(dev, "sysc_fields mismatch\n");
|
||||
|
||||
if (rev_offs != oh->class->sysc->rev_offs)
|
||||
dev_warn(dev, "rev_offs %08x != %08x\n", rev_offs,
|
||||
|
@ -3574,7 +3579,7 @@ int omap_hwmod_init_module(struct device *dev,
|
|||
|
||||
cookie->data = oh;
|
||||
|
||||
error = omap_hwmod_init_regbits(dev, data, &sysc_fields);
|
||||
error = omap_hwmod_init_regbits(dev, oh, data, &sysc_fields);
|
||||
if (error)
|
||||
return error;
|
||||
|
||||
|
|
|
@ -91,12 +91,6 @@ static irqreturn_t omap2_gp_timer_interrupt(int irq, void *dev_id)
|
|||
return IRQ_HANDLED;
|
||||
}
|
||||
|
||||
static struct irqaction omap2_gp_timer_irq = {
|
||||
.name = "gp_timer",
|
||||
.flags = IRQF_TIMER | IRQF_IRQPOLL,
|
||||
.handler = omap2_gp_timer_interrupt,
|
||||
};
|
||||
|
||||
static int omap2_gp_timer_set_next_event(unsigned long cycles,
|
||||
struct clock_event_device *evt)
|
||||
{
|
||||
|
@ -382,8 +376,9 @@ static void __init omap2_gp_clockevent_init(int gptimer_id,
|
|||
&clockevent_gpt.name, OMAP_TIMER_POSTED);
|
||||
BUG_ON(res);
|
||||
|
||||
omap2_gp_timer_irq.dev_id = &clkev;
|
||||
setup_irq(clkev.irq, &omap2_gp_timer_irq);
|
||||
if (request_irq(clkev.irq, omap2_gp_timer_interrupt,
|
||||
IRQF_TIMER | IRQF_IRQPOLL, "gp_timer", &clkev))
|
||||
pr_err("Failed to request irq %d (gp_timer)\n", clkev.irq);
|
||||
|
||||
__omap_dm_timer_int_enable(&clkev, OMAP_TIMER_INT_OVERFLOW);
|
||||
|
||||
|
|
Loading…
Reference in New Issue