lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <3d811222-68fa-0992-eeeb-97d1c6d09608@gmail.com>
Date:   Sun, 29 Mar 2020 12:34:04 +0200
From:   saravanan sekar <sravanhome@...il.com>
To:     Andy Shevchenko <andy.shevchenko@...il.com>
Cc:     Lee Jones <lee.jones@...aro.org>, Rob Herring <robh+dt@...nel.org>,
        Jonathan Cameron <jic23@...nel.org>,
        Hartmut Knaack <knaack.h@....de>,
        Lars-Peter Clausen <lars@...afoo.de>,
        Peter Meerwald <pmeerw@...erw.net>,
        Sebastian Reichel <sre@...nel.org>,
        devicetree <devicetree@...r.kernel.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        linux-iio <linux-iio@...r.kernel.org>,
        Linux PM <linux-pm@...r.kernel.org>
Subject: Re: [PATCH v5 4/5] power: supply: Add support for mps mp2629 battery
 charger

Hi Andy,

On 28/03/20 7:44 pm, Andy Shevchenko wrote:
> On Sat, Mar 28, 2020 at 1:29 PM saravanan sekar <sravanhome@...il.com> wrote:
>> On 28/03/20 12:02 pm, Andy Shevchenko wrote:
>>> On Sat, Mar 28, 2020 at 2:12 AM Saravanan Sekar <sravanhome@...il.com> wrote:
> ...
>
>>>> +       val->intval = (rval * props[fld].step) + props[fld].min;
>>> Too many parentheses.
>>>
>>> ...
>>>
>>>> +       return ((psp == POWER_SUPPLY_PROP_PRECHARGE_CURRENT) ||
>>>> +               (psp == POWER_SUPPLY_PROP_CHARGE_TERM_CURRENT) ||
>>>> +               (psp == POWER_SUPPLY_PROP_CONSTANT_CHARGE_CURRENT) ||
>>>> +               (psp == POWER_SUPPLY_PROP_CONSTANT_CHARGE_VOLTAGE));
>>> Ditto.
>> I think I misunderstood you previous review comment "Redundant
>> parentheses", no sure what is the expectation
> (At least) surrounding pair is not needed, return (a == b) || (c == d);
ok, I will remove outer ().
>>> ...
>>>
>>>> +       return ((psp == POWER_SUPPLY_PROP_INPUT_VOLTAGE_LIMIT) ||
>>>> +               (psp == POWER_SUPPLY_PROP_INPUT_CURRENT_LIMIT));
>>> Ditto.
> ...
>
>>>> +       struct power_supply_config psy_cfg = {NULL};
>>> { 0 }
>>>
>> NULL to make compiler happy.
> Hmm... Can you share warning / error compiler issued in 0 case?
>
Please see the 0-day warning.

"Reported-by: kbuild test robot <lkp@...el.com>
sparse warnings: (new ones prefixed by >>)
 >> drivers/power/supply/mp2629_charger.c:584:47: sparse: sparse: Using 
plain integer as NULL pointer"

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ