From patchwork Tue Aug 30 19:00:38 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Bernhard Beschow X-Patchwork-Id: 12959782 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id EFA52ECAAA1 for ; Tue, 30 Aug 2022 19:35:28 +0000 (UTC) Received: from localhost ([::1]:45412 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oT71D-0000p6-TS for qemu-devel@archiver.kernel.org; Tue, 30 Aug 2022 15:35:27 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:53620) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oT6U6-0002xu-HB; Tue, 30 Aug 2022 15:01:14 -0400 Received: from mail-wm1-x330.google.com ([2a00:1450:4864:20::330]:52097) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oT6U1-0008Ph-CV; Tue, 30 Aug 2022 15:01:14 -0400 Received: by mail-wm1-x330.google.com with SMTP id ay12so6246833wmb.1; Tue, 30 Aug 2022 12:01:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc; bh=7olQ9Tgb+lc961uAXORKVZMZxaKChj8B4za1nKR0prQ=; b=gY/+sI/PHqTPTae7upZoZ99VZEqFoFKEnAW/32UtpZItFc2FobJRG2pkEeTo3S3q7N 65kpnINFEMOznJ4ummXXFlzuO4FhsImHevWQPbM9ACQ0/gyRsa67sZcEXnif/RYViVqA 5lHrvtPzZIZ4+IntXHbXdz8cxaS9dwLMPXUkI6D5bW5M5I9OCL55n42JhwVjzAIxYde6 IwdK1fFNPEFlNK5IYuv5HPKB/3IUhDSYDVAenZwOChS6+3Huk+qpKHYBs0PvNeKbEczX 4xm4FQsZ2O0T1l3I8NL9RARykSMiVYUKWsq6kpU9Cw03QoyuVyoGjvwabwB86zXFA+Yh T5zA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc; bh=7olQ9Tgb+lc961uAXORKVZMZxaKChj8B4za1nKR0prQ=; b=ed59xcmfLtHUZ289cRyMMAQcCEmuuIUdglpK1lDxSerl7c4fxjcZR/odDL46s5epFX YVX+q6bCScfjcni7uQeMTw71lZddbOFoW0+TKtABlu3QZ2/jVu3OQcacZ8rVFLe31vFe BSusgffKCASotg3GSNMhxCfLDEYKzBB8x/dbnEX/wxXYXcTzyw89PjxjbynUSkwe3y77 pY+SfiIWbHaW+JhYyLqJcZWcN/owvMvwFtuoDiNicyI5l2NXvHwb79lHxjPLfOSKXaDs JEYPQ6koBNKpNGaAsvn3o84hG7XAZ1Wsb6FbFgmVSj7dAw6sgrnD+IQizYd/Yf1RF5oa 2CDg== X-Gm-Message-State: ACgBeo0nRjaLpFM6JM5LhwI1DL0x8ryEdrrQUKGXUV7/P9vmMKSIdxKo TN0D30CXYowFJyJh9gleyM4/wjznKAM= X-Google-Smtp-Source: AA6agR77sXMGkGDQjs+lChhIJ0+RUMj7VkkFJ5+7ZLjHsC4wZ/qo6+wDUcX6c9nUzsaSjspgeOmKkw== X-Received: by 2002:a05:600c:34d2:b0:3a5:afe5:3eb5 with SMTP id d18-20020a05600c34d200b003a5afe53eb5mr10645384wmq.122.1661886066904; Tue, 30 Aug 2022 12:01:06 -0700 (PDT) Received: from osoxes.fritz.box (p200300faaf0bb2009c4947838afc41b6.dip0.t-ipconnect.de. [2003:fa:af0b:b200:9c49:4783:8afc:41b6]) by smtp.gmail.com with ESMTPSA id j18-20020adfea52000000b002206203ed3dsm9821285wrn.29.2022.08.30.12.01.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 30 Aug 2022 12:01:06 -0700 (PDT) From: Bernhard Beschow To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, Huacai Chen , BALATON Zoltan , Jiaxun Yang , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Bernhard Beschow Subject: [PATCH v2 00/10] Instantiate VT82xx functions in host device Date: Tue, 30 Aug 2022 21:00:38 +0200 Message-Id: <20220830190048.67448-1-shentey@gmail.com> X-Mailer: git-send-email 2.37.2 MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::330; envelope-from=shentey@gmail.com; helo=mail-wm1-x330.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" v2: * Keep the call to pci_ide_create_devs() in board code for consistency (Zoltan) * Create rtc-time alias in board rather than in south bridge code * Remove stale comments about PCI functions v1: This series instantiates all PCI functions of the VT82xx south bridges in the south bridges themselves. For the IDE function this is especially important since its interrupt routing is configured in the ISA function, hence doesn't make sense to instantiate it as a "Frankenstein" device. The interrupt routing is currently hardcoded and changing that is currently not in the scope of this series. Testing done: * `qemu-system-ppc -machine pegasos2 -rtc base=localtime -device ati-vga,guest_hwcursor=true,romfile="" -cdrom morphos-3.17.iso -kernel morphos-3.17/boot.img` Boots successfully and it is possible to open games and tools. * I was unable to test the fuloong2e board even before this series since it seems to be unfinished [1]. A buildroot-baked kernel [2] booted but doesn't find its root partition, though the issues could be in the buildroot receipt I created. [1] https://osdn.net/projects/qmiga/wiki/SubprojectPegasos2 [2] https://github.com/shentok/buildroot/commits/fuloong2e Bernhard Beschow (10): hw/isa/vt82c686: Resolve chip-specific realize methods hw/isa/vt82c686: Resolve unneeded attribute hw/isa/vt82c686: Prefer pci_address_space() over get_system_memory() hw/isa/vt82c686: Reuse errp hw/isa/vt82c686: Instantiate IDE function in host device hw/isa/vt82c686: Instantiate USB functions in host device hw/isa/vt82c686: Instantiate PM function in host device hw/isa/vt82c686: Instantiate AC97 and MC97 functions in host device hw/isa/vt82c686: Embed RTCState in host device hw/isa/vt82c686: Create rtc-time alias in boards instead configs/devices/mips64el-softmmu/default.mak | 1 - hw/isa/Kconfig | 1 + hw/isa/vt82c686.c | 119 +++++++++++++++---- hw/mips/fuloong2e.c | 21 ++-- hw/ppc/Kconfig | 1 - hw/ppc/pegasos2.c | 25 ++-- include/hw/isa/vt82c686.h | 2 - 7 files changed, 115 insertions(+), 55 deletions(-) Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé