[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20230321011137.51837-10-paulmck@kernel.org>
Date: Mon, 20 Mar 2023 18:11:33 -0700
From: "Paul E. McKenney" <paulmck@...nel.org>
To: linux-kernel@...r.kernel.org
Cc: gwml@...r.gnuweeb.org, kernel-team@...a.com, w@....eu,
Feiyang Chen <chenfeiyang@...ngson.cn>,
Huacai Chen <chenhuacai@...ngson.cn>, Willy Tarreau <w@....eu>,
"Paul E . McKenney" <paulmck@...nel.org>
Subject: [PATCH nolibc 10/14] tools/nolibc: Include linux/fcntl.h and remove duplicate code
From: Feiyang Chen <chenfeiyang@...ngson.cn>
Include linux/fcntl.h for O_* and AT_*. asm/fcntl.h is included
by linux/fcntl.h, so it can be safely removed.
Signed-off-by: Feiyang Chen <chenfeiyang@...ngson.cn>
Acked-by: Huacai Chen <chenhuacai@...ngson.cn>
Signed-off-by: Willy Tarreau <w@....eu>
Signed-off-by: Paul E. McKenney <paulmck@...nel.org>
---
tools/include/nolibc/sys.h | 2 +-
tools/include/nolibc/types.h | 5 -----
2 files changed, 1 insertion(+), 6 deletions(-)
diff --git a/tools/include/nolibc/sys.h b/tools/include/nolibc/sys.h
index 115579e7f1db..41cad6d6137e 100644
--- a/tools/include/nolibc/sys.h
+++ b/tools/include/nolibc/sys.h
@@ -11,7 +11,6 @@
#include "std.h"
/* system includes */
-#include <asm/fcntl.h> // for O_*
#include <asm/unistd.h>
#include <asm/signal.h> // for SIGCHLD
#include <asm/ioctls.h>
@@ -20,6 +19,7 @@
#include <linux/loop.h>
#include <linux/time.h>
#include <linux/auxvec.h>
+#include <linux/fcntl.h> // for O_* and AT_*
#include "arch.h"
#include "errno.h"
diff --git a/tools/include/nolibc/types.h b/tools/include/nolibc/types.h
index 47a0997d2d74..10823e5ac44b 100644
--- a/tools/include/nolibc/types.h
+++ b/tools/include/nolibc/types.h
@@ -81,11 +81,6 @@
#define MAXPATHLEN (PATH_MAX)
#endif
-/* Special FD used by all the *at functions */
-#ifndef AT_FDCWD
-#define AT_FDCWD (-100)
-#endif
-
/* whence values for lseek() */
#define SEEK_SET 0
#define SEEK_CUR 1
--
2.40.0.rc2
Powered by blists - more mailing lists