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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Mon, 17 Jun 2024 12:56:01 -0600
From: Keith Busch <kbusch@...nel.org>
To: John Garry <john.g.garry@...cle.com>
Cc: axboe@...nel.dk, hch@....de, sagi@...mberg.me, jejb@...ux.ibm.com,
	martin.petersen@...cle.com, viro@...iv.linux.org.uk,
	brauner@...nel.org, dchinner@...hat.com, jack@...e.cz,
	djwong@...nel.org, linux-block@...r.kernel.org,
	linux-kernel@...r.kernel.org, linux-nvme@...ts.infradead.org,
	linux-fsdevel@...r.kernel.org, tytso@....edu, jbongio@...gle.com,
	linux-scsi@...r.kernel.org, ojaswin@...ux.ibm.com,
	linux-aio@...ck.org, linux-btrfs@...r.kernel.org,
	io-uring@...r.kernel.org, nilay@...ux.ibm.com,
	ritesh.list@...il.com, willy@...radead.org, agk@...hat.com,
	snitzer@...nel.org, mpatocka@...hat.com, dm-devel@...ts.linux.dev,
	hare@...e.de, Himanshu Madhani <himanshu.madhani@...cle.com>
Subject: Re: [PATCH v8 05/10] block: Add core atomic write support

On Mon, Jun 10, 2024 at 10:43:24AM +0000, John Garry wrote:
> +static void blk_validate_atomic_write_limits(struct queue_limits *lim)
> +{
> +	unsigned int boundary_sectors_hw;
> +
> +	if (!lim->atomic_write_hw_max)
> +		goto unsupported;
> +
> +	boundary_sectors_hw = lim->atomic_write_hw_boundary >> SECTOR_SHIFT;
> +
> +	if (boundary_sectors_hw) {
> +		/* It doesn't make sense to allow different non-zero values */
> +		if (lim->chunk_sectors &&
> +		    lim->chunk_sectors != boundary_sectors_hw)
> +			goto unsupported;

I'm not sure I follow why these two need to be the same. I can see
checking for 'chunk_sectors % boundary_sectors_hw == 0', but am I
missing something else?

The reason I ask, zone block devices redefine the "chunk_sectors" to
mean the zone size, and I'm pretty sure the typical zone size is much
larger than the any common atomic write size.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ