<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/scripts/livepatch/init.c, branch v6.19.11</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v6.19.11</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v6.19.11'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2026-02-05T16:00:45+00:00</updated>
<entry>
<title>livepatch: Free klp_{object,func}_ext data after initialization</title>
<updated>2026-02-05T16:00:45+00:00</updated>
<author>
<name>Petr Pavlu</name>
<email>petr.pavlu@suse.com</email>
</author>
<published>2026-01-23T10:26:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=b525fcaf0a76507f152d58c6f9e5ef67b3ff552c'/>
<id>urn:sha1:b525fcaf0a76507f152d58c6f9e5ef67b3ff552c</id>
<content type='text'>
The klp_object_ext and klp_func_ext data, which are stored in the
__klp_objects and __klp_funcs sections, respectively, are not needed
after they are used to create the actual klp_object and klp_func
instances. This operation is implemented by the init function in
scripts/livepatch/init.c.

Prefix the two sections with ".init" so they are freed after the module
is initializated.

Signed-off-by: Petr Pavlu &lt;petr.pavlu@suse.com&gt;
Acked-by: Joe Lawrence &lt;joe.lawrence@redhat.com&gt;
Acked-by: Miroslav Benes &lt;mbenes@suse.cz&gt;
Reviewed-by: Aaron Tomlin &lt;atomlin@atomlin.com&gt;
Link: https://patch.msgid.link/20260123102825.3521961-3-petr.pavlu@suse.com
Signed-off-by: Josh Poimboeuf &lt;jpoimboe@kernel.org&gt;
</content>
</entry>
<entry>
<title>livepatch: Fix having __klp_objects relics in non-livepatch modules</title>
<updated>2026-02-05T16:00:44+00:00</updated>
<author>
<name>Petr Pavlu</name>
<email>petr.pavlu@suse.com</email>
</author>
<published>2026-01-23T10:26:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=ab10815472fcbc2c772dc21a979460b7f74f0145'/>
<id>urn:sha1:ab10815472fcbc2c772dc21a979460b7f74f0145</id>
<content type='text'>
The linker script scripts/module.lds.S specifies that all input
__klp_objects sections should be consolidated into an output section of
the same name, and start/stop symbols should be created to enable
scripts/livepatch/init.c to locate this data.

This start/stop pattern is not ideal for modules because the symbols are
created even if no __klp_objects input sections are present.
Consequently, a dummy __klp_objects section also appears in the
resulting module. This unnecessarily pollutes non-livepatch modules.

Instead, since modules are relocatable files, the usual method for
locating consolidated data in a module is to read its section table.
This approach avoids the aforementioned problem.

The klp_modinfo already stores a copy of the entire section table with
the final addresses. Introduce a helper function that
scripts/livepatch/init.c can call to obtain the location of the
__klp_objects section from this data.

Fixes: dd590d4d57eb ("objtool/klp: Introduce klp diff subcommand for diffing object files")
Signed-off-by: Petr Pavlu &lt;petr.pavlu@suse.com&gt;
Acked-by: Joe Lawrence &lt;joe.lawrence@redhat.com&gt;
Acked-by: Miroslav Benes &lt;mbenes@suse.cz&gt;
Reviewed-by: Aaron Tomlin &lt;atomlin@atomlin.com&gt;
Link: https://patch.msgid.link/20260123102825.3521961-2-petr.pavlu@suse.com
Signed-off-by: Josh Poimboeuf &lt;jpoimboe@kernel.org&gt;
</content>
</entry>
<entry>
<title>livepatch/klp-build: Add stub init code for livepatch modules</title>
<updated>2025-10-14T21:50:19+00:00</updated>
<author>
<name>Josh Poimboeuf</name>
<email>jpoimboe@kernel.org</email>
</author>
<published>2025-09-17T16:04:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=59adee07b568fb78e2bf07df1f22f3fe45b7240a'/>
<id>urn:sha1:59adee07b568fb78e2bf07df1f22f3fe45b7240a</id>
<content type='text'>
Add a module initialization stub which can be linked with binary diff
objects to produce a livepatch module.

Acked-by: Petr Mladek &lt;pmladek@suse.com&gt;
Tested-by: Joe Lawrence &lt;joe.lawrence@redhat.com&gt;
Signed-off-by: Josh Poimboeuf &lt;jpoimboe@kernel.org&gt;
</content>
</entry>
</feed>
