From 63b10175bf1bed50bea300e5801c6fef34ee28bd Mon Sep 17 00:00:00 2001 From: Maxim Poliakovski Date: Mon, 2 Oct 2023 15:01:27 +0200 Subject: [PATCH] mesh: stubs for BusFree and EnaReselect commands. --- devices/common/scsi/mesh.cpp | 12 ++++++++++-- devices/common/scsi/mesh.h | 3 +++ 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/devices/common/scsi/mesh.cpp b/devices/common/scsi/mesh.cpp index 9c1cd0c..fce718f 100644 --- a/devices/common/scsi/mesh.cpp +++ b/devices/common/scsi/mesh.cpp @@ -155,8 +155,16 @@ void MeshController::perform_command(const uint8_t cmd) this->cur_state = SeqState::SEL_BEGIN; this->sequencer(); break; + case SeqCmd::BusFree: + LOG_F(INFO, "MESH: BusFree stub invoked"); + this->int_stat |= INT_CMD_DONE; + break; + case SeqCmd::EnaReselect: + LOG_F(INFO, "MESH: EnaReselect stub invoked"); + this->int_stat |= INT_CMD_DONE; + break; case SeqCmd::DisReselect: - LOG_F(9, "MESH: DisReselect command requested"); + LOG_F(9, "MESH: DisReselect stub invoked"); this->int_stat |= INT_CMD_DONE; break; case SeqCmd::ResetMesh: @@ -164,7 +172,7 @@ void MeshController::perform_command(const uint8_t cmd) this->int_stat |= INT_CMD_DONE; break; case SeqCmd::FlushFIFO: - LOG_F(INFO, "MESH: FlushFIFO command requested"); + LOG_F(INFO, "MESH: FlushFIFO stub invoked"); break; default: LOG_F(ERROR, "MESH: unsupported sequencer command 0x%X", this->cur_cmd); diff --git a/devices/common/scsi/mesh.h b/devices/common/scsi/mesh.h index d77dc0c..6f28dc0 100644 --- a/devices/common/scsi/mesh.h +++ b/devices/common/scsi/mesh.h @@ -61,6 +61,8 @@ enum SeqCmd : uint8_t { NoOperation = 0, Arbitrate = 1, Select = 2, + BusFree = 9, + EnaReselect = 0xC, DisReselect = 0xD, ResetMesh = 0xE, FlushFIFO = 0xF, @@ -107,6 +109,7 @@ public: MeshController(uint8_t mesh_id) { supports_types(HWCompType::SCSI_HOST | HWCompType::SCSI_DEV); this->chip_id = mesh_id; + this->set_name("MESH"); this->reset(true); }; ~MeshController() = default;