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=-10.1 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, 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 87448C433E0 for ; Fri, 22 May 2020 23:48:44 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 589C020812 for ; Fri, 22 May 2020 23:48:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1590191324; bh=5Sy4xxtTopVBFWbKmXNaDdHsc6ggYp/NRxt1kFT2dSU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=oOhauFU5jmFhCLF5pw05mzdRi9bVkn8yFAt0Ec2wjc8MjnFVRnM0l8jFbvZYNhWW2 hkaJZ+IGzbdDcuj0+5dtdWBn3uR2sbRNO2P0Y0rtwG0KimrE8swYB/uzz/eGaHfnZF M7Cy4a2nOwHczD10AfVgmdUmY4CrfUBRJhbfz518= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387417AbgEVXsn (ORCPT ); Fri, 22 May 2020 19:48:43 -0400 Received: from mail-io1-f67.google.com ([209.85.166.67]:39998 "EHLO mail-io1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387412AbgEVXsm (ORCPT ); Fri, 22 May 2020 19:48:42 -0400 Received: by mail-io1-f67.google.com with SMTP id q8so11951983iow.7 for ; Fri, 22 May 2020 16:48:41 -0700 (PDT) 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=J45nDshYNcYrGRYkIpqQuCHqEq06Xr5wTtd6CkH1TKQ=; b=Px6KCRkXqteLcDbFVtgCfHUK/6jarc22FmaA1LCHeTChauwPqO3TTx/tBSGMpDvtGn nq+WeRDTzJyPXQWg6+cQ9gyPkbc0RwdREDo6osB50S6Q9kW64/or4Qx9ni3MFMhrWqgE MRe/nxtFc4zkzyh1+9Fauy6UmdFkltsVWshEw8Qcl/X1/O1gE+1U2C/GYcst8VbHa1wv zLNdFtOvpcBIHwBPWooJl51zC7OsdW/1sHMqEjSi02qWDwCZOBEneb5NZ4OKBtemEuMc zUgPtnrnif+JqIMoiSEByPDcQQlBzde2QjgAF7/jlSzdEnCBqguCrY/Sqsi5psVQ5Bij 7L9A== X-Gm-Message-State: AOAM531h4j67vgHAXkNJqvKCt+MfTHuNYly97ne2uEotaFsqGbRQKsCo hbQiahnMbMLT0raVoAqIyg== X-Google-Smtp-Source: ABdhPJwvpizplNylsZ+mOBoLddCdqOsvUiQzZKpGEl+BV1UIE2Xf70za28p9484+5NSevVTlVtJ7jw== X-Received: by 2002:a5e:cb4d:: with SMTP id h13mr5172992iok.141.1590191321380; Fri, 22 May 2020 16:48:41 -0700 (PDT) Received: from xps15.herring.priv ([64.188.179.252]) by smtp.googlemail.com with ESMTPSA id w23sm4390877iod.9.2020.05.22.16.48.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 May 2020 16:48:40 -0700 (PDT) From: Rob Herring To: Lorenzo Pieralisi Cc: Bjorn Helgaas , linux-pci@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Linus Walleij Subject: [PATCH 07/15] PCI: v3: Use pci_host_probe() to register host Date: Fri, 22 May 2020 17:48:24 -0600 Message-Id: <20200522234832.954484-8-robh@kernel.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200522234832.954484-1-robh@kernel.org> References: <20200522234832.954484-1-robh@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org The v3 host driver does the same host registration and bus scanning calls as pci_host_probe, so let's use it instead. Cc: Linus Walleij Signed-off-by: Rob Herring --- drivers/pci/controller/pci-v3-semi.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/drivers/pci/controller/pci-v3-semi.c b/drivers/pci/controller/pci-v3-semi.c index 3681e5af3878..198cf2c6ed92 100644 --- a/drivers/pci/controller/pci-v3-semi.c +++ b/drivers/pci/controller/pci-v3-semi.c @@ -239,7 +239,6 @@ struct v3_pci { struct device *dev; void __iomem *base; void __iomem *config_base; - struct pci_bus *bus; u32 config_mem; u32 non_pre_mem; u32 pre_mem; @@ -904,17 +903,7 @@ static int v3_pci_probe(struct platform_device *pdev) val |= V3_SYSTEM_M_LOCK; writew(val, v3->base + V3_SYSTEM); - ret = pci_scan_root_bus_bridge(host); - if (ret) { - dev_err(dev, "failed to register host: %d\n", ret); - return ret; - } - v3->bus = host->bus; - - pci_bus_assign_resources(v3->bus); - pci_bus_add_devices(v3->bus); - - return 0; + return pci_host_probe(host); } static const struct of_device_id v3_pci_of_match[] = { -- 2.25.1 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=-10.0 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,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 08F4FC433E0 for ; Fri, 22 May 2020 23:51:10 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id CE0FE206BE for ; Fri, 22 May 2020 23:51:09 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="quRNk25c" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org CE0FE206BE Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=iOYoevn1UgYD/M0utux6NQMTtyJWNpwXXuK7GPZVtlg=; b=quRNk25cB4Ycl4 j44dMWJ1lBZuya+fgw21P8EjDABF17nPJbSYLgNtavscg0EZ1o+4n6hzrtuaxYU/gjHUAmEdANu9/ L5s7/KieHVQTHH99JY1aj6KhdWMoU16U0BZuTQgGVsXe671f6/OYtkey3tok0+57tTcMC5NpSuyLN xAU/Q1ilC1qKuK2HofAmEdfR48h/6ZUi7U2eU2+KLhJ6xAI+B+veGO1en42qsEJ38WYJJN7h97O8f 0mQ99zmHpOPhOanbBllPFlfW7YOQSmWEXPm6rXg/GA/3YawAND0NmTPFb9+iG8qYhK+DvClqY7JxX GF4lhS9V4V+EWs/19otQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jcHRP-0007PM-EF; Fri, 22 May 2020 23:51:03 +0000 Received: from mail-io1-f65.google.com ([209.85.166.65]) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1jcHP8-0003QJ-Ja for linux-arm-kernel@lists.infradead.org; Fri, 22 May 2020 23:48:44 +0000 Received: by mail-io1-f65.google.com with SMTP id d7so13359464ioq.5 for ; Fri, 22 May 2020 16:48:42 -0700 (PDT) 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=J45nDshYNcYrGRYkIpqQuCHqEq06Xr5wTtd6CkH1TKQ=; b=h5I1OPwKJsfMRO6eUPQf4aUijpUZnWP3PENQlTH/KwCGFnAmmQ4hXeFvoCVanUS/wq FLbahfayyns/yKW/yCATaqrm1xQILDTAvGYBDfwOART3rJpEUtpPX/N8KeyZvL17T1nB 08alk/zGf3Lu8PfF8qo1lCNC1KNtaX4HRhpj2IOoH5ngJearBL5/qmhEIJk6YfAeD+sg R4MKpTfhA8GcatQleH9l4/6LYQSwV2oI9YSXtq9MLEh2Z8giHzJXdm6EF8xoJ443snd8 2UZw8aqISSKpGJdWHKDsSo/ZOs5xHqVFOBErnEPS3bIar82G73Zmenga0roMqL5w52nH jYRg== X-Gm-Message-State: AOAM53337lQr9+NyTmxNzRS1R2fiMCmv/sG33GhPwj8UwzIivlz/7+83 xxR8b2VEO28AhCM57AFrXQ== X-Google-Smtp-Source: ABdhPJwvpizplNylsZ+mOBoLddCdqOsvUiQzZKpGEl+BV1UIE2Xf70za28p9484+5NSevVTlVtJ7jw== X-Received: by 2002:a5e:cb4d:: with SMTP id h13mr5172992iok.141.1590191321380; Fri, 22 May 2020 16:48:41 -0700 (PDT) Received: from xps15.herring.priv ([64.188.179.252]) by smtp.googlemail.com with ESMTPSA id w23sm4390877iod.9.2020.05.22.16.48.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 May 2020 16:48:40 -0700 (PDT) From: Rob Herring To: Lorenzo Pieralisi Subject: [PATCH 07/15] PCI: v3: Use pci_host_probe() to register host Date: Fri, 22 May 2020 17:48:24 -0600 Message-Id: <20200522234832.954484-8-robh@kernel.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200522234832.954484-1-robh@kernel.org> References: <20200522234832.954484-1-robh@kernel.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200522_164842_658899_B4AA5728 X-CRM114-Status: GOOD ( 12.65 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Bjorn Helgaas , linux-pci@vger.kernel.org, Linus Walleij , linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org The v3 host driver does the same host registration and bus scanning calls as pci_host_probe, so let's use it instead. Cc: Linus Walleij Signed-off-by: Rob Herring --- drivers/pci/controller/pci-v3-semi.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/drivers/pci/controller/pci-v3-semi.c b/drivers/pci/controller/pci-v3-semi.c index 3681e5af3878..198cf2c6ed92 100644 --- a/drivers/pci/controller/pci-v3-semi.c +++ b/drivers/pci/controller/pci-v3-semi.c @@ -239,7 +239,6 @@ struct v3_pci { struct device *dev; void __iomem *base; void __iomem *config_base; - struct pci_bus *bus; u32 config_mem; u32 non_pre_mem; u32 pre_mem; @@ -904,17 +903,7 @@ static int v3_pci_probe(struct platform_device *pdev) val |= V3_SYSTEM_M_LOCK; writew(val, v3->base + V3_SYSTEM); - ret = pci_scan_root_bus_bridge(host); - if (ret) { - dev_err(dev, "failed to register host: %d\n", ret); - return ret; - } - v3->bus = host->bus; - - pci_bus_assign_resources(v3->bus); - pci_bus_add_devices(v3->bus); - - return 0; + return pci_host_probe(host); } static const struct of_device_id v3_pci_of_match[] = { -- 2.25.1 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel