Re: [PATCH V2 2/2] iio: accell: mma8452: add optional vdd/vddio regulator operation support

2018-12-10 Thread Fabio Estevam
On Mon, Dec 10, 2018 at 5:25 AM Anson Huang wrote: > @@ -1533,6 +1536,27 @@ static int mma8452_probe(struct i2c_client *client, > data->client = client; > mutex_init(>lock); > data->chip_info = match->data; > + data->vdd_reg = devm_regulator_get_optional(>dev,

Re: [PATCH V2 2/2] iio: accell: mma8452: add optional vdd/vddio regulator operation support

2018-12-10 Thread Martin Kepplinger
On 10.12.18 08:25, Anson Huang wrote: > The accelerometer's power supply could be controlled by regulator > on some platforms, such as i.MX6Q-SABRESD board, the mma8451's > power supply is controlled by a GPIO fixed regulator, need to make > sure the regulator is enabled before any communication

[PATCH V2 2/2] iio: accell: mma8452: add optional vdd/vddio regulator operation support

2018-12-09 Thread Anson Huang
The accelerometer's power supply could be controlled by regulator on some platforms, such as i.MX6Q-SABRESD board, the mma8451's power supply is controlled by a GPIO fixed regulator, need to make sure the regulator is enabled before any communication with mma8451, this patch adds optional