On Tue, Nov 23, 2010 at 07:25:52PM +0100, Bengt Jonsson wrote:I get your point, I'll try this out.
The ab8500 regulator board configuration will be better separated
from the MFD board configuration. This patch adds a void pointer
for this purpose.
Adding something completely typesafe seems like a real loss - if you
want to point to something else at least point to a particular type -
eg,
struct foo;
struct pdata {
int other_stuff;
struct foo *foo;
};
The problem I see is that ab8500-core defines the number of regulators which I can see no reason for. If someone wants to add or remove a regulator they have to make a change in include/linux/mfd/ab8500.c as well as in the regulator files.struct regulator_init_data *regulator[AB8500_NUM_REGULATORS];
+ void *regulator_data;
It'd also help if you could articulate the problem you see with the
current approach...