Messages in this thread | | | Date | Wed, 27 Aug 2014 08:56:35 -0700 | Subject | Re: [PATCH v6 2/5] MFD: RK808: Add new mfd driver for RK808 | From | Doug Anderson <> |
| |
Lee,
On Wed, Aug 27, 2014 at 6:39 AM, Lee Jones <lee.jones@linaro.org> wrote: >> +static int rk808_probe(struct i2c_client *client, >> + const struct i2c_device_id *id) >> +{ >> + int ret; >> + int pm_off = 0; >> + struct rk808 *rk808; >> + struct device_node *np = client->dev.of_node; > > Are you prepared for np == NULL?
Given that the driver no longer supports getting its config from platform data, I think it simply depends on OF now. It seems like we could add a "&& OF" to the dependencies. Is that OK with you?
It doesn't hurt to still add a check for np == NULL and bail out, though.
| |