lkml.org 
[lkml]   [2018]   [Oct]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v13 04/12] livepatch: Consolidate klp_free functions
On Wed 2018-10-17 13:22:54, Josh Poimboeuf wrote:
> On Mon, Oct 15, 2018 at 02:37:05PM +0200, Petr Mladek wrote:
> > @@ -637,6 +647,7 @@ static int klp_init_patch(struct klp_patch *patch)
> > mutex_lock(&klp_mutex);
> >
> > patch->enabled = false;
> > + INIT_LIST_HEAD(&patch->list);
>
> Is this a bug fix? If so, it should go in a separate patch. I'm
> wondering how this worked before.

It is not a bug fix. It was not needed before because
klp_register_patch() did not checked this field when failed.

But this patch started to use the generic
klp_free_patch_start()/klp_free_patch_finish() in both
klp_unregister_patch() and in klp_init_patch() error patch.
Therefore we need to have a valid value from the beginning.

Best Regards,
Petr

\
 
 \ /
  Last update: 2018-10-18 13:41    [W:0.051 / U:3.644 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site