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]
Message-Id: <1541789329.305173.1571657968.7229F301@webmail.messagingengine.com>
Date:   Fri, 09 Nov 2018 16:48:49 -0200
From:   Rafael David Tinoco <rafael.tinoco@...aro.org>
To:     Cyrill Gorcunov <gorcunov@...il.com>
Cc:     adobriyan@...il.com, akpm@...ux-foundation.org,
        linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-kselftest@...r.kernel.org, shuah@...nel.org
Subject: Re: [PATCH] proc: fix and merge proc-self-map-file tests

On Fri, Nov 9, 2018, at 4:04 PM, Cyrill Gorcunov wrote:
> On Fri, Nov 09, 2018 at 10:01:13AM -0200, Rafael David Tinoco wrote:
> > 
> > Alright, I'm fixing membarrier_test before, so.. I guess we have a competition.. =o)
> 
> Rafael, Alexey, what about simply wrap the test code with x86 and extend later
> with all archs which support zero address mapping?
> ---
>  tools/testing/selftests/proc/proc-self-map-files-002.c |   14 ++++++++++++++
>  1 file changed, 14 insertions(+)
> 
> Index: linux-ml.git/tools/testing/selftests/proc/proc-self-map-files-002.c
> ===================================================================
> --- linux-ml.git.orig/tools/testing/selftests/proc/proc-self-map-files-002.c
> +++ linux-ml.git/tools/testing/selftests/proc/proc-self-map-files-002.c
> @@ -23,6 +23,11 @@
>  #include <sys/mman.h>
>  #include <stdlib.h>
>  
> +/*
> + * Should run on archs which support zero address mapping.
> + */
> +#if defined(__i386) || defined(__x86_64)
> +
>  static void pass(const char *fmt, unsigned long a, unsigned long b)
>  {
>  	char name[64];
> @@ -83,3 +88,12 @@ int main(void)
>  
>  	return 0;
>  }
> +
> +#else
> +
> +int main(void)
> +{
> +	return 0;
> +}
> +
> +#endif

let me see if I got this right.. the premise for this test is to have *at least*
2 vmas, so we can check if the symlink for the mem range, describing the mapped
area, is correct in procfs files, correct ? if yes, then why to have a totally
duplicated test... just to check if mmap(0, ... MAP_FIXED ...) would work ?

Wouldn't exist a better place to have such test ? like in
tools/testing/selftests/vm/mmap-null.c or something like it ?  genuine
curiosity.. thinking i'm missing something about this test...

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ