On Monday 02 July 2012, Lee Jones wrote: > On 02/07/12 11:38, Rajanikanth HV wrote: > > how will you accommodate new battery types information then? > > Add them to the driver too? > > From what I can see, the structs in board-mop500-bm.c are more of a > capability thing than saying "this is what we have". > > Please correct my snap-judgment if I'm incorrect.
My first reaction to this would have been to put it all into the device tree, but I agree that the amount of data is a bit excessive. Looking at the Sony xperia sola source code, it seems that the same data is used for *all* boards, and nothing in it looks board specific, so putting it all into the driver itself sounds like the easiest solution. We can always add some form of abstraction if we later need something more complex. The version I'm looking at uses a compile-time configuration symbol "CONFIG_AB8500_BATTERY_THERM_ON_BATCTRL". This has to get removed and turned into a run-time option. The regulator names in the platform data look should probably be taken from the device tree. Arnd _______________________________________________ linaro-dev mailing list linaro-dev@lists.linaro.org http://lists.linaro.org/mailman/listinfo/linaro-dev