Re: [PATCH v14 07/11] livepatch: Add atomic replace

2019-01-03 Thread Josh Poimboeuf
On Thu, Jan 03, 2019 at 01:47:40PM +0100, Petr Mladek wrote: > On Mon 2018-12-17 16:27:41, Petr Mladek wrote: > > On Thu 2018-12-13 16:55:28, Josh Poimboeuf wrote: > > > On Thu, Nov 29, 2018 at 10:44:27AM +0100, Petr Mladek wrote: > > > Side note, it would probably be useful to have a

Re: [PATCH v14 07/11] livepatch: Add atomic replace

2019-01-03 Thread Petr Mladek
On Mon 2018-12-17 16:27:41, Petr Mladek wrote: > On Thu 2018-12-13 16:55:28, Josh Poimboeuf wrote: > > On Thu, Nov 29, 2018 at 10:44:27AM +0100, Petr Mladek wrote: > > Side note, it would probably be useful to have a klp_for_each_patch() > > helper. > > Will do. Hmm, there are two possibilities:

Re: [PATCH v14 07/11] livepatch: Add atomic replace

2018-12-17 Thread Petr Mladek
On Thu 2018-12-13 16:55:28, Josh Poimboeuf wrote: > On Thu, Nov 29, 2018 at 10:44:27AM +0100, Petr Mladek wrote: > > @@ -415,6 +449,124 @@ static struct attribute *klp_patch_attrs[] = { > > NULL > > }; > > > > +/* > > + * Dynamically allocated objects and functions. > > + */ > > I don't

Re: [PATCH v14 07/11] livepatch: Add atomic replace

2018-12-13 Thread Josh Poimboeuf
On Thu, Nov 29, 2018 at 10:44:27AM +0100, Petr Mladek wrote: > @@ -146,6 +150,7 @@ struct klp_object { > * struct klp_patch - patch structure for live patching > * @mod: reference to the live patch module > * @objs:object entries for kernel objects to be patched > + * @replace:

Re: [PATCH v14 07/11] livepatch: Add atomic replace

2018-12-05 Thread Joe Lawrence
On Thu, Nov 29, 2018 at 10:44:27AM +0100, Petr Mladek wrote: > From: Jason Baron > > Sometimes we would like to revert a particular fix. Currently, this > is not easy because we want to keep all other fixes active and we > could revert only the last applied patch. > > One solution would be to

Re: [PATCH v14 07/11] livepatch: Add atomic replace

2018-12-05 Thread Joe Lawrence
On Thu, Nov 29, 2018 at 10:44:27AM +0100, Petr Mladek wrote: > From: Jason Baron > > Sometimes we would like to revert a particular fix. Currently, this > is not easy because we want to keep all other fixes active and we > could revert only the last applied patch. > > One solution would be to

Re: [PATCH v14 07/11] livepatch: Add atomic replace

2018-12-04 Thread Miroslav Benes
> -5.3. Disabling > +5.3. Replacing > +-- > + > +All enabled patches might get replaced by a cumulative patch that > +has the .replace flag set. > + > +Once the new patch is enabled and the 'transition" finishes then > +all the functions (struct klp_func) associated with the replaced

Re: [PATCH v14 07/11] livepatch: Add atomic replace

2018-12-04 Thread Miroslav Benes
> -5.3. Disabling > +5.3. Replacing > +-- > + > +All enabled patches might get replaced by a cumulative patch that > +has the .replace flag set. > + > +Once the new patch is enabled and the 'transition" finishes then > +all the functions (struct klp_func) associated with the replaced

[PATCH v14 07/11] livepatch: Add atomic replace

2018-11-29 Thread Petr Mladek
From: Jason Baron Sometimes we would like to revert a particular fix. Currently, this is not easy because we want to keep all other fixes active and we could revert only the last applied patch. One solution would be to apply new patch that implemented all the reverted functions like in the

[PATCH v14 07/11] livepatch: Add atomic replace

2018-11-29 Thread Petr Mladek
From: Jason Baron Sometimes we would like to revert a particular fix. Currently, this is not easy because we want to keep all other fixes active and we could revert only the last applied patch. One solution would be to apply new patch that implemented all the reverted functions like in the