Re: [PATCH v1.4 4/5] keys: add new trusted key-type

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: David Howells
Date: Friday, November 19, 2010 - 9:23 am

Mimi Zohar <zohar@linux.vnet.ibm.com> wrote:


I'd quote 'keyctl print' just so it's obvious where the command ends and the
descriptive text starts.


I recommend adding some example commands with all the arguments substituted.
Nothing helps get to grip with an API like knowing what a command is supposed
to look like when it's actually used.


There are still a lot of places in here where you should probably be using
const and size_t.


Using kzalloc() rather than kmalloc() is a waste of time, I'd've thought.
It's a temporary buffer.  Does it really need to be precleared?


Merge.


That's what [] is for.


kfree() can handle a NULL pointer.


Should there be a check for pcrlock() failure?


Values defined for TPM hardware access really ought to be in a separate file
in include/linux/.  They aren't strictly specific to the trusted key
implementation here; that may be the only user currently in the kernel, but
that doesn't mean there can't be another user.

David
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH v1.4 0/5] keys: trusted and encrypted keys, Mimi Zohar, (Thu Nov 18, 3:42 pm)
Re: [PATCH v1.4 2/5] tpm: add module_put wrapper, David Howells, (Fri Nov 19, 8:43 am)
Re: [PATCH v1.4 3/5] key: add tpm_send command, David Howells, (Fri Nov 19, 8:45 am)
Re: [PATCH v1.4 3/5] key: add tpm_send command, David Safford, (Fri Nov 19, 9:04 am)
Re: [PATCH v1.4 4/5] keys: add new trusted key-type, David Howells, (Fri Nov 19, 9:23 am)
Re: [PATCH v1.4 5/5] keys: add new key-type encrypted, David Howells, (Fri Nov 19, 9:43 am)
Re: [PATCH v1.4 3/5] key: add tpm_send command, David Howells, (Fri Nov 19, 9:45 am)
Re: [PATCH v1.4 4/5] keys: add new trusted key-type, David Safford, (Fri Nov 19, 11:00 am)