Use configured serial number in inquiry responses
authorMichael McMaster <michael@codesrc.com>
Mon, 22 Feb 2021 10:31:25 +0000 (20:31 +1000)
committerMichael McMaster <michael@codesrc.com>
Mon, 22 Feb 2021 10:31:25 +0000 (20:31 +1000)
src/firmware/inquiry.c

index 138e8c2..ded201c 100755 (executable)
@@ -123,6 +123,8 @@ void s2s_scsiInquiry()
        {\r
                memcpy(scsiDev.data, UnitSerialNumber, sizeof(UnitSerialNumber));\r
                scsiDev.dataLen = sizeof(UnitSerialNumber);\r
+        const S2S_TargetCfg* config = scsiDev.target->cfg;\r
+        memcpy(&scsiDev.data[4], config->serial, sizeof(config->serial));\r
                scsiDev.phase = DATA_IN;\r
        }\r
        else if (pageCode == 0x81)\r