Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1374112 > unrolled thread

Re: [PATCH v2 2/9] drivers: irqchip: Add STM32 external interrupts support

Started byLinus Walleij <linus.walleij@linaro.org>
First post2016-04-08 11:50 +0200
Last post2016-04-08 11:50 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [PATCH v2 2/9] drivers: irqchip: Add STM32 external interrupts support Linus Walleij <linus.walleij@linaro.org> - 2016-04-08 11:50 +0200

#1374112 — Re: [PATCH v2 2/9] drivers: irqchip: Add STM32 external interrupts support

FromLinus Walleij <linus.walleij@linaro.org>
Date2016-04-08 11:50 +0200
SubjectRe: [PATCH v2 2/9] drivers: irqchip: Add STM32 external interrupts support
Message-ID<rlBda-1LF-49@gated-at.bofh.it>
On Thu, Mar 31, 2016 at 5:09 PM, Maxime Coquelin
<mcoquelin.stm32@gmail.com> wrote:

> +       gc = domain->gc->gc[0];
> +       gc->reg_base                         = base;
> +       gc->chip_types->type               = IRQ_TYPE_EDGE_BOTH;
> +       gc->chip_types->chip.name          = gc->chip_types[0].chip.name;
> +       gc->chip_types->chip.irq_ack       = irq_gc_ack_set_bit;
> +       gc->chip_types->chip.irq_mask      = irq_gc_mask_clr_bit;
> +       gc->chip_types->chip.irq_unmask    = irq_gc_mask_set_bit;
> +       gc->chip_types->chip.irq_set_type  = stm32_irq_set_type;
> +       gc->chip_types->chip.irq_set_wake  = stm32_irq_set_wake;
> +       gc->chip_types->regs.ack           = EXTI_PR;
> +       gc->chip_types->regs.mask          = EXTI_IMR;
> +       gc->chip_types->handler            = handle_edge_irq;

If this is used by a GPIO chip (as happens in another part of
the series), you need to set up the .irq_request_resources()
and .irq_release_resources() to call gpiochip_lock_as_irq()
and gpiochip_unlock_as_irq().

As with the other comment on the GPIO patch, the separation
of concerns between irqchip and gpiochip is a bit artificial
here and breaks down somewhat.

Yours,
Linus Walleij

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web