This is a continuation of a patch series adding 9p server support for Darwin, originally submitted by Keno Fischer in mid-2018 (https://lists.nongnu.org/archive/html/qemu-devel/2018-06/msg04643.html). In some sense, this could be considered [PATCH v4] of that process, but I assume that the multi-year gap merits a fresh start..
It has since been updated and rebased for NixOS by Michael Roitzsch (https://github.com/NixOS/nixpkgs/pull/122420) with a goal of resubmitting upstream. I am submitting his patch set as suggested, as developed by Michael, with his Signed-off-by headers included in full. Additionally, I have run the patches through checkpatch.pl and adjusted coding style accordingly (with the exception of ignoring warnings about avoid architecture specific defines in hw/9pfs/9p-util-darwin.c, where they seem unavoidable), and have signed off on those modified commits.