lkml.org 
[lkml]   [2020]   [Apr]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2] mm: Add kvfree_sensitive() for freeing sensitive data objects
On Mon, Apr 06, 2020 at 02:58:27PM -0400, Waiman Long wrote:
> +/**
> + * kvfree_sensitive - free a data object containing sensitive information
> + * @addr - address of the data object to be freed
> + * @len - length of the data object

Did you try building this with W=1? I believe this is incorrect kerneldoc.
It should be @addr: and @len:

Also, it reads better in the htmldocs if you capitalise the first letter
of each sentence and finish with a full stop.

> @@ -914,7 +911,7 @@ long keyctl_read_key(key_serial_t keyid, char __user *buffer, size_t buflen)
> */
> if (ret > key_data_len) {
> if (unlikely(key_data))
> - __kvzfree(key_data, key_data_len);
> + kvfree_sensitive(key_data, key_data_len);

I'd drop the test of key_data here.

\
 
 \ /
  Last update: 2020-04-06 22:01    [W:0.204 / U:1.092 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site