> On Wed, Jul 11, 2012 at 8:28 AM, Stefan Fritsch <s...@sfritsch.de> wrote:
> > There is a virtio-scsi device, too, but this is only supported in very
> > recent versions of qemu. To attach the simpler virtio-block device as scsi,
> > the driver would have to emulate the scsi commands. Is there some generic
> > infrastructure to do that? Or which driver would you recommend to take the
> > emulation code from? sys/dev/ata/atascsi.c seems rather complex (it is twice
> > the size of sys/dev/pci/viod.c).
> 
> There are quite a few pretendy-SCSI drivers in the tree, but most of
> them deal with fairly complicated hardware so they're not good
> reference points.
> 
> sparc64's vdsk(4) driver is probably the best reference point, since
> it's also for a virtual disk driver (see sys/arch/sparc64/dev/vdsk.c).

Oh yes, vdsk(4) is also a good suggestion.

Reply via email to