[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20170106024657.y72pxkh6xeexwpp4@earth>
Date: Fri, 6 Jan 2017 03:46:58 +0100
From: Sebastian Reichel <sre@...nel.org>
To: Ezequiel Garcia <ezequiel@...guardiasur.com.ar>
Cc: Quentin Schulz <quentin.schulz@...e-electrons.com>,
jic23@...nel.org, knaack.h@....de, lars@...afoo.de,
pmeerw@...erw.net, Rob Herring <robh+dt@...nel.org>,
Mark Rutland <mark.rutland@....com>,
Chen-Yu Tsai <wens@...e.org>, linux@...linux.org.uk,
Maxime Ripard <maxime.ripard@...e-electrons.com>,
Lee Jones <lee.jones@...aro.org>,
Thomas Petazzoni <thomas.petazzoni@...e-electrons.com>,
"devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
linux-pm@...r.kernel.org, linux-iio@...r.kernel.org,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
bonbons@...ux-vserver.org, icenowy@...c.xyz,
linux-arm-kernel <linux-arm-kernel@...ts.infradead.org>
Subject: Re: [PATCH 17/22] power: supply: add battery driver for AXP20X and
AXP22X PMICs
Hi,
On Thu, Jan 05, 2017 at 02:34:48PM -0300, Ezequiel Garcia wrote:
> > +static int axp20x_power_probe(struct platform_device *pdev)
> > +{
> > + struct axp20x_dev *axp20x = dev_get_drvdata(pdev->dev.parent);
> > + struct axp20x_batt_ps *axp20x_batt;
> > + struct power_supply_config psy_cfg = {};
> > +
>
> To be consistent with the AC power supply and USB power supply,
> you might want to call of_device_is_available() here.
> Otherwise, the device probes even if "disabled" in the DTS.
I would expect that check in the mfd code. Probe should not be
called at all if the sub-device is disabled.
-- Sebastian
Download attachment "signature.asc" of type "application/pgp-signature" (834 bytes)
Powered by blists - more mailing lists