Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp2464677imm; Mon, 28 May 2018 08:34:20 -0700 (PDT) X-Google-Smtp-Source: AB8JxZpVP9BwT9uTG//eQHuAVR0V4nPeL5BPgTXm1eo82CHzx6u8QAoNWaqRql6ih6NQ0XCYnUQn X-Received: by 2002:a65:665a:: with SMTP id z26-v6mr10637577pgv.302.1527521660755; Mon, 28 May 2018 08:34:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527521660; cv=none; d=google.com; s=arc-20160816; b=roCxHqoAqpERfGAc57QM8zO5gSFL7dtxe/FiZARdBWA9XRcEY6TuB/urn3+/jtMlKZ OL6QfLA33bqrGIQ/mJWwdnsAJErL5gZmrhyjxfJw5C42IIRq2HFZF/8l6dYWNE7l2+nL mjzBV22GXHjcqOuIFprIH0gnzEvwMazt5KxF24FQYvH+tRtnX4izYhTCjRQ7tAs0NUGR ogpxkaIK6fS186+aYiAWO7SCKd6claYC9pav/CXPkKQk0ik0uHrh0g6MFi1D8UygSlFg BkR5LtaVA6QZat/k4qX14wOp25eENRvjSDwd2fxvP/KBwi2MINTm6KsmS17hV62nS+ps 7ucA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=OOvqutJ8aN6E4t94vED6uCwLFSXM7QSNxOsEaihPWmU=; b=KXBPuNaLmPAmmRitWEesIVdqjwl6o2hq23PLNhe7PtdByj/RZpoUMXPdyB28/kAhv4 IG1e9poxBEfMkQhkHg/wUia4WuyVXSw89nYCP6HL+4mfO2IS0kbrSPZmwlcxX5thOI2t assJLoWA5DMiqFHoDW7A0wfgi7Fmg3hOjTxBpMrOURkuhIIOHX+LMbC3T47G6FktK6R3 UujF3mx2kirvlOhMmbxz63jYpyPA/RhkyRK9HWYe6sGn050pt3wTDd+eGVM4FwTER4px CWHIQrO+Wx/bu+/8NzvpEPCm4OKTXGR/oG5H1G8FPYuL7jHDkNZKoMps4rsaYD+Icr4i wwVA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g7-v6si30505881pfg.264.2018.05.28.08.34.05; Mon, 28 May 2018 08:34:20 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1034509AbeE1Pd2 (ORCPT + 99 others); Mon, 28 May 2018 11:33:28 -0400 Received: from mout.kundenserver.de ([212.227.17.13]:40771 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1032932AbeE1Pcm (ORCPT ); Mon, 28 May 2018 11:32:42 -0400 Received: from wuerfel.lan ([95.208.111.237]) by mrelayeu.kundenserver.de (mreue102 [212.227.15.145]) with ESMTPA (Nemesis) id 0LilTh-1fte8u3z2r-00cwss; Mon, 28 May 2018 17:32:30 +0200 From: Arnd Bergmann To: "David S. Miller" , Alexei Starovoitov Cc: Arnd Bergmann , Masahiro Yamada , linux-kbuild@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] [net-next, wrong] make BPFILTER_UMH depend on X86 Date: Mon, 28 May 2018 17:31:01 +0200 Message-Id: <20180528153222.2037158-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 X-Provags-ID: V03:K1:ivnaRPfIEFtNNJ4kQMM7qjepuTZcsTkjMrVsVlMufh+C95dLyf6 94y1kCbDQXiPqNkEx4l0q7FSSuIgL3Z0X5aR+zeQWziBO3TFRjXXTNq6/NGYTi2wGLrrZfn DAswGdlFyYMZdMzGg8jBAouNMOit0ARQaGZTpkTOSX3kVsqUL2PqCrXb+085lFvHtWswJ71 CalneFaRZBO7WloJZ58Dw== X-UI-Out-Filterresults: notjunk:1;V01:K0:NT5PdMcGH9Q=:G7frivC4faYB4eQKitWU/O 2PnP5iaH6YqIBlkJ7xNd267i+DidTNjmSTj2Wvelw5HuQarJ22BBtrgc0wqZSieEqqlUuyDXy sx10cgo54XhOhPP+AWNKUnNfls7NJrUw6aYbkyOR6yX8vwFJQz6s+bgELrKEffIvnBa5FCDCJ tO/D55H5Fd31yTLgtxYvDJdqoSnuB6MQINdWVz1HiqvMgxwGqndQtjTotZO7PBl1rx+1bgiBP E/sqBF0qw2G5kc1++tHupBr2V2ASWx5Z4IXoUAu4KG+3X6ef5WpVIPv2F5qwP7kgaxzY10l7W kpzRMzCPGAWR/W9oB2ZEH9haQAUwg9t6VOkNRqPbbGSlSFnArZ25qLwYjvgo457S1aZbH5s8W CyezT8mB7FD1aTIczhP0EPGb0l9lvkYXBmHffQiihZXMV8KNBI3kvfrn1fwX14a0FRlUE5hYx PSuWzmXM9S6lgS0GpUMM92B4g9ZU0clCl7fkyQMpfKF1DJlhbavlwasE4hSgwCgBPZd39AzMq wf2LZe8//ECqbwJlhWCK1VShqMlSE8bSYdIsYjnp5KlGn1/L7YuN7aNhU5bR+9XMOdGD0vVSt 3oIlt7LNslbEAf2YN3xnU+KXpfK4DCSWOxwEg7xEVn+PHcbsPqCPvyNbuZtzyaf61v+Nv3d2d iUjuqnmQdsXldMkUjDHITDCh1YVPhk6h+px95irdIjzFJlx2lxElF9Kpt9U4N6FqD5z0= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org When build testing across architectures, I run into a build error on all targets other than X86: gcc-8.1.0-nolibc/arm-linux-gnueabi/bin/arm-linux-gnueabi-objdump: net/bpfilter/bpfilter_umh: File format not recognized gcc-8.1.0-nolibc/arm-linux-gnueabi/bin/arm-linux-gnueabi-objcopy:net/bpfilter/bpfilter_umh.o: Invalid bfd target The problem is that 'hostprogs' get built with 'gcc' rather than '$(CROSS_COMPILE)gcc', and my default gcc (as most people's) targets x86. To work around it, adding an X86 dependency gets randconfigs building again on my box. Clearly, this is not a good solution, since it should actually work fine when building native kernels on other architectures but that is now disabled, while cross building an x86 kernel on another host is still broken after my patch. What we probably want here is to try out if the compiler is able to build executables for the target architecture and not build the helper otherwise, at least when compile-testing. No idea how to do that though. Link: http://www.kernel.org/pub/tools/crosstool/ Cc: Masahiro Yamada Cc: linux-kbuild@vger.kernel.org Signed-off-by: Arnd Bergmann --- net/bpfilter/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/net/bpfilter/Kconfig b/net/bpfilter/Kconfig index 60725c5f79db..61cc4fcbb4d0 100644 --- a/net/bpfilter/Kconfig +++ b/net/bpfilter/Kconfig @@ -9,6 +9,7 @@ menuconfig BPFILTER if BPFILTER config BPFILTER_UMH tristate "bpfilter kernel module with user mode helper" + depends on X86 # actually depends on native builds default m help This builds bpfilter kernel module with embedded user mode helper -- 2.9.0