qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Peter Maydell <peter.maydell@linaro.org>
To: qemu-devel@nongnu.org
Subject: Re: [Bug 1858461] Re: Please refactor linux-user/mips/cpu_loop.c
Date: Wed, 08 Jan 2020 17:56:17 -0000	[thread overview]
Message-ID: <CAFEAcA-X5L0j6esqjowx0n=xBdxyuK4XDB_MLUEn2tHya19pOw@mail.gmail.com> (raw)
Message-ID: <20200108175617.spU9p8KZz0NGDl6DOKT9lvhP6RAN4J7M9MrbozYMpjk@z> (raw)
In-Reply-To: 157850256701.5510.8747112724719044821.malone@gac.canonical.com

On Wed, 8 Jan 2020 at 17:06, puchuu <1858461@bugs.launchpad.net> wrote:
> I think about the following development flow:
>
> 1. Kernel updates and maintains "tbl".
> 2. Qemu developer wants to implement new syscall (like clone3) in "linux-user/syscall.c".
> 3. Developer clones new kernel into some directory and runs generators.
> 4. All syscall related stuff will be updated immediately.

That seems like quite a lot of effort, given that we don't really
have to update the set of syscall number #defines very often.
At the moment it's just "somebody submits a patch which
updates the list of #defines every so often". (And if you want
to actually implement a new syscall then the the actual
implementation is the bulk of the work anyhow.)

In particular if you really want to proceed down the path of
suggesting scripts for doing the update then I think we would
want something that works for all our architectures, not just MIPS.

thanks
-- PMM

-- 
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1858461

Title:
  Please refactor linux-user/mips/cpu_loop.c

Status in QEMU:
  New

Bug description:
  Hello. I am working with qemu on test images. I've added a new syscall
  (436) to qemu but received ENOSYS from mips application.

  Please open "linux-user/mips/cpu_loop.c". I've added at the end of
  "mips_syscall_args" the following:

  ```
  MIPS_SYS(sys_getdents64_x32, 3)
  ```

  But

  ```
  syscall_num = env->active_tc.gpr[2] - 4000;
  if (syscall_num >= sizeof(mips_syscall_args)) {
    ret = -TARGET_ENOSYS;
  ```

  returns -TARGET_ENOSYS

  We can see that "linux-user/mips/cpu_loop.c" differs a lot from
  "linux-user/arm/cpu_loop.c". Arm has it's own "ARM_NR_BASE" and etc.

  Can you please refactor mips cpu loop in the same way as arm? Thank
  you.

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1858461/+subscriptions


  reply	other threads:[~2020-01-08 18:11 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-06 17:20 [Bug 1858461] [NEW] Please refactor linux-user/mips/cpu_loop.c puchuu
2020-01-06 17:21 ` [Bug 1858461] " puchuu
2020-01-06 23:32 ` puchuu
2020-01-06 23:38 ` puchuu
2020-01-07 10:37   ` Thomas Huth
2020-01-07 13:17 ` puchuu
2020-01-07 13:53 ` puchuu
2020-01-07 19:07 ` puchuu
2020-01-07 23:42 ` Aleksandar Markovic
2020-01-08 16:32 ` Aleksandar Markovic
2020-01-08 16:56 ` puchuu
2020-01-08 17:56   ` Peter Maydell [this message]
2020-01-08 17:56     ` Peter Maydell
2020-01-08 16:56 ` puchuu
2020-01-08 16:58 ` puchuu
2020-01-08 18:13 ` puchuu
2020-01-08 18:45 ` Aleksandar Markovic
2020-01-08 18:49 ` Aleksandar Markovic
2020-01-08 19:58 ` Aleksandar Markovic
2020-01-08 19:59 ` puchuu
2020-01-15 21:23 ` puchuu
2020-11-17 11:05 ` Philippe Mathieu-Daudé
2021-05-02 18:20 ` Thomas Huth
2021-05-09 16:03 ` Philippe Mathieu-Daudé

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAFEAcA-X5L0j6esqjowx0n=xBdxyuK4XDB_MLUEn2tHya19pOw@mail.gmail.com' \
    --to=peter.maydell@linaro.org \
    --cc=1858461@bugs.launchpad.net \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).