[Qemu-devel] [PATCH 07/11] linux-user: Fix layout of usage table to account for option text

2013-03-11 Thread riku . voipio
calculating maxarglen as the width of the first column text including a possible option argument, and adjusting its uses to match. Signed-off-by: Peter Maydell Signed-off-by: Riku Voipio --- linux-user/main.c | 24 1 file changed, 16 insertions(+), 8 deletions(-) diff

[Qemu-devel] [PATCH 09/11] linux-user: Implement sendfile and sendfile64

2013-03-11 Thread riku . voipio
From: Peter Maydell Implement the sendfile and sendfile64 syscalls. This implementation passes all the LTP test cases for these syscalls. Signed-off-by: Peter Maydell Reviewed-by: Richard Henderson Signed-off-by: Riku Voipio --- configure| 17 linux-user

[Qemu-devel] [PATCH 11/11] linux-user/syscall.c: Don't warn about unimplemented get_robust_list

2013-03-11 Thread riku . voipio
already do for set_robust_list, and add a comment documenting why we do this. This silences warnings which were being produced for emulating even trivial programs like 'ls' in x86-64-on-x86-64. Signed-off-by: Peter Maydell Reviewed-by: Richard Henderson Signed-off-by: Riku Voipio ---

[Qemu-devel] [PATCH 06/11] linux-user: Add more sparc syscall numbers

2013-03-11 Thread riku . voipio
From: Dillon Amburgey Signed-off-by: Dillon Amburgey Signed-off-by: Riku Voipio --- linux-user/sparc/syscall_nr.h |2 ++ 1 file changed, 2 insertions(+) diff --git a/linux-user/sparc/syscall_nr.h b/linux-user/sparc/syscall_nr.h index 061711c..534e6e9 100644 --- a/linux-user/sparc

[Qemu-devel] [PATCH 08/11] linux-user: make bogus negative iovec lengths fail EINVAL

2013-03-11 Thread riku . voipio
From: Peter Maydell If the guest passes us a bogus negative length for an iovec, fail EINVAL rather than proceeding blindly forward. This fixes some of the error cases tests for readv and writev in the LTP. Signed-off-by: Peter Maydell Reviewed-by: Richard Henderson Signed-off-by: Riku Voipio

Re: [Qemu-devel] [PATCH] translate-all.c: memory walker initial address miscalculation

2014-10-01 Thread Riku Voipio
Hi, Applied to linux-user tree, I'll send a pull req after a bit of testing. Riku On Tue, Sep 30, 2014 at 05:58:43PM +0400, Mikhail Ilin wrote: > ping > > http://patchwork.ozlabs.org/patch/386918/ > > On 22.09.2014 13:04, Mikhail Ilin wrote: > >ping > > > >http://patchwork.ozlabs.org/patch/386

[Qemu-devel] [PULL 5/5] translate-all.c: memory walker initial address miscalculation

2014-10-06 Thread riku . voipio
mpile. The issue led to incorrect debug output of memory maps and a mis-formed coredumped file. Signed-off-by: Mikhail Ilyin Signed-off-by: Riku Voipio --- include/exec/cpu-all.h | 4 ++-- linux-user/elfload.c | 18 +- translate-all.c| 33

[Qemu-devel] [PULL 3/5] linux-user: Simplify timerid checks on g_posix_timers range

2014-10-06 Thread riku . voipio
masked it. We can safely remove the masking. For the negativity check we can just treat the timerid as unsigned and only check for upper boundaries. Signed-off-by: Alexander Graf Signed-off-by: Riku Voipio --- linux-user/syscall.c | 30 +- 1 file changed, 17 inserti

[Qemu-devel] [PULL 4/5] linux-user: don't include timerfd if not needed

2014-10-06 Thread riku . voipio
From: Riku Voipio Without this, builds on older systems fail with: qemu/linux-user/syscall.c:61:25: warning: sys/timerfd.h: No such file or directory Signed-off-by: Riku Voipio --- linux-user/syscall.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/linux-user/syscall.c b/linux-user

[Qemu-devel] [PULL 0/5] linux-user patches for 2.2

2014-10-06 Thread riku . voipio
From: Riku Voipio The following changes since commit 1831e150606a221898bf46ffaf0453e9952cbbc4: Merge remote-tracking branch 'remotes/bonzini/tags/for-upstream' into staging (2014-09-30 16:45:35 +0100) are available in the git repository at: git://git.linaro.org/people/r

[Qemu-devel] [PULL 2/5] linux-user: Convert blkpg to use a special subop handler

2014-10-06 Thread riku . voipio
From: Alexander Graf The blkpg ioctl can take different payloads depending on the opcode in its payload structure. Create a new special ioctl handler that can only deal with partition style ones for now. This patch fixes running parted for me. Signed-off-by: Alexander Graf Signed-off-by: Riku

[Qemu-devel] [PULL 1/5] linux-user: Enable epoll_pwait syscall for ARM

2014-10-06 Thread riku . voipio
From: Peter Maydell We have support for the epoll_pwait syscall, but it wasn't enabled for ARM guests because we hadn't defined the syscall number; correct this deficiency. Reported-by: Dave Flogeras Signed-off-by: Peter Maydell Signed-off-by: Riku Voipio --- linux-user/arm/syscal

Re: [Qemu-devel] [PULL 0/5] linux-user patches for 2.2

2014-10-06 Thread Riku Voipio
On Mon, Oct 06, 2014 at 05:49:14PM +0100, Peter Maydell wrote: > On 6 October 2014 15:59, Peter Maydell wrote: > > Hi. I'm afraid this doesn't compile on my ARM box: > > > > /root/qemu/linux-user/syscall.c: In function ‘do_syscall’: > > /root/qemu/linux-user/syscall.c:9695:9: error: implicit decla

[Qemu-devel] [PULL v2 2/5] linux-user: Convert blkpg to use a special subop handler

2014-10-06 Thread riku . voipio
From: Alexander Graf The blkpg ioctl can take different payloads depending on the opcode in its payload structure. Create a new special ioctl handler that can only deal with partition style ones for now. This patch fixes running parted for me. Signed-off-by: Alexander Graf Signed-off-by: Riku

[Qemu-devel] [PULL v2 3/5] linux-user: Simplify timerid checks on g_posix_timers range

2014-10-06 Thread riku . voipio
masked it. We can safely remove the masking. For the negativity check we can just treat the timerid as unsigned and only check for upper boundaries. Signed-off-by: Alexander Graf Signed-off-by: Riku Voipio --- linux-user/syscall.c | 30 +- 1 file changed, 17 inserti

[Qemu-devel] [PULL v2 1/5] linux-user: Enable epoll_pwait syscall for ARM

2014-10-06 Thread riku . voipio
From: Peter Maydell We have support for the epoll_pwait syscall, but it wasn't enabled for ARM guests because we hadn't defined the syscall number; correct this deficiency. Reported-by: Dave Flogeras Signed-off-by: Peter Maydell Signed-off-by: Riku Voipio --- linux-user/arm/syscal

[Qemu-devel] [PULL v2 5/5] translate-all.c: memory walker initial address miscalculation

2014-10-06 Thread riku . voipio
mpile. The issue led to incorrect debug output of memory maps and a mis-formed coredumped file. Signed-off-by: Mikhail Ilyin Signed-off-by: Riku Voipio --- include/exec/cpu-all.h | 4 ++-- linux-user/elfload.c | 18 +- translate-all.c| 33

[Qemu-devel] [PULL v2 0/5] linux-user patches for 2.2

2014-10-06 Thread riku . voipio
From: Riku Voipio The following changes since commit 2472b6c07bb50179019589af1c22f43935ab7f5c: gdbstub: Allow target CPUs to specify watchpoint STOP_BEFORE_ACCESS flag (2014-10-06 14:25:43 +0100) are available in the git repository at: git://git.linaro.org/people/riku.voipio/qemu.git

[Qemu-devel] [PULL v2 4/5] linux-user: don't include timerfd if not needed

2014-10-06 Thread riku . voipio
From: Riku Voipio Without this, builds on older systems fail with: qemu/linux-user/syscall.c:61:25: warning: sys/timerfd.h: No such file or directory v2: fix the usual case where CONFIG_TIMERFD is enabled.. Signed-off-by: Riku Voipio --- linux-user/syscall.c | 4 +++- 1 file changed, 3

Re: [Qemu-devel] [PATCH v3 00/13] TARGET_*_ALIGNMENT cleanup, and config-target.mak trimming

2013-04-18 Thread Riku Voipio
On Wed, Apr 17, 2013 at 04:26:34PM +0200, Paolo Bonzini wrote: > This series expands on the one I sent yesterday, but also fixes some > confusion between target (CPU) and ABI types in linux-user/elfload.c. I'm ok with the linux-user/ parts, you can send this set directly. > target_short/int/llong

Re: [Qemu-devel] [PATCH] linux-user: change do_semop to return target errno when unsuccessful

2013-04-19 Thread Riku Voipio
On 19 April 2013 12:42, Stefan Hajnoczi wrote: > On Thu, Mar 21, 2013 at 06:57:36PM +0100, Petar Jovanovic wrote: > > From: Petar Jovanovic > > > > do_semop() is called from two places, and one of these fails to convert > > return error to target errno when semop fails. This patch changes the >

[Qemu-devel] [PATCH 1/3] linux-user: change do_semop to return target errno when unsuccessful

2013-04-19 Thread riku . voipio
Signed-off-by: Riku Voipio --- linux-user/syscall.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/linux-user/syscall.c b/linux-user/syscall.c index 1f07621..d6d2050 100644 --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -2764,7 +2764,7 @@ static inline

[Qemu-devel] [PULL] [PATCH 0/3] linux-user pending patches

2013-04-19 Thread riku . voipio
From: Riku Voipio The following changes since commit 09dada400328d75daf79e3eca1e48e024fec148d: configure: remove duplicate test (2013-04-18 14:12:31 +0200) are available in the git repository at: git://git.linaro.org/people/rikuvoipio/qemu.git linux-user-for-upstream for you to fetch

[Qemu-devel] [PATCH 2/3] linux-user: fix undefined shift in copy_to_user_fdset

2013-04-19 Thread riku . voipio
From: Andreas Schwab If TARGET_ABI_BITS is bigger than 32 we shift by more than the size of int. Signed-off-by: Andreas Schwab Reviewed-by: Peter Maydell Signed-off-by: Riku Voipio --- linux-user/syscall.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/linux-user

[Qemu-devel] [PATCH 3/3] linux-user: fix setgroups/getgroups for non-UID16 archs

2013-04-19 Thread riku . voipio
From: Andreas Schwab Don't assume target_id is a short. Signed-off-by: Andreas Schwab Signed-off-by: Riku Voipio --- linux-user/syscall.c |6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/linux-user/syscall.c b/linux-user/syscall.c index 5a786f2..c705960 1

[Qemu-devel] ppc64-linux-user broken since "PPC: Unify dcbzl code path" ?

2013-04-21 Thread Riku Voipio
Hi, While testing my linux-user smoke-testing setup, I noticed that with current qemu head: ./ppc64-linux-user/qemu-ppc64 ../../qemu-smoke/ppc64/busybox ls busybox: malloc.c:3096: sYSMALLOc: Assertion `(old_top == (((mbinptr) (((char *) &((av)->bins[((1) - 1) * 2])) - __builtin_offsetof (struct

Re: [Qemu-devel] [PATCH] linux-user: fix compile error due to stray colon at end of #ifdef line

2013-04-21 Thread Riku Voipio
ef directive > [-Werror] > > Signed-off-by: Peter Maydell Acked-By: Riku Voipio > --- > Obviously this is 1.5 material; don't care whether it goes through > linux-user or qemu-trivial or direct commit. > > linux-user/syscall.c | 2 +- > 1 file changed, 1 insertion(+)

Re: [Qemu-devel] Environment variables for user-mode QEMU

2013-04-25 Thread Riku Voipio
Bcc: Subject: Re: [Qemu-devel] Environment variables for user-mode QEMU Reply-To: In-Reply-To: <87txmwoyqc@schwinge.name> X-message-flag: Warning: message not sent with a DRM-Certified client On Wed, Apr 24, 2013 at 03:16:27PM +0200, Thomas Schwinge wrote: > We have a need to pass environme

Re: [Qemu-devel] [PATCH] PPC: Fix dcbz for linux-user on 970

2013-04-26 Thread Riku Voipio
ser, so that we get 32 byte clears again. This fixes ppc64-linux-user for my smoke tests, thanks. Tested-By: > Reported-by: Riku Voipio > Signed-off-by: Alexander Graf > --- > target-ppc/mem_helper.c |2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) > > di

[Qemu-devel] [PATCH v3] signal/all: remove return value from restore_sigcontext

2014-06-09 Thread riku . voipio
From: Riku Voipio make most implementations of restore_sigcontext void and remove checking it's return value from functions calling restore_sigcontext. The exception is the X86 version of the function that is too different from others to deal in this way, and arm version, to keep possibili

[Qemu-devel] [PATCH v3] signal/all/do_sigreturn - remove __get_user checks

2014-06-09 Thread riku . voipio
From: Riku Voipio Remove "if(__get_user" checks and their related error paths for all architecture's do_sigreturn. Remove the unlock_user_struct when the only way to end up there is from failed lock_user_struct. v3: remove unneccesary sigsegv label as suggested by Peter Sign

Re: [Qemu-devel] [PATCH v2 00/13] linux-user: __{get, put}_user return value cleanup

2014-06-09 Thread Riku Voipio
On 8 June 2014 00:40, Peter Maydell wrote: > On 6 June 2014 10:46, wrote: >> From: Riku Voipio >> >> This series is a cleanup and gcc-4.9 buildfix: >> >> linux-user/syscall.c: In function ‘host_to_target_stat64’: >> linux-user/qemu.h:301:19: error: rig

[Qemu-devel] [PULL 13/18] linux-user: fix gcc-4.9 compiler error on __{get, put]}_user

2014-06-09 Thread riku . voipio
From: Riku Voipio gcc-4.9 finds unused operand: linux-user/syscall.c: In function ‘host_to_target_stat64’: linux-user/qemu.h:301:19: error: right-hand operand of comma expression has no effect [-Werror=unused-value] ((hptr), (x)), 0) Just removing the rh operand is no good, it will error

[Qemu-devel] [PULL 17/18] linux-user: Return correct errno for unsupported netlink socket

2014-06-09 Thread riku . voipio
From: Ed Swierk This fixes "Cannot open audit interface - aborting." when the EAFNOSUPPORT errno differs between the target and host architectures (e.g. mips target and x86_64 host). Signed-off-by: Ed Swierk Signed-off-by: Riku Voipio --- linux-user/syscall.c | 2 +- 1 file

[Qemu-devel] [PULL 02/18] signal/x86/setup_frame: __put_user cleanup

2014-06-09 Thread riku . voipio
From: Riku Voipio Remove the remaining check for __put_user return value, and all the checks for err variable which isn't set anywhere anymore. No we can only end up in give_sigsegv due to failed lock_user_struct - thus we remove the unlock_user_struct to avoid unlocking a region never l

[Qemu-devel] [PULL 10/18] signal/ppc/{save, restore}_user_regs remove __put/get error checks

2014-06-09 Thread riku . voipio
From: Riku Voipio As __get_user and __put_user do not return errors, remove the if checks from around them. This allows making the save/restore functions void. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell Cc: Alexander Graf --- linux-user/signal.c | 126

[Qemu-devel] [PULL 00/18] linux-user fixes

2014-06-09 Thread riku . voipio
From: Riku Voipio Mostly fixes, but a bigger rework in signal.c to allow compiling with gcc-4.9 The following changes since commit 959e41473f2179850578482052fb73b913bc4e42: slirp/arp: do not special-case bogus IP addresses (2014-06-09 01:49:28 +0200) are available in the git repository at

[Qemu-devel] [PULL 18/18] User mode support for Linux ELF files with no section header

2014-06-09 Thread riku . voipio
ith no section headers to be run properly in user mode: Signed-off-by: Craig Heffner Signed-off-by: Riku Voipio --- linux-user/elfload.c | 1 - 1 file changed, 1 deletion(-) diff --git a/linux-user/elfload.c b/linux-user/elfload.c index 03a8719..b405b7f 100644 --- a/linux-user/elfload.c +++ b/li

[Qemu-devel] [PULL 12/18] signal/ppc/do_setcontext remove __get_user return check

2014-06-09 Thread riku . voipio
From: Riku Voipio The last remaining check for return value of __get_user. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell Cc: Alexander Graf --- linux-user/signal.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/linux-user/signal.c b/linux-user/signal.c index

[Qemu-devel] [PULL 05/18] signal/all: remove return value from restore_sigcontext

2014-06-09 Thread riku . voipio
From: Riku Voipio make most implementations of restore_sigcontext void and remove checking it's return value from functions calling restore_sigcontext. The exception is the X86 version of the function that is too different from others to deal in this way, and arm version, to keep possibili

[Qemu-devel] [PULL 06/18] signal/sparc/restore_fpu_state: remove

2014-06-09 Thread riku . voipio
From: Riku Voipio A function never called from anywhere, obviously half-complete. Remove function and if someone wants to complete this, please check the old version out of git history. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell --- linux-user/signal.c | 37

[Qemu-devel] [PULL 08/18] signal/all/do_sigreturn - remove __get_user checks

2014-06-09 Thread riku . voipio
From: Riku Voipio Remove "if(__get_user" checks and their related error paths for all architecture's do_sigreturn. Remove the unlock_user_struct when the only way to end up there is from failed lock_user_struct. v3: remove unneccesary sigsegv label as suggested by Peter Sign

[Qemu-devel] [PULL 15/18] linux-user: Don't overrun guest buffer in sched_getaffinity

2014-06-09 Thread riku . voipio
s use a buffer whose size is a multiple of 8 regardless of guest architecture. Signed-off-by: Peter Maydell Signed-off-by: Riku Voipio --- linux-user/syscall.c | 16 1 file changed, 16 insertions(+) diff --git a/linux-user/syscall.c b/linux-user/syscall.c index 6efeeff..8

[Qemu-devel] [PULL 03/18] signal/all: remove return value from copy_siginfo_to_user

2014-06-09 Thread riku . voipio
From: Riku Voipio Since copy_siginfo_to_user always returns 0, make it void and remove any checks for return value from calling functions. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell --- linux-user/signal.c | 28 +--- 1 file changed, 9 insertions(+), 19

[Qemu-devel] [PULL 04/18] signal/all: remove return value from setup_sigcontext

2014-06-09 Thread riku . voipio
From: Riku Voipio Make all implementations of setup_sigcontext void and remove checking it's return value from functions calling setup_sigcontext. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell --- linux-user/signal.c | 65 + 1

[Qemu-devel] [PULL 14/18] linux-user/uname: Return correct uname string for x86_64

2014-06-09 Thread riku . voipio
only those architectures which need to vary the string based on runtime CPU features. Signed-off-by: Peter Maydell Signed-off-by: Riku Voipio --- linux-user/uname.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/linux-user/uname.c b/linux-user/uname.c index f5d4c66..1e6560d 100644 -

[Qemu-devel] [PULL 16/18] linux-user: Tell guest about big host page sizes

2014-06-09 Thread riku . voipio
ed-by: Richard Henderson Signed-off-by: Riku Voipio --- linux-user/elfload.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/linux-user/elfload.c b/linux-user/elfload.c index 995f999..03a8719 100644 --- a/linux-user/elfload.c +++ b/linux-user/elfload.c @@ -1531,7 +1531,7 @@ s

[Qemu-devel] [PULL 09/18] signal/all/setup_frame remove __put_user checks

2014-06-09 Thread riku . voipio
From: Riku Voipio Remove "if(__put_user" checks and their related error paths for all architecture's setup_frame, setup_rt_frame and similar. Remove the unlock_user_struct when the only way to end up there is from failed lock_user_struct. Remove err variable if there are no user

[Qemu-devel] [PULL 01/18] signal/all: remove __get/__put_user return value reading

2014-06-09 Thread riku . voipio
From: Riku Voipio Remove all the simple cases of reading the return value of __get_user and __put_user. We set err = 0 in sparc versions of do_sigreturn and sparc64_set_context to avoid compile error, but else this patch is just general removal of err |= __get_user ... idiom. Signed-off-by

[Qemu-devel] [PULL 11/18] signal/sparc64_set_context: remove __get_user checks

2014-06-09 Thread riku . voipio
From: Riku Voipio Remove checks of __get_user and the err variable used to control flow with it. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell --- linux-user/signal.c | 12 +++- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/linux-user/signal.c b/linux-user

[Qemu-devel] [PULL 07/18] signal/all/do_sigaltstack remove __get_user value check

2014-06-09 Thread riku . voipio
From: Riku Voipio Access is already checked in the lock_user_struct call before. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell --- linux-user/signal.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/linux-user/signal.c b/linux-user/signal.c index addf3c8

Re: [Qemu-devel] [PULL 00/18] linux-user fixes

2014-06-09 Thread Riku Voipio
On 9 June 2014 16:37, Peter Maydell wrote: > On 9 June 2014 13:46, wrote: >> From: Riku Voipio >> >> Mostly fixes, but a bigger rework in signal.c to allow compiling with gcc-4.9 >> >> The following changes since commit 959e41473f2179850578482052fb73b913

[Qemu-devel] [PATCH v3 02/13] signal/x86/setup_frame: __put_user cleanup

2014-06-10 Thread riku . voipio
From: Riku Voipio Remove the remaining check for __put_user return value, and all the checks for err variable which isn't set anywhere anymore. No we can only end up in give_sigsegv due to failed lock_user_struct - thus we remove the unlock_user_struct to avoid unlocking a region never l

[Qemu-devel] [PATCH v3 03/13] signal/all: remove return value from copy_siginfo_to_user

2014-06-10 Thread riku . voipio
From: Riku Voipio Since copy_siginfo_to_user always returns 0, make it void and remove any checks for return value from calling functions. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell --- linux-user/signal.c | 28 +--- 1 file changed, 9 insertions(+), 19

[Qemu-devel] [PATCH v3 13/13] linux-user: fix gcc-4.9 compiler error on __{get, put]}_user

2014-06-10 Thread riku . voipio
From: Riku Voipio gcc-4.9 finds unused operand: linux-user/syscall.c: In function ‘host_to_target_stat64’: linux-user/qemu.h:301:19: error: right-hand operand of comma expression has no effect [-Werror=unused-value] ((hptr), (x)), 0) Just removing the rh operand is no good, it will error

[Qemu-devel] [PATCH v3 04/13] signal/all: remove return value from setup_sigcontext

2014-06-10 Thread riku . voipio
From: Riku Voipio Make all implementations of setup_sigcontext void and remove checking it's return value from functions calling setup_sigcontext. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell --- linux-user/signal.c | 65 + 1

[Qemu-devel] [PATCH v3 07/13] signal/all/do_sigaltstack remove __get_user value check

2014-06-10 Thread riku . voipio
From: Riku Voipio Access is already checked in the lock_user_struct call before. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell --- linux-user/signal.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/linux-user/signal.c b/linux-user/signal.c index 2a1c681

[Qemu-devel] [PATCH v3 12/13] signal/ppc/do_setcontext remove __get_user return check

2014-06-10 Thread riku . voipio
From: Riku Voipio The last remaining check for return value of __get_user. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell Cc: Alexander Graf --- linux-user/signal.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/linux-user/signal.c b/linux-user/signal.c index

[Qemu-devel] [PATCH v3 08/13] signal/all/do_sigreturn - remove __get_user checks

2014-06-10 Thread riku . voipio
From: Riku Voipio Remove "if(__get_user" checks and their related error paths for all architecture's do_sigreturn. Remove the unlock_user_struct when the only way to end up there is from failed lock_user_struct. v3: remove unneccesary sigsegv label as suggested by Peter Sign

[Qemu-devel] [PATCH v3 11/13] signal/sparc64_set_context: remove __get_user checks

2014-06-10 Thread riku . voipio
From: Riku Voipio Remove checks of __get_user and the err variable used to control flow with it. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell --- linux-user/signal.c | 12 +++- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/linux-user/signal.c b/linux-user

[Qemu-devel] [PATCH v3 10/13] signal/ppc/{save, restore}_user_regs remove __put/get error checks

2014-06-10 Thread riku . voipio
From: Riku Voipio As __get_user and __put_user do not return errors, remove the if checks from around them. This allows making the save/restore functions void. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell Cc: Alexander Graf --- linux-user/signal.c | 126

[Qemu-devel] [PATCH v3 05/13] signal/all: remove return value from restore_sigcontext

2014-06-10 Thread riku . voipio
From: Riku Voipio make most implementations of restore_sigcontext void and remove checking it's return value from functions calling restore_sigcontext. The exception is the X86 version of the function that is too different from others to deal in this way, and arm version, to keep possibili

[Qemu-devel] [PATCH v3 09/13] signal/all/setup_frame remove __put_user checks

2014-06-10 Thread riku . voipio
From: Riku Voipio Remove "if(__put_user" checks and their related error paths for all architecture's setup_frame, setup_rt_frame and similar. Remove the unlock_user_struct when the only way to end up there is from failed lock_user_struct. Remove err variable if there are no user

[Qemu-devel] [PATCH v3 06/13] signal/sparc/restore_fpu_state: remove

2014-06-10 Thread riku . voipio
From: Riku Voipio A function never called from anywhere, obviously half-complete. Remove function and if someone wants to complete this, please check the old version out of git history. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell --- linux-user/signal.c | 37

[Qemu-devel] [PATCH v3 01/13] signal/all: remove __get/__put_user return value reading

2014-06-10 Thread riku . voipio
From: Riku Voipio Remove all the simple cases of reading the return value of __get_user and __put_user. We set err = 0 in sparc versions of do_sigreturn and sparc64_set_context to avoid compile error, but else this patch is just general removal of err |= __get_user ... idiom. v2: remove err

[Qemu-devel] [PATCH v3 00/13] linux-user: __{get, put}_user return value cleanup

2014-06-10 Thread riku . voipio
From: Riku Voipio This series is a cleanup and gcc-4.9 buildfix: linux-user/syscall.c: In function ‘host_to_target_stat64’: linux-user/qemu.h:301:19: error: right-hand operand of comma expression has no effect [-Werror=unused-value] ((hptr), (x)), 0) removing the unused 0 moves the bar

Re: [Qemu-devel] [PATCH 00/16] linux-user fixes & improvements

2014-06-17 Thread Riku Voipio
Hi, On Sun, Jun 15, 2014 at 05:18:17PM +0100, Paul Burton wrote: > This series fixes a number of bugs in QEMUs linux-user support, some > specific to targetting the MIPS architecture but mostly generic. It also > adds support for some previously unsupported syscalls & {g,s}etsockopt > options. Th

[Qemu-devel] [PULL v2 10/17] signal/ppc/{save, restore}_user_regs remove __put/get error checks

2014-06-17 Thread riku . voipio
From: Riku Voipio As __get_user and __put_user do not return errors, remove the if checks from around them. This allows making the save/restore functions void. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell Cc: Alexander Graf --- linux-user/signal.c | 126

[Qemu-devel] [PULL v2 02/17] signal/x86/setup_frame: __put_user cleanup

2014-06-17 Thread riku . voipio
From: Riku Voipio Remove the remaining check for __put_user return value, and all the checks for err variable which isn't set anywhere anymore. No we can only end up in give_sigsegv due to failed lock_user_struct - thus we remove the unlock_user_struct to avoid unlocking a region never l

[Qemu-devel] [PULL v2 00/17] linux-user updates

2014-06-17 Thread riku . voipio
From: Riku Voipio Changes from first pull req: rebase against head patch 01/17 signal/all: remove __get/__put_user return value reading remove err variable from target_rt_restore_ucontext The following changes since commit af44da87e926ff64260b95f4350d338c4fc113ca: Merge remote

[Qemu-devel] [PULL v2 12/17] signal/ppc/do_setcontext remove __get_user return check

2014-06-17 Thread riku . voipio
From: Riku Voipio The last remaining check for return value of __get_user. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell Cc: Alexander Graf --- linux-user/signal.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/linux-user/signal.c b/linux-user/signal.c index

[Qemu-devel] [PULL v2 11/17] signal/sparc64_set_context: remove __get_user checks

2014-06-17 Thread riku . voipio
From: Riku Voipio Remove checks of __get_user and the err variable used to control flow with it. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell --- linux-user/signal.c | 12 +++- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/linux-user/signal.c b/linux-user

[Qemu-devel] [PULL v2 04/17] signal/all: remove return value from setup_sigcontext

2014-06-17 Thread riku . voipio
From: Riku Voipio Make all implementations of setup_sigcontext void and remove checking it's return value from functions calling setup_sigcontext. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell --- linux-user/signal.c | 65 + 1

[Qemu-devel] [PULL v2 17/17] User mode support for Linux ELF files with no section header

2014-06-17 Thread riku . voipio
ith no section headers to be run properly in user mode: Signed-off-by: Craig Heffner Signed-off-by: Riku Voipio --- linux-user/elfload.c | 1 - 1 file changed, 1 deletion(-) diff --git a/linux-user/elfload.c b/linux-user/elfload.c index c123244..1248eda 100644 --- a/linux-user/elfload.c +++ b/li

[Qemu-devel] [PULL v2 01/17] signal/all: remove __get/__put_user return value reading

2014-06-17 Thread riku . voipio
From: Riku Voipio Remove all the simple cases of reading the return value of __get_user and __put_user. We set err = 0 in sparc versions of do_sigreturn and sparc64_set_context to avoid compile error, but else this patch is just general removal of err |= __get_user ... idiom. v2: remove err

[Qemu-devel] [PULL v2 03/17] signal/all: remove return value from copy_siginfo_to_user

2014-06-17 Thread riku . voipio
From: Riku Voipio Since copy_siginfo_to_user always returns 0, make it void and remove any checks for return value from calling functions. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell --- linux-user/signal.c | 28 +--- 1 file changed, 9 insertions(+), 19

[Qemu-devel] [PULL v2 08/17] signal/all/do_sigreturn - remove __get_user checks

2014-06-17 Thread riku . voipio
From: Riku Voipio Remove "if(__get_user" checks and their related error paths for all architecture's do_sigreturn. Remove the unlock_user_struct when the only way to end up there is from failed lock_user_struct. v3: remove unneccesary sigsegv label as suggested by Peter Sign

[Qemu-devel] [PULL v2 14/17] linux-user/uname: Return correct uname string for x86_64

2014-06-17 Thread riku . voipio
only those architectures which need to vary the string based on runtime CPU features. Signed-off-by: Peter Maydell Signed-off-by: Riku Voipio --- linux-user/uname.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/linux-user/uname.c b/linux-user/uname.c index f5d4c66..1e6560d 100644 -

[Qemu-devel] [PULL v2 09/17] signal/all/setup_frame remove __put_user checks

2014-06-17 Thread riku . voipio
From: Riku Voipio Remove "if(__put_user" checks and their related error paths for all architecture's setup_frame, setup_rt_frame and similar. Remove the unlock_user_struct when the only way to end up there is from failed lock_user_struct. Remove err variable if there are no user

[Qemu-devel] [PULL v2 13/17] linux-user: fix gcc-4.9 compiler error on __{get, put]}_user

2014-06-17 Thread riku . voipio
From: Riku Voipio gcc-4.9 finds unused operand: linux-user/syscall.c: In function ‘host_to_target_stat64’: linux-user/qemu.h:301:19: error: right-hand operand of comma expression has no effect [-Werror=unused-value] ((hptr), (x)), 0) Just removing the rh operand is no good, it will error

[Qemu-devel] [PULL v2 15/17] linux-user: Don't overrun guest buffer in sched_getaffinity

2014-06-17 Thread riku . voipio
s use a buffer whose size is a multiple of 8 regardless of guest architecture. Signed-off-by: Peter Maydell Signed-off-by: Riku Voipio --- linux-user/syscall.c | 16 1 file changed, 16 insertions(+) diff --git a/linux-user/syscall.c b/linux-user/syscall.c index 6efeeff..8

[Qemu-devel] [PULL v2 07/17] signal/all/do_sigaltstack remove __get_user value check

2014-06-17 Thread riku . voipio
From: Riku Voipio Access is already checked in the lock_user_struct call before. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell --- linux-user/signal.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/linux-user/signal.c b/linux-user/signal.c index 2a1c681

[Qemu-devel] [PULL v2 06/17] signal/sparc/restore_fpu_state: remove

2014-06-17 Thread riku . voipio
From: Riku Voipio A function never called from anywhere, obviously half-complete. Remove function and if someone wants to complete this, please check the old version out of git history. Signed-off-by: Riku Voipio Reviewed-by: Peter Maydell --- linux-user/signal.c | 37

[Qemu-devel] [PULL v2 05/17] signal/all: remove return value from restore_sigcontext

2014-06-17 Thread riku . voipio
From: Riku Voipio make most implementations of restore_sigcontext void and remove checking it's return value from functions calling restore_sigcontext. The exception is the X86 version of the function that is too different from others to deal in this way, and arm version, to keep possibili

[Qemu-devel] [PULL v2 16/17] linux-user: Return correct errno for unsupported netlink socket

2014-06-17 Thread riku . voipio
From: Ed Swierk This fixes "Cannot open audit interface - aborting." when the EAFNOSUPPORT errno differs between the target and host architectures (e.g. mips target and x86_64 host). Signed-off-by: Ed Swierk Signed-off-by: Riku Voipio --- linux-user/syscall.c | 2 +- 1 file

Re: [Qemu-devel] [PATCH] linux-user: added fake open() for /proc/self/cmdline

2014-06-20 Thread Riku Voipio
On Wed, Jun 18, 2014 at 11:02:39AM +0200, li...@fixnum.org wrote: > From: Wim Vander Schelden Seems to work, applied to linux-user updates > Signed-off-by: Wim Vander Schelden > --- > linux-user/syscall.c | 46 ++ > 1 file changed, 46 insertions(+)

Re: [Qemu-devel] [PATCH 11/16] linux-user: support ioprio_{get, set} syscalls

2014-06-20 Thread Riku Voipio
On Sun, Jun 15, 2014 at 05:18:28PM +0100, Paul Burton wrote: > Add support for the ioprio_get & ioprio_set syscalls, allowing their > use by target programs. > > Signed-off-by: Paul Burton > --- > linux-user/syscall.c | 18 ++ > 1 file changed, 18 insertions(+) > > diff --git a/

Re: [Qemu-devel] [PATCH 01/16] linux-user: translate the result of getsockopt SO_TYPE

2014-06-21 Thread Riku Voipio
On Sun, Jun 15, 2014 at 05:18:18PM +0100, Paul Burton wrote: > QEMU previously passed the result of the host syscall directly to the > target program. This is a problem if the host & target have different > representations of socket types, as is the case when running a MIPS > target program on an x

Re: [Qemu-devel] [PATCH 04/16] linux-user: support SO_PASSSEC setsockopt option

2014-06-21 Thread Riku Voipio
On Sun, Jun 15, 2014 at 05:18:21PM +0100, Paul Burton wrote: > Translate the SO_PASSSEC option to setsockopt to the host value & > perform the syscall as expected, allowing use of the option by target > programs. Another file that is a total mess in linux-user tree.. This should be split out to ar

Re: [Qemu-devel] [PATCH 07/16] linux-user: fix struct target_epoll_event layout for MIPS

2014-06-21 Thread Riku Voipio
On Sun, Jun 15, 2014 at 05:18:24PM +0100, Paul Burton wrote: > MIPS requires the pad field to 64b-align the data field just as ARM > does. Is this true for the 64bit mips also? > Signed-off-by: Paul Burton > --- > linux-user/syscall_defs.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-)

Re: [Qemu-devel] [PATCH 00/16] linux-user fixes & improvements

2014-06-21 Thread Riku Voipio
On Sun, Jun 15, 2014 at 05:18:17PM +0100, Paul Burton wrote: > This series fixes a number of bugs in QEMUs linux-user support, some > specific to targetting the MIPS architecture but mostly generic. It also > adds support for some previously unsupported syscalls & {g,s}etsockopt > options. Apart f

Re: [Qemu-devel] [PULL v2 059/106] libqemustub: add stubs to be able to use qemu-char.c

2014-06-22 Thread Riku Voipio
Hi, On Wed, Jun 18, 2014 at 07:19:17PM +0300, Michael S. Tsirkin wrote: > From: Nikolay Nikolaev > > chardev depends on lots of external symbols that are not necessarily > needed to be able to use, for example, 'socket chardev'. So add stubs > for these functions: > > - bdrv_commit_all > - qe

Re: [Qemu-devel] [PATCH] console: move chardev declarations to sysemu/char.h

2014-06-23 Thread Riku Voipio
nchip/linaro/qemu/include/ui/qemu-pixman.h:14:20: fatal > error: pixman.h: No such file or directory > #include > ^ > compilation terminated. This fix works for me, thanks. Tested-by: Riku Voipio > Reported-by: Riku Voipio > Signed-off-by: Michael S. Tsi

[Qemu-devel] [PULL 02/19] Add support for the arm breakpoint syscall

2014-06-23 Thread riku . voipio
/arm/kernel/traps.c#L598 Signed-off-by: Hunter Laux Reviewed-by: Peter Maydell Signed-off-by: Riku Voipio --- linux-user/arm/syscall.h | 1 + linux-user/main.c| 4 2 files changed, 5 insertions(+) diff --git a/linux-user/arm/syscall.h b/linux-user/arm/syscall.h index ce2c2a8..e0d2cc3

[Qemu-devel] [PULL 09/19] linux-user: support strace of epoll_create1

2014-06-23 Thread riku . voipio
From: Paul Burton Add the epoll_create1 syscall to strace.list in order to display that syscall when it occurs, rather than a message about the syscall being unknown despite QEMU already implementing support for it. Signed-off-by: Paul Burton Signed-off-by: Riku Voipio --- linux-user

[Qemu-devel] [PULL 12/19] linux-user: allow NULL tv argument for settimeofday

2014-06-23 Thread riku . voipio
f-by: Paul Burton Signed-off-by: Riku Voipio --- linux-user/syscall.c | 12 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/linux-user/syscall.c b/linux-user/syscall.c index 0ce1a4e..8e2762b 100644 --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -6401,11 +640

[Qemu-devel] [PULL 00/19] linux-user changes for 2.1

2014-06-23 Thread riku . voipio
From: Riku Voipio The following changes since commit d9c1647d896d3192cba9dbf98fb7efab876edde5: Merge remote-tracking branch 'remotes/stefanha/tags/block-pull-request' into staging (2014-06-23 12:55:22 +0100) are available in the git repository at: git://git.linaro.org/people/r

[Qemu-devel] [PULL 17/19] linux-user: support the unshare syscall

2014-06-23 Thread riku . voipio
From: Paul Burton Add support for the unshare syscall, trivially passed through to the host. Signed-off-by: Paul Burton Signed-off-by: Riku Voipio --- linux-user/syscall.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/linux-user/syscall.c b/linux-user/syscall.c index ecd5be9

[Qemu-devel] [PULL 10/19] linux-user: fix struct target_epoll_event layout for MIPS

2014-06-23 Thread riku . voipio
From: Paul Burton MIPS requires the pad field to 64b-align the data field just as ARM does. Signed-off-by: Paul Burton Signed-off-by: Riku Voipio --- linux-user/syscall_defs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/linux-user/syscall_defs.h b/linux-user

[Qemu-devel] [PULL 13/19] linux-user: support timerfd_{create, gettime, settime} syscalls

2014-06-23 Thread riku . voipio
From: Paul Burton Adds support for the timerfd_create, timerfd_gettime & timerfd_settime syscalls, allowing use of timerfds by target programs. Signed-off-by: Paul Burton Signed-off-by: Riku Voipio --- linux-user/strace.list | 9 + linux-user/syscall.c

<    1   2   3   4   5   6   7   8   9   10   >