Linux Hardware Monitor development
 help / color / mirror / Atom feed
From: "Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>
To: Armin Wolf <W_Armin@gmx.de>
Cc: james@equiv.tech, jlee@suse.com, corentin.chary@gmail.com,
	luke@ljones.dev,  matan@svgalib.org, coproscefalo@gmail.com,
	 Hans de Goede <hdegoede@redhat.com>,
	linux@roeck-us.net, jdelvare@suse.com,
	 "Rafael J. Wysocki" <rafael@kernel.org>,
	lenb@kernel.org,  platform-driver-x86@vger.kernel.org,
	linux-hwmon@vger.kernel.org,  linux-acpi@vger.kernel.org,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v2 1/5] hwmon: (hp-wmi-sensors) Check if WMI event data exists
Date: Mon, 2 Sep 2024 17:09:26 +0300 (EEST)	[thread overview]
Message-ID: <c474bfef-a4d4-f1f5-463d-04ed6f69818e@linux.intel.com> (raw)
In-Reply-To: <20240901031055.3030-2-W_Armin@gmx.de>

[-- Attachment #1: Type: text/plain, Size: 1000 bytes --]

On Sun, 1 Sep 2024, Armin Wolf wrote:

> The BIOS can choose to return no event data in response to a
> WMI event, so the ACPI object passed to the WMI notify handler
> can be NULL.
> 
> Check for such a situation and ignore the event in such a case.
> 
> Fixes: 23902f98f8d4 ("hwmon: add HP WMI Sensors driver")
> Signed-off-by: Armin Wolf <W_Armin@gmx.de>

Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>

-- 
 i.


> ---
>  drivers/hwmon/hp-wmi-sensors.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/hwmon/hp-wmi-sensors.c b/drivers/hwmon/hp-wmi-sensors.c
> index b5325d0e72b9..dfa1d6926dea 100644
> --- a/drivers/hwmon/hp-wmi-sensors.c
> +++ b/drivers/hwmon/hp-wmi-sensors.c
> @@ -1637,6 +1637,8 @@ static void hp_wmi_notify(u32 value, void *context)
>  		goto out_unlock;
> 
>  	wobj = out.pointer;
> +	if (!wobj)
> +		goto out_unlock;
> 
>  	err = populate_event_from_wobj(dev, &event, wobj);
>  	if (err) {
> --
> 2.39.2
> 

  reply	other threads:[~2024-09-02 14:09 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-01  3:10 [PATCH v2 0/5] platform/x86: wmi: Pass event data directly to legacy notify handlers Armin Wolf
2024-09-01  3:10 ` [PATCH v2 1/5] hwmon: (hp-wmi-sensors) Check if WMI event data exists Armin Wolf
2024-09-02 14:09   ` Ilpo Järvinen [this message]
2024-09-02 14:28   ` Guenter Roeck
2024-09-04 17:55     ` Hans de Goede
2024-09-04 18:38       ` Guenter Roeck
2024-09-04 18:42         ` Hans de Goede
2024-09-04 19:40           ` Guenter Roeck
2024-09-01  3:10 ` [PATCH v2 2/5] platform/x86: wmi: Pass event data directly to legacy notify handlers Armin Wolf
2024-09-01  3:10 ` [PATCH v2 3/5] platform/x86: wmi: Remove wmi_get_event_data() Armin Wolf
2024-09-01  3:10 ` [PATCH v2 4/5] platform/x86: wmi: Merge get_event_data() with wmi_get_notify_data() Armin Wolf
2024-09-01  3:10 ` [PATCH v2 5/5] platform/x86: wmi: Call both legacy and WMI driver notify handlers Armin Wolf
2024-09-05 15:31 ` [PATCH v2 0/5] platform/x86: wmi: Pass event data directly to legacy " Hans de Goede

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=c474bfef-a4d4-f1f5-463d-04ed6f69818e@linux.intel.com \
    --to=ilpo.jarvinen@linux.intel.com \
    --cc=W_Armin@gmx.de \
    --cc=coproscefalo@gmail.com \
    --cc=corentin.chary@gmail.com \
    --cc=hdegoede@redhat.com \
    --cc=james@equiv.tech \
    --cc=jdelvare@suse.com \
    --cc=jlee@suse.com \
    --cc=lenb@kernel.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-hwmon@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@roeck-us.net \
    --cc=luke@ljones.dev \
    --cc=matan@svgalib.org \
    --cc=platform-driver-x86@vger.kernel.org \
    --cc=rafael@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