[PATCH] Evaluate syscall parameters on ARM LOAD_ARGS_x macros

Khem Raj kraj at mvista.com
Thu Mar 27 08:57:02 UTC 2008


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi

While compiling uclibc on thumb and running LTP tests on it I noticed
that the sched_setaffinity system calls were failing. The reason is that
when the parameters to syscall macros on ARM contain function calls, gcc
places the calls to evaluate the parameters at the very end just before
the system call instruction (SVC) is called.
This corrupts the registers that has been set up for the system call.

This patch evaluates the arguments in LOAD_ARGS_x macros and also
separates declaration to make it more PPC like. Thanks to Daniel
Jacobowitz for this suggestion.

OK ?

- --
Khem Raj
MontaVista Software Inc.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFH62FZUjbQJxVzeZQRAsL4AJ9d/5tq7oI5j83WGV4A6X+RNffr4ACcCxSs
umaI9CW4WfDAxndSPjGwEwg=
=wr+D
-----END PGP SIGNATURE-----
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: uclibc-arm-thumb-loadargs-macro.diff
Url: http://lists.busybox.net/pipermail/uclibc/attachments/20080327/67327023/attachment.diff 


More information about the uClibc mailing list