Messages in this thread | | | Date | Thu, 17 Jun 2010 21:59:47 +0400 | From | Anton Vorontsov <> | Subject | Re: [PATCH] Intel MID platform battery driver. (right patch this time) |
| |
On Thu, Jun 17, 2010 at 06:12:36PM +0100, Alan Cox wrote: > Oops sorry - try the right version this time. > > From: Nithish Mahalingam <nithish.mahalingam@intel.com> > > The PMIC Battery driver provides battery charging and battery gauge > functionality on Intel MID platforms. This provides the basic functions. There > are some USB drivers to merge before the selection of charging between the > different USB power levels can be enabled. > > Moved to a platform device by Alek Du. > > Signed-off-by: Nithish Mahalingam <nithish.mahalingam@intel.com> > Signed-off-by: Alan Cox <alan@linux.intel.com>
Applied to battery-2.6.git, thanks.
However, note that there's another issue that should be fixed both in this driver and in the platform (or SPI device driver) code.
[...] > +static __devinit int probe(int irq, struct device *dev)
Notice 'int irq' here.
[...] > +static int __devinit platform_pmic_battery_probe(struct platform_device *pdev) > +{ > + return probe(pdev->id, &pdev->dev);
So the irq number is derived from the platform device ID. Which is very bizarre, and not how things supposed to work. I guess there should be an IRQ resource for the device instead.
-- Anton Vorontsov email: cbouatmailru@gmail.com irc://irc.freenode.net/bd2
| |