From patchwork Fri Sep 14 09:46:58 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexey Skidanov X-Patchwork-Id: 10600587 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 34D2D15E8 for ; Fri, 14 Sep 2018 09:46:29 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1160A2B28B for ; Fri, 14 Sep 2018 09:46:29 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 055E02B2B8; Fri, 14 Sep 2018 09:46:29 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8B8A52B28B for ; Fri, 14 Sep 2018 09:46:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727726AbeINPAK (ORCPT ); Fri, 14 Sep 2018 11:00:10 -0400 Received: from mga11.intel.com ([192.55.52.93]:12179 "EHLO mga11.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726966AbeINPAJ (ORCPT ); Fri, 14 Sep 2018 11:00:09 -0400 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 14 Sep 2018 02:46:27 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.53,372,1531810800"; d="scan'208";a="91691968" Received: from kohsamui.iil.intel.com ([10.236.193.12]) by orsmga002.jf.intel.com with ESMTP; 14 Sep 2018 02:45:54 -0700 From: Alexey Skidanov To: labbott@redhat.com, shuah@kernel.org, linux-kselftest@vger.kernel.org Cc: Alexey Skidanov Subject: [PATCH] Fix compilation error Date: Fri, 14 Sep 2018 12:46:58 +0300 Message-Id: <1536918418-5016-1-git-send-email-alexey.skidanov@intel.com> X-Mailer: git-send-email 2.7.4 Sender: linux-kselftest-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kselftest@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP ionmap_test compilation failed because there is no dma_buf.h on any of include paths. Moreover, it's better to use the dma_buf.h file of kernel under test and not the currently running one. To fix this, add new target to the Makefile, installing Kernel headers for user space and direct compiler to look for dma_buf.h file there. Signed-off-by: Alexey Skidanov --- tools/testing/selftests/android/ion/Makefile | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/tools/testing/selftests/android/ion/Makefile b/tools/testing/selftests/android/ion/Makefile index e036952..a4aac0e 100644 --- a/tools/testing/selftests/android/ion/Makefile +++ b/tools/testing/selftests/android/ion/Makefile @@ -1,10 +1,14 @@ -INCLUDEDIR := -I. -I../../../../../drivers/staging/android/uapi/ -I../../../../../usr/include/ +INCLUDEDIR := -I. -I../../../../../drivers/staging/android/uapi/ -I../../../../../uapi/include CFLAGS := $(CFLAGS) $(INCLUDEDIR) -Wall -O2 -g TEST_GEN_FILES := ionapp_export ionapp_import ionmap_test -all: $(TEST_GEN_FILES) +all: usr_headers $(TEST_GEN_FILES) + +usr_headers: + cd ../../../../../ + make headers_install INSTALL_HDR_PATH=./uapi $(TEST_GEN_FILES): ipcsocket.c ionutils.c