Skip to content

Commit

Permalink
scsi: include firmware version in vendor section of inquiry
Browse files Browse the repository at this point in the history
  • Loading branch information
erichelgeson committed Feb 25, 2024
1 parent 23a4212 commit 4b92367
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
3 changes: 2 additions & 1 deletion lib/BlueSCSI_platform_RP2040/BlueSCSI_platform.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@ extern "C" {

/* These are used in debug output and default SCSI strings */
extern const char *g_platform_name;
#define PLATFORM_NAME "BlueSCSI Pico"
#define PLATFORM_NAME "BlueSCSI"
#define PLATFORM_REVISION "2.0"
#define PLATFORM_INQUIRY PLATFORM_NAME " v" BLUESCSI_FW_VERSION
#define PLATFORM_MAX_SCSI_SPEED S2S_CFG_SPEED_SYNC_10
#define PLATFORM_OPTIMAL_MIN_SD_WRITE_SIZE 32768
#define PLATFORM_OPTIMAL_MAX_SD_WRITE_SIZE 65536
Expand Down
5 changes: 4 additions & 1 deletion lib/SCSI2SD/src/firmware/inquiry.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@

#include "scsi.h"
#include "config.h"
#include "BlueSCSI_config.h"
#include "inquiry.h"

#include <string.h>
Expand Down Expand Up @@ -241,10 +242,12 @@ uint32_t s2s_getStandardInquiry(
memcpy(&out[8], cfg->vendor, sizeof(cfg->vendor));
memcpy(&out[16], cfg->prodId, sizeof(cfg->prodId));
memcpy(&out[32], cfg->revision, sizeof(cfg->revision));
memcpy(&out[36], PLATFORM_INQUIRY, sizeof(PLATFORM_INQUIRY));
return sizeof(StandardResponse) +
sizeof(cfg->vendor) +
sizeof(cfg->prodId) +
sizeof(cfg->revision);
sizeof(cfg->revision) +
sizeof(PLATFORM_INQUIRY);
}

uint8_t getDeviceTypeQualifier()
Expand Down

0 comments on commit 4b92367

Please sign in to comment.