Bug#951237: glibc/mips: bpo patch: mips: Fix argument passing for inlined syscalls on Linux [BZ #25523]

2020-02-13 Thread Aurelien Jarno
On 2020-02-13 10:52, YunQiang Su wrote:
> Package: src:glibc
> Version: 2.29
> Severity: serious
> 
> https://sourceware.org/bugzilla/show_bug.cgi?id=25523
> https://sourceware.org/git/?p=glibc.git;a=commit;h=4fbba6fe904d0094ddc4284066b3860d119cbd4a
> 
> mips: Fix argument passing for inlined syscalls on Linux [BZ #25523]
> 

Note that Debian is currently not affected by the issue, at least for
that syscall, probably because we use a different baseline ISA (ie
MIPS64R2).

I have backported the issue upstream in version 2.31. Backporting it
into 2.30 requires a tiny bit more of work and testing, I'll do that in
the next days. Note that we are waiting for the green light from the
release team to upload 2.30 to unstable, so there is no need to fix
version 2.29.

Aurelien

-- 
Aurelien Jarno  GPG: 4096R/1DDD8C9B
aurel...@aurel32.net http://www.aurel32.net



Bug#951237: glibc/mips: bpo patch: mips: Fix argument passing for inlined syscalls on Linux [BZ #25523]

2020-02-12 Thread YunQiang Su
Package: src:glibc
Version: 2.29
Severity: serious

https://sourceware.org/bugzilla/show_bug.cgi?id=25523
https://sourceware.org/git/?p=glibc.git;a=commit;h=4fbba6fe904d0094ddc4284066b3860d119cbd4a

mips: Fix argument passing for inlined syscalls on Linux [BZ #25523]

According to [gcc documentation][1], temporary variables must be used for
the desired content to not be call-clobbered.

Fix the Linux inline syscall templates by adding temporary variables,
much like what x86 did before
(commit 381a0c26d73e0f074c962e0ab53b99a6c327066d).

Tested with gcc 9.2.0, both cross-compiled and natively on Loongson
3A4000.

[1]: https://gcc.gnu.org/onlinedocs/gcc/Local-Register-Variables.html