From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-19.5 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A3D41C4338F for ; Mon, 26 Jul 2021 13:42:00 +0000 (UTC) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 28E2060E08 for ; Mon, 26 Jul 2021 13:42:00 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 28E2060E08 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=chromium.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id A3851833B9; Mon, 26 Jul 2021 15:41:16 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="Wq4MvZbH"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id B7ECB83330; Mon, 26 Jul 2021 15:39:24 +0200 (CEST) Received: from mail-oo1-xc2f.google.com (mail-oo1-xc2f.google.com [IPv6:2607:f8b0:4864:20::c2f]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 5175F83330 for ; Mon, 26 Jul 2021 15:35:17 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-oo1-xc2f.google.com with SMTP id s21-20020a4ae5550000b02902667598672bso2239549oot.12 for ; Mon, 26 Jul 2021 06:35:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=BVvc4ohwCF5ZZnGvfMGVqN6okSXh0CYdl3Y6py/+66k=; b=Wq4MvZbHw236Ox3L6wFIjglqQnhTQoYME2hzuWxsNKO34hhhOv7PlnPODa5uGpcRGW CI2nxbpzipP4WE+91QJGeqTJgMqjn7y6/mDv9JIYw1U/UdauK4d5VJ1R1wRmlVrhmnc3 KWuVcCEEovS1i2z5qVE/iOYLp20Umy9zCEq3U= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=BVvc4ohwCF5ZZnGvfMGVqN6okSXh0CYdl3Y6py/+66k=; b=kwM5c2bMI4Xj4+W7inCjl42UTHt21eRM/oW4RExd+V5hTnkC9wioCrhAahOAITU6+T qqj3aZXolrynZqZvnC14N27NH8It/QUA74OobVNoc88w9tCCZ2CCKUVOjT/nvT3/xDRP OsZFJccxG6UrCRVity27xs9eTlOhbKf+ZQNXAGvBqt5UQxkp7TkX2rs0OdDxtvvbdoVc phVAKA/cXeKZUdAytMxhjSJULd5wzokynTWz+2n4dyDhK6x/oU8dp3teGJshpi1oDpFn g5PoOOh9xxBxoWgMN9tRNYb6qSv1J8m7Bn97kJvNgmZjCmH+F2VCutTPwxt4Yd3KPJf1 ZCRA== X-Gm-Message-State: AOAM533xIHVSjp/DfBD8UBGHspPcVm6Zp2aleUzOkeAjd457GZj8qzrP btln1jhhmIfCLZ7TVocsMwaZqtxiF5VFPi7F X-Google-Smtp-Source: ABdhPJzn3+wIPjSspOKbXdU9NTQ643jFBpfX3IHyJk6vjlbHxDdccb7OEZsvpSCGzf9rmWjZ5h2NYA== X-Received: by 2002:a4a:b6ca:: with SMTP id w10mr3593244ooo.17.1627306515749; Mon, 26 Jul 2021 06:35:15 -0700 (PDT) Received: from kiwi.bld.corp.google.com (c-67-190-101-114.hsd1.co.comcast.net. [67.190.101.114]) by smtp.gmail.com with ESMTPSA id t141sm6591527oot.40.2021.07.26.06.35.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 26 Jul 2021 06:35:15 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Tom Rini , Simon Glass , Stefano Babic Subject: [PATCH 19/33] pci: imx: Drop use of DM_PCI Date: Mon, 26 Jul 2021 07:34:25 -0600 Message-Id: <20210726133440.634682-20-sjg@chromium.org> X-Mailer: git-send-email 2.32.0.432.gabb21c7263-goog In-Reply-To: <20210726133440.634682-1-sjg@chromium.org> References: <20210726133440.634682-1-sjg@chromium.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean Now that DM_PCI is always enabled we don't need to check it. Drop this old code. Signed-off-by: Simon Glass --- drivers/pci/pcie_imx.c | 81 ------------------------------------------ 1 file changed, 81 deletions(-) diff --git a/drivers/pci/pcie_imx.c b/drivers/pci/pcie_imx.c index 7b46fdb89a3..756166fd3ea 100644 --- a/drivers/pci/pcie_imx.c +++ b/drivers/pci/pcie_imx.c @@ -681,86 +681,6 @@ static int imx_pcie_link_up(struct imx_pcie_priv *priv) return 0; } -#if !CONFIG_IS_ENABLED(DM_PCI) -static struct imx_pcie_priv imx_pcie_priv = { - .dbi_base = (void __iomem *)MX6_DBI_ADDR, - .cfg_base = (void __iomem *)MX6_ROOT_ADDR, -}; - -static struct imx_pcie_priv *priv = &imx_pcie_priv; - -static int imx_pcie_read_config(struct pci_controller *hose, pci_dev_t d, - int where, u32 *val) -{ - struct imx_pcie_priv *priv = hose->priv_data; - - return imx_pcie_read_cfg(priv, d, where, val); -} - -static int imx_pcie_write_config(struct pci_controller *hose, pci_dev_t d, - int where, u32 val) -{ - struct imx_pcie_priv *priv = hose->priv_data; - - return imx_pcie_write_cfg(priv, d, where, val); -} - -void imx_pcie_init(void) -{ - /* Static instance of the controller. */ - static struct pci_controller pcc; - struct pci_controller *hose = &pcc; - int ret; - - memset(&pcc, 0, sizeof(pcc)); - - hose->priv_data = priv; - - /* PCI I/O space */ - pci_set_region(&hose->regions[0], - MX6_IO_ADDR, MX6_IO_ADDR, - MX6_IO_SIZE, PCI_REGION_IO); - - /* PCI memory space */ - pci_set_region(&hose->regions[1], - MX6_MEM_ADDR, MX6_MEM_ADDR, - MX6_MEM_SIZE, PCI_REGION_MEM); - - /* System memory space */ - pci_set_region(&hose->regions[2], - MMDC0_ARB_BASE_ADDR, MMDC0_ARB_BASE_ADDR, - 0xefffffff, PCI_REGION_MEM | PCI_REGION_SYS_MEMORY); - - hose->region_count = 3; - - pci_set_ops(hose, - pci_hose_read_config_byte_via_dword, - pci_hose_read_config_word_via_dword, - imx_pcie_read_config, - pci_hose_write_config_byte_via_dword, - pci_hose_write_config_word_via_dword, - imx_pcie_write_config); - - /* Start the controller. */ - ret = imx_pcie_link_up(priv); - - if (!ret) { - pci_register_hose(hose); - hose->last_busno = pci_hose_scan(hose); - } -} - -void imx_pcie_remove(void) -{ - imx6_pcie_assert_core_reset(priv, true); -} - -/* Probe function. */ -void pci_init_board(void) -{ - imx_pcie_init(); -} -#else static int imx_pcie_dm_read_config(const struct udevice *dev, pci_dev_t bdf, uint offset, ulong *value, enum pci_size_t size) @@ -852,4 +772,3 @@ U_BOOT_DRIVER(imx_pcie) = { .priv_auto = sizeof(struct imx_pcie_priv), .flags = DM_FLAG_OS_PREPARE, }; -#endif -- 2.32.0.432.gabb21c7263-goog