Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp2333027ybe; Tue, 3 Sep 2019 11:16:17 -0700 (PDT) X-Google-Smtp-Source: APXvYqyXKGY2qIzusr/dz7CbttB0zJEO1VT5L3Rjxf3uU1BRPHdssp9kQ6mTtbUp8FhwN0psrWBx X-Received: by 2002:a17:902:e407:: with SMTP id ci7mr37240013plb.326.1567534577166; Tue, 03 Sep 2019 11:16:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1567534577; cv=none; d=google.com; s=arc-20160816; b=X/UKgeimcvAeZKDV01c4HZi9q8QfrMPSW8UDdH4UuCwY3jGhDI1nMx47pEFbzAaTCC 9EgWmOiIjQzasnrEX32as8zSM5ybn5LMOnan1N/V8RVoVhe5HI5ThCTxMAJXHKzESQbY 1pM9xUT1abm9d1Ro+VDDQjOLnj/jP6msw4eruWgxOkPVN4j1K+XOh+NFDxdMkU8uBMae c3F5t3Q+L1ZqeyLqJqwIlYk8WTva5dB3tNqgDnxzRFaUhmSaPJD+uNN48URHBYj+f7cp BcnfzQr2DFLZGKftm6AvV6IYWMMUKyEMGyiHVcH0hIDN7R+klC/EQFXezGzOEsTGGeQ9 yFTg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=fXkAkHucmqjgRur+IjQhyi5kKT37YWuWTzD3VpWtsg0=; b=c4cU+MxDef4GlvB2Rud7asaqRWT9TjDAIcRj4zNmed4Nl2bsMSq2yoF7khOBzdQtAL rDmh16mDOiFoWu8BHg3MLacleYnKjq0YVWwZIcGdNb0X2x7g9AkMGOjSkZNYas4Ial3D NAe8We/u5c5ap2kUrQ3cF1+Zo/GO9/0vx+spryqbkozigzeLi090tLdMDjTKTVR1eZ28 rY2vuoojL5MjQCqXCBEK6E+W60yXhi455TvFy/Qq3y4jBVtYs61S8jAp6JHM4WZPXOFG /U8zxzGlKcik0xOdgqqz2ufRwHUbMFzAQN0ELYbhnx/PL3DM9rLsqAEf3nRvk4k+CZYx hOnQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=ntv7CEao; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u14si7084732pgi.431.2019.09.03.11.16.01; Tue, 03 Sep 2019 11:16:17 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=ntv7CEao; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729919AbfICSPE (ORCPT + 99 others); Tue, 3 Sep 2019 14:15:04 -0400 Received: from mail-yw1-f66.google.com ([209.85.161.66]:32948 "EHLO mail-yw1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727352AbfICSPD (ORCPT ); Tue, 3 Sep 2019 14:15:03 -0400 Received: by mail-yw1-f66.google.com with SMTP id e65so6154176ywh.0; Tue, 03 Sep 2019 11:15:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=fXkAkHucmqjgRur+IjQhyi5kKT37YWuWTzD3VpWtsg0=; b=ntv7CEaollKFU9wsGZi+urn8zpOjY8CZrCGX9uanU9rEkUUwtoG2BQKLAK4j1JP31E mdAOGt7iwUcrZFg0chBC92R/1SxbUnu3D5LM/lSWidgtI3+jzUkg7qUbKq9A1FYQsL87 jolqCgEbdAjycGAxGkfudyhK36bxCTFhbAaTL/y1zJSRQWu2gJ82rLSCp6OFDDovL62y mmopsdkjOUsLZqJ4BRQpHvitszF5ZpPn9a5Ir/XLS6LpB+nCi3iMo3rthv/EkBgG8zLW 0TrqloJ1w2W/HGRBbXst7/kckF8TRQmcHaqxhUtGGsIKfK0iy9YRoMT99XNzZYi159Kp MVJw== 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=fXkAkHucmqjgRur+IjQhyi5kKT37YWuWTzD3VpWtsg0=; b=QiwMPgxkx56aWfvgSpvWmBjTor/0kNHzXKGKtEVuK2cVSN4K44VoiUWUEl435kuQkQ 9/j695MjjQZ9u4RnaHCsLV5w6HuLVt2Z6pPs2egj5RhVaJR3uNC7ucTonwOMNSRL/1BR YteX5G3snVrhpfkV8VgX2YdxpuW+olgv61PLumqcDfmo+tPq4mlywFBu4wILeyMrXEQs 0bzatt6aagwmSql1TMeAY/NJGUM+MBwLd25b25YhmTdo5jcLT0BYWupjot8ndkJyczi3 urrGO3PgaaWS8ygzHx+5gh7WthRBmhFUfwLmqQWB5uq0k3okWsVWpW6p5UYJw0a6vYSL iRhA== X-Gm-Message-State: APjAAAUSsqKPIPELuv2FnlyiayW2Jazo8plWTfkKQpVRbWXVa5s8hbL0 bQCLEX6saL7nInd9M5bfps/qP7nQ4pkIpdLPMaE= X-Received: by 2002:a0d:df13:: with SMTP id i19mr26242555ywe.264.1567534502345; Tue, 03 Sep 2019 11:15:02 -0700 (PDT) MIME-Version: 1.0 References: <20190830095639.4562-1-kkamagui@gmail.com> <20190830095639.4562-3-kkamagui@gmail.com> <20190830124334.GA10004@ziepe.ca> In-Reply-To: From: Seunghun Han Date: Wed, 4 Sep 2019 03:14:48 +0900 Message-ID: Subject: Re: [PATCH 2/2] tpm: tpm_crb: enhance resource mapping mechanism for supporting AMD's fTPM To: "Safford, David (GE Global Research, US)" Cc: Jason Gunthorpe , Jarkko Sakkinen , Peter Huewe , Matthew Garrett , Matthew Garrett , "open list:TPM DEVICE DRIVER" , Linux Kernel Mailing List Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > I tried your patch out on my systems with a "reserved" but not "NVS" > region conflict, and you are correct - the region is not busy, and > the driver is able to map the buffers with your patch. > > > First of all, I misunderstood your message. > > I have to tell you about the buffer size exactly. The command and response > > buffer sizes in ACPI table were 0x1000 and this was 4K, not 1K. The sizes in > > the control register were 0x4000 and this was 16K (large buffer size), not 4K. > > I have been using the TPM for my research and the typical cases like creating > > public/private keys, encrypting/decrypting data, sealing/unsealing a secrete, > > and getting random numbers are not over 4K buffer. So, as you know, I think > > the 4K buffer can handle the most cases and the current implementation of > > crb_fixup_cmd_size() works well. If you concern the specific case that uses > > over 4K buffer, please let me know. > > I have read postings of some systems where ACPI says 1K, but in all of my cases > that I can test, you are correct that ACPI is saying 4K instead of the device's 16K. > I tried really hard, but couldn't send any valid requests over 4K, (I believe that's > actually the max by the spec), and therefore never saw any failures on my > systems. I think the driver behavior is wrong for those other cases, but perhaps > this should wait until someone can get access and do the testing. > > So I'm happy with your patches, other than what is decided for the nvs driver > conflict. I'm testing them on some production systems, and have seen no other > issues. > > dave Thank you for your help and testing. I would like to make patch v2 to change the point that kbuild robot told me. If you don't mind, may I add "tested-by" tag to patch v2 with your name and email address? Seunghun