linux-stable/drivers/vhost
Sudhakar Panneerselvam 6a70c943a2 scsi: vhost: Notify TCM about the maximum sg entries supported per command
[ Upstream commit 5ae6a6a915 ]

vhost-scsi pre-allocates the maximum sg entries per command and if a
command requires more than VHOST_SCSI_PREALLOC_SGLS entries, then that
command is failed by it. This patch lets vhost communicate the max sg limit
when it registers vhost_scsi_ops with TCM. With this change, TCM would
report the max sg entries through "Block Limits" VPD page which will be
typically queried by the SCSI initiator during device discovery. By knowing
this limit, the initiator could ensure the maximum transfer length is less
than or equal to what is reported by vhost-scsi.

Link: https://lore.kernel.org/r/1590166317-953-1-git-send-email-sudhakar.panneerselvam@oracle.com
Cc: Michael S. Tsirkin <mst@redhat.com>
Cc: Jason Wang <jasowang@redhat.com>
Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Mike Christie <mchristi@redhat.com>
Signed-off-by: Sudhakar Panneerselvam <sudhakar.panneerselvam@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-06-24 17:50:17 +02:00
..
Kconfig
Kconfig.vringh
Makefile
net.c vhost: Check docket sk_family instead of call getname 2020-03-05 16:43:44 +01:00
scsi.c scsi: vhost: Notify TCM about the maximum sg entries supported per command 2020-06-24 17:50:17 +02:00
test.c vhost/test: stop device before reset 2019-10-13 09:38:27 -04:00
test.h
vhost.c Revert "vhost: block speculation of translated descriptors" 2019-09-14 15:21:51 -04:00
vhost.h Revert "vhost: access vq metadata through kernel virtual address" 2019-09-04 07:39:48 -04:00
vringh.c vringh: fix copy direction of vringh_iov_push_kern() 2019-10-28 04:25:04 -04:00
vsock.c vhost/vsock: fix packet delivery order to monitoring devices 2020-05-27 17:46:31 +02:00