qemu-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-commits] [qemu/qemu] d03f9c: linux-user: Exit 0 when -h is used


From: GitHub
Subject: [Qemu-commits] [qemu/qemu] d03f9c: linux-user: Exit 0 when -h is used
Date: Fri, 02 Oct 2015 09:00:04 -0700

  Branch: refs/heads/master
  Home:   https://github.com/qemu/qemu
  Commit: d03f9c320234d2e49ad8b2f4abd049a497afa2be
      
https://github.com/qemu/qemu/commit/d03f9c320234d2e49ad8b2f4abd049a497afa2be
  Author: Meador Inge <address@hidden>
  Date:   2015-09-28 (Mon, 28 Sep 2015)

  Changed paths:
    M linux-user/main.c

  Log Message:
  -----------
  linux-user: Exit 0 when -h is used

Signed-off-by: Meador Inge <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: daaf8c8eb7135386134bc7075b9cf4dd57107c43
      
https://github.com/qemu/qemu/commit/daaf8c8eb7135386134bc7075b9cf4dd57107c43
  Author: Meador Inge <address@hidden>
  Date:   2015-09-28 (Mon, 28 Sep 2015)

  Changed paths:
    M linux-user/main.c

  Log Message:
  -----------
  linux-user: Add -help

This option is already available on the system mode
binaries.  It would be better if long options were
supported (i.e. --help), but this is okay for now.

Signed-off-by: Meador Inge <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: 138940bf08df1d8e9b862ad019a0d7d451e2413a
      
https://github.com/qemu/qemu/commit/138940bf08df1d8e9b862ad019a0d7d451e2413a
  Author: Meador Inge <address@hidden>
  Date:   2015-09-28 (Mon, 28 Sep 2015)

  Changed paths:
    M linux-user/main.c

  Log Message:
  -----------
  linux-user: Add proper error messages for bad options

This patch adds better support for diagnosing option
parser errors.  The previous implementation just printed
the usage text and exited when a bad option or argument
was found.  This made it very difficult to determine why
the usage was being displayed and it was doubly confusing
for cases like '--help' (it wasn't clear that --help was
actually an error).

Signed-off-by: Meador Inge <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: 4d1275c24d5d64d22ec4a30ce1b6a0db3ba9a25a
      
https://github.com/qemu/qemu/commit/4d1275c24d5d64d22ec4a30ce1b6a0db3ba9a25a
  Author: Riku Voipio <address@hidden>
  Date:   2015-09-28 (Mon, 28 Sep 2015)

  Changed paths:
    M linux-user/main.c

  Log Message:
  -----------
  linux-user: use EXIT_SUCCESS and EXIT_FAILURE

As suggested by Laurent, use EXIT_SUCCESS and EXIT_FAILURE from
stdlib.h instead of numeric values.

Cc: Laurent Vivier <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: ba02577cadbe5b53db791522310c977f9960f81f
      
https://github.com/qemu/qemu/commit/ba02577cadbe5b53db791522310c977f9960f81f
  Author: Meador Inge <address@hidden>
  Date:   2015-09-28 (Mon, 28 Sep 2015)

  Changed paths:
    M linux-user/main.c

  Log Message:
  -----------
  linux-user: Treat --foo options the same as -foo

The system mode binaries provide a similar alias
and it makes common options like --version and --help
work as expected.

Signed-off-by: Meador Inge <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: 84646ee25b68321624ef4768011e91064e4bd440
      
https://github.com/qemu/qemu/commit/84646ee25b68321624ef4768011e91064e4bd440
  Author: Stefan Brüns <address@hidden>
  Date:   2015-09-28 (Mon, 28 Sep 2015)

  Changed paths:
    M linux-user/elfload.c
    M linux-user/qemu.h

  Log Message:
  -----------
  linux-user: remove unused image_info members

Reviewed-by: Peter Maydell <address@hidden>
Signed-off-by: Stefan Brüns <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: 59baae9a626396a3a05840279084c4bf2beb8f40
      
https://github.com/qemu/qemu/commit/59baae9a626396a3a05840279084c4bf2beb8f40
  Author: Stefan Brüns <address@hidden>
  Date:   2015-09-28 (Mon, 28 Sep 2015)

  Changed paths:
    M linux-user/elfload.c
    M linux-user/flatload.c
    M linux-user/linuxload.c
    M linux-user/qemu.h
    M linux-user/syscall.c

  Log Message:
  -----------
  linux-user: remove MAX_ARG_PAGES limit

Instead of creating a temporary copy for the whole environment and
the arguments, directly copy everything to the target stack.

For this to work, we have to change the order of stack creation and
copying the arguments.

Reviewed-by: Peter Maydell <address@hidden>
Signed-off-by: Stefan Brüns <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: ee1045877a7e226945c7cec2bda80039bd2d0c8e
      
https://github.com/qemu/qemu/commit/ee1045877a7e226945c7cec2bda80039bd2d0c8e
  Author: Jonathan Neuschäfer <address@hidden>
  Date:   2015-09-28 (Mon, 28 Sep 2015)

  Changed paths:
    M linux-user/syscall.c
    M linux-user/syscall_defs.h

  Log Message:
  -----------
  linux-user: fix cmsg conversion in case of multiple headers

Currently, __target_cmsg_nxthdr compares a pointer derived from
target_cmsg against the msg_control field of target_msgh (through
subtraction).  This failed for me when emulating i386 code under x86_64,
because pointers in the host address space and pointers in the guest
address space were not the same.  This patch passes the initial value of
target_cmsg into __target_cmsg_nxthdr.

I found and fixed two more related bugs:
- __target_cmsg_nxthdr now returns the new cmsg pointer instead of the
  old one.
- tgt_space (in host_to_target_cmsg) doesn't count "sizeof (struct
  target_cmsghdr)" twice anymore.

Reviewed-by: Peter Maydell <address@hidden>
Signed-off-by: Jonathan Neuschäfer <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: 93b4eff80af9822e4b726dcf21ee61538e088695
      
https://github.com/qemu/qemu/commit/93b4eff80af9822e4b726dcf21ee61538e088695
  Author: Timothy E Baldwin <address@hidden>
  Date:   2015-09-28 (Mon, 28 Sep 2015)

  Changed paths:
    M linux-user/syscall.c

  Log Message:
  -----------
  linux-user: Return target error number in do_fork()

Whilst calls to do_fork() are wrapped in get_errno() this does not
translate return values.

Reviewed-by: Peter Maydell <address@hidden>
Signed-off-by: Timothy Edward Baldwin <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: 0f0426f343886fb5c9f137c2830f35cc2dae7327
      
https://github.com/qemu/qemu/commit/0f0426f343886fb5c9f137c2830f35cc2dae7327
  Author: Laurent Vivier <address@hidden>
  Date:   2015-09-28 (Mon, 28 Sep 2015)

  Changed paths:
    M linux-user/syscall.c

  Log Message:
  -----------
  linux-user: add name_to_handle_at/open_by_handle_at

This patch allows to run example given by open_by_handle_at(2):

      The following shell session demonstrates the use of these two programs:
      $ echo 'Can you please think about it?' > cecilia.txt
     $ ./t_name_to_handle_at cecilia.txt > fh
     $ ./t_open_by_handle_at < fh
     open_by_handle_at: Operation not permitted
     $ sudo ./t_open_by_handle_at < fh      # Need CAP_SYS_ADMIN
     Read 31 bytes
     $ rm cecilia.txt
  Now  we delete and (quickly) re-create the file so that it has the same
       content and (by chance) the  same  inode.[...]
      $ stat --printf="%i\n" cecilia.txt     # Display inode number
     4072121
     $ rm cecilia.txt
     $ echo 'Can you please think about it?' > cecilia.txt
     $ stat --printf="%i\n" cecilia.txt     # Check inode number
     4072121
     $ sudo ./t_open_by_handle_at < fh
     open_by_handle_at: Stale NFS file handle

See the man page for source code.

Reviewed-by: Peter Maydell <address@hidden>
Signed-off-by: Laurent Vivier <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: 08703b9f7bcd7ca2152d51a4c8893d26f1dc28de
      
https://github.com/qemu/qemu/commit/08703b9f7bcd7ca2152d51a4c8893d26f1dc28de
  Author: Chen Gang <address@hidden>
  Date:   2015-09-28 (Mon, 28 Sep 2015)

  Changed paths:
    M linux-user/syscall.c

  Log Message:
  -----------
  linux-user/syscall.c: Add EAGAIN to host_to_target_errno_table for

Under Alpha host, EAGAIN is redefined to 35, so it need be remapped too.

Reviewed-by: Peter Maydell <address@hidden>
Signed-off-by: Chen Gang <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: d0924a26d8f37ab95fdef99f6850b93e9af3ffb2
      
https://github.com/qemu/qemu/commit/d0924a26d8f37ab95fdef99f6850b93e9af3ffb2
  Author: Chen Gang <address@hidden>
  Date:   2015-10-01 (Thu, 01 Oct 2015)

  Changed paths:
    M linux-user/signal.c

  Log Message:
  -----------
  linux-user/signal.c: Use setup_rt_frame() instead of setup_frame() for target 
openrisc

qemu has already considered about some targets may have no traditional
signals. And openrisc's setup_frame() is dummy, but it can be supported
by setup_rt_frame().

Reviewed-by: Peter Maydell <address@hidden>
Signed-off-by: Chen Gang <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: 86abac06c142d20772b3f2e04c9bf02b7936a0b3
      
https://github.com/qemu/qemu/commit/86abac06c142d20772b3f2e04c9bf02b7936a0b3
  Author: Paolo Bonzini <address@hidden>
  Date:   2015-10-01 (Thu, 01 Oct 2015)

  Changed paths:
    M linux-user/mmap.c

  Log Message:
  -----------
  linux-user: assert that target_mprotect cannot fail

All error conditions that target_mprotect checks are also checked
by target_mmap.  EACCESS cannot happen because we are just removing
PROT_WRITE.  ENOMEM should not happen because we are modifying a
whole VMA (and we have bigger problems anyway if it happens).

Fixes a Coverity false positive, where Coverity complains about
target_mprotect's return value being passed to tb_invalidate_phys_range.

Signed-off-by: Paolo Bonzini <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: 945507d6bcde334f42b00cae134b4d47301d1821
      
https://github.com/qemu/qemu/commit/945507d6bcde334f42b00cae134b4d47301d1821
  Author: Peter Maydell <address@hidden>
  Date:   2015-10-02 (Fri, 02 Oct 2015)

  Changed paths:
    M linux-user/elfload.c
    M linux-user/flatload.c
    M linux-user/linuxload.c
    M linux-user/main.c
    M linux-user/mmap.c
    M linux-user/qemu.h
    M linux-user/signal.c
    M linux-user/syscall.c
    M linux-user/syscall_defs.h

  Log Message:
  -----------
  Merge remote-tracking branch 'remotes/riku/tags/pull-linux-user-20151002' 
into staging

First set of Linux-user que patches for 2.5

# gpg: Signature made Fri 02 Oct 2015 13:38:00 BST using RSA key ID DE3C9BC0
# gpg: Good signature from "Riku Voipio <address@hidden>"
# gpg:                 aka "Riku Voipio <address@hidden>"

* remotes/riku/tags/pull-linux-user-20151002:
  linux-user: assert that target_mprotect cannot fail
  linux-user/signal.c: Use setup_rt_frame() instead of setup_frame() for target 
openrisc
  linux-user/syscall.c: Add EAGAIN to host_to_target_errno_table for
  linux-user: add name_to_handle_at/open_by_handle_at
  linux-user: Return target error number in do_fork()
  linux-user: fix cmsg conversion in case of multiple headers
  linux-user: remove MAX_ARG_PAGES limit
  linux-user: remove unused image_info members
  linux-user: Treat --foo options the same as -foo
  linux-user: use EXIT_SUCCESS and EXIT_FAILURE
  linux-user: Add proper error messages for bad options
  linux-user: Add -help
  linux-user: Exit 0 when -h is used

Signed-off-by: Peter Maydell <address@hidden>


Compare: https://github.com/qemu/qemu/compare/37dd86a44cc4...945507d6bcde

reply via email to

[Prev in Thread] Current Thread [Next in Thread]