lkml.org 
[lkml]   [2018]   [Nov]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v3 01/16] tpm: use tpm_buf in tpm_transmit_cmd() as the IO parameter
On Mon, Nov 05, 2018 at 04:48:13PM -0500, Stefan Berger wrote:
> > int tpm_send(struct tpm_chip *chip, void *cmd, size_t buflen)
> > {
> > + struct tpm_buf buf;
> > int rc;
> >
> > chip = tpm_find_get_ops(chip);
> > if (!chip)
> > return -ENODEV;
> >
> > - rc = tpm_transmit_cmd(chip, NULL, cmd, buflen, 0, 0,
> > + rc = tpm_buf_init(&buf, 0, 0);
> > + if (rc)
> > + goto out;
> > +
> > + memcpy(buf.data, cmd, buflen);
>
>
> Nit: buflen -> cmd_len

Agreed that it should but I try to keep the patch as minimal and
mechanical as I can.

Thank you.

/Jarkko

\
 
 \ /
  Last update: 2018-11-06 06:54    [W:0.047 / U:1.380 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site