From: Christian Schoenebeck <linux_oss@crudebyte.com>
To: Robert Schwebel <r.schwebel@pengutronix.de>
Cc: Eric Van Hensbergen <ericvh@kernel.org>,
Latchesar Ionkov <lucho@ionkov.net>,
Dominique Martinet <asmadeus@codewreck.org>,
v9fs@lists.linux.dev, kernel@pengutronix.de
Subject: Re: mmap on 9p broken in 6.4
Date: Thu, 13 Jul 2023 09:50:42 +0200 [thread overview]
Message-ID: <8322841.litLk3al4c@silver> (raw)
In-Reply-To: <ZK8mAe4O3LSfDQGl@pengutronix.de>
On Thursday, July 13, 2023 12:15:29 AM CEST Robert Schwebel wrote:
> On Wed, Jul 12, 2023 at 05:57:40PM +0200, Christian Schoenebeck wrote:
> > > On Wed, Jul 12, 2023 at 11:01:53AM +0200, Christian Schoenebeck wrote:
> > > > > TL;DR: mmap() seems to be broken on 9pfs on Linux 6.4. setting
> > > > > "rootflags=ignoreqv" fixes it as well, but it feels like a regression.
> > > >
> > > > What's the precise set of 9p mount options on guest, which 9p server is used
> > > > and what are 9p server's options respectively?
> > >
> > > The server is qemu, started like this:
> > >
> > > qemu-system-arm -machine vexpress-a9 -cpu cortex-a9 -smp 4 -m 1024M -nographic -no-reboot -net nic,netdev=net1 -netdev user,id=net1,hostfwd=tcp:127.0.0.1:27737-:22,hostfwd=tcp:127.0.0.1:12345-:12345 -rtc base=2000-01-01 -object rng-random,filename=/dev/random,id=rng0 -device virtio-rng-device,rng=rng0 -device virtio-scsi-device,id=scsi -fsdev local,id=rootfs,path=./platform-v7a/root,security_model=mapped-file -device virtio-9p-device,fsdev=rootfs,mount_tag=/dev/root -kernel ./platform-v7a/images/linuximage -dtb ./platform-v7a/images/vexpress-v2p-ca9.dtb -append 'root=/dev/root rootfstype=9p rootflags=trans=virtio console=ttyAMA0,115200 loglevel=5 systemd.show_status=auto'
> > >
> > > This is qemu 8.0.2.
> >
> > Does adding QEMU option "multidevs=remap" [1] resolve it?
> >
> > [1] https://wiki.qemu.org/Documentation/9psetup#Starting_the_Guest_directly
>
> Unfortunately not:
>
> + exec ./platform-v7a/sysroot-host/bin/qemu-system-arm -machine vexpress-a9 -cpu cortex-a9 -smp 4 -m 1024M -nographic -no-reboot -net nic,netdev=net1 -netdev user,id=net1,hostfwd=tcp:127.0.0.1:27737-:22,hostfwd=tcp:127.0.0.1:12345-:12345 -rtc base=2000-01-01 -object rng-random,filename=/dev/random,id=rng0 -device vi
> rtio-rng-device,rng=rng0 -device virtio-scsi-device,id=scsi -fsdev local,id=rootfs,path=./platform-v7a/root,security_model=mapped-file,multidevs=remap -device virtio-9p-device,fsdev=rootfs,mount_tag=/dev/root -kernel ./platform-v7a/images/linuximage -dtb ./platform-v7a/images/vexpress-v2p-ca9.dtb -append 'root=/dev/
> root rootfstype=9p rootflags=trans=virtio console=ttyAMA0,115200 loglevel=5 systemd.show_status=auto'
I don't see any cache option here. I would expect at least cache=mmap here:
https://wiki.qemu.org/Documentation/9p_root_fs#Boot_the_9p_Root_FS_System
By default it's cache=none, which means no mmap() would be allowed either.
> [ 0.000000] L2C: platform modifies aux control register: 0x02020000 -> 0x02420000
> [ 0.000000] L2C: DT/platform modifies aux control register: 0x02020000 -> 0x02420000
> [ 0.004806] smp_twd: clock not found -2
> [ 1.069767] simple-pm-bus bus@40000000:motherboard-bus@40000000:iofpga@7,00000000: Failed to create device link (0x180) with dcc:tcrefclk
> [ 1.085798] simple-pm-bus bus@40000000:motherboard-bus@40000000:iofpga@7,00000000: Failed to create device link (0x180) with dcc:tcrefclk
> [ 1.153420] physmap-flash 48000000.psram: map_probe failed
> [ 1.535013] 9pnet_virtio: no channels available for device root
>
> ____ _ _
> | _ \ ___ _ __ __ _ _ _| |_ _ __ ___ _ __ (_)_ __
> | |_) / _ \ '_ \ / _` | | | | __| '__/ _ \| '_ \| \ \/ /
> | __/ __/ | | | (_| | |_| | |_| | | (_) | | | | |> <
> |_| \___|_| |_|\__, |\__,_|\__|_| \___/|_| |_|_/_/\_\
> |___/
>
> ____ _ _ _ ___ _
> | _ \(_)___| |_ _ __ ___ | |/ (_) |_
> | | | | / __| __| '__/ _ \| ' /| | __|
> | |_| | \__ \ |_| | | (_) | . \| | |_
> |____/|_|___/\__|_| \___/|_|\_\_|\__|
>
>
> OSELAS(R)-DistroKit-2019.12.0-00429-g57ffae760eb9 / v7a-2019.12.0-00429-g57ffae760eb9
> ptxdist-2023.07.1/2023-07-11T19:56:50+0200
>
> DistroKit login: root
> root@DistroKit:~ mount / -o remount,rw
> root@DistroKit:~ ldconfig
> ldconfig: Cannot mmap file /lib/libgcc_s.so.1.
>
> ldconfig: Cannot mmap file /lib/libstdc++.so.
Again, effective 9p mount options are always useful, e.g. `mount | grep 9p`
>
> [...]
>
> rsc
>
next prev parent reply other threads:[~2023-07-13 7:50 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-11 20:19 mmap on 9p broken in 6.4 Robert Schwebel
2023-07-12 9:01 ` Christian Schoenebeck
2023-07-12 14:14 ` Robert Schwebel
2023-07-12 15:57 ` Christian Schoenebeck
2023-07-12 22:15 ` Robert Schwebel
2023-07-13 7:50 ` Christian Schoenebeck [this message]
[not found] ` <CAFkjPTmrbe9Djs_iYf=vu1xbTLhey0OmePR2Jw=C_dbQVYnAhQ@mail.gmail.com>
2023-07-13 10:54 ` Christian Schoenebeck
2023-07-14 5:36 ` Robert Schwebel
2023-07-16 14:54 ` Eric Van Hensbergen
2023-07-16 19:48 ` Eric Van Hensbergen
2023-07-17 11:26 ` Robert Schwebel
2023-07-17 15:29 ` Eric Van Hensbergen
2023-07-17 18:11 ` Eric Van Hensbergen
2023-07-17 18:59 ` Eric Van Hensbergen
2023-07-14 5:34 ` Robert Schwebel
2023-07-13 11:22 ` Linux regression tracking #adding (Thorsten Leemhuis)
2023-07-26 14:07 ` Linux regression tracking #update (Thorsten Leemhuis)
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=8322841.litLk3al4c@silver \
--to=linux_oss@crudebyte.com \
--cc=asmadeus@codewreck.org \
--cc=ericvh@kernel.org \
--cc=kernel@pengutronix.de \
--cc=lucho@ionkov.net \
--cc=r.schwebel@pengutronix.de \
--cc=v9fs@lists.linux.dev \
/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.