From nobody Wed May 8 01:55:32 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1561415857; cv=none; d=zoho.com; s=zohoarc; b=b5F4i7JhnSbqVc0GAFlV38jjKAR6cpO14Snpesstqb6H8ux5I3b81veBAEhiZLMzPjigOsA9N/fRwiSfaiavULpF9lr/wvnIOmKyPOPb9psBqL9S743j33TRsJ4Lymvg//YWK42nHnbzV22VHWRoh1pqUN1Wdf/X+ONWaFY+hvs= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1561415857; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=AW/xKO7mT5etUQtESYRRO4Lg0VmgTpD5DqdFMv+nnSk=; b=K+uJnrM4Nq5qUrH71b0F/ZnIaSGsQyjToinVH5mtJlCVz3iX2KpoNxc2bEWuVTodEk4P//oI1wkOXSQgosoGjLUcMPV+hF4T6Fh8cpQlvGJC5yiyPknklHTnRvmCETjPnkQjKBDaEwFVIETfNI/FSEQXsFpDdA324fLxm/UW5DM= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (209.51.188.17 [209.51.188.17]) by mx.zohomail.com with SMTPS id 156141585744432.24890853309819; Mon, 24 Jun 2019 15:37:37 -0700 (PDT) Received: from localhost ([::1]:55128 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXad-000329-FS for importer@patchew.org; Mon, 24 Jun 2019 18:37:31 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34070) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXSL-00047P-Lx for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:28:59 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hfXSH-0005K5-Mt for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:28:57 -0400 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]:45921) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hfXSG-0005Dv-Ev for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:28:53 -0400 Received: by mail-wr1-x442.google.com with SMTP id f9so15528965wre.12 for ; Mon, 24 Jun 2019 15:28:49 -0700 (PDT) Received: from x1.local (183.red-88-21-202.staticip.rima-tde.net. [88.21.202.183]) by smtp.gmail.com with ESMTPSA id l1sm646781wmg.13.2019.06.24.15.28.46 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Mon, 24 Jun 2019 15:28:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=AW/xKO7mT5etUQtESYRRO4Lg0VmgTpD5DqdFMv+nnSk=; b=t/5pRsq4kx9n6VdI7kt7a6mIBirBRCuz9f0XwXGJIb/QrFoVSEfOB2D8Sg1U1jdqIg 3hEXPS+1UJU0B6psU1rImYNu7UaxO30Bx8Y7wea/NUlSFLVQsZAMlJNvJeXmniUxJphc yLdY5sSD2CrhmQCHRkNX76AEXcmLSvpwH6tr8qzccunMvs3k8V0rewjIexpwjAKBsP+N IP2NXMt40nsDVz76VlVfLExm+czkbWStu6Nnrk81xU3HEtNBnQ+t4Qk/LxJeUFwnDDL6 jrgY3IRXuaS1nfBv0Z0lVa2Ozh5jngPIXjV7gkjMc6/wUIqVJAcRgRhJW/USFOrCcohJ YO8A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=AW/xKO7mT5etUQtESYRRO4Lg0VmgTpD5DqdFMv+nnSk=; b=PAxpLZV3wgY4aOt4nTu7+PA4KPZbgM8ftp/lBNCibW8wNhx4d3GydOmokvrX3MSqoy 1zs7aiE5rK1Qaf7fVa60do78ofjulUkUkriUegrQNgTfWBq73JgX/3pTp9CPwLvnU6uk M3m8eEYFncC4pXk4fiHJLWh36a1wNtxoRrFcuvuPqJTvJQXT03byqflH4ezrPfPRH1ya ZcLHTMAX7socB66zixucaaGQ9nfWvo3wocEA8crMYUHAwsq2hHlmTnA7JdC2TFOoR4dz +/5N4gI9u6nvI8oZCF5bE3nXdJxo7QWEpf7mqUtV/1VYl/9/tS8SsHW41CWWVpy8ug86 IhCQ== X-Gm-Message-State: APjAAAUmvWHERltrJoRNl6dkgMYuIVBMZ2Z2FwJQFDACc9eqy64hX0vY Mw+26J8upAAS6G0kbBlJZPQEQALG X-Google-Smtp-Source: APXvYqwcEMzwaNOiA92PIjeXDSc/AxkEbAT4quzy0ms2scZsajbMRma2w6av9ON1TRzbY93InRwF+w== X-Received: by 2002:adf:f581:: with SMTP id f1mr16415389wro.179.1561415328149; Mon, 24 Jun 2019 15:28:48 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Date: Tue, 25 Jun 2019 00:28:35 +0200 Message-Id: <20190624222844.26584-2-f4bug@amsat.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190624222844.26584-1-f4bug@amsat.org> References: <20190624222844.26584-1-f4bug@amsat.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::442 Subject: [Qemu-devel] [PATCH 01/10] hw/mips/gt64xxx_pci: Fix multiline comment syntax X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Peter Maydell , Thomas Huth , Aleksandar Rikalo , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , =?UTF-8?q?Herv=C3=A9=20Poussineau?= , Artyom Tarasenko , Aleksandar Markovic , Paolo Bonzini , Aurelien Jarno Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Since commit 8c06fbdf36b checkpatch.pl enforce a new multiline comment syntax. Since we'll move this code around, fix its style first. Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Aleksandar Markovic --- hw/mips/gt64xxx_pci.c | 64 +++++++++++++++++++++++-------------------- 1 file changed, 35 insertions(+), 29 deletions(-) diff --git a/hw/mips/gt64xxx_pci.c b/hw/mips/gt64xxx_pci.c index f707e59c7a..c0924646b5 100644 --- a/hw/mips/gt64xxx_pci.c +++ b/hw/mips/gt64xxx_pci.c @@ -248,10 +248,11 @@ typedef struct GT64120State { } GT64120State; =20 /* Adjust range to avoid touching space which isn't mappable via PCI */ -/* XXX: Hardcoded values for Malta: 0x1e000000 - 0x1f100000 - 0x1fc00000 - 0x1fd00000 */ -static void check_reserved_space (hwaddr *start, - hwaddr *length) +/* + * XXX: Hardcoded values for Malta: 0x1e000000 - 0x1f100000 + * 0x1fc00000 - 0x1fd00000 + */ +static void check_reserved_space(hwaddr *start, hwaddr *length) { hwaddr begin =3D *start; hwaddr end =3D *start + *length; @@ -650,8 +651,10 @@ static void gt64120_writel (void *opaque, hwaddr addr, case GT_SDRAM_B1: case GT_SDRAM_B2: case GT_SDRAM_B3: - /* We don't simulate electrical parameters of the SDRAM. - Accept, but ignore the values. */ + /* + * We don't simulate electrical parameters of the SDRAM. + * Accept, but ignore the values. + */ s->regs[saddr] =3D val; break; =20 @@ -674,8 +677,10 @@ static uint64_t gt64120_readl (void *opaque, =20 /* CPU Configuration */ case GT_MULTI: - /* Only one GT64xxx is present on the CPU bus, return - the initial value */ + /* + * Only one GT64xxx is present on the CPU bus, return + * the initial value. + */ val =3D s->regs[saddr]; break; =20 @@ -685,17 +690,18 @@ static uint64_t gt64120_readl (void *opaque, case GT_CPUERR_DATALO: case GT_CPUERR_DATAHI: case GT_CPUERR_PARITY: - /* Emulated memory has no error, always return the initial - values */ + /* Emulated memory has no error, always return the initial values.= */ val =3D s->regs[saddr]; break; =20 /* CPU Sync Barrier */ case GT_PCI0SYNC: case GT_PCI1SYNC: - /* Reading those register should empty all FIFO on the PCI - bus, which are not emulated. The return value should be - a random value that should be ignored. */ + /* + * Reading those register should empty all FIFO on the PCI + * bus, which are not emulated. The return value should be + * a random value that should be ignored. + */ val =3D 0xc000ffee; break; =20 @@ -705,8 +711,7 @@ static uint64_t gt64120_readl (void *opaque, case GT_ECC_MEM: case GT_ECC_CALC: case GT_ECC_ERRADDR: - /* Emulated memory has no error, always return the initial - values */ + /* Emulated memory has no error, always return the initial values.= */ val =3D s->regs[saddr]; break; =20 @@ -785,8 +790,10 @@ static uint64_t gt64120_readl (void *opaque, case GT_SDRAM_B1: case GT_SDRAM_B2: case GT_SDRAM_B3: - /* We don't simulate electrical parameters of the SDRAM. - Just return the last written value. */ + /* + * We don't simulate electrical parameters of the SDRAM. + * Just return the last written value. + */ val =3D s->regs[saddr]; break; =20 @@ -949,20 +956,20 @@ static int gt64120_pci_map_irq(PCIDevice *pci_dev, in= t irq_num) slot =3D (pci_dev->devfn >> 3); =20 switch (slot) { - /* PIIX4 USB */ - case 10: + /* PIIX4 USB */ + case 10: return 3; - /* AMD 79C973 Ethernet */ - case 11: + /* AMD 79C973 Ethernet */ + case 11: return 1; - /* Crystal 4281 Sound */ - case 12: + /* Crystal 4281 Sound */ + case 12: return 2; - /* PCI slot 1 to 4 */ - case 18 ... 21: + /* PCI slot 1 to 4 */ + case 18 ... 21: return ((slot - 18) + irq_num) & 0x03; - /* Unknown device, don't do any translation */ - default: + /* Unknown device, don't do any translation */ + default: return irq_num; } } @@ -980,8 +987,7 @@ static void gt64120_pci_set_irq(void *opaque, int irq_n= um, int level) /* XXX: optimize */ pic_irq =3D piix4_dev->config[0x60 + irq_num]; if (pic_irq < 16) { - /* The pic level is the logical OR of all the PCI irqs mapped - to it */ + /* The pic level is the logical OR of all the PCI irqs mapped to i= t. */ pic_level =3D 0; for (i =3D 0; i < 4; i++) { if (pic_irq =3D=3D piix4_dev->config[0x60 + i]) --=20 2.19.1 From nobody Wed May 8 01:55:32 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1561415541; cv=none; d=zoho.com; s=zohoarc; b=BTvpUTj2JTyIJkm6gEfvQX6S6+sGkTyTw/Mqd5ItCMTYhFptA14nFs6IUv5AYAqMJXLEduKw4QceCMtpoCCOrXp+GIwKO4TfGnFyTkSQVn+hX0pmowwOQlqQEn8YW+uhaW67vBFk/U29KCOPMT3/kTVRsB95Mus09zYmu7cAL+Q= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1561415541; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=YYl7ySgnYbSglcrqVRBmzU1Qj+0tLpaiLz2/ZpoWR08=; b=oKFLzF+y4rCdLr1v1RcLta/Cwf005UaYQ3NvZO+qwWv5py44JxhRZCbZEgpVicyR+PPOo+pih2HyIEXdVaVlQ72BZklGGkQv/IWYj5h8j1x58Mkw5574kSMzwSgRd8b0Ld32Ya9mWHIXcXNFucoWhn85Ljt35o4yXYqN8li3OsU= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1561415540996623.352187887642; Mon, 24 Jun 2019 15:32:20 -0700 (PDT) Received: from localhost ([::1]:55096 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXVc-0007EF-14 for importer@patchew.org; Mon, 24 Jun 2019 18:32:20 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34074) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXSL-00047R-M8 for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:28:59 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hfXSH-0005Jl-LJ for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:28:57 -0400 Received: from mail-wm1-x344.google.com ([2a00:1450:4864:20::344]:51859) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hfXSF-0005Et-Vf for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:28:52 -0400 Received: by mail-wm1-x344.google.com with SMTP id 207so839941wma.1 for ; Mon, 24 Jun 2019 15:28:50 -0700 (PDT) Received: from x1.local (183.red-88-21-202.staticip.rima-tde.net. [88.21.202.183]) by smtp.gmail.com with ESMTPSA id l1sm646781wmg.13.2019.06.24.15.28.48 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Mon, 24 Jun 2019 15:28:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=YYl7ySgnYbSglcrqVRBmzU1Qj+0tLpaiLz2/ZpoWR08=; b=sfSnJm59jzSwwZ50SGvY9J225P8mBx27jYxT3nwWSTse5BalmyZnr3jcQCJA3lydSs blGfejHeTFBAVEdHDEjBMTaWQ1zyWZ92JUeXSxKrOhCrGGHHpLwm8UgIMbaeLRqvuYyH hB//oJ6sTs9A6MXVIYVpAkjbFyQrE4mZzAp8HN9RzdamRP01pcrLXSchbMeyzRGfZZcu XhfiemufCYXuc5w1Fs1/l6q5DSccoi5MxvVXT8j9KSM8KT2rGDUkjwkNFDsqHdlpoBRA cUv/96wlAYdKMMP6HwnphDZ7EUt0ArUdXLRjUbJMR6ojS0qsZzrxUbCvbvET+O7BmjaH 1OIw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=YYl7ySgnYbSglcrqVRBmzU1Qj+0tLpaiLz2/ZpoWR08=; b=UTqihKPW2s986A1KaKuABskGdhE8MiiCEVDjhFGnHOvL3mj1mvIfA9E+q3lBPMB6d/ CltXlAP3UepuL1aXlTXKu6IVdkO4l0CKTri0UD6XuCmQnkiHhIMZSAmRIr4ihDHplqkn 94F9r6GXXouVvwrrVxpJpSr+Mco6D6SDytD9ga974c3DS2rMeOD5TC/GWevmDTsnUxBz Y/oiFlOXPgM+Sa2eCpgKv/+NeiDTo2O/WkMCJtByJEpmP0QgVFXgUDNLSJ/iCwnVvVRe QmI4EbBi1BmXHRr8ZafRaBf0n75kA9kN9mV/D7yVXd/FFVOAg+U9eKd8Gq4DHejv7KWK PoIQ== X-Gm-Message-State: APjAAAXzT51y/GQUtl6MrfqWy+gu8+1Ug15X/2tcERtf/SqJd5dbnVhk T/J5Ks0XVSg4Efq0pNx5r2ksdNrx X-Google-Smtp-Source: APXvYqwil3VFfYQiElzKt/26JhI8NfYq9EiAWbzrfxQ2OQeG51q9/TqnP/zWfmdXkQs3qud516tF8A== X-Received: by 2002:a1c:9e90:: with SMTP id h138mr18073169wme.67.1561415329365; Mon, 24 Jun 2019 15:28:49 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Date: Tue, 25 Jun 2019 00:28:36 +0200 Message-Id: <20190624222844.26584-3-f4bug@amsat.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190624222844.26584-1-f4bug@amsat.org> References: <20190624222844.26584-1-f4bug@amsat.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::344 Subject: [Qemu-devel] [PATCH 02/10] hw/mips/gt64xxx_pci: Fix 'tabs' coding style issues X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Peter Maydell , Thomas Huth , Aleksandar Rikalo , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , =?UTF-8?q?Herv=C3=A9=20Poussineau?= , Artyom Tarasenko , Aleksandar Markovic , Paolo Bonzini , Aurelien Jarno Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Since we'll move this code around, fix its style first: ERROR: code indent should never use tabs Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Aleksandar Markovic --- hw/mips/gt64xxx_pci.c | 312 +++++++++++++++++++++--------------------- 1 file changed, 156 insertions(+), 156 deletions(-) diff --git a/hw/mips/gt64xxx_pci.c b/hw/mips/gt64xxx_pci.c index c0924646b5..bbd719f091 100644 --- a/hw/mips/gt64xxx_pci.c +++ b/hw/mips/gt64xxx_pci.c @@ -38,192 +38,192 @@ #define DPRINTF(fmt, ...) #endif =20 -#define GT_REGS (0x1000 >> 2) +#define GT_REGS (0x1000 >> 2) =20 /* CPU Configuration */ -#define GT_CPU (0x000 >> 2) -#define GT_MULTI (0x120 >> 2) +#define GT_CPU (0x000 >> 2) +#define GT_MULTI (0x120 >> 2) =20 /* CPU Address Decode */ -#define GT_SCS10LD (0x008 >> 2) -#define GT_SCS10HD (0x010 >> 2) -#define GT_SCS32LD (0x018 >> 2) -#define GT_SCS32HD (0x020 >> 2) -#define GT_CS20LD (0x028 >> 2) -#define GT_CS20HD (0x030 >> 2) -#define GT_CS3BOOTLD (0x038 >> 2) -#define GT_CS3BOOTHD (0x040 >> 2) -#define GT_PCI0IOLD (0x048 >> 2) -#define GT_PCI0IOHD (0x050 >> 2) -#define GT_PCI0M0LD (0x058 >> 2) -#define GT_PCI0M0HD (0x060 >> 2) -#define GT_PCI0M1LD (0x080 >> 2) -#define GT_PCI0M1HD (0x088 >> 2) -#define GT_PCI1IOLD (0x090 >> 2) -#define GT_PCI1IOHD (0x098 >> 2) -#define GT_PCI1M0LD (0x0a0 >> 2) -#define GT_PCI1M0HD (0x0a8 >> 2) -#define GT_PCI1M1LD (0x0b0 >> 2) -#define GT_PCI1M1HD (0x0b8 >> 2) -#define GT_ISD (0x068 >> 2) - -#define GT_SCS10AR (0x0d0 >> 2) -#define GT_SCS32AR (0x0d8 >> 2) -#define GT_CS20R (0x0e0 >> 2) -#define GT_CS3BOOTR (0x0e8 >> 2) - -#define GT_PCI0IOREMAP (0x0f0 >> 2) -#define GT_PCI0M0REMAP (0x0f8 >> 2) -#define GT_PCI0M1REMAP (0x100 >> 2) -#define GT_PCI1IOREMAP (0x108 >> 2) -#define GT_PCI1M0REMAP (0x110 >> 2) -#define GT_PCI1M1REMAP (0x118 >> 2) +#define GT_SCS10LD (0x008 >> 2) +#define GT_SCS10HD (0x010 >> 2) +#define GT_SCS32LD (0x018 >> 2) +#define GT_SCS32HD (0x020 >> 2) +#define GT_CS20LD (0x028 >> 2) +#define GT_CS20HD (0x030 >> 2) +#define GT_CS3BOOTLD (0x038 >> 2) +#define GT_CS3BOOTHD (0x040 >> 2) +#define GT_PCI0IOLD (0x048 >> 2) +#define GT_PCI0IOHD (0x050 >> 2) +#define GT_PCI0M0LD (0x058 >> 2) +#define GT_PCI0M0HD (0x060 >> 2) +#define GT_PCI0M1LD (0x080 >> 2) +#define GT_PCI0M1HD (0x088 >> 2) +#define GT_PCI1IOLD (0x090 >> 2) +#define GT_PCI1IOHD (0x098 >> 2) +#define GT_PCI1M0LD (0x0a0 >> 2) +#define GT_PCI1M0HD (0x0a8 >> 2) +#define GT_PCI1M1LD (0x0b0 >> 2) +#define GT_PCI1M1HD (0x0b8 >> 2) +#define GT_ISD (0x068 >> 2) + +#define GT_SCS10AR (0x0d0 >> 2) +#define GT_SCS32AR (0x0d8 >> 2) +#define GT_CS20R (0x0e0 >> 2) +#define GT_CS3BOOTR (0x0e8 >> 2) + +#define GT_PCI0IOREMAP (0x0f0 >> 2) +#define GT_PCI0M0REMAP (0x0f8 >> 2) +#define GT_PCI0M1REMAP (0x100 >> 2) +#define GT_PCI1IOREMAP (0x108 >> 2) +#define GT_PCI1M0REMAP (0x110 >> 2) +#define GT_PCI1M1REMAP (0x118 >> 2) =20 /* CPU Error Report */ -#define GT_CPUERR_ADDRLO (0x070 >> 2) -#define GT_CPUERR_ADDRHI (0x078 >> 2) -#define GT_CPUERR_DATALO (0x128 >> 2) /* GT-64120A only */ -#define GT_CPUERR_DATAHI (0x130 >> 2) /* GT-64120A only */ -#define GT_CPUERR_PARITY (0x138 >> 2) /* GT-64120A only */ +#define GT_CPUERR_ADDRLO (0x070 >> 2) +#define GT_CPUERR_ADDRHI (0x078 >> 2) +#define GT_CPUERR_DATALO (0x128 >> 2) /* GT-64120A only */ +#define GT_CPUERR_DATAHI (0x130 >> 2) /* GT-64120A only */ +#define GT_CPUERR_PARITY (0x138 >> 2) /* GT-64120A only */ =20 /* CPU Sync Barrier */ -#define GT_PCI0SYNC (0x0c0 >> 2) -#define GT_PCI1SYNC (0x0c8 >> 2) +#define GT_PCI0SYNC (0x0c0 >> 2) +#define GT_PCI1SYNC (0x0c8 >> 2) =20 /* SDRAM and Device Address Decode */ -#define GT_SCS0LD (0x400 >> 2) -#define GT_SCS0HD (0x404 >> 2) -#define GT_SCS1LD (0x408 >> 2) -#define GT_SCS1HD (0x40c >> 2) -#define GT_SCS2LD (0x410 >> 2) -#define GT_SCS2HD (0x414 >> 2) -#define GT_SCS3LD (0x418 >> 2) -#define GT_SCS3HD (0x41c >> 2) -#define GT_CS0LD (0x420 >> 2) -#define GT_CS0HD (0x424 >> 2) -#define GT_CS1LD (0x428 >> 2) -#define GT_CS1HD (0x42c >> 2) -#define GT_CS2LD (0x430 >> 2) -#define GT_CS2HD (0x434 >> 2) -#define GT_CS3LD (0x438 >> 2) -#define GT_CS3HD (0x43c >> 2) -#define GT_BOOTLD (0x440 >> 2) -#define GT_BOOTHD (0x444 >> 2) -#define GT_ADERR (0x470 >> 2) +#define GT_SCS0LD (0x400 >> 2) +#define GT_SCS0HD (0x404 >> 2) +#define GT_SCS1LD (0x408 >> 2) +#define GT_SCS1HD (0x40c >> 2) +#define GT_SCS2LD (0x410 >> 2) +#define GT_SCS2HD (0x414 >> 2) +#define GT_SCS3LD (0x418 >> 2) +#define GT_SCS3HD (0x41c >> 2) +#define GT_CS0LD (0x420 >> 2) +#define GT_CS0HD (0x424 >> 2) +#define GT_CS1LD (0x428 >> 2) +#define GT_CS1HD (0x42c >> 2) +#define GT_CS2LD (0x430 >> 2) +#define GT_CS2HD (0x434 >> 2) +#define GT_CS3LD (0x438 >> 2) +#define GT_CS3HD (0x43c >> 2) +#define GT_BOOTLD (0x440 >> 2) +#define GT_BOOTHD (0x444 >> 2) +#define GT_ADERR (0x470 >> 2) =20 /* SDRAM Configuration */ -#define GT_SDRAM_CFG (0x448 >> 2) -#define GT_SDRAM_OPMODE (0x474 >> 2) -#define GT_SDRAM_BM (0x478 >> 2) -#define GT_SDRAM_ADDRDECODE (0x47c >> 2) +#define GT_SDRAM_CFG (0x448 >> 2) +#define GT_SDRAM_OPMODE (0x474 >> 2) +#define GT_SDRAM_BM (0x478 >> 2) +#define GT_SDRAM_ADDRDECODE (0x47c >> 2) =20 /* SDRAM Parameters */ -#define GT_SDRAM_B0 (0x44c >> 2) -#define GT_SDRAM_B1 (0x450 >> 2) -#define GT_SDRAM_B2 (0x454 >> 2) -#define GT_SDRAM_B3 (0x458 >> 2) +#define GT_SDRAM_B0 (0x44c >> 2) +#define GT_SDRAM_B1 (0x450 >> 2) +#define GT_SDRAM_B2 (0x454 >> 2) +#define GT_SDRAM_B3 (0x458 >> 2) =20 /* Device Parameters */ -#define GT_DEV_B0 (0x45c >> 2) -#define GT_DEV_B1 (0x460 >> 2) -#define GT_DEV_B2 (0x464 >> 2) -#define GT_DEV_B3 (0x468 >> 2) -#define GT_DEV_BOOT (0x46c >> 2) +#define GT_DEV_B0 (0x45c >> 2) +#define GT_DEV_B1 (0x460 >> 2) +#define GT_DEV_B2 (0x464 >> 2) +#define GT_DEV_B3 (0x468 >> 2) +#define GT_DEV_BOOT (0x46c >> 2) =20 /* ECC */ -#define GT_ECC_ERRDATALO (0x480 >> 2) /* GT-64120A only */ -#define GT_ECC_ERRDATAHI (0x484 >> 2) /* GT-64120A only */ -#define GT_ECC_MEM (0x488 >> 2) /* GT-64120A only */ -#define GT_ECC_CALC (0x48c >> 2) /* GT-64120A only */ -#define GT_ECC_ERRADDR (0x490 >> 2) /* GT-64120A only */ +#define GT_ECC_ERRDATALO (0x480 >> 2) /* GT-64120A only */ +#define GT_ECC_ERRDATAHI (0x484 >> 2) /* GT-64120A only */ +#define GT_ECC_MEM (0x488 >> 2) /* GT-64120A only */ +#define GT_ECC_CALC (0x48c >> 2) /* GT-64120A only */ +#define GT_ECC_ERRADDR (0x490 >> 2) /* GT-64120A only */ =20 /* DMA Record */ -#define GT_DMA0_CNT (0x800 >> 2) -#define GT_DMA1_CNT (0x804 >> 2) -#define GT_DMA2_CNT (0x808 >> 2) -#define GT_DMA3_CNT (0x80c >> 2) -#define GT_DMA0_SA (0x810 >> 2) -#define GT_DMA1_SA (0x814 >> 2) -#define GT_DMA2_SA (0x818 >> 2) -#define GT_DMA3_SA (0x81c >> 2) -#define GT_DMA0_DA (0x820 >> 2) -#define GT_DMA1_DA (0x824 >> 2) -#define GT_DMA2_DA (0x828 >> 2) -#define GT_DMA3_DA (0x82c >> 2) -#define GT_DMA0_NEXT (0x830 >> 2) -#define GT_DMA1_NEXT (0x834 >> 2) -#define GT_DMA2_NEXT (0x838 >> 2) -#define GT_DMA3_NEXT (0x83c >> 2) -#define GT_DMA0_CUR (0x870 >> 2) -#define GT_DMA1_CUR (0x874 >> 2) -#define GT_DMA2_CUR (0x878 >> 2) -#define GT_DMA3_CUR (0x87c >> 2) +#define GT_DMA0_CNT (0x800 >> 2) +#define GT_DMA1_CNT (0x804 >> 2) +#define GT_DMA2_CNT (0x808 >> 2) +#define GT_DMA3_CNT (0x80c >> 2) +#define GT_DMA0_SA (0x810 >> 2) +#define GT_DMA1_SA (0x814 >> 2) +#define GT_DMA2_SA (0x818 >> 2) +#define GT_DMA3_SA (0x81c >> 2) +#define GT_DMA0_DA (0x820 >> 2) +#define GT_DMA1_DA (0x824 >> 2) +#define GT_DMA2_DA (0x828 >> 2) +#define GT_DMA3_DA (0x82c >> 2) +#define GT_DMA0_NEXT (0x830 >> 2) +#define GT_DMA1_NEXT (0x834 >> 2) +#define GT_DMA2_NEXT (0x838 >> 2) +#define GT_DMA3_NEXT (0x83c >> 2) +#define GT_DMA0_CUR (0x870 >> 2) +#define GT_DMA1_CUR (0x874 >> 2) +#define GT_DMA2_CUR (0x878 >> 2) +#define GT_DMA3_CUR (0x87c >> 2) =20 /* DMA Channel Control */ -#define GT_DMA0_CTRL (0x840 >> 2) -#define GT_DMA1_CTRL (0x844 >> 2) -#define GT_DMA2_CTRL (0x848 >> 2) -#define GT_DMA3_CTRL (0x84c >> 2) +#define GT_DMA0_CTRL (0x840 >> 2) +#define GT_DMA1_CTRL (0x844 >> 2) +#define GT_DMA2_CTRL (0x848 >> 2) +#define GT_DMA3_CTRL (0x84c >> 2) =20 /* DMA Arbiter */ -#define GT_DMA_ARB (0x860 >> 2) +#define GT_DMA_ARB (0x860 >> 2) =20 /* Timer/Counter */ -#define GT_TC0 (0x850 >> 2) -#define GT_TC1 (0x854 >> 2) -#define GT_TC2 (0x858 >> 2) -#define GT_TC3 (0x85c >> 2) -#define GT_TC_CONTROL (0x864 >> 2) +#define GT_TC0 (0x850 >> 2) +#define GT_TC1 (0x854 >> 2) +#define GT_TC2 (0x858 >> 2) +#define GT_TC3 (0x85c >> 2) +#define GT_TC_CONTROL (0x864 >> 2) =20 /* PCI Internal */ -#define GT_PCI0_CMD (0xc00 >> 2) -#define GT_PCI0_TOR (0xc04 >> 2) -#define GT_PCI0_BS_SCS10 (0xc08 >> 2) -#define GT_PCI0_BS_SCS32 (0xc0c >> 2) -#define GT_PCI0_BS_CS20 (0xc10 >> 2) -#define GT_PCI0_BS_CS3BT (0xc14 >> 2) -#define GT_PCI1_IACK (0xc30 >> 2) -#define GT_PCI0_IACK (0xc34 >> 2) -#define GT_PCI0_BARE (0xc3c >> 2) -#define GT_PCI0_PREFMBR (0xc40 >> 2) -#define GT_PCI0_SCS10_BAR (0xc48 >> 2) -#define GT_PCI0_SCS32_BAR (0xc4c >> 2) -#define GT_PCI0_CS20_BAR (0xc50 >> 2) -#define GT_PCI0_CS3BT_BAR (0xc54 >> 2) -#define GT_PCI0_SSCS10_BAR (0xc58 >> 2) -#define GT_PCI0_SSCS32_BAR (0xc5c >> 2) -#define GT_PCI0_SCS3BT_BAR (0xc64 >> 2) -#define GT_PCI1_CMD (0xc80 >> 2) -#define GT_PCI1_TOR (0xc84 >> 2) -#define GT_PCI1_BS_SCS10 (0xc88 >> 2) -#define GT_PCI1_BS_SCS32 (0xc8c >> 2) -#define GT_PCI1_BS_CS20 (0xc90 >> 2) -#define GT_PCI1_BS_CS3BT (0xc94 >> 2) -#define GT_PCI1_BARE (0xcbc >> 2) -#define GT_PCI1_PREFMBR (0xcc0 >> 2) -#define GT_PCI1_SCS10_BAR (0xcc8 >> 2) -#define GT_PCI1_SCS32_BAR (0xccc >> 2) -#define GT_PCI1_CS20_BAR (0xcd0 >> 2) -#define GT_PCI1_CS3BT_BAR (0xcd4 >> 2) -#define GT_PCI1_SSCS10_BAR (0xcd8 >> 2) -#define GT_PCI1_SSCS32_BAR (0xcdc >> 2) -#define GT_PCI1_SCS3BT_BAR (0xce4 >> 2) -#define GT_PCI1_CFGADDR (0xcf0 >> 2) -#define GT_PCI1_CFGDATA (0xcf4 >> 2) -#define GT_PCI0_CFGADDR (0xcf8 >> 2) -#define GT_PCI0_CFGDATA (0xcfc >> 2) +#define GT_PCI0_CMD (0xc00 >> 2) +#define GT_PCI0_TOR (0xc04 >> 2) +#define GT_PCI0_BS_SCS10 (0xc08 >> 2) +#define GT_PCI0_BS_SCS32 (0xc0c >> 2) +#define GT_PCI0_BS_CS20 (0xc10 >> 2) +#define GT_PCI0_BS_CS3BT (0xc14 >> 2) +#define GT_PCI1_IACK (0xc30 >> 2) +#define GT_PCI0_IACK (0xc34 >> 2) +#define GT_PCI0_BARE (0xc3c >> 2) +#define GT_PCI0_PREFMBR (0xc40 >> 2) +#define GT_PCI0_SCS10_BAR (0xc48 >> 2) +#define GT_PCI0_SCS32_BAR (0xc4c >> 2) +#define GT_PCI0_CS20_BAR (0xc50 >> 2) +#define GT_PCI0_CS3BT_BAR (0xc54 >> 2) +#define GT_PCI0_SSCS10_BAR (0xc58 >> 2) +#define GT_PCI0_SSCS32_BAR (0xc5c >> 2) +#define GT_PCI0_SCS3BT_BAR (0xc64 >> 2) +#define GT_PCI1_CMD (0xc80 >> 2) +#define GT_PCI1_TOR (0xc84 >> 2) +#define GT_PCI1_BS_SCS10 (0xc88 >> 2) +#define GT_PCI1_BS_SCS32 (0xc8c >> 2) +#define GT_PCI1_BS_CS20 (0xc90 >> 2) +#define GT_PCI1_BS_CS3BT (0xc94 >> 2) +#define GT_PCI1_BARE (0xcbc >> 2) +#define GT_PCI1_PREFMBR (0xcc0 >> 2) +#define GT_PCI1_SCS10_BAR (0xcc8 >> 2) +#define GT_PCI1_SCS32_BAR (0xccc >> 2) +#define GT_PCI1_CS20_BAR (0xcd0 >> 2) +#define GT_PCI1_CS3BT_BAR (0xcd4 >> 2) +#define GT_PCI1_SSCS10_BAR (0xcd8 >> 2) +#define GT_PCI1_SSCS32_BAR (0xcdc >> 2) +#define GT_PCI1_SCS3BT_BAR (0xce4 >> 2) +#define GT_PCI1_CFGADDR (0xcf0 >> 2) +#define GT_PCI1_CFGDATA (0xcf4 >> 2) +#define GT_PCI0_CFGADDR (0xcf8 >> 2) +#define GT_PCI0_CFGDATA (0xcfc >> 2) =20 /* Interrupts */ -#define GT_INTRCAUSE (0xc18 >> 2) -#define GT_INTRMASK (0xc1c >> 2) -#define GT_PCI0_ICMASK (0xc24 >> 2) -#define GT_PCI0_SERR0MASK (0xc28 >> 2) -#define GT_CPU_INTSEL (0xc70 >> 2) -#define GT_PCI0_INTSEL (0xc74 >> 2) -#define GT_HINTRCAUSE (0xc98 >> 2) -#define GT_HINTRMASK (0xc9c >> 2) -#define GT_PCI0_HICMASK (0xca4 >> 2) -#define GT_PCI1_SERR1MASK (0xca8 >> 2) +#define GT_INTRCAUSE (0xc18 >> 2) +#define GT_INTRMASK (0xc1c >> 2) +#define GT_PCI0_ICMASK (0xc24 >> 2) +#define GT_PCI0_SERR0MASK (0xc28 >> 2) +#define GT_CPU_INTSEL (0xc70 >> 2) +#define GT_PCI0_INTSEL (0xc74 >> 2) +#define GT_HINTRCAUSE (0xc98 >> 2) +#define GT_HINTRMASK (0xc9c >> 2) +#define GT_PCI0_HICMASK (0xca4 >> 2) +#define GT_PCI1_SERR1MASK (0xca8 >> 2) =20 #define PCI_MAPPING_ENTRY(regname) \ hwaddr regname ##_start; \ --=20 2.19.1 From nobody Wed May 8 01:55:32 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1561416085; cv=none; d=zoho.com; s=zohoarc; b=W7bnj7zzjjEXYFbcWSzFnAUW0bRz2MqC1Av9XgReAflSDH5Y2dYtRAk7U0rsIuYgxqpj8CaKfbm2o/+Vk7jmtVVYLYur4OShDxmdPfQ/br3ccS87H8AndmaacJmoYELpl/5ao9oMxeR+LwB4+OXN84BbxiciqiwETga7ynxk2d0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1561416085; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=5dXEvYdBuMJfEvXkir0hEhmfw03d7UAVN7/M5JOtto0=; b=kLXf+G+60/xhBUGTDAwkhm5aKfY7CYR4GskcgdL6dsjOM+6Q+7hvslhxfuZZi/viCyiTUTwJ5vBZgjCB/B+jAkeuo6M7YZlMaGpafd45AdsHA9z1OjgIFbgTqWpoJ92ZclP7jvuA65suF3De9qtnOAvJkypMuFnnk1Ykf5kDXTY= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1561416085928124.15156313883722; Mon, 24 Jun 2019 15:41:25 -0700 (PDT) Received: from localhost ([::1]:55144 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXeH-0005F3-IE for importer@patchew.org; Mon, 24 Jun 2019 18:41:17 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34067) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXSL-00047M-LY for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:28:59 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hfXSH-0005KB-Or for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:28:55 -0400 Received: from mail-wm1-x342.google.com ([2a00:1450:4864:20::342]:37680) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hfXSH-0005G9-II for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:28:53 -0400 Received: by mail-wm1-x342.google.com with SMTP id f17so878767wme.2 for ; Mon, 24 Jun 2019 15:28:51 -0700 (PDT) Received: from x1.local (183.red-88-21-202.staticip.rima-tde.net. [88.21.202.183]) by smtp.gmail.com with ESMTPSA id l1sm646781wmg.13.2019.06.24.15.28.49 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Mon, 24 Jun 2019 15:28:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=5dXEvYdBuMJfEvXkir0hEhmfw03d7UAVN7/M5JOtto0=; b=vgoGK1s5qWODw5qrxDj2KbfQuVz/Ek2j+3yC2Bd0DhthPj/Y2l0VMCFSgwOh6XiIQI cM5gscqDJhwHFLSdobBFt5wxNFo0ESF/YMoNB0KJsMRYxn7XnZtXoxxLLTFlmgFEVHnw FX2w5qmD5iyltJ+Zt6bMzjQW41CGjgmfxJIa7xLXb5CXHDB2DpU0uOVdtzXhgLgYIS01 7iFiAlh45RgEbrlQipclGf5EfZ3+IEoPUyEmY4NG/Nj877L082JBjfTIPgu2t0bOumyz 2hwlIrqzTyzlOskBtkTMeRARdREiB4iPQpYY3Z7dG0abPBB8X8RUouK+awFPvqxFXv/J Jh9w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=5dXEvYdBuMJfEvXkir0hEhmfw03d7UAVN7/M5JOtto0=; b=jYJ0PTRMHpzUMDO2j5eHBg2nMWJw6cq1agm24JZyq8w5fjKhxysqzZ4kaz+JYqx6zk qGk7EipWmFcgP8DynsZ/UcLq+ht1Txh0SgfU6i23RwE4fCUNfGSjd3kWhjSoLOfze9yY 9PiDH4DJrOBbrt0xyVMPN28GFb3+Pd447wIKx7Qfrz+yY6sZ7W2eRNt+ootVXyGJZpwO IGqNZpBoG8Hiu/o2auFMJAt+cMQjan5yAj7+SQqIYOgdnMe98CRa8MQGYNdsLShrrRXb iqEobpoVYYB9Qathd+21pzh1KjeazTLKMk7ao21XeShSHxXiMmK/gvcryFlkmt4CqtEK Maqw== X-Gm-Message-State: APjAAAVV10cfQ6Oi6bcEgvZ5zeI6i7Qr+fac167S+BM8p36vJko13BGr KOquRHwf/M9cri6mxFAKLOGx3947 X-Google-Smtp-Source: APXvYqxo5nOW6kvYQcwr/iUQcYmi5fgCXXYDXuJQ8qM2MCFHVFBFuKaGjxdBG+EjeDEcilA8sH8Dqw== X-Received: by 2002:a1c:20cf:: with SMTP id g198mr5482204wmg.88.1561415330618; Mon, 24 Jun 2019 15:28:50 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Date: Tue, 25 Jun 2019 00:28:37 +0200 Message-Id: <20190624222844.26584-4-f4bug@amsat.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190624222844.26584-1-f4bug@amsat.org> References: <20190624222844.26584-1-f4bug@amsat.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::342 Subject: [Qemu-devel] [PATCH 03/10] hw/mips/gt64xxx_pci: Fix 'braces' coding style issues X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Peter Maydell , Thomas Huth , Aleksandar Rikalo , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , =?UTF-8?q?Herv=C3=A9=20Poussineau?= , Artyom Tarasenko , Aleksandar Markovic , Paolo Bonzini , Aurelien Jarno Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Since we'll move this code around, fix its style first: ERROR: braces {} are necessary for all arms of this statement Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Aleksandar Markovic --- hw/mips/gt64xxx_pci.c | 27 ++++++++++++++++++--------- 1 file changed, 18 insertions(+), 9 deletions(-) diff --git a/hw/mips/gt64xxx_pci.c b/hw/mips/gt64xxx_pci.c index bbd719f091..cfd497960c 100644 --- a/hw/mips/gt64xxx_pci.c +++ b/hw/mips/gt64xxx_pci.c @@ -257,19 +257,25 @@ static void check_reserved_space(hwaddr *start, hwadd= r *length) hwaddr begin =3D *start; hwaddr end =3D *start + *length; =20 - if (end >=3D 0x1e000000LL && end < 0x1f100000LL) + if (end >=3D 0x1e000000LL && end < 0x1f100000LL) { end =3D 0x1e000000LL; - if (begin >=3D 0x1e000000LL && begin < 0x1f100000LL) + } + if (begin >=3D 0x1e000000LL && begin < 0x1f100000LL) { begin =3D 0x1f100000LL; - if (end >=3D 0x1fc00000LL && end < 0x1fd00000LL) + } + if (end >=3D 0x1fc00000LL && end < 0x1fd00000LL) { end =3D 0x1fc00000LL; - if (begin >=3D 0x1fc00000LL && begin < 0x1fd00000LL) + } + if (begin >=3D 0x1fc00000LL && begin < 0x1fd00000LL) { begin =3D 0x1fd00000LL; + } /* XXX: This is broken when a reserved range splits the requested rang= e */ - if (end >=3D 0x1f100000LL && begin < 0x1e000000LL) + if (end >=3D 0x1f100000LL && begin < 0x1e000000LL) { end =3D 0x1e000000LL; - if (end >=3D 0x1fd00000LL && begin < 0x1fc00000LL) + } + if (end >=3D 0x1fd00000LL && begin < 0x1fc00000LL) { end =3D 0x1fc00000LL; + } =20 *start =3D begin; *length =3D end - begin; @@ -385,8 +391,9 @@ static void gt64120_writel (void *opaque, hwaddr addr, PCIHostState *phb =3D PCI_HOST_BRIDGE(s); uint32_t saddr; =20 - if (!(s->regs[GT_CPU] & 0x00001000)) + if (!(s->regs[GT_CPU] & 0x00001000)) { val =3D bswap32(val); + } =20 saddr =3D (addr & 0xfff) >> 2; switch (saddr) { @@ -937,8 +944,9 @@ static uint64_t gt64120_readl (void *opaque, break; } =20 - if (!(s->regs[GT_CPU] & 0x00001000)) + if (!(s->regs[GT_CPU] & 0x00001000)) { val =3D bswap32(val); + } =20 return val; } @@ -990,8 +998,9 @@ static void gt64120_pci_set_irq(void *opaque, int irq_n= um, int level) /* The pic level is the logical OR of all the PCI irqs mapped to i= t. */ pic_level =3D 0; for (i =3D 0; i < 4; i++) { - if (pic_irq =3D=3D piix4_dev->config[0x60 + i]) + if (pic_irq =3D=3D piix4_dev->config[0x60 + i]) { pic_level |=3D pci_irq_levels[i]; + } } qemu_set_irq(pic[pic_irq], pic_level); } --=20 2.19.1 From nobody Wed May 8 01:55:32 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1561415437; cv=none; d=zoho.com; s=zohoarc; b=EGddhxSv2wGS4gAw7SVT5BIaT3TTqtkxNBd6ODaEILwJsUHfKXbXT18DkaeYmE6GGQtf67Uk0O1Lxv+l+YpN4i7aqEjEtIZgUhjZ9EV8TwLY3isoAs9FNhPYQ/OaUN9wRNeT9MQYFxVjYWOtu2JgIV+XuDj+umVVd76VGxqmL0I= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1561415437; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=B16UC5jpLoiB2eLXN09Oz9O+5YpGIzoXUKS3ahIfaxM=; b=dzPwywjvPAo5Eilt5QwhFwykk/t1XElw8kP1P+dodEyiqPUmJvmfL4yc3yR1Nm/ieinnk0tMWvWDnhSV3EpaUvXSE97WPeyMz7KVECAeeRq27kw9qg1zX3m6C0I+3WACr7ZAmhwi/tiIYoJIiDwo9UIOdnTPyzcXhYXBZMqYK2w= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1561415437872862.8978088226705; Mon, 24 Jun 2019 15:30:37 -0700 (PDT) Received: from localhost ([::1]:55082 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXTp-0005bn-Sq for importer@patchew.org; Mon, 24 Jun 2019 18:30:29 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34120) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXSN-000495-WE for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:29:01 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hfXSL-0005Lm-IR for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:28:59 -0400 Received: from mail-wm1-x341.google.com ([2a00:1450:4864:20::341]:34769) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hfXSH-0005HH-L1 for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:28:53 -0400 Received: by mail-wm1-x341.google.com with SMTP id w9so919719wmd.1 for ; Mon, 24 Jun 2019 15:28:52 -0700 (PDT) Received: from x1.local (183.red-88-21-202.staticip.rima-tde.net. [88.21.202.183]) by smtp.gmail.com with ESMTPSA id l1sm646781wmg.13.2019.06.24.15.28.50 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Mon, 24 Jun 2019 15:28:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=B16UC5jpLoiB2eLXN09Oz9O+5YpGIzoXUKS3ahIfaxM=; b=CKWKMr13uVcD39gXizeBevl8HbVjB8O8Gp0lS6DlHbl0nW1I2dqWSDpvOEMJa3Q5fs WpJTLL8qUTE/fmluRYlKoFwQqEe7xaFC+aNBRGmddV4Xyr7Ob38l3u02UZHrJ5UlZeDg xB1uxwN3f37Ud2TvRwqNP8sU2nuZ6vLikn317Mps8cUdywFKxG2BVWIL43x29T1Ei7lF R4eYhL2XXQ4lBLsnaq/LusvnKOG8Fw/LOZAquIsMnzSu6LZVf4CYiVFc1kGplRrQcQ++ 7JyaUALAc6U0COZzWUo+2u3rBEWCqO+fjj3J+9jtZnCr6WdFSapKnYDMyUs6Ybouvcby gLxg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=B16UC5jpLoiB2eLXN09Oz9O+5YpGIzoXUKS3ahIfaxM=; b=UMRgsafW9d0wzk6FzoyyXe7bfuLm9i+S06eM4fRuQhr8N53yC3mXJL97uugavRO/p5 H2BmmH4aEweEraj9lYnbv2XsqvJhTvoX/AIp4wIb7a1kP+r+JBJWW7GBg97gnc9yFHQI s40fqfFVwj6p+h5hmyNYWL9deffllTi+VDS5fS9JWfyUdHENf/vc30hRmNva3cvMrLQl PWkXsa7z8sIxTEKWwqa2VB9Z1QtQPd+wgrqC3txhk6Y/tfLHBFv7R2dttFCyZFHnNqv0 1BbmGHI53UnTcECGcRKb99zp03X9uGZBp/fQXmyefF92l8TEjqW7ZOetjswBNIdIiNfu yjIw== X-Gm-Message-State: APjAAAXhfIOLt8RnFwGju6RJZtZxRAA7LM1EAASGTfK/byYp9P27tKFQ jwdOlo3KsjHSYkAABixKz8CKi8Ft X-Google-Smtp-Source: APXvYqzx6dGBxEHnOqRH2pcxMWJdYDkNhoPgcHMlPPPj1CFcDaxFDNG1dKu0FvMuHqkepTlSORyurQ== X-Received: by 2002:a7b:c933:: with SMTP id h19mr18076367wml.52.1561415331785; Mon, 24 Jun 2019 15:28:51 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Date: Tue, 25 Jun 2019 00:28:38 +0200 Message-Id: <20190624222844.26584-5-f4bug@amsat.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190624222844.26584-1-f4bug@amsat.org> References: <20190624222844.26584-1-f4bug@amsat.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::341 Subject: [Qemu-devel] [PATCH 04/10] hw/mips/gt64xxx_pci: Fix 'spaces' coding style issues X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Peter Maydell , Thomas Huth , Aleksandar Rikalo , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , =?UTF-8?q?Herv=C3=A9=20Poussineau?= , Artyom Tarasenko , Aleksandar Markovic , Paolo Bonzini , Aurelien Jarno Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Since we'll move this code around, fix its style first: ERROR: space prohibited between function name and open parenthesis ERROR: line over 90 characters Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Aleksandar Markovic --- hw/mips/gt64xxx_pci.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/hw/mips/gt64xxx_pci.c b/hw/mips/gt64xxx_pci.c index cfd497960c..0b9fb02475 100644 --- a/hw/mips/gt64xxx_pci.c +++ b/hw/mips/gt64xxx_pci.c @@ -384,8 +384,8 @@ static const VMStateDescription vmstate_gt64120 =3D { } }; =20 -static void gt64120_writel (void *opaque, hwaddr addr, - uint64_t val, unsigned size) +static void gt64120_writel(void *opaque, hwaddr addr, + uint64_t val, unsigned size) { GT64120State *s =3D opaque; PCIHostState *phb =3D PCI_HOST_BRIDGE(s); @@ -671,8 +671,8 @@ static void gt64120_writel (void *opaque, hwaddr addr, } } =20 -static uint64_t gt64120_readl (void *opaque, - hwaddr addr, unsigned size) +static uint64_t gt64120_readl(void *opaque, + hwaddr addr, unsigned size) { GT64120State *s =3D opaque; PCIHostState *phb =3D PCI_HOST_BRIDGE(s); @@ -1193,7 +1193,8 @@ PCIBus *gt64120_register(qemu_irq *pic) get_system_io(), PCI_DEVFN(18, 0), 4, TYPE_PCI_BUS); qdev_init_nofail(dev); - memory_region_init_io(&d->ISD_mem, OBJECT(dev), &isd_mem_ops, d, "isd-= mem", 0x1000); + memory_region_init_io(&d->ISD_mem, OBJECT(dev), &isd_mem_ops, d, + "isd-mem", 0x1000); =20 pci_create_simple(phb->bus, PCI_DEVFN(0, 0), "gt64120_pci"); return phb->bus; --=20 2.19.1 From nobody Wed May 8 01:55:32 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1561416235; cv=none; d=zoho.com; s=zohoarc; b=k1Og90gGA87lcFiYuFAH4aBtboQlGuq2P+d8ac/C+KaV4LlhectpZooAOopnnKTZHQ7OWE1vF7FRlq5KjReQMQwIw2CH8KYF/eeoMuH/zapeX8hNxuo+frl34p2YTSN8zxp73vYcUBPuNaOi5Wee+rOL/aenyaNTaklhrWk8OcE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1561416235; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=/SgTNPPsJfCxHETluQbG5NnxhDJEDStW+F5nN1fBiA4=; b=iAqCkqiQLAa2Ioq1BTV8vHnFj8HmK1lPx5PkIbKZ9CDJnMXUN+Ka9VYEZZURQo81mq3LkS/7M9mQlS43uy4vXayBNfwOYMSvNtBFKt2zQYxKhOxCJ4X0QfiAii5hxlLwRXGsNrro0fzFR/UecRW0SmgdAytVNWsuWiQuacvMxoU= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (209.51.188.17 [209.51.188.17]) by mx.zohomail.com with SMTPS id 1561416235639265.9636913551757; Mon, 24 Jun 2019 15:43:55 -0700 (PDT) Received: from localhost ([::1]:55168 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXgj-000826-J7 for importer@patchew.org; Mon, 24 Jun 2019 18:43:49 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34119) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXSN-000493-Vt for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:29:01 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hfXSL-0005Md-Qf for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:28:59 -0400 Received: from mail-wm1-x344.google.com ([2a00:1450:4864:20::344]:35468) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hfXSL-0005JT-J3 for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:28:57 -0400 Received: by mail-wm1-x344.google.com with SMTP id c6so891826wml.0 for ; Mon, 24 Jun 2019 15:28:54 -0700 (PDT) Received: from x1.local (183.red-88-21-202.staticip.rima-tde.net. [88.21.202.183]) by smtp.gmail.com with ESMTPSA id l1sm646781wmg.13.2019.06.24.15.28.51 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Mon, 24 Jun 2019 15:28:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=/SgTNPPsJfCxHETluQbG5NnxhDJEDStW+F5nN1fBiA4=; b=n261ZvXHjr+N/pglJVMtesxuU17Fh2nAO+2wEwC0m/S9W0bFfNfAI1AGgfqihJBaMA 2G/lfmf8M9KuJsK0hklVa8qEPx6MSWSuCcnoZAMGmbDo5KoOfkqi9FyVKHtXZ610v5Op sLom89ZZ9/y6xvBh2zWLLxKOxoVHz0meymM3eEPoGo/44oVFLDt06hpvc8QqHL3DOT/4 ha/txKCbEsaIBTLvgx0a2aIOinL41ktlujIooEulOwSbIOyUp/q5zN4b6qDh7V5U9Efe ZYYqzSyJU3ZnZT8Lyn370mqqPC5HV1K1y9zRAkGM5Myy6/wJrV6QP6qNUjD6v7fvCcgF ra8A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=/SgTNPPsJfCxHETluQbG5NnxhDJEDStW+F5nN1fBiA4=; b=IpXHaBLAi+sanPw7DGXBwiLIDmMW9Bjjvx5JxKsS4rN6BtWXHCTTvKktLg97Fdtj8c gwxJF22LnsztuaNT0CfvXaxGuK6wXd4W6xIxrnVLd8wpMdaIbC8ZGUzmRgncrMasAIX2 6vgGnxMZWvWJ18wDxxFI5P9TAPkv22CRKdbbHFacF34ivBwS69ZBP/TrKoQMv1VZ7A22 JQxAR0yN9cRNX6rXSKR5odrrNGb4x9l3gXIGgBZ3Zv9FimhK7crs01ufJsAnskPCJn+4 s/1ly2Wt5bjO8Z2yp5BpffkP2fDD/s4xOfOIiA65bWRelhSO3o0jltgiY6qyKwneET+P R9Ug== X-Gm-Message-State: APjAAAXeb4GZR3OWEEKN8KfvgehESJ3IbAPOskrxjiDOXTUIUw2BqSbj I441ogtKk5ejKtJnqk1BvKX+ceFc X-Google-Smtp-Source: APXvYqxWDLhu44DmFzobLzftBpLohxi0WgtigD3Bp1eHtcAqb08ysyW1j73j/4e+C9IQPMBtZYoqPQ== X-Received: by 2002:a1c:a848:: with SMTP id r69mr16797119wme.12.1561415332999; Mon, 24 Jun 2019 15:28:52 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Date: Tue, 25 Jun 2019 00:28:39 +0200 Message-Id: <20190624222844.26584-6-f4bug@amsat.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190624222844.26584-1-f4bug@amsat.org> References: <20190624222844.26584-1-f4bug@amsat.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::344 Subject: [Qemu-devel] [PATCH 05/10] hw/mips/gt64xxx_pci: Use qemu_log_mask() instead of debug printf() X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Peter Maydell , Thomas Huth , Aleksandar Rikalo , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , =?UTF-8?q?Herv=C3=A9=20Poussineau?= , Artyom Tarasenko , Aleksandar Markovic , Paolo Bonzini , Aurelien Jarno Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Aleksandar Markovic --- hw/mips/gt64xxx_pci.c | 48 +++++++++++++++++++++++++++++++++---------- 1 file changed, 37 insertions(+), 11 deletions(-) diff --git a/hw/mips/gt64xxx_pci.c b/hw/mips/gt64xxx_pci.c index 0b9fb02475..f44326f14f 100644 --- a/hw/mips/gt64xxx_pci.c +++ b/hw/mips/gt64xxx_pci.c @@ -23,6 +23,7 @@ */ =20 #include "qemu/osdep.h" +#include "qemu/log.h" #include "hw/hw.h" #include "hw/mips/mips.h" #include "hw/pci/pci.h" @@ -466,12 +467,20 @@ static void gt64120_writel(void *opaque, hwaddr addr, case GT_CPUERR_DATAHI: case GT_CPUERR_PARITY: /* Read-only registers, do nothing */ + qemu_log_mask(LOG_GUEST_ERROR, + "gt64120: Read-only register write " + "reg:0x03%x size:%u value:0x%0*" PRIx64 "\n", + saddr << 2, size, size << 1, val); break; =20 /* CPU Sync Barrier */ case GT_PCI0SYNC: case GT_PCI1SYNC: /* Read-only registers, do nothing */ + qemu_log_mask(LOG_GUEST_ERROR, + "gt64120: Read-only register write " + "reg:0x03%x size:%u value:0x%0*" PRIx64 "\n", + saddr << 2, size, size << 1, val); break; =20 /* SDRAM and Device Address Decode */ @@ -510,7 +519,10 @@ static void gt64120_writel(void *opaque, hwaddr addr, case GT_DEV_B3: case GT_DEV_BOOT: /* Not implemented */ - DPRINTF ("Unimplemented device register offset 0x%x\n", saddr << 2= ); + qemu_log_mask(LOG_UNIMP, + "gt64120: Unimplemented device register write " + "reg:0x03%x size:%u value:0x%0*" PRIx64 "\n", + saddr << 2, size, size << 1, val); break; =20 /* ECC */ @@ -520,6 +532,10 @@ static void gt64120_writel(void *opaque, hwaddr addr, case GT_ECC_CALC: case GT_ECC_ERRADDR: /* Read-only registers, do nothing */ + qemu_log_mask(LOG_GUEST_ERROR, + "gt64120: Read-only register write " + "reg:0x03%x size:%u value:0x%0*" PRIx64 "\n", + saddr << 2, size, size << 1, val); break; =20 /* DMA Record */ @@ -543,23 +559,20 @@ static void gt64120_writel(void *opaque, hwaddr addr, case GT_DMA1_CUR: case GT_DMA2_CUR: case GT_DMA3_CUR: - /* Not implemented */ - DPRINTF ("Unimplemented DMA register offset 0x%x\n", saddr << 2); - break; =20 /* DMA Channel Control */ case GT_DMA0_CTRL: case GT_DMA1_CTRL: case GT_DMA2_CTRL: case GT_DMA3_CTRL: - /* Not implemented */ - DPRINTF ("Unimplemented DMA register offset 0x%x\n", saddr << 2); - break; =20 /* DMA Arbiter */ case GT_DMA_ARB: /* Not implemented */ - DPRINTF ("Unimplemented DMA register offset 0x%x\n", saddr << 2); + qemu_log_mask(LOG_UNIMP, + "gt64120: Unimplemented DMA register write " + "reg:0x03%x size:%u value:0x%0*" PRIx64 "\n", + saddr << 2, size, size << 1, val); break; =20 /* Timer/Counter */ @@ -569,7 +582,10 @@ static void gt64120_writel(void *opaque, hwaddr addr, case GT_TC3: case GT_TC_CONTROL: /* Not implemented */ - DPRINTF ("Unimplemented timer register offset 0x%x\n", saddr << 2); + qemu_log_mask(LOG_UNIMP, + "gt64120: Unimplemented timer register write " + "reg:0x03%x size:%u value:0x%0*" PRIx64 "\n", + saddr << 2, size, size << 1, val); break; =20 /* PCI Internal */ @@ -610,6 +626,10 @@ static void gt64120_writel(void *opaque, hwaddr addr, case GT_PCI1_CFGADDR: case GT_PCI1_CFGDATA: /* not implemented */ + qemu_log_mask(LOG_UNIMP, + "gt64120: Unimplemented timer register write " + "reg:0x03%x size:%u value:0x%0*" PRIx64 "\n", + saddr << 2, size, size << 1, val); break; case GT_PCI0_CFGADDR: phb->config_reg =3D val & 0x80fffffc; @@ -666,7 +686,10 @@ static void gt64120_writel(void *opaque, hwaddr addr, break; =20 default: - DPRINTF ("Bad register offset 0x%x\n", (int)addr); + qemu_log_mask(LOG_GUEST_ERROR, + "gt64120: Illegal register write " + "reg:0x03%x size:%u value:0x%0*" PRIx64 "\n", + saddr << 2, size, size << 1, val); break; } } @@ -940,7 +963,10 @@ static uint64_t gt64120_readl(void *opaque, =20 default: val =3D s->regs[saddr]; - DPRINTF ("Bad register offset 0x%x\n", (int)addr); + qemu_log_mask(LOG_GUEST_ERROR, + "gt64120: Illegal register read " + "reg:0x03%x size:%u value:0x%0*x\n", + saddr << 2, size, size << 1, val); break; } =20 --=20 2.19.1 From nobody Wed May 8 01:55:32 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1561416414; cv=none; d=zoho.com; s=zohoarc; b=lHeXL7uAv5YTiJwtIsO5ytboIF+9+mZF/ssOlpJP0xLE3s8Zbp7n0EKx12OIXRbhxvVyq7PUEO5chLOJP8G9x2037DGJbdd574ANl3lfgyI4q+oEJ/uJfOxKdRjelY80ikCL9JFa6GcJoV1+nzHnRO29wpCE8guQ4Y0/lrs4+jE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1561416414; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=XPVQ0Q7g0XVbgaspN3zKRxgg/gjh0Nu7ZJZjIIHtzpA=; b=Jw800iy0/LEyqXa6Q8pcLz5goXaaqRX1JHJU30o+qElhrf0BPaPa766lXSS/nQCMqweKTF++fyJTCSysH/kGbp9gl9YDs8zBCkwkDevj3CCN2eS/6PjSAETDpC5OzJ2MYwrra+Cwkeml21eybMX7yEwSRQsWp2OaaM4tHH8aSew= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (209.51.188.17 [209.51.188.17]) by mx.zohomail.com with SMTPS id 1561416414525898.3892333959675; Mon, 24 Jun 2019 15:46:54 -0700 (PDT) Received: from localhost ([::1]:55186 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXjZ-0001rV-Bk for importer@patchew.org; Mon, 24 Jun 2019 18:46:45 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34166) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXSP-0004Aw-9L for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:29:02 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hfXSN-0005OD-Te for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:29:01 -0400 Received: from mail-wm1-x343.google.com ([2a00:1450:4864:20::343]:55970) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hfXSL-0005Ke-MV for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:28:57 -0400 Received: by mail-wm1-x343.google.com with SMTP id a15so820436wmj.5 for ; Mon, 24 Jun 2019 15:28:55 -0700 (PDT) Received: from x1.local (183.red-88-21-202.staticip.rima-tde.net. [88.21.202.183]) by smtp.gmail.com with ESMTPSA id l1sm646781wmg.13.2019.06.24.15.28.53 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Mon, 24 Jun 2019 15:28:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=XPVQ0Q7g0XVbgaspN3zKRxgg/gjh0Nu7ZJZjIIHtzpA=; b=MGuAyROEiihriTMfcWbLTvFHkTjaNVDMc20j78Y0Z7fN5y6m7a+yT+lajIX89VzuBL wQImMxi9bh0cGyV4PmYNxainGfi7hc8kTZCo4YHn+PtvWJOSQXz2i4oVduTo9kJUsjyH FicrZ1WmatowRuK2UVexMc5qUxktigwvSQ8ZzxoxxHgFNFMCbg+AakE1FuksvXK8ujT0 jd8u8uZH/Wq/kstoQFRSA2+SmWGcUnRZvMIhzl2L9H8r++c6BbfaM8Szy+ivrNPz/GX7 p9NpcrucAyXIAB2D4tD8TVZmpk89n+gLxhg/ZVhgWpTwCPnGFykZFtEVp7D6LvoHxQ/X FPTw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=XPVQ0Q7g0XVbgaspN3zKRxgg/gjh0Nu7ZJZjIIHtzpA=; b=BDzq8/HPfEc6vaXDNlbxgNT1n0fQ1Mady3SRJ2jx2JC4ivcguZjiyPsX9dkpKO0+MO Tk1yKIg41KnVpXs3IqmRce95MsYyYtt2MfSShrmo8wxBTp7vpYuOXdf14DEzitmNoB+L cpTnZIv483fZvRcC2iVFl6nOYYAvwalb8PAbQjpVWS8cPiPQfJUHtOSZglQd8h0VTAmx CJA4Z60/63MVbFTojNwK6BThxyj1OpJI4tvCGzlzr2ezJOYkFtndCE4aIIpnFYmgTQEA nxcZ/2ZmI4/0RkYcYdz0bN19TE0vACwktH1TptpeTPWoVcE8RnUrGz1XfCPxXbiLyRZt Nqzw== X-Gm-Message-State: APjAAAWLEb0DF4h/vYlpJR8lVyg4X+PdY/TPRk/U2tQ1lhP+jZTXKYoT uXBYWpLXjg+O3keeM+e3YtAB7RCI X-Google-Smtp-Source: APXvYqxivGlhMAVo+PqGcY4XCw/vTqmKsyeryQuLNjwq5rdTl/mEYKIU6NvnOtbPxd7PDhWEUcbewg== X-Received: by 2002:a7b:c051:: with SMTP id u17mr16886669wmc.25.1561415334291; Mon, 24 Jun 2019 15:28:54 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Date: Tue, 25 Jun 2019 00:28:40 +0200 Message-Id: <20190624222844.26584-7-f4bug@amsat.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190624222844.26584-1-f4bug@amsat.org> References: <20190624222844.26584-1-f4bug@amsat.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::343 Subject: [Qemu-devel] [PATCH 06/10] hw/mips/gt64xxx_pci: Convert debug printf()s to trace events X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Peter Maydell , Thomas Huth , Aleksandar Rikalo , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , =?UTF-8?q?Herv=C3=A9=20Poussineau?= , Artyom Tarasenko , Aleksandar Markovic , Paolo Bonzini , Aurelien Jarno Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Aleksandar Markovic --- Makefile.objs | 1 + hw/mips/gt64xxx_pci.c | 29 ++++++++++------------------- hw/mips/trace-events | 4 ++++ 3 files changed, 15 insertions(+), 19 deletions(-) create mode 100644 hw/mips/trace-events diff --git a/Makefile.objs b/Makefile.objs index 658cfc9d9f..3b83621f32 100644 --- a/Makefile.objs +++ b/Makefile.objs @@ -163,6 +163,7 @@ trace-events-subdirs +=3D hw/input trace-events-subdirs +=3D hw/intc trace-events-subdirs +=3D hw/isa trace-events-subdirs +=3D hw/mem +trace-events-subdirs +=3D hw/mips trace-events-subdirs +=3D hw/misc trace-events-subdirs +=3D hw/misc/macio trace-events-subdirs +=3D hw/net diff --git a/hw/mips/gt64xxx_pci.c b/hw/mips/gt64xxx_pci.c index f44326f14f..815ef0711d 100644 --- a/hw/mips/gt64xxx_pci.c +++ b/hw/mips/gt64xxx_pci.c @@ -30,14 +30,7 @@ #include "hw/pci/pci_host.h" #include "hw/i386/pc.h" #include "exec/address-spaces.h" - -//#define DEBUG - -#ifdef DEBUG -#define DPRINTF(fmt, ...) fprintf(stderr, "%s: " fmt, __func__, ##__VA_ARG= S__) -#else -#define DPRINTF(fmt, ...) -#endif +#include "trace.h" =20 #define GT_REGS (0x1000 >> 2) =20 @@ -294,9 +287,7 @@ static void gt64120_isd_mapping(GT64120State *s) check_reserved_space(&start, &length); length =3D 0x1000; /* Map new address */ - DPRINTF("ISD: "TARGET_FMT_plx"@"TARGET_FMT_plx - " -> "TARGET_FMT_plx"@"TARGET_FMT_plx"\n", - s->ISD_length, s->ISD_start, length, start); + trace_gt64120_isd_remap(s->ISD_length, s->ISD_start, length, start); s->ISD_start =3D start; s->ISD_length =3D length; memory_region_add_subregion(get_system_memory(), s->ISD_start, &s->ISD= _mem); @@ -648,19 +639,19 @@ static void gt64120_writel(void *opaque, hwaddr addr, /* not really implemented */ s->regs[saddr] =3D ~(~(s->regs[saddr]) | ~(val & 0xfffffffe)); s->regs[saddr] |=3D !!(s->regs[saddr] & 0xfffffffe); - DPRINTF("INTRCAUSE %" PRIx64 "\n", val); + trace_gt64120_write("INTRCAUSE", size << 1, val); break; case GT_INTRMASK: s->regs[saddr] =3D val & 0x3c3ffffe; - DPRINTF("INTRMASK %" PRIx64 "\n", val); + trace_gt64120_write("INTRMASK", size << 1, val); break; case GT_PCI0_ICMASK: s->regs[saddr] =3D val & 0x03fffffe; - DPRINTF("ICMASK %" PRIx64 "\n", val); + trace_gt64120_write("ICMASK", size << 1, val); break; case GT_PCI0_SERR0MASK: s->regs[saddr] =3D val & 0x0000003f; - DPRINTF("SERR0MASK %" PRIx64 "\n", val); + trace_gt64120_write("SERR0MASK", size << 1, val); break; =20 /* Reserved when only PCI_0 is configured. */ @@ -936,19 +927,19 @@ static uint64_t gt64120_readl(void *opaque, /* Interrupts */ case GT_INTRCAUSE: val =3D s->regs[saddr]; - DPRINTF("INTRCAUSE %x\n", val); + trace_gt64120_read("INTRCAUSE", size << 1, val); break; case GT_INTRMASK: val =3D s->regs[saddr]; - DPRINTF("INTRMASK %x\n", val); + trace_gt64120_read("INTRMASK", size << 1, val); break; case GT_PCI0_ICMASK: val =3D s->regs[saddr]; - DPRINTF("ICMASK %x\n", val); + trace_gt64120_read("ICMASK", size << 1, val); break; case GT_PCI0_SERR0MASK: val =3D s->regs[saddr]; - DPRINTF("SERR0MASK %x\n", val); + trace_gt64120_read("SERR0MASK", size << 1, val); break; =20 /* Reserved when only PCI_0 is configured. */ diff --git a/hw/mips/trace-events b/hw/mips/trace-events new file mode 100644 index 0000000000..75d4c73f2e --- /dev/null +++ b/hw/mips/trace-events @@ -0,0 +1,4 @@ +# gt64xxx.c +gt64120_read(const char *regname, int width, uint64_t value) "gt64120 read= %s value:0x%0*" PRIx64 +gt64120_write(const char *regname, int width, uint64_t value) "gt64120 wri= te %s value:0x%0*" PRIx64 +gt64120_isd_remap(uint64_t from_length, uint64_t from_addr, uint64_t to_le= ngth, uint64_t to_addr) "ISD: 0x%08" PRIx64 "@0x%08" PRIx64 " -> 0x%08" PRI= x64 "@0x%08" PRIx64 --=20 2.19.1 From nobody Wed May 8 01:55:32 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1561416334; cv=none; d=zoho.com; s=zohoarc; b=MYHztJHtMfAz7UhkIzMM7AMPmnCkxDo+HaqRRbzwBXOVIkD4q6ZaoRHKZVc5JevD+PFq5C7rXRQHMEcIn7QDJY06t7x4fkMpQ2S6f7t6oh3AA3PpglKsr4Mj8TrhlIASoYfoHgqH67QJYACyGsnsaO1jjQdXwEJxnTWdYVf3rL0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1561416334; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=KYk64fDgJf3EGuB/Zdsti2GInZLj+JR40MhwE281SdQ=; b=kjUyKD7pXRme1box3Pj+oNXea99/7Y9+s1tuR7DW3qC/QjcmYdmmEU3shG5BPNI5cz1AC2wJcFx3FJhKg2ggjLiOOt2K6pGFCSUM+2gMk1XtJXCN3yPPeZZdh0hbgiFLOPoR9nGPab9GFbc3VaeVtcguohrBPd/C6i4qljjNPSE= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1561416334462324.5445720492436; Mon, 24 Jun 2019 15:45:34 -0700 (PDT) Received: from localhost ([::1]:55174 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXiN-0000hQ-Fp for importer@patchew.org; Mon, 24 Jun 2019 18:45:31 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34155) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXSP-0004AU-11 for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:29:02 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hfXSN-0005O7-T3 for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:29:00 -0400 Received: from mail-wm1-x343.google.com ([2a00:1450:4864:20::343]:37682) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hfXSL-0005LC-NQ for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:28:57 -0400 Received: by mail-wm1-x343.google.com with SMTP id f17so878904wme.2 for ; Mon, 24 Jun 2019 15:28:56 -0700 (PDT) Received: from x1.local (183.red-88-21-202.staticip.rima-tde.net. [88.21.202.183]) by smtp.gmail.com with ESMTPSA id l1sm646781wmg.13.2019.06.24.15.28.54 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Mon, 24 Jun 2019 15:28:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=KYk64fDgJf3EGuB/Zdsti2GInZLj+JR40MhwE281SdQ=; b=HfdHXcnIXZGy2hmeWotpRxxZ7Fz+go3S7kfxiAZtNIqP6E/Vymn3+i1ONBXxhzpIVj GP1a8lkosg17Z21KeDZ76Z1p7JGdn3Nf+oU5hYCs5gGvaAbrEXflDX/xzxXXmTTVUi35 xYdgkRpuJzJcOqoM1M8P0aAUt3xTwZY3F0kq7rDS3pOZ6NBZvDFuqKM2LkJfmfTs5TwC 5HJZiY6aN4bntWP2ZqPvh6XPY16gd2aIJx0Sv/xi4jvCMsvoTsoSyt1PyTJ9ANH0i7wG Xq7rtsWJjuhMRDDER+UqrT9cVWcy1P9izpgGlMCsQARbS0aMuQfZD084wgKKiPJbxlw4 mNlA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=KYk64fDgJf3EGuB/Zdsti2GInZLj+JR40MhwE281SdQ=; b=iDcbabbG6J264ZSmgrb9kS26H8HyPXFYfN3etXEK32nxDur1lhBiI1/0uNtg5981Ad igN+8oeCXCk3LBm81xSug0Qq/wXD1mLhXHTJnFGc2lYncXS8jXCLgoeyM1V6HmNmkF9w t5j9ZVRRXoEmAHvUrfItQdkmOTMgkejwfrxM7lvYPZXkEqFX74Z7DDXS8hBpPs+bZcTX UVjCEXtCI2AeBUa+9hGphB7EaAAGYxwxgll578jv8x/L2ZW/CKmgt6GPyabilOu4QuJl 9GBYgb2q8oeQgPhtrVqz+9aMvUjgY73IDeevgblQ+rO42I/WBz4NYsZacQx6Sn2Hm7y7 vjtw== X-Gm-Message-State: APjAAAXAT3EfejVcnHfdWDZdGLawrv1I/1H6IcyMVpJ/PveFACU6nNzX +CVQnasD1UjtGv0k8W2waG0Evynd X-Google-Smtp-Source: APXvYqwPXDmdFgHp1zgf5gBDChS07DejhIJ1U65DogBa+A3MxZFlbcAVRZhhs0OU2ug8RM5SgX5UoQ== X-Received: by 2002:a05:600c:2549:: with SMTP id e9mr17711615wma.46.1561415335517; Mon, 24 Jun 2019 15:28:55 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Date: Tue, 25 Jun 2019 00:28:41 +0200 Message-Id: <20190624222844.26584-8-f4bug@amsat.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190624222844.26584-1-f4bug@amsat.org> References: <20190624222844.26584-1-f4bug@amsat.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::343 Subject: [Qemu-devel] [PATCH 07/10] hw/mips/gt64xxx_pci: Align the pci0-mem size X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Peter Maydell , Thomas Huth , Aleksandar Rikalo , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , =?UTF-8?q?Herv=C3=A9=20Poussineau?= , Artyom Tarasenko , Aleksandar Markovic , Paolo Bonzini , Aurelien Jarno Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) One byte is missing, use an aligned size. (qemu) info mtree memory-region: pci0-mem 0000000000000000-00000000fffffffe (prio 0, i/o): pci0-mem ^ Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Aleksandar Markovic --- hw/mips/gt64xxx_pci.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/mips/gt64xxx_pci.c b/hw/mips/gt64xxx_pci.c index 815ef0711d..2fa313f498 100644 --- a/hw/mips/gt64xxx_pci.c +++ b/hw/mips/gt64xxx_pci.c @@ -23,6 +23,7 @@ */ =20 #include "qemu/osdep.h" +#include "qemu/units.h" #include "qemu/log.h" #include "hw/hw.h" #include "hw/mips/mips.h" @@ -1201,7 +1202,7 @@ PCIBus *gt64120_register(qemu_irq *pic) dev =3D qdev_create(NULL, TYPE_GT64120_PCI_HOST_BRIDGE); d =3D GT64120_PCI_HOST_BRIDGE(dev); phb =3D PCI_HOST_BRIDGE(dev); - memory_region_init(&d->pci0_mem, OBJECT(dev), "pci0-mem", UINT32_MAX); + memory_region_init(&d->pci0_mem, OBJECT(dev), "pci0-mem", 4 * GiB); address_space_init(&d->pci0_mem_as, &d->pci0_mem, "pci0-mem"); phb->bus =3D pci_register_root_bus(dev, "pci", gt64120_pci_set_irq, gt64120_pci_map_= irq, --=20 2.19.1 From nobody Wed May 8 01:55:32 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1561415726; cv=none; d=zoho.com; s=zohoarc; b=ES0GiR+IhEuCHWSdr00XRUwfVCHKEhWxuDTwTtRnfLfb9NXjs7JQOILYDDLz7p03r35R5IiVEbv9jC8daNg0uwV/y0Shg7SZWNlgdWFbweD7eqT2OUU4s9fr/T6SQkXWXQKqfDPAsrLeNbiDmIJ6uIAss3p6516QLsa3WfBqdow= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1561415726; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=rT3WvtpigTN3xO4aUvjlhGu30zqDl1BA3eirdCSenGY=; b=mw0fpFz5sYybRpG0CSGhhiinNR/a+T+KWxUXS5Kr52VF1DqT3NfO9FAjlGXuXCDvCv1tHtfdEJEcSlX6u3LtGR2EsG4iesqWBXZO54CTKALDI28TAw9Y7pVBhOpFV9Y6mXTEQdNE6NQRxakJxA0zJUYhFNgTxXA9dfeWncP67Hc= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1561415726635693.7678491653961; Mon, 24 Jun 2019 15:35:26 -0700 (PDT) Received: from localhost ([::1]:55106 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXYZ-0000ge-Jj for importer@patchew.org; Mon, 24 Jun 2019 18:35:23 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34179) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXSP-0004C3-O9 for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:29:03 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hfXSO-0005P2-6g for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:29:01 -0400 Received: from mail-wm1-x344.google.com ([2a00:1450:4864:20::344]:35469) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hfXSN-0005Le-Tj for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:29:00 -0400 Received: by mail-wm1-x344.google.com with SMTP id c6so891944wml.0 for ; Mon, 24 Jun 2019 15:28:57 -0700 (PDT) Received: from x1.local (183.red-88-21-202.staticip.rima-tde.net. [88.21.202.183]) by smtp.gmail.com with ESMTPSA id l1sm646781wmg.13.2019.06.24.15.28.55 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Mon, 24 Jun 2019 15:28:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=rT3WvtpigTN3xO4aUvjlhGu30zqDl1BA3eirdCSenGY=; b=CO6zLsdQmYkw/tpmJ7ZdO1Nni8NIkxXbjZGZYfilr2ULrHk8LveGwlyYo2qx+pz7lq KLPbpO0UudAjz8NuiD+ZKllK0LCHioqqopIavypky0k7UB+tyAwITlhdn+WZjW/r7Jn3 Es7N9S7p+ATy2bR/cbhfREGgai03TY8XkSVEixkAd/4+pJlK78TQCiMeyTJug5BmOkY/ 0duahjtOA/dNOphAyZIra7O9aBPmLwLxuN/j716KzUVIuUGUsE13fmKFyuM+ODvZIdeZ wxGzVokWYHbeRcSvWoGq+7CxW2YVI7+GagjaWsGeKnKo5/8r6PPEkPJue/UDr/WPcH1G mIWw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=rT3WvtpigTN3xO4aUvjlhGu30zqDl1BA3eirdCSenGY=; b=Y6b4eFtgT5Ibi7JlfvroARR/eYqKKnU/G+EeBAZkJK7rCGlrlRHbcZ1wUn3kP3wiLu XVb+FGjuLT5BS2pJOVZSy6Ii+baJP5YEgKE9Z2gXCmiriToY/2MI5LKpccICIq1UQy37 Ddmaq2+143xn4Z3ShmA5GjMn1KbbWugatdUZ/toRiJjShOqahrqBZuSSNFO9dn+oI6Yd 4Ubb1AE2ca0/L6bao5rLgJG8Fjr6IRtLJDaIeV79ksR0OAgZqEf6v1l+PPdeDMxDM5qq i2a+/83fs8GKn2+C8RsSpakcuJFFbvNSM6aU6hlWP+7NJM3jZ/p8tURxqoV51TQVvcL7 SPHg== X-Gm-Message-State: APjAAAWblHizphsRcbh9NxhT4YvvNkfbNTzla/Kx6jWvPRvBoPVxK0cC WhxbkLrsFcVj1RbNB1sHbQY0OT1G X-Google-Smtp-Source: APXvYqw3EwM8fMiInZQV7ll8rHWM61Hjlqs3BlBBIZ/7Lmsk4FpnR4dMsgb0K46PIERkNBUHv/HX/g== X-Received: by 2002:a1c:c2d5:: with SMTP id s204mr17776629wmf.174.1561415336828; Mon, 24 Jun 2019 15:28:56 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Date: Tue, 25 Jun 2019 00:28:42 +0200 Message-Id: <20190624222844.26584-9-f4bug@amsat.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190624222844.26584-1-f4bug@amsat.org> References: <20190624222844.26584-1-f4bug@amsat.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::344 Subject: [Qemu-devel] [PATCH 08/10] hw/mips/gt64xxx_pci: Add a 'cpu_big_endian' qdev property X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Peter Maydell , Thomas Huth , Aleksandar Rikalo , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , =?UTF-8?q?Herv=C3=A9=20Poussineau?= , Artyom Tarasenko , Aleksandar Markovic , Paolo Bonzini , Aurelien Jarno Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) This device does not have to be TARGET-dependent. Add a 'cpu_big_endian' property which sets the byte-swapping options if required. Signed-off-by: Philippe Mathieu-Daud=C3=A9 --- I might change my mind and name it 'little_endian' to be closer to the datasheet. --- include/hw/mips/mips.h | 2 +- hw/mips/gt64xxx_pci.c | 29 +++++++++++++---------------- hw/mips/mips_malta.c | 2 +- 3 files changed, 15 insertions(+), 18 deletions(-) diff --git a/include/hw/mips/mips.h b/include/hw/mips/mips.h index 2f6774d540..6ec41d33f1 100644 --- a/include/hw/mips/mips.h +++ b/include/hw/mips/mips.h @@ -9,7 +9,7 @@ #include "hw/irq.h" =20 /* gt64xxx.c */ -PCIBus *gt64120_register(qemu_irq *pic); +PCIBus *gt64120_create(qemu_irq *pic, bool target_is_bigendian); =20 /* bonito.c */ PCIBus *bonito_init(qemu_irq *pic); diff --git a/hw/mips/gt64xxx_pci.c b/hw/mips/gt64xxx_pci.c index 2fa313f498..5209038ee5 100644 --- a/hw/mips/gt64xxx_pci.c +++ b/hw/mips/gt64xxx_pci.c @@ -240,6 +240,7 @@ typedef struct GT64120State { PCI_MAPPING_ENTRY(ISD); MemoryRegion pci0_mem; AddressSpace pci0_mem_as; + bool cpu_big_endian; } GT64120State; =20 /* Adjust range to avoid touching space which isn't mappable via PCI */ @@ -1028,15 +1029,12 @@ static void gt64120_pci_set_irq(void *opaque, int i= rq_num, int level) static void gt64120_reset(DeviceState *dev) { GT64120State *s =3D GT64120_PCI_HOST_BRIDGE(dev); + const uint32_t pci_cmd =3D s->cpu_big_endian ? 0x00000000 : 0x00010001; =20 /* FIXME: Malta specific hw assumptions ahead */ =20 /* CPU Configuration */ -#ifdef TARGET_WORDS_BIGENDIAN - s->regs[GT_CPU] =3D 0x00000000; -#else - s->regs[GT_CPU] =3D 0x00001000; -#endif + s->regs[GT_CPU] =3D !s->cpu_big_endian << 12; s->regs[GT_MULTI] =3D 0x00000003; =20 /* CPU Address decode */ @@ -1143,11 +1141,7 @@ static void gt64120_reset(DeviceState *dev) s->regs[GT_TC_CONTROL] =3D 0x00000000; =20 /* PCI Internal */ -#ifdef TARGET_WORDS_BIGENDIAN - s->regs[GT_PCI0_CMD] =3D 0x00000000; -#else - s->regs[GT_PCI0_CMD] =3D 0x00010001; -#endif + s->regs[GT_PCI0_CMD] =3D pci_cmd; s->regs[GT_PCI0_TOR] =3D 0x0000070f; s->regs[GT_PCI0_BS_SCS10] =3D 0x00fff000; s->regs[GT_PCI0_BS_SCS32] =3D 0x00fff000; @@ -1164,11 +1158,7 @@ static void gt64120_reset(DeviceState *dev) s->regs[GT_PCI0_SSCS10_BAR] =3D 0x00000000; s->regs[GT_PCI0_SSCS32_BAR] =3D 0x01000000; s->regs[GT_PCI0_SCS3BT_BAR] =3D 0x1f000000; -#ifdef TARGET_WORDS_BIGENDIAN - s->regs[GT_PCI1_CMD] =3D 0x00000000; -#else - s->regs[GT_PCI1_CMD] =3D 0x00010001; -#endif + s->regs[GT_PCI1_CMD] =3D pci_cmd; s->regs[GT_PCI1_TOR] =3D 0x0000070f; s->regs[GT_PCI1_BS_SCS10] =3D 0x00fff000; s->regs[GT_PCI1_BS_SCS32] =3D 0x00fff000; @@ -1193,13 +1183,14 @@ static void gt64120_reset(DeviceState *dev) gt64120_pci_mapping(s); } =20 -PCIBus *gt64120_register(qemu_irq *pic) +PCIBus *gt64120_create(qemu_irq *pic, bool target_is_bigendian) { GT64120State *d; PCIHostState *phb; DeviceState *dev; =20 dev =3D qdev_create(NULL, TYPE_GT64120_PCI_HOST_BRIDGE); + qdev_prop_set_bit(dev, "cpu_big_endian", target_is_bigendian); d =3D GT64120_PCI_HOST_BRIDGE(dev); phb =3D PCI_HOST_BRIDGE(dev); memory_region_init(&d->pci0_mem, OBJECT(dev), "pci0-mem", 4 * GiB); @@ -1262,6 +1253,11 @@ static const TypeInfo gt64120_pci_info =3D { }, }; =20 +static Property gt64120_properties[] =3D { + DEFINE_PROP_BOOL("cpu_big_endian", GT64120State, cpu_big_endian, true), + DEFINE_PROP_END_OF_LIST(), +}; + static void gt64120_class_init(ObjectClass *klass, void *data) { DeviceClass *dc =3D DEVICE_CLASS(klass); @@ -1269,6 +1265,7 @@ static void gt64120_class_init(ObjectClass *klass, vo= id *data) set_bit(DEVICE_CATEGORY_BRIDGE, dc->categories); dc->reset =3D gt64120_reset; dc->vmsd =3D &vmstate_gt64120; + dc->props =3D gt64120_properties; } =20 static const TypeInfo gt64120_info =3D { diff --git a/hw/mips/mips_malta.c b/hw/mips/mips_malta.c index 51db5212be..97f8ffbf1b 100644 --- a/hw/mips/mips_malta.c +++ b/hw/mips/mips_malta.c @@ -1375,7 +1375,7 @@ void mips_malta_init(MachineState *machine) isa_irq =3D qemu_irq_proxy(&s->i8259, 16); =20 /* Northbridge */ - pci_bus =3D gt64120_register(isa_irq); + pci_bus =3D gt64120_create(isa_irq, be); =20 /* Southbridge */ ide_drive_get(hd, ARRAY_SIZE(hd)); --=20 2.19.1 From nobody Wed May 8 01:55:32 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1561415808; cv=none; d=zoho.com; s=zohoarc; b=EZ3Ft1iImapABRh759YQ6ArZ/yj0OQH/a1EEofpu0tu8vwpD9Wj6OMVaGTNRDaupwMTv4Y0DQx6j4sW+1DyAq93tOqFYm3sZjLpnhKK4yHzsfMK1kJ9Qnc/52hFfdS7Lw6qDhibFzqUPPg+/arPyeC7WCJys4WQLZ4In/2YdKzg= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1561415808; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=dutpFDVMpS+BeonIxVWBTDXWqsqJ8Tyi/t5MVWPpXKY=; b=EiVJyA53ulhT65oi52V8LqWESv4K8IPA2NZw4jY5SuOMFaGe/nhWnx/TQLenPa9B0215wrKGCdkpnWQ9CZkNfVbJRbHJwlfW+zf8khANe254wAZyhDJ10TOVCe0JlpAHtGfd6f3wCE0PguDRGukKUuoDyP9J7Pse9PPq0lv7qy4= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1561415808747244.32454764840998; Mon, 24 Jun 2019 15:36:48 -0700 (PDT) Received: from localhost ([::1]:55121 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXZs-0002L2-LC for importer@patchew.org; Mon, 24 Jun 2019 18:36:47 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34176) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXSP-0004Bx-MN for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:29:03 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hfXSO-0005Ow-5b for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:29:01 -0400 Received: from mail-wm1-x341.google.com ([2a00:1450:4864:20::341]:53314) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hfXSN-0005NI-SP for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:29:00 -0400 Received: by mail-wm1-x341.google.com with SMTP id x15so829669wmj.3 for ; Mon, 24 Jun 2019 15:28:59 -0700 (PDT) Received: from x1.local (183.red-88-21-202.staticip.rima-tde.net. [88.21.202.183]) by smtp.gmail.com with ESMTPSA id l1sm646781wmg.13.2019.06.24.15.28.56 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Mon, 24 Jun 2019 15:28:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=dutpFDVMpS+BeonIxVWBTDXWqsqJ8Tyi/t5MVWPpXKY=; b=QKEi8l4kIr2ObtABOD1ZIE74YpSdn0pJPP/tE0BO3FcytFamUo8VjIG/gMWCaMlV+L voaaPNLOqbbXpotXfi1GKP9rABAT0HDCzDYwIAMgT8cKc660BSKYXrBFGQNSYajC/15U cGRcs76J+2WxYj7PkvociNDTmOoZqPSZ46uNaMtZUHJK+5R4Vvr38YTEvN9oGk0Cn4VM OSrxIRvUEOzYGKVDRf6lACogJbPMiIfnhvh18awQbQagfwpSKYApU4ufmln9l5Q6lUTR v+Oh+Ety7ZE/vtur1ZeMCH/45t9As9NTQDYnS7vivklb1NiRzqufa7d/xBxgsE9Ek/7F 90xg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=dutpFDVMpS+BeonIxVWBTDXWqsqJ8Tyi/t5MVWPpXKY=; b=s8BtDhG2TL9+w0B5HnW5F7PgrgaRyMpsG91uSqftubqOCfhDfbQCqqhUPMV+9y4iGv hmU0rPtsdMkcWVV2t9C1kdCZFETGVjrxDvXnQiV2N7Wk01KOZ6dPpIonFc5wOO0Ri8hL 5sLyLieSmicKwot8lkflMXBgafvkPYtd4G0RAOpivAtgmiYt+Nucu6webnAPOh4pKDCY wBbsRdHSQN/WpTJdihpSAxAmCGKutZjl18uMaPHtjuSCto76gL8BDIiM4Z/uwZulNG4r 42qr50DrgB/OBeK9dF114YmOfxGPRsjGYpflLxjuudsUyHweo7nnix7RS08eK2ZNZy5Y 9CtQ== X-Gm-Message-State: APjAAAUHIeZ4QBibm8e77cqqqLzu9hgiWyAavnXUz6VNK8EVvHCmr1F6 UYZR4j23I9DmzF2UvFbPDNw17a9A X-Google-Smtp-Source: APXvYqxAJ3wff9BPORMRJIt1T391LX8v/bFTHEbTk4+7Leeg4gvaJzB2CaKYOsnSnmf0hRPaANSIGg== X-Received: by 2002:a7b:c301:: with SMTP id k1mr16826731wmj.43.1561415338112; Mon, 24 Jun 2019 15:28:58 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Date: Tue, 25 Jun 2019 00:28:43 +0200 Message-Id: <20190624222844.26584-10-f4bug@amsat.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190624222844.26584-1-f4bug@amsat.org> References: <20190624222844.26584-1-f4bug@amsat.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::341 Subject: [Qemu-devel] [PATCH 09/10] hw/mips/gt64xxx_pci: Move it to hw/pci-host/ X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Peter Maydell , Thomas Huth , Aleksandar Rikalo , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , =?UTF-8?q?Herv=C3=A9=20Poussineau?= , Artyom Tarasenko , Aleksandar Markovic , Paolo Bonzini , Aurelien Jarno Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) The GT-64120 is a north-bridge, and it is not MIPS specific. Move it with the other north-bridge devices. We move this device in the common-obj, and compile it once for the 4 different MIPS targets. Signed-off-by: Philippe Mathieu-Daud=C3=A9 --- hw/{mips/gt64xxx_pci.c =3D> pci-host/gt64120.c} | 0 MAINTAINERS | 2 +- hw/mips/Makefile.objs | 2 +- hw/mips/trace-events | 4 ---- hw/pci-host/Makefile.objs | 2 +- hw/pci-host/trace-events | 5 +++++ 6 files changed, 8 insertions(+), 7 deletions(-) rename hw/{mips/gt64xxx_pci.c =3D> pci-host/gt64120.c} (100%) diff --git a/hw/mips/gt64xxx_pci.c b/hw/pci-host/gt64120.c similarity index 100% rename from hw/mips/gt64xxx_pci.c rename to hw/pci-host/gt64120.c diff --git a/MAINTAINERS b/MAINTAINERS index abef4a1cfc..da348e1af1 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -928,7 +928,7 @@ M: Aurelien Jarno R: Aleksandar Rikalo S: Maintained F: hw/mips/mips_malta.c -F: hw/mips/gt64xxx_pci.c +F: hw/pci-host/gt64120.c F: tests/acceptance/linux_ssh_mips_malta.py =20 Mipssim diff --git a/hw/mips/Makefile.objs b/hw/mips/Makefile.objs index 525809af07..da65e19c20 100644 --- a/hw/mips/Makefile.objs +++ b/hw/mips/Makefile.objs @@ -1,6 +1,6 @@ obj-y +=3D addr.o mips_int.o obj-$(CONFIG_R4K) +=3D mips_r4k.o -obj-$(CONFIG_MALTA) +=3D gt64xxx_pci.o mips_malta.o +obj-$(CONFIG_MALTA) +=3D mips_malta.o obj-$(CONFIG_MIPSSIM) +=3D mips_mipssim.o obj-$(CONFIG_JAZZ) +=3D mips_jazz.o obj-$(CONFIG_FULONG) +=3D mips_fulong2e.o diff --git a/hw/mips/trace-events b/hw/mips/trace-events index 75d4c73f2e..e69de29bb2 100644 --- a/hw/mips/trace-events +++ b/hw/mips/trace-events @@ -1,4 +0,0 @@ -# gt64xxx.c -gt64120_read(const char *regname, int width, uint64_t value) "gt64120 read= %s value:0x%0*" PRIx64 -gt64120_write(const char *regname, int width, uint64_t value) "gt64120 wri= te %s value:0x%0*" PRIx64 -gt64120_isd_remap(uint64_t from_length, uint64_t from_addr, uint64_t to_le= ngth, uint64_t to_addr) "ISD: 0x%08" PRIx64 "@0x%08" PRIx64 " -> 0x%08" PRI= x64 "@0x%08" PRIx64 diff --git a/hw/pci-host/Makefile.objs b/hw/pci-host/Makefile.objs index a9cd3e022d..3e1657774d 100644 --- a/hw/pci-host/Makefile.objs +++ b/hw/pci-host/Makefile.objs @@ -17,5 +17,5 @@ common-obj-$(CONFIG_PCI_PIIX) +=3D piix.o common-obj-$(CONFIG_PCI_EXPRESS_Q35) +=3D q35.o common-obj-$(CONFIG_PCI_EXPRESS_GENERIC_BRIDGE) +=3D gpex.o common-obj-$(CONFIG_PCI_EXPRESS_XILINX) +=3D xilinx-pcie.o - +common-obj-$(CONFIG_MALTA) +=3D gt64120.o common-obj-$(CONFIG_PCI_EXPRESS_DESIGNWARE) +=3D designware.o diff --git a/hw/pci-host/trace-events b/hw/pci-host/trace-events index d19ca9aef6..eecc233670 100644 --- a/hw/pci-host/trace-events +++ b/hw/pci-host/trace-events @@ -20,3 +20,8 @@ unin_data_write(uint64_t addr, unsigned len, uint64_t val= ) "write addr 0x%"PRIx6 unin_data_read(uint64_t addr, unsigned len, uint64_t val) "read addr 0x%"P= RIx64 " len %d val 0x%"PRIx64 unin_write(uint64_t addr, uint64_t value) "addr=3D0x%" PRIx64 " val=3D0x%"= PRIx64 unin_read(uint64_t addr, uint64_t value) "addr=3D0x%" PRIx64 " val=3D0x%"P= RIx64 + +# gt64120.c +gt64120_read(const char *regname, int width, uint64_t value) "gt64120 read= %s value:0x%0*" PRIx64 +gt64120_write(const char *regname, int width, uint64_t value) "gt64120 wri= te %s value:0x%0*" PRIx64 +gt64120_isd_remap(uint64_t from_length, uint64_t from_addr, uint64_t to_le= ngth, uint64_t to_addr) "ISD: 0x%08" PRIx64 "@0x%08" PRIx64 " -> 0x%08" PRI= x64 "@0x%08" PRIx64 --=20 2.19.1 From nobody Wed May 8 01:55:32 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1561415983; cv=none; d=zoho.com; s=zohoarc; b=RFs+KK78XHJvXgVtfStoTqw1VPrGkFfqVsPz4+nozQNqPlQ/tC94/gB1HeFy8Uyh1raKxi1lRx/KC+TBPmSiq4PrM+KvGc74glK7hNNt4nwOb/ObOvslF53Hb4cOgn+hs4ClWQgRfa48IaWdtV3xy1NsK/X6cVquf7CkwmBVIb8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1561415983; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=9SctNReWxhEE3cMWEX6p+uUNHMIHY/fb8Bqmz63WdR4=; b=AEcVKxq9u/vy5Gaq5JAl3gh0X4D8dQ0f7LMFxP40oEC3T9+mpBW/ksl1FlrWbj9SZJjbuUVrUGFsmmjoRaagjDFlmO4TzXd+d73P1Oo2Jhzg6S0InfG9iYSzSup3/fBLoCEPeDyuBsEUsrAZZyMxCwcafKTwAKKE5ysGDPs53bo= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1561415983104977.2154715281205; Mon, 24 Jun 2019 15:39:43 -0700 (PDT) Received: from localhost ([::1]:55140 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXck-0004R4-6Q for importer@patchew.org; Mon, 24 Jun 2019 18:39:42 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34184) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfXSP-0004CO-Vl for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:29:03 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hfXSO-0005Pc-Ma for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:29:01 -0400 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]:44693) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hfXSO-0005Ny-E4 for qemu-devel@nongnu.org; Mon, 24 Jun 2019 18:29:00 -0400 Received: by mail-wr1-x442.google.com with SMTP id r16so15528502wrl.11 for ; Mon, 24 Jun 2019 15:29:00 -0700 (PDT) Received: from x1.local (183.red-88-21-202.staticip.rima-tde.net. [88.21.202.183]) by smtp.gmail.com with ESMTPSA id l1sm646781wmg.13.2019.06.24.15.28.58 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Mon, 24 Jun 2019 15:28:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=9SctNReWxhEE3cMWEX6p+uUNHMIHY/fb8Bqmz63WdR4=; b=RgQukXrfhDk9U6VLTwaL94F0+GEQYpzHt9aH/mSzmEFJPF/o0QUHhM4HaJ0NkmedIB CMfKSe/9NMIfzdXJuc0C58UXQ1/tb1pWsA2Y3pPWCcQEFnMfw6qkwUU2Kq2enIetEs4M RqP6jQYjn9AaTGJPN5lg+quL6BZzS8qy2r4KasUVOpPRGQzoXtzPKHvoHgHfGcp2YImg 8/4P7/myjbG/w9TJ/uq1qwkHlRYCumjKTAeSEkFO9OHWYdHFZrCO7/xzpyurmtf7fObp ZbnkoEs6/jR+oA5XE8HsIZiBtKIUjGHM611WTqv/Syu3KCAL4TKVq5IqViL9bATttOhl jVqw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=9SctNReWxhEE3cMWEX6p+uUNHMIHY/fb8Bqmz63WdR4=; b=mie8JhfGhXgL/MIY8EEMpcPlGk8yCZX9vCnndpX789l70tZ91lUrbzG1+R7FpFYkDN Teix2GS55t8Dz6FBQ8lCCb+wWnCKkbpvyTAVAiUpf8ZLvWBWRcWpfr7+FSCn1Uz+E4CV NrI3d0g1Jt64LOvug3Fvvrb5AM6njTEwJKFfUZUqoqXnt9ipIiXB6Xx9UDE4vleKDVHl d+/P4eF84oBHQCTDlp8caprLQMvZu3JpEVybaZxlbSBh7Wv8E9yLINSiqhpvMekF5aU6 PmwUOO9aZFmlb3I2X1+4n0ssbr+f36BUeXDF3jZ79wsGxJE7KqTReGl+tc9zOSsrRQtw vpTw== X-Gm-Message-State: APjAAAU7J7racoWdtzwO2RjcF22VAkk9XnvkPLNvqekt4yPzsn2Ifw41 A5aQoLYYwJGkkltZmlUbudN8n85/ X-Google-Smtp-Source: APXvYqw/+IZ/snn4T9+g/yNeUZATXLbOk5a0vVi69maJqE87fahpMwL6MmmCau8T32QC8LBlzyU6kw== X-Received: by 2002:a5d:484e:: with SMTP id n14mr26801694wrs.348.1561415339334; Mon, 24 Jun 2019 15:28:59 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Date: Tue, 25 Jun 2019 00:28:44 +0200 Message-Id: <20190624222844.26584-11-f4bug@amsat.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190624222844.26584-1-f4bug@amsat.org> References: <20190624222844.26584-1-f4bug@amsat.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::442 Subject: [Qemu-devel] [RFC PATCH 10/10] hw/pci-host/gt64120: Clean the decoded address space X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Peter Maydell , Thomas Huth , Aleksandar Rikalo , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , =?UTF-8?q?Herv=C3=A9=20Poussineau?= , Artyom Tarasenko , Aleksandar Markovic , Paolo Bonzini , Aurelien Jarno Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) The SysAd bus is split in various address spaces. Declare the different regions separately, this helps a lot while tracing different access while debugging. We also add the PCI1 ranges. See 'GT-64120A System Controller' datasheet Rev, 1.1, "Table 15: CPU and Device Decoder Default Address Mapping" Signed-off-by: Philippe Mathieu-Daud=C3=A9 --- While this device is modelled toward the Malta board, it is generic. --- hw/mips/mips_malta.c | 6 ------ hw/pci-host/gt64120.c | 19 +++++++++++++++++++ 2 files changed, 19 insertions(+), 6 deletions(-) diff --git a/hw/mips/mips_malta.c b/hw/mips/mips_malta.c index 97f8ffbf1b..d6e4a0dad9 100644 --- a/hw/mips/mips_malta.c +++ b/hw/mips/mips_malta.c @@ -53,7 +53,6 @@ #include "sysemu/qtest.h" #include "qapi/error.h" #include "qemu/error-report.h" -#include "hw/misc/empty_slot.h" #include "sysemu/kvm.h" #include "hw/semihosting/semihost.h" #include "hw/mips/cps.h" @@ -1209,11 +1208,6 @@ void mips_malta_init(MachineState *machine) DeviceState *dev =3D qdev_create(NULL, TYPE_MIPS_MALTA); MaltaState *s =3D MIPS_MALTA(dev); =20 - /* The whole address space decoded by the GT-64120A doesn't generate - exception when accessing invalid memory. Create an empty slot to - emulate this feature. */ - empty_slot_init("gt64120-ad", 0x00000000, 0x20000000); - qdev_init_nofail(dev); =20 /* create CPU */ diff --git a/hw/pci-host/gt64120.c b/hw/pci-host/gt64120.c index 5209038ee5..6eaa571994 100644 --- a/hw/pci-host/gt64120.c +++ b/hw/pci-host/gt64120.c @@ -31,6 +31,8 @@ #include "hw/pci/pci_host.h" #include "hw/i386/pc.h" #include "exec/address-spaces.h" +#include "hw/misc/empty_slot.h" +#include "hw/misc/unimp.h" #include "trace.h" =20 #define GT_REGS (0x1000 >> 2) @@ -1206,6 +1208,23 @@ PCIBus *gt64120_create(qemu_irq *pic, bool target_is= _bigendian) "isd-mem", 0x1000); =20 pci_create_simple(phb->bus, PCI_DEVFN(0, 0), "gt64120_pci"); + + create_unimplemented_device("gt64120_i2o", 0x14000000, 256); + + empty_slot_init("SCS0", 0x00000000, 8 * MiB); + empty_slot_init("SCS1", 0x00800000, 8 * MiB); + empty_slot_init("SCS2", 0x01000000, 8 * MiB); + empty_slot_init("SCS3", 0x01800000, 8 * MiB); + empty_slot_init("CS0", 0x1c000000, 8 * MiB); + empty_slot_init("CS1", 0x1c800000, 8 * MiB); + empty_slot_init("CS2", 0x1d000000, 32 * MiB); + empty_slot_init("CS3", 0x1f000000, 12 * MiB); + empty_slot_init("BootCS", 0x1fc00000, 4 * MiB); + + create_unimplemented_device("pci1-io", 0x20000000, 32 * MiB); + empty_slot_init("pci1-mem0", 0x22000000, 32 * MiB); + empty_slot_init("pci1-mem1", 0x24000000, 32 * MiB); + return phb->bus; } =20 --=20 2.19.1