lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAKwvOdnc8au10g8q8miab89j3tT8UhwnZOMAJdRgkXVrnkhwqQ@mail.gmail.com>
Date:   Tue, 15 Sep 2020 13:12:24 -0700
From:   Nick Desaulniers <ndesaulniers@...gle.com>
To:     Josh Poimboeuf <jpoimboe@...hat.com>
Cc:     Borislav Petkov <bp@...en8.de>, Rong Chen <rong.a.chen@...el.com>,
        kernel test robot <lkp@...el.com>,
        "Li, Philip" <philip.li@...el.com>, x86-ml <x86@...nel.org>,
        LKML <linux-kernel@...r.kernel.org>,
        clang-built-linux <clang-built-linux@...glegroups.com>,
        Marco Elver <elver@...gle.com>
Subject: Re: [tip:x86/seves] BUILD SUCCESS WITH WARNING e6eb15c9ba3165698488ae5c34920eea20eaa38e

On Tue, Sep 15, 2020 at 10:02 AM Josh Poimboeuf <jpoimboe@...hat.com> wrote:
>
> On Tue, Sep 15, 2020 at 06:05:54PM +0200, Borislav Petkov wrote:
> > On Tue, Sep 15, 2020 at 10:18:16PM +0800, Rong Chen wrote:
> > > On Tue, Sep 15, 2020 at 03:55:19PM +0200, Borislav Petkov wrote:
> > > > On Tue, Sep 15, 2020 at 09:42:56PM +0800, kernel test robot wrote:
> > > > > tree/branch: https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git  x86/seves
> > > > > branch HEAD: e6eb15c9ba3165698488ae5c34920eea20eaa38e  KVM: nSVM: Avoid freeing uninitialized pointers in svm_set_nested_state()
> > > > >
> > > > > Warning in current branch:
> > > > >
> > > > > arch/x86/kernel/sev-es.o: warning: objtool: ist_exc_vmm_communication()+0x12: unreachable instruction
> > > > >
> > > > > Warning ids grouped by kconfigs:
> > > > >
> > > > > clang_recent_errors
> > > > > `-- x86_64-randconfig-r001-20200913
> > > > >     `-- arch-x86-kernel-sev-es.o:warning:objtool:ist_exc_vmm_communication():unreachable-instruction
> >
> > Ok, I can't trigger this with gcc-9, gcc-10 and clang-10.
> >
> > .config below says clang-12 so it could be some experimental
> > bug^Wfeature :)
> >
> > peterz says this has been fixed by:
> >
> > 318af7b80b6a ("Revert "kbuild: use -flive-patching when CONFIG_LIVEPATCH is enabled"")
> >
> > but that was reportedly for gcc.
> >
> > Lemme Cc the people of interest and leave the rest in here for
> > reference. Note that CONFIG_LIVEPATCH is enabled in that .config.
>
> If somebody can share the .o file, I can take a look.

Taking a look at the latest report of unreachable instruction from
objtool from 0day bot:
https://groups.google.com/g/clang-built-linux/c/IbF96FeMT8g

$ cd /tmp
$ git clone --depth=1
https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git --branch
x86/seves
$ cd tip
$ gunzip <attached config.gz>
$ cp config .config
$ make LLVM=1 -j71 2> log.txt
$ grep warning: log.txt | cut -d ' ' -f 2- | sort | uniq -c
   3737 warning: objtool: asan.module_ctor()+0xc: call without frame
pointer save/setup
   3737 warning: objtool: asan.module_dtor()+0xc: call without frame
pointer save/setup
      1 warning: objtool: early_alloc()+0x6b: unreachable instruction
      1 warning: objtool: ist_exc_vmm_communication()+0x12:
unreachable instruction
      1 warning: objtool: kmem_cache_create_usercopy()+0x286:
unreachable instruction
      1 warning: objtool: oops_end()+0xc1: unreachable instruction
      1 warning: objtool: __register_nosave_region()+0x87: unreachable
instruction
$ ag ist_exc_vmm_communication
arch/x86/kernel/sev-es.c
1351:           ist_exc_vmm_communication(regs, error_code);
$ gzip -9 arch/x86/kernel/sev-es.o
<attached>

If I remove CONFIG_KASAN=y, I actually get way more unreachable
instruction failures!  Let me play with
tools/testing/ktest/config-bisect.pl and see if I can narrow down the
set of configs from the randconfig.  Also, it's possible that there's
more than one bug here.
-- 
Thanks,
~Nick Desaulniers

Download attachment "config.gz" of type "application/gzip" (34473 bytes)

Download attachment "sev-es.o.gz" of type "application/gzip" (36154 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ