From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752542AbdFOUJz (ORCPT ); Thu, 15 Jun 2017 16:09:55 -0400 Received: from mr11p00im-asmtp002.me.com ([17.110.69.253]:27731 "EHLO mr11p00im-asmtp002.me.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752510AbdFOUJw (ORCPT ); Thu, 15 Jun 2017 16:09:52 -0400 X-Greylist: delayed 3613 seconds by postgrey-1.27 at vger.kernel.org; Thu, 15 Jun 2017 16:09:52 EDT X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2017-06-15_09:,, signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 clxscore=1034 suspectscore=1 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1701120000 definitions=main-1706150331 From: Theodore Dubois To: mtk.manpages@gmail.com Cc: linux-man@vger.kernel.org, linux-kernel@vger.kernel.org, Theodore Dubois Subject: [PATCH] mmap.2: mmap with address NULL and MAP_FIXED results in EPERM Date: Thu, 15 Jun 2017 12:09:01 -0700 Message-id: <20170615190901.30119-1-tblodt@icloud.com> X-Mailer: git-send-email 2.13.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This can be verified with a simple test program. I'm not sure if this is a kernel bug or a documentation bug, though... --- man2/mmap.2 | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/man2/mmap.2 b/man2/mmap.2 index d1942b52a..58361c837 100644 --- a/man2/mmap.2 +++ b/man2/mmap.2 @@ -515,6 +515,13 @@ was mounted no-exec. .\" (Since 2.4.25 / 2.6.0.) .TP .B EPERM +The +.I addr +argument is 0 and +.B MAP_FIXED +is specified. +.TP +.B EPERM The operation was prevented by a file seal; see .BR fcntl (2). .TP -- 2.13.1