3 # Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher
6 --- glibc-2.2.5/sysdeps/unix/sysv/linux/arm/ioperm.c~arm-ctl_bus_isa.patch 2004-09-03 19:00:33.000000000 -0500
7 +++ glibc-2.2.5/sysdeps/unix/sysv/linux/arm/ioperm.c 2004-09-03 19:00:37.000000000 -0500
10 #include <sys/sysctl.h>
12 +/* see http://www.ussg.iu.edu/hypermail/linux/kernel/0311.0/0529.html */
13 +#include <linux/version.h>
14 +#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,4,23))
15 +#define CTL_BUS_ISA BUS_ISA /* and hope it's not the one from linux/input.h */
18 #define PATH_ARM_SYSTYPE "/etc/arm_systype"
19 #define PATH_CPUINFO "/proc/cpuinfo"
22 * Initialize I/O system. There are several ways to get the information
23 * we need. Each is tried in turn until one succeeds.
25 - * 1. Sysctl (CTL_BUS, BUS_ISA, ISA_*). This is the preferred method
26 + * 1. Sysctl (CTL_BUS, CTL_BUS_ISA, ISA_*). This is the preferred method
27 * but not all kernels support it.
29 * 2. Read the value (not the contents) of symlink PATH_ARM_SYSTYPE.
34 - static int iobase_name[] = { CTL_BUS, BUS_ISA, BUS_ISA_PORT_BASE };
35 - static int ioshift_name[] = { CTL_BUS, BUS_ISA, BUS_ISA_PORT_SHIFT };
36 + static int iobase_name[] = { CTL_BUS, CTL_BUS_ISA, BUS_ISA_PORT_BASE };
37 + static int ioshift_name[] = { CTL_BUS, CTL_BUS_ISA, BUS_ISA_PORT_SHIFT };
38 size_t len = sizeof(io.base);
40 if (! sysctl (iobase_name, 3, &io.io_base, &len, NULL, 0)