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] [day] [month] [year] [list]
Date:	Mon, 4 May 2009 12:32:22 +0200
From:	Arnd Bergmann <arnd@...db.de>
To:	monstr@...str.eu
Cc:	linux-arch@...r.kernel.org,
	Remis Lima Baima <remis.developer@...glemail.com>,
	linux-kernel@...r.kernel.org,
	Russell King <rmk+lkml@....linux.org.uk>
Subject: Re: [PATCH V3] asm-generic: add a generic uaccess.h

On Monday 04 May 2009, Michal Simek wrote:
> #define MAKE_MM_SEG(s)  ((mm_segment_t) { (s) })
> 
> #ifndef KERNEL_DS
> #define KERNEL_DS       MAKE_MM_SEG(~0UL)
> #endif
> 
> #ifndef USER_DS
> #define USER_DS         MAKE_MM_SEG(TASK_SIZE - 1)
> #endif
> 
> 
> #ifndef get_fs
> #define get_ds() (KERNEL_DS)
> #define get_fs() (current_thread_info()->addr_limit)
> 
> static inline void set_fs(mm_segment_t fs)
> {
>         current_thread_info()->addr_limit = fs;
> }
> #endif
> 

yes, looks good. Thanks for the suggestion.

	Arnd <><
--
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