Received: by 2002:a25:683:0:0:0:0:0 with SMTP id 125csp4551958ybg; Mon, 8 Jun 2020 10:38:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJym3nlmv/pzmxALn0yME1JmQqhnTxjeSbISFt9gjZpFu3pBfrEmIDCYh2sT5dtfd+YullGz X-Received: by 2002:a17:907:20f4:: with SMTP id rh20mr21368962ejb.55.1591637931431; Mon, 08 Jun 2020 10:38:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1591637931; cv=none; d=google.com; s=arc-20160816; b=TznY09Rfb4deYrIzMvuzUpZa/L2u54vqC4DBDPpgSFpV8+cJ6WrcaCmBH/vEiu7zd+ 1335y76Zze+GV8U6T2o6MI31+d736E8jo/9WDoQqPM9ohHN1YG2Zng63DZKj8YRzOnNv qv3cwi+Dqvk3mgaMn/LTUyVhEJHiRIMuRnrRD/W4XyNtwisSiGT++yNltl8SIlusZczG QJd1P6K0d6KL0L905DHMnuiJ7enqOiPE76A50DVccr7/MsSQKl+bYmdOK01R8NsqHVom F3ncouijV8a/M00BT853+H4miw40fkEXP5HzvHESmeZg1wxHzvZp81QuM5t72ujrgnVL p/yQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=8XmB9dtJu++KVpOBk6iZgjeuWMZ0//aiEGYwXB9eRqM=; b=BVG9KmuyEmYwaGIsVytJGVzrpfY1EVzwbms8ttyAorgwiSPtdy+pXWNAf/AZEpiZfu ogtKwGshVJ+dD7as5BRTO2ZjHH3U8pg9Jy0sBuj8dusRt+zGCV0FaLPF+O0Q0cvdhynv 7SYf/9XSN8P6yAjtOCmVTNuOyPdPEZ5su3D0mEWVlTgGCjkt5TwRAxxguhC85c4RXFAx tWUBiwrP4uq3H6Qk/1NzKNZa18UJOMhVvNbEGDARPqDXbdjwSctClIC+OG9ZYHv/xNw9 RZKHFY0fe01SH/P5z/v2T2prfD3+u9caqa1M/HSITTAnc6jQhhLq1tmJzjrmQYtHNkDl hciw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=DRpx0Tma; 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 dd10si8934614edb.245.2020.06.08.10.38.28; Mon, 08 Jun 2020 10:38:51 -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=DRpx0Tma; 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 S1730270AbgFHP2P (ORCPT + 99 others); Mon, 8 Jun 2020 11:28:15 -0400 Received: from us-smtp-delivery-1.mimecast.com ([207.211.31.120]:60906 "EHLO us-smtp-1.mimecast.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1730228AbgFHP2G (ORCPT ); Mon, 8 Jun 2020 11:28:06 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1591630084; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=8XmB9dtJu++KVpOBk6iZgjeuWMZ0//aiEGYwXB9eRqM=; b=DRpx0Tma3OuSunO8JInFI79X1r7aGhIkeWujA4oadjLShaxV5qfeaC3F+P04T5MhYyPWlX yQlH4kT8Prd0yfTYhT4Hqucyb1SLpzv9Su03YJ5uvoa3l3V1lfkBcnZG3i6dfDREq2aI5g ZTlEXv+GU5NJ9tEAfSCHi2xhSyvEMqI= Received: from mail-wr1-f70.google.com (mail-wr1-f70.google.com [209.85.221.70]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-463-zvAoXYcENVKXKqogWTDuBQ-1; Mon, 08 Jun 2020 11:28:00 -0400 X-MC-Unique: zvAoXYcENVKXKqogWTDuBQ-1 Received: by mail-wr1-f70.google.com with SMTP id t5so7286181wro.20 for ; Mon, 08 Jun 2020 08:28:00 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=8XmB9dtJu++KVpOBk6iZgjeuWMZ0//aiEGYwXB9eRqM=; b=jSV1ha/KcGhTowarffNn9kF0QfgyTHraXqykbJUW183x8wRrKJYT6XKJHpTWopgVDZ oEneLvcBUHmeVyexK61hy2XcBRe9XaGM5AtUA2E2V+k8hkGVVnfJQz2VyqxvenoIrOJI 4Dxu7kdjfHDKddqIbSDMSpoIiupxFz6Wc56nZZJf2GflRpclflsoU7mRV58ysypr/pJY zjo7l5Ayamh/WlMVpLJTdvYncvaDnPPwVoFEXrbIARFwaPQ0+en6OHZ7BuDvYBvFkcF8 lObbplP3bAogHBofmAkYW+LK2ICyKwY/UzbjwY7OnTbXVATBJ84viqxdiUVMynaEnwx0 HdeA== X-Gm-Message-State: AOAM532pyo3oHeG7O4jCJDUNeWpogAHtRErrABsTXI8W3pxWcEsXuYCr 9c5WUcKQNHIaUPmWl1y8PxqV9tuIoiKXu50wlGcCUwU1TMqYaGdFc2cS46rOs6P+lu04oevlzN2 vWX90Ee/9kNICm6AVU/QpjYSA X-Received: by 2002:a1c:998c:: with SMTP id b134mr17814682wme.78.1591630079537; Mon, 08 Jun 2020 08:27:59 -0700 (PDT) X-Received: by 2002:a1c:998c:: with SMTP id b134mr17814670wme.78.1591630079357; Mon, 08 Jun 2020 08:27:59 -0700 (PDT) Received: from redfedo.redhat.com ([2a01:cb14:499:3d00:cd47:f651:9d80:157a]) by smtp.gmail.com with ESMTPSA id u130sm23981707wmg.32.2020.06.08.08.27.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Jun 2020 08:27:58 -0700 (PDT) From: Julien Thierry To: linux-kernel@vger.kernel.org Cc: jpoimboe@redhat.com, peterz@infradead.org, mbenes@suse.cz, raphael.gault@arm.com, Julien Thierry Subject: [PATCH 2/7] objtool: Make sync-check consider the target architecture Date: Mon, 8 Jun 2020 16:27:49 +0100 Message-Id: <20200608152754.2483-3-jthierry@redhat.com> X-Mailer: git-send-email 2.21.1 In-Reply-To: <20200608152754.2483-1-jthierry@redhat.com> References: <20200608152754.2483-1-jthierry@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Do not take into account outdated headers unrelated to the build of the current architecture. Signed-off-by: Julien Thierry --- tools/objtool/Makefile | 2 +- tools/objtool/sync-check.sh | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/tools/objtool/Makefile b/tools/objtool/Makefile index 7770edcda3a0..614b87278260 100644 --- a/tools/objtool/Makefile +++ b/tools/objtool/Makefile @@ -60,7 +60,7 @@ export srctree OUTPUT CFLAGS SRCARCH AWK include $(srctree)/tools/build/Makefile.include $(OBJTOOL_IN): fixdep FORCE - @$(CONFIG_SHELL) ./sync-check.sh + @$(CONFIG_SHELL) ./sync-check.sh $(SRCARCH) @$(MAKE) $(build)=objtool $(OBJTOOL): $(LIBSUBCMD) $(OBJTOOL_IN) diff --git a/tools/objtool/sync-check.sh b/tools/objtool/sync-check.sh index 13e4fca28015..f01b5a4d12ac 100755 --- a/tools/objtool/sync-check.sh +++ b/tools/objtool/sync-check.sh @@ -1,6 +1,9 @@ #!/bin/sh # SPDX-License-Identifier: GPL-2.0 +TARGET_ARCH=$1 + +if [ "$TARGET_ARCH" == "x86" ]; then FILES=" arch/x86/include/asm/inat_types.h arch/x86/include/asm/orc_types.h @@ -12,6 +15,7 @@ arch/x86/include/asm/insn.h -I '^#include [\"<]\(asm/\)*inat.h[\">]' arch/x86/lib/inat.c -I '^#include [\"<]\(../include/\)*asm/insn.h[\">]' arch/x86/lib/insn.c -I '^#include [\"<]\(../include/\)*asm/in\(at\|sn\).h[\">]' -I '^#include [\"<]\(../include/\)*asm/emulate_prefix.h[\">]' " +fi check_2 () { file1=$1 -- 2.21.1