Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp603296pxu; Fri, 23 Oct 2020 08:48:01 -0700 (PDT) X-Google-Smtp-Source: ABdhPJznrLX2sZR/rKrgrJEusLbX5A6nEoA7UhS/FQhx1siUYWwzS3nxUvcVfPMyyCAuXsHApfvy X-Received: by 2002:a17:906:3c03:: with SMTP id h3mr2533979ejg.78.1603468081411; Fri, 23 Oct 2020 08:48:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603468081; cv=none; d=google.com; s=arc-20160816; b=M3fgbbsABare+3dOx/P7ZaqWEK1um68PzMaMLvhPNiAjHvPvm176Xyccqj9CuXabcF 8/sDj87Z0kFZJQVwaz/9US+0O6KQBm3jhJyvGe/z4iVwx1Uyd2wSm2Vu3NNk3wjHpH/W V2Twl3DzvJ8HnFRtjKRk+yr5uHA7686nG2m/u6/dtGLFKoZ24HLgoDHWeYz5PCM8HYvC 4m5bOoYXEJJvYtiIenQm0sYiGDbBnx3kQbxWOovVlC0z+U1dfo+ZIWRLbgkUx3lJYyJ8 rGVszqcaEkWcMvEsrMfbHg86JEr13o30cXFxHrz7Jy0zdjUE1ZP8EfrXb3Luxqar2ydH 45QA== 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; bh=2DJdSBX8szjPIQTzW3YOotIcf7ou9mdsTh5wLqX75BY=; b=re07+DkcJaYlbSLELqplzya337jdIt/Ji92VIRnQLdIbSqMTrJpoLh8072RfcX0q/l Bbk3xZd9et+kJ/DodUhsMCNyWD+zAk++uYw18Fbi7CgXQi8t64eu5Rs26dOzlqmI1ciS 6UlyaFi0rvpJJA5/tsSyVnZiGXmXMluSIyW3wM95bouzbc45qQpntAtHwOC8iKkvFSD7 DFVqY2n+zitvlXXW1Q3Tdx4tymR8nTHR0aBnGjE4USj5n4ekrbXsFpm3BpTyYV4G+Q9O /diIoBslabXJc926lQVjXyY86Whwn3no9wgKcFfxGwbNfMLT3Bf1g0rPV8vPVRzk+zm6 32BQ== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id s26si1214091edr.329.2020.10.23.08.47.38; Fri, 23 Oct 2020 08:48:01 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S463599AbgJWM1q (ORCPT + 99 others); Fri, 23 Oct 2020 08:27:46 -0400 Received: from mail-ot1-f65.google.com ([209.85.210.65]:46396 "EHLO mail-ot1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S372336AbgJWM1p (ORCPT ); Fri, 23 Oct 2020 08:27:45 -0400 Received: by mail-ot1-f65.google.com with SMTP id m11so1105140otk.13; Fri, 23 Oct 2020 05:27:43 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=2DJdSBX8szjPIQTzW3YOotIcf7ou9mdsTh5wLqX75BY=; b=p1s9JDXcDKVHPd0Mgzy3UrNPRzpRA8wbvM7ZWGWd8jk2ryN5ap7Uj36rDKskNPwdbf NAyEhWfXpD3OBKp9WG60d9i/Z9T6lDnnJpr0deO74hJ89lOK2ppObYxxmxS9j08gddg9 j6m5GI3X43JSKSuxOpVGgbDkfuELsN9C879SdkPrwJ1G47BWvp/gpfbJmfIVb/5ntY09 FksOQDLst2UucgiGjUxKS5Sc2IPj5mQh3sN1exN10QrVhYkmxXiMbMg+KABulWhoxUzD 5ba6yQjQyGXoGyLWkFZL0FzTVg15J0G1ihsu8jrbKbPDXjs5UY5Dc5scFpyUffJpQg/C rQEg== X-Gm-Message-State: AOAM533g62Scwn0SJ1cCh2bQlDRcfuLN57RvdG98iF0mJPB4mtJzuvhW eFCMTZ3mt/Szz/xvAZkSOT5KcQaQS5yY7+EVr2c= X-Received: by 2002:a9d:5e14:: with SMTP id d20mr1239076oti.107.1603456063222; Fri, 23 Oct 2020 05:27:43 -0700 (PDT) MIME-Version: 1.0 References: <20201023075530.19295-1-prabhakar.mahadev-lad.rj@bp.renesas.com> <20201023075530.19295-2-prabhakar.mahadev-lad.rj@bp.renesas.com> In-Reply-To: From: Geert Uytterhoeven Date: Fri, 23 Oct 2020 14:27:32 +0200 Message-ID: Subject: Re: [PATCH 1/2] arm64: dts: renesas: hihope-common: Add optee node To: "Lad, Prabhakar" Cc: Lad Prabhakar , Magnus Damm , Rob Herring , Linux-Renesas , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , Linux Kernel Mailing List , Biju Das , Marek Vasut Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Prabhakar, CC Marek On Fri, Oct 23, 2020 at 12:03 PM Lad, Prabhakar wrote: > On Fri, Oct 23, 2020 at 10:50 AM Geert Uytterhoeven > wrote: > > On Fri, Oct 23, 2020 at 9:56 AM Lad Prabhakar > > wrote: > > > Add optee device tree node to HiHope RZ/G2{HMN} boards. > > > > > > Signed-off-by: Lad Prabhakar > > > Reviewed-by: Biju Das > > > > Thanks for your patch! > > > > > --- a/arch/arm64/boot/dts/renesas/hihope-common.dtsi > > > +++ b/arch/arm64/boot/dts/renesas/hihope-common.dtsi > > > @@ -110,6 +110,13 @@ > > > #clock-cells = <0>; > > > clock-frequency = <25000000>; > > > }; > > > + > > > + firmware { > > > + optee { > > > + compatible = "linaro,optee-tz"; > > > + method = "smc"; > > > + }; > > > + }; > > > }; > > > > Should this be added to the SoC-specific .dtsi instead? > It's a bit tricky, the reason I put in board files is due to current > boards having optee do the same. Let me know if you want me to move > the nodes to SoC dtsi At least the Layerscape and K3 SoCs do have the optee node in the SoC-specific .dtsi... Given it needs a special TFA, it's probably safest to pass this through the firmware stack, cfr. the memory nodes? > > How can we test this? > This needs a special TFA (by special I mean optee enabled > (SPD="opteed")) and In Linux we need the below configs enabled: > > CONFIG_TEE=y > CONFIG_OPTEE=y > CONFIG_OPTEE_SHM_NUM_PRIV_PAGES=1 > > Once Linux is booted up this exposes a optee device which can be used > for communication. I have used optee_test [1] test-suite (xtest) to > make sure all the tests pass (I have attached results for RZ/G2H for > reference). > > [1] https://optee.readthedocs.io/en/latest/building/gits/optee_test.html Thanks, that is very valuable information! Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds