From: Thorsten Scherer <T.Scherer@eckelmann.de>
To: Oleksij Rempel <o.rempel@pengutronix.de>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH v2 1/2] ARM: i.MX8MP: skov: add fallback for unsupported HW
Date: Wed, 3 Apr 2024 06:00:56 +0200 [thread overview]
Message-ID: <raghvrf6akiqagwlod3s65ilcfawb43slshzljngl77rnaf27l@cvxmvo7iqokx> (raw)
In-Reply-To: <20240402092654.94523-1-o.rempel@pengutronix.de>
Hi Oleksij,
I spotted some typos.
On Tue, Apr 02, 2024 at 11:26:53AM +0200, Oleksij Rempel wrote:
> Add fallback support for currently not supported HW. Instead of
> completely fail, it is better to use some kind of basic devicetree with
> reduced functionality.
>
> Signed-off-by: Oleksij Rempel <o.rempel@pengutronix.de>
> ---
> arch/arm/boards/skov-imx8mp/board.c | 12 ++++++++----
> 1 file changed, 8 insertions(+), 4 deletions(-)
>
> diff --git a/arch/arm/boards/skov-imx8mp/board.c b/arch/arm/boards/skov-imx8mp/board.c
> index 3b6eb7b080..41122ea1e4 100644
> --- a/arch/arm/boards/skov-imx8mp/board.c
> +++ b/arch/arm/boards/skov-imx8mp/board.c
> @@ -85,6 +85,10 @@ static const struct board_description imx8mp_variants[] = {
> },
> };
>
> +static const struct board_description imx8mp_basic_viariant = {
s/imx8mp_basic_viariant/imx8mp_basic_variant/
> + .dts_compatible = "skov,imx8mp-skov-basic",
> +};
> +
> static int skov_imx8mp_fixup(struct device_node *root, void *data)
> {
> struct device_node *chosen = of_create_node(root, "/chosen");
> @@ -171,12 +175,12 @@ static int skov_imx8mp_init_variant(struct skov_imx8mp_priv *priv)
> priv->variant_id = v;
>
> if (v >= ARRAY_SIZE(imx8mp_variants)) {
> - dev_err(dev, "Invalid variant %u\n", v);
> - return -EINVAL;
> + dev_warn(dev, "Unsuported variant %u. Fall back to basic variant\n", v);
s/Unsuported/Unsupported/
> + variant = &imx8mp_basic_viariant;
s/imx8mp_basic_viariant/imx8mp_basic_variant/
> + } else {
> + variant = &imx8mp_variants[v];
> }
>
> - variant = &imx8mp_variants[v];
> -
> if (variant->flags & SKOV_IMX8MP_HAS_HDMI) {
> ret = skov_imx8mp_get_hdmi(dev);
> if (ret < 0)
> --
> 2.39.2
>
>
Best regards
Thorsten
next prev parent reply other threads:[~2024-04-03 4:02 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-04-02 9:26 Oleksij Rempel
2024-04-02 9:26 ` [PATCH v2 2/2] ARM: i.MX8MP: skov: add new bd500 variant support Oleksij Rempel
2024-04-03 4:00 ` Thorsten Scherer [this message]
2024-04-03 4:29 ` [PATCH v2 1/2] ARM: i.MX8MP: skov: add fallback for unsupported HW Oleksij Rempel
2024-04-03 11:29 ` Sascha Hauer
2024-04-03 11:28 ` Sascha Hauer
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=raghvrf6akiqagwlod3s65ilcfawb43slshzljngl77rnaf27l@cvxmvo7iqokx \
--to=t.scherer@eckelmann.de \
--cc=barebox@lists.infradead.org \
--cc=o.rempel@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox