From patchwork Mon Sep 7 14:04:48 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bamvor Zhang Jian X-Patchwork-Id: 53236 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-lb0-f199.google.com (mail-lb0-f199.google.com [209.85.217.199]) by patches.linaro.org (Postfix) with ESMTPS id 4264022B06 for ; Mon, 7 Sep 2015 14:08:40 +0000 (UTC) Received: by lbcjc2 with SMTP id jc2sf25937091lbc.0 for ; Mon, 07 Sep 2015 07:08:39 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=dFkzERFgdy+Pxntq+jW25Y1lUlgag6NYjpnixtnCU3k=; b=dUJPWv7ijZUIrVaZg3fLES3tfSZG1J6VXqKk9eDEyBjFINeSd5sekYl8+r1t2eapAP AVJiuT/7q9eXmuq+WY8mdGE6Y/yrW84xtHUyQc7A6953dwbG23epFAPfIvbwsepN/hni 7Xny0wgzMlKQqw+4EW9CbkT+94hPWviLNWDzs68glyUwi0Z6jm6TLxXqGutO242tgHnu BSPNB/vFv+i+/jmkZrapoZIegMc3DR3i8AAwvW5ikPYyA//g8IMwftBOvEHb0VDIUYRf iRkm9w/rejSEAc+a28B9utUQHlpdZABYza5rTiMPJXZ6LttLfoWNwwsL7j/fcdRQ8Bl1 3rFw== X-Gm-Message-State: ALoCoQmZYZ+CgD27QcpPEvjkC7AQswZyrAI6JJ6l181wq2mlc5m0zXsnubETV/TdH4/C0hz+qeFO X-Received: by 10.180.90.106 with SMTP id bv10mr5108581wib.6.1441634918976; Mon, 07 Sep 2015 07:08:38 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.239.161 with SMTP id vt1ls530816lac.41.gmail; Mon, 07 Sep 2015 07:08:38 -0700 (PDT) X-Received: by 10.112.168.100 with SMTP id zv4mr16997294lbb.117.1441634918701; Mon, 07 Sep 2015 07:08:38 -0700 (PDT) Received: from mail-lb0-f176.google.com (mail-lb0-f176.google.com. [209.85.217.176]) by mx.google.com with ESMTPS id tp6si84137lbb.97.2015.09.07.07.08.38 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 07 Sep 2015 07:08:38 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.176 as permitted sender) client-ip=209.85.217.176; Received: by lbbmp1 with SMTP id mp1so39885456lbb.1 for ; Mon, 07 Sep 2015 07:08:38 -0700 (PDT) X-Received: by 10.112.72.97 with SMTP id c1mr3361379lbv.86.1441634918609; Mon, 07 Sep 2015 07:08:38 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.59.35 with SMTP id w3csp398485lbq; Mon, 7 Sep 2015 07:08:37 -0700 (PDT) X-Received: by 10.50.134.198 with SMTP id pm6mr31248924igb.53.1441634917475; Mon, 07 Sep 2015 07:08:37 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id dn2si20311220pdb.103.2015.09.07.07.08.36; Mon, 07 Sep 2015 07:08:37 -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; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751534AbbIGOIf (ORCPT + 28 others); Mon, 7 Sep 2015 10:08:35 -0400 Received: from mail-pa0-f54.google.com ([209.85.220.54]:35379 "EHLO mail-pa0-f54.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752421AbbIGOIb (ORCPT ); Mon, 7 Sep 2015 10:08:31 -0400 Received: by pacfv12 with SMTP id fv12so100480023pac.2 for ; Mon, 07 Sep 2015 07:08:31 -0700 (PDT) X-Received: by 10.66.219.227 with SMTP id pr3mr42553294pac.33.1441634911484; Mon, 07 Sep 2015 07:08:31 -0700 (PDT) Received: from linux-j170.site (ec2-52-68-133-70.ap-northeast-1.compute.amazonaws.com. [52.68.133.70]) by smtp.gmail.com with ESMTPSA id gh5sm12167908pbc.87.2015.09.07.07.08.26 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 07 Sep 2015 07:08:30 -0700 (PDT) From: Bamvor Jian Zhang To: linux-kernel@vger.kernel.org Cc: broonie@kernel.org, khilman@linaro.org, tyler.baker@linaro.org, bamvor.zhangjian@linaro.org, shuahkh@osg.samsung.com, mpe@ellerman.id.au Subject: [PATCH v2 2/6] selftests: only compile userfaultfd for x86 and powperpc Date: Mon, 7 Sep 2015 22:04:48 +0800 Message-Id: <1441634692-19494-3-git-send-email-bamvor.zhangjian@linaro.org> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1441634692-19494-1-git-send-email-bamvor.zhangjian@linaro.org> References: <1441634692-19494-1-git-send-email-bamvor.zhangjian@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: bamvor.zhangjian@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.176 as permitted sender) smtp.mailfrom=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Check it before compiling to avoid the failure of building and installation. Signed-off-by: Bamvor Jian Zhang --- tools/testing/selftests/vm/Makefile | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/tools/testing/selftests/vm/Makefile b/tools/testing/selftests/vm/Makefile index 1dacac8..925a82d 100644 --- a/tools/testing/selftests/vm/Makefile +++ b/tools/testing/selftests/vm/Makefile @@ -1,5 +1,15 @@ # Makefile for vm selftests +uname_M := $(shell uname -m 2>/dev/null || echo not) +ARCH ?= $(shell echo $(uname_M) | sed -e s/i.86/i386/ -e s/ppc.*/powerpc/) + +ifeq ($(ARCH),powerpc) +support_userfaultfd = yes +endif +ifeq ($(ARCH),x86) +support_userfaultfd = yes +endif + CFLAGS = -Wall -I ../../../../usr/include $(EXTRA_CFLAGS) BINARIES = compaction_test BINARIES += hugepage-mmap @@ -9,7 +19,9 @@ BINARIES += mlock2-tests BINARIES += on-fault-limit BINARIES += thuge-gen BINARIES += transhuge-stress +ifdef support_userfaultfd BINARIES += userfaultfd +endif all: $(BINARIES) %: %.c