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: Wed, 15 Nov 2023 11:58:48 -0500
From: Linus Torvalds <>
To: David Howells <>
Cc: Christian Brauner <>, Jens Axboe <>, 
	Al Viro <>, Christoph Hellwig <>, 
	David Laight <>, Matthew Wilcox <>, 
	Brendan Higgins <>, David Gow <>,,,,,,,, 
	Andrew Morton <>, Christian Brauner <>, 
	David Hildenbrand <>, John Hubbard <>, 
	Huacai Chen <>, WANG Xuerui <>, 
	Heiko Carstens <>, Vasily Gorbik <>, 
	Alexander Gordeev <>, Christian Borntraeger <>, 
	Sven Schnelle <>,,
Subject: Re: [PATCH v3 05/10] iov_iter: Create a function to prepare userspace
 VM for UBUF/IOVEC tests

On Wed, 15 Nov 2023 at 11:39, David Howells <> wrote:
> I was trying to make it possible to do these tests before starting userspace
> as there's a good chance that if the UBUF/IOVEC iterators don't work right
> then your system can't be booted.

Oh, I don't think that any unit test should bother to check for that
kind of catastrophic case.

If something is so broken that the kernel doesn't boot properly even
into some basic test infrastructure, then bisection will trivially
find where that breakage was introduced.

And if it's something as core as the iov iterators, it won't even get
past the initial developer unless it's some odd build system

So extreme cases aren't even worth checking for. What's worth testing
is "the system boots and works, but I want to check the edge cases".

IOW, when it comes to things like user copies, it's things like
alignment, and the page fault edge cases with EFAULT in particular.
You can easily get the return value wrong for a user copy that ends up
with an unaligned fault at the end of the last mapped page. Everything
normal will still work fine, because nobody does something that odd.

But those are best handled as user mode tests.


Powered by blists - more mailing lists