lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <2df6f002-dcf8-1073-d0b5-a9843103096a@collabora.com>
Date:   Thu, 13 Apr 2023 23:36:59 +0300
From:   Dmitry Osipenko <dmitry.osipenko@...labora.com>
To:     Benjamin Bara <bbara93@...il.com>, Wolfram Sang <wsa@...nel.org>,
        Lee Jones <lee@...nel.org>, rafael.j.wysocki@...el.com
Cc:     peterz@...radead.org, jonathanh@...dia.com,
        richard.leitner@...ux.dev, treding@...dia.com,
        linux-kernel@...r.kernel.org, linux-i2c@...r.kernel.org,
        linux-tegra@...r.kernel.org,
        Benjamin Bara <benjamin.bara@...data.com>
Subject: Re: [PATCH v4 3/4] mfd: tps6586x: use devm-based power off handler

On 4/13/23 10:46, Benjamin Bara wrote:
> +static int tps6586x_power_off_handler(struct sys_off_data *data)
>  {
> -	if (tps6586x_clr_bits(tps6586x_dev, TPS6586X_SUPPLYENE, EXITSLREQ_BIT))
> -		return;
> +	struct device *tps6586x_dev = data->cb_data;
> +	int ret;
> +
> +	ret = tps6586x_clr_bits(tps6586x_dev, TPS6586X_SUPPLYENE, EXITSLREQ_BIT);
> +	if (ret)
> +		return ret;
>  
> -	tps6586x_set_bits(tps6586x_dev, TPS6586X_SUPPLYENE, SLEEP_MODE_BIT);
> +	return tps6586x_set_bits(tps6586x_dev, TPS6586X_SUPPLYENE, SLEEP_MODE_BIT);

Handlers must return NOTIFY_DONE or notifier_from_errno(). Sorry for
missing this previously.

-- 
Best regards,
Dmitry

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ