From: Andy Shevchenko <andriy.shevchenko@intel.com>
To: Mark Hasemeyer <markhas@chromium.org>
Cc: LKML <linux-kernel@vger.kernel.org>,
"Sudeep Holla" <sudeep.holla@arm.com>,
"AngeloGioacchino Del Regno"
<angelogioacchino.delregno@collabora.com>,
"Rob Herring" <robh@kernel.org>,
"Krzysztof Kozlowski" <krzysztof.kozlowski@linaro.org>,
"Konrad Dybcio" <konrad.dybcio@linaro.org>,
"Raul Rangel" <rrangel@chromium.org>,
"Tzung-Bi Shih" <tzungbi@kernel.org>,
"David Gow" <davidgow@google.com>,
"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
"Mark Brown" <broonie@kernel.org>,
"Rafael J. Wysocki" <rafael@kernel.org>,
"Takashi Iwai" <tiwai@suse.de>,
"Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>
Subject: Re: [PATCH v4 23/24] platform: Modify platform_get_irq_optional() to use resource
Date: Sun, 14 Jan 2024 16:04:19 +0200 [thread overview]
Message-ID: <ZaPp4yVQ44J7HJB2@smile.fi.intel.com> (raw)
In-Reply-To: <CANg-bXA1thAjWDeaJs8aO-SmTkgcjx8Cw0nWUHt+CGyCrB5tLA@mail.gmail.com>
On Mon, Jan 08, 2024 at 12:09:10PM -0700, Mark Hasemeyer wrote:
> On Sat, Jan 6, 2024 at 7:56 AM Andy Shevchenko
> <andriy.shevchenko@intel.com> wrote:
> > On Tue, Jan 02, 2024 at 02:07:47PM -0700, Mark Hasemeyer wrote:
...
> > > + ret = fwnode_irq_get_resource(fwnode, num, r);
> >
> > I still prefer this not to return positive value. Since you _require_ @r to be
> > not NULL, i.e. valid, the returning positive value makes no sense.
> >
> > > + ret = ret < 0 ? ret : 0;
> > > + if (!ret || ret == -EPROBE_DEFER)
> > > + goto out;
>
> I agree. But echoing my response from v3 patch 24:
> - The fwnode patch is already reviewed and approved.
> - The fwnode patch uses of_irq_to_resource() which already existed and
> returns the irq number on success. The error handling translation will
> just get pushed to the fwnode subsystem unless of_irq_to_resource() is
> also modified which means updating 8 or so drivers that reference it.
>
> I can either:
> -Leave it
> -Modify the fwnode subsystem to perform the error translation of
> of_irq_to_resource()
> -Modify the fwnode and OF subsystems and update all driver references
>
> The fwnode and OF patches are already reviewed. I imagine coding
> changes would imply dropping any Reviewed-by tags and requesting
> another review?
> I'd really prefer to not blow up the patch series anymore, but if you
> feel strongly, we can come up with a solution.
fwnode is quite generic API and I won't fail it from day 1.
Yet we have already some deviations in fwnode/device vs. OF/ACPI cases
(first comes to mind is device_for_each_child_node() which assumes
"availability").
So, I would prefer fwnode API to not inherit issues/features of OF specific
code. Maybe this can be considered as "yes, please update it".
--
With Best Regards,
Andy Shevchenko
next prev parent reply other threads:[~2024-01-14 14:04 UTC|newest]
Thread overview: 69+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-02 21:07 [PATCH v4 00/24] Improve IRQ wake capability reporting and update the cros_ec driver to use it Mark Hasemeyer
2024-01-02 21:07 ` Mark Hasemeyer
2024-01-02 21:07 ` [PATCH v4 01/24] resource: Add DEFINE_RES_*_NAMED_FLAGS macro Mark Hasemeyer
2024-01-02 21:07 ` [PATCH v4 02/24] gpiolib: acpi: Modify acpi_dev_irq_wake_get_by() to use resource Mark Hasemeyer
2024-01-06 14:44 ` Andy Shevchenko
2024-01-08 19:08 ` Mark Hasemeyer
2024-01-02 21:07 ` [PATCH v4 03/24] i2c: acpi: Modify i2c_acpi_get_irq() " Mark Hasemeyer
2024-01-06 14:48 ` Andy Shevchenko
2024-01-02 21:07 ` [PATCH v4 04/24] dt-bindings: power: Clarify wording for wakeup-source property Mark Hasemeyer
2024-01-09 20:45 ` Rob Herring
2024-01-02 21:07 ` [PATCH v4 05/24] ARM: dts: tegra: Enable cros-ec-spi as wake source Mark Hasemeyer
2024-01-02 21:07 ` [PATCH v4 06/24] ARM: dts: rockchip: rk3288: " Mark Hasemeyer
2024-01-02 21:07 ` Mark Hasemeyer
2024-01-02 21:07 ` Mark Hasemeyer
2024-01-02 21:07 ` [PATCH v4 07/24] ARM: dts: samsung: exynos5420: " Mark Hasemeyer
2024-01-02 21:07 ` Mark Hasemeyer
2024-01-02 21:07 ` [PATCH v4 08/24] ARM: dts: samsung: exynos5800: " Mark Hasemeyer
2024-01-02 21:07 ` Mark Hasemeyer
2024-01-02 21:07 ` [PATCH v4 09/24] arm64: dts: mediatek: mt8173: " Mark Hasemeyer
2024-01-02 21:07 ` Mark Hasemeyer
2024-01-03 12:22 ` AngeloGioacchino Del Regno
2024-01-03 12:22 ` AngeloGioacchino Del Regno
2024-01-02 21:07 ` [PATCH v4 10/24] arm64: dts: mediatek: mt8183: " Mark Hasemeyer
2024-01-02 21:07 ` Mark Hasemeyer
2024-01-03 12:22 ` AngeloGioacchino Del Regno
2024-01-03 12:22 ` AngeloGioacchino Del Regno
2024-01-02 21:07 ` [PATCH v4 11/24] arm64: dts: mediatek: mt8192: " Mark Hasemeyer
2024-01-02 21:07 ` Mark Hasemeyer
2024-01-03 12:22 ` AngeloGioacchino Del Regno
2024-01-03 12:22 ` AngeloGioacchino Del Regno
2024-01-02 21:07 ` [PATCH v4 12/24] arm64: dts: mediatek: mt8195: " Mark Hasemeyer
2024-01-02 21:07 ` Mark Hasemeyer
2024-01-03 12:22 ` AngeloGioacchino Del Regno
2024-01-03 12:22 ` AngeloGioacchino Del Regno
2024-01-02 21:07 ` [PATCH v4 13/24] arm64: dts: tegra: " Mark Hasemeyer
2024-01-02 21:07 ` [PATCH v4 14/24] arm64: dts: qcom: sc7180: " Mark Hasemeyer
2024-01-02 21:07 ` [PATCH v4 15/24] arm64: dts: qcom: sc7280: " Mark Hasemeyer
2024-01-02 21:07 ` [PATCH v4 16/24] arm64: dts: qcom: sdm845: " Mark Hasemeyer
2024-01-02 21:07 ` [PATCH v4 17/24] arm64: dts: rockchip: rk3399: " Mark Hasemeyer
2024-01-02 21:07 ` Mark Hasemeyer
2024-01-02 21:07 ` Mark Hasemeyer
2024-01-02 21:07 ` [PATCH v4 18/24] of: irq: add wake capable bit to of_irq_resource() Mark Hasemeyer
2024-01-02 21:07 ` [PATCH v4 19/24] of: irq: Add default implementation for of_irq_to_resource() Mark Hasemeyer
2024-01-02 21:07 ` [PATCH v4 20/24] of: irq: Remove extern from function declarations Mark Hasemeyer
2024-01-02 21:07 ` [PATCH v4 21/24] device property: Modify fwnode irq_get() to use resource Mark Hasemeyer
2024-01-06 14:52 ` Andy Shevchenko
2024-01-09 20:47 ` Rob Herring
2024-01-02 21:07 ` [PATCH v4 22/24] device property: Update functions to use EXPORT_SYMBOL_GPL() Mark Hasemeyer
2024-01-08 18:32 ` Sakari Ailus
2024-01-02 21:07 ` [PATCH v4 23/24] platform: Modify platform_get_irq_optional() to use resource Mark Hasemeyer
2024-01-06 14:55 ` Andy Shevchenko
2024-01-08 19:09 ` Mark Hasemeyer
2024-01-14 14:04 ` Andy Shevchenko [this message]
2024-01-02 21:07 ` [PATCH v4 24/24] platform/chrome: cros_ec: Use PM subsystem to manage wakeirq Mark Hasemeyer
2024-01-03 0:46 ` Stephen Boyd
2024-01-03 17:47 ` Mark Hasemeyer
2024-01-03 20:46 ` Stephen Boyd
2024-01-03 22:25 ` Mark Hasemeyer
2024-01-03 22:45 ` Mark Hasemeyer
2024-01-04 0:38 ` Stephen Boyd
2024-01-04 0:29 ` Stephen Boyd
2024-01-04 4:55 ` Mark Hasemeyer
2024-01-08 19:07 ` Stephen Boyd
2024-01-08 19:56 ` Mark Hasemeyer
2024-01-08 20:47 ` Stephen Boyd
2024-01-22 9:14 ` [PATCH v4 00/24] Improve IRQ wake capability reporting and update the cros_ec driver to use it Matthias Brugger
2024-01-22 9:14 ` Matthias Brugger
2024-02-14 17:57 ` (subset) " Bjorn Andersson
2024-02-14 17:57 ` Bjorn Andersson
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=ZaPp4yVQ44J7HJB2@smile.fi.intel.com \
--to=andriy.shevchenko@intel.com \
--cc=angelogioacchino.delregno@collabora.com \
--cc=broonie@kernel.org \
--cc=davidgow@google.com \
--cc=gregkh@linuxfoundation.org \
--cc=konrad.dybcio@linaro.org \
--cc=krzysztof.kozlowski@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=markhas@chromium.org \
--cc=rafael@kernel.org \
--cc=robh@kernel.org \
--cc=rrangel@chromium.org \
--cc=sudeep.holla@arm.com \
--cc=tiwai@suse.de \
--cc=tzungbi@kernel.org \
--cc=u.kleine-koenig@pengutronix.de \
/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.