Index | Thread | Search

From:
Jonathan Gray <jsg@jsg.id.au>
Subject:
remove unused MSQID defines from sys/msg.h
To:
tech@openbsd.org
Date:
Sat, 26 Oct 2024 09:09:13 +1100

Download raw body.

Thread
remove unused MSQID defines that were under _KERNEL
combine ifdefs while here

Index: sys/sys/msg.h
===================================================================
RCS file: /cvs/src/sys/sys/msg.h,v
diff -u -p -r1.22 msg.h
--- sys/sys/msg.h	10 Jun 2024 04:10:25 -0000	1.22
+++ sys/sys/msg.h	25 Oct 2024 21:27:06 -0000
@@ -133,27 +133,14 @@ struct msg_sysctl_info {
 #define MSGTQL	40
 #endif
 
-/*
- * macros to convert between msqid_ds's and msqid's.
- * XXX unused, going away
- */
-#define MSQID(ix,ds)	((ix) & 0xffff | (((ds).msg_perm.seq << 16) & 0xffff0000))
-#define MSQID_IX(id)	((id) & 0xffff)
-#define MSQID_SEQ(id)	(((id) >> 16) & 0xffff)
-#endif
-
-
-#ifndef _KERNEL
+void msginit(void);
+#else /* !_KERNEL */
 __BEGIN_DECLS
 int msgctl(int, int, struct msqid_ds *);
 int msgget(key_t, int);
 int msgsnd(int, const void *, size_t, int);
 int msgrcv(int, void *, size_t, long, int);
 __END_DECLS
-#else
-struct proc;
-
-void	msginit(void);
-#endif /* !_KERNEL */
+#endif
 
 #endif /* !_SYS_MSG_H_ */