qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Warner Losh <imp@bsdimp.com>
To: qemu-devel@nongnu.org
Cc: "Kyle Evans" <kevans@freebsd.org>,
	richard.henderson@linaro.org,
	"Alex Bennée" <alex.bennee@linaro.org>,
	f4bug@amsat.org, "Warner Losh" <imp@bsdimp.com>,
	"Paolo Bonzini" <pbonzini@redhat.com>,
	"Thomas Huth" <thuth@redhat.com>
Subject: [PATCH v3 00/11] 2023 Q1 bsd-user upstreaming: bugfixes and sysctl
Date: Thu, 16 Feb 2023 16:33:42 -0700	[thread overview]
Message-ID: <20230216233353.13944-1-imp@bsdimp.com> (raw)

[ letter edited -- need reviews for these hunks
     bsd-user: Helper routines h2g_old_sysctl
     bsd-user: various helper routines for sysctl
]

This group of patches gets the basic framework for sysctl upstreamed. There's a
lot more to translate far too many binary blobs the kernel publishes via
sysctls, but I'm leaving those out in the name of simplicity.

There's also a bug fix from Doug Rabson that fixes a long int confusion leading
to a trunctation of addresses (oops)

There's a fix for the -static option, since clang hates -no-pie and needs only
-fno-pie.

Finally, I'm changing how I'm upstreaming a little. I'm doing a little deeper
dives into our rather chaotic repo to find a couple of authors I might have
missed. From here on out, I'll be using the original author's name as the git
author. I'll also tag the co-authors better as well when there's multiple people
that did something (other than reformat and/or move code around). I've
discovered more code moved about than I'd previously known. This seems more in
line with standard practice. Also, I've reviewed all these changes, but I don't
know if I need to add Reviewed-by: or not, so I've done it for one or two and
will make it consistent before the pull request. git log suggests maintainers
are inconsistent about this (or I've not discovered the rules they follow).

check-patch gives some line lenght warnings, but should otherwise be OK. There's
several static functions that aren't used until the end of the patch
series... Not sure the best way to suppress the build warnings there (but since
they are just warnings...).

v3:
o Removed -strict, it's not ready and needs a complete rethink.
o Add g_assert_not_reached()
o target -> guest in most places
o Use MIN() to simplify things
o Better types in many places (abi_int instead of int32_t)
o Use ARRAY_COUNT
o fix tabs copied from FreeBSD sources to spaces

v2:
o Created various helper functions to make the code a little better
o split a few patches that I thought would be approved together but
  that generated commentary. It's easier to manage 1 per patch for
  those.
o Add/delete G_GNU_UNUSED to ensure all patches compile w/o warnings
o Fix 64-bit running 32-bit binary to get a LONG or ULONG. Add a
  bounce buffer for these so we don't overflow anything on the target
  and return all the elements of arrays.
o Fixed a number of nits noticed in the review.
o Add or improve comments to explain things there were questions on
  during the review.
o fix noted typos
o fix host != target page size differences
o Add pointers to FreeBSD source code, as appropriate
o fix locking (mostly unlocking) on error paths
o Note: -strict feedback not yet applied due to large numbers of changes
  from the rest. Next round.

Doug Rabson (1):
  bsd-user: Don't truncate the return value from freebsd_syscall

Juergen Lock (3):
  bsd-user: sysctl helper funtions: sysctl_name2oid and sysctl_oidfmt
  bsd-user: common routine do_freebsd_sysctl_oid for all sysctl variants
  bsd-user: Start translation of arch-specific sysctls

Kyle Evans (2):
  bsd-user: do_freebsd_sysctl helper for sysctl(2)
  bsd-user: implement sysctlbyname(2)

Stacey Son (2):
  bsd-user: Add sysarch syscall
  bsd-user: Helper routines oidfmt

Warner Losh (3):
  build: Don't specify -no-pie for --static user-mode programs
  bsd-user: various helper routines for sysctl
  bsd-user: Helper routines h2g_old_sysctl

 bsd-user/freebsd/os-sys.c     | 572 ++++++++++++++++++++++++++++++++++
 bsd-user/freebsd/os-syscall.c |  17 +-
 bsd-user/qemu.h               |   5 +
 configure                     |   2 +-
 4 files changed, 594 insertions(+), 2 deletions(-)

-- 
2.39.1



             reply	other threads:[~2023-02-16 23:34 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-16 23:33 Warner Losh [this message]
2023-02-16 23:33 ` [PATCH v3 01/11] bsd-user: Don't truncate the return value from freebsd_syscall Warner Losh
2023-02-16 23:33 ` [PATCH v3 02/11] build: Don't specify -no-pie for --static user-mode programs Warner Losh
2023-02-17  0:38   ` Alex Bennée
2023-02-16 23:33 ` [PATCH v3 03/11] bsd-user: Add sysarch syscall Warner Losh
2023-02-16 23:33 ` [PATCH v3 04/11] bsd-user: various helper routines for sysctl Warner Losh
2023-02-17 17:38   ` Richard Henderson
2023-02-16 23:33 ` [PATCH v3 05/11] bsd-user: Helper routines oidfmt Warner Losh
2023-02-16 23:33 ` [PATCH v3 06/11] bsd-user: Helper routines h2g_old_sysctl Warner Losh
2023-02-17 17:41   ` Richard Henderson
2023-02-16 23:33 ` [PATCH v3 07/11] bsd-user: sysctl helper funtions: sysctl_name2oid and sysctl_oidfmt Warner Losh
2023-02-16 23:33 ` [PATCH v3 08/11] bsd-user: common routine do_freebsd_sysctl_oid for all sysctl variants Warner Losh
2023-02-16 23:33 ` [PATCH v3 09/11] bsd-user: Start translation of arch-specific sysctls Warner Losh
2023-02-16 23:33 ` [PATCH v3 10/11] bsd-user: do_freebsd_sysctl helper for sysctl(2) Warner Losh
2023-02-16 23:33 ` [PATCH v3 11/11] bsd-user: implement sysctlbyname(2) Warner Losh

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=20230216233353.13944-1-imp@bsdimp.com \
    --to=imp@bsdimp.com \
    --cc=alex.bennee@linaro.org \
    --cc=f4bug@amsat.org \
    --cc=kevans@freebsd.org \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=richard.henderson@linaro.org \
    --cc=thuth@redhat.com \
    /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).