Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 19 Apr 2017 05:28:21 +0000 (UTC)
From:      Sepherosa Ziehau <sephe@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject:   svn commit: r317125 - in stable/10/sys/dev/hyperv: storvsc utilities
Message-ID:  <201704190528.v3J5SLGs005205@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: sephe
Date: Wed Apr 19 05:28:21 2017
New Revision: 317125
URL: https://svnweb.freebsd.org/changeset/base/317125

Log:
  MFC 316813,316815
  
  316813
      hyperv/storvsc: Use ULL for 64bits value shift.
  
      Reported by:    PVS
      Sponsored by:   Microsoft
  
  316815
      hyperv/kvp: Remove always false condition.
  
      Reported by:    PVS
      Sponsored by:   Microsoft

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

Modified: stable/10/sys/dev/hyperv/storvsc/hv_storvsc_drv_freebsd.c
==============================================================================
--- stable/10/sys/dev/hyperv/storvsc/hv_storvsc_drv_freebsd.c	Wed Apr 19 05:19:33 2017	(r317124)
+++ stable/10/sys/dev/hyperv/storvsc/hv_storvsc_drv_freebsd.c	Wed Apr 19 05:28:21 2017	(r317125)
@@ -1771,7 +1771,7 @@ storvsc_check_bounce_buffer_sgl(bus_dma_
 			}
 			pre_aligned = TRUE;
 		} else {
-			tmp_bits |= 1 << i;
+			tmp_bits |= 1ULL << i;
 			if (!pre_aligned) {
 				if (phys_addr != vtophys(sgl[i-1].ds_addr +
 				    sgl[i-1].ds_len)) {

Modified: stable/10/sys/dev/hyperv/utilities/hv_kvp.c
==============================================================================
--- stable/10/sys/dev/hyperv/utilities/hv_kvp.c	Wed Apr 19 05:19:33 2017	(r317124)
+++ stable/10/sys/dev/hyperv/utilities/hv_kvp.c	Wed Apr 19 05:28:21 2017	(r317125)
@@ -516,7 +516,7 @@ hv_kvp_convert_usermsg_to_hostmsg(struct
 		/* Use values by string */
 		host_exchg_data->value_type = HV_REG_SZ;
 
-		if ((hkey_len < 0) || (hvalue_len < 0))
+		if (hvalue_len < 0)
 			return (EINVAL);
 
 		return (0);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201704190528.v3J5SLGs005205>