From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga07.intel.com ([134.134.136.100]:46221 "EHLO mga07.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752804AbeF2LbO (ORCPT ); Fri, 29 Jun 2018 07:31:14 -0400 Date: Fri, 29 Jun 2018 14:31:07 +0300 From: Jarkko Sakkinen To: Ricardo Schwarzmeier Cc: linux-integrity@vger.kernel.org, linux-kernel@vger.kernel.org, peterhuewe@gmx.de, jgg@ziepe.ca, arnd@arndb.de, gregkh@linuxfoundation.org Subject: Re: [PATCH v5] tpm: Return the actual size when receiving an unsupported command Message-ID: <20180629113107.GA10894@linux.intel.com> References: <20180626153145.7408-1-Ricardo.Schwarzmeier@infineon.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii In-Reply-To: <20180626153145.7408-1-Ricardo.Schwarzmeier@infineon.com> Sender: linux-integrity-owner@vger.kernel.org List-ID: On Tue, Jun 26, 2018 at 05:31:45PM +0200, Ricardo Schwarzmeier wrote: > The userpace expects to read the number of bytes stated in the header. > Returning the size of the buffer instead would be unexpected. > Fixes: 095531f891e6 ("tpm: return a TPM_RC_COMMAND_CODE response if command is not implemented") > > Signed-off-by: Ricardo Schwarzmeier Reviewed-by: Jarkko Sakkinen /Jarkko