From patchwork Wed Nov 4 10:03:05 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Ellerman X-Patchwork-Id: 11880119 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id EC77215E6 for ; Wed, 4 Nov 2020 10:03:16 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 989982225B for ; Wed, 4 Nov 2020 10:03:16 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=ellerman.id.au header.i=@ellerman.id.au header.b="X9jZQphO" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728776AbgKDKDO (ORCPT ); Wed, 4 Nov 2020 05:03:14 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59928 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727923AbgKDKDO (ORCPT ); Wed, 4 Nov 2020 05:03:14 -0500 Received: from ozlabs.org (bilbo.ozlabs.org [IPv6:2401:3900:2:1::2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D79B8C0613D3; Wed, 4 Nov 2020 02:03:13 -0800 (PST) Received: by ozlabs.org (Postfix, from userid 1034) id 4CR2KB2hxfz9sTK; Wed, 4 Nov 2020 21:03:10 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ellerman.id.au; s=201909; t=1604484190; bh=L1GBv73QytYJI/5pzM+dKFeWgUQ+ltUjUa2+CVaFVAA=; h=From:To:Cc:Subject:Date:From; b=X9jZQphOB1UPN3HBNOr0E3kt5wR++jemdLWJg+ewe+oEr6OA27EsdygKIZZ4an8ip qvc8NMnPjQ1M0WbWPctZ1iZqB7ZCR3GAzos4hEsiAHbVrhH/J5HFtlWoL6nUtoB23e e23UkDJuvP8sNXMemw+ePXNweNlhiYuTTP1AOiEfVRb5cfKzJzln2tzY5Z5b5s+zmN 73voxdlh++o3QcVz0MjjVRXBnBV+ApGDu1TSTXj9KrfGb/t3lhoTRXdxHpNALQlxSq PfyfBbLUEIg5HskJf/kXi67V+foEjw4XsAAEK6CqYf4ebF9Kp5s3messxHZInhThtm EqrJZJE8WZL+Q== From: Michael Ellerman To: linux-kselftest@vger.kernel.org, skhan@linuxfoundation.org Cc: linux-kernel@vger.kernel.org Subject: [PATCH] selftests/memfd: Fix implicit declaration warnings Date: Wed, 4 Nov 2020 21:03:05 +1100 Message-Id: <20201104100305.655720-1-mpe@ellerman.id.au> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-kselftest@vger.kernel.org The memfd tests emit several warnings: fuse_test.c:261:7: warning: implicit declaration of function 'open' fuse_test.c:67:6: warning: implicit declaration of function 'fcntl' memfd_test.c:397:6: warning: implicit declaration of function 'fallocate' memfd_test.c:64:7: warning: implicit declaration of function 'open' memfd_test.c:90:6: warning: implicit declaration of function 'fcntl' These are all caused by the test not including fcntl.h. Instead of including linux/fcntl.h, include fcntl.h, which should eventually cause the former to be included as well. Signed-off-by: Michael Ellerman --- tools/testing/selftests/memfd/fuse_test.c | 2 +- tools/testing/selftests/memfd/memfd_test.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) base-commit: cf7cd542d1b538f6e9e83490bc090dd773f4266d diff --git a/tools/testing/selftests/memfd/fuse_test.c b/tools/testing/selftests/memfd/fuse_test.c index b018e835737d..be675002f918 100644 --- a/tools/testing/selftests/memfd/fuse_test.c +++ b/tools/testing/selftests/memfd/fuse_test.c @@ -20,7 +20,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/tools/testing/selftests/memfd/memfd_test.c b/tools/testing/selftests/memfd/memfd_test.c index 334a7eea2004..74baab83fec3 100644 --- a/tools/testing/selftests/memfd/memfd_test.c +++ b/tools/testing/selftests/memfd/memfd_test.c @@ -6,7 +6,7 @@ #include #include #include -#include +#include #include #include #include