--- nono/vm/spc.h 2026/04/29 17:04:56 1.1.1.10 +++ nono/vm/spc.h 2026/04/29 17:04:59 1.1.1.11 @@ -121,9 +121,10 @@ struct SPC static const int SERR_SHORT_XFER = 0x02; // Short Transfer Period // PCTL レジスタ - // ここでは BusFree INT Enable ビットだけを保持。 - // 残りの MSG, C/D, I/O は親クラスの信号線フラグから生成。 + // BusFree INT Enable は独立して保持。 + // MSG, CD, IO の3ビットは pctl_out で保持。 bool busfree_intr_enable; + uint8 pctl_out; static const int PCTL_MASK = 0x87; // 書き込みマスク static const int PCTL_BFINT_EN = 0x80; // BusFree INT Enable static const int PCTL_MSG = 0x04; @@ -155,11 +156,6 @@ class SPCDevice : public SCSIHostDevice bool Init() override; void ResetHard() override; - // 接続中のデバイスを ID 順に並べたリストを返す (UI ステータスパネル用) - const std::vector& GetConnectedDevices() const { - return connected_devices; - } - // SCSIBus コールバック // バスフリーになった (全員に通知される) @@ -218,6 +214,8 @@ class SPCDevice : public SCSIHostDevice // SERR レジスタ値の取得 uint32 GetSERR() const; + // PCTL レジスタへの書き込み + void WritePCTL(uint32); // PCTL レジスタ値の取得 uint32 GetPCTL() const; @@ -247,7 +245,6 @@ class SPCDevice : public SCSIHostDevice // Transfer コマンド実行 void TransferCommand(); - void TransferCommandStart(Event& ev); void HardwareTransfer(Event& ev); void TransferComplete(); // Transfer コマンド実行中なら true @@ -272,9 +269,6 @@ class SPCDevice : public SCSIHostDevice // 割り込み信号線の接続先デバイス InterruptDevice *interrupt {}; - // 接続中のデバイス(イニシエータ含む)を ID 順に並べたリスト (モニタ用) - std::vector connected_devices {}; - // イベント Event event { this }; Event event_tc { this };