--- nono/vm/ufs.h 2026/04/29 17:04:50 1.1 +++ nono/vm/ufs.h 2026/04/29 17:05:29 1.1.1.4 @@ -4,12 +4,18 @@ // Licensed under nono-license.txt // +// +// UFS 読み込み +// + #pragma once #include "device.h" #include "ffs_dinode.h" #include "ffs_fs.h" +class SCSIDisk; + // ディスクラベル (1セクタ目) // svnweb.freebsd.org/csrg/sys/luna68k/stand/omron_disklabel.h struct scd_dk_label @@ -41,7 +47,7 @@ static_assert(sizeof(scd_dk_label) == 51 class inodefile final { public: - inodefile(Device *parent_); + explicit inodefile(Device *parent_); ~inodefile(); // ディレクトリエントリからファイルを検索 @@ -58,11 +64,11 @@ class inodefile final class Filesys final { public: - Filesys(Device *parent_); + explicit Filesys(Device *parent_); ~Filesys(); // ファイルシステムをオープン - bool Mount(SCSIHD *hd_, uint32 start, uint32 size); + bool Mount(SCSIDisk *hd_, uint32 start, uint32 size); // ファイル名からファイルを探す bool OpenFile(inodefile& inode, const std::string& filename); @@ -80,7 +86,7 @@ class Filesys final void PeekBlock(void *buf, uint32 b, uint32 len) const; Device *parent {}; // 親デバイス - SCSIHD *hd {}; // ターゲット SCSI HD + SCSIDisk *hd {}; // ターゲット SCSI Disk // パーティション情報 uint32 part_start {}; // パーティションの先頭セクタ