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:	Fri, 13 Nov 2015 15:57:33 -0500
From:	Jeff Moyer <jmoyer@...hat.com>
To:	Hannes Reinecke <hare@...e.de>
Cc:	Jens Axboe <axboe@...com>, Alexander Graf <agraf@...e.com>,
	Christoph Hellwig <hch@....de>,
	Ming Lei <tom.leiming@...il.com>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/4] loop: Enable correct physical blocksize

Hi Hannes,

Hannes Reinecke <hare@...e.de> writes:

> When running on files the physical blocksize is actually 4k,

How did you come to that conclusion?  Are you basing it on the file
system block size?  If so, that's configurable at mkfs time and can be
anything from 512 bytes to 64k on current in-tree file systems that I
know of (depending on platform, of course).

The main use for physical block size, as I understand it, is to allow
partitioning utilities to place partitions on physical block boundaries
of the underlying storage.  The benefit of that is to avoid
read-modify-writes for I/O which is naturally sized and aligned.  If we
carry that forward to loop, then I think it does makes sense to key off
of the file system block size, but the fact remains that 4k is not
universal.

So, I think the idea is sound, but you should be setting the physical
block size to sb->s_blocksize.  And I don't see any reason why we
wouldn't do this by default, do you?

If you end up reposting this patch, would you mind including more of
this rationale in your commit message?

Thanks!
Jeff
--
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