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=-4.5 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,HTTP_ESCAPED_HOST, MAILING_LIST_MULTI,MENTIONS_GIT_HOSTING,SPF_HELO_NONE,SPF_PASS 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 CE47EC04AB4 for ; Thu, 16 May 2019 07:06:19 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 93D7F20862 for ; Thu, 16 May 2019 07:06:19 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="VXisOUaR" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726604AbfEPHGT (ORCPT ); Thu, 16 May 2019 03:06:19 -0400 Received: from mail-vs1-f68.google.com ([209.85.217.68]:38280 "EHLO mail-vs1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726319AbfEPHGS (ORCPT ); Thu, 16 May 2019 03:06:18 -0400 Received: by mail-vs1-f68.google.com with SMTP id x184so602757vsb.5 for ; Thu, 16 May 2019 00:06:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=3tuyRdp1kiTY23EHvc9NEBL/dfI6XqAQnryU6YgN88k=; b=VXisOUaRMulel+iyFbX21Xi2jHYGI6moKFyX5kvQe7al8mpkl0q80RJl6c5kjnsh1h yWGuLg1y5NZPcm7p+Cw47rCHhC+0XjiL8ZxQniuJ0M8kQmjlD3hcn2PsQw+7K/Wr92xt Ym9VT+hZVUxX6HKFvEbHNWvSD5ZzczOTri+dD3Q/TaQAj+RpiCw/TJFip78oFa1mAnjw eY6fVaVTm8jK+vUgj6YSwGVV5STazrNbXYDN8soNzs9QjR+a4N/WdtBXU1Sll2PyYtuz qe0rorZxQjBQriGR++jFIqbXLslnfOZxl+HPeTqApkxq1TtXLr4ASaBy8bbTSaXK+evi p8Ew== 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=3tuyRdp1kiTY23EHvc9NEBL/dfI6XqAQnryU6YgN88k=; b=kgfVplwREWlw0SZoymOfLjLt1w6YWePp3TeGZNjFlgJ1INbURX+g90cdzr+9Pj2TOW 47EBgC3ceJyHYreIwatcnxyKQ1aq/8X97kNExGc1wXutv0D9kihCrVVcgP+uYSThoK9a Udn7sxUuMeQdli7JupGZVzJg6snYPm6ABlDYXc0AvUQeX8Fv9kVZWF2VuS7kz2cINOB/ Aaz/GRMdPNMLMMIFDyEHZljqNn7Bc11+ziKyynFxE3sEuKFuJI667deTJMxrXuNCnRyy ad7z72HSnuXokr9MoV/JOv2g7Bh2GBAUbI+v1qI6g/0pAY/XhnQFjCnvGMCJE9zXPIiW PPUQ== X-Gm-Message-State: APjAAAXVvU2lInjNugKJPFW9+FPrtaPtuyA0VRHXzTcRAuIpy7e2Sr3A Ppd3kzDFwbBMci+QZFyesYmRgkUz187OSGylU+Qn+w== X-Google-Smtp-Source: APXvYqyViiR+25Q5khqd7QCbhk03N20cWs1hjwkUwhl4DGOsX3b3Ue0RL6+ZKESk/A7zZpAsuR5BcBvLLt4soUS7uOA= X-Received: by 2002:a67:2781:: with SMTP id n123mr5270839vsn.141.1557990377174; Thu, 16 May 2019 00:06:17 -0700 (PDT) MIME-Version: 1.0 References: <20190415155636.32748-1-sashal@kernel.org> <20190507174020.GH1747@sasha-vm> <20190508124436.GE7642@linux.intel.com> <20190514193056.GN11972@sasha-vm> In-Reply-To: From: Sumit Garg Date: Thu, 16 May 2019 12:36:05 +0530 Message-ID: Subject: Re: [PATCH v3 0/2] ftpm: a firmware based TPM driver To: Thirupathaiah Annapureddy Cc: Sasha Levin , Jarkko Sakkinen , "peterhuewe@gmx.de" , "jgg@ziepe.ca" , "corbet@lwn.net" , Linux Kernel Mailing List , "linux-doc@vger.kernel.org" , "linux-integrity@vger.kernel.org" , Microsoft Linux Kernel List , "Bryan Kelly (CSI)" Content-Type: text/plain; charset="UTF-8" Sender: linux-integrity-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-integrity@vger.kernel.org On Thu, 16 May 2019 at 06:30, Thirupathaiah Annapureddy wrote: > > > > > -----Original Message----- > > From: Sumit Garg > > Sent: Tuesday, May 14, 2019 7:02 PM > > To: Sasha Levin > > Cc: Jarkko Sakkinen ; peterhuewe@gmx.de; > > jgg@ziepe.ca; corbet@lwn.net; Linux Kernel Mailing List > kernel@vger.kernel.org>; linux-doc@vger.kernel.org; linux- > > integrity@vger.kernel.org; Microsoft Linux Kernel List > kernel@microsoft.com>; Thirupathaiah Annapureddy ; > > Bryan Kelly (CSI) > > Subject: Re: [PATCH v3 0/2] ftpm: a firmware based TPM driver > > > > On Wed, 15 May 2019 at 01:00, Sasha Levin wrote: > > > > > > On Wed, May 08, 2019 at 03:44:36PM +0300, Jarkko Sakkinen wrote: > > > >On Tue, May 07, 2019 at 01:40:20PM -0400, Sasha Levin wrote: > > > >> On Mon, Apr 15, 2019 at 11:56:34AM -0400, Sasha Levin wrote: > > > >> > From: "Sasha Levin (Microsoft)" > > > >> > > > > >> > Changes since v2: > > > >> > > > > >> > - Drop the devicetree bindings patch (we don't add any new ones). > > > >> > - More code cleanups based on Jason Gunthorpe's review. > > > >> > > > > >> > Sasha Levin (2): > > > >> > ftpm: firmware TPM running in TEE > > > >> > ftpm: add documentation for ftpm driver > > > >> > > > >> Ping? Does anyone have any objections to this? > > > > > > > >Sorry I've been on vacation week before last week and last week > > > >I was extremely busy because I had been on vacation. This in > > > >my TODO list. Will look into it tomorrow in detail. > > > > > > > >Apologies for the delay with this! > > > > > > Hi Jarkko, > > > > > > If there aren't any big objections to this, can we get it merged in? > > > We'll be happy to address any comments that come up. > > > > I guess you have missed or ignored this comment [1]. Please address it. > > > > [1] > > https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Flkml.org% > > 2Flkml%2F2019%2F5%2F8%2F11&data=01%7C01%7Cthiruan%40microsoft.com%7Cf2a > > 80c7b94434329eaee08d6d8d962b1%7C72f988bf86f141af91ab2d7cd011db47%7C1&sd > > ata=hyJRc23NwEFLDuaIMkbSCGetd%2BObQWiAg%2BJtMMR6z9U%3D&reserved=0 > > > > -Sumit > > Thanks for reviewing and adding comments. > > We tried to use TEE bus framework you suggested for fTPM enumeration. > We were not able to pass the TCG Logs collected by the boot loaders. > > Currently there are 3 ways to pass TCG Logs based on the code > in drivers/char/tpm/eventlog: > > 1. ACPI Table > 2. EFI Table > 3. OF Device node properties > > Our ARM system is booting using U-boot and Device Tree. > So ACPI/EFI table mechanism to pass TCG2 logs won't be applicable. > We needed to use OF device node properties to pass TCG2 Logs. > TEE bus enumeration framework does not work for our use case due to the above. Firstly let me clarify that this framework is intended to communicate with TEE based services/devices rather than boot loader. And in this case fTPM being a TEE based service, so this framework should be used. > > Is it possible to add flexibility in TEE bus enumeration framework to support > platform specific properties through OF nodes or ACPI? > As you mentioned above, TCG logs are collected by boot loader. So it should find a way to pass them to Linux. How about if boot loader register these TCG logs with fTPM TA which could be fetched during fTPM driver probe or new api like tpm_read_log_tee()? This is something similar to what I used in optee-rng [1] driver to fetch RNG properties. [1] https://github.com/torvalds/linux/blob/master/drivers/char/hw_random/optee-rng.c#L176 -Sumit > > > > > > > > -- > > > Thanks, > > > Sasha