Fixed the MO part of the fix - do NOT hardcode to 512!

This commit is contained in:
OBattler
2025-03-20 06:30:58 +01:00
parent f74db2660f
commit 7575bdc562

View File

@@ -1363,7 +1363,7 @@ mo_command(scsi_common_t *sc, const uint8_t *cdb)
mo_buf_alloc(dev, dev->packet_len);
const int ret = mo_blocks(dev, &alloc_length, 0);
alloc_length = dev->requested_blocks * 512;
alloc_length = dev->requested_blocks * dev->drv->sector_size;
if (ret > 0) {
dev->requested_blocks = max_len;