[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAL_Jsq+aB=h+GOzv=vyAKupF8GogtbgHyG07e=F7-8eivsmh9w@mail.gmail.com>
Date: Tue, 19 Sep 2017 14:35:35 -0500
From: Rob Herring <robh@...nel.org>
To: Alan Tull <atull@...nel.org>
Cc: Guenter Roeck <linux@...ck-us.net>,
Linux HWMON List <linux-hwmon@...r.kernel.org>,
"devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
linux-kernel <linux-kernel@...r.kernel.org>,
Jean Delvare <jdelvare@...e.com>,
Mark Rutland <mark.rutland@....com>
Subject: Re: [PATCH 2/2] hwmon: add dt binding for max1619
On Tue, Sep 19, 2017 at 1:11 PM, Alan Tull <atull@...nel.org> wrote:
> On Mon, Sep 18, 2017 at 4:11 PM, Rob Herring <robh@...nel.org> wrote:
>> On Mon, Sep 11, 2017 at 12:58:57PM -0700, Guenter Roeck wrote:
>>> On Mon, Sep 11, 2017 at 02:16:49PM -0500, Alan Tull wrote:
>>> > Add new device tree binding for max1619.
>>> >
>>> > Signed-off-by: Alan Tull <atull@...nel.org>
>>>
>>> Technically that should already work, without explicit binding,
>>> or did the i2c core change lately ?
>>
>> There was some work in that direction IIRC.
>
> Yes, after Guenter replied I tried it without this patch and it
> worked. i2c drivers can have a 'detect' function that can check part
> id, etc. If detection succeeds, it will fill in the device name in
> i2c_board_info->type and the i2c-core will enumerate using that.
Right, I expected it still worked, but am saying we don't want to rely
on that behavior and introduce new places relying on it. Otherwise,
the driver will match on say "rob,max1619" as well. The detect
function is the really old way to probe devices IIRC. The function to
look at is i2c_of_match_device. We want OF style match, not a match
with i2c_of_match_device_sysfs which strips the vendor prefix from the
compatible.
Rob
Powered by blists - more mailing lists