Re: [PATCH v2 3/3] hwmon: (gpd-fan): upgrade log level from warn to err for platform device creation failure

From: Pei Xiao

Date: Wed May 27 2026 - 05:34:05 EST




在 2026/5/27 16:10, xiaopeitux@xxxxxxxxxxx 写道:
> From: Pei Xiao <xiaopei01@xxxxxxxxxx>
>
> When platform_create_bundle() fails, the error is fatal and prevents the
> driver from loading. Use pr_err() instead of pr_warn() to clearly indicate
> a critical failure.
>
> Signed-off-by: Pei Xiao <xiaopei01@xxxxxxxxxx>
> ---
> drivers/hwmon/gpd-fan.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/hwmon/gpd-fan.c b/drivers/hwmon/gpd-fan.c
> index 745b3fb9e3a4..b18725f4d108 100644
> --- a/drivers/hwmon/gpd-fan.c
> +++ b/drivers/hwmon/gpd-fan.c
> @@ -712,7 +712,7 @@ static int __init gpd_fan_init(void)
> match, sizeof(*match));
>
> if (IS_ERR(gpd_fan_platform_device)) {
> - pr_warn("Failed to create platform device\n");
> + pr_error("Failed to create platform device\n");
V1 not have  have this build errro ! But V2 have ! oh my god!
We will send a new thread!
> return PTR_ERR(gpd_fan_platform_device);
> }
>