qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH 0/3] [v4] Megasas HBA emulation


From: Hannes Reinecke
Subject: [Qemu-devel] [PATCH 0/3] [v4] Megasas HBA emulation
Date: Fri, 1 Jul 2011 09:42:49 +0200

Hi all,

thanks to Paolo and Stefan most of the SCSI patches are now in, so
I've made the next attempt of submitting my Megaraid SAS HBA emulation.

To do so, I've done two additional patches, both should be valid cleanups.

- Replace 'tag' by 'hba_private'
  The SCSIRequest structure has a 'tag', which is being used by the
  drivers to match the SCSIRequest to the internal request structure.
  The only driver actually to benefit from this is the lsi53c895a
  driver, everyone else either leaves it blank or uses some internal
  numberting here.
  So this patch converts the 'tag' to a 'hba_private' pointer, which
  allows the driver to store a pointer to the internal structure
  directly within the SCSIRequest. This saves the lookup and an
  additional field in the driver internal request structure.
- Add an 'offset' parameter to iov_to_buf()
  iov_from_buf() has it, but iov_to_buf() has it not. But we'll be
  needing it if the iovec is larger than the buffer. So there.

And, of course, the megasas driver itself. Which has been modified
to work with the new interface; otherwise there have been no changes
to the previous submission.

Hannes Reinecke (3):
  iov: Add 'offset' parameter to iov_to_buf()
  scsi: replace 'tag' with 'hba_private' pointer
  megasas: LSI Megaraid SAS emulation

 Makefile.objs           |    1 +
 default-configs/pci.mak |    1 +
 hw/esp.c                |    2 +-
 hw/lsi53c895a.c         |   17 +-
 hw/megasas.c            | 1923 +++++++++++++++++++++++++++++++++++++++++++++++
 hw/mfi.h                | 1197 +++++++++++++++++++++++++++++
 hw/pci_ids.h            |    3 +-
 hw/scsi-bus.c           |   22 +-
 hw/scsi-disk.c          |    5 +-
 hw/scsi-generic.c       |    4 +-
 hw/scsi.h               |    8 +-
 hw/spapr_vscsi.c        |   41 +-
 hw/usb-msd.c            |   10 +-
 hw/virtio-net.c         |    2 +-
 hw/virtio-serial-bus.c  |    2 +-
 iov.c                   |   23 +-
 iov.h                   |    2 +-
 trace-events            |   14 +-
 18 files changed, 3193 insertions(+), 84 deletions(-)
 create mode 100644 hw/megasas.c
 create mode 100644 hw/mfi.h




reply via email to

[Prev in Thread] Current Thread [Next in Thread]