器件型号: J721S2XSOMXEVM
大家好、我在基于 J721S2 的定制电路板上运行 Jailhouse Linux 囚犯时遇到问题。
我知道 TI 不支持在 J721S2 上运行 Jailhouse、但我使用现有的 J721E 单元配置作为 J721S2 配置的基础、我将在下面提供该配置。
我在第二个 A72 内核上运行了一个裸机连接器、它只能打印到 UART、看起来运行良好。
我有一个 Linux 实例几乎在第二个核心上运行、但问题是、一旦内核从用户空间运行/init、系统就会减慢速度、即登录提示永远不会出现、所有与 systemd 相关的驱动程序消息都会在 30 秒内打印、慢慢增加到 60 秒、然后再增加 90 秒、然后停止。
这里是 dmesg 的一个片段
[ 0.072299] Serial: 8250/16550 driver, 4 ports, IRQ sharing enabled
[ 0.075902] printk: console [ttyS3] disabled
[ 0.076093] 2850000.serial: ttyS3 at MMIO 0x2850000 (irq = 13, base_baud = 3000000) is a 8250
[ 0.076278] printk: console [ttyS3] enabled
[ 0.512285] loop: module loaded
[ 0.956672] i2c_dev: i2c /dev entries driver
[ 0.961281] device-mapper: ioctl: 4.48.0-ioctl (2023-03-01) initialised: dm-devel@redhat.com
[ 0.970175] sdhci: Secure Digital Host Controller Interface driver
[ 0.977660] sdhci: Copyright(c) Pierre Ossman
[ 0.977735] sdhci-pltfm: SDHCI platform and OF driver helper
[ 0.987847] ledtrig-cpu: registered to indicate activity on CPUs
[ 0.995775] hw perfevents: enabled with armv8_pmuv3 PMU driver, 7 counters available
[ 1.004375] NET: Registered PF_PACKET protocol family
[ 1.016820] registered taskstats version 1
[ 1.016851] Loading compiled-in X.509 certificates
[ 1.036733] ti-sci 44083000.dmsc: ABI: 4.0 (firmware rev 0x000b '11.0.9--v11.00.09+ (Fancy Rat)')
[ 1.047730] ti-sci-intr interconnect@100000:interconnect0:interrupt-controller1: Interrupt Router 227 domain created
[ 1.059745] ti-sci-inta 33d00000.interrupt-controller: Interrupt Aggregator domain 265 created
[ 1.068676] clk: Not disabling unused clocks
[ 1.068695] ALSA device list:
[ 1.068703] No soundcards found.
[ 1.828794] Freeing initrd memory: 29692K
[ 1.834028] Freeing unused kernel memory: 1728K
[ 1.838762] Run /init as init process
[ 1.842440] with arguments:
[ 1.842442] /init
[ 1.842444] with environment:
[ 1.842446] HOME=/
[ 1.842447] TERM=linux
[ 1.842449] tsc=reliable
[ 1.874635] systemd[1]: System time before build time, advancing clock.
[ 1.887376] NET: Registered PF_INET6 protocol family
[ 1.893137] Segment Routing with IPv6
[ 1.896852] In-situ OAM (IOAM) with IPv6
[ 1.905308] systemd[1]: systemd 255.17^ running in system mode (+PAM -AUDIT -SELINUX -APPARMOR +IMA -SMACK +SECCOMP -GCRYPT -GNUTLS -OPENSSL +ACL +BLKID -CURL -ELFUTILS -FIDO2 -IDN2 -IDN -IPTC +KMOD -LIBCRYPTSETUP +LIBFDISK -PCRE2 -PWQUALITY -P11KIT -QRENCODE -TPM2 -BZIP2 -LZ4 -XZ -ZLIB +ZSTD -BPF_FRAMEWORK -XKBCOMMON +UTMP +SYSVINIT default-hierarchy=unified)
[ 1.937285] systemd[1]: Detected virtualization vm-other.
[ 1.937302] systemd[1]: Detected architecture arm64.
[ 32.225073] systemd[1]: Hostname set to <am68-fas-xm1>.
[ 32.230597] systemd[1]: Initializing machine ID from random generator.
[ 62.533900] systemd[1]: Queued start job for default target Multi-User System.
[ 62.553740] systemd[1]: Created slice Slice /system/getty.
[ 92.642288] systemd[1]: Created slice Slice /system/modprobe.
[ 122.850367] systemd[1]: Created slice Slice /system/serial-getty.
[ 153.058087] systemd[1]: Created slice User and Session Slice.
[ 183.265198] systemd[1]: Started Dispatch Password Requests to Console Directory Watch.
[ 213.473177] systemd[1]: Started Forward Password Requests to Wall Directory Watch.
它似乎与内核调度器和 arch_timer 有关、就像计时器中断发生频率不够高、或者调度器由于任何原因都无法正常工作一样。
我怀疑我的单元配置在中断配置方面不正确、或者我的囚犯 DTS 不正确。 下面附加了单元配置和 DTS。
我使用以下命令启动单元格
modprobe jailhouse
jailhouse enable /usr/share/jailhouse/cells/k3-j721s2.cell
jailhouse cell linux /usr/share/jailhouse/cells/k3-j721s2-linux-demo.cell /boot/Image -d /usr/share/jailhouse/cells/inmate-k3-j721s2-linux.dtb -i /root/rootfs.cpio.gz -c ""
inmate-k3-j721s2-linux.dts.txt
我理解 TI 不对此提供官方支持、但如果有相关经验的人能向我发出提示并指明方向、我将不胜感激。
非常感谢!
Darko