Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.9 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1B2D2C2BA19 for ; Wed, 22 Apr 2020 01:24:20 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id E7A99206D5 for ; Wed, 22 Apr 2020 01:24:19 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=fb.com header.i=@fb.com header.b="nCIiv++n" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726039AbgDVBYT (ORCPT ); Tue, 21 Apr 2020 21:24:19 -0400 Received: from mx0b-00082601.pphosted.com ([67.231.153.30]:52472 "EHLO mx0b-00082601.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726024AbgDVBYT (ORCPT ); Tue, 21 Apr 2020 21:24:19 -0400 Received: from pps.filterd (m0109331.ppops.net [127.0.0.1]) by mx0a-00082601.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 03M1J9Tw016675 for ; Tue, 21 Apr 2020 18:24:15 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fb.com; h=from : to : cc : subject : date : message-id : mime-version : content-transfer-encoding : content-type; s=facebook; bh=wbw+03kqAr4+0VBwg+Xhrq4PpfYJHMGxVN4suU9Mbc0=; b=nCIiv++nvKFhKh+R2Lb09S+eBmy9bMPW/17RPFbudNahdCM6Yjo9zwro5ayk/nl/+PRy hMh+ZdkEY9pSksaQd3gGBwWHzE9v3t/qM8psdc5kM6+4ZmnEpU1QGAinyMngmADry2Zg BMIu6dP5Uvf6KlL/U8V4ptlJLPmIeDPRQyI= Received: from mail.thefacebook.com ([163.114.132.120]) by mx0a-00082601.pphosted.com with ESMTP id 30fycfu68e-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Tue, 21 Apr 2020 18:24:15 -0700 Received: from intmgw002.08.frc2.facebook.com (2620:10d:c085:108::4) by mail.thefacebook.com (2620:10d:c085:11d::5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1847.3; Tue, 21 Apr 2020 18:24:14 -0700 Received: by devbig012.ftw2.facebook.com (Postfix, from userid 137359) id 237F02EC2E30; Tue, 21 Apr 2020 18:24:13 -0700 (PDT) Smtp-Origin-Hostprefix: devbig From: Andrii Nakryiko Smtp-Origin-Hostname: devbig012.ftw2.facebook.com To: , , , CC: , , Andrii Nakryiko Smtp-Origin-Cluster: ftw2c04 Subject: [PATCH bpf-next] tools/runqslower: ensure own vmlinux.h is picked up first Date: Tue, 21 Apr 2020 18:24:07 -0700 Message-ID: <20200422012407.176303-1-andriin@fb.com> X-Mailer: git-send-email 2.24.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-FB-Internal: Safe Content-Type: text/plain X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.138,18.0.676 definitions=2020-04-21_10:2020-04-21,2020-04-21 signatures=0 X-Proofpoint-Spam-Details: rule=fb_default_notspam policy=fb_default score=0 malwarescore=0 suspectscore=0 spamscore=0 priorityscore=1501 mlxscore=0 lowpriorityscore=0 bulkscore=0 clxscore=1015 adultscore=0 phishscore=0 mlxlogscore=273 impostorscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2003020000 definitions=main-2004220008 X-FB-Internal: deliver Sender: bpf-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: bpf@vger.kernel.org Reorder include paths to ensure that runqslower sources are picking up vmlinux.h, generated by runqslower's own Makefile. When runqslower is bui= lt from selftests/bpf, due to current -I$(BPF_INCLUDE) -I$(OUTPUT) ordering,= it might pick up not-yet-complete vmlinux.h, generated by selftests Makefile= , which could lead to compilation errors like [0]. So ensure that -I$(OUTPU= T) goes first and rely on runqslower's Makefile own dependency chain to ensu= re vmlinux.h is properly completed before source code relying on it is compi= led. [0] https://travis-ci.org/github/libbpf/libbpf/jobs/677905925 Signed-off-by: Andrii Nakryiko --- tools/bpf/runqslower/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/bpf/runqslower/Makefile b/tools/bpf/runqslower/Makefil= e index 39edd68afa8e..8a6f82e56a24 100644 --- a/tools/bpf/runqslower/Makefile +++ b/tools/bpf/runqslower/Makefile @@ -8,7 +8,7 @@ BPFTOOL ?=3D $(DEFAULT_BPFTOOL) LIBBPF_SRC :=3D $(abspath ../../lib/bpf) BPFOBJ :=3D $(OUTPUT)/libbpf.a BPF_INCLUDE :=3D $(OUTPUT) -INCLUDES :=3D -I$(BPF_INCLUDE) -I$(OUTPUT) -I$(abspath ../../lib) +INCLUDES :=3D -I$(OUTPUT) -I$(BPF_INCLUDE) -I$(abspath ../../lib) CFLAGS :=3D -g -Wall =20 # Try to detect best kernel BTF source --=20 2.24.1