From nobody Tue Aug 06 18:19:28 2024 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WdhR50qP0z5SPtY; Tue, 06 Aug 2024 18:19:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WdhR45N6hz49l6; Tue, 6 Aug 2024 18:19:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1722968368; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=S4FsEfgIkQ99Wx9LKeTbZs3Qu5qLbqYXY6CH7BiVqwI=; b=hybQYRxBAAY6ii+pnNY2iLdtVvW8pNq7ijct5fK2suJuKhfYG1Ugmh+b/DRS1zMrhh/hsL qtJo2sb7s6NVhbsYLclj279DT/6AuoK3gzOSJbUSB67tny/x1tclDSHMHNc0CGW/FEWMQW kLLFeGmEvbL5fU1lF5QYR9kVKxWK1WAIDva3wjuL5D6rKZ4TzK29MmPMpNMS4dsdON/J3J dHPBalrSJ+8iQRA985xbnrpRiHCaf7zN8RNUwnU0pL+LiUXzYaEB31J+ZT7krGYOeuv6VB zVdbUHnDxB7lmco9LlDwkZ1+A4+ngJDZnLo63K7o75xR3za7B4NnNCmqV4fF5w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1722968368; a=rsa-sha256; cv=none; b=uzvIp3nxQcbp/cUGEtziuPh6uo1urMyBXvIBbJHq+KbwRhyrwVCGkHUOkY26dG7GY/+02J Hl84rNqy4Z6G+MzaCpESPHMo0DnLMDjKxDAjOp2CzKbffqRyN5eRNJ8sD8YBGOMgVpm4dJ 9jrV0SUF7w5jjuFD6WYEzzlt5WJzcJY7Onp1Q306SZauzkQcjZq1ruh7Wi0d7NetN0v5ut CNUYfgo1VtLBt8O3C47858m9Iz0zOpCRfg4aqAHAlv0pCdTNqvkXuzC4Sx3CldFDZXSi0U CWAcVF+YxFUwI664ClNZvLBdZY1rPgbo3FRkICIX5keYUHE5cCCQBfY4WA8dgg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1722968368; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=S4FsEfgIkQ99Wx9LKeTbZs3Qu5qLbqYXY6CH7BiVqwI=; b=i6yZ8tnu/5Y5npWFtLtKqFXwcL77FnFT5mslqaViDy9x+/cEbXCEb8xfwdAkMVmUouEEYf TJpdSWrPsSVqXmaEGq6/N8EIzkXCrChNZcWrpwJMxTcddt56aN6XFUzHdiCBHIYxwjvqty 9NHMR6FnLae6i2RSikQWTJvCKHi8/4jKnL+3WlhZPya8aWhQgAIZ0pPOwIbbknsoQQViNy BTLDQCITDH79GXiin29tA/5YhLP9KF6a2gyPrdCU5qUKYUoG/FIEQXzGr5kSaJfTKC2rxo lmqcFJB51eVAk9Ww5pAsT1FHbYxg3PJcwEv45bNtQZgEivZ5Pyk9YU1MqLPFEA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WdhR4505pzHW0; Tue, 6 Aug 2024 18:19:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 476IJSUb044448; Tue, 6 Aug 2024 18:19:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 476IJStK044445; Tue, 6 Aug 2024 18:19:28 GMT (envelope-from git) Date: Tue, 6 Aug 2024 18:19:28 GMT Message-Id: <202408061819.476IJStK044445@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Brooks Davis Subject: git: b5c95c93fdd4 - main - sys/mman.h: consistently use `#define` List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: brooks X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b5c95c93fdd47c0764219b8bf293ce54369caf27 Auto-Submitted: auto-generated The branch main has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=b5c95c93fdd47c0764219b8bf293ce54369caf27 commit b5c95c93fdd47c0764219b8bf293ce54369caf27 Author: Brooks Davis AuthorDate: 2024-08-06 18:19:09 +0000 Commit: Brooks Davis CommitDate: 2024-08-06 18:19:09 +0000 sys/mman.h: consistently use `#define` There were 12 cases of `#define` and 91 of `#define` and in some cases like msync() flags (MS_*) there wasn't consistency. Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D46233 --- sys/sys/mman.h | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/sys/sys/mman.h b/sys/sys/mman.h index 8feba252e2fe..6ee2d5562db1 100644 --- a/sys/sys/mman.h +++ b/sys/sys/mman.h @@ -30,7 +30,7 @@ */ #ifndef _SYS_MMAN_H_ -#define _SYS_MMAN_H_ +#define _SYS_MMAN_H_ #include #include @@ -39,10 +39,10 @@ /* * Inheritance for minherit() */ -#define INHERIT_SHARE 0 -#define INHERIT_COPY 1 -#define INHERIT_NONE 2 -#define INHERIT_ZERO 3 +#define INHERIT_SHARE 0 +#define INHERIT_COPY 1 +#define INHERIT_NONE 2 +#define INHERIT_ZERO 3 #endif /* @@ -118,9 +118,9 @@ * Flags provided to shm_rename */ /* Don't overwrite dest, if it exists */ -#define SHM_RENAME_NOREPLACE (1 << 0) +#define SHM_RENAME_NOREPLACE (1 << 0) /* Atomically swap src and dest */ -#define SHM_RENAME_EXCHANGE (1 << 1) +#define SHM_RENAME_EXCHANGE (1 << 1) #endif /* __BSD_VISIBLE */ @@ -128,21 +128,21 @@ /* * Process memory locking */ -#define MCL_CURRENT 0x0001 /* Lock only current memory */ -#define MCL_FUTURE 0x0002 /* Lock all future memory as well */ +#define MCL_CURRENT 0x0001 /* Lock only current memory */ +#define MCL_FUTURE 0x0002 /* Lock all future memory as well */ #endif /* * Error return from mmap() */ -#define MAP_FAILED ((void *)-1) +#define MAP_FAILED ((void *)-1) /* * msync() flags */ #define MS_SYNC 0x0000 /* msync synchronously */ -#define MS_ASYNC 0x0001 /* return immediately */ -#define MS_INVALIDATE 0x0002 /* invalidate all cached data */ +#define MS_ASYNC 0x0001 /* return immediately */ +#define MS_INVALIDATE 0x0002 /* invalidate all cached data */ /* * Advice to madvise