uweseimet / scsi2pi

Advanced performant SCSI/SASI emulation and tools for the PiSCSI/RaSCSI board
https://www.scsi2pi.net
BSD 3-Clause "New" or "Revised" License
10 stars 2 forks source link

Use shared transfer buffer in order to save memory #108

Closed uweseimet closed 4 days ago

uweseimet commented 4 days ago

Currently each s2p controller has its own instance of a buffer that holds the data during a SCSI transfer. This buffer is shared between the LUNs of a controller, but not between the controllers. When not using LUNs there is a controller per device. s2p runs a single transfer at a time, which means that the buffer can be shared between the controllers, saving main memory. This is especially useful for small Pis.

Depending on the client platform and the drivers/tools used, several MB can be saved, especially if the transfer sizes are big. On an Atari, when using the Kobold tool for copying data, this can easily be 10 MB for each additional device.