
Hi Stefano,
On 04/25/2011 04:59 AM, Jason Hui wrote:
Hi, Stefano,
Hi Jason,
If you still want me to include the DA9053 support into fsl_pmic, could you please extend the fsl_pmic support to easily add another vender's pmic support first?
Really I have not understood your question. What do you mean ?
Then, Can you tell me how to add the dialog pmic support into fsl_pmi.c file which is dedicated for freescale mc13xxx? Thanks,
IMHO the details for each Power Controllers are inside the corresponding header, that contains the register description, in your xace DA09053.h. The fsl_pmic.c expones only a general way to speak with the controller via SPI or I2C interface. If I see your patch, the only real difference with the original file is that a single byte is read/written with the DA09053, while the mc13xxx have 32-bit registers. You can add this option as CONFIG_ switch, or in another way.
Only the board is aware about which PMIC is used. In fact, the fsl_pmic.c does not include neither mc13892.h nor mc13783.h.
Then why not rename the driver to something else than "fsl_pmic"? Maybe this is what Jason really is asking? I have not looked any deeper, but maybe something like "i2c_pmic" or such...
Cheers Detlev