Commit 1743c1de16 for qemu.org

commit 1743c1de165fcc2905249e5b02d0b88329f9c9ad
Merge: ee7eb612be d21201257a
Author: Stefan Hajnoczi <stefanha@redhat.com>
Date:   Sat May 9 07:36:20 2026 -0400

    Merge tag 'bsd-user-2026-05-pull-request' of https://gitlab.com/bsdimp/qemu-from-official into staging

    bsd-user May 2026 pull request

    Three patch series were reviewed during the code freeze and are finally ready to
    head into the tree.

    (1) Use SPDX identifiers in most places. This makes it easier for me to upstream
    since I can do almost all of the files in the forked tree and not have it be an
    issue each time I add a new file.

    (2) Per discussions in the review, copy thunk.c to bsd-user from linux-user. We
    will use this in the third set of patches, ioctls. All that changed is the
    copyright header. This file has style problems, but fixing them would be a worse
    problem than the style issues since we share it with linux-user and want to
    track changes there. In the future we may actually share, but for now this was
    the compromise.

    (3) All the ioctls that bsd-user supports in FreeBSD. This uses the thunk.c code
    to translate back and forth between host and target. A number of pedantic
    changes were made against the blitz branch upstream and were discovered or
    highlighted by claude code.

    I used claude to extract all the ioctl code from the blitz branch for
    upstreaming. I had it review the code and fixed the problems it found (though
    one was a false positive). I've not tagged these as Assisted-by: since that part
    of our policy is in flux. No creative output of claude was applied here, though
    it also suggested the commit messages (that I rewrote in large part, but
    vestiges of the original remain). To be clear: Claude didn't write any of
    the actual code.

    # -----BEGIN PGP SIGNATURE-----
    # Comment: GPGTools - https://gpgtools.org
    #
    # iQIzBAABCgAdFiEEIDX4lLAKo898zeG3bBzRKH2wEQAFAmn7+HkACgkQbBzRKH2w
    # EQBseRAAn4RqHJDLLdFpyfspFPOr8Etjmq6MdJ3MXtDauyOWE2IIY1bBsr5a81Ko
    # VjG3zpZ3kOE6eQsCKIHHUEljtrfej3kdrvfdMI5d0Qtk4YQSU3rN2Tz6CRNIQNRb
    # xALkkvsKY0AxP1xzdldUMCR2oO0AT1u0NC7aPpiKbg8Z4wUujDcaPXnNkun6xoRw
    # ysELRm3G1zyvIw0WX3LUrcxYel+O4cXoF1Fzi3ZLSyryeKOBXTQG/uA7+9YJUyLx
    # wsrl++bACCDHwkwnuFiIvg+ZkBiMfkVHz6SLRcMfVjwmAfRuPukvjB8ZZBXRLT94
    # zeG+R9t4zCRKC8Cka4AsYUyceHfgj/kdNkEd7u5rJHVHSUsfQAbWywRRhjOyO4Ad
    # 3nzKOCJ68e4bu3FOc7ih2pcrS71/zxR1HWa2FgwPOntrDaagCbugfSepZ5bJewvW
    # rBqujzgLV7B5fNDUAaYP+HnYr/qu6oaJZ4APalubBu+/Y++P1KBzfsiNSoFLHTzU
    # XFsGB0ktMbVJtqMfQKNBJlsd8XrRguhRvrujwBAKJxUt1XIS7lJfYQIN1sn2pfBe
    # evUsHsp978u1BR58rwEMRJeYxLIZe+Q6T3JJNXhwC+WsWZvjdLo2Xta78HcudC0R
    # z1FnH99jlUFpgHiySQUMR/6FYPBxRMQ4dPa4hgLVKYOSyN4GguI=
    # =L844
    # -----END PGP SIGNATURE-----
    # gpg: Signature made Wed 06 May 2026 22:27:05 EDT
    # gpg:                using RSA key 2035F894B00AA3CF7CCDE1B76C1CD1287DB01100
    # gpg: Good signature from "Warner Losh <wlosh@netflix.com>" [unknown]
    # gpg:                 aka "Warner Losh <imp@bsdimp.com>" [unknown]
    # gpg:                 aka "Warner Losh <imp@freebsd.org>" [unknown]
    # gpg:                 aka "Warner Losh <imp@village.org>" [unknown]
    # gpg:                 aka "Warner Losh <wlosh@bsdimp.com>" [unknown]
    # gpg: WARNING: This key is not certified with a trusted signature!
    # gpg:          There is no indication that the signature belongs to the owner.
    # Primary key fingerprint: 2035 F894 B00A A3CF 7CCD  E1B7 6C1C D128 7DB0 1100

    * tag 'bsd-user-2026-05-pull-request' of https://gitlab.com/bsdimp/qemu-from-official: (25 commits)
      bsd-user: Add call to do_bsd_ioctl and add bsd-ioctl.c to the build
      bsd-user: Add init_bsd_ioctl function
      bsd-user: Add do_bsd_ioctl main function
      bsd-user: Add do_ioctl_in6_ifreq_sockaddr_int function
      bsd-user: Add target_to_host_sockaddr_in6 function
      bsd-user: Add do_ioctl_unsupported function
      bsd-user: Add log_unsupported_ioctl function
      bsd-user: Add bsd-ioctl.c infrastructure and termios conversion
      bsd-user: Add target_sockaddr and safe_ioctl to syscall_defs.h
      bsd-user: Add bsd-ioctl.h header
      bsd-user: Add FreeBSD ioctl command table
      bsd-user: Add FreeBSD ioctl type definitions
      bsd-user: Add FreeBSD IPv6 ioctl definitions
      bsd-user: Add FreeBSD disk ioctl definitions
      bsd-user: Add FreeBSD cryptodev ioctl definitions
      bsd-user: Add FreeBSD socket ioctl definitions
      bsd-user: Add FreeBSD file I/O ioctl definitions
      bsd-user: Add FreeBSD tty ioctl definitions
      bsd-user: ioctl: add common definitions
      bsd-user: Copy linux-user/thunk.c to bsd-user
      ...

    Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>