[LTP] [PATCH] syscalls/statmount07: drop "invalid buffer size" test

Cyril Hrubis chrubis@suse.cz
Tue Oct 15 11:50:55 CEST 2024


Hi!
> The manpage doesn't say that 'smbuf' needs to be valid
> for entire range of 'bufsize'.
> 
> This check relies on access_ok() check, which can be skipped
> on some arches/configs, for example on s390x with
> CONFIG_ALTERNATE_USER_ADDRESS_SPACE=y. Test then fails with:
>   statmount07.c:117: TFAIL: invalid buffer size succeeded

And does it fail later on in the copy_to_user() if the buffer is
physically not accesible?

We may add a test that would look like:

| page mapped rw | page mapped read only |
             ^
	     buf pointer starts here

What do you think?

-- 
Cyril Hrubis
chrubis@suse.cz


More information about the ltp mailing list