Magellan Linux

Contents of /trunk/linux-libc-headers/patches/linux-2.6.19.1-mips_headers-1.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 435 - (show annotations) (download)
Fri Mar 16 00:06:55 2007 UTC (17 years, 1 month ago) by niro
File size: 13929 byte(s)
updated to upstream svn-149

1 diff -Naur linux-2.6.19.1/include/asm-mips/compat.h linux-mips-2.6.19.1/include/asm-mips/compat.h
2 --- linux-2.6.19.1/include/asm-mips/compat.h 2006-12-11 11:32:53.000000000 -0800
3 +++ linux-mips-2.6.19.1/include/asm-mips/compat.h 2006-12-11 15:38:26.000000000 -0800
4 @@ -5,6 +5,7 @@
5 */
6 #include <linux/types.h>
7 #include <asm/page.h>
8 +#include <asm/ptrace.h>
9
10 #define COMPAT_USER_HZ 100
11
12 @@ -32,6 +33,7 @@
13 s32 val[2];
14 } compat_fsid_t;
15 typedef s32 compat_timer_t;
16 +typedef s32 compat_key_t;
17
18 typedef s32 compat_int_t;
19 typedef s32 compat_long_t;
20 @@ -146,4 +148,71 @@
21 return (void __user *) (regs->regs[29] - len);
22 }
23
24 +struct compat_ipc64_perm {
25 + compat_key_t key;
26 + __compat_uid32_t uid;
27 + __compat_gid32_t gid;
28 + __compat_uid32_t cuid;
29 + __compat_gid32_t cgid;
30 + compat_mode_t mode;
31 + unsigned short seq;
32 + unsigned short __pad2;
33 + compat_ulong_t __unused1;
34 + compat_ulong_t __unused2;
35 +};
36 +
37 +struct compat_semid64_ds {
38 + struct compat_ipc64_perm sem_perm;
39 + compat_time_t sem_otime;
40 + compat_time_t sem_ctime;
41 + compat_ulong_t sem_nsems;
42 + compat_ulong_t __unused1;
43 + compat_ulong_t __unused2;
44 +};
45 +
46 +struct compat_msqid64_ds {
47 + struct compat_ipc64_perm msg_perm;
48 +#ifndef CONFIG_CPU_LITTLE_ENDIAN
49 + compat_ulong_t __unused1;
50 +#endif
51 + compat_time_t msg_stime;
52 +#ifdef CONFIG_CPU_LITTLE_ENDIAN
53 + compat_ulong_t __unused1;
54 +#endif
55 +#ifndef CONFIG_CPU_LITTLE_ENDIAN
56 + compat_ulong_t __unused2;
57 +#endif
58 + compat_time_t msg_rtime;
59 +#ifdef CONFIG_CPU_LITTLE_ENDIAN
60 + compat_ulong_t __unused2;
61 +#endif
62 +#ifndef CONFIG_CPU_LITTLE_ENDIAN
63 + compat_ulong_t __unused3;
64 +#endif
65 + compat_time_t msg_ctime;
66 +#ifdef CONFIG_CPU_LITTLE_ENDIAN
67 + compat_ulong_t __unused3;
68 +#endif
69 + compat_ulong_t msg_cbytes;
70 + compat_ulong_t msg_qnum;
71 + compat_ulong_t msg_qbytes;
72 + compat_pid_t msg_lspid;
73 + compat_pid_t msg_lrpid;
74 + compat_ulong_t __unused4;
75 + compat_ulong_t __unused5;
76 +};
77 +
78 +struct compat_shmid64_ds {
79 + struct compat_ipc64_perm shm_perm;
80 + compat_size_t shm_segsz;
81 + compat_time_t shm_atime;
82 + compat_time_t shm_dtime;
83 + compat_time_t shm_ctime;
84 + compat_pid_t shm_cpid;
85 + compat_pid_t shm_lpid;
86 + compat_ulong_t shm_nattch;
87 + compat_ulong_t __unused1;
88 + compat_ulong_t __unused2;
89 +};
90 +
91 #endif /* _ASM_COMPAT_H */
92 diff -Naur linux-2.6.19.1/include/asm-mips/io.h linux-mips-2.6.19.1/include/asm-mips/io.h
93 --- linux-2.6.19.1/include/asm-mips/io.h 2006-12-11 11:32:53.000000000 -0800
94 +++ linux-mips-2.6.19.1/include/asm-mips/io.h 2006-12-11 15:38:26.000000000 -0800
95 @@ -518,34 +518,6 @@
96 }
97
98 /*
99 - * Memory Mapped I/O
100 - */
101 -#define ioread8(addr) readb(addr)
102 -#define ioread16(addr) readw(addr)
103 -#define ioread32(addr) readl(addr)
104 -
105 -#define iowrite8(b,addr) writeb(b,addr)
106 -#define iowrite16(w,addr) writew(w,addr)
107 -#define iowrite32(l,addr) writel(l,addr)
108 -
109 -#define ioread8_rep(a,b,c) readsb(a,b,c)
110 -#define ioread16_rep(a,b,c) readsw(a,b,c)
111 -#define ioread32_rep(a,b,c) readsl(a,b,c)
112 -
113 -#define iowrite8_rep(a,b,c) writesb(a,b,c)
114 -#define iowrite16_rep(a,b,c) writesw(a,b,c)
115 -#define iowrite32_rep(a,b,c) writesl(a,b,c)
116 -
117 -/* Create a virtual mapping cookie for an IO port range */
118 -extern void __iomem *ioport_map(unsigned long port, unsigned int nr);
119 -extern void ioport_unmap(void __iomem *);
120 -
121 -/* Create a virtual mapping cookie for a PCI BAR (memory or IO) */
122 -struct pci_dev;
123 -extern void __iomem *pci_iomap(struct pci_dev *dev, int bar, unsigned long max);
124 -extern void pci_iounmap(struct pci_dev *dev, void __iomem *);
125 -
126 -/*
127 * ISA space is 'always mapped' on currently supported MIPS systems, no need
128 * to explicitly ioremap() it. The fact that the ISA IO space is mapped
129 * to PAGE_OFFSET is pure coincidence - it does not mean ISA values
130 diff -Naur linux-2.6.19.1/include/asm-mips/mach-au1x00/au1000.h linux-mips-2.6.19.1/include/asm-mips/mach-au1x00/au1000.h
131 --- linux-2.6.19.1/include/asm-mips/mach-au1x00/au1000.h 2006-12-11 11:32:53.000000000 -0800
132 +++ linux-mips-2.6.19.1/include/asm-mips/mach-au1x00/au1000.h 2006-12-11 15:38:26.000000000 -0800
133 @@ -39,6 +39,7 @@
134 #ifndef _LANGUAGE_ASSEMBLY
135
136 #include <linux/delay.h>
137 +#include <linux/types.h>
138 #include <asm/io.h>
139
140 /* cpu pipeline flush */
141 @@ -1664,12 +1665,12 @@
142 * addresses. For PCI IO, it's simpler because we get to do the ioremap
143 * ourselves and then adjust the device's resources.
144 */
145 -#define Au1500_EXT_CFG 0x600000000ULL
146 -#define Au1500_EXT_CFG_TYPE1 0x680000000ULL
147 -#define Au1500_PCI_IO_START 0x500000000ULL
148 -#define Au1500_PCI_IO_END 0x5000FFFFFULL
149 -#define Au1500_PCI_MEM_START 0x440000000ULL
150 -#define Au1500_PCI_MEM_END 0x44FFFFFFFULL
151 +#define Au1500_EXT_CFG ((resource_size_t) 0x600000000ULL)
152 +#define Au1500_EXT_CFG_TYPE1 ((resource_size_t) 0x680000000ULL)
153 +#define Au1500_PCI_IO_START ((resource_size_t) 0x500000000ULL)
154 +#define Au1500_PCI_IO_END ((resource_size_t) 0x5000FFFFFULL)
155 +#define Au1500_PCI_MEM_START ((resource_size_t) 0x440000000ULL)
156 +#define Au1500_PCI_MEM_END ((resource_size_t) 0x44FFFFFFFULL)
157
158 #define PCI_IO_START (Au1500_PCI_IO_START + 0x1000)
159 #define PCI_IO_END (Au1500_PCI_IO_END)
160 diff -Naur linux-2.6.19.1/include/asm-mips/mach-au1x00/au1xxx_ide.h linux-mips-2.6.19.1/include/asm-mips/mach-au1x00/au1xxx_ide.h
161 --- linux-2.6.19.1/include/asm-mips/mach-au1x00/au1xxx_ide.h 2006-12-11 11:32:53.000000000 -0800
162 +++ linux-mips-2.6.19.1/include/asm-mips/mach-au1x00/au1xxx_ide.h 2006-12-11 15:38:26.000000000 -0800
163 @@ -83,6 +83,7 @@
164 } _auide_hwif;
165
166 #ifdef CONFIG_BLK_DEV_IDE_AU1XXX_MDMA2_DBDMA
167 +
168 /* HD white list */
169 static const struct drive_list_entry dma_white_list [] = {
170 /*
171 diff -Naur linux-2.6.19.1/include/asm-mips/mach-ip27/irq.h linux-mips-2.6.19.1/include/asm-mips/mach-ip27/irq.h
172 --- linux-2.6.19.1/include/asm-mips/mach-ip27/irq.h 2006-12-11 11:32:53.000000000 -0800
173 +++ linux-mips-2.6.19.1/include/asm-mips/mach-ip27/irq.h 2006-12-11 15:38:26.000000000 -0800
174 @@ -10,8 +10,6 @@
175 #ifndef __ASM_MACH_IP27_IRQ_H
176 #define __ASM_MACH_IP27_IRQ_H
177
178 -#include <asm/sn/arch.h>
179 -
180 /*
181 * A hardwired interrupt number is completly stupid for this system - a
182 * large configuration might have thousands if not tenthousands of
183 diff -Naur linux-2.6.19.1/include/asm-mips/mach-ip27/topology.h linux-mips-2.6.19.1/include/asm-mips/mach-ip27/topology.h
184 --- linux-2.6.19.1/include/asm-mips/mach-ip27/topology.h 2006-12-11 11:32:53.000000000 -0800
185 +++ linux-mips-2.6.19.1/include/asm-mips/mach-ip27/topology.h 2006-12-11 15:38:26.000000000 -0800
186 @@ -1,7 +1,6 @@
187 #ifndef _ASM_MACH_TOPOLOGY_H
188 #define _ASM_MACH_TOPOLOGY_H 1
189
190 -#include <asm/sn/arch.h>
191 #include <asm/sn/hub.h>
192 #include <asm/mmzone.h>
193
194 diff -Naur linux-2.6.19.1/include/asm-mips/page.h linux-mips-2.6.19.1/include/asm-mips/page.h
195 --- linux-2.6.19.1/include/asm-mips/page.h 2006-12-11 11:32:53.000000000 -0800
196 +++ linux-mips-2.6.19.1/include/asm-mips/page.h 2006-12-11 15:38:26.000000000 -0800
197 @@ -59,16 +59,13 @@
198 flush_data_cache_page((unsigned long)addr);
199 }
200
201 -static inline void copy_user_page(void *vto, void *vfrom, unsigned long vaddr,
202 - struct page *to)
203 -{
204 - extern void (*flush_data_cache_page)(unsigned long addr);
205 -
206 - copy_page(vto, vfrom);
207 - if (!cpu_has_ic_fills_f_dc ||
208 - pages_do_alias((unsigned long)vto, vaddr & PAGE_MASK))
209 - flush_data_cache_page((unsigned long)vto);
210 -}
211 +extern void copy_user_page(void *vto, void *vfrom, unsigned long vaddr,
212 + struct page *to);
213 +struct vm_area_struct;
214 +extern void copy_user_highpage(struct page *to, struct page *from,
215 + unsigned long vaddr, struct vm_area_struct *vma);
216 +
217 +#define __HAVE_ARCH_COPY_USER_HIGHPAGE
218
219 /*
220 * These are used to make use of C type-checking..
221 diff -Naur linux-2.6.19.1/include/asm-mips/pci.h linux-mips-2.6.19.1/include/asm-mips/pci.h
222 --- linux-2.6.19.1/include/asm-mips/pci.h 2006-12-11 11:32:53.000000000 -0800
223 +++ linux-mips-2.6.19.1/include/asm-mips/pci.h 2006-12-11 15:38:26.000000000 -0800
224 @@ -187,4 +187,10 @@
225 /* Do platform specific device initialization at pci_enable_device() time */
226 extern int pcibios_plat_dev_init(struct pci_dev *dev);
227
228 +/* Chances are this interrupt is wired PC-style ... */
229 +static inline int pci_get_legacy_ide_irq(struct pci_dev *dev, int channel)
230 +{
231 + return channel ? 15 : 14;
232 +}
233 +
234 #endif /* _ASM_PCI_H */
235 diff -Naur linux-2.6.19.1/include/asm-mips/ptrace.h linux-mips-2.6.19.1/include/asm-mips/ptrace.h
236 --- linux-2.6.19.1/include/asm-mips/ptrace.h 2006-12-11 11:32:53.000000000 -0800
237 +++ linux-mips-2.6.19.1/include/asm-mips/ptrace.h 2006-12-11 15:38:26.000000000 -0800
238 @@ -84,6 +84,14 @@
239
240 extern asmlinkage void do_syscall_trace(struct pt_regs *regs, int entryexit);
241
242 +extern NORET_TYPE void die(const char *, struct pt_regs *);
243 +
244 +static inline void die_if_kernel(const char *str, struct pt_regs *regs)
245 +{
246 + if (unlikely(!user_mode(regs)))
247 + die(str, regs);
248 +}
249 +
250 #endif
251
252 #endif /* _ASM_PTRACE_H */
253 diff -Naur linux-2.6.19.1/include/asm-mips/sn/arch.h linux-mips-2.6.19.1/include/asm-mips/sn/arch.h
254 --- linux-2.6.19.1/include/asm-mips/sn/arch.h 2006-12-11 11:32:53.000000000 -0800
255 +++ linux-mips-2.6.19.1/include/asm-mips/sn/arch.h 2006-12-11 15:38:26.000000000 -0800
256 @@ -18,7 +18,6 @@
257 #endif
258
259 typedef u64 hubreg_t;
260 -typedef u64 nic_t;
261
262 #define cputonasid(cpu) (cpu_data[(cpu)].p_nasid)
263 #define cputoslice(cpu) (cpu_data[(cpu)].p_slice)
264 diff -Naur linux-2.6.19.1/include/asm-mips/sn/klconfig.h linux-mips-2.6.19.1/include/asm-mips/sn/klconfig.h
265 --- linux-2.6.19.1/include/asm-mips/sn/klconfig.h 2006-12-11 11:32:53.000000000 -0800
266 +++ linux-mips-2.6.19.1/include/asm-mips/sn/klconfig.h 2006-12-11 15:38:26.000000000 -0800
267 @@ -61,6 +61,8 @@
268 #endif /* CONFIG_SGI_IP35 */
269 #endif /* CONFIG_SGI_IP27 || CONFIG_SGI_IP35 */
270
271 +typedef u64 nic_t;
272 +
273 #define KLCFGINFO_MAGIC 0xbeedbabe
274
275 typedef s32 klconf_off_t;
276 @@ -176,7 +178,7 @@
277 /* --- New Macros for the changed kl_config_hdr_t structure --- */
278
279 #define PTR_CH_MALLOC_HDR(_k) ((klc_malloc_hdr_t *)\
280 - (unsigned long)_k + (_k->ch_malloc_hdr_off)))
281 + ((unsigned long)_k + (_k->ch_malloc_hdr_off)))
282
283 #define KL_CONFIG_CH_MALLOC_HDR(_n) PTR_CH_MALLOC_HDR(KL_CONFIG_HDR(_n))
284
285 diff -Naur linux-2.6.19.1/include/asm-mips/system.h linux-mips-2.6.19.1/include/asm-mips/system.h
286 --- linux-2.6.19.1/include/asm-mips/system.h 2006-12-11 11:32:53.000000000 -0800
287 +++ linux-mips-2.6.19.1/include/asm-mips/system.h 2006-12-11 15:38:26.000000000 -0800
288 @@ -18,7 +18,6 @@
289 #include <asm/addrspace.h>
290 #include <asm/cpu-features.h>
291 #include <asm/dsp.h>
292 -#include <asm/ptrace.h>
293 #include <asm/war.h>
294
295 /*
296 @@ -472,14 +471,6 @@
297 extern unsigned long ebase;
298 extern void per_cpu_trap_init(void);
299
300 -extern NORET_TYPE void die(const char *, struct pt_regs *);
301 -
302 -static inline void die_if_kernel(const char *str, struct pt_regs *regs)
303 -{
304 - if (unlikely(!user_mode(regs)))
305 - die(str, regs);
306 -}
307 -
308 extern int stop_a_enabled;
309
310 /*
311 diff -Naur linux-2.6.19.1/include/linux/highmem.h linux-mips-2.6.19.1/include/linux/highmem.h
312 --- linux-2.6.19.1/include/linux/highmem.h 2006-12-11 11:32:53.000000000 -0800
313 +++ linux-mips-2.6.19.1/include/linux/highmem.h 2006-12-11 15:38:26.000000000 -0800
314 @@ -94,7 +94,10 @@
315 kunmap_atomic(kaddr, KM_USER0);
316 }
317
318 -static inline void copy_user_highpage(struct page *to, struct page *from, unsigned long vaddr)
319 +#ifndef __HAVE_ARCH_COPY_USER_HIGHPAGE
320 +
321 +static inline void copy_user_highpage(struct page *to, struct page *from,
322 + unsigned long vaddr, struct vm_area_struct *vma)
323 {
324 char *vfrom, *vto;
325
326 @@ -107,6 +110,8 @@
327 smp_wmb();
328 }
329
330 +#endif
331 +
332 static inline void copy_highpage(struct page *to, struct page *from)
333 {
334 char *vfrom, *vto;
335 diff -Naur linux-2.6.19.1/include/linux/pci_ids.h linux-mips-2.6.19.1/include/linux/pci_ids.h
336 --- linux-2.6.19.1/include/linux/pci_ids.h 2006-12-11 11:32:53.000000000 -0800
337 +++ linux-mips-2.6.19.1/include/linux/pci_ids.h 2006-12-11 15:38:26.000000000 -0800
338 @@ -1604,6 +1604,9 @@
339 #define PCI_VENDOR_ID_SATSAGEM 0x1267
340 #define PCI_DEVICE_ID_SATSAGEM_NICCY 0x1016
341
342 +#define PCI_VENDOR_ID_SILICON_MOTION 0x126f
343 +#define PCI_DEVICE_ID_SM501_VOYAGER_GX_REV_AA 0x0501
344 +#define PCI_DEVICE_ID_SM501_VOYAGER_GX_REV_B 0x0510
345
346 #define PCI_VENDOR_ID_ENSONIQ 0x1274
347 #define PCI_DEVICE_ID_ENSONIQ_CT5880 0x5880
348 diff -Naur linux-2.6.19.1/include/linux/serial.h linux-mips-2.6.19.1/include/linux/serial.h
349 --- linux-2.6.19.1/include/linux/serial.h 2006-12-11 11:32:53.000000000 -0800
350 +++ linux-mips-2.6.19.1/include/linux/serial.h 2006-12-11 15:38:26.000000000 -0800
351 @@ -76,7 +76,8 @@
352 #define PORT_16654 11
353 #define PORT_16850 12
354 #define PORT_RSA 13 /* RSA-DV II/S card */
355 -#define PORT_MAX 13
356 +#define PORT_SB1250 14
357 +#define PORT_MAX 14
358
359 #define SERIAL_IO_PORT 0
360 #define SERIAL_IO_HUB6 1
361 diff -Naur linux-2.6.19.1/include/linux/serial_ip3106.h linux-mips-2.6.19.1/include/linux/serial_ip3106.h
362 --- linux-2.6.19.1/include/linux/serial_ip3106.h 2006-12-11 11:32:53.000000000 -0800
363 +++ linux-mips-2.6.19.1/include/linux/serial_ip3106.h 2006-12-11 15:38:26.000000000 -0800
364 @@ -78,4 +78,16 @@
365 #define IP3106_UART_FIFO_RXFIFO 0x00001F00
366 #define IP3106_UART_FIFO_RBRTHR 0x000000FF
367
368 +#define ip3106_lcr(base,port) *(volatile u32 *)(base+(port*0x1000) + 0x000)
369 +#define ip3106_mcr(base, port) *(volatile u32 *)(base+(port*0x1000) + 0x004)
370 +#define ip3106_baud(base, port) *(volatile u32 *)(base+(port*0x1000) + 0x008)
371 +#define ip3106_cfg(base, port) *(volatile u32 *)(base+(port*0x1000) + 0x00C)
372 +#define ip3106_fifo(base, port) *(volatile u32 *)(base+(port*0x1000) + 0x028)
373 +#define ip3106_istat(base, port) *(volatile u32 *)(base+(port*0x1000) + 0xFE0)
374 +#define ip3106_ien(base, port) *(volatile u32 *)(base+(port*0x1000) + 0xFE4)
375 +#define ip3106_iclr(base, port) *(volatile u32 *)(base+(port*0x1000) + 0xFE8)
376 +#define ip3106_iset(base, port) *(volatile u32 *)(base+(port*0x1000) + 0xFEC)
377 +#define ip3106_pd(base, port) *(volatile u32 *)(base+(port*0x1000) + 0xFF4)
378 +#define ip3106_mid(base, port) *(volatile u32 *)(base+(port*0x1000) + 0xFFC)
379 +
380 #endif