[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1387184787.722913245@f178.i.mail.ru>
Date: Mon, 16 Dec 2013 13:06:27 +0400
From: Alexander Shiyan <shc_work@...l.ru>
To: Lee Jones <lee.jones@...aro.org>
Cc: linux-kernel@...r.kernel.org,
Samuel Ortiz <sameo@...ux.intel.com>
Subject: Re: [PATCH 3/3] mfd: mc13xxx: Simplify "probe" & "remove"
> > This patch simplifies "probe" and "remove" functions by moving
> > some initialization code in the driver core.
> >
> > Signed-off-by: Alexander Shiyan <shc_work@...l.ru>
> > ---
> > drivers/mfd/mc13xxx-core.c | 36 +++++++++++++++++-------------------
> > drivers/mfd/mc13xxx-i2c.c | 18 ++++--------------
> > drivers/mfd/mc13xxx-spi.c | 19 ++++++-------------
> > drivers/mfd/mc13xxx.h | 6 ++----
> > 4 files changed, 29 insertions(+), 50 deletions(-)
> >
> > diff --git a/drivers/mfd/mc13xxx-core.c b/drivers/mfd/mc13xxx-core.c
> > index b0c7cb0..06e64b6 100644
> > --- a/drivers/mfd/mc13xxx-core.c
> > +++ b/drivers/mfd/mc13xxx-core.c
>
> <snip>
>
> > - ret = request_threaded_irq(irq, NULL, mc13xxx_irq_thread,
> > + ret = request_threaded_irq(mc13xxx->irq, NULL, mc13xxx_irq_thread,
> > IRQF_ONESHOT | IRQF_TRIGGER_HIGH, "mc13xxx", mc13xxx);
>
> Please use devm_* managed resources, then you can remove the free_irq().
Using devm-* is not possible at this time since we need to avoid interrupts before
removing mc13xxx childs.
This could be converted to use devm-* functions once we migrate to IRQ domains.
I work on this now.
---
Powered by blists - more mailing lists