Changeset 441 for GPL/trunk/include/linux
- Timestamp:
- Jun 6, 2009, 4:22:27 AM (16 years ago)
- Location:
- GPL/trunk/include/linux
- Files:
-
- 24 edited
Legend:
- Unmodified
- Added
- Removed
-
GPL/trunk/include/linux/bitops.h
r32 r441 1 /* $Id: bitops.h,v 1.1.1.1 2003/07/02 13:57:00 eleph Exp $ */2 3 1 #ifndef _I386_BITOPS_H 4 2 #define _I386_BITOPS_H … … 20 18 */ 21 19 #include <asm\bitops.h> 22 20 #define smp_mb__after_clear_bit() 23 21 #endif /* _I386_BITOPS_H */ -
GPL/trunk/include/linux/capability.h
r305 r441 3 3 #ifndef _LINUX_CAPABILITY_H 4 4 #define _LINUX_CAPABILITY_H 5 5 #define capable(a) 1 6 #define CAP_SYS_ADMIN 0 6 7 #endif /* _LINUX_CAPABILITY_H */ -
GPL/trunk/include/linux/compiler-gcc.h
r305 r441 9 9 /* The "volatile" is due to gcc bugs */ 10 10 //#define barrier() __asm__ __volatile__("": : :"memory") 11 #define barrier 11 #define barrier() 12 12 13 13 /* This macro obfuscates arithmetic on a variable address so that gcc -
GPL/trunk/include/linux/compiler.h
r305 r441 10 10 # define __kernel 11 11 # define __safe 12 # define __nocast 13 # define __iomem 14 # define __deprecated /* unimplemented */ 12 15 #endif 13 16 … … 41 44 #define unlikely(x) __builtin_expect(!!(x), 0) 42 45 43 /* Optimization barrier */44 #ifndef barrier45 # define barrier() __memory_barrier()46 #endif47 46 48 47 #ifndef RELOC_HIDE -
GPL/trunk/include/linux/device.h
r305 r441 3 3 #ifndef _LINUX_DEVICE_H 4 4 #define _LINUX_DEVICE_H 5 #include < sound/config.h>5 #include <linux/pm.h> 6 6 #if 0 7 7 struct device { … … 42 42 #define dev_get_drvdata(dev) (dev)->private_data 43 43 44 #define MODULE_ALIAS_CHARDEV_MAJOR(x) 44 45 45 46 #endif /* _LINUX_DEVICE_H */ -
GPL/trunk/include/linux/dma-mapping.h
r305 r441 29 29 #define DMA_24BIT_MASK 0x0000000000ffffffULL 30 30 #endif 31 31 #define DMA_BIT_MASK(n) (((n) == 64) ? ~0ULL : ((1ULL<<(n))-1)) 32 32 #endif 33 33 -
GPL/trunk/include/linux/fs.h
r305 r441 264 264 extern void kill_fasync(struct fasync_struct *, int, int); 265 265 266 #define fops_get(x) (x) 267 #define fops_put(x) do { ; } while (0) 268 #define imajor(x) major((x)->i_rdev) 269 266 270 #endif /* _LINUX_FS_H */ -
GPL/trunk/include/linux/init.h
r32 r441 1 /* $Id: init.h,v 1.1.1.1 2003/07/02 13:57:00 eleph Exp $ */2 3 1 #ifndef _LINUX_INIT_H 4 2 #define _LINUX_INIT_H … … 138 136 #endif 139 137 138 #define __devexit_p(x) x 139 140 140 #endif /* _LINUX_INIT_H */ -
GPL/trunk/include/linux/interrupt.h
r438 r441 26 26 #define IRQ_HANDLED (1) 27 27 #define IRQ_RETVAL(x) ((x) != 0) 28 29 #include <linux/signal.h> 30 #define IRQF_SHARED SA_SHIRQ 31 #define IRQF_DISABLED SA_INTERRUPT 32 #define IRQF_SAMPLE_RANDOM SA_SAMPLE_RANDOM 33 #define IRQF_PERCPU SA_PERCPU 34 #ifdef SA_PROBEIRQ 35 #define IRQF_PROBE_SHARED SA_PROBEIRQ 36 #else 37 #define IRQF_PROBE_SHARED 0 /* dummy */ 38 #endif 28 39 29 40 struct irqaction { … … 132 143 extern int probe_irq_off(unsigned long); /* returns 0 or negative on failure */ 133 144 145 typedef irqreturn_t (*snd_irq_handler_t)(int, void *); 146 #define irq_handler_t snd_irq_handler_t 147 #undef irq_handler_t 148 #define irq_handler_t snd_irq_handler_t 149 150 int request_irq(unsigned int, irq_handler_t handler, 151 unsigned long, const char *, void *); 152 134 153 #endif -
GPL/trunk/include/linux/kernel.h
r319 r441 1 /* $Id: kernel.h,v 1.1.1.1 2003/07/02 13:57:00 eleph Exp $ */2 3 1 #ifndef _LINUX_KERNEL_H 4 2 #define _LINUX_KERNEL_H … … 99 97 100 98 static void complete_and_exit(struct completion *, long); 99 #define printk_ratelimit() 1 100 #define ALIGN(x,a) (((x)+(a)-1)&~((a)-1)) 101 #define dump_stack() 102 #define upper_32_bits(n) ((u32)(((n) >> 16) >> 16)) 101 103 102 104 #endif -
GPL/trunk/include/linux/list.h
r32 r441 112 112 #endif /* __KERNEL__ */ 113 113 114 #define container_of(ptr, type, member) \ 115 ( (type *)( (char *)ptr - offsetof(type,member) ) ) 116 _WCRTLINK extern int snprintf( char *__buf, size_t __bufsize, 117 const char *__fmt, ... ); 118 #define offsetof(__typ,__id) ((size_t)&(((__typ*)0)->__id)) 119 #define list_for_each_entry(itemptr, headptr, struct_listmember_name, container_type) \ 120 for (itemptr=(container_type *) \ 121 (((char *)((headptr)->next))-offsetof(container_type, struct_listmember_name)); \ 122 &(itemptr->struct_listmember_name)!=(headptr); \ 123 itemptr=(container_type *) \ 124 (((char *)(itemptr->struct_listmember_name.next))-offsetof(container_type, struct_listmember_name))) 125 126 #define list_for_each_entry_safe(itemptr, n, headptr, struct_listmember_name, container_type) \ 127 for (itemptr=(container_type *) \ 128 (((char *)((headptr)->next))-offsetof(container_type, struct_listmember_name)), \ 129 n=(container_type *) \ 130 (((char *)(itemptr->struct_listmember_name.next))-offsetof(container_type, struct_listmember_name)); \ 131 &(itemptr->struct_listmember_name)!=(headptr); \ 132 itemptr=n, \ 133 n=(container_type *) \ 134 (((char *)(n->struct_listmember_name.next))-offsetof(container_type, struct_listmember_name))) 135 136 /** 137 * list_move_tail - delete from one list and add as another's tail 138 * @list: the entry to move 139 * @head: the head that will follow our entry 140 */ 141 static inline void list_move_tail(struct list_head *list, 142 struct list_head *head) 143 { 144 __list_del(list->prev, list->next); 145 list_add_tail(list, head); 146 } 147 114 148 #endif -
GPL/trunk/include/linux/mm.h
r305 r441 171 171 }; 172 172 173 #define SetPageReserved(a) a 174 #define ClearPageReserved(a) a 175 173 176 #endif -
GPL/trunk/include/linux/module.h
r280 r441 59 59 #endif 60 60 61 #define try_inc_mod_count(x) ++(*(unsigned long *)x) 62 #define try_module_get(x) try_inc_mod_count(x) 63 static inline void module_put(struct module *module) 64 { 65 if (module) 66 do {} while(0); 67 } 68 69 #define MODULE_FIRMWARE(x) 70 #define MODULE_ALIAS(x) 71 61 72 #endif /* _LINUX_MODULE_H */ -
GPL/trunk/include/linux/pci.h
r428 r441 295 295 typedef struct pci_dev; 296 296 297 297 #define PCI_D0 0 298 #define PCI_D1 1 299 #define PCI_D2 2 300 #define PCI_D3hot 3 301 #define PCI_D3cold 4 302 #define pci_choose_state(pci,state) ((state) ? PCI_D3hot : PCI_D0) 298 303 299 304 typedef struct device { … … 678 683 679 684 #endif /* __KERNEL__ */ 685 686 static inline unsigned char snd_pci_revision(struct pci_dev *pci) 687 { 688 unsigned char rev; 689 pci_read_config_byte(pci, PCI_REVISION_ID, &rev); 690 return rev; 691 } 692 693 /* pci_intx() wrapper */ 694 #define pci_intx(pci,x) 695 696 /* MSI */ 697 static inline int snd_pci_enable_msi(struct pci_dev *dev) { return -1; } 698 #undef pci_enable_msi 699 #define pci_enable_msi(dev) snd_pci_enable_msi(dev) 700 #undef pci_disable_msi 701 #define pci_disable_msi(dev) 702 #define pci_dev_present(x) snd_pci_dev_present(x) 703 extern void * __ioremap(unsigned long offset, unsigned long size, unsigned long flags); 704 static inline void *pci_ioremap_bar(struct pci_dev *pdev, int bar) 705 { 706 return __ioremap(pci_resource_start(pdev, bar), 707 pci_resource_len(pdev, bar),0x010); 708 } 709 680 710 #endif /* LINUX_PCI_H */ -
GPL/trunk/include/linux/pm.h
r305 r441 249 249 #endif /* __KERNEL__ */ 250 250 251 typedef u32 __bitwise pm_message_t; 252 #define PMSG_FREEZE 3 253 #define PMSG_SUSPEND 3 254 #define PMSG_ON 0 255 251 256 #endif /* _LINUX_PM_H */ -
GPL/trunk/include/linux/pnp.h
r249 r441 19 19 #endif /* TARGET_OS2 */ 20 20 #include <linux/list.h> 21 #include <linux/pm.h> 21 22 22 23 #define PNP_MAX_PORT 8 -
GPL/trunk/include/linux/proc_fs.h
r305 r441 236 236 #endif /* CONFIG_PROC_FS */ 237 237 238 static inline struct proc_dir_entry *PDE(const struct inode *inode) 239 { 240 return (struct proc_dir_entry *) inode->u.generic_ip; 241 } 242 238 243 #endif /* _LINUX_PROC_FS_H */ -
GPL/trunk/include/linux/sched.h
r351 r441 14 14 #define TASK_SWAPPING 16 15 15 #define TASK_EXCLUSIVE 32 16 17 #define set_current_state(a) 16 18 17 19 struct task_struct { … … 47 49 void schedule(void); 48 50 51 #define cond_resched() \ 52 do { \ 53 if (1) { \ 54 set_current_state(TASK_RUNNING); \ 55 schedule(); \ 56 } \ 57 } while (0) 58 49 59 // 12 Jun 07 SHL Drop superfluous near 50 60 #if 0 … … 68 78 } 69 79 80 #define flush_scheduled_work() 81 82 #define schedule_timeout_interruptible(x) \ 83 set_current_state(TASK_INTERRUPTIBLE); \ 84 schedule_timeout(x); 85 86 #define schedule_timeout_uninterruptible(x) \ 87 set_current_state(TASK_UNINTERRUPTIBLE); \ 88 schedule_timeout(x); 89 70 90 #endif /* _LINUX_SCHED_H */ -
GPL/trunk/include/linux/spinlock.h
r32 r441 78 78 #define write_unlock(lock) spin_unlock(lock) 79 79 80 #define rwlock_init(x) *(x) = RW_LOCK_UNLOCKED; 81 80 82 #endif /* !SMP */ 81 83 #endif /* __LINUX_SPINLOCK_H */ -
GPL/trunk/include/linux/string.h
r305 r441 10 10 int strncmp (const char *string1, const char *string2, size_t count); 11 11 #endif 12 12 13 #endif 13 14 -
GPL/trunk/include/linux/time.h
r32 r441 114 114 #endif 115 115 116 /* wrapper for getnstimeofday() 117 * it's needed for recent 2.6 kernels, too, due to lack of EXPORT_SYMBOL 118 */ 119 #define getnstimeofday(x) do { \ 120 struct timeval __x; \ 121 do_gettimeofday(&__x); \ 122 (x)->tv_sec = __x.tv_sec; \ 123 (x)->tv_nsec = __x.tv_usec * 1000; \ 124 } while (0) 125 126 #define do_posix_clock_monotonic_gettime getnstimeofday 127 116 128 #endif -
GPL/trunk/include/linux/types.h
r120 r441 1 /* $Id: types.h,v 1.1.1.1 2003/07/02 13:57:02 eleph Exp $ */2 3 1 #ifndef _LINUX_TYPES_H 4 2 #define _LINUX_TYPES_H … … 7 5 8 6 #include <linux/posix_types.h> 7 #include <linux/compiler.h> 9 8 #include <asm/types.h> 10 9 … … 72 71 typedef unsigned long ulong; 73 72 73 #define BITS_PER_LONG 32 74 74 75 typedef unsigned long dma_addr_t; 75 76 … … 131 132 #endif 132 133 134 typedef unsigned __nocast gfp_t; 135 133 136 #include <string.h> 134 137 typedef __u32 __le32; 135 138 #endif /* _LINUX_TYPES_H */ -
GPL/trunk/include/linux/uio.h
r305 r441 3 3 #ifndef _LINUX_UIO_H 4 4 #define _LINUX_UIO_H 5 struct iovec { 6 char *iov_base; /* Base address. */ 7 #ifdef __32BIT__ 8 size_t iov_len; /* Length. */ 9 #else 10 long iov_len; /* Length. */ 11 #endif 12 }; 5 13 6 14 #endif /* _LINUX_UIO_H */ -
GPL/trunk/include/linux/workqueue.h
r305 r441 1 1 #ifndef __LINUX_WORKQUEUE_H 2 2 #define __LINUX_WORKQUEUE_H 3 struct work_struct { 4 unsigned long pending; 5 struct list_head entry; 6 void (*func)(void *); 7 void *data; 8 void *wq_data; 9 struct timer_list timer; 10 }; 11 12 struct delayed_work { 13 struct work_struct work; 14 }; 15 16 #define INIT_WORK(_work, _func, _data) \ 17 do { \ 18 (_work)->func = _func; \ 19 (_work)->data = _data; \ 20 init_timer(&(_work)->timer); \ 21 } while (0) 22 #define __WORK_INITIALIZER(n, f, d) { \ 23 .func = (f), \ 24 .data = (d), \ 25 } 26 #define DECLARE_WORK(n, f, d) \ 27 struct work_struct n = __WORK_INITIALIZER(n, f, d) 28 29 /* redefine INIT_WORK() */ 30 static inline void snd_INIT_WORK(struct work_struct *w, void (*f)(struct work_struct *)) 31 { 32 INIT_WORK(w, (void(*)(void*))(f), w); 33 } 34 #undef INIT_WORK 35 #define INIT_WORK(w,f) snd_INIT_WORK(w,f) 36 #define create_singlethread_workqueue(name) create_workqueue(name) 3 37 #endif /* __LINUX_WORKQUEUE_H */
Note:
See TracChangeset
for help on using the changeset viewer.