From patchwork Mon Feb 27 14:01:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 657053 Delivered-To: patch@linaro.org Received: by 2002:adf:a3c6:0:0:0:0:0 with SMTP id m6csp2378382wrb; Mon, 27 Feb 2023 06:22:46 -0800 (PST) X-Google-Smtp-Source: AK7set913Te9eAQwaWmas2ekQ1KUThut/wM1xK6yyeEWZy+nXZSUqO8lfGLUMdE0uMlrGqYXkwcj X-Received: by 2002:a05:6214:20c4:b0:56e:aa11:daa3 with SMTP id 4-20020a05621420c400b0056eaa11daa3mr57948693qve.14.1677507766481; Mon, 27 Feb 2023 06:22:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1677507766; cv=none; d=google.com; s=arc-20160816; b=BoWFqIO9sbgNK22I1VON5X8LuDe7CaUXVDPDkmrh5dnBmjZcPgV/EnqCq5Cfa9HbVH fbE7gXZI+fXzfevYoWJRPa4J2aJrEylGvEY7dgxl2ux+/tzz70RNKZYYxJp96+531R/J 1k4xDEHzyYHE76ndtpJdMAlPnkhIUd+ManHn4TPa13kcaac7ddr716guqllDogyONVOw Fv5Y4D/ymVzWKTTdlhqy5l3emKEGsBV3lF+VahuunbL1ybCGnsRtBmUqFGTX0ssuuVlw pYHsDQsqxK0DKVn/Ue658QX+DQolH3emcE9JTfwswRB7cClX2ZEIwVQqqJE051njEgkR uMCg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=9BKlSKMnDRINkghzZqZAhHYmo0aDImrj9cOx+uErDGk=; b=mkfojTYa3tcIdK+BwWWm/hWbW22IwgGFzIt2YpTG3pw6wVVksbnd1CwyvOO8Bp8bYC BbLtpwGLRBQ0GPx3JyuFhu3Pe5gJ3p+ED/MxgxoOxisb4mQ3ZyLk3Mbgy3yqJPYuqFJV j8MFvYL4MMS5arC4s0s7WbhMeNySgGZ1QGLhoK1h53bqODfSzWLTcX34ukNlt5KUHO33 9OOKrJyKNRxedABPxDlW0OeKgXhizV+G0VgAYcS35ZNVnGrVRRitstKAQvMFkxGUPaEz F+fdahznmyGc+Hr83A+zEgVMacMqgKOVoeYFcwnPwTQddOX22f8IphnIbJfw1Ee/yxDF LtxA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=JciwVA5c; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id d205-20020a3768d6000000b0074283f7d02fsi5502613qkc.733.2023.02.27.06.22.46 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 27 Feb 2023 06:22:46 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=JciwVA5c; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pWeFJ-0001Z2-LI; Mon, 27 Feb 2023 09:12:55 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pWeDc-0008GB-7R for qemu-devel@nongnu.org; Mon, 27 Feb 2023 09:11:13 -0500 Received: from mail-wr1-x430.google.com ([2a00:1450:4864:20::430]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pWeDZ-000109-0X for qemu-devel@nongnu.org; Mon, 27 Feb 2023 09:11:07 -0500 Received: by mail-wr1-x430.google.com with SMTP id bv17so6375140wrb.5 for ; Mon, 27 Feb 2023 06:11:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=9BKlSKMnDRINkghzZqZAhHYmo0aDImrj9cOx+uErDGk=; b=JciwVA5cxvJm3qxKhgzMTvK0pqS+IqbvGL4S+MfFcbxrW4N2HEbApjSS+YHzYPmg4P KrFxeSayGAH/jSfvSNB1zuJzXwUaDngPBEvIikXm8ksDEPOpCGIrcXgS/own/BpE2pUW 9tlVja5Uyw3uY2/5a5fo0Yt3fnLk8k8xADB+w2qbcN14FhtucM/ZGz7JQ485o9m3gHSd Qyr5x04rMw1TxlpZp0AFFB78Ri8aeejXyL5fmaq4thI5rEnBDIlpzEzRiowNaEXG0UZu ci+4cuAjO6Wm9I2b8UILMe884r9s3aR+Yum7EBDEnQg+6dU7kXoSH///s8r+SvItSddO yrag== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=9BKlSKMnDRINkghzZqZAhHYmo0aDImrj9cOx+uErDGk=; b=Zg7CjN7Kgh2v456FIsxck/AUvfXLZyNZByMyQifKQgiuQrWRY9B6FAE+stqKau/G0b gb2D1fjXHFqNn0Urwv2Pzqwb6Bocd1EAL33JqjAfsxZwGEQ0RWqmWn8iSDuhkS1cl2Ux mUGT3eZMaHHoRTdRTC89Q+9vwaymFILWhnj725LzXf02cc4geNunAELOb4iNNRCmTmkL RGDA4qIvmOn7hl0+GrIBvIxe4Zur7yIPa8qvWVjuLXqiJ6sEEN1JW/j9dAZUIfiyEazy G+nSRmyChQo1p/82zKCFkf9b0gVGmhR1S4j5L5hA53GgNgg/FEWjFt0xAoFDzgsr98qe /WhA== X-Gm-Message-State: AO0yUKVYZFUxnX63wrBc7i5+VfTxXsjCeWKwqBwuUjHcfKsN6EfbL/vU wfoY9GM16ieh2RU7bNbZbrd482YFGOC/cKfz X-Received: by 2002:a5d:408e:0:b0:2c7:deb:c61 with SMTP id o14-20020a5d408e000000b002c70deb0c61mr13826040wrp.39.1677507060733; Mon, 27 Feb 2023 06:11:00 -0800 (PST) Received: from localhost.localdomain ([81.0.6.76]) by smtp.gmail.com with ESMTPSA id y13-20020adfe6cd000000b002c8476dde7asm7188020wrm.114.2023.02.27.06.10.59 for (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Mon, 27 Feb 2023 06:11:00 -0800 (PST) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Subject: [PULL 106/126] hw/ide: Un-inline ide_set_irq() Date: Mon, 27 Feb 2023 15:01:53 +0100 Message-Id: <20230227140213.35084-97-philmd@linaro.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20230227140213.35084-1-philmd@linaro.org> References: <20230227140213.35084-1-philmd@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::430; envelope-from=philmd@linaro.org; helo=mail-wr1-x430.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, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Only include "hw/irq.h" where appropriate. Signed-off-by: Philippe Mathieu-Daudé Message-Id: <20230215112712.23110-10-philmd@linaro.org> Reviewed-by: Richard Henderson --- hw/ide/ahci.c | 1 + hw/ide/core.c | 8 ++++++++ hw/ide/ich.c | 1 + hw/ide/macio.c | 1 + hw/ide/microdrive.c | 1 + hw/ide/pci.c | 1 + hw/misc/macio/gpio.c | 1 + hw/sparc64/sun4u.c | 1 + include/hw/ide/internal.h | 9 +-------- 9 files changed, 16 insertions(+), 8 deletions(-) diff --git a/hw/ide/ahci.c b/hw/ide/ahci.c index 595a96203f..08c7ae6e3c 100644 --- a/hw/ide/ahci.c +++ b/hw/ide/ahci.c @@ -22,6 +22,7 @@ */ #include "qemu/osdep.h" +#include "hw/irq.h" #include "hw/pci/msi.h" #include "hw/pci/pci.h" #include "hw/qdev-properties.h" diff --git a/hw/ide/core.c b/hw/ide/core.c index 5d1039378f..1473b6057f 100644 --- a/hw/ide/core.c +++ b/hw/ide/core.c @@ -24,6 +24,7 @@ */ #include "qemu/osdep.h" +#include "hw/irq.h" #include "hw/isa/isa.h" #include "migration/vmstate.h" #include "qemu/error-report.h" @@ -2782,6 +2783,13 @@ void ide_init2(IDEBus *bus, qemu_irq irq) bus->dma = &ide_dma_nop; } +void ide_set_irq(IDEBus *bus) +{ + if (!(bus->cmd & IDE_CTRL_DISABLE_IRQ)) { + qemu_irq_raise(bus->irq); + } +} + void ide_exit(IDEState *s) { timer_free(s->sector_write_timer); diff --git a/hw/ide/ich.c b/hw/ide/ich.c index 1007a51fcb..d61faab532 100644 --- a/hw/ide/ich.c +++ b/hw/ide/ich.c @@ -61,6 +61,7 @@ */ #include "qemu/osdep.h" +#include "hw/irq.h" #include "hw/pci/msi.h" #include "hw/pci/pci.h" #include "migration/vmstate.h" diff --git a/hw/ide/macio.c b/hw/ide/macio.c index e604466acb..15fd934831 100644 --- a/hw/ide/macio.c +++ b/hw/ide/macio.c @@ -24,6 +24,7 @@ */ #include "qemu/osdep.h" +#include "hw/irq.h" #include "hw/ppc/mac_dbdma.h" #include "hw/qdev-properties.h" #include "migration/vmstate.h" diff --git a/hw/ide/microdrive.c b/hw/ide/microdrive.c index 56c5be3655..b9822b939b 100644 --- a/hw/ide/microdrive.c +++ b/hw/ide/microdrive.c @@ -29,6 +29,7 @@ #include "qapi/error.h" #include "qemu/module.h" #include "sysemu/dma.h" +#include "hw/irq.h" #include "hw/ide/internal.h" #include "qom/object.h" diff --git a/hw/ide/pci.c b/hw/ide/pci.c index 84ba733548..ae638dee0d 100644 --- a/hw/ide/pci.c +++ b/hw/ide/pci.c @@ -24,6 +24,7 @@ */ #include "qemu/osdep.h" +#include "hw/irq.h" #include "hw/pci/pci.h" #include "migration/vmstate.h" #include "sysemu/dma.h" diff --git a/hw/misc/macio/gpio.c b/hw/misc/macio/gpio.c index c8ac5633b2..4deb330471 100644 --- a/hw/misc/macio/gpio.c +++ b/hw/misc/macio/gpio.c @@ -28,6 +28,7 @@ #include "migration/vmstate.h" #include "hw/misc/macio/macio.h" #include "hw/misc/macio/gpio.h" +#include "hw/irq.h" #include "hw/nmi.h" #include "qemu/log.h" #include "qemu/module.h" diff --git a/hw/sparc64/sun4u.c b/hw/sparc64/sun4u.c index 8a56ba9f98..a25e951f9d 100644 --- a/hw/sparc64/sun4u.c +++ b/hw/sparc64/sun4u.c @@ -28,6 +28,7 @@ #include "qapi/error.h" #include "qemu/datadir.h" #include "cpu.h" +#include "hw/irq.h" #include "hw/pci/pci.h" #include "hw/pci/pci_bridge.h" #include "hw/pci/pci_bus.h" diff --git a/include/hw/ide/internal.h b/include/hw/ide/internal.h index 84d3722d67..57a6278327 100644 --- a/include/hw/ide/internal.h +++ b/include/hw/ide/internal.h @@ -8,7 +8,6 @@ */ #include "hw/ide.h" -#include "hw/irq.h" #include "sysemu/dma.h" #include "hw/block/block.h" #include "exec/ioport.h" @@ -572,13 +571,6 @@ static inline IDEState *idebus_active_if(IDEBus *bus) return bus->ifs + bus->unit; } -static inline void ide_set_irq(IDEBus *bus) -{ - if (!(bus->cmd & IDE_CTRL_DISABLE_IRQ)) { - qemu_irq_raise(bus->irq); - } -} - /* hw/ide/core.c */ extern const VMStateDescription vmstate_ide_bus; @@ -627,6 +619,7 @@ int ide_init_drive(IDEState *s, BlockBackend *blk, IDEDriveKind kind, void ide_init2(IDEBus *bus, qemu_irq irq); void ide_exit(IDEState *s); int ide_init_ioport(IDEBus *bus, ISADevice *isa, int iobase, int iobase2); +void ide_set_irq(IDEBus *bus); void ide_register_restart_cb(IDEBus *bus); void ide_exec_cmd(IDEBus *bus, uint32_t val);