[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAPhsuW6+6S5qBGEvFfVh7M-_-FntL=Rk=OqZzvQjpZ6MyDhNuA@mail.gmail.com>
Date: Tue, 3 Sep 2024 22:26:02 -0700
From: Song Liu <song@...nel.org>
To: Josh Poimboeuf <jpoimboe@...nel.org>
Cc: live-patching@...r.kernel.org, linux-kernel@...r.kernel.org,
x86@...nel.org, Miroslav Benes <mbenes@...e.cz>, Petr Mladek <pmladek@...e.com>,
Joe Lawrence <joe.lawrence@...hat.com>, Jiri Kosina <jikos@...nel.org>,
Peter Zijlstra <peterz@...radead.org>, Marcos Paulo de Souza <mpdesouza@...e.com>
Subject: Re: [RFC 00/31] objtool, livepatch: Livepatch module generation
Hi Josh,
I have attached the config I used for LLVM and gcc.
Thanks,
Song
On Tue, Sep 3, 2024 at 9:30 PM Josh Poimboeuf <jpoimboe@...nel.org> wrote:
>
> On Tue, Sep 03, 2024 at 10:32:00AM -0700, Song Liu wrote:
> > Hi Josh,
> >
> > Thanks for the patchset! We really need this work so that we can undo our
> > hack for LTO enabled kernels.
> >
> > On Mon, Sep 2, 2024 at 9:00 PM Josh Poimboeuf <jpoimboe@...nel.org> wrote:
> > >
> > > Hi,
> > >
> > > Here's a new way to build livepatch modules called klp-build.
> > >
> > > I started working on it when I realized that objtool already does 99% of
> > > the work needed for detecting function changes.
> > >
> > > This is similar in concept to kpatch-build, but the implementation is
> > > much cleaner.
> > >
> > > Personally I still have reservations about the "source-based" approach
> > > (klp-convert and friends), including the fragility and performance
> > > concerns of -flive-patching. I would submit that klp-build might be
> > > considered the "official" way to make livepatch modules.
> > >
> > > Please try it out and let me know what you think. Based on v6.10.
> > >
> > > Also avaiable at:
> > >
> > > git://git.kernel.org/pub/scm/linux/kernel/git/jpoimboe/linux.git klp-build-rfc
> >
> > I tried to compile the code in this branch with gcc-12 and llvm-18. Some
> > of these errors are easy to fix (attached below). But some are trickier, for
> > example:
> >
> > with gcc-12:
> > ...
> > BTFIDS vmlinux
> > NM System.map
> > SORTTAB vmlinux
> > incomplete ORC unwind tables in file: vmlinux
> > Failed to sort kernel tables
>
> Thanks for trying it! If you share your config(s) I can look into it.
>
> I haven't tried clang yet, but will soon.
>
> --
> Josh
Download attachment "gcc.config" of type "application/octet-stream" (118017 bytes)
Download attachment "llvm.config" of type "application/octet-stream" (118131 bytes)
Powered by blists - more mailing lists