From patchwork Sat Sep 9 14:21:16 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kamil Rytarowski X-Patchwork-Id: 9945355 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 457DA6035D for ; Sat, 9 Sep 2017 14:34:34 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 35D1928A2C for ; Sat, 9 Sep 2017 14:34:34 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2890328A41; Sat, 9 Sep 2017 14:34:34 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.4 required=2.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_HI,RCVD_IN_SORBS_SPAM autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 8F08428A2C for ; Sat, 9 Sep 2017 14:34:33 +0000 (UTC) Received: from localhost ([::1]:49725 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dqgq7-0000XM-72 for patchwork-qemu-devel@patchwork.kernel.org; Sat, 09 Sep 2017 10:34:31 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37178) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dqgpU-0000Ww-Jy for qemu-devel@nongnu.org; Sat, 09 Sep 2017 10:33:53 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dqgpR-0000MI-HC for qemu-devel@nongnu.org; Sat, 09 Sep 2017 10:33:52 -0400 Received: from mout.gmx.net ([212.227.17.20]:58658) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dqgpR-0000Li-8Q for qemu-devel@nongnu.org; Sat, 09 Sep 2017 10:33:49 -0400 Received: from localhost.localdomain ([185.58.161.191]) by mail.gmx.com (mrgmx101 [212.227.17.174]) with ESMTPSA (Nemesis) id 0Lbi2Z-1d9spn22e3-00lH8p; Sat, 09 Sep 2017 16:33:36 +0200 From: Kamil Rytarowski To: pbonzini@redhat.com Date: Sat, 9 Sep 2017 16:21:16 +0200 Message-Id: <20170909142116.26816-1-n54@gmx.com> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20170903163615.15562-1-n54@gmx.com> References: <20170903163615.15562-1-n54@gmx.com> X-Provags-ID: V03:K0:J25ekEhPAs+5PzL3ekPxCEW7ev5WCjcGndvv9NMDGRuBsapj/jf dey2yWXm75083d/8oP1nK/sjnSfoNsB5BlHUqzscSCygwfb/Kt5DQ0TNG1lpXrcCpVRa2i3 kdpv8KJaOExfukOtBSjOr/lCbqgrVB8WEqOOoCjGc23XEAChxQ95KlHnQQat8yLCxpSbrJd 6/fuA4HD/EeQZ8eYCHd/g== X-UI-Out-Filterresults: notjunk:1; V01:K0:r/0MCnAhJVk=:h4SA5AzQGrL6/oCLttf5Fp iP7qtv4BCrCoNbQhOuXXIoVETB7cyUsD1gDVs0Oo34ol5FHtBg8jTSCEOIS8LVCubOu23q34M AMfz+Xe75qsVe2iNIwwYV0TW0W8ya1ykrrFt4TOy+7VOR7BcnAYWH9SX8GFuutFbNupzRpFup zMEC+Gt/q03v/gDA6MVkfwHgcORlXEJ9nFvgHM8b4ZP7QTVpTnadhgY4+ZcTJwgslce7q+y8c LmG0kG0G4cvTwEpVHZRS31hUukUIEFlHKDwywiS2AasRlzLRSTrRKNx+To21SeriL5YSX3rx9 dOc8IKWXgPuqu9UdCH1i1wSnIpKxt53/Hb7txDE59fXx67SaUiQXnKOxfCwVPpjYovNxZQN3h lsFxM0NW7AydA0hpe4QYhRTQFZCPG08Hpnfkd7Coy9A/9GQjdNwGNZEKUPY/9cTBdQWi5ocsn Kw5rpGl10xLyg1zUCdTZUoZ+aI+kIsqRwb2FA4mzOL3tcHO/T3PXRtBfyPVXT4wRfNK0WqeLZ YWxXVj9KsmX6Jlw496rZrBJrumOQKootafRqbk2OIULzC0SutuuifkhkTNlblrhTPzIQtz+7z WciQtyXiwBPRcHXXivHUlAN5fN/PDal/paR3iyqPgDam+G6q7TDQ1SWkgORMJhTSTww2hWJMG 5HucOTygXPUoObQOXHZf6RbCig+URq6Hakd3ps7tMSVQRHjMmsGQQ7yJeqsuHAFAqQU3J03Ed S63Zmmv91WrssJV1YZGMzpNInAX110WF2fqcGoiuy8HI8SaMgK+K1VmExApiiy0xnqXvx5758 C4gkQ1kTkcxxOQtho1S1gqaxz75Qw== X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 212.227.17.20 Subject: [Qemu-devel] [PATCH v2] scsi/esp: Rename the ESP macro to ESP_STATE X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Kamil Rytarowski , qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP SunOS defines ESP (x86 register) in as 7. This fixes build on SmartOS (Joyent). Signed-off-by: Kamil Rytarowski --- hw/scsi/esp.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/hw/scsi/esp.c b/hw/scsi/esp.c index eee831efeb..22c2d91e39 100644 --- a/hw/scsi/esp.c +++ b/hw/scsi/esp.c @@ -593,7 +593,7 @@ const VMStateDescription vmstate_esp = { }; #define TYPE_ESP "esp" -#define ESP(obj) OBJECT_CHECK(SysBusESPState, (obj), TYPE_ESP) +#define ESP_STATE(obj) OBJECT_CHECK(SysBusESPState, (obj), TYPE_ESP) typedef struct { /*< private >*/ @@ -644,7 +644,7 @@ void esp_init(hwaddr espaddr, int it_shift, ESPState *esp; dev = qdev_create(NULL, TYPE_ESP); - sysbus = ESP(dev); + sysbus = ESP_STATE(dev); esp = &sysbus->esp; esp->dma_memory_read = dma_memory_read; esp->dma_memory_write = dma_memory_write; @@ -672,7 +672,7 @@ static const struct SCSIBusInfo esp_scsi_info = { static void sysbus_esp_gpio_demux(void *opaque, int irq, int level) { - SysBusESPState *sysbus = ESP(opaque); + SysBusESPState *sysbus = ESP_STATE(opaque); ESPState *s = &sysbus->esp; switch (irq) { @@ -688,7 +688,7 @@ static void sysbus_esp_gpio_demux(void *opaque, int irq, int level) static void sysbus_esp_realize(DeviceState *dev, Error **errp) { SysBusDevice *sbd = SYS_BUS_DEVICE(dev); - SysBusESPState *sysbus = ESP(dev); + SysBusESPState *sysbus = ESP_STATE(dev); ESPState *s = &sysbus->esp; sysbus_init_irq(sbd, &s->irq); @@ -706,7 +706,7 @@ static void sysbus_esp_realize(DeviceState *dev, Error **errp) static void sysbus_esp_hard_reset(DeviceState *dev) { - SysBusESPState *sysbus = ESP(dev); + SysBusESPState *sysbus = ESP_STATE(dev); esp_hard_reset(&sysbus->esp); }