Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp892109ybz; Wed, 22 Apr 2020 09:46:31 -0700 (PDT) X-Google-Smtp-Source: APiQypJAvzdUIA7gsHPaNMp/hp+ak8K4Rt2xTqMn0kixernSE0rMMgpHXvVYJ0SbKfh0+OUN7hkI X-Received: by 2002:a50:f61b:: with SMTP id c27mr22457744edn.256.1587573991438; Wed, 22 Apr 2020 09:46:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1587573991; cv=none; d=google.com; s=arc-20160816; b=pA09mxMj1rRCW7e7Br7U2uWD1vTXSmN35e+gBxewrEO4Yg8XF0gcFSg/CyVnQWnXG+ Mef3QuhIXTfYmBaa6Wv25C/BJjEgnnw2jxUoEkyPKwPVGuBQpMVrohc/iFzu6fLUV2Zg aVpAjEadT4T3AFkHOQ6xt21gkAmaq51wkavGO5wJ7Ffu10jjtWvuBeoC/GkSPqkBH/uw c584JwUu7HB+6b9gmCqrFKXLwo0q46MzMvcA7W2sUmKwTXUKRp03pKsnvVztfa9KFFsW 2Mcr4lUUSxaPRcx3M0InwdQ/lnxY38JBy0BU5UKoAIxHZCa7EtwlDMuBMFT4B7bY+Mpy ORcQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=c0nWZoKPKTTJxXUMabK38nbk8dEd9Y8pN0ufpg96O1o=; b=R762hJSRxaKQYOLqR6+BrWrWSmr2uIghBUiuSoIILRyqd2ot7pdM+gqT1tUz9AdugL A45i6jPJVnS0FKGbsuNsQ1VzSgvlFC8HW9Rj1NIWwtipBGN6KlmvcXpXg+eNVNzeF6rj HHYzJxvNda60WW8PRowGvxVIK0SoZIMx1rJxCPppk0PHUH8PhxIUrPSNqD3FmFaA6w4x jiOX45IEsokUZSq8oS7gGma8Cx7CBRxV5q5OrIqy2+AmohruEcMFQqbnfQd6YvvLuu1M /tufxXB98ehLZPg/nVrRc+eY87/Y4k1zhvjHr5oTaNidvBaFP7Z1eBmfYtWt7b5ZzxAR hFzA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=ENAoOIZe; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g5si3232979ejk.339.2020.04.22.09.46.07; Wed, 22 Apr 2020 09:46:31 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=ENAoOIZe; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726458AbgDVQoP (ORCPT + 99 others); Wed, 22 Apr 2020 12:44:15 -0400 Received: from us-smtp-2.mimecast.com ([207.211.31.81]:48810 "EHLO us-smtp-delivery-1.mimecast.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726147AbgDVQoP (ORCPT ); Wed, 22 Apr 2020 12:44:15 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1587573854; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=c0nWZoKPKTTJxXUMabK38nbk8dEd9Y8pN0ufpg96O1o=; b=ENAoOIZehoG8swNWwCsaw7PsBG6qyf7tYeALkBXSjWK7xMBdfiLIoQ9UKgImCf39OcPHar bEHQeRP0RuB0D3V/nWh2217H2b7A+MzIOUw5zLCS/glXrHEkcZKz26W9VtOIrYbqsoLNWU FYjM9vuoKR+BsD5DtFeukmQSQa40eiE= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-201-9W6c9HByNa2NbULOmEnGpw-1; Wed, 22 Apr 2020 12:44:11 -0400 X-MC-Unique: 9W6c9HByNa2NbULOmEnGpw-1 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id D753418FE860; Wed, 22 Apr 2020 16:44:09 +0000 (UTC) Received: from treble (ovpn-117-114.rdu2.redhat.com [10.10.117.114]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 957706084B; Wed, 22 Apr 2020 16:44:08 +0000 (UTC) Date: Wed, 22 Apr 2020 11:44:06 -0500 From: Josh Poimboeuf To: Randy Dunlap Cc: Stephen Rothwell , Linux Next Mailing List , Linux Kernel Mailing List , Peter Zijlstra , Kees Cook Subject: Re: linux-next: Tree for Apr 22 (objtool warnings) Message-ID: <20200422164406.qhvd2my35wnjlzyg@treble> References: <20200422171016.484b031d@canb.auug.org.au> <2bf0635d-1406-23db-28c7-e55da9a07e05@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <2bf0635d-1406-23db-28c7-e55da9a07e05@infradead.org> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Apr 22, 2020 at 08:35:29AM -0700, Randy Dunlap wrote: > On 4/22/20 12:10 AM, Stephen Rothwell wrote: > > Hi all, > > > > Changes since 20200421: > > > > on x86_64: In both cases the unreachable instruction happens immediately after a call to a function which is truncated with a UD2 (because of UBSAN_TRAP). When I remove UBSAN_TRAP, the UD2s are replaced with calls to __ubsan_handle_type_mismatch_v1(). Kees, any idea? > arch/x86/net/bpf_jit_comp.o: warning: objtool: bpf_int_jit_compile()+0x246: unreachable instruction 00000000000010a1 : 10a1: 55 push %rbp 10a2: 53 push %rbx 10a3: 48 81 ec d0 00 00 00 sub $0xd0,%rsp 10aa: 48 89 fb mov %rdi,%rbx 10ad: 65 48 8b 04 25 28 00 mov %gs:0x28,%rax 10b4: 00 00 10b6: 48 89 84 24 c8 00 00 mov %rax,0xc8(%rsp) 10bd: 00 10be: 31 c0 xor %eax,%eax 10c0: 48 8b bc 24 e0 00 00 mov 0xe0(%rsp),%rdi 10c7: 00 10c8: e8 00 00 00 00 callq 10cd 10c9: R_X86_64_PLT32 __tsan_func_entry-0x4 10cd: f6 c3 07 test $0x7,%bl 10d0: 75 7f jne 1151 10d2: 48 8d 7b 0c lea 0xc(%rbx),%rdi 10d6: e8 00 00 00 00 callq 10db 10d7: R_X86_64_PLT32 __tsan_read4-0x4 10db: 48 89 e7 mov %rsp,%rdi 10de: e8 00 00 00 00 callq 10e3 10df: R_X86_64_PLT32 __tsan_write8-0x4 10e3: 48 8d 6c 24 08 lea 0x8(%rsp),%rbp 10e8: 48 89 2c 24 mov %rbp,(%rsp) 10ec: 48 8d 7b 04 lea 0x4(%rbx),%rdi 10f0: e8 00 00 00 00 callq 10f5 10f1: R_X86_64_PLT32 __tsan_read4-0x4 10f5: 48 8d 7b 20 lea 0x20(%rbx),%rdi 10f9: e8 00 00 00 00 callq 10fe 10fa: R_X86_64_PLT32 __tsan_read8-0x4 10fe: 48 8b 7b 20 mov 0x20(%rbx),%rdi 1102: 40 f6 c7 07 test $0x7,%dil 1106: 75 49 jne 1151 1108: 48 83 c7 18 add $0x18,%rdi 110c: e8 00 00 00 00 callq 1111 110d: R_X86_64_PLT32 __tsan_read4-0x4 1111: 48 c7 c7 00 00 00 00 mov $0x0,%rdi 1114: R_X86_64_32S ideal_nops 1118: e8 00 00 00 00 callq 111d 1119: R_X86_64_PLT32 __tsan_read8-0x4 111d: 48 8b 1d 00 00 00 00 mov 0x0(%rip),%rbx # 1124 1120: R_X86_64_PC32 ideal_nops-0x4 1124: 48 8d 7b 48 lea 0x48(%rbx),%rdi 1128: f6 c3 07 test $0x7,%bl 112b: 75 24 jne 1151 112d: e8 00 00 00 00 callq 1132 112e: R_X86_64_PLT32 __tsan_read8-0x4 1132: 48 8b 43 48 mov 0x48(%rbx),%rax 1136: 8b 10 mov (%rax),%edx 1138: 89 55 00 mov %edx,0x0(%rbp) 113b: 0f b6 40 04 movzbl 0x4(%rax),%eax 113f: 88 45 04 mov %al,0x4(%rbp) 1142: 48 8d 7c 24 0d lea 0xd(%rsp),%rdi 1147: e8 00 00 00 00 callq 114c 1148: R_X86_64_PLT32 __tsan_write1-0x4 114c: c6 44 24 0d 55 movb $0x55,0xd(%rsp) 1151: 0f 0b ud2 > drivers/media/i2c/ir-kbd-i2c.o: warning: objtool: ir_probe()+0x745: unreachable instruction 000000000000091e : 91e: 55 push %rbp 91f: 48 83 ec 70 sub $0x70,%rsp 923: 65 48 8b 04 25 28 00 mov %gs:0x28,%rax 92a: 00 00 92c: 48 89 44 24 68 mov %rax,0x68(%rsp) 931: 31 c0 xor %eax,%eax 933: 48 8b 7c 24 78 mov 0x78(%rsp),%rdi 938: e8 00 00 00 00 callq 93d 939: R_X86_64_PLT32 __tsan_func_entry-0x4 93d: 48 8d 6c 24 08 lea 0x8(%rsp),%rbp 942: be 60 00 00 00 mov $0x60,%esi 947: 48 89 ef mov %rbp,%rdi 94a: e8 00 00 00 00 callq 94f 94b: R_X86_64_PLT32 __tsan_write_range-0x4 94f: b9 0c 00 00 00 mov $0xc,%ecx 954: 31 c0 xor %eax,%eax 956: 48 89 ef mov %rbp,%rdi 959: f3 48 ab rep stos %rax,%es:(%rdi) 95c: 48 89 ef mov %rbp,%rdi 95f: e8 00 00 00 00 callq 964 960: R_X86_64_PLT32 __tsan_write1-0x4 964: c6 44 24 08 60 movb $0x60,0x8(%rsp) 969: 0f 0b ud2 -- Josh