From patchwork Sun Oct 24 11:00:02 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gleb Natapov X-Patchwork-Id: 265382 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id o9OB0BFd008566 for ; Sun, 24 Oct 2010 11:00:15 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932452Ab0JXLAH (ORCPT ); Sun, 24 Oct 2010 07:00:07 -0400 Received: from mx1.redhat.com ([209.132.183.28]:63554 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932440Ab0JXLAF (ORCPT ); Sun, 24 Oct 2010 07:00:05 -0400 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o9OB05fk026975 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Sun, 24 Oct 2010 07:00:05 -0400 Received: from dhcp-1-237.tlv.redhat.com (dhcp-1-237.tlv.redhat.com [10.35.1.237]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o9OB03od032459; Sun, 24 Oct 2010 07:00:04 -0400 Received: by dhcp-1-237.tlv.redhat.com (Postfix, from userid 13519) id 204F618D46D; Sun, 24 Oct 2010 13:00:03 +0200 (IST) From: Gleb Natapov To: avi@redhat.com, mtosatti@redhat.com Cc: kvm@vger.kernel.org Subject: [PATCH 1/2] Use defines instead of numbers for cpu hotplug Date: Sun, 24 Oct 2010 13:00:02 +0200 Message-Id: <1287918003-7359-1-git-send-email-gleb@redhat.com> X-Scanned-By: MIMEDefang 2.67 on 10.5.11.12 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Sun, 24 Oct 2010 11:00:15 +0000 (UTC) diff --git a/hw/acpi_piix4.c b/hw/acpi_piix4.c index 1c8e4e2..1db5ee3 100644 --- a/hw/acpi_piix4.c +++ b/hw/acpi_piix4.c @@ -39,6 +39,7 @@ #define PCI_BASE 0xae00 #define PCI_EJ_BASE 0xae08 +#define PIIX4_CPU_HOTPLUG_STATUS 4 #define PIIX4_PCI_HOTPLUG_STATUS 2 struct gpe_regs { @@ -636,13 +637,13 @@ static void piix4_acpi_system_hot_add_init(PCIBus *bus, PIIX4PMState *s) #if defined(TARGET_I386) static void enable_processor(struct gpe_regs *g, int cpu) { - g->sts |= 4; + g->sts |= PIIX4_CPU_HOTPLUG_STATUS; g->cpus_sts[cpu/8] |= (1 << (cpu%8)); } static void disable_processor(struct gpe_regs *g, int cpu) { - g->sts |= 4; + g->sts |= PIIX4_CPU_HOTPLUG_STATUS; g->cpus_sts[cpu/8] &= ~(1 << (cpu%8)); }