Author: sephe
Date: Wed Oct 19 07:43:39 2016
New Revision: 307617
URL: https://svnweb.freebsd.org/changeset/base/307617

Log:
  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

Modified:
  stable/11/sys/dev/hyperv/storvsc/hv_storvsc_drv_freebsd.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/dev/hyperv/storvsc/hv_storvsc_drv_freebsd.c
==============================================================================
--- stable/11/sys/dev/hyperv/storvsc/hv_storvsc_drv_freebsd.c   Wed Oct 19 
07:40:51 2016        (r307616)
+++ stable/11/sys/dev/hyperv/storvsc/hv_storvsc_drv_freebsd.c   Wed Oct 19 
07:43:39 2016        (r307617)
@@ -2210,7 +2210,7 @@ storvsc_io_done(struct hv_storvsc_reques
                                    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,
_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "[email protected]"

Reply via email to