Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

objtool warnings in localmodconfig #336

Closed
nickdesaulniers opened this issue Jan 28, 2019 · 25 comments
Closed

objtool warnings in localmodconfig #336

nickdesaulniers opened this issue Jan 28, 2019 · 25 comments
Assignees
Labels
[ARCH] x86_64 This bug impacts ARCH=x86_64 asm goto related to the implementation of asm goto [BUG] llvm A bug that should be fixed in upstream LLVM [FIXED][LINUX] 5.2 This bug was fixed in Linux 5.2 [TOOL] objtool warning is produced by the kernel's objtool

Comments

@nickdesaulniers
Copy link
Member

nickdesaulniers commented Jan 28, 2019

not sure if asm goto related or not.

With D53765 Diff 183780.

$ grep objtool: log.txt
arch/x86/kernel/apic/vector.o: warning: objtool: print_PIC()+0x129: sibling call from callable instruction with modified stack frame
drivers/acpi/ec.o: warning: objtool: acpi_ec_unmask_gpe()+0x35: sibling call from callable instruction with modified stack frame
drivers/cpufreq/intel_pstate.o: warning: objtool: intel_pstate_update_perf_limits()+0x1ff: unreachable instruction
drivers/gpu/drm/i915/gvt/cmd_parser.o: warning: objtool: parser_exec_state_dump()+0x144: unreachable instruction

localmodconfig.txt

@nickdesaulniers nickdesaulniers added [BUG] Untriaged Something isn't working [ARCH] x86_64 This bug impacts ARCH=x86_64 asm goto related to the implementation of asm goto labels Jan 28, 2019
@nickdesaulniers nickdesaulniers self-assigned this Jan 28, 2019
@nickdesaulniers nickdesaulniers added the [TOOL] objtool warning is produced by the kernel's objtool label Jan 28, 2019
@nickdesaulniers
Copy link
Member Author

$ make CC=clang  arch/x86/kernel/apic/vector.o
$ make CC=clang drivers/acpi/ec.o
$ make CC=clang drivers/cpufreq/intel_pstate.o

reliably repro. Final one needs

$ make CC=clang drivers/gpu/drm/i915/

@nickdesaulniers
Copy link
Member Author

All of the above are reproducible with 183921.

Without asm goto, I don't observe. Bisection now.

@nickdesaulniers nickdesaulniers added [BUG] llvm A bug that should be fixed in upstream LLVM and removed [BUG] Untriaged Something isn't working labels Jan 29, 2019
@nickdesaulniers
Copy link
Member Author

nickdesaulniers commented Jan 29, 2019

Seems to be related to orc unwinder generations CONFIG_UNWINDER_ORC=y.

./tools/objtool/objtool orc generate --no-fp --retpoline arch/x86/kernel/apic/vector.o
./tools/objtool/objtool orc generate --no-fp --retpoline drivers/acpi/ec.o
./tools/objtool/objtool orc generate --no-fp --retpoline drivers/cpufreq/intel_pstate.o

C Reduce spat this out from arch/x86/kernel/apic/vector.o:

// $ clang -no-integrated-as -O2 -pg -mfentry vector.c
// $ tools/objtool/objtool orc generate  --no-fp --retpoline vector.o
// vector.o: warning: objtool: print_PIC()+0x27: sibling call from
// callable instruction with modified stack frame
c, d;
a(char);
b(void);
void print_PIC() {
  if (c) {
    b();
    asm goto("1:.long b - ., %l[l_yes] - . \n\t" : : : : l_yes);
  l_yes:
    a(d);
  }
}
vector.o:     file format elf64-x86-64
Disassembly of section .text:
0000000000000000 <print_PIC>:
   0:   e8 00 00 00 00          callq  5 <print_PIC+0x5>
   5:   83 3d 00 00 00 00 00    cmpl   $0x0,0x0(%rip)        # c <print_PIC+0xc>
   c:   74 1e                   je     2c <print_PIC+0x2c>
   e:   55                      push   %rbp
   f:   48 89 e5                mov    %rsp,%rbp
  12:   e8 00 00 00 00          callq  17 <print_PIC+0x17>
  17:   00 00                   add    %al,(%rax)
  19:   00 00                   add    %al,(%rax)
  1b:   05 00 00 00 5d          add    $0x5d000000,%eax
  20:   0f be 3d 00 00 00 00    movsbl 0x0(%rip),%edi        # 27 <print_PIC+0x27>
  27:   e9 00 00 00 00          jmpq   2c <print_PIC+0x2c>
  2c:   c3                      retq
$ grep objtool: log.txt
arch/x86/kernel/apic/vector.o: warning: objtool: print_PIC()+0x129: sibling call from callable instruction with modified stack frame
arch/x86/pci/fixup.o: warning: objtool: pci_fixup_i450nx()+0xfd: unreachable instruction
drivers/acpi/ec.o: warning: objtool: acpi_ec_unmask_gpe()+0x35: sibling call from callable instruction with modified stack frame
sound/pci/hda/hda_generic.o: warning: objtool: parse_output_paths()+0x146: unreachable instruction
drivers/cpufreq/intel_pstate.o: warning: objtool: intel_pstate_update_perf_limits()+0x1ff: unreachable instruction
lib/crc-t10dif.o: warning: objtool: crc_t10dif_transform_show()+0x3c: return with modified stack frame
lib/crc-t10dif.o: warning: objtool: crc_t10dif_transform_show()+0x0: stack state mismatch: cfa1=7+16 cfa2=7+8
drivers/input/touchscreen/elants_i2c.o: warning: objtool: elants_i2c_query_test_version()+0x1ad: unreachable instruction
drivers/mfd/wm831x-irq.o: warning: objtool: wm831x_irq_sync_unlock()+0xc6: unreachable instruction
drivers/mmc/core/mmc.o: warning: objtool: mmc_fixup_device()+0x97: unreachable instruction
drivers/misc/mei/bus-fixup.o: warning: objtool: mei_fwver()+0x1ac: unreachable instruction
drivers/platform/x86/intel_turbo_max_3.o: warning: objtool: get_oc_core_priority()+0x11c: unreachable instruction
drivers/gpu/drm/i915/gvt/cmd_parser.o: warning: objtool: parser_exec_state_dump()+0x144: unreachable instruction
$ grep objtool: log.txt  | wc -l
13

@nickdesaulniers
Copy link
Member Author

arch/x86/pci/fixup.o: warning: objtool: pci_fixup_i450nx()+0xfd: unreachable instruction

was C reduced down to:

// clang -O2 -no-integrated-as -c -mfentry -pg
pci_fixup_i450nx() {
  for (;;)
    asm goto("" : : : : a);
a:;
}

fixup.o:     file format elf64-x86-64


Disassembly of section .text:

0000000000000000 <pci_fixup_i450nx>:
   0:   e8 00 00 00 00          callq  5 <pci_fixup_i450nx+0x5>
   5:   55                      push   %rbp
   6:   48 89 e5                mov    %rsp,%rbp
   9:   0f 1f 80 00 00 00 00    nopl   0x0(%rax)
  10:   eb fe                   jmp    10 <pci_fixup_i450nx+0x10>
  12:   5d                      pop    %rbp
  13:   c3                      retq

The combination of -mfentry -pg flags to clang look problematic in both cases.

@topperc
Copy link

topperc commented Jan 29, 2019

For fixup.o, is it just complaining that we didn't delete the code after the infinite loop? It looks like gcc will compile an infinite loop for that as well. gcc still emits an unreachable retq, but not the frame pointer setup and teardown.

@topperc
Copy link

topperc commented Jan 29, 2019

Looks like -pg explicitly forces -mdisable-fp-elim in clang. This prevents the backend from removing the frame code.

@topperc
Copy link

topperc commented Jan 29, 2019

The vector.o case is a bad optimization of stack frame prologue/epilogue due to the weird control flow asm-goto creates. I've added a fix similar to what we do for EHPads in the latest patch in phabricator.

@jpoimboe
Copy link

@nickdesaulniers If you give me the original non-reduced fixup.o, I can clarify what objtool is complaining about (and why it doesn't complain about the same code for GCC).

@dileks
Copy link

dileks commented Jan 30, 2019

@topperc @nickdesaulniers
It's amazing to see things getting fixed so fast, Thanks.
Now, building a new llvm-toolchain-8.0.0rc1 (llvm and clang) with D53765.id184223.diff

@dileks
Copy link

dileks commented Jan 30, 2019

@topperc With D53765.id184223.diff

$ TESTS="CodeGen/asm-goto.c"

$ cd build ; for t in $TESTS ; do ./bin/llvm-lit -v ./tools/clang/test/$t ; done
llvm-lit: /home/sdi/src/llvm-toolchain/llvm/utils/lit/lit/llvm/config.py:337: note: using clang: /home/sdi/src/llvm-toolchain/build/bin/clang
-- Testing: 1 tests, 1 threads --
FAIL: Clang :: CodeGen/asm-goto.c (1 of 1)
******************** TEST 'Clang :: CodeGen/asm-goto.c' FAILED ********************
Script:
--
: 'RUN: at line 1';   /home/sdi/src/llvm-toolchain/build/bin/clang -cc1 -internal-isystem /home/sdi/src/llvm-toolchain/build/lib/clang/8.0.0/include -nostdsysteminc -O0 -emit-llvm  /home/sdi/src/llvm-toolchain/llvm/tools/clang/test/CodeGen/asm-goto.c -o - | /home/sdi/src/llvm-toolchain/build/bin/FileCheck /home/sdi/src/llvm-toolchain/llvm/tools/clang/test/CodeGen/asm-goto.c
--
Exit Code: 1

Command Output (stderr):
--
/home/sdi/src/llvm-toolchain/llvm/tools/clang/test/CodeGen/asm-goto.c:6:12: error: CHECK: expected string not found in input
 // CHECK: to label %normal0 or jump [label %label_true, label %loop], !srcloc !2
           ^
<stdin>:13:29: note: scanning from here
 callbr void asm sideeffect "testl $0, $0; jne ${1:l};", "r,X,X,~{dirflag},~{fpsr},~{flags}"(i32 %0, i8* blockaddress(@foo, %label_true), i8* blockaddress(@foo, %loop)) #1
                            ^
<stdin>:14:2: note: possible intended match here
 to label %normal0 [label %label_true, label %loop], !srcloc !2
 ^

--

********************
Testing Time: 0.12s
********************
Failing Tests (1):
    Clang :: CodeGen/asm-goto.c

  Unexpected Failures: 1

UPDATE: Fix for D56571.id181973.diff

[ test/CodeGen/asm-goto.c ]
-  // CHECK: to label %normal0 or jump [label %label_true, label %loop], !srcloc !2
+  // CHECK: to label %normal0 [label %label_true, label %loop], !srcloc !2

@dileks
Copy link

dileks commented Jan 30, 2019

I see all the objtool warnings observed by Nick plus the following when I use a Debian kernel-config as a base:

$ grep objtool: build-log_5.0.0-rc4-1-amd64-cbl-asmgoto.txt | cut -d ' ' -f 5- | sort | uniq
return with modified stack frame
sibling call from callable instruction with modified stack frame
stack state mismatch: cfa1=6+16 cfa2=7+8
stack state mismatch: cfa1=7+16 cfa2=7+8
undefined stack state
unreachable instruction

objtool-warnings_dileks.txt

@dileks
Copy link

dileks commented Jan 30, 2019

If I run on bare metal I see the folowing kernel-panic (noted from the screen):

Kernel stack is corrupted in intel_idle_probe
Call Trace:
  dump_stack
  panic
  ? intel_idle_probe
  __stack_chk_fail
  intel_idle_probe
  ? efifb_driver_init
  intel_idle_init
  do_one_initcall
  do_initcall_level
  do_basic_setup
  ? rest_init
  ret_from_fork
Kernel offset: 0x168000000 from 0x ffffffff 81 000000 (relocation range: 0x ffffffff 80 000000 - 0x ffffffff bf ffffff)

If you have any suggestions how I can log these lines (being able to read them from a system wit a running kernel), please let me know. Thanks.

@jpoimboe
Copy link

I think the best way is to either take a picture, or enable kdump.

@dileks
Copy link

dileks commented Jan 30, 2019

@jpoimboe
I tried with systemd-debugging (console) and saw some more informations on the screen by appending to my kernel command-line:

systemd.log_level=debug systemd.log_target=console console=ttyS0,38400 console=tty1

My colleague here suggested me to use kdump also, Thanks.

[1] https://freedesktop.org/wiki/Software/systemd/Debugging/
[2] https://www.kernel.org/doc/Documentation/kdump/kdump.txt

@nickdesaulniers
Copy link
Member Author

nickdesaulniers commented Jan 30, 2019

@dileks from your trace, looks like -fstack-protector-strong guard is failing in intel_idle_probe. I wouldn't risk booting on bare metal until the objtool warnings are all fixed. At least boot in QEMU first as a base sanity check. It would suck to suffer data loss from running on bare metal (but accepting the risk is much appreciated, for the sake of testing).

From your list of objtool warnings, are any from the translation unit that defines intel_idel_probe?

@dileks
Copy link

dileks commented Jan 30, 2019

@nickdesaulniers
All kernel boot fine in QEMU.

What do you mean by "from the translation unit that defines intel_idel_probe"?

@nathanchance
Copy link
Member

What do you mean by "from the translation unit that defines intel_idel_probe"?

intel_idle_probe is defined in drivers/idle/intel_idle.c, are there any objtool warnings from drivers/idle/intel_idle.o.

@nickdesaulniers
Copy link
Member Author

drivers/acpi/ec.o: warning: objtool: acpi_ec_unmask_gpe()+0x35: sibling call from callable instruction with modified stack frame:

0000000000000fa0 <acpi_ec_unmask_gpe>:
     fa0:       e8 00 00 00 00          callq  fa5 <acpi_ec_unmask_gpe+0x5>
                        fa1: R_X86_64_PC32      __fentry__-0x4
     fa5:       f7 47 28 00 01 00 00    testl  $0x100,0x28(%rdi)
     fac:       74 16                   je     fc4 <acpi_ec_unmask_gpe+0x24>
     fae:       55                      push   %rbp
     faf:       48 89 e5                mov    %rsp,%rbp
     fb2:       f0 80 67 29 fe          lock andb $0xfe,0x29(%rdi)
     fb7:       31 f6                   xor    %esi,%esi
     fb9:       e8 22 00 00 00          callq  fe0 <acpi_ec_enable_gpe>
     fbe:       0f 1f 44 00 00          nopl   0x0(%rax,%rax,1)
     fc3:       5d                      pop    %rbp
     fc4:       c3                      retq   
     fc5:       48 c7 c7 00 00 00 00    mov    $0x0,%rdi   ; how do we get here???
                        fc8: R_X86_64_32S       __verbose+0x380
     fcc:       48 c7 c6 00 00 00 00    mov    $0x0,%rsi
                        fcf: R_X86_64_32S       .rodata.str1.1+0x53d
     fd3:       31 c0                   xor    %eax,%eax
     fd5:       e9 00 00 00 00          jmpq   fda <acpi_ec_unmask_gpe+0x3a>
                        fd6: R_X86_64_PC32      __dynamic_pr_debug-0x4
     fda:       66 0f 1f 44 00 00       nopw   0x0(%rax,%rax,1)

@jpoimboe , thoughts?

With my localmodconfig from the first comment on this bug, and Diff 184345:

$ grep objtool: log.txt                                                                                                       
arch/x86/pci/fixup.o: warning: objtool: pci_fixup_i450nx()+0xfd: unreachable instruction
drivers/acpi/ec.o: warning: objtool: acpi_ec_unmask_gpe()+0x35: sibling call from callable instruction with modified stack frame
arch/x86/kernel/apic/vector.o: warning: objtool: print_PIC()+0x129: sibling call from callable instruction with modified stack frame
drivers/cpufreq/intel_pstate.o: warning: objtool: intel_pstate_update_perf_limits()+0x1ff: unreachable instruction
sound/pci/hda/hda_generic.o: warning: objtool: parse_output_paths()+0x146: unreachable instruction
lib/crc-t10dif.o: warning: objtool: crc_t10dif_transform_show()+0x3c: return with modified stack frame
lib/crc-t10dif.o: warning: objtool: crc_t10dif_transform_show()+0x0: stack state mismatch: cfa1=7+16 cfa2=7+8
drivers/input/touchscreen/elants_i2c.o: warning: objtool: elants_i2c_query_test_version()+0x1ad: unreachable instruction
drivers/misc/mei/bus-fixup.o: warning: objtool: mei_fwver()+0x1ac: unreachable instruction
drivers/mfd/wm831x-irq.o: warning: objtool: wm831x_irq_sync_unlock()+0xc6: unreachable instruction
drivers/mmc/core/mmc.o: warning: objtool: mmc_fixup_device()+0x97: unreachable instruction
drivers/platform/x86/intel_turbo_max_3.o: warning: objtool: get_oc_core_priority()+0x11c: unreachable instruction
drivers/gpu/drm/i915/gvt/cmd_parser.o: warning: objtool: parser_exec_state_dump()+0x144: unreachable instruction

===

for lib/crc-t10dif.o, here's a creduced case:
export4.zip
Looks like %bb.4:/.Lfunc_end0: falls through into crc_t10dif_transform_show's lone ret without restoring the stack.

@jpoimboe
Copy link

 fc5:       48 c7 c7 00 00 00 00    mov    $0x0,%rdi   ; how do we get here???

I'd have to look at the jump table to be sure, but I'd guess that the NOP at 0xfbe can probably be patched at runtime by the jump label code to be a JMP to 0xfc5. In which case the objtool warning is correct.

(BTW, I'm out the next few days, so I may not be very responsive until Monday.)

@topperc
Copy link

topperc commented Jan 31, 2019

I've uploaded a new patch to phabricator for crc-t10dif.o. I'm not super confident in it but it fixed the reduced case.

@dileks
Copy link

dileks commented Jan 31, 2019

@nickdesaulniers @nathanchance @jpoimboe
No objtool warnings from drivers/idle/intel_idle.o.

build-log_idle-intel_idle.txt

@nickdesaulniers
Copy link
Member Author

with

clang asm goto diff 185489
llvm asm goto diff 185868

and the config from above, I just see a few unreachable instruction warnings:

arch/x86/pci/fixup.o: warning: objtool: pci_fixup_i450nx()+0xfd: unreachable instruction
sound/pci/hda/hda_generic.o: warning: objtool: parse_output_paths()+0x146: unreachable instruction
drivers/input/touchscreen/elants_i2c.o: warning: objtool: elants_i2c_query_test_version()+0x1ad: unreachable instruction
drivers/mfd/wm831x-irq.o: warning: objtool: wm831x_irq_sync_unlock()+0xc6: unreachable instruction
drivers/misc/mei/bus-fixup.o: warning: objtool: mei_fwver()+0x1ac: unreachable instruction
drivers/mmc/core/mmc.o: warning: objtool: mmc_fixup_device()+0x97: unreachable instruction
drivers/platform/x86/intel_turbo_max_3.o: warning: objtool: get_oc_core_priority()+0x11c: unreachable instruction
drivers/gpu/drm/i915/gvt/cmd_parser.o: warning: objtool: parser_exec_state_dump()+0x144: unreachable instruction

I'll try to provide @jpoimboe the object files pre-orc-generation.

@dileks
Copy link

dileks commented Feb 26, 2019

One stack state mismatch left (rest is unreachable instruction):

$ grep objtool: build-log.txt | grep -v 'unreachable instruction'
drivers/gpu/drm/vmwgfx/vmwgfx_msg.o: warning: objtool: vmw_host_get_guestinfo()+0x1d5: stack state mismatch: cfa1=6+16 cfa2=7+8
drivers/gpu/drm/vmwgfx/vmwgfx_msg.o: warning: objtool: vmw_host_log()+0x15a: stack state mismatch: cfa1=6+16 cfa2=7+8

Full list:

$ grep objtool: build-log.txt
fs/affs/super.o: warning: objtool: affs_fill_super()+0x35f: unreachable instruction
drivers/block/skd_main.o: warning: objtool: skd_pci_probe()+0x308: unreachable instruction
drivers/gpu/drm/ttm/ttm_bo.o: warning: objtool: ttm_bo_device_release()+0x154: unreachable instruction
drivers/gpu/drm/vmwgfx/vmwgfx_msg.o: warning: objtool: vmw_host_get_guestinfo()+0x1d5: stack state mismatch: cfa1=6+16 cfa2=7+8
drivers/gpu/drm/vmwgfx/vmwgfx_msg.o: warning: objtool: vmw_host_log()+0x15a: stack state mismatch: cfa1=6+16 cfa2=7+8
drivers/hwmon/ad7414.o: warning: objtool: ad7414_update_device()+0xf6: unreachable instruction
drivers/hwmon/w83l785ts.o: warning: objtool: w83l785ts_read_value()+0xa8: unreachable instruction
drivers/infiniband/hw/mlx4/mad.o: warning: objtool: handle_port_mgmt_change_event()+0x158: unreachable instruction
drivers/input/mouse/elan_i2c_core.o: warning: objtool: elan_write_fw_block()+0x90: unreachable instruction
drivers/input/tablet/gtco.o: warning: objtool: gtco_probe()+0x3d7: unreachable instruction
drivers/input/touchscreen/usbtouchscreen.o: warning: objtool: mtouch_init()+0x25f: unreachable instruction
drivers/media/dvb-frontends/cxd2820r_core.o: warning: objtool: cxd2820r_gpio()+0xeb: unreachable instruction
drivers/media/usb/dvb-usb-v2/anysee.o: warning: objtool: anysee_ctrl_msg()+0x16a: unreachable instruction
drivers/media/usb/msi2500/msi2500.o: warning: objtool: msi2500_set_usb_adc()+0x151: unreachable instruction
drivers/misc/mei/bus-fixup.o: warning: objtool: mei_fwver()+0x1ac: unreachable instruction
drivers/mmc/core/mmc.o: warning: objtool: mmc_fixup_device()+0x97: unreachable instruction
drivers/mmc/host/wbsd.o: warning: objtool: wbsd_scan()+0x140: unreachable instruction
drivers/mmc/host/rtsx_pci_sdmmc.o: warning: objtool: sd_send_cmd_get_rsp()+0x53a: unreachable instruction
drivers/mmc/host/rtsx_usb_sdmmc.o: warning: objtool: sd_send_cmd_get_rsp()+0x6c1: unreachable instruction
drivers/mtd/maps/pcmciamtd.o: warning: objtool: pcmciamtd_config()+0x46c: unreachable instruction
drivers/mtd/nand/raw/r852.o: warning: objtool: r852_ecc_correct()+0x103: unreachable instruction
drivers/mtd/ssfdc.o: warning: objtool: get_logical_address()+0x15c: unreachable instruction
drivers/net/ethernet/cavium/liquidio/cn23xx_pf_device.o: warning: objtool: cn23xx_dump_pf_initialized_regs()+0x233: unreachable instruction
drivers/net/ethernet/realtek/8139too.o: warning: objtool: rtl8139_tx_timeout_task()+0xc0: unreachable instruction
drivers/scsi/qla2xxx/qla_target.o: warning: objtool: qlt_lport_dump()+0x116: unreachable instruction
drivers/scsi/ufs/ufshcd.o: warning: objtool: ufshcd_dme_set_attr()+0xf5: unreachable instruction
drivers/staging/rtl8192u/r8192U_core.o: warning: objtool: rtl8192_read_eeprom_info()+0x6aa: unreachable instruction
drivers/staging/rtl8192u/r8192U_dm.o: warning: objtool: dm_TXPowerTrackingCallback_TSSI()+0x469: unreachable instruction
drivers/staging/rts5208/rtsx_card.o: warning: objtool: card_rw()+0x13e: unreachable instruction
drivers/staging/rts5208/sd.o: warning: objtool: sd_tuning_rx()+0x17f: unreachable instruction
drivers/thermal/intel/intel_soc_dts_iosf.o: warning: objtool: intel_soc_dts_iosf_interrupt_handler()+0xf6: unreachable instruction
drivers/usb/atm/usbatm.o: warning: objtool: usbatm_usb_probe()+0x405: unreachable instruction
drivers/usb/serial/iuu_phoenix.o: warning: objtool: iuu_uart_flush()+0x18f: unreachable instruction
drivers/usb/serial/keyspan.o: warning: objtool: keyspan_open()+0xdb: unreachable instruction
sound/pci/atiixp.o: warning: objtool: snd_atiixp_mixer_new()+0x246: unreachable instruction
sound/pci/atiixp_modem.o: warning: objtool: snd_atiixp_mixer_new()+0x1e0: unreachable instruction
sound/pci/azt3328.o: warning: objtool: snd_azf3328_debug_show_ports()+0x36: unreachable instruction
sound/pci/echoaudio/darla20.o: warning: objtool: free_firmware_cache()+0x62: unreachable instruction
sound/pci/echoaudio/gina20.o: warning: objtool: free_firmware_cache()+0x62: unreachable instruction
sound/pci/echoaudio/layla20.o: warning: objtool: free_firmware_cache()+0x62: unreachable instruction
sound/pci/echoaudio/darla24.o: warning: objtool: free_firmware_cache()+0x62: unreachable instruction
sound/pci/echoaudio/gina24.o: warning: objtool: free_firmware_cache()+0x62: unreachable instruction
sound/pci/echoaudio/layla24.o: warning: objtool: free_firmware_cache()+0x62: unreachable instruction
sound/pci/echoaudio/mona.o: warning: objtool: free_firmware_cache()+0x62: unreachable instruction
sound/pci/echoaudio/mia.o: warning: objtool: free_firmware_cache()+0x62: unreachable instruction
sound/pci/echoaudio/echo3g.o: warning: objtool: free_firmware_cache()+0x62: unreachable instruction
sound/pci/echoaudio/indigo.o: warning: objtool: free_firmware_cache()+0x62: unreachable instruction
sound/pci/echoaudio/indigoio.o: warning: objtool: free_firmware_cache()+0x62: unreachable instruction
sound/pci/echoaudio/indigodj.o: warning: objtool: free_firmware_cache()+0x62: unreachable instruction
sound/pci/echoaudio/indigoiox.o: warning: objtool: free_firmware_cache()+0x62: unreachable instruction
sound/pci/echoaudio/indigodjx.o: warning: objtool: free_firmware_cache()+0x62: unreachable instruction
sound/pci/hda/hda_generic.o: warning: objtool: parse_output_paths()+0x146: unreachable instruction
sound/soc/intel/haswell/sst-haswell-pcm.o: warning: objtool: hsw_pcm_prepare()+0x88: unreachable instruction
arch/x86/pci/fixup.o: warning: objtool: pci_fixup_i450nx()+0xfd: unreachable instruction
net/bridge/netfilter/ebtables.o: warning: objtool: compat_calc_entry()+0x184: unreachable instruction
net/netfilter/nf_conntrack_proto_gre.o: warning: objtool: nf_ct_gre_keymap_destroy()+0xfb: unreachable instruction

Independent of all these warnings I can boot into bare metal when linking with GNU/ld linker (LLD is a different story).

@tpimh
Copy link

tpimh commented Mar 7, 2019

Another few which I can't see reported:

arch/x86/events/intel/core.o: warning: objtool: intel_pmu_nhm_workaround()+0xa9: unreachable instruction
arch/x86/kernel/cpu/mtrr/generic.o: warning: objtool: get_fixed_ranges()+0x9f: unreachable instruction
arch/x86/kernel/platform-quirks.o: warning: objtool: x86_early_init_platform_quirks()+0x8e: unreachable instruction

The last one is #199.

@nickdesaulniers
Copy link
Member Author

I suspect this is fixed (I cannot repro any longer). If folks spot any more of these, please file individual bugs with what arch and what configs on top of the defconfig is required.

@tpimh tpimh added the [FIXED][LINUX] 5.2 This bug was fixed in Linux 5.2 label Jun 24, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[ARCH] x86_64 This bug impacts ARCH=x86_64 asm goto related to the implementation of asm goto [BUG] llvm A bug that should be fixed in upstream LLVM [FIXED][LINUX] 5.2 This bug was fixed in Linux 5.2 [TOOL] objtool warning is produced by the kernel's objtool
Projects
None yet
Development

No branches or pull requests

6 participants