From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933510AbcKDE0G (ORCPT ); Fri, 4 Nov 2016 00:26:06 -0400 Received: from mga03.intel.com ([134.134.136.65]:59518 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933067AbcKDE0F (ORCPT ); Fri, 4 Nov 2016 00:26:05 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.31,442,1473145200"; d="scan'208";a="27381703" Date: Thu, 3 Nov 2016 22:25:59 -0600 From: Jarkko Sakkinen To: Tomas Winkler Cc: tpmdd-devel@lists.sourceforge.net, Jason Gunthorpe , linux-kernel@vger.kernel.org Subject: Re: [PATCH 2/2] tpm/tpm2-chip: fix kdoc errors Message-ID: <20161104042559.b2pp3sn4xdy7yvuc@intel.com> References: <1477962314-26763-1-git-send-email-tomas.winkler@intel.com> <1477962314-26763-3-git-send-email-tomas.winkler@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1477962314-26763-3-git-send-email-tomas.winkler@intel.com> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo User-Agent: Mutt/1.6.2-neo (2016-08-21) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Nov 01, 2016 at 03:05:14AM +0200, Tomas Winkler wrote: > Use correct kdoc format, describe correct parameters and return values. > > Signed-off-by: Tomas Winkler > --- > drivers/char/tpm/tpm2-cmd.c | 107 +++++++++++++++++++++++++++----------------- > 1 file changed, 66 insertions(+), 41 deletions(-) > > diff --git a/drivers/char/tpm/tpm2-cmd.c b/drivers/char/tpm/tpm2-cmd.c > index 7df55d58c939..a7a519c87bee 100644 > --- a/drivers/char/tpm/tpm2-cmd.c > +++ b/drivers/char/tpm/tpm2-cmd.c > @@ -258,11 +258,13 @@ static const struct tpm_input_header tpm2_pcrread_header = { > * tpm2_pcr_read() - read a PCR value > * @chip: TPM chip to use. > * @pcr_idx: index of the PCR to read. > - * @ref_buf: buffer to store the resulting hash, > + * @res_buf: buffer to store the resulting hash, > * > - * 0 is returned when the operation is successful. If a negative number is > - * returned it remarks a POSIX error code. If a positive number is returned > - * it remarks a TPM error. > + * > + * Return: > + * 0 when the operation is successful > + * A negative number for system errors (errno) > + * A positive number for a TPM error. > */ > int tpm2_pcr_read(struct tpm_chip *chip, int pcr_idx, u8 *res_buf) > { > @@ -304,13 +306,15 @@ static const struct tpm_input_header tpm2_pcrextend_header = { > > /** > * tpm2_pcr_extend() - extend a PCR value > + * > * @chip: TPM chip to use. > * @pcr_idx: index of the PCR. > * @hash: hash value to use for the extend operation. > * > - * 0 is returned when the operation is successful. If a negative number is > - * returned it remarks a POSIX error code. If a positive number is returned > - * it remarks a TPM error. > + * Return: > + * 0 when the operation is successful > + * A negative number for system errors (errno) > + * A positive number for a TPM error. Put this to tpm_transmit_cmd only and refer to that from other functions with "same as with tpm_transmit_cmd()" with parenthesis because that marks in rst a link to that function. /Jarkko