From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: "Martin Hundebøll" <martin@geanix.com>
Cc: Linus Walleij <linus.walleij@linaro.org>,
"open list:GPIO SUBSYSTEM" <linux-gpio@vger.kernel.org>
Subject: Re: Re: [PATCH v1 1/9] pinctrl: mcp23s08: Get rid of legacy platform data
Date: Fri, 9 Oct 2020 17:02:36 +0300 [thread overview]
Message-ID: <20201009140236.GG4077@smile.fi.intel.com> (raw)
In-Reply-To: <c82ef50e-8f5c-39cd-6032-b4797a49e0e1@geanix.com>
On Fri, Oct 09, 2020 at 11:15:57AM +0200, Martin Hundebøll wrote:
> On 16/04/2020 12.35, Linus Walleij wrote:
> > On Tue, Apr 7, 2020 at 7:38 PM Andy Shevchenko
> > <andriy.shevchenko@linux.intel.com> wrote:
...
> This series caused probing of my PiFace2 to fail:
Thanks for report!
> > [ 1.019604] mcp23s08: probe of spi0.0 failed with error -22
I suppose you are trying this on v5.9-rc8 with the same result?
This case without any error message and with -EINVAL points me to the only
possible call that may fail, i.e.
ret = mcp23s08_spi_regmap_init(data->mcp[addr], dev, addr, type);
if (ret)
return ret;
Can you confirm this by adding a dev_info() call in between?
ret = mcp23s08_spi_regmap_init(data->mcp[addr], dev, addr, type);
if (ret) {
dev_info(dev, "regmap init failed for %d@%u\n", type, addr);
return ret;
}
and share what it prints, please?
EINVAL can be returned either by wrong type (see switch-case inside that
function) or by devm_regmap_init().
> I tried to bisect, but some of the commits failed to compile:
>
> > drivers/pinctrl/pinctrl-mcp23s08.c:959:39: error: 'mcp23s08_spi_of_match'
> undeclared (first use in this function); did you mean
> 'mcp23s08_i2c_of_match'?
>
> > 959 | match = of_match_device(of_match_ptr(mcp23s08_spi_of_match),
> &spi->dev);
At which patch this happens?
I compiled them individually but it might be slipped during rebase in between
of versions of the patch series.
> However, bisecting did narrow it down to a few commits:
You meant that revert of all of them helps?
Can you rather try to revert all patches against this driver until the one
which starts the series and bisect again? (Should be like 4-5 iterations only).
> > * 1ac30db20be2 - (refs/bisect/bad) pinctrl: mcp23s08: Make use of device
> properties (6 months ago) <Andy Shevchenko>
>
> > * 88af89b52a1b -
> (refs/bisect/skip-88af89b52a1b7493f1e5ec165856b4c6767cf654) pinctrl:
> mcp23s08: Propagate error code from device_property_read_u32() (6 months
> ago) <Andy Shevchenko>
>
> > * 0874758ecb2b -
> (refs/bisect/skip-0874758ecb2b3faa200a86dda45dbc29335f883e) pinctrl:
> mcp23s08: Refactor mcp23s08_spi_regmap_init() (6 months ago) <Andy
> Shevchenko>
>
> > * 0521701c8d10 -
> (refs/bisect/skip-0521701c8d10f832a401cc7ebfa92bb73782d792) pinctrl:
> mcp23s08: Drop unused parameter in mcp23s08_probe_one() (6 months ago) <Andy
> Shevchenko>
>
> > * d3da29b628a8 -
> (refs/bisect/skip-d3da29b628a86777d25c741c44b8af35f10020a0) pinctrl:
> mcp23s08: Consolidate SPI and I²C code (6 months ago) <Andy Shevchenko>
>
> > * 84d02e785d34 -
> (refs/bisect/good-84d02e785d34be9363a825d696cca1f07fac2634) pinctrl:
> mcp23s08: Deduplicate IRQ chip filling (6 months ago) <Andy Shevchenko>
>
> I'm using the rpi3 device tree (broadcom/bcm2837-rpi-3-b.dtb) overlayed with
> a configuration for the mcp23s08:
> /dts-v1/;
> /plugin/;
> / {
> fragment@0 {
> target-path = "/soc/spi@7e204000";
> __overlay__ {
> pinctrl-names = "default";
> pinctrl-0 = <&spi0_gpio7>;
> #address-cells = <1>;
> #size-cells = <0>;
> status = "okay";
> gpio@0 {
> compatible = "microchip,mcp23s17";
> reg = <0>;
> gpio-controller;
> #gpio-cells = <2>;
> microchip,spi-present-mask = <0x01>;
> spi-max-frequency = <1000000>;
> };
> };
> };
Okay, there is no IRQ chip here... But this should be fine I think.
> };
> I looked around the code a bit, and tried to compare it with v5.7, but
> didn't see any obvious candidates.
--
With Best Regards,
Andy Shevchenko
next prev parent reply other threads:[~2020-10-09 14:01 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-07 17:38 [PATCH v1 1/9] pinctrl: mcp23s08: Get rid of legacy platform data Andy Shevchenko
2020-04-07 17:38 ` [PATCH v1 2/9] pinctrl: mcp23s08: Deduplicate IRQ chip filling Andy Shevchenko
2020-04-07 17:38 ` [PATCH v1 3/9] pinctrl: mcp23s08: Consolidate SPI and I²C code Andy Shevchenko
2020-04-07 17:38 ` [PATCH v1 4/9] pinctrl: mcp23s08: Drop unused parameter in mcp23s08_probe_one() Andy Shevchenko
2020-04-07 17:38 ` [PATCH v1 5/9] pinctrl: mcp23s08: Refactor mcp23s08_spi_regmap_init() Andy Shevchenko
2020-04-07 17:38 ` [PATCH v1 6/9] pinctrl: mcp23s08: Propagate error code from device_property_read_u32() Andy Shevchenko
2020-04-07 17:38 ` [PATCH v1 7/9] pinctrl: mcp23s08: Make use of device properties Andy Shevchenko
2020-04-07 17:38 ` [PATCH v1 8/9] pinctrl: mcp23s08: Use for_each_set_bit() and hweight_long() Andy Shevchenko
2020-04-07 17:38 ` [PATCH v1 9/9] pinctrl: mcp23s08: Split to three parts: core, I²C, SPI Andy Shevchenko
2020-04-16 10:35 ` [PATCH v1 1/9] pinctrl: mcp23s08: Get rid of legacy platform data Linus Walleij
2020-10-09 9:15 ` Martin Hundebøll
2020-10-09 14:02 ` Andy Shevchenko [this message]
2020-10-09 16:02 ` Andy Shevchenko
2021-09-16 12:51 ` Florian Eckert
2021-09-22 6:36 ` Andy Shevchenko
2021-09-22 7:53 ` Andy Shevchenko
2021-09-23 14:17 ` Add a SSDT ACPI description to recognize my I2C device connected via SMBus Florian Eckert
2021-09-23 16:24 ` Mika Westerberg
2021-09-23 20:26 ` Andy Shevchenko
2021-09-23 20:29 ` Andy Shevchenko
2021-09-29 22:40 ` Florian Eckert
2021-09-30 6:15 ` Andy Shevchenko
2021-09-30 6:19 ` Andy Shevchenko
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201009140236.GG4077@smile.fi.intel.com \
--to=andriy.shevchenko@linux.intel.com \
--cc=linus.walleij@linaro.org \
--cc=linux-gpio@vger.kernel.org \
--cc=martin@geanix.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.