Re: [PATCH] newlib/libc/sys/rtems/include/machine/param.h: Add _KERNEL to stop method leakage

Corinna Vinschen <[email protected]>
Newsgroups gmane.comp.lib.newlib
Message-ID <[email protected]>
On Oct 18 18:31, Joel Sherrill wrote:
> The following FreeBSD kernel methods are not in any standard and
> prototypes/definitions were leaking into application space:
> 
>   + round_page()
>   + trunc_page()
>   + atop()
>   + ptoa()
>   + pgtok()
> ---
>  newlib/libc/sys/rtems/include/machine/param.h | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/newlib/libc/sys/rtems/include/machine/param.h b/newlib/libc/sys/rtems/include/machine/param.h
> index 4892b61..e37d056 100644
> --- a/newlib/libc/sys/rtems/include/machine/param.h
> +++ b/newlib/libc/sys/rtems/include/machine/param.h
> @@ -71,6 +71,7 @@
>  
>  #define	MAXPAGESIZES	1		/* maximum number of supported page sizes */
>  
> +#ifdef _KERNEL
>  /*
>   * Mach derived conversion macros
>   */
> @@ -82,4 +83,6 @@
>  
>  #define	pgtok(x)		((unsigned long)(x) * (PAGE_SIZE / 1024))
>  
> +#endif
> +
>  #endif /* !_MACHINE_PARAM_H_ */
> -- 
> 1.8.3.1

Please push.


Thanks,
Corinna

-- 
Corinna Vinschen
Cygwin Maintainer
Red Hat
signature.asc (application/pgp-signature, 833 B)
-----BEGIN PGP SIGNATURE-----

iQIzBAEBCAAdFiEEoVYPmneWZnwT6kwF9TYGna5ET6AFAlvJmz0ACgkQ9TYGna5E
T6CyGQ//Q2mbA905Au+a2h/19yllDnMI/LRs32dPiNPCEdGdr+AL5fN22QunpiQB
lcNgqbSZra2bAfffKCOgYbJY96yQxdXAmUQ4pYCe8XccXhzqhq5J9m7cusXTOVWD
R1lvw5ZXudAUU+e+pmAtXNOG/VV2aAj4hCtMkyKjcnpnwodjWBqTPEOyO4pcD8oa
zUQfuhcdrH0iQOm37iChYZmQbyhN47KN2ElyNYUFFSJueGvYw1iT4B35p7drkGaX
EYxh2ldGlOIMrB1hRd3fLSOGuIEzkrmrhyjPcsm5UCct7MZ6WgA5Ti+JyHsywXod
fdp9uepmdhybiO9EFeB9ySeBPuATn/0834gsSgjm9dn3q17ADKwKlNIVEqR3yUFV
90RCUb7ofiLvsui3R5k6/4BHfmheIzOuydt3IVnlywcV7mv/wlvrfV0Yf4GuMM/6
DScZu/UUaFy495KmiALzi7g/KyLtPyxox/QjaINj24wPNZzy0J6yn2Y0c0YWTFAa
Y61n96V7XbWQkMRNOCqLlybdZZvQNb8c8iEM0UCCIetmWOX2oeTrn0dVBwFkXYHm
pNtRFNxvOyEVua55roZTaw/G5yS/Hasr8oWNSidVsGip/QCWL3ACsZx0LHTqYahu
wVynFEjTOSyYqCzWF6DWKf6tZZRsD5nPQvHgZZtuAVBwKx2Rz9k=
=IRV3
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.