From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:51745) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YcUfS-0000DR-GQ for qemu-devel@nongnu.org; Mon, 30 Mar 2015 04:03:36 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YcUfN-0002BP-E2 for qemu-devel@nongnu.org; Mon, 30 Mar 2015 04:03:30 -0400 Received: from e06smtp15.uk.ibm.com ([195.75.94.111]:32773) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YcUfN-0002BD-4b for qemu-devel@nongnu.org; Mon, 30 Mar 2015 04:03:25 -0400 Received: from /spool/local by e06smtp15.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 30 Mar 2015 09:03:24 +0100 Received: from b06cxnps4076.portsmouth.uk.ibm.com (d06relay13.portsmouth.uk.ibm.com [9.149.109.198]) by d06dlp01.portsmouth.uk.ibm.com (Postfix) with ESMTP id A6DDD17D805A for ; Mon, 30 Mar 2015 09:03:50 +0100 (BST) Received: from d06av02.portsmouth.uk.ibm.com (d06av02.portsmouth.uk.ibm.com [9.149.37.228]) by b06cxnps4076.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id t2U83KYc8192358 for ; Mon, 30 Mar 2015 08:03:20 GMT Received: from d06av02.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av02.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id t2U83HSj012132 for ; Mon, 30 Mar 2015 02:03:20 -0600 From: Cornelia Huck Date: Mon, 30 Mar 2015 10:02:27 +0200 Message-Id: <1427702547-21261-5-git-send-email-cornelia.huck@de.ibm.com> In-Reply-To: <1427702547-21261-1-git-send-email-cornelia.huck@de.ibm.com> References: <1427702547-21261-1-git-send-email-cornelia.huck@de.ibm.com> Subject: [Qemu-devel] [PULL for-2.3 4/4] s390x/ipl: avoid sign extension List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: peter.maydell@linaro.org Cc: Cornelia Huck , borntraeger@de.ibm.com, jfrei@linux.vnet.ibm.com, qemu-devel@nongnu.org, agraf@suse.de Make s390_update_iplstate() return uint32_t to avoid sign extensions for cssids > 127. While this doesn't matter in practice yet (as nobody supports MCSS-E and thus won't see the real cssid), play safe. Reported-by: Paolo Bonzini Reviewed-by: Jason J. Herne Signed-off-by: Cornelia Huck --- hw/s390x/ipl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/s390x/ipl.c b/hw/s390x/ipl.c index 5c86613..2e26d2a 100644 --- a/hw/s390x/ipl.c +++ b/hw/s390x/ipl.c @@ -218,7 +218,7 @@ static Property s390_ipl_properties[] = { * - -1 if no valid boot device was found * - ccw id of the boot device otherwise */ -static uint64_t s390_update_iplstate(CPUS390XState *env, S390IPLState *ipl) +static uint32_t s390_update_iplstate(CPUS390XState *env, S390IPLState *ipl) { DeviceState *dev_st; -- 2.3.4