diff options
Diffstat (limited to 'include/asm-cris')
-rw-r--r-- | include/asm-cris/arch-v10/ide.h | 5 | ||||
-rw-r--r-- | include/asm-cris/arch-v32/ide.h | 5 | ||||
-rw-r--r-- | include/asm-cris/atomic.h | 2 | ||||
-rw-r--r-- | include/asm-cris/bitops.h | 7 | ||||
-rw-r--r-- | include/asm-cris/checksum.h | 2 | ||||
-rw-r--r-- | include/asm-cris/elf.h | 3 | ||||
-rw-r--r-- | include/asm-cris/ethernet.h | 3 | ||||
-rw-r--r-- | include/asm-cris/fasttimer.h | 16 | ||||
-rw-r--r-- | include/asm-cris/hardirq.h | 1 | ||||
-rw-r--r-- | include/asm-cris/page.h | 11 | ||||
-rw-r--r-- | include/asm-cris/pgalloc.h | 6 | ||||
-rw-r--r-- | include/asm-cris/posix_types.h | 1 | ||||
-rw-r--r-- | include/asm-cris/socket.h | 2 | ||||
-rw-r--r-- | include/asm-cris/system.h | 15 | ||||
-rw-r--r-- | include/asm-cris/termbits.h | 13 | ||||
-rw-r--r-- | include/asm-cris/thread_info.h | 9 | ||||
-rw-r--r-- | include/asm-cris/tlb.h | 2 | ||||
-rw-r--r-- | include/asm-cris/unistd.h | 40 | ||||
-rw-r--r-- | include/asm-cris/user.h | 2 |
19 files changed, 101 insertions, 44 deletions
diff --git a/include/asm-cris/arch-v10/ide.h b/include/asm-cris/arch-v10/ide.h index 78b301ed7b1..ea34e0d0a38 100644 --- a/include/asm-cris/arch-v10/ide.h +++ b/include/asm-cris/arch-v10/ide.h @@ -89,11 +89,6 @@ static inline void ide_init_default_hwifs(void) } } -/* some configuration options we don't need */ - -#undef SUPPORT_VLB_SYNC -#define SUPPORT_VLB_SYNC 0 - #endif /* __KERNEL__ */ #endif /* __ASMCRIS_IDE_H */ diff --git a/include/asm-cris/arch-v32/ide.h b/include/asm-cris/arch-v32/ide.h index 11296170d05..fb9c3627a5b 100644 --- a/include/asm-cris/arch-v32/ide.h +++ b/include/asm-cris/arch-v32/ide.h @@ -48,11 +48,6 @@ static inline unsigned long ide_default_io_base(int index) return REG_TYPE_CONV(unsigned long, reg_ata_rw_ctrl2, ctrl2); } -/* some configuration options we don't need */ - -#undef SUPPORT_VLB_SYNC -#define SUPPORT_VLB_SYNC 0 - #define IDE_ARCH_ACK_INTR #define ide_ack_intr(hwif) ((hwif)->ack_intr(hwif)) diff --git a/include/asm-cris/atomic.h b/include/asm-cris/atomic.h index 0b51a87e553..2949a945876 100644 --- a/include/asm-cris/atomic.h +++ b/include/asm-cris/atomic.h @@ -3,6 +3,8 @@ #ifndef __ASM_CRIS_ATOMIC__ #define __ASM_CRIS_ATOMIC__ +#include <linux/compiler.h> + #include <asm/system.h> #include <asm/arch/atomic.h> diff --git a/include/asm-cris/bitops.h b/include/asm-cris/bitops.h index e2f49c27ed2..75ea6e09648 100644 --- a/include/asm-cris/bitops.h +++ b/include/asm-cris/bitops.h @@ -24,13 +24,6 @@ #include <linux/compiler.h> /* - * Some hacks to defeat gcc over-optimizations.. - */ -struct __dummy { unsigned long a[100]; }; -#define ADDR (*(struct __dummy *) addr) -#define CONST_ADDR (*(const struct __dummy *) addr) - -/* * set_bit - Atomically set a bit in memory * @nr: the bit to set * @addr: the address to start counting from diff --git a/include/asm-cris/checksum.h b/include/asm-cris/checksum.h index 180dbf2757b..c6c5be62c69 100644 --- a/include/asm-cris/checksum.h +++ b/include/asm-cris/checksum.h @@ -62,7 +62,7 @@ static inline __sum16 ip_fast_csum(const void *iph, unsigned int ihl) * returns a 16-bit checksum, already complemented */ -static inline __sum16 int csum_tcpudp_magic(__be32 saddr, __be32 daddr, +static inline __sum16 csum_tcpudp_magic(__be32 saddr, __be32 daddr, unsigned short len, unsigned short proto, __wsum sum) diff --git a/include/asm-cris/elf.h b/include/asm-cris/elf.h index 96a40c1de57..001f64ad11e 100644 --- a/include/asm-cris/elf.h +++ b/include/asm-cris/elf.h @@ -45,7 +45,6 @@ typedef unsigned long elf_fpregset_t; #define ELF_DATA ELFDATA2LSB #define ELF_ARCH EM_CRIS -#ifdef __KERNEL__ #include <asm/arch/elf.h> /* The master for these definitions is {binutils}/include/elf/cris.h: */ @@ -91,6 +90,4 @@ typedef unsigned long elf_fpregset_t; #define SET_PERSONALITY(ex, ibcs2) set_personality((ibcs2)?PER_SVR4:PER_LINUX) -#endif /* __KERNEL__ */ - #endif diff --git a/include/asm-cris/ethernet.h b/include/asm-cris/ethernet.h index 30da58a7d00..4d58652c3a4 100644 --- a/include/asm-cris/ethernet.h +++ b/include/asm-cris/ethernet.h @@ -15,4 +15,7 @@ #define SET_ETH_DUPLEX_AUTO SIOCDEVPRIVATE+3 /* Auto neg duplex */ #define SET_ETH_DUPLEX_HALF SIOCDEVPRIVATE+4 /* Full duplex */ #define SET_ETH_DUPLEX_FULL SIOCDEVPRIVATE+5 /* Half duplex */ +#define SET_ETH_ENABLE_LEDS SIOCDEVPRIVATE+6 /* Enable net LEDs */ +#define SET_ETH_DISABLE_LEDS SIOCDEVPRIVATE+7 /* Disable net LEDs */ +#define SET_ETH_AUTONEG SIOCDEVPRIVATE+8 #endif /* _CRIS_ETHERNET_H */ diff --git a/include/asm-cris/fasttimer.h b/include/asm-cris/fasttimer.h index a3a77132ce3..8f8a8d6c965 100644 --- a/include/asm-cris/fasttimer.h +++ b/include/asm-cris/fasttimer.h @@ -1,9 +1,8 @@ -/* $Id: fasttimer.h,v 1.3 2004/05/14 10:19:19 starvik Exp $ +/* * linux/include/asm-cris/fasttimer.h * * Fast timers for ETRAX100LX - * This may be useful in other OS than Linux so use 2 space indentation... - * Copyright (C) 2000, 2002 Axis Communications AB + * Copyright (C) 2000-2007 Axis Communications AB */ #include <linux/time.h> /* struct timeval */ #include <linux/timex.h> @@ -12,11 +11,16 @@ typedef void fast_timer_function_type(unsigned long); +struct fasttime_t { + unsigned long tv_jiff; /* jiffies */ + unsigned long tv_usec; /* microseconds */ +}; + struct fast_timer{ /* Close to timer_list */ struct fast_timer *next; struct fast_timer *prev; - struct timeval tv_set; - struct timeval tv_expires; + struct fasttime_t tv_set; + struct fasttime_t tv_expires; unsigned long delay_us; fast_timer_function_type *function; unsigned long data; @@ -38,6 +42,6 @@ int del_fast_timer(struct fast_timer * t); void schedule_usleep(unsigned long us); -void fast_timer_init(void); +int fast_timer_init(void); #endif diff --git a/include/asm-cris/hardirq.h b/include/asm-cris/hardirq.h index 1c13dd3faac..74178adeb1c 100644 --- a/include/asm-cris/hardirq.h +++ b/include/asm-cris/hardirq.h @@ -1,6 +1,7 @@ #ifndef __ASM_HARDIRQ_H #define __ASM_HARDIRQ_H +#include <asm/irq.h> #include <linux/threads.h> #include <linux/cache.h> diff --git a/include/asm-cris/page.h b/include/asm-cris/page.h index 0648e3153f8..3b0156c4631 100644 --- a/include/asm-cris/page.h +++ b/include/asm-cris/page.h @@ -1,17 +1,12 @@ #ifndef _CRIS_PAGE_H #define _CRIS_PAGE_H -#ifdef __KERNEL__ - #include <asm/arch/page.h> +#include <linux/const.h> /* PAGE_SHIFT determines the page size */ #define PAGE_SHIFT 13 -#ifndef __ASSEMBLY__ -#define PAGE_SIZE (1UL << PAGE_SHIFT) -#else -#define PAGE_SIZE (1 << PAGE_SHIFT) -#endif +#define PAGE_SIZE (_AC(1, UL) << PAGE_SHIFT) #define PAGE_MASK (~(PAGE_SIZE-1)) #define clear_page(page) memset((void *)(page), 0, PAGE_SIZE) @@ -77,7 +72,5 @@ typedef struct { unsigned long pgprot; } pgprot_t; #include <asm-generic/memory_model.h> #include <asm-generic/page.h> -#endif /* __KERNEL__ */ - #endif /* _CRIS_PAGE_H */ diff --git a/include/asm-cris/pgalloc.h b/include/asm-cris/pgalloc.h index deaddfe79bb..8ddd66f8177 100644 --- a/include/asm-cris/pgalloc.h +++ b/include/asm-cris/pgalloc.h @@ -16,7 +16,7 @@ static inline pgd_t *pgd_alloc (struct mm_struct *mm) return (pgd_t *)get_zeroed_page(GFP_KERNEL); } -static inline void pgd_free (pgd_t *pgd) +static inline void pgd_free(struct mm_struct *mm, pgd_t *pgd) { free_page((unsigned long)pgd); } @@ -34,12 +34,12 @@ static inline struct page *pte_alloc_one(struct mm_struct *mm, unsigned long add return pte; } -static inline void pte_free_kernel(pte_t *pte) +static inline void pte_free_kernel(struct mm_struct *mm, pte_t *pte) { free_page((unsigned long)pte); } -static inline void pte_free(struct page *pte) +static inline void pte_free(struct mm_struct *mm, struct page *pte) { __free_page(pte); } diff --git a/include/asm-cris/posix_types.h b/include/asm-cris/posix_types.h index 92000d0c3f9..3a5e4c43eae 100644 --- a/include/asm-cris/posix_types.h +++ b/include/asm-cris/posix_types.h @@ -52,7 +52,6 @@ typedef struct { } __kernel_fsid_t; #ifdef __KERNEL__ -#include <linux/bitops.h> #undef __FD_SET #define __FD_SET(fd,fdsetp) set_bit(fd, (void *)(fdsetp)) diff --git a/include/asm-cris/socket.h b/include/asm-cris/socket.h index 5b18dfdf174..9df0ca82f5d 100644 --- a/include/asm-cris/socket.h +++ b/include/asm-cris/socket.h @@ -54,6 +54,8 @@ #define SO_TIMESTAMPNS 35 #define SCM_TIMESTAMPNS SO_TIMESTAMPNS +#define SO_MARK 36 + #endif /* _ASM_SOCKET_H */ diff --git a/include/asm-cris/system.h b/include/asm-cris/system.h index fea0e8d57cb..5bcfe5a1090 100644 --- a/include/asm-cris/system.h +++ b/include/asm-cris/system.h @@ -66,6 +66,21 @@ static inline unsigned long __xchg(unsigned long x, volatile void * ptr, int siz return x; } +#include <asm-generic/cmpxchg-local.h> + +/* + * cmpxchg_local and cmpxchg64_local are atomic wrt current CPU. Always make + * them available. + */ +#define cmpxchg_local(ptr, o, n) \ + ((__typeof__(*(ptr)))__cmpxchg_local_generic((ptr), (unsigned long)(o),\ + (unsigned long)(n), sizeof(*(ptr)))) +#define cmpxchg64_local(ptr, o, n) __cmpxchg64_local_generic((ptr), (o), (n)) + +#ifndef CONFIG_SMP +#include <asm-generic/cmpxchg.h> +#endif + #define arch_align_stack(x) (x) void default_idle(void); diff --git a/include/asm-cris/termbits.h b/include/asm-cris/termbits.h index 71c1b36269b..66e1a7492a0 100644 --- a/include/asm-cris/termbits.h +++ b/include/asm-cris/termbits.h @@ -171,6 +171,19 @@ struct ktermios { #define B115200 0010002 #define B230400 0010003 #define B460800 0010004 + +/* Unsupported rates, but needed to avoid compile error. */ +#define B500000 0010005 +#define B576000 0010006 +#define B1000000 0010010 +#define B1152000 0010011 +#define B1500000 0010012 +#define B2000000 0010013 +#define B2500000 0010014 +#define B3000000 0010015 +#define B3500000 0010016 +#define B4000000 0010017 + /* etrax supports these additional three baud rates */ #define B921600 0010005 #define B1843200 0010006 diff --git a/include/asm-cris/thread_info.h b/include/asm-cris/thread_info.h index fde39f6c49c..784668ab0fa 100644 --- a/include/asm-cris/thread_info.h +++ b/include/asm-cris/thread_info.h @@ -32,6 +32,7 @@ struct thread_info { unsigned long flags; /* low level flags */ __u32 cpu; /* current CPU */ int preempt_count; /* 0 => preemptable, <0 => BUG */ + __u32 tls; /* TLS for this thread */ mm_segment_t addr_limit; /* thread address space: 0-0xBFFFFFFF for user-thead @@ -79,14 +80,18 @@ struct thread_info { * - other flags in MSW */ #define TIF_SYSCALL_TRACE 0 /* syscall trace active */ -#define TIF_SIGPENDING 1 /* signal pending */ -#define TIF_NEED_RESCHED 2 /* rescheduling necessary */ +#define TIF_NOTIFY_RESUME 1 /* resumption notification requested */ +#define TIF_SIGPENDING 2 /* signal pending */ +#define TIF_NEED_RESCHED 3 /* rescheduling necessary */ +#define TIF_RESTORE_SIGMASK 9 /* restore signal mask in do_signal() */ #define TIF_POLLING_NRFLAG 16 /* true if poll_idle() is polling TIF_NEED_RESCHED */ #define TIF_MEMDIE 17 #define _TIF_SYSCALL_TRACE (1<<TIF_SYSCALL_TRACE) +#define _TIF_NOTIFY_RESUME (1<<TIF_NOTIFY_RESUME) #define _TIF_SIGPENDING (1<<TIF_SIGPENDING) #define _TIF_NEED_RESCHED (1<<TIF_NEED_RESCHED) +#define _TIF_RESTORE_SIGMASK (1<<TIF_RESTORE_SIGMASK) #define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) #define _TIF_WORK_MASK 0x0000FFFE /* work to do on interrupt/exception return */ diff --git a/include/asm-cris/tlb.h b/include/asm-cris/tlb.h index 6cc26debe40..7724246a260 100644 --- a/include/asm-cris/tlb.h +++ b/include/asm-cris/tlb.h @@ -1,6 +1,8 @@ #ifndef _CRIS_TLB_H #define _CRIS_TLB_H +#include <linux/pagemap.h> + #include <asm/arch/tlb.h> /* diff --git a/include/asm-cris/unistd.h b/include/asm-cris/unistd.h index 7c90fa970c3..bd57a794917 100644 --- a/include/asm-cris/unistd.h +++ b/include/asm-cris/unistd.h @@ -255,6 +255,7 @@ #define __NR_io_submit 248 #define __NR_io_cancel 249 #define __NR_fadvise64 250 +/* 251 is available for reuse (was briefly sys_set_zone_reclaim) */ #define __NR_exit_group 252 #define __NR_lookup_dcookie 253 #define __NR_epoll_create 254 @@ -292,10 +293,46 @@ #define __NR_add_key 286 #define __NR_request_key 287 #define __NR_keyctl 288 +#define __NR_ioprio_set 289 +#define __NR_ioprio_get 290 +#define __NR_inotify_init 291 +#define __NR_inotify_add_watch 292 +#define __NR_inotify_rm_watch 293 +#define __NR_migrate_pages 294 +#define __NR_openat 295 +#define __NR_mkdirat 296 +#define __NR_mknodat 297 +#define __NR_fchownat 298 +#define __NR_futimesat 299 +#define __NR_fstatat64 300 +#define __NR_unlinkat 301 +#define __NR_renameat 302 +#define __NR_linkat 303 +#define __NR_symlinkat 304 +#define __NR_readlinkat 305 +#define __NR_fchmodat 306 +#define __NR_faccessat 307 +#define __NR_pselect6 308 +#define __NR_ppoll 309 +#define __NR_unshare 310 +#define __NR_set_robust_list 311 +#define __NR_get_robust_list 312 +#define __NR_splice 313 +#define __NR_sync_file_range 314 +#define __NR_tee 315 +#define __NR_vmsplice 316 +#define __NR_move_pages 317 +#define __NR_getcpu 318 +#define __NR_epoll_pwait 319 +#define __NR_utimensat 320 +#define __NR_signalfd 321 +#define __NR_timerfd 322 +#define __NR_eventfd 323 +#define __NR_fallocate 324 #ifdef __KERNEL__ -#define NR_syscalls 289 +#define NR_syscalls 325 #include <asm/arch/unistd.h> @@ -321,6 +358,7 @@ #define __ARCH_WANT_SYS_SIGPENDING #define __ARCH_WANT_SYS_SIGPROCMASK #define __ARCH_WANT_SYS_RT_SIGACTION +#define __ARCH_WANT_SYS_RT_SIGSUSPEND /* * "Conditional" syscalls diff --git a/include/asm-cris/user.h b/include/asm-cris/user.h index 2538e2a003d..73e60fcbcf3 100644 --- a/include/asm-cris/user.h +++ b/include/asm-cris/user.h @@ -38,7 +38,7 @@ struct user { unsigned long start_data; /* data starting address */ unsigned long start_stack; /* stack starting address */ long int signal; /* signal causing core dump */ - struct regs * u_ar0; /* help gdb find registers */ + unsigned long u_ar0; /* help gdb find registers */ unsigned long magic; /* identifies a core file */ char u_comm[32]; /* user command name */ }; |