From patchwork Thu Oct 17 21:05:51 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lorenzo Stoakes X-Patchwork-Id: 13840820 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id A6CE4D3C534 for ; Thu, 17 Oct 2024 21:06:38 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 40F886B008A; Thu, 17 Oct 2024 17:06:38 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 38A466B008C; Thu, 17 Oct 2024 17:06:38 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 169166B0092; Thu, 17 Oct 2024 17:06:38 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0014.hostedemail.com [216.40.44.14]) by kanga.kvack.org (Postfix) with ESMTP id E38426B008A for ; Thu, 17 Oct 2024 17:06:37 -0400 (EDT) Received: from smtpin01.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay08.hostedemail.com (Postfix) with ESMTP id E73F2141686 for ; Thu, 17 Oct 2024 21:06:25 +0000 (UTC) X-FDA: 82684327572.01.1230432 Received: from mx0a-00069f02.pphosted.com (mx0a-00069f02.pphosted.com [205.220.165.32]) by imf05.hostedemail.com (Postfix) with ESMTP id D10B7100006 for ; Thu, 17 Oct 2024 21:06:14 +0000 (UTC) Authentication-Results: imf05.hostedemail.com; dkim=pass header.d=oracle.com header.s=corp-2023-11-20 header.b=GKDEfDDg; dkim=pass header.d=oracle.onmicrosoft.com header.s=selector2-oracle-onmicrosoft-com header.b=oBelhuZD; dmarc=pass (policy=reject) header.from=oracle.com; spf=pass (imf05.hostedemail.com: domain of lorenzo.stoakes@oracle.com designates 205.220.165.32 as permitted sender) smtp.mailfrom=lorenzo.stoakes@oracle.com; arc=pass ("microsoft.com:s=arcselector10001:i=1") ARC-Seal: i=2; s=arc-20220608; d=hostedemail.com; t=1729199146; a=rsa-sha256; cv=pass; b=TaIlxW4f2n/lxvukHePBMaEzOb1JqxZAM8UloOOD0nf8A+0xOOavrTsXpMxVsnVXlNQx/1 eX/2vIWSMfbknnTyzhPsmJcfeYni9pLoUaXvYomBpAduKdbyaFqDPzxEf8aQwjvfvUle1U crtre2XmKKOt+dFssL7JIVDoiieRnLk= ARC-Authentication-Results: i=2; imf05.hostedemail.com; dkim=pass header.d=oracle.com header.s=corp-2023-11-20 header.b=GKDEfDDg; dkim=pass header.d=oracle.onmicrosoft.com header.s=selector2-oracle-onmicrosoft-com header.b=oBelhuZD; dmarc=pass (policy=reject) header.from=oracle.com; spf=pass (imf05.hostedemail.com: domain of lorenzo.stoakes@oracle.com designates 205.220.165.32 as permitted sender) smtp.mailfrom=lorenzo.stoakes@oracle.com; arc=pass ("microsoft.com:s=arcselector10001:i=1") ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1729199146; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=RAj91Ze6DG6ZBIncneUlpECDpYuSfR7OmBgoH5NyN2A=; b=0sIMKmqZqki7mx5lWRwU2Mi87oRvXUF0eQYg+l5pojW/l4LI9Sf6/dIJEOchNyRPwo1r88 a46lQC58SylsQtRsmTJnR9MvEiX1qEupjN1ID+GGlt51SYLN0BI9Nexnbgri5/vl2RTyeF W5GS/A/0Nwv3GYSYGgPjd1n1ILtiiIg= Received: from pps.filterd (m0333521.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 49HKtouD006183; Thu, 17 Oct 2024 21:06:24 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=cc :content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s= corp-2023-11-20; bh=RAj91Ze6DG6ZBIncneUlpECDpYuSfR7OmBgoH5NyN2A=; b= GKDEfDDgnRW5oy6HuqvhNVU3j7ZupC4KaWIyJ58j4c4GcvxEKnBkyuhYbdIHEHtX BWiGFHll5t9USxYj9lSESKO37CFSQQ39EyJVUjakow1XsCU7LHDLVJzlGkw14otO u9lK+xdkV483YiCbPnWlejJXpN69jgsUzLCTgWp+tXKwxu+rmsV9RPyLaXZt5f7P IBu0nCD63fwsK4HyTGxycaXCjXgY5j1JpC32diOdMbD1VUryLiztG9PO4+6+fsOt i33d6k/hgTGG12kpSZThd4R+lpTxkqAFKRHpVXYumSkSQriiv+klYiGyjRgnRMjc rrqRPTee++9tNDuKhTheOw== Received: from phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (phxpaimrmta01.appoci.oracle.com [138.1.114.2]) by mx0b-00069f02.pphosted.com (PPS) with ESMTPS id 427g1aq7jx-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 17 Oct 2024 21:06:23 +0000 (GMT) Received: from pps.filterd (phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com [127.0.0.1]) by phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (8.18.1.2/8.18.1.2) with ESMTP id 49HJCPJN027100; Thu, 17 Oct 2024 21:06:23 GMT Received: from nam12-bn8-obe.outbound.protection.outlook.com (mail-bn8nam12lp2172.outbound.protection.outlook.com [104.47.55.172]) by phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (PPS) with ESMTPS id 427fjasv4x-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 17 Oct 2024 21:06:23 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=PoPxUWIX+iQQfApnyfcWtYEHo4jGlX1ukmoEVgfFtdus+EJah3qUS365jVWls2WOheG0ajmxpnre0Xkcxl7gCH2wzbXiHto40RypPVDjys9Cy2DhUBmWkVQrYOfAtRAytQqXLR/6qbgZSyj8B7OX/slbwmEevAOrbU54+XkVTxkGof+UGvRpKm7rSZ8f64tSpyXEiqKKiEBaHExas8PVzxKT71RIDa7bP/mowDJ/W7k9dEUN51q+y57R/uYFNixtzZf0wJ841Dqn7WHI7GIjQuRGj+Uj3qj34GUCUsd81nJUnBB8LlTooIOoi23jwm1LAfJTCRBu0cblrXGaG+8mog== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=RAj91Ze6DG6ZBIncneUlpECDpYuSfR7OmBgoH5NyN2A=; b=kSA1EoHHY/lf66jTFOyPAL6mOcbD/lsz802utbcYWFVQAtsb5HLZ9+erFNmxHerHPQAphnj0IpIO0u6RxhjW0MtPXkdKx4yy+EZzyKavmoP6IZOkkycsSJ6S8AtWRpZNIwYdPMjya7L9T9F53ar+xfC9BMelFTCyMeMm6MKOC2ooOAa1nfazAn+TRy7TQxOIaIOR2SlvQ2J/R23KHzzXC/uNxtK/yWOpubWdLQL8ZOpToDQxJzeqXdNSe7lzgZMR2uV0M3Ayr5v2HM4K/INBtp+R4Kwr7iWRed4HDBil3Cg9BD4HcfnCHMfKJovKMCj3jGfS54o0v+wJZUPyxCDlww== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.onmicrosoft.com; s=selector2-oracle-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=RAj91Ze6DG6ZBIncneUlpECDpYuSfR7OmBgoH5NyN2A=; b=oBelhuZDQ8zujMrfc3PM5Pqwp3yoHjcA3ZOCAMUdCmjVJELNj9Vez0oyv0msg7+NYIBnjDb4NZxXDFt2x5FB1cHlrRuOro3Ug1P+I7lMrqGUMAH0572kx3kmygRKvDIOPPDGEpJy9H/VJIQ70qWsl5LzC7kUxp4Ur2HnYERw6bQ= Received: from SJ0PR10MB5613.namprd10.prod.outlook.com (2603:10b6:a03:3d0::5) by DS0PR10MB6752.namprd10.prod.outlook.com (2603:10b6:8:13a::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8069.18; Thu, 17 Oct 2024 21:06:20 +0000 Received: from SJ0PR10MB5613.namprd10.prod.outlook.com ([fe80::4239:cf6f:9caa:940e]) by SJ0PR10MB5613.namprd10.prod.outlook.com ([fe80::4239:cf6f:9caa:940e%5]) with mapi id 15.20.8069.016; Thu, 17 Oct 2024 21:06:20 +0000 From: Lorenzo Stoakes To: Christian Brauner Cc: Shuah Khan , "Liam R . Howlett" , Suren Baghdasaryan , Vlastimil Babka , pedro.falcato@gmail.com, linux-kselftest@vger.kernel.org, linux-mm@kvack.org, linux-fsdevel@vger.kernel.org, linux-api@vger.kernel.org, linux-kernel@vger.kernel.org, Oliver Sang , John Hubbard Subject: [PATCH v4 3/4] selftests: pidfd: add pidfd.h UAPI wrapper Date: Thu, 17 Oct 2024 22:05:51 +0100 Message-ID: X-Mailer: git-send-email 2.46.2 In-Reply-To: References: X-ClientProxiedBy: LO4P123CA0623.GBRP123.PROD.OUTLOOK.COM (2603:10a6:600:294::18) To SJ0PR10MB5613.namprd10.prod.outlook.com (2603:10b6:a03:3d0::5) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SJ0PR10MB5613:EE_|DS0PR10MB6752:EE_ X-MS-Office365-Filtering-Correlation-Id: 2b3013cd-6f7e-4ad3-ff23-08dceeef8c68 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|7416014|376014|366016|1800799024; X-Microsoft-Antispam-Message-Info: RqKf1QYas7BIecVfRckVuMTQIHcH6rD0MESHQq5Rw4jdOsP89TsRKsqy7aOw+BwftWubpqjYcBEcnZyBYUcROxEwihBKxtf0oruKj9ct5s8HPp+fml+8g2Wq3dpYfLuvsWNjfVuIVRkRXzN099BgALqS7qAj8Ad+W4WOQjwbT3xS1FPTarrkCjbp2mBMEtUVEXqXUclCNtFtVrmyGivUtNS+Dtc0PvSBKKBGw2NNU/cnud9a9+3Jcc49hEfA2hWGlfQcUmqgs4m4fwoIzd0hMNyZXsV60S8ulQr/nW2GNFcq60lsNHYGIW1nL1rnfaHJQ6NAZIJICINyGuYIKH4BAX6/Lrldhij+rPc1McwOOrzw4eTbQD6SBhQTBHJBIVg7t2zb7r1xELqA6qIhO0jTf4+BybKaE7cjFtQzzfLzcFggs97cR0M6hcxtKhmSFK+rNoefOWrKMrFGmzrc1yvk6jTzH2/ADJ6sNwsuhUYx3sIUHNuFHycl6jLCW0cLBKQBKeSIZ8/nt0l4K9X+pzsI3jyA6toTrB24f1PJbO5plgV47/nYSwSAlcglAxVefL5TFG63NI6Y4Hua8cIgYdT+0dYsRwgG5KLzjqW7wFNDkIf5IlBDwcZABObhwgrqHCj8WKk0mxXnZeFPUUlH2gKY5FmfZYogcFSau4rjjhHnMIFzHnl9ocr+9xp3Kv7ESgKzmgUrIT7KDkGLnKBraSK40PXsr7rAnIkf99TJWkxXCkIvI/qo9zToDD8WSGWzTSM5gt3EKaVUldmkbAxw3vh0FvBieEyeT0Uy/4BalG+o4mGFW55Ki7enj76/wE7p5UX07voD4l20Yn+VbNZGCWNLsZmmq4RL0yvVTMESHe17NgejCAFZhtr/zlWIEj2bfLsueJTC3KJGTu9ku5smjE4qYYbOCGPU6+tpRJAMuLfQNeaK4BE5ZMsgsq+ZwDwdyFqqDHNsBtz4F9zpsyWyWkbiDJSeUXfEr8yLjxvll5Maq0mqrtKq+Ci4275Y24wKSn5Aizl2Pthizd+WaFifhCmCVVnbD39i0IUdDRRqiBovkDuRDs9wDUt380ivTdeEqeszUaj9r1uKfBHwLjhmm12RttsxAPlSaH+WuCMa1pIrAcqvgix5e0N6KkNSpgMKQ7m1/4F6yIAdX1/FW+F0iqXW5eVtVGyeNECria/dFJKLj0ZtGC94KXtiCIEEHU0T+PxRfhNWCKQ0P99jvRuQSzIksA1pXm+u5USzOuyVJVEmCmCN3tvukAw8G2viXs8Elq+n0/gX3kKM+L3ENTFaMZ65PVligI7UDIbBVabnDbksrEfcU1oW6Pn//zaALz8y1nAM X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SJ0PR10MB5613.namprd10.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(7416014)(376014)(366016)(1800799024);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 4m/lJtGrkyAwkMjaIof6g4tDrxuHn52fi3utolCacQpNGkRfw5mAEs+qFh36vNfvpagj1HLTKb+N+73fQKfXPrCn1OmA4v62SQWF5LydEXuRhNPI8a7oSxfUX6Jh9xT9W4gm2Ci6J8rTtdMfiee7qOUF784vruG7pJ7UGwUROoA7jJN9HkfA/8bNeGp2cXFuzFRe7Rfh4OKy8Hw2o1KxJizYw6SY17Vi4PNzMMEHu+2rw9l0PDqXke7PdEBBYs0rwlCwvuRaZpkVENjfs6Xe/lsqKe6N2fbQ99pFe7G3sUc1xbISV+xEn5Dy579MitR+tp9xCVRCiTc2SaX45z5aI+59kZ8bN09J+MSLPG9/goZ+mub3toWAYcw3jKteL48I25uXVsH0e6C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FYtdROwHgLKYObt1uNA4G6bVT4QA4yxCQXrkITI86UCRgAwScyfdf3IRMgm70x034FcX3ZeQfVsV8/7KgHG2sPgECbP++xMArmDD7SBPA/QxeJpADHaocLx0Cv4txgomShJSFxVXSfiUpzxIQ== X-MS-Exchange-AntiSpam-ExternalHop-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-ExternalHop-MessageData-0: QJ8WPDqxO1N4MoNP+8oZT3tG3hItR3uq7m29+f87I7WVZ2P3zwfnD4svTPUJXnLXpzf5BHljwZ2k9i2b7Al1ShzLb7Hghw37tfGNEa7LCSR/21a68YUbVHYLOj6OYTfgfgqgN9XcTd27009d0yC3Qe1WC+ZlxLja4e5PZqQZTKxNNjUtr4sKCEKdGim9Y244+GLXT85dN02d/IZQJYoP6SEl3IsSzLxLVt7wSjuAQeb/kd/nJxC6Pi+6bZbt239l5Yw3z6nS9mFypy9zlLQdVJJpkZGsi/dMaqnKktsOf5gjBN5gndr/Gbw3UDzXin3k/bg2Uj2nSckzcWfX+/5CEoHN4sp8kRRO+5gMW+TaQNJszJHBReFIqtTaFw9utru+ie0AkmTmA+L2WD4tZL2axiiYUPBPs9+7AvkgRj9nW1OZKE7O1XpUt1baUWn7fBQBtJTtOOcIISFz4WFvKMNo9Pn8RI8DjXkd9OD5zv+vUbSp1OBycvOKO9+5gEF8rJ0c80rA5P4YGZjTUPdhTs/xPtsUWdMjfSAt4zpT5riC0Q4kf+uOCMjPbBU2jxldKRUn3etk4fsmNc8pFbwXCgPy7a1dPwbKyC7O8t3FAYfSoNE= X-OriginatorOrg: oracle.com X-MS-Exchange-CrossTenant-Network-Message-Id: 2b3013cd-6f7e-4ad3-ff23-08dceeef8c68 X-MS-Exchange-CrossTenant-AuthSource: SJ0PR10MB5613.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 17 Oct 2024 21:06:20.1247 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 4e2c6054-71cb-48f1-bd6c-3a9705aca71b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: gbs/DS9dSnzTCf9tiVROuPKvCvuz8e5xiY7UUoGBxsxogX1qoha49qga5tRCg6+5qjognsQD35oDdWXqHY3ttydc17JMCRL8M7MnF0i+Ptc= X-MS-Exchange-Transport-CrossTenantHeadersStamped: DS0PR10MB6752 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1051,Hydra:6.0.680,FMLib:17.12.62.30 definitions=2024-10-17_23,2024-10-17_01,2024-09-30_01 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxscore=0 malwarescore=0 adultscore=0 bulkscore=0 spamscore=0 mlxlogscore=999 phishscore=0 suspectscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2409260000 definitions=main-2410170142 X-Proofpoint-GUID: dgD7fwfNYYOyQbS51OITWB6zwyI9qkjK X-Proofpoint-ORIG-GUID: dgD7fwfNYYOyQbS51OITWB6zwyI9qkjK X-Rspam-User: X-Rspamd-Queue-Id: D10B7100006 X-Rspamd-Server: rspam01 X-Stat-Signature: 6gx56dc3gtzezkr7q7y763tfh3yd4jd6 X-HE-Tag: 1729199174-119410 X-HE-Meta: U2FsdGVkX188qhljH1gIIqSacvuyO55uMyZ3m8/59nh7mRaKQ35GMZSNdhSMPfxlTwyxsfErSHL3HxH+vmlPjh88zPIIh3uPhIiFGM3lI7Y69C9hiS76i/75Dpco9yhai6+iESjxeMhzw4qqNlIBgEfzyon/zGNJdZdfC4rlHSSjq1tX1MfpdT5sEn+ncZpMrMEQN3SboE+Gww1AI3ZkbZVhcCxvd2Kz+XTgqxOxXgl4OppvpnZouH5J+7h/8VwNhB9io45a52rKlhY8ew6SXMPqDysB28hfyslGzZDYpxgP/v3ptJcs+suLJxgpwBSElZFuouQL8NcGvo3OgwTbXudoyjl3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wFo4XExj4GDKPyTQlChnweYUsIpWpX6TZN211E8EHQRsc3UXrx4T3X20INV7+yjaCNFItE4PMGMIiLoNkfWeMqhehWnH1BR3dA0+gepR6Vz+vbOVJJtDNkCTmCrhwyo2XLZhngUyTiZzHdSEdQi7JEZ7J9bDWAbtsTWuzcuT9zmUfI3mCiINqJ9x7pah28719HnNuNX8QRuv+o2Ap+5MgRRIfZWdWRQ= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000015, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: Conflicts can arise between system fcntl.h and linux/fcntl.h, imported by the linux/pidfd.h UAPI header. Work around this by adding a wrapper for linux/pidfd.h to tools/include/ which sets the linux/fcntl.h header guard ahead of importing the pidfd.h header file. Adjust the pidfd selftests Makefile to reference this include directory and put it at a higher precidence than any make header installed headers to ensure the wrapper is preferred. This way we can directly import the UAPI header file without issue, use the latest system header file without having to duplicate anything. Reviewed-by: Shuah Khan Signed-off-by: Lorenzo Stoakes --- tools/include/linux/pidfd.h | 14 ++++++++++++++ tools/testing/selftests/pidfd/Makefile | 3 +-- 2 files changed, 15 insertions(+), 2 deletions(-) create mode 100644 tools/include/linux/pidfd.h diff --git a/tools/include/linux/pidfd.h b/tools/include/linux/pidfd.h new file mode 100644 index 000000000000..113c8023072d --- /dev/null +++ b/tools/include/linux/pidfd.h @@ -0,0 +1,14 @@ +/* SPDX-License-Identifier: GPL-2.0-only */ + +#ifndef _TOOLS_LINUX_PIDFD_H +#define _TOOLS_LINUX_PIDFD_H + +/* + * Some systems have issues with the linux/fcntl.h import in linux/pidfd.h, so + * work around this by setting the header guard. + */ +#define _LINUX_FCNTL_H +#include "../../../include/uapi/linux/pidfd.h" +#undef _LINUX_FCNTL_H + +#endif /* _TOOLS_LINUX_PIDFD_H */ diff --git a/tools/testing/selftests/pidfd/Makefile b/tools/testing/selftests/pidfd/Makefile index d731e3e76d5b..f5038c9dae14 100644 --- a/tools/testing/selftests/pidfd/Makefile +++ b/tools/testing/selftests/pidfd/Makefile @@ -1,8 +1,7 @@ # SPDX-License-Identifier: GPL-2.0-only -CFLAGS += -g $(KHDR_INCLUDES) -pthread -Wall +CFLAGS += -g -isystem $(top_srcdir)/tools/include $(KHDR_INCLUDES) -pthread -Wall TEST_GEN_PROGS := pidfd_test pidfd_fdinfo_test pidfd_open_test \ pidfd_poll_test pidfd_wait pidfd_getfd_test pidfd_setns_test include ../lib.mk -