lkml.org 
[lkml]   [2014]   [Sep]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    SubjectRe: [PATCH v8 5/5] regulator: RK808: Remove pdata from the regulator
    From
    Chris,

    On Wed, Sep 3, 2014 at 10:06 AM, Chris Zhong <zyw@rock-chips.com> wrote:
    > Signed-off-by: Chris Zhong <zyw@rock-chips.com>
    >
    > Tested-by: Heiko <heiko@sntech.de>
    > ---
    >
    > Changes in v8:
    > Adviced by Doug
    > - remove rk808_regulator_dts() function
    > - remove the check about "client->dev.of_node"

    Nice, this cleaned this up a lot. Thanks!


    > static int rk808_regulator_probe(struct platform_device *pdev)
    > {
    > struct rk808 *rk808 = dev_get_drvdata(pdev->dev.parent);
    > struct i2c_client *client = rk808->i2c;
    > - struct rk808_board *pdata = dev_get_platdata(&client->dev);
    > struct regulator_config config = {};
    > struct regulator_dev *rk808_rdev;
    > - struct regulator_init_data *reg_data;
    > - int i = 0;

    As Heiko mentioned, you need "struct device_node *np, *reg_np;" here.

    > int ret = 0;
    > + int i = 0;

    nit: I think neither "ret" nor "i" needs to be initted here.


    Otherwise I agree that this looks really good!

    -Doug


    \
     
     \ /
      Last update: 2014-09-04 00:21    [W:5.492 / U:1.452 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site