From owner-svn-src-stable@freebsd.org Wed Oct 19 07:43:41 2016 Return-Path: Delivered-To: svn-src-stable@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 20365C17929; Wed, 19 Oct 2016 07:43:41 +0000 (UTC) (envelope-from sephe@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E254CC1F; Wed, 19 Oct 2016 07:43:40 +0000 (UTC) (envelope-from sephe@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u9J7hdIH026846; Wed, 19 Oct 2016 07:43:39 GMT (envelope-from sephe@FreeBSD.org) Received: (from sephe@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u9J7hdOq026845; Wed, 19 Oct 2016 07:43:39 GMT (envelope-from sephe@FreeBSD.org) Message-Id: <201610190743.u9J7hdOq026845@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: sephe set sender to sephe@FreeBSD.org using -f From: Sepherosa Ziehau Date: Wed, 19 Oct 2016 07:43:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r307617 - stable/11/sys/dev/hyperv/storvsc X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 19 Oct 2016 07:43:41 -0000 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 Reported by: Lili Deng 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,