SCSI Write Buffer command "Download microcode with offset and save" vs "Download microcode with save" mode

1.2k views Asked by At

I want to use Write Buffer SCSI command to upload a firmware of a tape drive (LTO-6). As described in IBM LTO SCSI Reference section "5.2.41.6: MODE[07h] – Download microcode with offsets, save, and activate", microcode is transferred to the device using one or more WRITE BUFFER commands, saved to nonvolatile storage (Page 180). According to the CDB (Page 132), the Buffer Offset can be expressed in 3 bytes so does the Parameter List Length.

As I understand you may want to use more than one Write Buffer command in case the firmware size can't be expressed in 3 bytes (more than about 16M), and if so you can use the offset for that. But if the offset itself can't be expressed in more than 3 bytes, that means one can't write at offset 17M for example (therefor can't use this command more than twice in a row).

Does anybody know if this is the real use of "offset and save" mode?

2

There are 2 answers

0
Baruch Even On

You can use the mode 07h (Section 5.2.17.4) where the write buffer uses a shifted offset and thus you can express offsets larger than 16MB.

0
Shimaa On

Looks like one can't upload more than 32MB in the firmware buffer, and what was meant by 2 or more Write Buffer commands is to issue them with smaller value than the maximum(16MB) if you have a DMA(Direct Memory Access) limitation.

One can use the interpretation mentioned by Baruch Even with Read Buffer command with mode 07h (It's not supported by all Buffer IDs, one can check by issuing Read Buffer with mode 07h and it will return illegal request if it's not supported).

On the other hand, Write Buffer commands sections shows no such interpretation to any of the modes.