summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authordlg <dlg@openbsd.org>2014-10-22 23:56:47 +0000
committerdlg <dlg@openbsd.org>2014-10-22 23:56:47 +0000
commitb5b8c50f23acda0eb8bd12f6f48c662adf81ad72 (patch)
tree601d0024683835df06c221600fc674203f5f86ad /sys
parentmake the description of the syntax of function lists agree (diff)
downloadwireguard-openbsd-b5b8c50f23acda0eb8bd12f6f48c662adf81ad72.tar.xz
wireguard-openbsd-b5b8c50f23acda0eb8bd12f6f48c662adf81ad72.zip
make [bl]emtoh{16,32,64} take volatile const foo *, not volatile foo *
while in the manpage add volatile where the code has it too. ok miod@ guenther@
Diffstat (limited to 'sys')
-rw-r--r--sys/arch/powerpc/include/endian.h8
-rw-r--r--sys/arch/sparc64/include/endian.h8
2 files changed, 8 insertions, 8 deletions
diff --git a/sys/arch/powerpc/include/endian.h b/sys/arch/powerpc/include/endian.h
index d8e4c5eb38c..11ce8200c8c 100644
--- a/sys/arch/powerpc/include/endian.h
+++ b/sys/arch/powerpc/include/endian.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: endian.h,v 1.20 2014/07/12 16:25:09 guenther Exp $ */
+/* $OpenBSD: endian.h,v 1.21 2014/10/22 23:56:47 dlg Exp $ */
/*-
* Copyright (c) 1997 Niklas Hallqvist. All rights reserved.
@@ -30,7 +30,7 @@
#ifdef _KERNEL
static inline __uint16_t
-__mswap16(volatile __uint16_t *m)
+__mswap16(volatile const __uint16_t *m)
{
__uint16_t v;
@@ -42,7 +42,7 @@ __mswap16(volatile __uint16_t *m)
}
static inline __uint32_t
-__mswap32(volatile __uint32_t *m)
+__mswap32(volatile const __uint32_t *m)
{
__uint32_t v;
@@ -54,7 +54,7 @@ __mswap32(volatile __uint32_t *m)
}
static inline __uint64_t
-__mswap64(volatile __uint64_t *m)
+__mswap64(volatile const __uint64_t *m)
{
__uint32_t *a = (__uint32_t *)m;
__uint64_t v;
diff --git a/sys/arch/sparc64/include/endian.h b/sys/arch/sparc64/include/endian.h
index b2bb346d4ed..72b3e4928da 100644
--- a/sys/arch/sparc64/include/endian.h
+++ b/sys/arch/sparc64/include/endian.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: endian.h,v 1.6 2014/07/12 16:25:09 guenther Exp $ */
+/* $OpenBSD: endian.h,v 1.7 2014/10/22 23:56:47 dlg Exp $ */
#ifndef _MACHINE_ENDIAN_H_
#define _MACHINE_ENDIAN_H_
@@ -10,7 +10,7 @@
#define __ASI_P_L 0x88 /* == ASI_PRIMARY_LITTLE */
static inline __uint16_t
-__mswap16(volatile __uint16_t *m)
+__mswap16(volatile const __uint16_t *m)
{
__uint16_t v;
@@ -22,7 +22,7 @@ __mswap16(volatile __uint16_t *m)
}
static inline __uint32_t
-__mswap32(volatile __uint32_t *m)
+__mswap32(volatile const __uint32_t *m)
{
__uint32_t v;
@@ -34,7 +34,7 @@ __mswap32(volatile __uint32_t *m)
}
static inline __uint64_t
-__mswap64(volatile __uint64_t *m)
+__mswap64(volatile const __uint64_t *m)
{
__uint64_t v;