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=-13.2 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,NICE_REPLY_A,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=unavailable 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 ABD93C433E2 for ; Mon, 7 Sep 2020 19:44:57 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 525AA21532 for ; Mon, 7 Sep 2020 19:44:57 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="x6jtKtcP"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=nvidia.com header.i=@nvidia.com header.b="dbyO4rHY" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 525AA21532 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=nvidia.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+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=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:Date:Message-ID:From: References:To:Subject:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=4V7/Bnkm4LZx0YE6n8QSt4lw6sY9fquJQW6BEJP3o58=; b=x6jtKtcPM5V7lF5IFYVPTty0t FDnA9HPdywjQ/3u2Ia+04uWrhQ732vhyd4yk/VkVBgdmhaxJRuHomHeXDrdHjbe4oIPlSrmI/5ky7 J+vAvc8kZpYQjiPpOqBLdKSAeeLLSJ+4RLpZGXWf7Pt0PKrirJjt1Uv6fUBxnkWFwpoygCAe26Vvt 7OoPS7v6s9w69RMDwoIWxvE4VORNYuKJF3hacv5+9fnilujnjEt/sZqyErKl10KmHLxbMqCHok4Bn xXwZAwr+v+FEL60Tw9LWrqnaPDfwQeEziYnVhWapUXwZGDpYNr+vd19DdJcD//u6wLp6iD6V9iacK F1Wy2briQ==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kFN3E-0002ld-8Z; Mon, 07 Sep 2020 19:43:40 +0000 Received: from hqnvemgate25.nvidia.com ([216.228.121.64]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kFN3A-0002lF-9h for linux-arm-kernel@lists.infradead.org; Mon, 07 Sep 2020 19:43:37 +0000 Received: from hqpgpgate101.nvidia.com (Not Verified[216.228.121.13]) by hqnvemgate25.nvidia.com (using TLS: TLSv1.2, DES-CBC3-SHA) id ; Mon, 07 Sep 2020 12:42:45 -0700 Received: from hqmail.nvidia.com ([172.20.161.6]) by hqpgpgate101.nvidia.com (PGP Universal service); Mon, 07 Sep 2020 12:43:34 -0700 X-PGP-Universal: processed; by hqpgpgate101.nvidia.com on Mon, 07 Sep 2020 12:43:34 -0700 Received: from [10.26.73.157] (10.124.1.5) by HQMAIL107.nvidia.com (172.20.187.13) with Microsoft SMTP Server (TLS) id 15.0.1473.3; Mon, 7 Sep 2020 19:43:33 +0000 Subject: Re: [PATCH 8/9] firmware: tegra: Enable BPMP support on Tegra234 To: Thierry Reding References: <20200716141856.544718-1-thierry.reding@gmail.com> <20200716141856.544718-9-thierry.reding@gmail.com> From: Jon Hunter Message-ID: <05068df4-7c6d-e291-9bed-4b4a57eb2498@nvidia.com> Date: Mon, 7 Sep 2020 20:43:31 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <20200716141856.544718-9-thierry.reding@gmail.com> X-Originating-IP: [10.124.1.5] X-ClientProxiedBy: HQMAIL111.nvidia.com (172.20.187.18) To HQMAIL107.nvidia.com (172.20.187.13) Content-Language: en-US DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nvidia.com; s=n1; t=1599507765; bh=73KBzlUIA5eYA1VqGk+Jtuiw1SyndnYIZV7XhXuuO9k=; h=X-PGP-Universal:Subject:To:CC:References:From:Message-ID:Date: User-Agent:MIME-Version:In-Reply-To:X-Originating-IP: X-ClientProxiedBy:Content-Type:Content-Language: Content-Transfer-Encoding; b=dbyO4rHY+Qa9L2N8jGL7BRzWWFDUdzg0OAnguoQ9F/9cKxzGxuhb/PA8YeYVCKIvG gHqBOTh5YWj1ycSn0X0g2R5kKN0jKW9fGWaBSZqvG1/WgumeQ8gHVf2X6DqGIMG6ha CegGIb8wuv5AOxtHuVUF9VRjVH3v5MZHkxlXktuxt2gfFyf2Newbg63a075SSDW9kn WD2XBz52Q3lljVs2mNzt53pAO9lLYuosQM9ThaTOPX5M322io18/R6b/x4lIjmqxI4 kNLeEFOZ860P4+Q4/YUealIXpev0K6ilDQjmTNhESs7MhpHbUGx0FhhxnsLzA16RTm mlRoSJfRuEyeA== X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200907_154336_482795_66451BA7 X-CRM114-Status: GOOD ( 25.07 ) 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: linux-tegra@vger.kernel.org, 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+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 16/07/2020 15:18, Thierry Reding wrote: > From: Thierry Reding > > Enable support for the BPMP on Tegra234 to avoid relying on Tegra194 > being enabled to pull in the needed OF device ID table entry. > > On simulation platforms the BPMP hasn't booted up yet by the time we > probe the BPMP driver and the BPMP hasn't had a chance to mark the > doorbell as ringable by the CCPLEX. This corresponding check in the > BPMP driver will therefore fail. Work around this by disabling the > check on simulation platforms. > > Signed-off-by: Thierry Reding > --- > drivers/firmware/tegra/bpmp.c | 3 ++- > drivers/mailbox/tegra-hsp.c | 9 ++++++++- > 2 files changed, 10 insertions(+), 2 deletions(-) > > diff --git a/drivers/firmware/tegra/bpmp.c b/drivers/firmware/tegra/bpmp.c > index 4d93d8925e14..0742a90cb844 100644 > --- a/drivers/firmware/tegra/bpmp.c > +++ b/drivers/firmware/tegra/bpmp.c > @@ -856,7 +856,8 @@ static const struct tegra_bpmp_soc tegra210_soc = { > > static const struct of_device_id tegra_bpmp_match[] = { > #if IS_ENABLED(CONFIG_ARCH_TEGRA_186_SOC) || \ > - IS_ENABLED(CONFIG_ARCH_TEGRA_194_SOC) > + IS_ENABLED(CONFIG_ARCH_TEGRA_194_SOC) || \ > + IS_ENABLED(CONFIG_ARCH_TEGRA_234_SOC) > { .compatible = "nvidia,tegra186-bpmp", .data = &tegra186_soc }, > #endif > #if IS_ENABLED(CONFIG_ARCH_TEGRA_210_SOC) > diff --git a/drivers/mailbox/tegra-hsp.c b/drivers/mailbox/tegra-hsp.c > index 834b35dc3b13..e07091d71986 100644 > --- a/drivers/mailbox/tegra-hsp.c > +++ b/drivers/mailbox/tegra-hsp.c > @@ -13,6 +13,8 @@ > #include > #include > > +#include > + > #include > > #include "mailbox.h" > @@ -322,7 +324,12 @@ static int tegra_hsp_doorbell_startup(struct mbox_chan *chan) > if (!ccplex) > return -ENODEV; > > - if (!tegra_hsp_doorbell_can_ring(db)) > + /* > + * On simulation platforms the BPMP hasn't had a chance yet to mark > + * the doorbell as ringable by the CCPLEX, so we want to skip extra > + * checks here. > + */ > + if (tegra_is_silicon() && !tegra_hsp_doorbell_can_ring(db)) > return -ENODEV; > > spin_lock_irqsave(&hsp->lock, flags); > Reviewed-by: Jon Hunter Cheers Jon -- nvpublic _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel