Received: by 2002:a05:6a10:eb17:0:0:0:0 with SMTP id hx23csp3728537pxb; Tue, 7 Sep 2021 06:25:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzpwe9ZsKlK6+x27snGoEA3iLMTBoF8+x9kQ5gnb7My5H6o2RHxt/rHdCGQ4c+A3aC8U0Dn X-Received: by 2002:a50:eacc:: with SMTP id u12mr18260853edp.140.1631021131722; Tue, 07 Sep 2021 06:25:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631021131; cv=none; d=google.com; s=arc-20160816; b=itzuoodhpmaaIGeqRAZIDkh60a1JLDDrIctw5OVypk3kpIqBweW95LVeV3QXteiqt4 KKPZXzIuLMFg1vxAObWxB/LeQ+0ok50D+IkBukV6ZQe+rdxH+Jgo+bq2ct3VmrtH/VN4 CWKt2O3IOOzs2ANy7WU5pDmqV7EaurQmg6RYoyQz3Q0v0KMTYiM9IZ6etImDkXnCECqT cEfY2SdDcUGCuGlXb4rbFgIMYHjfw1zPKu/OP/g7vskm2mmm2ido2cSZDydHNY0j0v+t AKoNd0sL5vtAJ51xY3QoTILDmSmQhy6KuRfU+eaavBm86qJuyp+12CGA2Pwx8RHJeEZ9 g/3A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=hWbWyuW5aU8mLi349jhyHP0vmo8bfEQPYUaqON4P71c=; b=PzgFjYI8gTyldUT/W43J+/HHC55NWr26FLMC6JlUXpyaCMVbiaTO9XCVjmcj2URG89 UwT5v0rGYsoo1MMVNQ9EG7Qnd08oPjetdJawbHZyiss9tK0uj929zKtz0LXIqNU4gso1 F5gq5AkAdoWOKafrY80RjLqWnul2b/G4HJDDwsL063zlrlMfHKkjSkwhNJWC0MHay484 Uig4jHXVnn1no1wWkxpmC+tcmGDkPRVMnLm4Henb36anmuUH2tI+boe6m4F6xgMLB9Ui jbT5cSKmurt/7WDZ9l5da69TULD0yyWCEqu3DZ/mNWcE0Ha+M6d+4v9lhWkTuhUS4qfH ulNA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="Q/zlmlKm"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h20si10141676ejt.70.2021.09.07.06.25.07; Tue, 07 Sep 2021 06:25:31 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="Q/zlmlKm"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1344638AbhIGNKb (ORCPT + 99 others); Tue, 7 Sep 2021 09:10:31 -0400 Received: from mail.kernel.org ([198.145.29.99]:36844 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1344507AbhIGNK1 (ORCPT ); Tue, 7 Sep 2021 09:10:27 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id A08F161057; Tue, 7 Sep 2021 13:09:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1631020161; bh=EwAZ6xsh+B077xdiAiUPyl2HqmdVrDjC+5YWJzZ/NfU=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=Q/zlmlKmY5yaK8vdBrwafAOfK+k7tAOK2PrHwh8Y7zubnXxcJNdNEK3MGJd7YYk8t sVl5Iu+QmwjsouHH6tILI1wa00lk2DaRqTAA5QfccE5pIVUom4M8sghvYRxsBkj2FH fu8HjQChFTdeBL09bWX+HBa4oYvDUhf0iKabh82sdWM1dtDS/4qAMSkAqSng5JuHj2 4h3AnJHki2aETz+rcuvDs0HiTdNEL5+UsvCFeXrlbc2lTl1lOSbnMGZu9fJxtrcO7j 3rSOF6EWvhoobW0F7JVSY7MaQGZzVM2UUtoW+vwTyvjnOA/L0fJzuYdmV7faaUqPM/ jsXz/nziD5lXg== Received: by mail-ej1-f44.google.com with SMTP id a25so19578065ejv.6; Tue, 07 Sep 2021 06:09:21 -0700 (PDT) X-Gm-Message-State: AOAM530VhfuOXCNWvMa6BOfNEjYNHIOAPkJA8LvYbg3gWFmHn7GHSzLO A4vReSfg3p0kvQGR439jHSEp2bm+a2YKEvmKKw== X-Received: by 2002:a17:906:2dcf:: with SMTP id h15mr18410957eji.320.1631020160188; Tue, 07 Sep 2021 06:09:20 -0700 (PDT) MIME-Version: 1.0 References: <20210903145340.225511-1-daniel.baluta@oss.nxp.com> <20210903145340.225511-3-daniel.baluta@oss.nxp.com> In-Reply-To: From: Rob Herring Date: Tue, 7 Sep 2021 08:09:08 -0500 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v2 2/2] dt-bindings: dsp: fsl: Add DSP optional clocks documentation To: Daniel Baluta Cc: Daniel Baluta , Mark Brown , Pierre-Louis Bossart , Liam Girdwood , Ranjani Sridharan , Kai Vehmanen , Devicetree List , Shawn Guo , Pengutronix Kernel Team , Fabio Estevam , dl-linux-imx , =?UTF-8?Q?P=C3=A9ter_Ujfalusi?= , Linux-ALSA , Linux Kernel Mailing List , Suman Anna , Daniel Baluta , Shengjiu Wang Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Sep 4, 2021 at 9:51 AM Daniel Baluta wrote: > > On Fri, Sep 3, 2021 at 8:11 PM Rob Herring wrote: > > > > On Fri, Sep 03, 2021 at 05:53:40PM +0300, Daniel Baluta wrote: > > > From: Daniel Baluta > > > > > > DSP node on the Linux kernel side must also take care of enabling > > > DAI/DMA related clocks. > > > > > > By design we choose to manage DAI/DMA clocks from the kernel side because of > > > the architecture of some i.MX8 boards. > > > > > > Clocks are handled by a special M4 core which runs a special firmware > > > called SCFW (System Controler firmware). > > > > > > This communicates with A cores running Linux via a special Messaging > > > Unit and implements a custom API which is already implemented by the > > > Linux kernel i.MX clocks implementation. > > > > > > Note that these clocks are optional. We can use the DSP without them. > > > > > > Signed-off-by: Daniel Baluta > > > --- > > > .../devicetree/bindings/dsp/fsl,dsp.yaml | 33 +++++++++++++++++++ > > > 1 file changed, 33 insertions(+) > > > > > > diff --git a/Documentation/devicetree/bindings/dsp/fsl,dsp.yaml b/Documentation/devicetree/bindings/dsp/fsl,dsp.yaml > > > index 7afc9f2be13a..1453668c0194 100644 > > > --- a/Documentation/devicetree/bindings/dsp/fsl,dsp.yaml > > > +++ b/Documentation/devicetree/bindings/dsp/fsl,dsp.yaml > > > @@ -24,16 +24,49 @@ properties: > > > maxItems: 1 > > > > > > clocks: > > > + minItems: 3 > > > items: > > > - description: ipg clock > > > - description: ocram clock > > > - description: core clock > > > + - description: esai0 core clock for accessing registers > > > + - description: esai0 baud clock > > > + - description: esai0 system clock > > > + - description: esai0 spba clock required when ESAI is placed in slave mode > > > + - description: SAI1 bus clock > > > + - description: SAI1 master clock 0 > > > + - description: SAI1 master clock 1 > > > + - description: SAI1 master clock 2 > > > + - description: SAI1 master clock 3 > > > + - description: SAI3 bus clock > > > + - description: SAI3 master clock 0 > > > + - description: SAI3 master clock 1 > > > + - description: SAI3 master clock 2 > > > + - description: SAI3 master clock 3 > > > + - description: SDMA3 root clock used for accessing registers > > > > Sigh, I just rejected this kind of thing for the other i.MX8 DSP > > binding[1]. > > > > Add a reference to the h/w block and then get the clocks (and other > > resources) from there. > > The H/W block is controlled by the DSP firmware. So, we don't want > to use the Linux kernel driver (thus the H/W block device tree node). 'status' is how you disable a device to not be used by the OS. The information about that device's resources are already in DT, we don't need to duplicate that here. If you want a list of devices assigned to the DSP here, that would be okay. > The only thing that we cannot control from the DSP firmware are the clocks > hence we handle them in the DSP node. > > We moved the DAI clocks under the DSP node as I think you suggested here: > > https://www.lkml.org/lkml/2020/3/12/969 No, that's certainly not what I was suggesting. The resources in the DSP node should be the h/w resources of the DSP itself. Rob