]> xenbits.xensource.com Git - xen.git/commit
xen/livepatch: simplify and unify logic in prepare_payload()
authorRoger Pau Monné <roger.pau@citrix.com>
Thu, 26 Sep 2024 10:14:28 +0000 (12:14 +0200)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Thu, 26 Sep 2024 13:18:03 +0000 (14:18 +0100)
commit86d09d16dd74298b19a03df492d9503f20cfc17c
treeb53a1da86961a9db78b4f4a5d42ee9d5fbbfdc04
parent8c81423038f17f6cbc853dd35d69d50a4458f764
xen/livepatch: simplify and unify logic in prepare_payload()

The following sections: .note.gnu.build-id, .livepatch.xen_depends and
.livepatch.depends are mandatory and ensured to be present by
check_special_sections() before prepare_payload() is called.

Simplify the logic in prepare_payload() by introducing a generic function to
parse the sections that contain a buildid.  Note the function assumes the
buildid related section to always be present.

No functional change intended.

Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
xen/common/livepatch.c