diff options
author | sephe <sephe@FreeBSD.org> | 2016-10-19 08:45:19 +0000 |
---|---|---|
committer | sephe <sephe@FreeBSD.org> | 2016-10-19 08:45:19 +0000 |
commit | 2e85c985ba15a9b9fdd319c4420b89bd1fce3938 (patch) | |
tree | b81d55ab375a626c54f2a0c051eba22d24b51590 | |
parent | 3bbcf8b0fc235583e542746bca94be368fb6fb1c (diff) | |
download | FreeBSD-src-2e85c985ba15a9b9fdd319c4420b89bd1fce3938.zip FreeBSD-src-2e85c985ba15a9b9fdd319c4420b89bd1fce3938.tar.gz |
MFC 307261
hyperv/stor: Fix off-by-one bug; this brings back TRIM support.
Submitted by: Hongjiang Zhang <honzhan microsoft com>
Reported by: Lili Deng <v-lide microsoft com>
Sponsored by: Microsoft
Differential Revision: https://reviews.freebsd.org/D8238
-rw-r--r-- | sys/dev/hyperv/storvsc/hv_storvsc_drv_freebsd.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/dev/hyperv/storvsc/hv_storvsc_drv_freebsd.c b/sys/dev/hyperv/storvsc/hv_storvsc_drv_freebsd.c index 2f5c795..33cbed7 100644 --- a/sys/dev/hyperv/storvsc/hv_storvsc_drv_freebsd.c +++ b/sys/dev/hyperv/storvsc/hv_storvsc_drv_freebsd.c @@ -2210,7 +2210,7 @@ storvsc_io_done(struct hv_storvsc_request *reqp) resp_buf[3], resp_buf[4]); } if (vm_srb->srb_status == SRB_STATUS_SUCCESS && - data_len > SHORT_INQUIRY_LENGTH) { + data_len >= SHORT_INQUIRY_LENGTH) { char vendor[16]; cam_strvis(vendor, inq_data->vendor, |