aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog.arm6
-rw-r--r--sysdeps/unix/sysv/linux/arm/ioperm.c11
2 files changed, 15 insertions, 2 deletions
diff --git a/ChangeLog.arm b/ChangeLog.arm
index e3e7fa17cf..e36328bce2 100644
--- a/ChangeLog.arm
+++ b/ChangeLog.arm
@@ -1,3 +1,9 @@
+2005-05-09 Daniel Jacobowitz <dan@codesourcery.com>
+ Mark Mitchell <mark@codesourcery.com>
+
+ * sysdeps/unix/sysv/linux/arm/ioperm.c (BUS_ISA): Define for new
+ kernel headers.
+
2005-06-09 Phil Blundell <pb@reciva.com>
* sysdeps/unix/arm/sysdep.h, sysdeps/unix/sysv/linux/arm/sysdep.h,
diff --git a/sysdeps/unix/sysv/linux/arm/ioperm.c b/sysdeps/unix/sysv/linux/arm/ioperm.c
index 558b485b61..65ec077336 100644
--- a/sysdeps/unix/sysv/linux/arm/ioperm.c
+++ b/sysdeps/unix/sysv/linux/arm/ioperm.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 1999, 2003 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 1999, 2003, 2005 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Phil Blundell, based on the Alpha version by
David Mosberger.
@@ -44,6 +44,7 @@
#include <sys/types.h>
#include <sys/mman.h>
+#include <linux/version.h>
#include <asm/page.h>
#include <sys/sysctl.h>
@@ -80,7 +81,7 @@ static struct platform {
* Initialize I/O system. There are several ways to get the information
* we need. Each is tried in turn until one succeeds.
*
- * 1. Sysctl (CTL_BUS, BUS_ISA, ISA_*). This is the preferred method
+ * 1. Sysctl (CTL_BUS, CTL_BUS_ISA, ISA_*). This is the preferred method
* but not all kernels support it.
*
* 2. Read the value (not the contents) of symlink PATH_ARM_SYSTYPE.
@@ -95,6 +96,12 @@ static struct platform {
* values.
*/
+/* The Linux kernel headers renamed this constant between 2.5.26 and
+ 2.5.27. It was backported to 2.4 between 2.4.22 and 2.4.23. */
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,4,23)
+# define BUS_ISA CTL_BUS_ISA
+#endif
+
static int
init_iosys (void)
{