From nobody Mon Jun 8 11:02:52 2026 Received: from mail-wm1-f46.google.com (mail-wm1-f46.google.com [209.85.128.46]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id BAA51384CCD for ; Fri, 29 May 2026 17:27:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.46 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780075670; cv=none; b=Xf9qAfNjhUln9PY54zVgTt+s9pSplIBwHT0OFiNfxOngR7MJqWHZ0oz7lZG0ihhjflnNoPVceJoDwRarcVqkW86OedPp2ceJgn0BU31lXVH0DcoR53FBQJ5MwnBc1aJnh23zeKZ4PHiMVCyEk13lA9FIk9xTQn1Dw/jCOAJFvhg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780075670; c=relaxed/simple; bh=fAktiUpSZP15Q/bKIpxU0tnb6CaSxI63AleOteLRFhg=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:To:Cc; b=HS3pQDGz6E02xepN6dUks4Q2b6Xd7qkhhvniq1wAUm7MPiebC3Si8n6CW/4qGKYSN3avMkFcoB1jwTwqe8+1hsNr2oJPP94RuRV79kzdMDgFfF5+38RHmDaxuNo4ziye2anf6K8VeOBeY12LNlc2uhL5aoQQ8fBOvYC69/ESAVo= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com; spf=pass smtp.mailfrom=google.com; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b=EBpgZLY3; arc=none smtp.client-ip=209.85.128.46 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=google.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="EBpgZLY3" Received: by mail-wm1-f46.google.com with SMTP id 5b1f17b1804b1-4891b4934ffso5535e9.0 for ; Fri, 29 May 2026 10:27:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20251104; t=1780075666; x=1780680466; darn=vger.kernel.org; h=cc:to:message-id:content-transfer-encoding:mime-version:subject :date:from:from:to:cc:subject:date:message-id:reply-to; bh=85ALWsPr3bven76gnOdRecqCaNgtkddpS3RLL8wWr8o=; b=EBpgZLY3+njr7il5nsigIQB3SetWHoIf5y3+l6LmmCToqPszw/W9IS+bbMowu+WxVN Xy2bsH6SJFbdoi7HslcHby6knh4y69gW1jE1/VgobbokfvyT2VXk4pV7eNh3RFc2cKPa zu+WOYKoPsixLw6u4ZCmhuxj+7JBczK8pYos49uvJiM3e7/BA0G5ANAvWcddEQNtAlPf ubDcwi3m4DG4WQII+0so3ZHwV5PQUqWgttUTA/0wV8okzbxloUVxcgXpjEitTiTyr8aK MA8LeaEwsUwM1nO9z2wVaIQZTngnf4IAlka7n77PNKLCJA8Zo5H6QekLEw8n2oGDbSM7 MaCA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1780075666; x=1780680466; h=cc:to:message-id:content-transfer-encoding:mime-version:subject :date:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=85ALWsPr3bven76gnOdRecqCaNgtkddpS3RLL8wWr8o=; b=oBbwTcTGbRuX9m3oFowCKBbgycD1dTMz7QT4GLKuUnmQfu4+ILyvvJSgZaUd41rs1P mprQJb9IfXqXIwti6NJXiUNEvbQQ6RTYjhioA2y1BrNXiD9KRb/2p6xZidD7f4va6qv5 l87c1x2a5CkQFlvFCq7qZ728saeFMyIR6Dn7cADIkovf5hAXnloaBUBavFpDG3sZduhR 7bmzJ2S0d/V6X+wOJcFJtp0I4CI6sxpOtso1/NF9wzF4PyBr8NoO25fIjJJpSl3XqJRn 5aqvN7WxCsxMqcXmnqmpqzxUf0ruxglqKUISRqT2EI0HvLtmPr/FRWPpVfZ2qHl/KpfK h8YA== X-Forwarded-Encrypted: i=1; AFNElJ/3jVRFA7SjVeW9NJP2QG1ABYIF7aKxq0g6E8mSoRSGTHShgFR8FLPb1HkMIxulBQqDxhCrXNjqqWwbSs8=@vger.kernel.org X-Gm-Message-State: AOJu0YydXZ0pxX4cwF2o/dS8PmaAXXtSFqtpfq+EqO3Zw8ua6hrsWuw1 ETX/h+N/QvjajHBwZ4zO4EjrtQSG0ZAp5jNrfhgjoKG7TqflbUfO9QcxKVMJyxX2AOMuGEPYXNY 7i6g7sr5X X-Gm-Gg: Acq92OGfJBrBRP6nEEB0jgwS+O9I0godpMwY+bJ0Ac8Bflg+BfIDPBdNai2gwnYXSIp mXOROugYVstG6+CMBvocqAS6soH0eJC/P8/8h+9xrXIKYatVKAGT/CzWMxrU47pYYsIkxsLTEST XwL10WAZsNYYqQtDNLiv0tN/4pVjWzcg5STT9nACP7SORRpj+t23i1nxI6tyUbK98l0gw+qc1wm iJBfq06raXzB852dSSQLeSB54oHAW85CwlwHmBJ/6z/L5qUHW/M7L5dvkXcEXDxt/bK9Fd1bbXW t4k/ldUk3TUEaRLMQGseW7zh2iY3f0nYufzQxpcMdDHxMGCmw8+4gHiTbdx7s/uxSGOkPZx8bfr 7RrM8PH2Nwgl9wxUgjukkJpOsNutLCt3upsRKeQ8yRSZwtjmqnT4yED3dp4rUuqOrl3UVq9/23i X0xUsbekF6oqp/wHOkZGJ0l37L95Y1SVYuQeCClPFtCF9TZFeSqBos92MLSjaz X-Received: by 2002:a05:600c:8a0d:20b0:47d:1e65:e841 with SMTP id 5b1f17b1804b1-490a2d38b01mr1535e9.9.1780075665742; Fri, 29 May 2026 10:27:45 -0700 (PDT) Received: from localhost ([2a00:79e0:288a:8:d743:bf7b:2a4:a9a2]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4909c0b8a11sm18620525e9.16.2026.05.29.10.27.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 May 2026 10:27:45 -0700 (PDT) From: Jann Horn Date: Fri, 29 May 2026 19:27:39 +0200 Subject: [PATCH] man/man2/fanotify_mark.2: AT_FDCWD plus NULL path doesn't work Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260529-fan-mark-cwd-v1-1-cdfb3b5b6d7c@google.com> X-B4-Tracking: v=1; b=H4sIAIrMGWoC/6tWKk4tykwtVrJSqFYqSi3LLM7MzwNyDHUUlJIzE vPSU3UzU4B8JSMDIzMDUyNL3bTEPN3cxKJs3eTyFF3DZHMzA0MDs9S0NEsloJaCotS0zAqwcdG xEH5xaVJWanIJyAyl2loAJGpbGnAAAAA= X-Change-ID: 20260529-fan-mark-cwd-1c760106eff9 To: Alejandro Colomar , Jan Kara , Amir Goldstein , Matthew Bobrowski Cc: linux-man@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, Jann Horn X-Mailer: b4 0.15.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1780075660; l=1197; i=jannh@google.com; s=20240730; h=from:subject:message-id; bh=fAktiUpSZP15Q/bKIpxU0tnb6CaSxI63AleOteLRFhg=; b=hJ5GktEo+vJE7QpLWOYRXPPB5iwKBbBqD8iZUaDnywVjF1mwymGbV/ip3JMGKU3iYtYqsl9ye eC7zM0ArIzHDJSpUt0GJNM4eqgoq9A2tLOyFUVkIf8vE9ncoRKTNjwg X-Developer-Key: i=jannh@google.com; a=ed25519; pk=AljNtGOzXeF6khBXDJVVvwSEkVDGnnZZYqfWhP1V+C8= The fanotify_mark.2 manpage claims that AT_FDCWD works with a NULL path, but there is no kernel code for that - in fanotify_find_path(), in the `if (filename =3D=3D NULL)` block, the fd is only used for a normal FD lookup. This was also already the case when this manpage was written back in 2014, so remove the bogus documentation. Fixes: c200b422d ("fanotify_mark.2: New page documenting fanotify_mark(2)") Signed-off-by: Jann Horn Acked-by: Amir Goldstein --- man/man2/fanotify_mark.2 | 8 -------- 1 file changed, 8 deletions(-) diff --git a/man/man2/fanotify_mark.2 b/man/man2/fanotify_mark.2 index e561ffd21..a3b77537c 100644 --- a/man/man2/fanotify_mark.2 +++ b/man/man2/fanotify_mark.2 @@ -560,14 +560,6 @@ defines the filesystem object to be marked. .IP \[bu] If .I path -is NULL, and -.I dirfd -takes the special value -.BR AT_FDCWD , -the current working directory is to be marked. -.IP \[bu] -If -.I path is absolute, it defines the filesystem object to be marked, and .I dirfd is ignored. --- base-commit: 9db8ca91f920b9aba40ed68de6b8da0ca9dbefaa change-id: 20260529-fan-mark-cwd-1c760106eff9 Best regards, -- =20 Jann Horn