[PATCH 0/5] xen/livepatch: fixes for the pre-apply / post-revert hooks

Roger Pau Monne posted 5 patches 4 months, 4 weeks ago
Patches applied successfully (tree, apply log)
git fetch https://gitlab.com/xen-project/patchew/xen tags/patchew/20231130142944.46322-1-roger.pau@citrix.com
There is a newer version of this series
xen/common/livepatch.c                        | 95 +++++++++++--------
xen/common/virtual_region.c                   | 40 +++-----
xen/include/xen/livepatch.h                   | 32 +------
xen/test/livepatch/Makefile                   |  4 +-
.../livepatch/xen_action_hooks_norevert.c     | 24 ++---
5 files changed, 81 insertions(+), 114 deletions(-)
[PATCH 0/5] xen/livepatch: fixes for the pre-apply / post-revert hooks
Posted by Roger Pau Monne 4 months, 4 weeks ago
Hello,

The follow series contain a misc of fixes mostly related to the usage of
the pre-apply / post-revert hooks.  The norevert test is also fixed to
work as I think was expected.  Finally both the no{apply,revert}
tests are fixed to build properly, as the files where previously
unhooked from the build system completely.

I'm unsure how useful the apply and revert hooks really are, as without
calling the internal apply/revert functions the state of the payload
structure is quite likely inconsistent with the code expectations.

Thanks, Roger.

Roger Pau Monne (5):
  xen/livepatch: register livepatch regions when loaded
  xen/livepatch: search for symbols in all loaded payloads
  xen/livepatch: fix norevert test attempt to open-code revert
  xen/livepatch: fix norevert test hook setup typo
  xen/livepatch: properly build the noapply and norevert tests

 xen/common/livepatch.c                        | 95 +++++++++++--------
 xen/common/virtual_region.c                   | 40 +++-----
 xen/include/xen/livepatch.h                   | 32 +------
 xen/test/livepatch/Makefile                   |  4 +-
 .../livepatch/xen_action_hooks_norevert.c     | 24 ++---
 5 files changed, 81 insertions(+), 114 deletions(-)

-- 
2.43.0
Re: [PATCH 0/5] xen/livepatch: fixes for the pre-apply / post-revert hooks
Posted by Jan Beulich 2 months ago
On 30.11.2023 15:29, Roger Pau Monne wrote:
> Hello,
> 
> The follow series contain a misc of fixes mostly related to the usage of
> the pre-apply / post-revert hooks.  The norevert test is also fixed to
> work as I think was expected.  Finally both the no{apply,revert}
> tests are fixed to build properly, as the files where previously
> unhooked from the build system completely.
> 
> I'm unsure how useful the apply and revert hooks really are, as without
> calling the internal apply/revert functions the state of the payload
> structure is quite likely inconsistent with the code expectations.
> 
> Thanks, Roger.
> 
> Roger Pau Monne (5):
>   xen/livepatch: register livepatch regions when loaded
>   xen/livepatch: search for symbols in all loaded payloads
>   xen/livepatch: fix norevert test attempt to open-code revert
>   xen/livepatch: fix norevert test hook setup typo
>   xen/livepatch: properly build the noapply and norevert tests

With the R-b-s that have arrived, could you clarify in how far these
can be committed out of order?

Jan
Re: [PATCH 0/5] xen/livepatch: fixes for the pre-apply / post-revert hooks
Posted by Roger Pau Monné 2 months ago
On Fri, Feb 23, 2024 at 11:48:10AM +0100, Jan Beulich wrote:
> On 30.11.2023 15:29, Roger Pau Monne wrote:
> > Hello,
> > 
> > The follow series contain a misc of fixes mostly related to the usage of
> > the pre-apply / post-revert hooks.  The norevert test is also fixed to
> > work as I think was expected.  Finally both the no{apply,revert}
> > tests are fixed to build properly, as the files where previously
> > unhooked from the build system completely.
> > 
> > I'm unsure how useful the apply and revert hooks really are, as without
> > calling the internal apply/revert functions the state of the payload
> > structure is quite likely inconsistent with the code expectations.
> > 
> > Thanks, Roger.
> > 
> > Roger Pau Monne (5):
> >   xen/livepatch: register livepatch regions when loaded
> >   xen/livepatch: search for symbols in all loaded payloads
> >   xen/livepatch: fix norevert test attempt to open-code revert
> >   xen/livepatch: fix norevert test hook setup typo
> >   xen/livepatch: properly build the noapply and norevert tests
> 
> With the R-b-s that have arrived, could you clarify in how far these
> can be committed out of order?

All can be applied out of order, except for the last one, that's
"xen/livepatch: properly build the noapply and norevert tests" as
applying that will enable the tests in osstest, and those will fail
without all the previous adjustments.

I was about to send v2 with the requested changes, but will wait for
you to commit 2/5 and 4/5.

Thanks, Roger.
Re: [PATCH 0/5] xen/livepatch: fixes for the pre-apply / post-revert hooks
Posted by Jan Beulich 2 months ago
On 26.02.2024 09:40, Roger Pau Monné wrote:
> On Fri, Feb 23, 2024 at 11:48:10AM +0100, Jan Beulich wrote:
>> On 30.11.2023 15:29, Roger Pau Monne wrote:
>>> Hello,
>>>
>>> The follow series contain a misc of fixes mostly related to the usage of
>>> the pre-apply / post-revert hooks.  The norevert test is also fixed to
>>> work as I think was expected.  Finally both the no{apply,revert}
>>> tests are fixed to build properly, as the files where previously
>>> unhooked from the build system completely.
>>>
>>> I'm unsure how useful the apply and revert hooks really are, as without
>>> calling the internal apply/revert functions the state of the payload
>>> structure is quite likely inconsistent with the code expectations.
>>>
>>> Thanks, Roger.
>>>
>>> Roger Pau Monne (5):
>>>   xen/livepatch: register livepatch regions when loaded
>>>   xen/livepatch: search for symbols in all loaded payloads
>>>   xen/livepatch: fix norevert test attempt to open-code revert
>>>   xen/livepatch: fix norevert test hook setup typo
>>>   xen/livepatch: properly build the noapply and norevert tests
>>
>> With the R-b-s that have arrived, could you clarify in how far these
>> can be committed out of order?
> 
> All can be applied out of order, except for the last one, that's
> "xen/livepatch: properly build the noapply and norevert tests" as
> applying that will enable the tests in osstest, and those will fail
> without all the previous adjustments.
> 
> I was about to send v2 with the requested changes, but will wait for
> you to commit 2/5 and 4/5.

Except that patch 2 had 3 failing hunks, and not just fuzz in any of them.
Which was too much for me to consider fixing up while committing.

Jan