Re: [RFT] Sonypi: convert to the new platform device interface

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 12/13/05, Mattia Dongili <[email protected]> wrote:
> On Tue, Dec 13, 2005 at 02:19:40AM -0500, Dmitry Torokhov wrote:
> > Hi,
> >
> > Now that we allow manual binding and unbinding devices through sysfs it
> > is better if main device initialization is done in ->probe() instead of
> > module_init(). The following patch converts sonypi driver to this model.
> >
> > The patch compiles but I was unable to test it since I don't have the
> > hardware...
> [...]
> > +static int __devinit sonypi_setup_irq(struct sonypi_device *dev,
> > +                                   const struct sonypi_irq_list *irq_list)
> > +{
> > +     while (irq_list->irq) {
> > +
> > +             if (!request_irq(dev->irq, sonypi_irq,
>                                 ^^^^^^^^
> this should be irq_list->irq
>
> other than that seems to work here on a type2 model:
>
> sonypi: Sony Programmable I/O Controller Driver v1.26.
> sonypi: trying irq 11
> input: Sony Vaio Jogdial as /class/input/input8
> input: Sony Vaio Keys as /class/input/input9
> sonypi: detected type2 model, verbose = 1, fnkeyinit = off, camera = off, compat = off, mask = 0xffffffff, useinput = on, acpi = on
> sonypi: enabled at irq=11, port1=0x1080, port2=0x1084
> sonypi: device allocated minor is 63
> sonypi: unknown event port1=0x0f,port2=0x05
>

Thank you very much for testing and debugging the patch. I will fix
the irq thing and repost.

> Oh, there seems to be a spurious interrupt happening at modules
> insertion (I suspect sonypi_enable triggering and ignoring it), but this
> happens with the old module too and I never noticed it before. Wouldn't
> make more sense to print the warning even if verbose=0 to be able to
> catch it timely? I mean it's since 2.4 times I don't enable verbose mode
> in sonypi...
>

Probably, let's see what Stelian will say.

--
Dmitry
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux