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]
Date:	Tue, 05 Apr 2016 17:04:05 +0200
From:	Johannes Thumshirn <jthumshirn@...e.de>
To:	Matias Bjørling <m@...rling.me>
Cc:	linux-block@...r.kernel.org, linux-kernel@...r.kernel.org,
	linux-block-owner@...r.kernel.org
Subject: Re: [PATCH 1/5] lightnvm: handle submit_io failure

On 2016-04-05 16:55, Matias Bjørling wrote:
> The device ->submit_io() callback might fail to submit I/O to device.
> In that case, the nvm_submit_ppa function should not wait for
> completion. Instead return the ->submit_io() error.
> 
> Signed-off-by: Matias Bjørling <m@...rling.me>
> ---
>  drivers/lightnvm/core.c | 5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/drivers/lightnvm/core.c b/drivers/lightnvm/core.c
> index 0dc9a80..c2ef53a 100644
> --- a/drivers/lightnvm/core.c
> +++ b/drivers/lightnvm/core.c
> @@ -351,6 +351,11 @@ int nvm_submit_ppa(struct nvm_dev *dev, struct
> ppa_addr *ppa, int nr_ppas,
>  	nvm_generic_to_addr_mode(dev, &rqd);
> 
>  	ret = dev->ops->submit_io(dev, &rqd);
> +	if (ret) {
> +		nvm_free_rqd_ppalist(dev, &rqd);
> +		bio_put(bio);
> +		return ret;
> +	}
> 
>  	/* Prevent hang_check timer from firing at us during very long I/O */
>  	hang_check = sysctl_hung_task_timeout_secs;

Looks good,
Reviewed-by: Johannes Thumshirn <jthumshirn@...e.de>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ