On Mon, 18 Feb 2019 17:41:32 +0100
Bartosz Golaszewski <b...@bgdev.pl> wrote:

> From: Bartosz Golaszewski <bgolaszew...@baylibre.com>
> 
> Implement the irq_set_type() callback and call irqd_set_trigger_type()
> internally so that users interested in the configured trigger type can
> later retrieve it using irqd_get_trigger_type().
> 
> Signed-off-by: Bartosz Golaszewski <bgolaszew...@baylibre.com>
> ---
>  kernel/irq/irq_sim.c | 8 ++++++++
>  1 file changed, 8 insertions(+)
> 
> diff --git a/kernel/irq/irq_sim.c b/kernel/irq/irq_sim.c
> index 98a20e1594ce..83ecc65d8be2 100644
> --- a/kernel/irq/irq_sim.c
> +++ b/kernel/irq/irq_sim.c
> @@ -25,10 +25,18 @@ static void irq_sim_irqunmask(struct irq_data *data)
>       irq_ctx->enabled = true;
>  }
>  
> +static int irq_sim_set_type(struct irq_data *data, unsigned int type)
> +{
> +     irqd_set_trigger_type(data, type);
> +
> +     return 0;

You keep ignoring the requirement for sanitization of the trigger type.
Frankly, I'm getting tired of fighting over 3 lines of incorrect code.

I guess that despite all the noise, you don't really want this code in
after all.

        M.
-- 
Without deviation from the norm, progress is not possible.

Reply via email to