From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 44EC93DE449 for ; Thu, 23 Apr 2026 10:43:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=170.10.129.124 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1776941023; cv=none; b=pGuXqv1UJ2YB9gd+jaTSFbjP6dOzYuHGmzQp9xebsuUVKie4fa6rlTT1wjpyNuSKbOwuFTyPn+uHVhl1sMEjZbCOXSq/KzZTpiRjvzf5unGMiWNXasSuScHRci60RTgKcrZjixg0DI7GgKMJbyl6L/A1Q4bvVQm76yPRJcJac9I= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1776941023; c=relaxed/simple; bh=0MVBmj0UTxxc7uf2d9nD5AhPeN8g9BS4BwA1Dv9oSp0=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=fpm97o94LbLiyVn5/LRldL9pcpgprI+/nsJ8Gk/zQLNoyqjK2EbeGM8IYZCm32mtes5BTYZtAuLoBKD0m8H2P7A/Hkt16nLAFE9NUu+5tIB0yACdQcvDs0geTrvlc7bpGEGuH2KXW8lYH5gj469gTU3IyNNmZYCNVuM2YnlLun4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com; spf=pass smtp.mailfrom=redhat.com; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b=E4W1BcF1; dkim=pass (2048-bit key) header.d=redhat.com header.i=@redhat.com header.b=GVJH8JLQ; arc=none smtp.client-ip=170.10.129.124 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="E4W1BcF1"; dkim=pass (2048-bit key) header.d=redhat.com header.i=@redhat.com header.b="GVJH8JLQ" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1776941021; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=WuQW4pBXbKGvyJp/vS2sHGTY1we6BBTCK+8vKgNTI+s=; b=E4W1BcF1JrIRTcbWaSHxfhsPauaMMYgggzguaFoAh9cn6yIuDpXY6XbHAGtagfTjN+T7Cq xqzief7DiofAV+9pm1bgH/SfGJh5+J9ZfzuBcrjjotkP0FrutOy6MW2/hd2Xda1Ukp8yX+ +NC6XxlLdH+nTr0j94SMGCD2nrnE0Ds= Received: from mail-pj1-f69.google.com (mail-pj1-f69.google.com [209.85.216.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-531-1vezuX4_Nsungcy7YLNPfg-1; Thu, 23 Apr 2026 06:43:39 -0400 X-MC-Unique: 1vezuX4_Nsungcy7YLNPfg-1 X-Mimecast-MFC-AGG-ID: 1vezuX4_Nsungcy7YLNPfg_1776941019 Received: by mail-pj1-f69.google.com with SMTP id 98e67ed59e1d1-35d9278587bso7707120a91.2 for ; Thu, 23 Apr 2026 03:43:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=google; t=1776941019; x=1777545819; darn=vger.kernel.org; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:from:to :cc:subject:date:message-id:reply-to; bh=WuQW4pBXbKGvyJp/vS2sHGTY1we6BBTCK+8vKgNTI+s=; b=GVJH8JLQ8qIX0BqU8NS4l+awyBgDoTBGwSPrrFj8xlv/AV7qyqsKHTEum29Fx18ieU 0cv5oIWnUXdu1toA9KjnmMPA3NiFRojr8oaEYpinU2NRkg5BoZ2DeAkZGiBxTb56Dv7R RyhOCLz+SzpvoWRvgcr/+RVzoK4p5Nq0v7UQo65M+yOlLUlSp2Uj6fuNlKebIq7xQdeN HUjVQ3irl8rl28uEFvR/ybxt5Z9Jg2jenB308Yhsv8tuTl7O/Ug3NL0Yuchdyhq+t+bT /HEUVapR5Vj9SDWv/DKTc2pGCaep86Y/I6VnDjcoH5CCP15CXAOjNJZ4pejZBYhR3qkF 4PRw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1776941019; x=1777545819; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=WuQW4pBXbKGvyJp/vS2sHGTY1we6BBTCK+8vKgNTI+s=; b=LAeuO8OStdvxUVPyA7D3J3UWfjpUDo6N6/9iQX78Hde9+nDCHirKsVIlI1ynRfKW6m O4ai8LgC4ncbInWc2x9xZ1m+6cq+xSCObem5LgOcTe9ehmVlcWpfs+S7Jn8G+WuGBx3m a/iDU6VMaR1Z5SakqqW8Y6L3HeUh7PWHyh7P7Y5D5ldiy1WgF09lL9XqeDEsqbdeuygT sblW8YAlt4tVYxlSgLQKZhlOBxwudbEUDpUPFlwSIC0LUJKWsU9gewxjZ2tgatFkmgtq Vg6Cp9DySx5WDTfGIpYxaNs36wn25O/tj6U80wAMy223Q0YOZ2h+3z/ilc60aagvsOdW KZJQ== X-Gm-Message-State: AOJu0Yz5vNK9BW6ByZJjq231M5vRGwi2KWiJNz3+aAGh3GO7U5l+96Ws WUkyFsu23Q+4Rs6YLzNWDM7GTL5Ixm9g3tyC5Esm7VjPI/ctyJBC++9M2DoSu1z+/OsGfR526W6 iYP1M96MgB7H9oYCTkaWXzkKNgdn68bv5Pjf2q9p5EAMpeikSDSAM7D0RTvS7UbOJ8A== X-Gm-Gg: AeBDievir2ecYyUjchB7Ji6yAaPTKdvxExGu/Zl0J4qZhUcW43sIpR0kR5hdCOWRxx5 CWHjqTlz1u38D7Gbluh1FuR74k7QjnhXaUVn66KCMkTXTeaLFXwBmGFkVeQfQJlFSm8MlBh1zPV jMoWYcBhpWSxY8D3dz/dqp7E2sKBpq35gXnhK5g7G2rcYStLUo848h5N2JK/1nZIBYi2PFh2R2i 0g2hqRPFMpdIwbDQtx7VNuPWuRw4bcftmg3BrsJQM6iTXKaI05BRLVBgfqwBKxdBPlzhH8mHVz1 zwc0mbeIeqADjDruN7aH7CQglcW9kGUjyJ3x5xwfujIjlWhTCoGQZC25lARtihb2CeQ3AqcVlqD D7L08pwba9IjMMwCKYpV0NuM= X-Received: by 2002:a17:90b:2e45:b0:35b:e4f8:7cc7 with SMTP id 98e67ed59e1d1-36140473f8amr25177633a91.17.1776941018565; Thu, 23 Apr 2026 03:43:38 -0700 (PDT) X-Received: by 2002:a17:90b:2e45:b0:35b:e4f8:7cc7 with SMTP id 98e67ed59e1d1-36140473f8amr25177605a91.17.1776941018067; Thu, 23 Apr 2026 03:43:38 -0700 (PDT) Received: from fedora ([49.36.110.230]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-2b5faa34ea7sm191377915ad.34.2026.04.23.03.43.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Apr 2026 03:43:37 -0700 (PDT) Date: Thu, 23 Apr 2026 16:13:27 +0530 From: Arun Menon To: Jarkko Sakkinen , Stefan Berger Cc: linux-kernel@vger.kernel.org, linux-integrity@vger.kernel.org, Jason Gunthorpe , Peter Huewe Subject: Re: [RFC 0/4] tpm_crb: Add command and response buffer chunking support Message-ID: References: <20260324071803.324774-1-armenon@redhat.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: On Wed, Apr 08, 2026 at 11:34:54AM +0300, Jarkko Sakkinen wrote: > On Tue, Mar 24, 2026 at 06:11:11PM +0530, Arun Menon wrote: > > Hi Jarkko, > > > > On Tue, Mar 24, 2026 at 12:41:26PM +0200, Jarkko Sakkinen wrote: > > > On Tue, Mar 24, 2026 at 12:47:59PM +0530, Arun Menon wrote: > > > > The new version of TCG TPM v185 (currently under review [1]) supports > > > > sending data/commands in chunks for the CRB (Command Response Buffer) > > > > interface. This is in line with the initiative to support PQC algorithms. > > > > > > > > This series implements the logic to send and receive larger TPM > > > > cmd/rsp between the linux guest and the TPM backend in chunks. > > > > Currently, the TPM CRB driver is limited by the physical size of the > > > > MMIO window. When userspace attempts to send a payload that exceeds this > > > > size, the driver rejects it. > > > > > > > > This series introduces chunking support. The driver now checks the CRB > > > > interface capability for CRB_INTF_CAP_CRB_CHUNK. If supported by the > > > > backend, the driver will slice oversized commands into MMIO-sized > > > > chunks, signalling the backend via CRB_START_NEXT_CHUNK, and finalizing > > > > with CRB_START_INVOKE. Responses are also read back in a similar chunked > > > > manner. > > > > > > > > If the backend does not support chunking, the driver retains its legacy > > > > behaviour and enforces the standard size limits. > > > > > > > > This feature also requires the QEMU to interpret the data in chunks and > > > > forward it to the TPM backend and subsequently dispatch the TPM response > > > > in chunks back to the linux guest. This is implemented in [2] > > > > > > > > [1] https://trustedcomputinggroup.org/wp-content/uploads/PC-Client-Specific-Platform-TPM-Profile-for-TPM-2p0-v1p07_rc1_121225.pdf > > > > [2] https://lore.kernel.org/qemu-devel/20260319135316.37412-1-armenon@redhat.com/ > > > > > > > > Arun Menon (4): > > > > tpm_crb: Add definition of TPM CRB chunking fields > > > > tpm_crb: Add new wrapper function to invoke start method > > > > tpm_crb: Implement command and response chunking logic > > > > tpm: Increase TPM_BUFSIZE to 64kB for chunking support > > > > > > > > drivers/char/tpm/tpm.h | 2 +- > > > > drivers/char/tpm/tpm_crb.c | 194 ++++++++++++++++++++++++++----------- > > > > 2 files changed, 137 insertions(+), 59 deletions(-) > > > > > > > > -- > > > > 2.53.0 > > > > > > > > > > When QEMU has the feature available? > > > > The QEMU patches are in review at the moment, > > here is the link: https://lore.kernel.org/qemu-devel/20260319135316.37412-1-armenon@redhat.com/ > > Hoping to have them merged soon. > > Right, and additional question: what about swtpm? Hi Jarkko, Apologies for the delay in following up. Regarding your question about swtpm, I’ve looped in Stefan Berger who should be able to provide more technical context on that front. I also wanted to gently point you toward the latest revision of this series v2, as I’ve addressed some feedback since our last exchange. latest : https://lore.kernel.org/lkml/20260324181244.17741-1-armenon@redhat.com/ I’ve been working on the QEMU integration side in the meantime to ensure the end-to-end flow is solid. qemu link : https://lore.kernel.org/qemu-devel/20260422103018.123608-1-armenon@redhat.com/ I look forward to your feedback when time permits. > > For both, to give detailed review, good enough is their main branch > (i.e. as long as upstream accepts them I can use them). > > > > > > > > > BR, Jarkko > > > > > > > Regards, > > Arun Menon > > > > BR, Jarkko Regards, Arun Menon