devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Guenter Roeck <linux@roeck-us.net>
To: Binbin Zhou <zhoubinbin@loongson.cn>
Cc: Binbin Zhou <zhoubb.aaron@gmail.com>,
	Huacai Chen <chenhuacai@loongson.cn>,
	Rob Herring <robh+dt@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Keguang Zhang <keguang.zhang@gmail.com>,
	Wim Van Sebroeck <wim@linux-watchdog.org>,
	Huacai Chen <chenhuacai@kernel.org>,
	Xuerui Wang <kernel@xen0n.name>,
	loongarch@lists.linux.dev, devicetree@vger.kernel.org,
	linux-watchdog@vger.kernel.org
Subject: Re: [PATCH v2 3/5] watchdog: loongson1: Drop CONFIG_OF
Date: Wed, 12 Nov 2025 15:54:01 -0800	[thread overview]
Message-ID: <74ea5501-e4ea-4dbc-8c94-a1ca5d4abc66@roeck-us.net> (raw)
In-Reply-To: <a374b938f2cc304b7e618bf22a5e8fa9f32e3efd.1762482089.git.zhoubinbin@loongson.cn>

On Fri, Nov 07, 2025 at 02:01:29PM +0800, Binbin Zhou wrote:
> The general recommendation is to not use of_match_ptr() or CONFIG_OF
> ifdef.
> 
> Drop them.
> 
> Signed-off-by: Binbin Zhou <zhoubinbin@loongson.cn>

Reviewed-by: Guenter Roeck <linux@roeck-us.net>

> ---
>  drivers/watchdog/loongson1_wdt.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/drivers/watchdog/loongson1_wdt.c b/drivers/watchdog/loongson1_wdt.c
> index 781f01f1f888..255198cbf5bf 100644
> --- a/drivers/watchdog/loongson1_wdt.c
> +++ b/drivers/watchdog/loongson1_wdt.c
> @@ -142,20 +142,18 @@ static int ls1x_wdt_probe(struct platform_device *pdev)
>  	return devm_watchdog_register_device(dev, &drvdata->wdt);
>  }
>  
> -#ifdef CONFIG_OF
>  static const struct of_device_id ls1x_wdt_dt_ids[] = {
>  	{ .compatible = "loongson,ls1b-wdt", },
>  	{ .compatible = "loongson,ls1c-wdt", },
>  	{ /* sentinel */ }
>  };
>  MODULE_DEVICE_TABLE(of, ls1x_wdt_dt_ids);
> -#endif
>  
>  static struct platform_driver ls1x_wdt_driver = {
>  	.probe = ls1x_wdt_probe,
>  	.driver = {
>  		.name = "ls1x-wdt",
> -		.of_match_table = of_match_ptr(ls1x_wdt_dt_ids),
> +		.of_match_table = ls1x_wdt_dt_ids,
>  	},
>  };
>  
> -- 
> 2.47.3
> 

  reply	other threads:[~2025-11-12 23:54 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-07  6:01 [PATCH v2 0/5] Watchdog: Add Loongson-2K0300 watchdog support Binbin Zhou
2025-11-07  6:01 ` [PATCH v2 1/5] watchdog: loongson1: Add missing MODULE_PARM_DESC Binbin Zhou
2025-11-12 23:53   ` Guenter Roeck
2025-11-07  6:01 ` [PATCH v2 2/5] watchdog: loongson1: Simplify ls1x_wdt_probe code Binbin Zhou
2025-11-12 23:53   ` Guenter Roeck
2025-11-07  6:01 ` [PATCH v2 3/5] watchdog: loongson1: Drop CONFIG_OF Binbin Zhou
2025-11-12 23:54   ` Guenter Roeck [this message]
2025-11-07  6:01 ` [PATCH v2 4/5] dt-bindings: watchdog: loongson,ls1x-wdt: Add ls2k0300-wdt compatible Binbin Zhou
2025-11-07 17:20   ` Conor Dooley
2025-11-12 23:54   ` Guenter Roeck
2025-11-07  6:01 ` [PATCH v2 5/5] watchdog: loongson1: Add Loongson-2k0300 watchdog support Binbin Zhou
2025-11-07  7:53   ` Huacai Chen
2025-11-12 23:55   ` Guenter Roeck
2025-11-16  4:00 ` [PATCH v2 0/5] Watchdog: Add Loongson-2K0300 " Keguang Zhang

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=74ea5501-e4ea-4dbc-8c94-a1ca5d4abc66@roeck-us.net \
    --to=linux@roeck-us.net \
    --cc=chenhuacai@kernel.org \
    --cc=chenhuacai@loongson.cn \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=keguang.zhang@gmail.com \
    --cc=kernel@xen0n.name \
    --cc=krzk+dt@kernel.org \
    --cc=linux-watchdog@vger.kernel.org \
    --cc=loongarch@lists.linux.dev \
    --cc=robh+dt@kernel.org \
    --cc=wim@linux-watchdog.org \
    --cc=zhoubb.aaron@gmail.com \
    --cc=zhoubinbin@loongson.cn \
    /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;
as well as URLs for NNTP newsgroup(s).