mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Marek Vasut <marex@denx.de>
To: Saravana Kannan <saravanak@google.com>
Cc: linux-arm-kernel@lists.infradead.org, kernel@dh-electronics.com,
	AngeloGioacchino Del Regno
	<angelogioacchino.delregno@collabora.com>,
	Arnd Bergmann <arnd@arndb.de>, Fabio Estevam <festevam@gmail.com>,
	Jeff Johnson <quic_jjohnson@quicinc.com>,
	Neil Armstrong <neil.armstrong@linaro.org>,
	Pengutronix Kernel Team <kernel@pengutronix.de>,
	Sascha Hauer <s.hauer@pengutronix.de>,
	Shawn Guo <shawnguo@kernel.org>,
	imx@lists.linux.dev, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 1/2] soc: imx8m: Probe the SoC driver as platform driver
Date: Sun, 29 Sep 2024 20:47:36 +0200	[thread overview]
Message-ID: <51a87d3e-7a9c-4709-ab64-d869dca28b0a@denx.de> (raw)
In-Reply-To: <CAGETcx95ZMBJR0F-3Cr8++1_MwiMCPHiwfdx7m5q0XDAiGG75A@mail.gmail.com>

On 9/28/24 12:27 AM, Saravana Kannan wrote:

[...]

>>> I'm glad it's working for you, but I think there might still be a race
>>> that you are just lucky enough to not hit. I think you still need to
>>> fix up drivers/base/soc.c to return -EPROBE_DEFER when
>>> soc_device_match() is called but soc_bus_type has no devices
>>> registered. That way any drivers that try to use that API will defer
>>> probe until this device gets to probe.
>>
>> soc_device_match() returns a pointer to soc_device_attribute or NULL, do
>> you have some other function in mind ?
> 
> No, I'm talking about the same function. I'm asking to change it to
> return ERR_PTR(-EPROBE_DEFER) instead
> of NULL if no soc device has been registered yet.
> 
> And you'll also go change all the drivers that use that API and are on
> the IMX boards supported by this soc driver, to handle the
> -EPROBE_DEFER correctly.
> 
> And this error will only get returned for boards that do async probing
> and using a platform device to register the soc device. So it's
> not going to break everyone if you do this change.
It seems the imx8m has no users of this, so I created a local patch, but 
I'll send a V4 of this series first.

      parent reply	other threads:[~2024-09-29 18:52 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-26 21:36 Marek Vasut
2024-09-26 21:36 ` [PATCH v3 2/2] soc: imx8m: Remove global soc_uid Marek Vasut
2024-09-27 16:58   ` Frank Li
2024-09-27 20:05     ` Marek Vasut
2024-09-26 23:39 ` [PATCH v3 1/2] soc: imx8m: Probe the SoC driver as platform driver Saravana Kannan
2024-09-27 11:56   ` Arnd Bergmann
2024-09-27 21:42   ` Marek Vasut
2024-09-27 22:27     ` Saravana Kannan
2024-09-28 14:09       ` Arnd Bergmann
2024-09-29 18:47       ` Marek Vasut [this message]

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=51a87d3e-7a9c-4709-ab64-d869dca28b0a@denx.de \
    --to=marex@denx.de \
    --cc=angelogioacchino.delregno@collabora.com \
    --cc=arnd@arndb.de \
    --cc=festevam@gmail.com \
    --cc=imx@lists.linux.dev \
    --cc=kernel@dh-electronics.com \
    --cc=kernel@pengutronix.de \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=neil.armstrong@linaro.org \
    --cc=quic_jjohnson@quicinc.com \
    --cc=s.hauer@pengutronix.de \
    --cc=saravanak@google.com \
    --cc=shawnguo@kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®