Linux-Hwmon Archive on lore.kernel.org
 help / color / Atom feed
From: Guenter Roeck <linux@roeck-us.net>
To: Christian Schneider <cschneider@radiodata.biz>
Cc: linux-hwmon@vger.kernel.org
Subject: Re: [PATCHv2] hwmon, gpio-fan: fix that sysfs_notify in void fan_alarm_notify is not received in userspace
Date: Sat, 15 Jun 2019 06:17:56 -0700
Message-ID: <aedff3d4-1cb7-0228-121e-9e49341f19ea@roeck-us.net> (raw)
In-Reply-To: <e5390907-9112-4aca-e2e8-acf4097bf941@radiodata.biz>

On 6/14/19 8:35 AM, Christian Schneider wrote:
> Alarms on gpio-fan can't be received from sysfs_notify, because the wrong kobject is passed.
> This patch fixes this.
> 
> Signed-off-by: Christian Schneider <cschneider@radiodata.biz>
> ---
> diff --git a/drivers/hwmon/gpio-fan.c b/drivers/hwmon/gpio-fan.c
> index 84753680a4e8..76377791ff0e 100644
> --- a/drivers/hwmon/gpio-fan.c
> +++ b/drivers/hwmon/gpio-fan.c
> @@ -54,8 +54,8 @@ static void fan_alarm_notify(struct work_struct *ws)
>          struct gpio_fan_data *fan_data =
>                  container_of(ws, struct gpio_fan_data, alarm_work);
> 
> -       sysfs_notify(&fan_data->dev->kobj, NULL, "fan1_alarm");
> -       kobject_uevent(&fan_data->dev->kobj, KOBJ_CHANGE);
> +       sysfs_notify(&fan_data->hwmon_dev->kobj, NULL, "fan1_alarm");
> +       kobject_uevent(&fan_data->hwmon_dev->kobj, KOBJ_CHANGE);
>   }
> 
>   static irqreturn_t fan_alarm_irq_handler(int irq, void *dev_id)
> 
The patch is whitespace damaged (cut-and-paste, maybe ?) and does not apply.
Can you send it with git send-email, possibly ?

Thanks,
Guenter

  reply index

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-14 13:52 [PATCH] " Christian Schneider
2019-06-14 14:05 ` Guenter Roeck
2019-06-14 14:16   ` Christian Schneider
2019-06-14 14:52     ` Guenter Roeck
2019-06-14 15:35       ` [PATCHv2] " Christian Schneider
2019-06-15 13:17         ` Guenter Roeck [this message]
2019-06-17  9:36           ` Christian Schneider
2019-06-14 15:37       ` [PATCH] " Christian Schneider

Reply instructions:

You may reply publically 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=aedff3d4-1cb7-0228-121e-9e49341f19ea@roeck-us.net \
    --to=linux@roeck-us.net \
    --cc=cschneider@radiodata.biz \
    --cc=linux-hwmon@vger.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

Linux-Hwmon Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-hwmon/0 linux-hwmon/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-hwmon linux-hwmon/ https://lore.kernel.org/linux-hwmon \
		linux-hwmon@vger.kernel.org linux-hwmon@archiver.kernel.org
	public-inbox-index linux-hwmon


Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-hwmon


AGPL code for this site: git clone https://public-inbox.org/ public-inbox