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-next>] [day] [month] [year] [list]
Date:   Mon, 5 Jun 2017 18:54:50 +0100
From:   Colin Ian King <colin.king@...onical.com>
To:     Tony Lindgren <tony@...mide.com>
Cc:     Andrew Lunn <andrew@...n.ch>,
        Florian Fainelli <f.fainelli@...il.com>,
        netdev@...r.kernel.org,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: re: phy: cpcap-usb: Add CPCAP PMIC USB support

Hi Tony,

While running static analysis on linux-next, CoverityScan picked up a
NULL pointer deference on ddata->pins when calling pinctrl_lookup_state:

466        ddata->pins = devm_pinctrl_get(ddata->dev);

   1. Condition IS_ERR(ddata->pins), taking true branch.

467        if (IS_ERR(ddata->pins)) {
468                dev_info(ddata->dev, "default pins not configured:
%ld\n",
469                         PTR_ERR(ddata->pins));

   2. assign_zero: Assigning: ddata->pins = NULL.

470                ddata->pins = NULL;
471        }
472

   CID 1440453 (#1 of 1): Explicit null dereferenced (FORWARD_NULL)3.
var_deref_model: Passing null pointer ddata->pins to
pinctrl_lookup_state, which dereferences it. [show details]

473        ddata->pins_ulpi = pinctrl_lookup_state(ddata->pins, "ulpi");


I suspect the IS_ERROR() check should return with some error return
rather than continuing.

Colin.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ