On 11/29/21 5:04 AM, Hannes Reinecke wrote:
This entire thing looks like an NVMe controller which is made to look like a SCSI controller. It even uses most of the NVMe structures. And from what I've seen there is not much SCSI specific in here; I/O and queue setup is pretty much what every NVMe controller does. So why not make it a true NVMe controller? Yes, you would need to discuss with the NVMe folks on how a RAID controller should look like in NVMe terms. But overall I guess the driver would be far smaller and possibly easier to maintain. So where's the benefit having it as a SCSI driver (apart from the fact that is allows you to side-step having to discuss the interface with NVMexpress.org ...)? Or, to put it the other way round: Is there anything SCSI specific which would prevent such an approach?
Hi Hannes, Isn't every driver that defines a struct scsi_host_template by definition a SCSI driver? If there is enough code that is shared between the spraid driver and the NVMe core one could look into creating a library with the shared code. However, I'm not sure this is worth the effort nor that the NVMe maintainers will agree with this. Thanks, Bart.