From: "Theodore Ts'o" <tytso@mit.edu>
To: fstests@vger.kernel.org
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
Khazhismel Kumykov <khazhy@google.com>,
Leah Rumancik <leah.rumancik@gmail.com>
Subject: I got xfstests working on Mac OS!
Date: Fri, 29 Dec 2023 01:42:12 -0600 [thread overview]
Message-ID: <20231229074212.GA116263@mit.edu> (raw)
Well, technically I taught kvm-xfstests how to use qemu to use MacOS's
Hypervisor Virtualization Framework (hvf) --- hvf is MacOS / Apple
Silicon's analogue to kvm on x86_64 --- to boot an arm64 Linux kernel,
and I'm using the arm64 test appliance that had been created to run on
Google Compute Engine's arm platforms to run xfstests on a Macbook Air
M2.
The arm64 kernel was built using the "install-kconfig ; kbuild"
commands which are shipped with xfstests-bld[1], and the same kernel
can be used for arn64 GCE VM's in the cloud. For now the kernel was
built in a Parallels VM running Debian Testing, although there are
some hacks[2] to allow you to build a Linux kernel using Apple's XCode
compilers without needing to boot up a Parallels VM. I haven't had
time to play with that yet, though.
[1] https://github.com/tytso/xfstests-bld
[2] https://github.com/GayPizzaSpecifications/mac-linux-kdk
A quick demo video of this all working can be found here[3], and all
of the changes have been checked in and are available at [1].
[3] https://www.youtube.com/watch?v=JF_bcOCf_5Y
- Ted
P.S. Note: the current version of gcc-13 shipping with Debian
testing as of this writing will core dump while building one of the
kernel files (with host=aarch64 and target=aarch64) from v6.7-rc5.
This appears to be a compiler bug in gcc; Clang works just fine
building the arm64 test kernel which I used for this demo.
P.P.S. Yes, "kvm-xfstests" is more and more of a misnomer these days;
the script can also be called as "qemu-xfstests", but I find
"kvm-xfstests" easier to type. :-)
P.P.P.S. No, I haven't tried using Asahi Linux on my Macbook Air M2
15" yet --- it's on my todo list to play with --- but it should work
just fine there. There may be some minor changes needed to the
scripts in kvm-xfstests so that it works on a Fedora userspace, since
I do all of my development using Debian. It should mostly work, as I
did fixed up issues so that kvm-xfstests would work on Fedora/x86_64 a
few months ago. Some things may have bit rotted though, and I only
got the ability to run the test appliance working on Fedora; building
an updated Test Appliance doesn't yet work, since it would require
getting debootstrap to work on Fedora. Patches welcome...
reply other threads:[~2023-12-29 7:42 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20231229074212.GA116263@mit.edu \
--to=tytso@mit.edu \
--cc=fstests@vger.kernel.org \
--cc=khazhy@google.com \
--cc=leah.rumancik@gmail.com \
--cc=torvalds@linux-foundation.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.