RISC-Vネタ続き。今度も支那製のRISC-VベースのSBCで名前が示す通り、RaspberryPiフォームファクター互換(と言って良いのか)、具体的にはRPi zeroフォームファクタ互換風なRISC-VベースのLinux SBC。:
外観はこちら↓
下手な写真で申し訳ないが下のピンクの基板がMQ-pro(MangoPi proとも)で、上のさつま芋色(語彙が貧相ですみません:)基板は下にMQ-proがあってUSB-serial変換他を兼ねるRPI zero用のMaker pHATになる。pHATが登場するのはMQ-proがRPI zeroフォームファクタ互換(少なくとも拡張バスの主用な接続、今回はシリアルと電源、GND系が合っていれば使えそうなので)に見えたので使ってみた。開発者がフォームファクタ互換にする理由はオリジナルの周辺機器を流用したのも理由だから当然と言えば当然とも言える。私にとっての興味の中心は支那製RISC-V64Socの情報取得なので、Allwinner(センスが・・・、でも各種機器に採用されている有名なプランドではある:)最低限のブロック図をデータシートから引用:
0.Allwinner D1-H The RISC-V Multi-Media Decoding Platform SoC
雑な比較だが巷に色々提供されているアプリケーションプロセサ(古いが使った事があるチップという意味でFreescale i.MX515(Singlecoreという意味で:)等の所謂ARM cortex-A系のSocのRISC-V64版というイメージだろうか。これは他社:例えばRenesas)も同様でARM v8コア版とRISC-V64 or 32版というアプローチに見える(RISC-V純血派以外は:)。きっとこれはユーザに少ないリスクでマイグレーションパスを提案出来るメーカの戦術なのだろう(古くはFreescaleのMCF51JM/MS9S08JMとか)。もっともこの手の頭替え戦術は成功事例は少ない様な気がするし、ポイントは異なるアーキテクチャコアに最も抵抗するのはソフト屋さんだから、それをねじ伏せる権力以外の方法があるか、具体的にはRISC-V64ならではのキラーアプリケーションを創出出来るかがRISC-Vワールドの未来を握っているのだろう。日本人としてはRenesasさんのRISC-V64のLinuxBSP対応のエバボードが個人入手可能なレンジで提供されると嬉しいな(願望)。
それはさておき、
1.MangoPiについて
正直よく知らないので上記本家サイトを参照。もっともRPI財団の如く整った体制ではなさそうで(素材の関係から支那系技術者が主体?)それはそれでこういう界隈はそういうものであろう。少なくともOx64のUndocumented状態(言い過ぎです:)に比べりゃ雲泥の差、というか少なくともマイクロSDカードに適切なイメージファイルをddすればシリアルコンソールにメッセージが出力される。
MQ-proの本家サイトだが、コンテンツはこれからの様でバカでかい写真で大半の空間を埋めている。肝心のハードウェア資料は回路図とBOMデータはUpされており、Socのデータシートとマニュアルも存在する(英語版も:)。上記のRPi用pHATが使えるか判断する為に回路図を確認しておく:
上図中右がRPi互換と思しき拡張コネクタでざっとピン情報をRPiのそれと突き合わせると少なくともconsole用TXD,RXD,GND、電源系は互換に見えるし、GPIOは全く異なるがそれはマッピングするなり開発元の情報を参照すれば良い訳で、少なくともRPi用pHATを接続可能かと言えば・・・何とかなるのではというのが私の判断。ああ、コンソールシリアルが動けばいいやという意味です:)。
RPi用のpHATが使える前提で後はMQ-proとpHATを接続する為にピンヘッダをハンダ付けする(ハンダセラピーとも:)。それが上記写真の下のピンク基板のピンヘッダハンダ付け済のMQ-proなのです。ああハンダセラピーとはプロセッサ誌かトラ技かどこかで久しくハンダゴテを握っていない変人さんが禁断症状や多種多様なストレスに苛まれた時に、人が癒やしグッズや小動物によるセラピーのハンダ付けバージョンと称して言われたスラングです。今の境遇の私には染み入る言葉かもしれない(単なる妄想です:)。ハードウェアの準備は後はマイクロBケーブルを用意すれば良いだけで、RPi zeroスキームを流用出来れば楽に済む筈。。。
2.Armbian
RISC-VターゲットなのにARM風な名前のディストリなのは歴史的経緯があるのだろう。さまざまなディストリが存在する様だが本家サイトで開示されており、中国語では無い物からArmbian 22.08のディストリを探してきた。本家サイトはGUIベースの為、コンソールにはBootシーケンスを出力するがコンソールとして使えないので能無し(headless)バージョンをGoogleさんに探してもらう:
私が書き込んだのはHeadlessバージョンで上記サイトから:
Headless / CLI
Armbian_22.08.0-trunk_Nezha_jammy_current_5.19.0.img.xz
Armbian_22.08.0-trunk_Nezha_sid_current_5.19.0.img.xz
リンク先がロシアなのが不安。。。
3.起動
ディスクイメージの書込はxzを解凍し、imgファイルをddでマイクロSDに書込、MQ-proのマイクロSDスロットに挿して、pHATのUSBケーブルをUbuntu20.04(Thinkpad A285)に接続し、gtktermでボーレートを115,200bpsに設定し、電源Onすると普通にbootしてくれる。操作感はRPi zeroと同様な印象
MMC: mmc@4020000: 0, mmc@4021000: 1
Loading Environment from nowhere... OK
In: serial@2500000
Out: serial@2500000
Err: serial@2500000
Net:
Warning: ethernet@4500000 (eth0) using random MAC address - 0a:53:49:16:2a:4b
eth0: ethernet@4500000
Hit any key to stop autoboot: 0
switch to partitions #0, OK
mmc0 is current device
Scanning mmc 0:1...
Found /extlinux/extlinux.conf
Retrieving file: /extlinux/extlinux.conf
1: Armbian
Retrieving file: /uInitrd
Retrieving file: /Image
append: root=UUID=a9578c71-06d9-426c-b9b0-3e5f2dbdd644 console=ttyS0,115200n8 console=tty0 earlycon=sbi rootflags=data=writeback rw no_console_suspend consoleblank=0 fsck.fix=yes fsck.repair=yes net.ifnames=0 bootsplash.bootfile=bootsplash.armbian
Moving Image from 0x40040000 to 0x40200000, end=41add000
## Loading init Ramdisk from Legacy Image at 41c00000 ...
Image Name: uInitrd
Image Type: RISC-V Linux RAMDisk Image (gzip compressed)
Data Size: 11506920 Bytes = 11 MiB
Load Address: 00000000
Entry Point: 00000000
Verifying Checksum ... OK
## Flattened Device Tree blob at 7fb14730
Booting using the fdt blob at 0x7fb14730
Loading Ramdisk to 42306000, end 42dff4e8 ... OK
Loading Device Tree to 00000000422fb000, end 000000004230568f ... OKStarting kernel ...
[ 0.000000] Linux version 5.19.0-rc1-d1 (root@user-VirtualBox) (riscv64-linux-gnu-gcc (Ubuntu 10.3.0-8ubuntu1) 10.3.0, GNU ld (GNU Binutils for Ubuntu) 2.37) #trunk Thu Jun 23 10:42:46 MSK 2022
[ 0.000000] OF: fdt: Ignoring memory range 0x40000000 - 0x40200000
[ 0.000000] Machine model: Allwinner D1 Nezha
[ 0.000000] earlycon: sbi0 at I/O port 0x0 (options '')
[ 0.000000] printk: bootconsole [sbi0] enabled
[ 0.000000] efi: UEFI not found.
[ 0.000000] Zone ranges:
[ 0.000000] DMA32 [mem 0x0000000040200000-0x000000007fffffff]
[ 0.000000] Normal empty
[ 0.000000] Movable zone start for each node
[ 0.000000] Early memory node ranges
[ 0.000000] node 0: [mem 0x0000000040200000-0x000000007fffffff]
[ 0.000000] Initmem setup node 0 [mem 0x0000000040200000-0x000000007fffffff]
[ 0.000000] riscv: SBI specification v0.3 detected
[ 0.000000] riscv: SBI implementation ID=0x1 Version=0x10000
[ 0.000000] riscv: SBI TIME extension detected
[ 0.000000] riscv: SBI IPI extension detected
[ 0.000000] riscv: SBI RFENCE extension detected
[ 0.000000] riscv: SBI SRST extension detected
[ 0.000000] riscv: base ISA extensions acdfim
[ 0.000000] riscv: ELF capabilities acdfim
[ 0.000000] Built 1 zonelists, mobility grouping on. Total pages: 257544
[ 0.000000] Kernel command line: root=UUID=a9578c71-06d9-426c-b9b0-3e5f2dbdd644 console=ttyS0,115200n8 console=tty0 earlycon=sbi rootflags=data=writeback rw no_console_suspend consoleblank=0 fsck.fix=yes fsck.repair=yes net.ifnames=0 bootsplash.bootfile=bootsplash.armbian
[ 0.000000] Dentry cache hash table entries: 131072 (order: 8, 1048576 bytes, linear)
[ 0.000000] Inode-cache hash table entries: 65536 (order: 7, 524288 bytes, linear)
[ 0.000000] mem auto-init: stack:off, heap alloc:off, heap free:off
[ 0.000000] Memory: 990492K/1046528K available (9566K kernel code, 6325K rwdata, 6144K rodata, 2215K init, 528K bss, 56036K reserved, 0K cma-reserved)
[ 0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[ 0.000000] trace event string verifier disabled
[ 0.000000] NR_IRQS: 64, nr_irqs: 64, preallocated irqs: 0
[ 0.000000] OF: of_irq_init: found /cpus/cpu@0/interrupt-controller with parent (null)
[ 0.000000] OF: of_irq_init: found /soc/interrupt-controller@6010000 with parent /soc/interrupt-controller@10000000
[ 0.000000] OF: of_irq_init: found /soc/interrupt-controller@10000000 with parent /cpus/cpu@0/interrupt-controller
[ 0.000000] OF: of_irq_init: init /cpus/cpu@0/interrupt-controller with parent (null)
[ 0.000000] riscv-intc: 64 local interrupts mapped
[ 0.000000] OF: of_irq_init: init /soc/interrupt-controller@10000000 with parent /cpus/cpu@0/interrupt-controller
[ 0.000000] plic: interrupt-controller@10000000: mapped 176 interrupts with 1 handlers for 2 contexts.
[ 0.000000] OF: of_irq_init: init /soc/interrupt-controller@6010000 with parent /soc/interrupt-controller@10000000
[ 0.000000] riscv_timer_init_dt: Registering clocksource cpuid [0] hartid [0]
[ 0.000000] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x588fe9dc0, max_idle_ns: 440795202592 ns
[ 0.000000] sched_clock: 64 bits at 24MHz, resolution 41ns, wraps every 4398046511097ns
[ 0.008416] clocksource: timer: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 79635851949 ns
[ 0.018188] Console: colour dummy device 80x25
[ 0.022570] printk: console [tty0] enabled
[ 0.026736] printk: bootconsole [sbi0] disabled
[ 0.000000] Linux version 5.19.0-rc1-d1 (root@user-VirtualBox) (riscv64-linux-gnu-gcc (Ubuntu 10.3.0-8ubuntu1) 10.3.0, GNU ld (GNU Binutils for Ubuntu) 2.37) #trunk Thu Jun 23 10:42:46 MSK 2022
[ 0.000000] OF: fdt: Ignoring memory range 0x40000000 - 0x40200000
[ 0.000000] Machine model: Allwinner D1 Nezha
[ 0.000000] earlycon: sbi0 at I/O port 0x0 (options '')
[ 0.000000] printk: bootconsole [sbi0] enabled
[ 0.000000] efi: UEFI not found.
[ 0.000000] Zone ranges:
[ 0.000000] DMA32 [mem 0x0000000040200000-0x000000007fffffff]
[ 0.000000] Normal empty
[ 0.000000] Movable zone start for each node
[ 0.000000] Early memory node ranges
[ 0.000000] node 0: [mem 0x0000000040200000-0x000000007fffffff]
[ 0.000000] Initmem setup node 0 [mem 0x0000000040200000-0x000000007fffffff]
[ 0.000000] riscv: SBI specification v0.3 detected
[ 0.000000] riscv: SBI implementation ID=0x1 Version=0x10000
[ 0.000000] riscv: SBI TIME extension detected
[ 0.000000] riscv: SBI IPI extension detected
[ 0.000000] riscv: SBI RFENCE extension detected
[ 0.000000] riscv: SBI SRST extension detected
[ 0.000000] riscv: base ISA extensions acdfim
[ 0.000000] riscv: ELF capabilities acdfim
[ 0.000000] Built 1 zonelists, mobility grouping on. Total pages: 257544
[ 0.000000] Kernel command line: root=UUID=a9578c71-06d9-426c-b9b0-3e5f2dbdd644 console=ttyS0,115200n8 console=tty0 earlycon=sbi rootflags=data=writeback rw no_console_suspend consoleblank=0 fsck.fix=yes fsck.repair=yes net.ifnames=0 bootsplash.bootfile=bootsplash.armbian
[ 0.000000] Dentry cache hash table entries: 131072 (order: 8, 1048576 bytes, linear)
[ 0.000000] Inode-cache hash table entries: 65536 (order: 7, 524288 bytes, linear)
[ 0.000000] mem auto-init: stack:off, heap alloc:off, heap free:off
[ 0.000000] Memory: 990492K/1046528K available (9566K kernel code, 6325K rwdata, 6144K rodata, 2215K init, 528K bss, 56036K reserved, 0K cma-reserved)
[ 0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[ 0.000000] trace event string verifier disabled
[ 0.000000] NR_IRQS: 64, nr_irqs: 64, preallocated irqs: 0
[ 0.000000] OF: of_irq_init: found /cpus/cpu@0/interrupt-controller with parent (null)
[ 0.000000] OF: of_irq_init: found /soc/interrupt-controller@6010000 with parent /soc/interrupt-controller@10000000
[ 0.000000] OF: of_irq_init: found /soc/interrupt-controller@10000000 with parent /cpus/cpu@0/interrupt-controller
[ 0.000000] OF: of_irq_init: init /cpus/cpu@0/interrupt-controller with parent (null)
[ 0.000000] riscv-intc: 64 local interrupts mapped
[ 0.000000] OF: of_irq_init: init /soc/interrupt-controller@10000000 with parent /cpus/cpu@0/interrupt-controller
[ 0.000000] plic: interrupt-controller@10000000: mapped 176 interrupts with 1 handlers for 2 contexts.
[ 0.000000] OF: of_irq_init: init /soc/interrupt-controller@6010000 with parent /soc/interrupt-controller@10000000
[ 0.000000] riscv_timer_init_dt: Registering clocksource cpuid [0] hartid [0]
[ 0.000000] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x588fe9dc0, max_idle_ns: 440795202592 ns
[ 0.000000] sched_clock: 64 bits at 24MHz, resolution 41ns, wraps every 4398046511097ns
[ 0.008416] clocksource: timer: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 79635851949 ns
[ 0.018188] Console: colour dummy device 80x25
[ 0.022570] printk: console [tty0] enabled
[ 0.026736] printk: bootconsole [sbi0] disabled
[ 0.031405] Calibrating delay loop (skipped), value calculated using timer frequency.. 48.00 BogoMIPS (lpj=96000)
[ 0.031455] pid_max: default: 32768 minimum: 301
[ 0.031756] Mount-cache hash table entries: 2048 (order: 2, 16384 bytes, linear)
[ 0.031806] Mountpoint-cache hash table entries: 2048 (order: 2, 16384 bytes, linear)
[ 0.034377] cblist_init_generic: Setting adjustable number of callback queues.
[ 0.034416] cblist_init_generic: Setting shift to 0 and lim to 1.
[ 0.034607] riscv: ELF compat mode failed
[ 0.034657] ASID allocator using 16 bits (65536 entries)
[ 0.035779] EFI services will not be available.
[ 0.036369] printk: console [tty0] printing thread started
[ 0.036617] devtmpfs: initialized
[ 0.047047] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 7645041785100000 ns
[ 0.047075] futex hash table entries: 256 (order: 0, 6144 bytes, linear)
[ 0.047221] pinctrl core: initialized pinctrl subsystem
[ 0.049319] NET: Registered PF_NETLINK/PF_ROUTE protocol family
[ 0.050009] DMA: preallocated 128 KiB GFP_KERNEL pool for atomic allocations
[ 0.050060] DMA: preallocated 128 KiB GFP_KERNEL|GFP_DMA32 pool for atomic allocations
[ 0.050149] audit: initializing netlink subsys (disabled)
[ 0.051117] thermal_sys: Registered thermal governor 'bang_bang'
[ 0.051129] thermal_sys: Registered thermal governor 'step_wise'
[ 0.051135] thermal_sys: Registered thermal governor 'user_space'
[ 0.051406] cpuidle: using governor menu
[ 0.053691] audit: type=2000 audit(0.032:1): state=initialized audit_enabled=0 res=1
[ 0.076392] platform 5460000.tcon-top: Fixing up cyclic dependency with 5200000.mixer
[ 0.076533] platform 5460000.tcon-top: Fixing up cyclic dependency with 5100000.mixer
[ 0.077150] platform 5461000.lcd-controller: Fixing up cyclic dependency with 5460000.tcon-top
[ 0.077987] platform 5470000.lcd-controller: Fixing up cyclic dependency with 5460000.tcon-top
[ 0.078765] platform 5500000.hdmi: Fixing up cyclic dependency with 5460000.tcon-top
[ 0.082093] platform 7090000.rtc: Fixing up cyclic dependency with 7010000.clock-controller
[ 0.084191] platform connector: Fixing up cyclic dependency with 5500000.hdmi
[ 0.152223] HugeTLB registered 2.00 MiB page size, pre-allocated 0 pages
[ 0.221546] raid6: int64x8 gen() 346 MB/s
[ 0.289542] raid6: int64x4 gen() 445 MB/s
[ 0.357564] raid6: int64x2 gen() 444 MB/s
[ 0.425598] raid6: int64x1 gen() 349 MB/s
[ 0.425610] raid6: using algorithm int64x4 gen() 445 MB/s
[ 0.493529] raid6: .... xor() 314 MB/s, rmw enabled
[ 0.493538] raid6: using intx1 recovery algorithm
[ 0.517960] fbcon: Taking over console
[ 0.519812] iommu: Default domain type: Translated
[ 0.519823] iommu: DMA domain TLB invalidation policy: strict mode
[ 0.520337] SCSI subsystem initialized
[ 0.521023] usbcore: registered new interface driver usbfs
[ 0.521097] usbcore: registered new interface driver hub
[ 0.521161] usbcore: registered new device driver usb
[ 0.521786] mc: Linux media interface: v0.10
[ 0.521886] videodev: Linux video capture interface: v2.00
[ 0.522938] Advanced Linux Sound Architecture Driver Initialized.
[ 0.524459] clocksource: Switched to clocksource riscv_clocksource
[ 0.525030] VFS: Disk quotas dquot_6.6.0
[ 0.525092] VFS: Dquot-cache hash table entries: 512 (order 0, 4096 bytes)
[ 0.563668] NET: Registered PF_INET protocol family
[ 0.564014] IP idents hash table entries: 16384 (order: 5, 131072 bytes, linear)
[ 0.567638] tcp_listen_portaddr_hash hash table entries: 512 (order: 0, 4096 bytes, linear)
[ 0.567708] TCP established hash table entries: 8192 (order: 4, 65536 bytes, linear)
[ 0.567814] TCP bind bhash tables hash table entries: 8192 (order: 5, 131072 bytes, linear)
[ 0.568276] TCP: Hash tables configured (established 8192 bind 8192)
[ 0.568741] MPTCP token hash table entries: 1024 (order: 2, 24576 bytes, linear)
[ 0.568898] UDP hash table entries: 512 (order: 2, 16384 bytes, linear)
[ 0.568961] UDP-Lite hash table entries: 512 (order: 2, 16384 bytes, linear)
[ 0.569326] NET: Registered PF_UNIX/PF_LOCAL protocol family
[ 0.569378] NET: Registered PF_XDP protocol family
[ 0.570915] Initialise system trusted keyrings
[ 0.573002] Trying to unpack rootfs image as initramfs...
[ 0.580957] workingset: timestamp_bits=46 max_order=18 bucket_order=0
[ 0.591904] zbud: loaded
[ 0.613246] NET: Registered PF_ALG protocol family
[ 0.613272] xor: measuring software checksum speed
[ 0.618902] 8regs : 1767 MB/sec
[ 0.624527] 8regs_prefetch : 1762 MB/sec
[ 0.630128] 32regs : 1764 MB/sec
[ 0.635728] 32regs_prefetch : 1763 MB/sec
[ 0.635737] xor: using function: 8regs (1767 MB/sec)
[ 0.672587] Key type asymmetric registered
[ 0.672605] Asymmetric key parser 'x509' registered
[ 0.672817] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 247)
[ 0.673070] io scheduler mq-deadline registered
[ 0.673080] io scheduler kyber registered
[ 0.673273] io scheduler bfq registered
[ 0.766909] Serial: 8250/16550 driver, 6 ports, IRQ sharing disabled
[ 0.787782] sun8i-mixer 5100000.mixer: Adding to iommu group 0
[ 0.792756] sun8i-mixer 5200000.mixer: Adding to iommu group 0
[ 0.795741] zram: Added device: zram0
[ 0.809021] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[ 0.809056] ehci-platform: EHCI generic platform driver
[ 0.809523] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[ 0.809554] ohci-platform: OHCI generic platform driver
[ 0.810934] usbcore: registered new interface driver uas
[ 0.811019] usbcore: registered new interface driver usb-storage
[ 0.811170] usbcore: registered new interface driver usbserial_generic
[ 0.811217] usbserial: USB Serial support registered for generic
[ 0.811918] UDC core: g_ether: couldn't find an available UDC
[ 0.812307] mousedev: PS/2 mouse device common for all mice
[ 0.821060] sun6i-rtc 7090000.rtc: registered as rtc0
[ 0.821167] sun6i-rtc 7090000.rtc: setting system clock to 1970-01-02T00:00:12 UTC (86412)
[ 0.821374] sun6i-rtc 7090000.rtc: RTC enabled
[ 0.821721] i2c_dev: i2c /dev entries driver
[ 0.825450] sunxi-wdt 6011000.watchdog: Watchdog enabled (timeout=16 sec, nowayout=0)
[ 0.825725] device-mapper: uevent: version 1.0.3
[ 0.826271] device-mapper: ioctl: 4.46.0-ioctl (2022-02-22) initialised: dm-devel@redhat.com
[ 0.830404] sdhci: Secure Digital Host Controller Interface driver
[ 0.830414] sdhci: Copyright(c) Pierre Ossman
[ 0.830456] Synopsys Designware Multimedia Card Interface Driver
[ 0.833046] sdhci-pltfm: SDHCI platform and OF driver helper
[ 0.833600] ledtrig-cpu: registered to indicate activity on CPUs
[ 0.833980] sun8i-ce 3040000.crypto: Set mod clock to 300000000 (300 Mhz) from 400000000 (400 Mhz)
[ 0.836742] sun8i-ce 3040000.crypto: will run requests pump with realtime priority
[ 0.841012] sun8i-ce 3040000.crypto: will run requests pump with realtime priority
[ 0.841262] sun8i-ce 3040000.crypto: will run requests pump with realtime priority
[ 0.845171] sun8i-ce 3040000.crypto: will run requests pump with realtime priority
[ 0.845298] sun8i-ce 3040000.crypto: Register cbc(aes)
[ 0.845342] sun8i-ce 3040000.crypto: Register ecb(aes)
[ 0.845360] sun8i-ce 3040000.crypto: Register cbc(des3_ede)
[ 0.845379] sun8i-ce 3040000.crypto: Register ecb(des3_ede)
[ 0.845399] sun8i-ce 3040000.crypto: Register md5
[ 0.845420] sun8i-ce 3040000.crypto: Register sha1
[ 0.845449] sun8i-ce 3040000.crypto: Register sha224
[ 0.845476] sun8i-ce 3040000.crypto: Register sha256
[ 0.845502] sun8i-ce 3040000.crypto: Register sha384
[ 0.845526] sun8i-ce 3040000.crypto: Register sha512
[ 0.845552] sun8i-ce 3040000.crypto: Register stdrng
[ 0.846401] sun8i-ce 3040000.crypto: CryptoEngine Die ID 0
[ 0.846856] hid: raw HID events driver (C) Jiri Kosina
[ 0.847173] usbcore: registered new interface driver usbhid
[ 0.847181] usbhid: USB HID core driver
[ 0.847423] cedrus 1c0e000.video-codec: Adding to iommu group 0
[ 0.848070] cedrus 1c0e000.video-codec: Device registered as /dev/video0
[ 0.851239] riscv-pmu-sbi: SBI PMU extension is available
[ 0.853116] random: crng init done
[ 0.853163] riscv-pmu-sbi: 15 firmware and 2 hardware counters
[ 0.853175] riscv-pmu-sbi: Perf sampling/filtering is not supported as sscof extension is not available
[ 0.856825] usbcore: registered new interface driver snd-usb-audio
[ 0.865242] sun20i-codec 2030000.audio-codec: ASoC: Adding component 2030000.audio-codec for platform /soc/audio-codec@2030000
[ 0.865273] sun20i-codec 2030000.audio-codec: ASoC: Adding component 2030000.audio-codec for platform /soc/audio-codec@2030000
[ 0.882175] drop_monitor: Initializing network drop monitor service
[ 0.882484] Initializing XFRM netlink socket
[ 0.883142] NET: Registered PF_INET6 protocol family
[ 1.291225] Freeing initrd memory: 11236K
[ 1.375530] Segment Routing with IPv6
[ 1.375541] RPL Segment Routing with IPv6
[ 1.375598] In-situ OAM (IOAM) with IPv6
[ 1.375713] mip6: Mobile IPv6
[ 1.375724] NET: Registered PF_PACKET protocol family
[ 1.376856] registered taskstats version 1
[ 1.376889] Loading compiled-in X.509 certificates
[ 1.422975] Loaded X.509 cert 'Build time autogenerated kernel key: a8cce71c7e275b61abc337180d5dbd747814788f'
[ 1.423668] zswap: loaded using pool lzo/zbud
[ 1.424333] Key type ._fscrypt registered
[ 1.424343] Key type .fscrypt registered
[ 1.424347] Key type fscrypt-provisioning registered
[ 1.426948] Btrfs loaded, crc32c=crc32c-generic, zoned=yes, fsverity=yes
[ 1.469154] sun20i-d1-pinctrl 2000000.pinctrl: initialized sunXi PIO driver
[ 1.471850] printk: console [ttyS0] disabled
[ 1.492131] 2500000.serial: ttyS0 at MMIO 0x2500000 (irq = 207, base_baud = 1500000) is a 16550A
[ 1.492427] printk: console [ttyS0] enabled
[ 1.514697] 2500400.serial: ttyS1 at MMIO 0x2500400 (irq = 208, base_baud = 1500000) is a 16550A
[ 1.514756] printk: console [ttyS0] printing thread started
[ 1.538554] serial serial0: tty port ttyS1 registered
[ 1.539425] sun4i-drm display-engine: Adding to iommu group 0
[ 1.579826] sun4i-drm display-engine: bound 5100000.mixer (ops sun8i_mixer_ops)
[ 1.618694] sun4i-drm display-engine: bound 5200000.mixer (ops sun8i_mixer_ops)
[ 1.619302] sun4i-drm display-engine: bound 5460000.tcon-top (ops sun8i_tcon_top_ops)
[ 1.620091] sun4i-drm display-engine: No panel or bridge found... RGB output disabled
[ 1.620116] sun4i-drm display-engine: bound 5461000.lcd-controller (ops sun4i_tcon_ops)
[ 1.627064] sun4i-drm display-engine: bound 5470000.lcd-controller (ops sun4i_tcon_ops)
[ 1.627681] sun8i-dw-hdmi 5500000.hdmi: Detected HDMI TX controller v2.12a with HDCP (sun8i_dw_hdmi_phy)
[ 1.628505] sun8i-dw-hdmi 5500000.hdmi: registered DesignWare HDMI I2C bus driver
[ 1.629156] sun4i-drm display-engine: bound 5500000.hdmi (ops sun8i_dw_hdmi_ops)
[ 1.637438] [drm] Initialized sun4i-drm 1.0.0 20150629 for display-engine on minor 0
[ 1.637533] sun4i-drm display-engine: [drm] Cannot find any crtc or sizes
[ 1.639293] sun4i-drm display-engine: [drm] Cannot find any crtc or sizes
[ 2.039944] spi-nand: probe of spi0.0 failed with error -110
[ 2.046733] dwmac-sun8i 4500000.ethernet: IRQ eth_wake_irq not found
[ 2.046752] dwmac-sun8i 4500000.ethernet: IRQ eth_lpi not found
[ 2.047151] dwmac-sun8i 4500000.ethernet: PTP uses main clock
[ 2.047200] dwmac-sun8i 4500000.ethernet: Current syscon value is not the default 50006 (expect 0)
[ 2.047570] dwmac-sun8i 4500000.ethernet: No HW DMA feature register supported
[ 2.047584] dwmac-sun8i 4500000.ethernet: RX Checksum Offload Engine supported
[ 2.047591] dwmac-sun8i 4500000.ethernet: COE Type 2
[ 2.047600] dwmac-sun8i 4500000.ethernet: TX Checksum insertion supported
[ 2.047607] dwmac-sun8i 4500000.ethernet: Normal descriptors
[ 2.047614] dwmac-sun8i 4500000.ethernet: Chain mode enabled
[ 2.208601] dwmac-sun8i 4500000.ethernet: EMAC reset timeout
[ 2.208619] dwmac-sun8i 4500000.ethernet eth0: stmmac_dvr_remove: removing driver
[ 2.210619] dwmac-sun8i: probe of 4500000.ethernet failed with error -110
[ 2.224576] input: 2009800.keys as /devices/platform/soc/2009800.keys/input/input0
[ 4.276512] i2c i2c-2: mv64xxx: I2C bus locked, block: 1, time_left: 0
[ 4.276545] pcf857x: probe of 2-0038 failed with error -110
[ 4.290459] sun50i-r329-ledc 2008000.led-controller: Registered 1 LEDs
[ 4.294276] sunxi-mmc 4020000.mmc: Got CD GPIO
[ 4.294835] sunxi-mmc 4021000.mmc: allocated mmc-pwrseq
[ 4.305122] musb-sunxi 4100000.usb: Invalid or missing 'dr_mode' property
[ 4.305137] musb-sunxi: probe of 4100000.usb failed with error -22
[ 4.306555] phy phy-4100400.phy.0: Changing dr_mode to 1
[ 4.306572] phy phy-4100400.phy.0: External vbus detected, not enabling our own vbus
[ 4.306580] ehci-platform 4101000.usb: EHCI Host Controller
[ 4.306895] ehci-platform 4101000.usb: new USB bus registered, assigned bus number 1
[ 4.307301] ehci-platform 4101000.usb: irq 222, io mem 0x04101000
[ 4.308265] ehci-platform 4200000.usb: EHCI Host Controller
[ 4.308827] ehci-platform 4200000.usb: new USB bus registered, assigned bus number 2
[ 4.309055] ehci-platform 4200000.usb: irq 223, io mem 0x04200000
[ 4.310928] ALSA device list:
[ 4.310939] #0: sun20i-codec
[ 4.311816] ohci-platform 4101400.usb: Generic Platform OHCI controller
[ 4.313017] ohci-platform 4200400.usb: Generic Platform OHCI controller
[ 4.313360] ohci-platform 4200400.usb: new USB bus registered, assigned bus number 4
[ 4.313523] ohci-platform 4200400.usb: irq 225, io mem 0x04200400
[ 4.313610] ohci-platform 4101400.usb: new USB bus registered, assigned bus number 3
[ 4.313762] ohci-platform 4101400.usb: irq 224, io mem 0x04101400
[ 4.320623] sunxi-mmc 4021000.mmc: initialized, max. request size: 2047 KB, uses new timings mode
[ 4.321206] ehci-platform 4101000.usb: USB 2.0 started, EHCI 1.00
[ 4.321879] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002, bcdDevice= 5.19
[ 4.321897] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[ 4.321907] usb usb1: Product: EHCI Host Controller
[ 4.321915] usb usb1: Manufacturer: Linux 5.19.0-rc1-d1 ehci_hcd
[ 4.321923] usb usb1: SerialNumber: 4101000.usb
[ 4.322848] hub 1-0:1.0: USB hub found
[ 4.322921] hub 1-0:1.0: 1 port detected
[ 4.330213] sunxi-mmc 4020000.mmc: initialized, max. request size: 2047 KB, uses new timings mode
[ 4.343153] ehci-platform 4200000.usb: USB 2.0 started, EHCI 1.00
[ 4.343545] usb usb2: New USB device found, idVendor=1d6b, idProduct=0002, bcdDevice= 5.19
[ 4.343561] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[ 4.343571] usb usb2: Product: EHCI Host Controller
[ 4.343579] usb usb2: Manufacturer: Linux 5.19.0-rc1-d1 ehci_hcd
[ 4.343588] usb usb2: SerialNumber: 4200000.usb
[ 4.344056] sunxi-mmc 4021000.mmc: card claims to support voltages below defined range
[ 4.345569] hub 2-0:1.0: USB hub found
[ 4.345637] hub 2-0:1.0: 1 port detected
[ 4.389593] usb usb3: New USB device found, idVendor=1d6b, idProduct=0001, bcdDevice= 5.19
[ 4.389612] usb usb3: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[ 4.389622] usb usb3: Product: Generic Platform OHCI controller
[ 4.389631] usb usb3: Manufacturer: Linux 5.19.0-rc1-d1 ohci_hcd
[ 4.389638] usb usb3: SerialNumber: 4101400.usb
[ 4.391414] hub 3-0:1.0: USB hub found
[ 4.391486] hub 3-0:1.0: 1 port detected
[ 4.394320] usb usb4: New USB device found, idVendor=1d6b, idProduct=0001, bcdDevice= 5.19
[ 4.394340] usb usb4: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[ 4.394350] usb usb4: Product: Generic Platform OHCI controller
[ 4.394357] usb usb4: Manufacturer: Linux 5.19.0-rc1-d1 ohci_hcd
[ 4.394366] usb usb4: SerialNumber: 4200400.usb
[ 4.395245] hub 4-0:1.0: USB hub found
[ 4.395497] hub 4-0:1.0: 1 port detected
[ 4.399987] Freeing unused kernel image (initmem) memory: 2212K
[ 4.400100] Run /init as init process
[ 4.405660] mmc1: new high speed SDIO card at address 0001
[ 4.451861] mmc0: new high speed SDXC card at address 0001
[ 4.455096] mmcblk0: mmc0:0001 ASTC 58.2 GiB
[ 4.495073] GPT:Primary header thinks Alt. header is not at the end of the disk.
[ 4.495085] GPT:7110655 != 122138623
[ 4.495093] GPT:Alternate GPT header not at the end of the disk.
[ 4.495096] GPT:7110655 != 122138623
[ 4.495100] GPT: Use GNU Parted to correct GPT errors.
[ 4.495148] mmcblk0: p1 p2
[ 9.785749] EXT4-fs (mmcblk0p2): mounted filesystem with writeback data mode. Quota mode: none.
[ 11.173221] systemd[1]: System time before build time, advancing clock.
[ 11.271345] systemd[1]: systemd 251.2-5 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)
[ 11.271399] systemd[1]: Detected architecture riscv64.
[ 11.313439] systemd[1]: Hostname set to <nezha>.
[ 13.643568] systemd[1]: Queued start job for default target Graphical Interface.
[ 13.663529] systemd[1]: Created slice Slice /system/getty.
[ 13.674435] systemd[1]: Created slice Slice /system/modprobe.
[ 13.685267] systemd[1]: Created slice Slice /system/serial-getty.
[ 13.696367] systemd[1]: Created slice Slice /system/systemd-fsck.
[ 13.700209] systemd[1]: Created slice User and Session Slice.
[ 13.701084] systemd[1]: Dispatch Password Requests to Console Directory Watch when bootsplash is active was skipped because of a failed condition check (ConditionPathExists=/sys/devices/platform/bootsplash.0/enabled).
[ 13.701845] systemd[1]: Started Forward Password Requests to Wall Directory Watch.
[ 13.704255] systemd[1]: Set up automount Arbitrary Executable File Formats File System Automount Point.
[ 13.711729] systemd[1]: Reached target Local Encrypted Volumes.
[ 13.712701] systemd[1]: Reached target Local Integrity Protected Volumes.
[ 13.713765] systemd[1]: Reached target Host and Network Name Lookups.
[ 13.714450] systemd[1]: Reached target Path Units.
[ 13.721368] systemd[1]: Reached target Slice Units.
[ 13.722109] systemd[1]: Reached target Swaps.
[ 13.722786] systemd[1]: Reached target System Time Set.
[ 13.723947] systemd[1]: Reached target Local Verity Protected Volumes.
[ 13.806221] systemd[1]: Listening on RPCbind Server Activation Socket.
[ 13.815230] systemd[1]: Listening on fsck to fsckd communication Socket.
[ 13.816693] systemd[1]: Listening on initctl Compatibility Named Pipe.
[ 13.819086] systemd[1]: Listening on Journal Audit Socket.
[ 13.827860] systemd[1]: Listening on Journal Socket (/dev/log).
[ 13.830297] systemd[1]: Listening on Journal Socket.
[ 13.838108] systemd[1]: Listening on udev Control Socket.
[ 13.839897] systemd[1]: Listening on udev Kernel Socket.
[ 13.858785] systemd[1]: Mounting Huge Pages File System...
[ 13.907808] systemd[1]: Mounting POSIX Message Queue File System...
[ 13.966402] systemd[1]: Mounting NFSD configuration filesystem...
[ 14.024969] systemd[1]: Mounting Kernel Debug File System...
[ 14.073038] systemd[1]: Mounting Kernel Trace File System...
[ 14.075398] systemd[1]: Kernel Module supporting RPCSEC_GSS was skipped because of a failed condition check (ConditionPathExists=/etc/krb5.keytab).
[ 14.140113] systemd[1]: Starting Restore / save the current clock...
[ 14.221328] systemd[1]: Starting Set the console keyboard layout...
[ 14.266090] systemd[1]: Starting Create List of Static Device Nodes...
[ 14.341643] systemd[1]: Starting Load Kernel Module configfs...
[ 14.418521] systemd[1]: Starting Load Kernel Module drm...
[ 14.493572] systemd[1]: Starting Load Kernel Module fuse...
[ 14.532801] systemd[1]: File System Check on Root Device was skipped because of a failed condition check (ConditionPathExists=!/run/initramfs/fsck-root).
[ 14.593793] systemd[1]: Starting Load Kernel Modules...
[ 14.683543] systemd[1]: Starting Remount Root and Kernel File Systems...
[ 14.700783] systemd[1]: Repartition Root Disk was skipped because all trigger condition checks failed.
[ 14.765573] systemd[1]: Starting Coldplug All udev Devices...
[ 14.928390] systemd[1]: Mounted Huge Pages File System.
[ 14.961975] systemd[1]: Mounted POSIX Message Queue File System.
[ 14.963465] systemd[1]: Mounted Kernel Debug File System.
[ 15.065033] systemd[1]: Mounted Kernel Trace File System.
[ 15.102625] systemd[1]: Finished Restore / save the current clock.
[ 15.123849] systemd[1]: Finished Create List of Static Device Nodes.
[ 15.131601] systemd[1]: modprobe@configfs.service: Deactivated successfully.
[ 15.157708] systemd[1]: Finished Load Kernel Module configfs.
[ 15.177068] systemd[1]: modprobe@drm.service: Deactivated successfully.
[ 15.192665] systemd[1]: Finished Load Kernel Module drm.
[ 15.208759] systemd[1]: Finished Load Kernel Modules.
[ 15.289783] systemd[1]: Mounting Kernel Configuration File System...
[ 15.301046] fuse: init (API version 7.36)
[ 15.336656] EXT4-fs (mmcblk0p2): re-mounted. Quota mode: none.
[ 15.396094] systemd[1]: Starting Apply Kernel Variables...
[ 15.681642] systemd[1]: modprobe@fuse.service: Deactivated successfully.
[ 15.696778] systemd[1]: Finished Load Kernel Module fuse.
[ 15.736761] systemd[1]: Finished Remount Root and Kernel File Systems.
[ 15.738587] systemd[1]: Mounted Kernel Configuration File System.
[ 15.801091] systemd[1]: Mounting FUSE Control File System...
[ 15.802284] systemd[1]: Platform Persistent Storage Archival was skipped because of a failed condition check (ConditionDirectoryNotEmpty=/sys/fs/pstore).Armbian 22.08.0-
Armbian 22.08.0-trunk Sid hvc0nezha login: trunk Sid ttyS0
nezha login:
おしまい
20230611 17:28追記:
折角RISC-V64ベースのlinuxでセルフコンパイルも出来る様なのでhello,word的なコードを見てみる:)
naka@nezha:~$ cat t0.c#include <stdio.h>void main(){printf("Hello,MQ-pro\n");}naka@nezha:~$ cat t0.s.file "t0.c".option pic.text.section .rodata.align 3.LC0:.string "Hello,MQ-pro".text.align 1.globl main.type main, @functionmain:addi sp,sp,-16sd ra,8(sp)sd s0,0(sp)addi s0,sp,16lla a0,.LC0call puts@pltnopld ra,8(sp)ld s0,0(sp)addi sp,sp,16jr ra.size main, .-main.section .note.GNU-stack,"",@progbitsnaka@nezha:~$
数年前にRISC-VのISA本を斜め読みした気はするが命令セットは自分で使い込んでみないと身につかないもので記憶に薄いが、偏見ありまくりの見方(これでもRISC-V支持派故、RISC/CISC等という差別語(意識高い系の人、IT業界はMaster/Slave型Flip−Flop等、人権に配慮しない差別語(彼らにとっては=差別主義者であり、敵:)に満ち溢れておりますぞ、活動を(煽り):)を撒き散らす御大の思考回路はどうかと思うのだが、それはそれとして(技術に色は付いてないので)普通の人間でも理解しやすく、簡潔で好印象な命令・コード出力との印象を示しておこう。