From patchwork Mon Mar 17 16:00:33 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Maydell X-Patchwork-Id: 26389 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-pa0-f71.google.com (mail-pa0-f71.google.com [209.85.220.71]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 5A74820143 for ; Mon, 17 Mar 2014 16:00:44 +0000 (UTC) Received: by mail-pa0-f71.google.com with SMTP id kq14sf14878702pab.2 for ; Mon, 17 Mar 2014 09:00:43 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=7fJTJ3EvsjtAFGFsh7UXSPauT3AMMB5+qv7ItvDwiNA=; b=fPokDrDn7BgDG2CQikyMq23q2cQBgCRwbUY9fH3wotLsmNPzF0XUbpjwXCR8cOOaVA 5Xsgf85ZgOC7kunnZujYDpJXTYqik4G7Dx7FYw2Dj9AB7BMAMmu0wya4p6zFf6Frggtx ROh1eEPQIV90lFD+P+I86n7kj1qTzivTJMI05D/UZn1a5CHnJFUu/f85bynTmci8/BPR RQN49LjyS9NXtyXAp0pRfhn3Gxi9zJ3J0lDdGcXw5T17K66x0VdBx+e/TY9ew/IRNQ8F OFpOtnVFOhfsygJFEucirla87aV1ED6aBNGnTldytvRo1goaqPZKxTJtwJJCVka2tQOz BaPQ== X-Gm-Message-State: ALoCoQl/uH0pJvUyxm145xhwMAjLM+/ThSvyy0uio0Uzo+5OhYw4ER16KfO72iw3sJxMoy8h99ji X-Received: by 10.66.240.37 with SMTP id vx5mr9033303pac.8.1395072043487; Mon, 17 Mar 2014 09:00:43 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.86.85 with SMTP id o79ls622154qgd.12.gmail; Mon, 17 Mar 2014 09:00:43 -0700 (PDT) X-Received: by 10.52.189.33 with SMTP id gf1mr6269065vdc.26.1395072043382; Mon, 17 Mar 2014 09:00:43 -0700 (PDT) Received: from mail-vc0-f181.google.com (mail-vc0-f181.google.com [209.85.220.181]) by mx.google.com with ESMTPS id w14si5409777vco.78.2014.03.17.09.00.43 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 17 Mar 2014 09:00:43 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.220.181 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.181; Received: by mail-vc0-f181.google.com with SMTP id id10so5890831vcb.40 for ; Mon, 17 Mar 2014 09:00:43 -0700 (PDT) X-Received: by 10.52.128.231 with SMTP id nr7mr10549263vdb.17.1395072043286; Mon, 17 Mar 2014 09:00:43 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.220.78.9 with SMTP id i9csp137538vck; Mon, 17 Mar 2014 09:00:42 -0700 (PDT) X-Received: by 10.180.7.227 with SMTP id m3mr9937711wia.59.1395072042239; Mon, 17 Mar 2014 09:00:42 -0700 (PDT) Received: from mnementh.archaic.org.uk (mnementh.archaic.org.uk. [2001:8b0:1d0::1]) by mx.google.com with ESMTPS id v4si5324920wiy.47.2014.03.17.09.00.41 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Mon, 17 Mar 2014 09:00:42 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of pm215@archaic.org.uk designates 2001:8b0:1d0::1 as permitted sender) client-ip=2001:8b0:1d0::1; Received: from pm215 by mnementh.archaic.org.uk with local (Exim 4.80) (envelope-from ) id 1WPZxx-0004vj-81; Mon, 17 Mar 2014 16:00:41 +0000 From: Peter Maydell To: qemu-devel@nongnu.org Cc: patches@linaro.org, qemu-trivial@nongnu.org, qemu-ppc@nongnu.org Subject: [PATCH v2 04/12] hw/i386/acpi_build.c: Avoid shifting left into sign bit Date: Mon, 17 Mar 2014 16:00:33 +0000 Message-Id: <1395072041-18911-5-git-send-email-peter.maydell@linaro.org> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1395072041-18911-1-git-send-email-peter.maydell@linaro.org> References: <1395072041-18911-1-git-send-email-peter.maydell@linaro.org> X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: peter.maydell@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.181 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Add U suffix to avoid undefined behaviour. Signed-off-by: Peter Maydell Reviewed-by: Michael S. Tsirkin --- hw/i386/acpi-build.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c index 7ecfd70..b8a456e 100644 --- a/hw/i386/acpi-build.c +++ b/hw/i386/acpi-build.c @@ -907,7 +907,7 @@ static void build_pci_bus_end(PCIBus *bus, void *bus_state) build_append_byte(notify, 0x7B); /* AndOp */ build_append_byte(notify, 0x68); /* Arg0Op */ - build_append_int(notify, 0x1 << i); + build_append_int(notify, 0x1U << i); build_append_byte(notify, 0x00); /* NullName */ build_append_byte(notify, 0x86); /* NotifyOp */ build_append_nameseg(notify, "S%.02X_", PCI_DEVFN(i, 0));