Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/raidframe Fix some ARM kernel builds. ARM abuses co...
details: https://anonhg.NetBSD.org/src/rev/81ed312022ce
branches: trunk
changeset: 358842:81ed312022ce
user: skrll <skrll%NetBSD.org@localhost>
date: Fri Jan 19 09:04:23 2018 +0000
description:
Fix some ARM kernel builds. ARM abuses compat32 for ABI compatibility and
this means some ioctls overlap.
diffstat:
sys/dev/raidframe/rf_netbsdkintf.c | 14 ++++++++++++--
1 files changed, 12 insertions(+), 2 deletions(-)
diffs (78 lines):
diff -r b3cd68031c34 -r 81ed312022ce sys/dev/raidframe/rf_netbsdkintf.c
--- a/sys/dev/raidframe/rf_netbsdkintf.c Fri Jan 19 08:01:05 2018 +0000
+++ b/sys/dev/raidframe/rf_netbsdkintf.c Fri Jan 19 09:04:23 2018 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_netbsdkintf.c,v 1.353 2018/01/18 00:32:49 mrg Exp $ */
+/* $NetBSD: rf_netbsdkintf.c,v 1.354 2018/01/19 09:04:23 skrll Exp $ */
/*-
* Copyright (c) 1996, 1997, 1998, 2008-2011 The NetBSD Foundation, Inc.
@@ -101,7 +101,7 @@
***********************************************************/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rf_netbsdkintf.c,v 1.353 2018/01/18 00:32:49 mrg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_netbsdkintf.c,v 1.354 2018/01/19 09:04:23 skrll Exp $");
#ifdef _KERNEL_OPT
#include "opt_compat_netbsd.h"
@@ -1115,8 +1115,10 @@
case RAIDFRAME_GET_COMPONENT_LABEL80:
#endif
#ifdef COMPAT_NETBSD32
+#ifdef _LP64
case RAIDFRAME_GET_INFO32:
#endif
+#endif
if ((rs->sc_flags & RAIDF_INITED) == 0)
return (ENXIO);
}
@@ -1152,8 +1154,10 @@
/* configure the system */
case RAIDFRAME_CONFIGURE:
#ifdef COMPAT_NETBSD32
+#ifdef _LP64
case RAIDFRAME_CONFIGURE32:
#endif
+#endif
if (raidPtr->valid) {
/* There is a valid RAID set running on this unit! */
@@ -1169,11 +1173,13 @@
return (ENOMEM);
}
#ifdef COMPAT_NETBSD32
+#ifdef _LP64
if (cmd == RAIDFRAME_CONFIGURE32 &&
(l->l_proc->p_flag & PK_32) != 0)
retcode = rf_config_netbsd32(data, k_cfg);
else
#endif
+#endif
{
u_cfg = *((RF_Config_t **) data);
retcode = copyin(u_cfg, k_cfg, sizeof(RF_Config_t));
@@ -1476,8 +1482,10 @@
case RAIDFRAME_GET_INFO:
#ifdef COMPAT_NETBSD32
+#ifdef _LP64
case RAIDFRAME_GET_INFO32:
#endif
+#endif
RF_Malloc(d_cfg, sizeof(RF_DeviceConfig_t),
(RF_DeviceConfig_t *));
if (d_cfg == NULL)
@@ -1485,10 +1493,12 @@
retcode = rf_get_info(raidPtr, d_cfg);
if (retcode == 0) {
#ifdef COMPAT_NETBSD32
+#ifdef _LP64
if (cmd == RAIDFRAME_GET_INFO32)
ucfgp = NETBSD32PTR64(*(netbsd32_pointer_t *)data);
else
#endif
+#endif
ucfgp = *(RF_DeviceConfig_t **)data;
retcode = copyout(d_cfg, ucfgp, sizeof(RF_DeviceConfig_t));
}
Home |
Main Index |
Thread Index |
Old Index