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] [day] [month] [year] [list]
Date:	Fri, 11 Jan 2008 10:15:03 +0100
From:	Jens Axboe <jens.axboe@...cle.com>
To:	Rusty Russell <rusty@...tcorp.com.au>
Cc:	Tejun Heo <htejun@...il.com>,
	James Bottomley <James.Bottomley@...senpartnership.com>,
	linux-scsi@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] Don't blatt first element of prv in sg_chain()

On Mon, Jan 07 2008, Rusty Russell wrote:
> I realize that sg chaining is a ploy to make the rest of the kernel
> devs feel the pain of the SCSI subsystem.  But this was a little
> unsubtle.
> 
> Signed-off-by: Rusty Russell <rusty@...tcorp.com.au>
> 
> diff -r b3aec596b841 include/linux/scatterlist.h
> --- a/include/linux/scatterlist.h	Mon Jan 07 12:43:56 2008 +1100
> +++ b/include/linux/scatterlist.h	Mon Jan 07 15:01:51 2008 +1100
> @@ -188,8 +188,8 @@ static inline void sg_chain(struct scatt
>  	/*
>  	 * offset and length are unused for chain entry.  Clear them.
>  	 */
> -	prv->offset = 0;
> -	prv->length = 0;
> +	prv[prv_nents - 1].offset = 0;
> +	prv[prv_nents - 1].length = 0;
>  
>  	/*
>  	 * Set lowest bit to indicate a link pointer, and make sure to clear

Dang, I should have caught that. Thanks Rusty...

-- 
Jens Axboe

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ