diff options
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/compat_ioctl.h | 15 | ||||
| -rw-r--r-- | include/linux/cpu.h | 5 | ||||
| -rw-r--r-- | include/linux/eeprom.h | 136 | ||||
| -rw-r--r-- | include/linux/fb.h | 23 | ||||
| -rw-r--r-- | include/linux/fs.h | 6 | ||||
| -rw-r--r-- | include/linux/fs_enet_pd.h | 1 | ||||
| -rw-r--r-- | include/linux/i2c-id.h | 18 | ||||
| -rw-r--r-- | include/linux/if_wanpipe_common.h | 2 | ||||
| -rw-r--r-- | include/linux/istallion.h | 2 | ||||
| -rw-r--r-- | include/linux/libata.h | 6 | ||||
| -rw-r--r-- | include/linux/mtd/cfi.h | 1 | ||||
| -rw-r--r-- | include/linux/mtd/mtd.h | 1 | ||||
| -rw-r--r-- | include/linux/namei.h | 2 | ||||
| -rw-r--r-- | include/linux/phonedev.h | 1 | ||||
| -rw-r--r-- | include/linux/proc_fs.h | 1 | ||||
| -rw-r--r-- | include/linux/raid/bitmap.h | 11 | ||||
| -rw-r--r-- | include/linux/raid/md.h | 5 | ||||
| -rw-r--r-- | include/linux/raid/md_k.h | 40 | ||||
| -rw-r--r-- | include/linux/raid/raid1.h | 4 | ||||
| -rw-r--r-- | include/linux/raid/raid5.h | 2 | ||||
| -rw-r--r-- | include/linux/sched.h | 1 | ||||
| -rw-r--r-- | include/linux/stallion.h | 2 | ||||
| -rw-r--r-- | include/linux/sysctl.h | 3 | ||||
| -rw-r--r-- | include/linux/videodev.h | 82 | ||||
| -rw-r--r-- | include/linux/videodev2.h | 207 |
25 files changed, 266 insertions, 311 deletions
diff --git a/include/linux/compat_ioctl.h b/include/linux/compat_ioctl.h index ecb0d39c0798..2209ad3499a3 100644 --- a/include/linux/compat_ioctl.h +++ b/include/linux/compat_ioctl.h | |||
| @@ -10,6 +10,10 @@ | |||
| 10 | #define ULONG_IOCTL(cmd) HANDLE_IOCTL((cmd),(ioctl_trans_handler_t)sys_ioctl) | 10 | #define ULONG_IOCTL(cmd) HANDLE_IOCTL((cmd),(ioctl_trans_handler_t)sys_ioctl) |
| 11 | #endif | 11 | #endif |
| 12 | 12 | ||
| 13 | |||
| 14 | COMPATIBLE_IOCTL(0x4B50) /* KDGHWCLK - not in the kernel, but don't complain */ | ||
| 15 | COMPATIBLE_IOCTL(0x4B51) /* KDSHWCLK - not in the kernel, but don't complain */ | ||
| 16 | |||
| 13 | /* Big T */ | 17 | /* Big T */ |
| 14 | COMPATIBLE_IOCTL(TCGETA) | 18 | COMPATIBLE_IOCTL(TCGETA) |
| 15 | COMPATIBLE_IOCTL(TCSETA) | 19 | COMPATIBLE_IOCTL(TCSETA) |
| @@ -52,13 +56,6 @@ ULONG_IOCTL(TIOCSCTTY) | |||
| 52 | COMPATIBLE_IOCTL(TIOCGPTN) | 56 | COMPATIBLE_IOCTL(TIOCGPTN) |
| 53 | COMPATIBLE_IOCTL(TIOCSPTLCK) | 57 | COMPATIBLE_IOCTL(TIOCSPTLCK) |
| 54 | COMPATIBLE_IOCTL(TIOCSERGETLSR) | 58 | COMPATIBLE_IOCTL(TIOCSERGETLSR) |
| 55 | /* Big F */ | ||
| 56 | COMPATIBLE_IOCTL(FBIOBLANK) | ||
| 57 | COMPATIBLE_IOCTL(FBIOGET_VSCREENINFO) | ||
| 58 | COMPATIBLE_IOCTL(FBIOPUT_VSCREENINFO) | ||
| 59 | COMPATIBLE_IOCTL(FBIOPAN_DISPLAY) | ||
| 60 | COMPATIBLE_IOCTL(FBIOGET_CON2FBMAP) | ||
| 61 | COMPATIBLE_IOCTL(FBIOPUT_CON2FBMAP) | ||
| 62 | /* Little f */ | 59 | /* Little f */ |
| 63 | COMPATIBLE_IOCTL(FIOCLEX) | 60 | COMPATIBLE_IOCTL(FIOCLEX) |
| 64 | COMPATIBLE_IOCTL(FIONCLEX) | 61 | COMPATIBLE_IOCTL(FIONCLEX) |
| @@ -81,6 +78,8 @@ COMPATIBLE_IOCTL(HDIO_DRIVE_CMD) | |||
| 81 | COMPATIBLE_IOCTL(HDIO_DRIVE_TASK) | 78 | COMPATIBLE_IOCTL(HDIO_DRIVE_TASK) |
| 82 | COMPATIBLE_IOCTL(HDIO_SET_PIO_MODE) | 79 | COMPATIBLE_IOCTL(HDIO_SET_PIO_MODE) |
| 83 | COMPATIBLE_IOCTL(HDIO_SET_NICE) | 80 | COMPATIBLE_IOCTL(HDIO_SET_NICE) |
| 81 | COMPATIBLE_IOCTL(HDIO_SET_KEEPSETTINGS) | ||
| 82 | COMPATIBLE_IOCTL(HDIO_SCAN_HWIF) | ||
| 84 | /* 0x02 -- Floppy ioctls */ | 83 | /* 0x02 -- Floppy ioctls */ |
| 85 | COMPATIBLE_IOCTL(FDMSGON) | 84 | COMPATIBLE_IOCTL(FDMSGON) |
| 86 | COMPATIBLE_IOCTL(FDMSGOFF) | 85 | COMPATIBLE_IOCTL(FDMSGOFF) |
| @@ -99,6 +98,7 @@ COMPATIBLE_IOCTL(FDTWADDLE) | |||
| 99 | COMPATIBLE_IOCTL(FDFMTTRK) | 98 | COMPATIBLE_IOCTL(FDFMTTRK) |
| 100 | COMPATIBLE_IOCTL(FDRAWCMD) | 99 | COMPATIBLE_IOCTL(FDRAWCMD) |
| 101 | /* 0x12 */ | 100 | /* 0x12 */ |
| 101 | COMPATIBLE_IOCTL(BLKRASET) | ||
| 102 | COMPATIBLE_IOCTL(BLKROSET) | 102 | COMPATIBLE_IOCTL(BLKROSET) |
| 103 | COMPATIBLE_IOCTL(BLKROGET) | 103 | COMPATIBLE_IOCTL(BLKROGET) |
| 104 | COMPATIBLE_IOCTL(BLKRRPART) | 104 | COMPATIBLE_IOCTL(BLKRRPART) |
| @@ -262,6 +262,7 @@ COMPATIBLE_IOCTL(RTC_WKALM_RD) | |||
| 262 | /* Little m */ | 262 | /* Little m */ |
| 263 | COMPATIBLE_IOCTL(MTIOCTOP) | 263 | COMPATIBLE_IOCTL(MTIOCTOP) |
| 264 | /* Socket level stuff */ | 264 | /* Socket level stuff */ |
| 265 | COMPATIBLE_IOCTL(FIOQSIZE) | ||
| 265 | COMPATIBLE_IOCTL(FIOSETOWN) | 266 | COMPATIBLE_IOCTL(FIOSETOWN) |
| 266 | COMPATIBLE_IOCTL(SIOCSPGRP) | 267 | COMPATIBLE_IOCTL(SIOCSPGRP) |
| 267 | COMPATIBLE_IOCTL(FIOGETOWN) | 268 | COMPATIBLE_IOCTL(FIOGETOWN) |
diff --git a/include/linux/cpu.h b/include/linux/cpu.h index 1f7b2c097503..43c44530ef9d 100644 --- a/include/linux/cpu.h +++ b/include/linux/cpu.h | |||
| @@ -42,6 +42,7 @@ struct notifier_block; | |||
| 42 | /* Need to know about CPUs going up/down? */ | 42 | /* Need to know about CPUs going up/down? */ |
| 43 | extern int register_cpu_notifier(struct notifier_block *nb); | 43 | extern int register_cpu_notifier(struct notifier_block *nb); |
| 44 | extern void unregister_cpu_notifier(struct notifier_block *nb); | 44 | extern void unregister_cpu_notifier(struct notifier_block *nb); |
| 45 | extern int current_in_cpu_hotplug(void); | ||
| 45 | 46 | ||
| 46 | int cpu_up(unsigned int cpu); | 47 | int cpu_up(unsigned int cpu); |
| 47 | 48 | ||
| @@ -54,6 +55,10 @@ static inline int register_cpu_notifier(struct notifier_block *nb) | |||
| 54 | static inline void unregister_cpu_notifier(struct notifier_block *nb) | 55 | static inline void unregister_cpu_notifier(struct notifier_block *nb) |
| 55 | { | 56 | { |
| 56 | } | 57 | } |
| 58 | static inline int current_in_cpu_hotplug(void) | ||
| 59 | { | ||
| 60 | return 0; | ||
| 61 | } | ||
| 57 | 62 | ||
| 58 | #endif /* CONFIG_SMP */ | 63 | #endif /* CONFIG_SMP */ |
| 59 | extern struct sysdev_class cpu_sysdev_class; | 64 | extern struct sysdev_class cpu_sysdev_class; |
diff --git a/include/linux/eeprom.h b/include/linux/eeprom.h deleted file mode 100644 index 38afd9da1dfe..000000000000 --- a/include/linux/eeprom.h +++ /dev/null | |||
| @@ -1,136 +0,0 @@ | |||
| 1 | /* credit winbond-840.c | ||
| 2 | */ | ||
| 3 | #include <asm/io.h> | ||
| 4 | struct eeprom_ops { | ||
| 5 | void (*set_cs)(void *ee); | ||
| 6 | void (*clear_cs)(void *ee); | ||
| 7 | }; | ||
| 8 | |||
| 9 | #define EEPOL_EEDI 0x01 | ||
| 10 | #define EEPOL_EEDO 0x02 | ||
| 11 | #define EEPOL_EECLK 0x04 | ||
| 12 | #define EEPOL_EESEL 0x08 | ||
| 13 | |||
| 14 | struct eeprom { | ||
| 15 | void *dev; | ||
| 16 | struct eeprom_ops *ops; | ||
| 17 | |||
| 18 | void __iomem * addr; | ||
| 19 | |||
| 20 | unsigned ee_addr_bits; | ||
| 21 | |||
| 22 | unsigned eesel; | ||
| 23 | unsigned eeclk; | ||
| 24 | unsigned eedo; | ||
| 25 | unsigned eedi; | ||
| 26 | unsigned polarity; | ||
| 27 | unsigned ee_state; | ||
| 28 | |||
| 29 | spinlock_t *lock; | ||
| 30 | u32 *cache; | ||
| 31 | }; | ||
| 32 | |||
| 33 | |||
| 34 | u8 eeprom_readb(struct eeprom *ee, unsigned address); | ||
| 35 | void eeprom_read(struct eeprom *ee, unsigned address, u8 *bytes, | ||
| 36 | unsigned count); | ||
| 37 | void eeprom_writeb(struct eeprom *ee, unsigned address, u8 data); | ||
| 38 | void eeprom_write(struct eeprom *ee, unsigned address, u8 *bytes, | ||
| 39 | unsigned count); | ||
| 40 | |||
| 41 | /* The EEPROM commands include the alway-set leading bit. */ | ||
| 42 | enum EEPROM_Cmds { | ||
| 43 | EE_WriteCmd=(5 << 6), EE_ReadCmd=(6 << 6), EE_EraseCmd=(7 << 6), | ||
| 44 | }; | ||
| 45 | |||
| 46 | void setup_ee_mem_bitbanger(struct eeprom *ee, void __iomem *memaddr, int eesel_bit, int eeclk_bit, int eedo_bit, int eedi_bit, unsigned polarity) | ||
| 47 | { | ||
| 48 | ee->addr = memaddr; | ||
| 49 | ee->eesel = 1 << eesel_bit; | ||
| 50 | ee->eeclk = 1 << eeclk_bit; | ||
| 51 | ee->eedo = 1 << eedo_bit; | ||
| 52 | ee->eedi = 1 << eedi_bit; | ||
| 53 | |||
| 54 | ee->polarity = polarity; | ||
| 55 | |||
| 56 | *ee->cache = readl(ee->addr); | ||
| 57 | } | ||
| 58 | |||
| 59 | /* foo. put this in a .c file */ | ||
| 60 | static inline void eeprom_update(struct eeprom *ee, u32 mask, int pol) | ||
| 61 | { | ||
| 62 | unsigned long flags; | ||
| 63 | u32 data; | ||
| 64 | |||
| 65 | spin_lock_irqsave(ee->lock, flags); | ||
| 66 | data = *ee->cache; | ||
| 67 | |||
| 68 | data &= ~mask; | ||
| 69 | if (pol) | ||
| 70 | data |= mask; | ||
| 71 | |||
| 72 | *ee->cache = data; | ||
| 73 | //printk("update: %08x\n", data); | ||
| 74 | writel(data, ee->addr); | ||
| 75 | spin_unlock_irqrestore(ee->lock, flags); | ||
| 76 | } | ||
| 77 | |||
| 78 | void eeprom_clk_lo(struct eeprom *ee) | ||
| 79 | { | ||
| 80 | int pol = !!(ee->polarity & EEPOL_EECLK); | ||
| 81 | |||
| 82 | eeprom_update(ee, ee->eeclk, pol); | ||
| 83 | udelay(2); | ||
| 84 | } | ||
| 85 | |||
| 86 | void eeprom_clk_hi(struct eeprom *ee) | ||
| 87 | { | ||
| 88 | int pol = !!(ee->polarity & EEPOL_EECLK); | ||
| 89 | |||
| 90 | eeprom_update(ee, ee->eeclk, !pol); | ||
| 91 | udelay(2); | ||
| 92 | } | ||
| 93 | |||
| 94 | void eeprom_send_addr(struct eeprom *ee, unsigned address) | ||
| 95 | { | ||
| 96 | int pol = !!(ee->polarity & EEPOL_EEDI); | ||
| 97 | unsigned i; | ||
| 98 | address |= 6 << 6; | ||
| 99 | |||
| 100 | /* Shift the read command bits out. */ | ||
| 101 | for (i=0; i<11; i++) { | ||
| 102 | eeprom_update(ee, ee->eedi, ((address >> 10) & 1) ^ pol); | ||
| 103 | address <<= 1; | ||
| 104 | eeprom_clk_hi(ee); | ||
| 105 | eeprom_clk_lo(ee); | ||
| 106 | } | ||
| 107 | eeprom_update(ee, ee->eedi, pol); | ||
| 108 | } | ||
| 109 | |||
| 110 | u16 eeprom_readw(struct eeprom *ee, unsigned address) | ||
| 111 | { | ||
| 112 | unsigned i; | ||
| 113 | u16 res = 0; | ||
| 114 | |||
| 115 | eeprom_clk_lo(ee); | ||
| 116 | eeprom_update(ee, ee->eesel, 1 ^ !!(ee->polarity & EEPOL_EESEL)); | ||
| 117 | eeprom_send_addr(ee, address); | ||
| 118 | |||
| 119 | for (i=0; i<16; i++) { | ||
| 120 | u32 data; | ||
| 121 | eeprom_clk_hi(ee); | ||
| 122 | res <<= 1; | ||
| 123 | data = readl(ee->addr); | ||
| 124 | //printk("eeprom_readw: %08x\n", data); | ||
| 125 | res |= !!(data & ee->eedo) ^ !!(ee->polarity & EEPOL_EEDO); | ||
| 126 | eeprom_clk_lo(ee); | ||
| 127 | } | ||
| 128 | eeprom_update(ee, ee->eesel, 0 ^ !!(ee->polarity & EEPOL_EESEL)); | ||
| 129 | |||
| 130 | return res; | ||
| 131 | } | ||
| 132 | |||
| 133 | |||
| 134 | void eeprom_writeb(struct eeprom *ee, unsigned address, u8 data) | ||
| 135 | { | ||
| 136 | } | ||
diff --git a/include/linux/fb.h b/include/linux/fb.h index e7ff98e395f6..04a58f33ec53 100644 --- a/include/linux/fb.h +++ b/include/linux/fb.h | |||
| @@ -201,6 +201,14 @@ struct fb_bitfield { | |||
| 201 | #define FB_VMODE_SMOOTH_XPAN 512 /* smooth xpan possible (internally used) */ | 201 | #define FB_VMODE_SMOOTH_XPAN 512 /* smooth xpan possible (internally used) */ |
| 202 | #define FB_VMODE_CONUPDATE 512 /* don't update x/yoffset */ | 202 | #define FB_VMODE_CONUPDATE 512 /* don't update x/yoffset */ |
| 203 | 203 | ||
| 204 | /* | ||
| 205 | * Display rotation support | ||
| 206 | */ | ||
| 207 | #define FB_ROTATE_UR 0 | ||
| 208 | #define FB_ROTATE_CW 1 | ||
| 209 | #define FB_ROTATE_UD 2 | ||
| 210 | #define FB_ROTATE_CCW 3 | ||
| 211 | |||
| 204 | #define PICOS2KHZ(a) (1000000000UL/(a)) | 212 | #define PICOS2KHZ(a) (1000000000UL/(a)) |
| 205 | #define KHZ2PICOS(a) (1000000000UL/(a)) | 213 | #define KHZ2PICOS(a) (1000000000UL/(a)) |
| 206 | 214 | ||
| @@ -489,9 +497,9 @@ struct fb_cursor_user { | |||
| 489 | #define FB_EVENT_MODE_DELETE 0x04 | 497 | #define FB_EVENT_MODE_DELETE 0x04 |
| 490 | /* A driver registered itself */ | 498 | /* A driver registered itself */ |
| 491 | #define FB_EVENT_FB_REGISTERED 0x05 | 499 | #define FB_EVENT_FB_REGISTERED 0x05 |
| 492 | /* get console to framebuffer mapping */ | 500 | /* CONSOLE-SPECIFIC: get console to framebuffer mapping */ |
| 493 | #define FB_EVENT_GET_CONSOLE_MAP 0x06 | 501 | #define FB_EVENT_GET_CONSOLE_MAP 0x06 |
| 494 | /* set console to framebuffer mapping */ | 502 | /* CONSOLE-SPECIFIC: set console to framebuffer mapping */ |
| 495 | #define FB_EVENT_SET_CONSOLE_MAP 0x07 | 503 | #define FB_EVENT_SET_CONSOLE_MAP 0x07 |
| 496 | /* A display blank is requested */ | 504 | /* A display blank is requested */ |
| 497 | #define FB_EVENT_BLANK 0x08 | 505 | #define FB_EVENT_BLANK 0x08 |
| @@ -500,6 +508,12 @@ struct fb_cursor_user { | |||
| 500 | /* The resolution of the passed in fb_info about to change and | 508 | /* The resolution of the passed in fb_info about to change and |
| 501 | all vc's should be changed */ | 509 | all vc's should be changed */ |
| 502 | #define FB_EVENT_MODE_CHANGE_ALL 0x0A | 510 | #define FB_EVENT_MODE_CHANGE_ALL 0x0A |
| 511 | /* CONSOLE-SPECIFIC: set console rotation */ | ||
| 512 | #define FB_EVENT_SET_CON_ROTATE 0x0B | ||
| 513 | /* CONSOLE-SPECIFIC: get console rotation */ | ||
| 514 | #define FB_EVENT_GET_CON_ROTATE 0x0C | ||
| 515 | /* CONSOLE-SPECIFIC: rotate all consoles */ | ||
| 516 | #define FB_EVENT_SET_CON_ROTATE_ALL 0x0D | ||
| 503 | 517 | ||
| 504 | struct fb_event { | 518 | struct fb_event { |
| 505 | struct fb_info *info; | 519 | struct fb_info *info; |
| @@ -817,8 +831,8 @@ extern void cfb_imageblit(struct fb_info *info, const struct fb_image *image); | |||
| 817 | /* drivers/video/fbmem.c */ | 831 | /* drivers/video/fbmem.c */ |
| 818 | extern int register_framebuffer(struct fb_info *fb_info); | 832 | extern int register_framebuffer(struct fb_info *fb_info); |
| 819 | extern int unregister_framebuffer(struct fb_info *fb_info); | 833 | extern int unregister_framebuffer(struct fb_info *fb_info); |
| 820 | extern int fb_prepare_logo(struct fb_info *fb_info); | 834 | extern int fb_prepare_logo(struct fb_info *fb_info, int rotate); |
| 821 | extern int fb_show_logo(struct fb_info *fb_info); | 835 | extern int fb_show_logo(struct fb_info *fb_info, int rotate); |
| 822 | extern char* fb_get_buffer_offset(struct fb_info *info, struct fb_pixmap *buf, u32 size); | 836 | extern char* fb_get_buffer_offset(struct fb_info *info, struct fb_pixmap *buf, u32 size); |
| 823 | extern void fb_pad_unaligned_buffer(u8 *dst, u32 d_pitch, u8 *src, u32 idx, | 837 | extern void fb_pad_unaligned_buffer(u8 *dst, u32 d_pitch, u8 *src, u32 idx, |
| 824 | u32 height, u32 shift_high, u32 shift_low, u32 mod); | 838 | u32 height, u32 shift_high, u32 shift_low, u32 mod); |
| @@ -828,6 +842,7 @@ extern int fb_get_color_depth(struct fb_var_screeninfo *var, | |||
| 828 | struct fb_fix_screeninfo *fix); | 842 | struct fb_fix_screeninfo *fix); |
| 829 | extern int fb_get_options(char *name, char **option); | 843 | extern int fb_get_options(char *name, char **option); |
| 830 | extern int fb_new_modelist(struct fb_info *info); | 844 | extern int fb_new_modelist(struct fb_info *info); |
| 845 | extern int fb_con_duit(struct fb_info *info, int event, void *data); | ||
| 831 | 846 | ||
| 832 | extern struct fb_info *registered_fb[FB_MAX]; | 847 | extern struct fb_info *registered_fb[FB_MAX]; |
| 833 | extern int num_registered_fb; | 848 | extern int num_registered_fb; |
diff --git a/include/linux/fs.h b/include/linux/fs.h index 1b5f502a4b8f..cc35b6ac778d 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
| @@ -874,6 +874,7 @@ static inline void unlock_super(struct super_block * sb) | |||
| 874 | /* | 874 | /* |
| 875 | * VFS helper functions.. | 875 | * VFS helper functions.. |
| 876 | */ | 876 | */ |
| 877 | extern int vfs_permission(struct nameidata *, int); | ||
| 877 | extern int vfs_create(struct inode *, struct dentry *, int, struct nameidata *); | 878 | extern int vfs_create(struct inode *, struct dentry *, int, struct nameidata *); |
| 878 | extern int vfs_mkdir(struct inode *, struct dentry *, int); | 879 | extern int vfs_mkdir(struct inode *, struct dentry *, int); |
| 879 | extern int vfs_mknod(struct inode *, struct dentry *, int, dev_t); | 880 | extern int vfs_mknod(struct inode *, struct dentry *, int, dev_t); |
| @@ -889,6 +890,11 @@ extern int vfs_rename(struct inode *, struct dentry *, struct inode *, struct de | |||
| 889 | extern void dentry_unhash(struct dentry *dentry); | 890 | extern void dentry_unhash(struct dentry *dentry); |
| 890 | 891 | ||
| 891 | /* | 892 | /* |
| 893 | * VFS file helper functions. | ||
| 894 | */ | ||
| 895 | extern int file_permission(struct file *, int); | ||
| 896 | |||
| 897 | /* | ||
| 892 | * File types | 898 | * File types |
| 893 | * | 899 | * |
| 894 | * NOTE! These match bits 12..15 of stat.st_mode | 900 | * NOTE! These match bits 12..15 of stat.st_mode |
diff --git a/include/linux/fs_enet_pd.h b/include/linux/fs_enet_pd.h index bef23bbf8690..783c476b8674 100644 --- a/include/linux/fs_enet_pd.h +++ b/include/linux/fs_enet_pd.h | |||
| @@ -16,7 +16,6 @@ | |||
| 16 | #ifndef FS_ENET_PD_H | 16 | #ifndef FS_ENET_PD_H |
| 17 | #define FS_ENET_PD_H | 17 | #define FS_ENET_PD_H |
| 18 | 18 | ||
| 19 | #include <linux/version.h> | ||
| 20 | #include <asm/types.h> | 19 | #include <asm/types.h> |
| 21 | 20 | ||
| 22 | #define FS_ENET_NAME "fs_enet" | 21 | #define FS_ENET_NAME "fs_enet" |
diff --git a/include/linux/i2c-id.h b/include/linux/i2c-id.h index 1ce4b54caa21..74abaecdb572 100644 --- a/include/linux/i2c-id.h +++ b/include/linux/i2c-id.h | |||
| @@ -27,10 +27,10 @@ | |||
| 27 | * ---- Driver types ----------------------------------------------------- | 27 | * ---- Driver types ----------------------------------------------------- |
| 28 | * device id name + number function description, i2c address(es) | 28 | * device id name + number function description, i2c address(es) |
| 29 | * | 29 | * |
| 30 | * Range 1000-1999 range is defined in sensors/sensors.h | 30 | * Range 1000-1999 range is defined in sensors/sensors.h |
| 31 | * Range 0x100 - 0x1ff is for V4L2 Common Components | 31 | * Range 0x100 - 0x1ff is for V4L2 Common Components |
| 32 | * Range 0xf000 - 0xffff is reserved for local experimentation, and should | 32 | * Range 0xf000 - 0xffff is reserved for local experimentation, and should |
| 33 | * never be used in official drivers | 33 | * never be used in official drivers |
| 34 | */ | 34 | */ |
| 35 | 35 | ||
| 36 | #define I2C_DRIVERID_MSP3400 1 | 36 | #define I2C_DRIVERID_MSP3400 1 |
| @@ -99,7 +99,14 @@ | |||
| 99 | #define I2C_DRIVERID_MAX6900 63 /* MAX6900 real-time clock */ | 99 | #define I2C_DRIVERID_MAX6900 63 /* MAX6900 real-time clock */ |
| 100 | #define I2C_DRIVERID_SAA7114H 64 /* video decoder */ | 100 | #define I2C_DRIVERID_SAA7114H 64 /* video decoder */ |
| 101 | #define I2C_DRIVERID_DS1374 65 /* DS1374 real time clock */ | 101 | #define I2C_DRIVERID_DS1374 65 /* DS1374 real time clock */ |
| 102 | 102 | #define I2C_DRIVERID_TDA9874 66 /* TV sound decoder */ | |
| 103 | #define I2C_DRIVERID_SAA6752HS 67 /* MPEG2 encoder */ | ||
| 104 | #define I2C_DRIVERID_TVEEPROM 68 /* TV EEPROM */ | ||
| 105 | #define I2C_DRIVERID_WM8775 69 /* wm8775 audio processor */ | ||
| 106 | #define I2C_DRIVERID_CS53L32A 70 /* cs53l32a audio processor */ | ||
| 107 | #define I2C_DRIVERID_CX25840 71 /* cx2584x video encoder */ | ||
| 108 | #define I2C_DRIVERID_SAA7127 72 /* saa7124 video encoder */ | ||
| 109 | #define I2C_DRIVERID_SAA711X 73 /* saa711x video encoders */ | ||
| 103 | 110 | ||
| 104 | #define I2C_DRIVERID_EXP0 0xF0 /* experimental use id's */ | 111 | #define I2C_DRIVERID_EXP0 0xF0 /* experimental use id's */ |
| 105 | #define I2C_DRIVERID_EXP1 0xF1 | 112 | #define I2C_DRIVERID_EXP1 0xF1 |
| @@ -111,7 +118,7 @@ | |||
| 111 | #define I2C_DRIVERID_ARP 902 /* SMBus ARP Client */ | 118 | #define I2C_DRIVERID_ARP 902 /* SMBus ARP Client */ |
| 112 | #define I2C_DRIVERID_ALERT 903 /* SMBus Alert Responder Client */ | 119 | #define I2C_DRIVERID_ALERT 903 /* SMBus Alert Responder Client */ |
| 113 | 120 | ||
| 114 | /* IDs -- Use DRIVERIDs 1000-1999 for sensors. | 121 | /* IDs -- Use DRIVERIDs 1000-1999 for sensors. |
| 115 | These were originally in sensors.h in the lm_sensors package */ | 122 | These were originally in sensors.h in the lm_sensors package */ |
| 116 | #define I2C_DRIVERID_LM78 1002 | 123 | #define I2C_DRIVERID_LM78 1002 |
| 117 | #define I2C_DRIVERID_LM75 1003 | 124 | #define I2C_DRIVERID_LM75 1003 |
| @@ -190,6 +197,7 @@ | |||
| 190 | #define I2C_HW_B_NVIDIA 0x01001c /* nvidia framebuffer driver */ | 197 | #define I2C_HW_B_NVIDIA 0x01001c /* nvidia framebuffer driver */ |
| 191 | #define I2C_HW_B_SAVAGE 0x01001d /* savage framebuffer driver */ | 198 | #define I2C_HW_B_SAVAGE 0x01001d /* savage framebuffer driver */ |
| 192 | #define I2C_HW_B_RADEON 0x01001e /* radeon framebuffer driver */ | 199 | #define I2C_HW_B_RADEON 0x01001e /* radeon framebuffer driver */ |
| 200 | #define I2C_HW_B_EM28XX 0x01001f /* em28xx video capture cards */ | ||
| 193 | 201 | ||
| 194 | /* --- PCF 8584 based algorithms */ | 202 | /* --- PCF 8584 based algorithms */ |
| 195 | #define I2C_HW_P_LP 0x020000 /* Parallel port interface */ | 203 | #define I2C_HW_P_LP 0x020000 /* Parallel port interface */ |
diff --git a/include/linux/if_wanpipe_common.h b/include/linux/if_wanpipe_common.h index f25fec8ee2ca..6e5461d69fdd 100644 --- a/include/linux/if_wanpipe_common.h +++ b/include/linux/if_wanpipe_common.h | |||
| @@ -17,8 +17,6 @@ | |||
| 17 | #ifndef _WANPIPE_SOCK_DRIVER_COMMON_H | 17 | #ifndef _WANPIPE_SOCK_DRIVER_COMMON_H |
| 18 | #define _WANPIPE_SOCK_DRIVER_COMMON_H | 18 | #define _WANPIPE_SOCK_DRIVER_COMMON_H |
| 19 | 19 | ||
| 20 | #include <linux/version.h> | ||
| 21 | |||
| 22 | typedef struct { | 20 | typedef struct { |
| 23 | struct net_device *slave; | 21 | struct net_device *slave; |
| 24 | atomic_t packet_sent; | 22 | atomic_t packet_sent; |
diff --git a/include/linux/istallion.h b/include/linux/istallion.h index 5f4ee646c119..1f996621bc9c 100644 --- a/include/linux/istallion.h +++ b/include/linux/istallion.h | |||
| @@ -21,8 +21,6 @@ | |||
| 21 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | 21 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. |
| 22 | */ | 22 | */ |
| 23 | 23 | ||
| 24 | #include <linux/version.h> | ||
| 25 | |||
| 26 | /*****************************************************************************/ | 24 | /*****************************************************************************/ |
| 27 | #ifndef _ISTALLION_H | 25 | #ifndef _ISTALLION_H |
| 28 | #define _ISTALLION_H | 26 | #define _ISTALLION_H |
diff --git a/include/linux/libata.h b/include/linux/libata.h index dcd17e7458ab..6f0752219f64 100644 --- a/include/linux/libata.h +++ b/include/linux/libata.h | |||
| @@ -214,7 +214,7 @@ struct ata_probe_ent { | |||
| 214 | struct list_head node; | 214 | struct list_head node; |
| 215 | struct device *dev; | 215 | struct device *dev; |
| 216 | const struct ata_port_operations *port_ops; | 216 | const struct ata_port_operations *port_ops; |
| 217 | Scsi_Host_Template *sht; | 217 | struct scsi_host_template *sht; |
| 218 | struct ata_ioports port[ATA_MAX_PORTS]; | 218 | struct ata_ioports port[ATA_MAX_PORTS]; |
| 219 | unsigned int n_ports; | 219 | unsigned int n_ports; |
| 220 | unsigned int hard_port_no; | 220 | unsigned int hard_port_no; |
| @@ -398,7 +398,7 @@ struct ata_port_operations { | |||
| 398 | }; | 398 | }; |
| 399 | 399 | ||
| 400 | struct ata_port_info { | 400 | struct ata_port_info { |
| 401 | Scsi_Host_Template *sht; | 401 | struct scsi_host_template *sht; |
| 402 | unsigned long host_flags; | 402 | unsigned long host_flags; |
| 403 | unsigned long pio_mask; | 403 | unsigned long pio_mask; |
| 404 | unsigned long mwdma_mask; | 404 | unsigned long mwdma_mask; |
| @@ -433,7 +433,7 @@ extern void ata_pci_remove_one (struct pci_dev *pdev); | |||
| 433 | #endif /* CONFIG_PCI */ | 433 | #endif /* CONFIG_PCI */ |
| 434 | extern int ata_device_add(const struct ata_probe_ent *ent); | 434 | extern int ata_device_add(const struct ata_probe_ent *ent); |
| 435 | extern void ata_host_set_remove(struct ata_host_set *host_set); | 435 | extern void ata_host_set_remove(struct ata_host_set *host_set); |
| 436 | extern int ata_scsi_detect(Scsi_Host_Template *sht); | 436 | extern int ata_scsi_detect(struct scsi_host_template *sht); |
| 437 | extern int ata_scsi_ioctl(struct scsi_device *dev, int cmd, void __user *arg); | 437 | extern int ata_scsi_ioctl(struct scsi_device *dev, int cmd, void __user *arg); |
| 438 | extern int ata_scsi_queuecmd(struct scsi_cmnd *cmd, void (*done)(struct scsi_cmnd *)); | 438 | extern int ata_scsi_queuecmd(struct scsi_cmnd *cmd, void (*done)(struct scsi_cmnd *)); |
| 439 | extern int ata_scsi_error(struct Scsi_Host *host); | 439 | extern int ata_scsi_error(struct Scsi_Host *host); |
diff --git a/include/linux/mtd/cfi.h b/include/linux/mtd/cfi.h index 39f1430bd6d5..3c9ea4b7adda 100644 --- a/include/linux/mtd/cfi.h +++ b/include/linux/mtd/cfi.h | |||
| @@ -8,7 +8,6 @@ | |||
| 8 | #define __MTD_CFI_H__ | 8 | #define __MTD_CFI_H__ |
| 9 | 9 | ||
| 10 | #include <linux/config.h> | 10 | #include <linux/config.h> |
| 11 | #include <linux/version.h> | ||
| 12 | #include <linux/delay.h> | 11 | #include <linux/delay.h> |
| 13 | #include <linux/types.h> | 12 | #include <linux/types.h> |
| 14 | #include <linux/interrupt.h> | 13 | #include <linux/interrupt.h> |
diff --git a/include/linux/mtd/mtd.h b/include/linux/mtd/mtd.h index e95d0463a3e5..b6f2fdae65c6 100644 --- a/include/linux/mtd/mtd.h +++ b/include/linux/mtd/mtd.h | |||
| @@ -14,7 +14,6 @@ | |||
| 14 | #endif | 14 | #endif |
| 15 | 15 | ||
| 16 | #include <linux/config.h> | 16 | #include <linux/config.h> |
| 17 | #include <linux/version.h> | ||
| 18 | #include <linux/types.h> | 17 | #include <linux/types.h> |
| 19 | #include <linux/module.h> | 18 | #include <linux/module.h> |
| 20 | #include <linux/uio.h> | 19 | #include <linux/uio.h> |
diff --git a/include/linux/namei.h b/include/linux/namei.h index 1c975d0d9e94..455660eafba9 100644 --- a/include/linux/namei.h +++ b/include/linux/namei.h | |||
| @@ -74,7 +74,7 @@ extern struct file *nameidata_to_filp(struct nameidata *nd, int flags); | |||
| 74 | extern void release_open_intent(struct nameidata *); | 74 | extern void release_open_intent(struct nameidata *); |
| 75 | 75 | ||
| 76 | extern struct dentry * lookup_one_len(const char *, struct dentry *, int); | 76 | extern struct dentry * lookup_one_len(const char *, struct dentry *, int); |
| 77 | extern struct dentry * lookup_hash(struct qstr *, struct dentry *); | 77 | extern struct dentry * lookup_hash(struct nameidata *); |
| 78 | 78 | ||
| 79 | extern int follow_down(struct vfsmount **, struct dentry **); | 79 | extern int follow_down(struct vfsmount **, struct dentry **); |
| 80 | extern int follow_up(struct vfsmount **, struct dentry **); | 80 | extern int follow_up(struct vfsmount **, struct dentry **); |
diff --git a/include/linux/phonedev.h b/include/linux/phonedev.h index d54049eed0c3..a0e31adf3abe 100644 --- a/include/linux/phonedev.h +++ b/include/linux/phonedev.h | |||
| @@ -2,7 +2,6 @@ | |||
| 2 | #define __LINUX_PHONEDEV_H | 2 | #define __LINUX_PHONEDEV_H |
| 3 | 3 | ||
| 4 | #include <linux/types.h> | 4 | #include <linux/types.h> |
| 5 | #include <linux/version.h> | ||
| 6 | 5 | ||
| 7 | #ifdef __KERNEL__ | 6 | #ifdef __KERNEL__ |
| 8 | 7 | ||
diff --git a/include/linux/proc_fs.h b/include/linux/proc_fs.h index 65ceeaa30652..74488e49166d 100644 --- a/include/linux/proc_fs.h +++ b/include/linux/proc_fs.h | |||
| @@ -66,6 +66,7 @@ struct proc_dir_entry { | |||
| 66 | write_proc_t *write_proc; | 66 | write_proc_t *write_proc; |
| 67 | atomic_t count; /* use count */ | 67 | atomic_t count; /* use count */ |
| 68 | int deleted; /* delete flag */ | 68 | int deleted; /* delete flag */ |
| 69 | void *set; | ||
| 69 | }; | 70 | }; |
| 70 | 71 | ||
| 71 | struct kcore_list { | 72 | struct kcore_list { |
diff --git a/include/linux/raid/bitmap.h b/include/linux/raid/bitmap.h index 9de99198caf1..899437802aea 100644 --- a/include/linux/raid/bitmap.h +++ b/include/linux/raid/bitmap.h | |||
| @@ -6,7 +6,13 @@ | |||
| 6 | #ifndef BITMAP_H | 6 | #ifndef BITMAP_H |
| 7 | #define BITMAP_H 1 | 7 | #define BITMAP_H 1 |
| 8 | 8 | ||
| 9 | #define BITMAP_MAJOR 3 | 9 | #define BITMAP_MAJOR_LO 3 |
| 10 | /* version 4 insists the bitmap is in little-endian order | ||
| 11 | * with version 3, it is host-endian which is non-portable | ||
| 12 | */ | ||
| 13 | #define BITMAP_MAJOR_HI 4 | ||
| 14 | #define BITMAP_MAJOR_HOSTENDIAN 3 | ||
| 15 | |||
| 10 | #define BITMAP_MINOR 39 | 16 | #define BITMAP_MINOR 39 |
| 11 | 17 | ||
| 12 | /* | 18 | /* |
| @@ -133,7 +139,8 @@ typedef __u16 bitmap_counter_t; | |||
| 133 | /* use these for bitmap->flags and bitmap->sb->state bit-fields */ | 139 | /* use these for bitmap->flags and bitmap->sb->state bit-fields */ |
| 134 | enum bitmap_state { | 140 | enum bitmap_state { |
| 135 | BITMAP_ACTIVE = 0x001, /* the bitmap is in use */ | 141 | BITMAP_ACTIVE = 0x001, /* the bitmap is in use */ |
| 136 | BITMAP_STALE = 0x002 /* the bitmap file is out of date or had -EIO */ | 142 | BITMAP_STALE = 0x002, /* the bitmap file is out of date or had -EIO */ |
| 143 | BITMAP_HOSTENDIAN = 0x8000, | ||
| 137 | }; | 144 | }; |
| 138 | 145 | ||
| 139 | /* the superblock at the front of the bitmap file -- little endian */ | 146 | /* the superblock at the front of the bitmap file -- little endian */ |
diff --git a/include/linux/raid/md.h b/include/linux/raid/md.h index ffa316ce4dc8..13e7c4b62367 100644 --- a/include/linux/raid/md.h +++ b/include/linux/raid/md.h | |||
| @@ -66,8 +66,10 @@ | |||
| 66 | * and major_version/minor_version accordingly | 66 | * and major_version/minor_version accordingly |
| 67 | * >=2 means that Internal bitmaps are supported by setting MD_SB_BITMAP_PRESENT | 67 | * >=2 means that Internal bitmaps are supported by setting MD_SB_BITMAP_PRESENT |
| 68 | * in the super status byte | 68 | * in the super status byte |
| 69 | * >=3 means that bitmap superblock version 4 is supported, which uses | ||
| 70 | * little-ending representation rather than host-endian | ||
| 69 | */ | 71 | */ |
| 70 | #define MD_PATCHLEVEL_VERSION 2 | 72 | #define MD_PATCHLEVEL_VERSION 3 |
| 71 | 73 | ||
| 72 | extern int register_md_personality (int p_num, mdk_personality_t *p); | 74 | extern int register_md_personality (int p_num, mdk_personality_t *p); |
| 73 | extern int unregister_md_personality (int p_num); | 75 | extern int unregister_md_personality (int p_num); |
| @@ -87,6 +89,7 @@ extern void md_print_devices (void); | |||
| 87 | 89 | ||
| 88 | extern void md_super_write(mddev_t *mddev, mdk_rdev_t *rdev, | 90 | extern void md_super_write(mddev_t *mddev, mdk_rdev_t *rdev, |
| 89 | sector_t sector, int size, struct page *page); | 91 | sector_t sector, int size, struct page *page); |
| 92 | extern void md_super_wait(mddev_t *mddev); | ||
| 90 | extern int sync_page_io(struct block_device *bdev, sector_t sector, int size, | 93 | extern int sync_page_io(struct block_device *bdev, sector_t sector, int size, |
| 91 | struct page *page, int rw); | 94 | struct page *page, int rw); |
| 92 | 95 | ||
diff --git a/include/linux/raid/md_k.h b/include/linux/raid/md_k.h index ebce949b1443..46629a275ba9 100644 --- a/include/linux/raid/md_k.h +++ b/include/linux/raid/md_k.h | |||
| @@ -105,6 +105,8 @@ struct mdk_rdev_s | |||
| 105 | int sb_size; /* bytes in the superblock */ | 105 | int sb_size; /* bytes in the superblock */ |
| 106 | int preferred_minor; /* autorun support */ | 106 | int preferred_minor; /* autorun support */ |
| 107 | 107 | ||
| 108 | struct kobject kobj; | ||
| 109 | |||
| 108 | /* A device can be in one of three states based on two flags: | 110 | /* A device can be in one of three states based on two flags: |
| 109 | * Not working: faulty==1 in_sync==0 | 111 | * Not working: faulty==1 in_sync==0 |
| 110 | * Fully working: faulty==0 in_sync==1 | 112 | * Fully working: faulty==0 in_sync==1 |
| @@ -115,11 +117,12 @@ struct mdk_rdev_s | |||
| 115 | * It can never have faulty==1, in_sync==1 | 117 | * It can never have faulty==1, in_sync==1 |
| 116 | * This reduces the burden of testing multiple flags in many cases | 118 | * This reduces the burden of testing multiple flags in many cases |
| 117 | */ | 119 | */ |
| 118 | int faulty; /* if faulty do not issue IO requests */ | ||
| 119 | int in_sync; /* device is a full member of the array */ | ||
| 120 | 120 | ||
| 121 | unsigned long flags; /* Should include faulty and in_sync here. */ | 121 | unsigned long flags; |
| 122 | #define Faulty 1 /* device is known to have a fault */ | ||
| 123 | #define In_sync 2 /* device is in_sync with rest of array */ | ||
| 122 | #define WriteMostly 4 /* Avoid reading if at all possible */ | 124 | #define WriteMostly 4 /* Avoid reading if at all possible */ |
| 125 | #define BarriersNotsupp 5 /* BIO_RW_BARRIER is not supported */ | ||
| 123 | 126 | ||
| 124 | int desc_nr; /* descriptor index in the superblock */ | 127 | int desc_nr; /* descriptor index in the superblock */ |
| 125 | int raid_disk; /* role of device in array */ | 128 | int raid_disk; /* role of device in array */ |
| @@ -132,6 +135,9 @@ struct mdk_rdev_s | |||
| 132 | * only maintained for arrays that | 135 | * only maintained for arrays that |
| 133 | * support hot removal | 136 | * support hot removal |
| 134 | */ | 137 | */ |
| 138 | atomic_t read_errors; /* number of consecutive read errors that | ||
| 139 | * we have tried to ignore. | ||
| 140 | */ | ||
| 135 | }; | 141 | }; |
| 136 | 142 | ||
| 137 | typedef struct mdk_personality_s mdk_personality_t; | 143 | typedef struct mdk_personality_s mdk_personality_t; |
| @@ -148,6 +154,8 @@ struct mddev_s | |||
| 148 | 154 | ||
| 149 | struct gendisk *gendisk; | 155 | struct gendisk *gendisk; |
| 150 | 156 | ||
| 157 | struct kobject kobj; | ||
| 158 | |||
| 151 | /* Superblock information */ | 159 | /* Superblock information */ |
| 152 | int major_version, | 160 | int major_version, |
| 153 | minor_version, | 161 | minor_version, |
| @@ -171,6 +179,10 @@ struct mddev_s | |||
| 171 | sector_t resync_mark_cnt;/* blocks written at resync_mark */ | 179 | sector_t resync_mark_cnt;/* blocks written at resync_mark */ |
| 172 | 180 | ||
| 173 | sector_t resync_max_sectors; /* may be set by personality */ | 181 | sector_t resync_max_sectors; /* may be set by personality */ |
| 182 | |||
| 183 | sector_t resync_mismatches; /* count of sectors where | ||
| 184 | * parity/replica mismatch found | ||
| 185 | */ | ||
| 174 | /* recovery/resync flags | 186 | /* recovery/resync flags |
| 175 | * NEEDED: we might need to start a resync/recover | 187 | * NEEDED: we might need to start a resync/recover |
| 176 | * RUNNING: a thread is running, or about to be started | 188 | * RUNNING: a thread is running, or about to be started |
| @@ -178,6 +190,8 @@ struct mddev_s | |||
| 178 | * ERR: and IO error was detected - abort the resync/recovery | 190 | * ERR: and IO error was detected - abort the resync/recovery |
| 179 | * INTR: someone requested a (clean) early abort. | 191 | * INTR: someone requested a (clean) early abort. |
| 180 | * DONE: thread is done and is waiting to be reaped | 192 | * DONE: thread is done and is waiting to be reaped |
| 193 | * REQUEST: user-space has requested a sync (used with SYNC) | ||
| 194 | * CHECK: user-space request for for check-only, no repair | ||
| 181 | */ | 195 | */ |
| 182 | #define MD_RECOVERY_RUNNING 0 | 196 | #define MD_RECOVERY_RUNNING 0 |
| 183 | #define MD_RECOVERY_SYNC 1 | 197 | #define MD_RECOVERY_SYNC 1 |
| @@ -185,6 +199,8 @@ struct mddev_s | |||
| 185 | #define MD_RECOVERY_INTR 3 | 199 | #define MD_RECOVERY_INTR 3 |
| 186 | #define MD_RECOVERY_DONE 4 | 200 | #define MD_RECOVERY_DONE 4 |
| 187 | #define MD_RECOVERY_NEEDED 5 | 201 | #define MD_RECOVERY_NEEDED 5 |
| 202 | #define MD_RECOVERY_REQUESTED 6 | ||
| 203 | #define MD_RECOVERY_CHECK 7 | ||
| 188 | unsigned long recovery; | 204 | unsigned long recovery; |
| 189 | 205 | ||
| 190 | int in_sync; /* know to not need resync */ | 206 | int in_sync; /* know to not need resync */ |
| @@ -195,6 +211,13 @@ struct mddev_s | |||
| 195 | int degraded; /* whether md should consider | 211 | int degraded; /* whether md should consider |
| 196 | * adding a spare | 212 | * adding a spare |
| 197 | */ | 213 | */ |
| 214 | int barriers_work; /* initialised to true, cleared as soon | ||
| 215 | * as a barrier request to slave | ||
| 216 | * fails. Only supported | ||
| 217 | */ | ||
| 218 | struct bio *biolist; /* bios that need to be retried | ||
| 219 | * because BIO_RW_BARRIER is not supported | ||
| 220 | */ | ||
| 198 | 221 | ||
| 199 | atomic_t recovery_active; /* blocks scheduled, but not written */ | 222 | atomic_t recovery_active; /* blocks scheduled, but not written */ |
| 200 | wait_queue_head_t recovery_wait; | 223 | wait_queue_head_t recovery_wait; |
| @@ -232,7 +255,7 @@ struct mddev_s | |||
| 232 | 255 | ||
| 233 | static inline void rdev_dec_pending(mdk_rdev_t *rdev, mddev_t *mddev) | 256 | static inline void rdev_dec_pending(mdk_rdev_t *rdev, mddev_t *mddev) |
| 234 | { | 257 | { |
| 235 | int faulty = rdev->faulty; | 258 | int faulty = test_bit(Faulty, &rdev->flags); |
| 236 | if (atomic_dec_and_test(&rdev->nr_pending) && faulty) | 259 | if (atomic_dec_and_test(&rdev->nr_pending) && faulty) |
| 237 | set_bit(MD_RECOVERY_NEEDED, &mddev->recovery); | 260 | set_bit(MD_RECOVERY_NEEDED, &mddev->recovery); |
| 238 | } | 261 | } |
| @@ -270,6 +293,13 @@ struct mdk_personality_s | |||
| 270 | }; | 293 | }; |
| 271 | 294 | ||
| 272 | 295 | ||
| 296 | struct md_sysfs_entry { | ||
| 297 | struct attribute attr; | ||
| 298 | ssize_t (*show)(mddev_t *, char *); | ||
| 299 | ssize_t (*store)(mddev_t *, const char *, size_t); | ||
| 300 | }; | ||
| 301 | |||
| 302 | |||
| 273 | static inline char * mdname (mddev_t * mddev) | 303 | static inline char * mdname (mddev_t * mddev) |
| 274 | { | 304 | { |
| 275 | return mddev->gendisk ? mddev->gendisk->disk_name : "mdX"; | 305 | return mddev->gendisk ? mddev->gendisk->disk_name : "mdX"; |
| @@ -304,10 +334,8 @@ typedef struct mdk_thread_s { | |||
| 304 | mddev_t *mddev; | 334 | mddev_t *mddev; |
| 305 | wait_queue_head_t wqueue; | 335 | wait_queue_head_t wqueue; |
| 306 | unsigned long flags; | 336 | unsigned long flags; |
| 307 | struct completion *event; | ||
| 308 | struct task_struct *tsk; | 337 | struct task_struct *tsk; |
| 309 | unsigned long timeout; | 338 | unsigned long timeout; |
| 310 | const char *name; | ||
| 311 | } mdk_thread_t; | 339 | } mdk_thread_t; |
| 312 | 340 | ||
| 313 | #define THREAD_WAKEUP 0 | 341 | #define THREAD_WAKEUP 0 |
diff --git a/include/linux/raid/raid1.h b/include/linux/raid/raid1.h index 60e19b667548..292b98f2b408 100644 --- a/include/linux/raid/raid1.h +++ b/include/linux/raid/raid1.h | |||
| @@ -110,7 +110,9 @@ struct r1bio_s { | |||
| 110 | #define R1BIO_Uptodate 0 | 110 | #define R1BIO_Uptodate 0 |
| 111 | #define R1BIO_IsSync 1 | 111 | #define R1BIO_IsSync 1 |
| 112 | #define R1BIO_Degraded 2 | 112 | #define R1BIO_Degraded 2 |
| 113 | #define R1BIO_BehindIO 3 | 113 | #define R1BIO_BehindIO 3 |
| 114 | #define R1BIO_Barrier 4 | ||
| 115 | #define R1BIO_BarrierRetry 5 | ||
| 114 | /* For write-behind requests, we call bi_end_io when | 116 | /* For write-behind requests, we call bi_end_io when |
| 115 | * the last non-write-behind device completes, providing | 117 | * the last non-write-behind device completes, providing |
| 116 | * any write was successful. Otherwise we call when | 118 | * any write was successful. Otherwise we call when |
diff --git a/include/linux/raid/raid5.h b/include/linux/raid/raid5.h index 176fc653c284..f025ba6fb14c 100644 --- a/include/linux/raid/raid5.h +++ b/include/linux/raid/raid5.h | |||
| @@ -154,6 +154,8 @@ struct stripe_head { | |||
| 154 | #define R5_Wantwrite 5 | 154 | #define R5_Wantwrite 5 |
| 155 | #define R5_Syncio 6 /* this io need to be accounted as resync io */ | 155 | #define R5_Syncio 6 /* this io need to be accounted as resync io */ |
| 156 | #define R5_Overlap 7 /* There is a pending overlapping request on this block */ | 156 | #define R5_Overlap 7 /* There is a pending overlapping request on this block */ |
| 157 | #define R5_ReadError 8 /* seen a read error here recently */ | ||
| 158 | #define R5_ReWrite 9 /* have tried to over-write the readerror */ | ||
| 157 | 159 | ||
| 158 | /* | 160 | /* |
| 159 | * Write method | 161 | * Write method |
diff --git a/include/linux/sched.h b/include/linux/sched.h index 03b68a7b4b82..2bbf968b23d9 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h | |||
| @@ -909,6 +909,7 @@ do { if (atomic_dec_and_test(&(tsk)->usage)) __put_task_struct(tsk); } while(0) | |||
| 909 | #define PF_SYNCWRITE 0x00200000 /* I am doing a sync write */ | 909 | #define PF_SYNCWRITE 0x00200000 /* I am doing a sync write */ |
| 910 | #define PF_BORROWED_MM 0x00400000 /* I am a kthread doing use_mm */ | 910 | #define PF_BORROWED_MM 0x00400000 /* I am a kthread doing use_mm */ |
| 911 | #define PF_RANDOMIZE 0x00800000 /* randomize virtual address space */ | 911 | #define PF_RANDOMIZE 0x00800000 /* randomize virtual address space */ |
| 912 | #define PF_HOTPLUG_CPU 0x01000000 /* Currently performing CPU hotplug */ | ||
| 912 | 913 | ||
| 913 | /* | 914 | /* |
| 914 | * Only the _current_ task can read/write to tsk->flags, but other | 915 | * Only the _current_ task can read/write to tsk->flags, but other |
diff --git a/include/linux/stallion.h b/include/linux/stallion.h index e89b77b6505a..13a37f137ea2 100644 --- a/include/linux/stallion.h +++ b/include/linux/stallion.h | |||
| @@ -21,8 +21,6 @@ | |||
| 21 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | 21 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. |
| 22 | */ | 22 | */ |
| 23 | 23 | ||
| 24 | #include <linux/version.h> | ||
| 25 | |||
| 26 | /*****************************************************************************/ | 24 | /*****************************************************************************/ |
| 27 | #ifndef _STALLION_H | 25 | #ifndef _STALLION_H |
| 28 | #define _STALLION_H | 26 | #define _STALLION_H |
diff --git a/include/linux/sysctl.h b/include/linux/sysctl.h index fc8e367f671e..fc131d6602b9 100644 --- a/include/linux/sysctl.h +++ b/include/linux/sysctl.h | |||
| @@ -24,6 +24,7 @@ | |||
| 24 | #include <linux/compiler.h> | 24 | #include <linux/compiler.h> |
| 25 | 25 | ||
| 26 | struct file; | 26 | struct file; |
| 27 | struct completion; | ||
| 27 | 28 | ||
| 28 | #define CTL_MAXNAME 10 /* how many path components do we allow in a | 29 | #define CTL_MAXNAME 10 /* how many path components do we allow in a |
| 29 | call to sysctl? In other words, what is | 30 | call to sysctl? In other words, what is |
| @@ -925,6 +926,8 @@ struct ctl_table_header | |||
| 925 | { | 926 | { |
| 926 | ctl_table *ctl_table; | 927 | ctl_table *ctl_table; |
| 927 | struct list_head ctl_entry; | 928 | struct list_head ctl_entry; |
| 929 | int used; | ||
| 930 | struct completion *unregistering; | ||
| 928 | }; | 931 | }; |
| 929 | 932 | ||
| 930 | struct ctl_table_header * register_sysctl_table(ctl_table * table, | 933 | struct ctl_table_header * register_sysctl_table(ctl_table * table, |
diff --git a/include/linux/videodev.h b/include/linux/videodev.h index 1cc8c31b7988..91140091ced2 100644 --- a/include/linux/videodev.h +++ b/include/linux/videodev.h | |||
| @@ -1,57 +1,16 @@ | |||
| 1 | #ifndef __LINUX_VIDEODEV_H | 1 | #ifndef __LINUX_VIDEODEV_H |
| 2 | #define __LINUX_VIDEODEV_H | 2 | #define __LINUX_VIDEODEV_H |
| 3 | 3 | ||
| 4 | #include <linux/compiler.h> | ||
| 5 | #include <linux/types.h> | 4 | #include <linux/types.h> |
| 6 | 5 | ||
| 7 | #define HAVE_V4L2 1 | 6 | #define HAVE_V4L1 1 |
| 7 | |||
| 8 | #include <linux/videodev2.h> | 8 | #include <linux/videodev2.h> |
| 9 | 9 | ||
| 10 | #ifdef __KERNEL__ | 10 | #ifdef __KERNEL__ |
| 11 | 11 | ||
| 12 | #include <linux/poll.h> | ||
| 13 | #include <linux/mm.h> | 12 | #include <linux/mm.h> |
| 14 | #include <linux/device.h> | ||
| 15 | |||
| 16 | struct video_device | ||
| 17 | { | ||
| 18 | /* device info */ | ||
| 19 | struct device *dev; | ||
| 20 | char name[32]; | ||
| 21 | int type; /* v4l1 */ | ||
| 22 | int type2; /* v4l2 */ | ||
| 23 | int hardware; | ||
| 24 | int minor; | ||
| 25 | |||
| 26 | /* device ops + callbacks */ | ||
| 27 | struct file_operations *fops; | ||
| 28 | void (*release)(struct video_device *vfd); | ||
| 29 | |||
| 30 | |||
| 31 | /* obsolete -- fops->owner is used instead */ | ||
| 32 | struct module *owner; | ||
| 33 | /* dev->driver_data will be used instead some day. | ||
| 34 | * Use the video_{get|set}_drvdata() helper functions, | ||
| 35 | * so the switch over will be transparent for you. | ||
| 36 | * Or use {pci|usb}_{get|set}_drvdata() directly. */ | ||
| 37 | void *priv; | ||
| 38 | |||
| 39 | /* for videodev.c intenal usage -- please don't touch */ | ||
| 40 | int users; /* video_exclusive_{open|close} ... */ | ||
| 41 | struct semaphore lock; /* ... helper function uses these */ | ||
| 42 | char devfs_name[64]; /* devfs */ | ||
| 43 | struct class_device class_dev; /* sysfs */ | ||
| 44 | }; | ||
| 45 | |||
| 46 | #define VIDEO_MAJOR 81 | ||
| 47 | |||
| 48 | #define VFL_TYPE_GRABBER 0 | ||
| 49 | #define VFL_TYPE_VBI 1 | ||
| 50 | #define VFL_TYPE_RADIO 2 | ||
| 51 | #define VFL_TYPE_VTX 3 | ||
| 52 | 13 | ||
| 53 | extern int video_register_device(struct video_device *, int type, int nr); | ||
| 54 | extern void video_unregister_device(struct video_device *); | ||
| 55 | extern struct video_device* video_devdata(struct file*); | 14 | extern struct video_device* video_devdata(struct file*); |
| 56 | 15 | ||
| 57 | #define to_video_device(cd) container_of(cd, struct video_device, class_dev) | 16 | #define to_video_device(cd) container_of(cd, struct video_device, class_dev) |
| @@ -68,11 +27,7 @@ video_device_remove_file(struct video_device *vfd, | |||
| 68 | class_device_remove_file(&vfd->class_dev, attr); | 27 | class_device_remove_file(&vfd->class_dev, attr); |
| 69 | } | 28 | } |
| 70 | 29 | ||
| 71 | /* helper functions to alloc / release struct video_device, the | 30 | #if OBSOLETE_OWNER /* to be removed in 2.6.15 */ |
| 72 | later can be used for video_device->release() */ | ||
| 73 | struct video_device *video_device_alloc(void); | ||
| 74 | void video_device_release(struct video_device *vfd); | ||
| 75 | |||
| 76 | /* helper functions to access driver private data. */ | 31 | /* helper functions to access driver private data. */ |
| 77 | static inline void *video_get_drvdata(struct video_device *dev) | 32 | static inline void *video_get_drvdata(struct video_device *dev) |
| 78 | { | 33 | { |
| @@ -83,30 +38,12 @@ static inline void video_set_drvdata(struct video_device *dev, void *data) | |||
| 83 | { | 38 | { |
| 84 | dev->priv = data; | 39 | dev->priv = data; |
| 85 | } | 40 | } |
| 41 | #endif | ||
| 86 | 42 | ||
| 87 | extern int video_exclusive_open(struct inode *inode, struct file *file); | 43 | extern int video_exclusive_open(struct inode *inode, struct file *file); |
| 88 | extern int video_exclusive_release(struct inode *inode, struct file *file); | 44 | extern int video_exclusive_release(struct inode *inode, struct file *file); |
| 89 | extern int video_usercopy(struct inode *inode, struct file *file, | ||
| 90 | unsigned int cmd, unsigned long arg, | ||
| 91 | int (*func)(struct inode *inode, struct file *file, | ||
| 92 | unsigned int cmd, void *arg)); | ||
| 93 | #endif /* __KERNEL__ */ | 45 | #endif /* __KERNEL__ */ |
| 94 | 46 | ||
| 95 | #define VID_TYPE_CAPTURE 1 /* Can capture */ | ||
| 96 | #define VID_TYPE_TUNER 2 /* Can tune */ | ||
| 97 | #define VID_TYPE_TELETEXT 4 /* Does teletext */ | ||
| 98 | #define VID_TYPE_OVERLAY 8 /* Overlay onto frame buffer */ | ||
| 99 | #define VID_TYPE_CHROMAKEY 16 /* Overlay by chromakey */ | ||
| 100 | #define VID_TYPE_CLIPPING 32 /* Can clip */ | ||
| 101 | #define VID_TYPE_FRAMERAM 64 /* Uses the frame buffer memory */ | ||
| 102 | #define VID_TYPE_SCALES 128 /* Scalable */ | ||
| 103 | #define VID_TYPE_MONOCHROME 256 /* Monochrome only */ | ||
| 104 | #define VID_TYPE_SUBCAPTURE 512 /* Can capture subareas of the image */ | ||
| 105 | #define VID_TYPE_MPEG_DECODER 1024 /* Can decode MPEG streams */ | ||
| 106 | #define VID_TYPE_MPEG_ENCODER 2048 /* Can encode MPEG streams */ | ||
| 107 | #define VID_TYPE_MJPEG_DECODER 4096 /* Can decode MJPEG streams */ | ||
| 108 | #define VID_TYPE_MJPEG_ENCODER 8192 /* Can encode MJPEG streams */ | ||
| 109 | |||
| 110 | struct video_capability | 47 | struct video_capability |
| 111 | { | 48 | { |
| 112 | char name[32]; | 49 | char name[32]; |
| @@ -202,9 +139,9 @@ struct video_audio | |||
| 202 | #define VIDEO_SOUND_STEREO 2 | 139 | #define VIDEO_SOUND_STEREO 2 |
| 203 | #define VIDEO_SOUND_LANG1 4 | 140 | #define VIDEO_SOUND_LANG1 4 |
| 204 | #define VIDEO_SOUND_LANG2 8 | 141 | #define VIDEO_SOUND_LANG2 8 |
| 205 | __u16 mode; | 142 | __u16 mode; |
| 206 | __u16 balance; /* Stereo balance */ | 143 | __u16 balance; /* Stereo balance */ |
| 207 | __u16 step; /* Step actual volume uses */ | 144 | __u16 step; /* Step actual volume uses */ |
| 208 | }; | 145 | }; |
| 209 | 146 | ||
| 210 | struct video_clip | 147 | struct video_clip |
| @@ -260,9 +197,6 @@ struct video_key | |||
| 260 | __u32 flags; | 197 | __u32 flags; |
| 261 | }; | 198 | }; |
| 262 | 199 | ||
| 263 | |||
| 264 | #define VIDEO_MAX_FRAME 32 | ||
| 265 | |||
| 266 | struct video_mbuf | 200 | struct video_mbuf |
| 267 | { | 201 | { |
| 268 | int size; /* Total memory to map */ | 202 | int size; /* Total memory to map */ |
| @@ -270,10 +204,8 @@ struct video_mbuf | |||
| 270 | int offsets[VIDEO_MAX_FRAME]; | 204 | int offsets[VIDEO_MAX_FRAME]; |
| 271 | }; | 205 | }; |
| 272 | 206 | ||
| 273 | |||
| 274 | #define VIDEO_NO_UNIT (-1) | 207 | #define VIDEO_NO_UNIT (-1) |
| 275 | 208 | ||
| 276 | |||
| 277 | struct video_unit | 209 | struct video_unit |
| 278 | { | 210 | { |
| 279 | int video; /* Video minor */ | 211 | int video; /* Video minor */ |
diff --git a/include/linux/videodev2.h b/include/linux/videodev2.h index 89a055761bed..a114fff6568b 100644 --- a/include/linux/videodev2.h +++ b/include/linux/videodev2.h | |||
| @@ -15,16 +15,99 @@ | |||
| 15 | */ | 15 | */ |
| 16 | #ifdef __KERNEL__ | 16 | #ifdef __KERNEL__ |
| 17 | #include <linux/time.h> /* need struct timeval */ | 17 | #include <linux/time.h> /* need struct timeval */ |
| 18 | #include <linux/poll.h> | ||
| 19 | #include <linux/device.h> | ||
| 18 | #endif | 20 | #endif |
| 19 | #include <linux/compiler.h> /* need __user */ | 21 | #include <linux/compiler.h> /* need __user */ |
| 20 | 22 | ||
| 23 | |||
| 24 | #define OBSOLETE_OWNER 1 /* It will be removed for 2.6.15 */ | ||
| 25 | #define HAVE_V4L2 1 | ||
| 26 | |||
| 27 | /* | ||
| 28 | * Common stuff for both V4L1 and V4L2 | ||
| 29 | * Moved from videodev.h | ||
| 30 | */ | ||
| 31 | |||
| 32 | #define VIDEO_MAX_FRAME 32 | ||
| 33 | |||
| 34 | #define VID_TYPE_CAPTURE 1 /* Can capture */ | ||
| 35 | #define VID_TYPE_TUNER 2 /* Can tune */ | ||
| 36 | #define VID_TYPE_TELETEXT 4 /* Does teletext */ | ||
| 37 | #define VID_TYPE_OVERLAY 8 /* Overlay onto frame buffer */ | ||
| 38 | #define VID_TYPE_CHROMAKEY 16 /* Overlay by chromakey */ | ||
| 39 | #define VID_TYPE_CLIPPING 32 /* Can clip */ | ||
| 40 | #define VID_TYPE_FRAMERAM 64 /* Uses the frame buffer memory */ | ||
| 41 | #define VID_TYPE_SCALES 128 /* Scalable */ | ||
| 42 | #define VID_TYPE_MONOCHROME 256 /* Monochrome only */ | ||
| 43 | #define VID_TYPE_SUBCAPTURE 512 /* Can capture subareas of the image */ | ||
| 44 | #define VID_TYPE_MPEG_DECODER 1024 /* Can decode MPEG streams */ | ||
| 45 | #define VID_TYPE_MPEG_ENCODER 2048 /* Can encode MPEG streams */ | ||
| 46 | #define VID_TYPE_MJPEG_DECODER 4096 /* Can decode MJPEG streams */ | ||
| 47 | #define VID_TYPE_MJPEG_ENCODER 8192 /* Can encode MJPEG streams */ | ||
| 48 | |||
| 49 | #ifdef __KERNEL__ | ||
| 50 | |||
| 51 | #define VFL_TYPE_GRABBER 0 | ||
| 52 | #define VFL_TYPE_VBI 1 | ||
| 53 | #define VFL_TYPE_RADIO 2 | ||
| 54 | #define VFL_TYPE_VTX 3 | ||
| 55 | |||
| 56 | struct video_device | ||
| 57 | { | ||
| 58 | /* device info */ | ||
| 59 | struct device *dev; | ||
| 60 | char name[32]; | ||
| 61 | int type; /* v4l1 */ | ||
| 62 | int type2; /* v4l2 */ | ||
| 63 | int hardware; | ||
| 64 | int minor; | ||
| 65 | |||
| 66 | /* device ops + callbacks */ | ||
| 67 | struct file_operations *fops; | ||
| 68 | void (*release)(struct video_device *vfd); | ||
| 69 | |||
| 70 | |||
| 71 | #if OBSOLETE_OWNER /* to be removed in 2.6.15 */ | ||
| 72 | /* obsolete -- fops->owner is used instead */ | ||
| 73 | struct module *owner; | ||
| 74 | /* dev->driver_data will be used instead some day. | ||
| 75 | * Use the video_{get|set}_drvdata() helper functions, | ||
| 76 | * so the switch over will be transparent for you. | ||
| 77 | * Or use {pci|usb}_{get|set}_drvdata() directly. */ | ||
| 78 | void *priv; | ||
| 79 | #endif | ||
| 80 | |||
| 81 | /* for videodev.c intenal usage -- please don't touch */ | ||
| 82 | int users; /* video_exclusive_{open|close} ... */ | ||
| 83 | struct semaphore lock; /* ... helper function uses these */ | ||
| 84 | char devfs_name[64]; /* devfs */ | ||
| 85 | struct class_device class_dev; /* sysfs */ | ||
| 86 | }; | ||
| 87 | |||
| 88 | #define VIDEO_MAJOR 81 | ||
| 89 | |||
| 90 | extern int video_register_device(struct video_device *, int type, int nr); | ||
| 91 | extern void video_unregister_device(struct video_device *); | ||
| 92 | extern int video_usercopy(struct inode *inode, struct file *file, | ||
| 93 | unsigned int cmd, unsigned long arg, | ||
| 94 | int (*func)(struct inode *inode, struct file *file, | ||
| 95 | unsigned int cmd, void *arg)); | ||
| 96 | |||
| 97 | /* helper functions to alloc / release struct video_device, the | ||
| 98 | later can be used for video_device->release() */ | ||
| 99 | struct video_device *video_device_alloc(void); | ||
| 100 | void video_device_release(struct video_device *vfd); | ||
| 101 | |||
| 102 | #endif | ||
| 103 | |||
| 21 | /* | 104 | /* |
| 22 | * M I S C E L L A N E O U S | 105 | * M I S C E L L A N E O U S |
| 23 | */ | 106 | */ |
| 24 | 107 | ||
| 25 | /* Four-character-code (FOURCC) */ | 108 | /* Four-character-code (FOURCC) */ |
| 26 | #define v4l2_fourcc(a,b,c,d)\ | 109 | #define v4l2_fourcc(a,b,c,d)\ |
| 27 | (((__u32)(a)<<0)|((__u32)(b)<<8)|((__u32)(c)<<16)|((__u32)(d)<<24)) | 110 | (((__u32)(a)<<0)|((__u32)(b)<<8)|((__u32)(c)<<16)|((__u32)(d)<<24)) |
| 28 | 111 | ||
| 29 | /* | 112 | /* |
| 30 | * E N U M S | 113 | * E N U M S |
| @@ -154,20 +237,20 @@ struct v4l2_capability | |||
| 154 | }; | 237 | }; |
| 155 | 238 | ||
| 156 | /* Values for 'capabilities' field */ | 239 | /* Values for 'capabilities' field */ |
| 157 | #define V4L2_CAP_VIDEO_CAPTURE 0x00000001 /* Is a video capture device */ | 240 | #define V4L2_CAP_VIDEO_CAPTURE 0x00000001 /* Is a video capture device */ |
| 158 | #define V4L2_CAP_VIDEO_OUTPUT 0x00000002 /* Is a video output device */ | 241 | #define V4L2_CAP_VIDEO_OUTPUT 0x00000002 /* Is a video output device */ |
| 159 | #define V4L2_CAP_VIDEO_OVERLAY 0x00000004 /* Can do video overlay */ | 242 | #define V4L2_CAP_VIDEO_OVERLAY 0x00000004 /* Can do video overlay */ |
| 160 | #define V4L2_CAP_VBI_CAPTURE 0x00000010 /* Is a raw VBI capture device */ | 243 | #define V4L2_CAP_VBI_CAPTURE 0x00000010 /* Is a raw VBI capture device */ |
| 161 | #define V4L2_CAP_VBI_OUTPUT 0x00000020 /* Is a raw VBI output device */ | 244 | #define V4L2_CAP_VBI_OUTPUT 0x00000020 /* Is a raw VBI output device */ |
| 162 | #if 1 | 245 | #if 1 |
| 163 | #define V4L2_CAP_SLICED_VBI_CAPTURE 0x00000040 /* Is a sliced VBI capture device */ | 246 | #define V4L2_CAP_SLICED_VBI_CAPTURE 0x00000040 /* Is a sliced VBI capture device */ |
| 164 | #define V4L2_CAP_SLICED_VBI_OUTPUT 0x00000080 /* Is a sliced VBI output device */ | 247 | #define V4L2_CAP_SLICED_VBI_OUTPUT 0x00000080 /* Is a sliced VBI output device */ |
| 165 | #endif | 248 | #endif |
| 166 | #define V4L2_CAP_RDS_CAPTURE 0x00000100 /* RDS data capture */ | 249 | #define V4L2_CAP_RDS_CAPTURE 0x00000100 /* RDS data capture */ |
| 167 | 250 | ||
| 168 | #define V4L2_CAP_TUNER 0x00010000 /* has a tuner */ | 251 | #define V4L2_CAP_TUNER 0x00010000 /* has a tuner */ |
| 169 | #define V4L2_CAP_AUDIO 0x00020000 /* has audio support */ | 252 | #define V4L2_CAP_AUDIO 0x00020000 /* has audio support */ |
| 170 | #define V4L2_CAP_RADIO 0x00040000 /* is a radio device */ | 253 | #define V4L2_CAP_RADIO 0x00040000 /* is a radio device */ |
| 171 | 254 | ||
| 172 | #define V4L2_CAP_READWRITE 0x01000000 /* read/write systemcalls */ | 255 | #define V4L2_CAP_READWRITE 0x01000000 /* read/write systemcalls */ |
| 173 | #define V4L2_CAP_ASYNCIO 0x02000000 /* async I/O */ | 256 | #define V4L2_CAP_ASYNCIO 0x02000000 /* async I/O */ |
| @@ -179,13 +262,13 @@ struct v4l2_capability | |||
| 179 | 262 | ||
| 180 | struct v4l2_pix_format | 263 | struct v4l2_pix_format |
| 181 | { | 264 | { |
| 182 | __u32 width; | 265 | __u32 width; |
| 183 | __u32 height; | 266 | __u32 height; |
| 184 | __u32 pixelformat; | 267 | __u32 pixelformat; |
| 185 | enum v4l2_field field; | 268 | enum v4l2_field field; |
| 186 | __u32 bytesperline; /* for padding, zero if unused */ | 269 | __u32 bytesperline; /* for padding, zero if unused */ |
| 187 | __u32 sizeimage; | 270 | __u32 sizeimage; |
| 188 | enum v4l2_colorspace colorspace; | 271 | enum v4l2_colorspace colorspace; |
| 189 | __u32 priv; /* private data, depends on pixelformat */ | 272 | __u32 priv; /* private data, depends on pixelformat */ |
| 190 | }; | 273 | }; |
| 191 | 274 | ||
| @@ -238,12 +321,12 @@ struct v4l2_pix_format | |||
| 238 | */ | 321 | */ |
| 239 | struct v4l2_fmtdesc | 322 | struct v4l2_fmtdesc |
| 240 | { | 323 | { |
| 241 | __u32 index; /* Format number */ | 324 | __u32 index; /* Format number */ |
| 242 | enum v4l2_buf_type type; /* buffer type */ | 325 | enum v4l2_buf_type type; /* buffer type */ |
| 243 | __u32 flags; | 326 | __u32 flags; |
| 244 | __u8 description[32]; /* Description string */ | 327 | __u8 description[32]; /* Description string */ |
| 245 | __u32 pixelformat; /* Format fourcc */ | 328 | __u32 pixelformat; /* Format fourcc */ |
| 246 | __u32 reserved[4]; | 329 | __u32 reserved[4]; |
| 247 | }; | 330 | }; |
| 248 | 331 | ||
| 249 | #define V4L2_FMT_FLAG_COMPRESSED 0x0001 | 332 | #define V4L2_FMT_FLAG_COMPRESSED 0x0001 |
| @@ -393,7 +476,7 @@ struct v4l2_jpegcompression | |||
| 393 | #define V4L2_JPEG_MARKER_DRI (1<<5) /* Define Restart Interval */ | 476 | #define V4L2_JPEG_MARKER_DRI (1<<5) /* Define Restart Interval */ |
| 394 | #define V4L2_JPEG_MARKER_COM (1<<6) /* Comment segment */ | 477 | #define V4L2_JPEG_MARKER_COM (1<<6) /* Comment segment */ |
| 395 | #define V4L2_JPEG_MARKER_APP (1<<7) /* App segment, driver will | 478 | #define V4L2_JPEG_MARKER_APP (1<<7) /* App segment, driver will |
| 396 | * allways use APP0 */ | 479 | * allways use APP0 */ |
| 397 | }; | 480 | }; |
| 398 | 481 | ||
| 399 | 482 | ||
| @@ -402,10 +485,10 @@ struct v4l2_jpegcompression | |||
| 402 | */ | 485 | */ |
| 403 | struct v4l2_requestbuffers | 486 | struct v4l2_requestbuffers |
| 404 | { | 487 | { |
| 405 | __u32 count; | 488 | __u32 count; |
| 406 | enum v4l2_buf_type type; | 489 | enum v4l2_buf_type type; |
| 407 | enum v4l2_memory memory; | 490 | enum v4l2_memory memory; |
| 408 | __u32 reserved[2]; | 491 | __u32 reserved[2]; |
| 409 | }; | 492 | }; |
| 410 | 493 | ||
| 411 | struct v4l2_buffer | 494 | struct v4l2_buffer |
| @@ -511,9 +594,9 @@ struct v4l2_outputparm | |||
| 511 | 594 | ||
| 512 | struct v4l2_cropcap { | 595 | struct v4l2_cropcap { |
| 513 | enum v4l2_buf_type type; | 596 | enum v4l2_buf_type type; |
| 514 | struct v4l2_rect bounds; | 597 | struct v4l2_rect bounds; |
| 515 | struct v4l2_rect defrect; | 598 | struct v4l2_rect defrect; |
| 516 | struct v4l2_fract pixelaspect; | 599 | struct v4l2_fract pixelaspect; |
| 517 | }; | 600 | }; |
| 518 | 601 | ||
| 519 | struct v4l2_crop { | 602 | struct v4l2_crop { |
| @@ -544,6 +627,7 @@ typedef __u64 v4l2_std_id; | |||
| 544 | 627 | ||
| 545 | #define V4L2_STD_NTSC_M ((v4l2_std_id)0x00001000) | 628 | #define V4L2_STD_NTSC_M ((v4l2_std_id)0x00001000) |
| 546 | #define V4L2_STD_NTSC_M_JP ((v4l2_std_id)0x00002000) | 629 | #define V4L2_STD_NTSC_M_JP ((v4l2_std_id)0x00002000) |
| 630 | #define V4L2_STD_NTSC_443 ((v4l2_std_id)0x00004000) | ||
| 547 | 631 | ||
| 548 | #define V4L2_STD_SECAM_B ((v4l2_std_id)0x00010000) | 632 | #define V4L2_STD_SECAM_B ((v4l2_std_id)0x00010000) |
| 549 | #define V4L2_STD_SECAM_D ((v4l2_std_id)0x00020000) | 633 | #define V4L2_STD_SECAM_D ((v4l2_std_id)0x00020000) |
| @@ -581,13 +665,14 @@ typedef __u64 v4l2_std_id; | |||
| 581 | 665 | ||
| 582 | #define V4L2_STD_525_60 (V4L2_STD_PAL_M |\ | 666 | #define V4L2_STD_525_60 (V4L2_STD_PAL_M |\ |
| 583 | V4L2_STD_PAL_60 |\ | 667 | V4L2_STD_PAL_60 |\ |
| 584 | V4L2_STD_NTSC) | 668 | V4L2_STD_NTSC |\ |
| 669 | V4L2_STD_NTSC_443) | ||
| 585 | #define V4L2_STD_625_50 (V4L2_STD_PAL |\ | 670 | #define V4L2_STD_625_50 (V4L2_STD_PAL |\ |
| 586 | V4L2_STD_PAL_N |\ | 671 | V4L2_STD_PAL_N |\ |
| 587 | V4L2_STD_PAL_Nc |\ | 672 | V4L2_STD_PAL_Nc |\ |
| 588 | V4L2_STD_SECAM) | 673 | V4L2_STD_SECAM) |
| 589 | #define V4L2_STD_ATSC (V4L2_STD_ATSC_8_VSB |\ | 674 | #define V4L2_STD_ATSC (V4L2_STD_ATSC_8_VSB |\ |
| 590 | V4L2_STD_ATSC_16_VSB) | 675 | V4L2_STD_ATSC_16_VSB) |
| 591 | 676 | ||
| 592 | #define V4L2_STD_UNKNOWN 0 | 677 | #define V4L2_STD_UNKNOWN 0 |
| 593 | #define V4L2_STD_ALL (V4L2_STD_525_60 |\ | 678 | #define V4L2_STD_ALL (V4L2_STD_525_60 |\ |
| @@ -595,7 +680,7 @@ typedef __u64 v4l2_std_id; | |||
| 595 | 680 | ||
| 596 | struct v4l2_standard | 681 | struct v4l2_standard |
| 597 | { | 682 | { |
| 598 | __u32 index; | 683 | __u32 index; |
| 599 | v4l2_std_id id; | 684 | v4l2_std_id id; |
| 600 | __u8 name[24]; | 685 | __u8 name[24]; |
| 601 | struct v4l2_fract frameperiod; /* Frames, not fields */ | 686 | struct v4l2_fract frameperiod; /* Frames, not fields */ |
| @@ -610,9 +695,9 @@ struct v4l2_standard | |||
| 610 | struct v4l2_input | 695 | struct v4l2_input |
| 611 | { | 696 | { |
| 612 | __u32 index; /* Which input */ | 697 | __u32 index; /* Which input */ |
| 613 | __u8 name[32]; /* Label */ | 698 | __u8 name[32]; /* Label */ |
| 614 | __u32 type; /* Type of input */ | 699 | __u32 type; /* Type of input */ |
| 615 | __u32 audioset; /* Associated audios (bitfield) */ | 700 | __u32 audioset; /* Associated audios (bitfield) */ |
| 616 | __u32 tuner; /* Associated tuner */ | 701 | __u32 tuner; /* Associated tuner */ |
| 617 | v4l2_std_id std; | 702 | v4l2_std_id std; |
| 618 | __u32 status; | 703 | __u32 status; |
| @@ -647,9 +732,9 @@ struct v4l2_input | |||
| 647 | struct v4l2_output | 732 | struct v4l2_output |
| 648 | { | 733 | { |
| 649 | __u32 index; /* Which output */ | 734 | __u32 index; /* Which output */ |
| 650 | __u8 name[32]; /* Label */ | 735 | __u8 name[32]; /* Label */ |
| 651 | __u32 type; /* Type of output */ | 736 | __u32 type; /* Type of output */ |
| 652 | __u32 audioset; /* Associated audios (bitfield) */ | 737 | __u32 audioset; /* Associated audios (bitfield) */ |
| 653 | __u32 modulator; /* Associated modulator */ | 738 | __u32 modulator; /* Associated modulator */ |
| 654 | v4l2_std_id std; | 739 | v4l2_std_id std; |
| 655 | __u32 reserved[4]; | 740 | __u32 reserved[4]; |
| @@ -671,12 +756,12 @@ struct v4l2_control | |||
| 671 | /* Used in the VIDIOC_QUERYCTRL ioctl for querying controls */ | 756 | /* Used in the VIDIOC_QUERYCTRL ioctl for querying controls */ |
| 672 | struct v4l2_queryctrl | 757 | struct v4l2_queryctrl |
| 673 | { | 758 | { |
| 674 | __u32 id; | 759 | __u32 id; |
| 675 | enum v4l2_ctrl_type type; | 760 | enum v4l2_ctrl_type type; |
| 676 | __u8 name[32]; /* Whatever */ | 761 | __u8 name[32]; /* Whatever */ |
| 677 | __s32 minimum; /* Note signedness */ | 762 | __s32 minimum; /* Note signedness */ |
| 678 | __s32 maximum; | 763 | __s32 maximum; |
| 679 | __s32 step; | 764 | __s32 step; |
| 680 | __s32 default_value; | 765 | __s32 default_value; |
| 681 | __u32 flags; | 766 | __u32 flags; |
| 682 | __u32 reserved[2]; | 767 | __u32 reserved[2]; |
| @@ -779,10 +864,10 @@ struct v4l2_modulator | |||
| 779 | 864 | ||
| 780 | struct v4l2_frequency | 865 | struct v4l2_frequency |
| 781 | { | 866 | { |
| 782 | __u32 tuner; | 867 | __u32 tuner; |
| 783 | enum v4l2_tuner_type type; | 868 | enum v4l2_tuner_type type; |
| 784 | __u32 frequency; | 869 | __u32 frequency; |
| 785 | __u32 reserved[8]; | 870 | __u32 reserved[8]; |
| 786 | }; | 871 | }; |
| 787 | 872 | ||
| 788 | /* | 873 | /* |
| @@ -802,6 +887,7 @@ struct v4l2_audio | |||
| 802 | 887 | ||
| 803 | /* Flags for the 'mode' field */ | 888 | /* Flags for the 'mode' field */ |
| 804 | #define V4L2_AUDMODE_AVL 0x00001 | 889 | #define V4L2_AUDMODE_AVL 0x00001 |
| 890 | #define V4L2_AUDMODE_32BITS 0x00002 | ||
| 805 | 891 | ||
| 806 | struct v4l2_audioout | 892 | struct v4l2_audioout |
| 807 | { | 893 | { |
| @@ -846,14 +932,14 @@ struct v4l2_vbi_format | |||
| 846 | 932 | ||
| 847 | struct v4l2_sliced_vbi_format | 933 | struct v4l2_sliced_vbi_format |
| 848 | { | 934 | { |
| 849 | __u16 service_set; | 935 | __u16 service_set; |
| 850 | /* service_lines[0][...] specifies lines 0-23 (1-23 used) of the first field | 936 | /* service_lines[0][...] specifies lines 0-23 (1-23 used) of the first field |
| 851 | service_lines[1][...] specifies lines 0-23 (1-23 used) of the second field | 937 | service_lines[1][...] specifies lines 0-23 (1-23 used) of the second field |
| 852 | (equals frame lines 313-336 for 625 line video | 938 | (equals frame lines 313-336 for 625 line video |
| 853 | standards, 263-286 for 525 line standards) */ | 939 | standards, 263-286 for 525 line standards) */ |
| 854 | __u16 service_lines[2][24]; | 940 | __u16 service_lines[2][24]; |
| 855 | __u32 io_size; | 941 | __u32 io_size; |
| 856 | __u32 reserved[2]; /* must be zero */ | 942 | __u32 reserved[2]; /* must be zero */ |
| 857 | }; | 943 | }; |
| 858 | 944 | ||
| 859 | #define V4L2_SLICED_TELETEXT_B (0x0001) | 945 | #define V4L2_SLICED_TELETEXT_B (0x0001) |
| @@ -866,22 +952,22 @@ struct v4l2_sliced_vbi_format | |||
| 866 | 952 | ||
| 867 | struct v4l2_sliced_vbi_cap | 953 | struct v4l2_sliced_vbi_cap |
| 868 | { | 954 | { |
| 869 | __u16 service_set; | 955 | __u16 service_set; |
| 870 | /* service_lines[0][...] specifies lines 0-23 (1-23 used) of the first field | 956 | /* service_lines[0][...] specifies lines 0-23 (1-23 used) of the first field |
| 871 | service_lines[1][...] specifies lines 0-23 (1-23 used) of the second field | 957 | service_lines[1][...] specifies lines 0-23 (1-23 used) of the second field |
| 872 | (equals frame lines 313-336 for 625 line video | 958 | (equals frame lines 313-336 for 625 line video |
| 873 | standards, 263-286 for 525 line standards) */ | 959 | standards, 263-286 for 525 line standards) */ |
| 874 | __u16 service_lines[2][24]; | 960 | __u16 service_lines[2][24]; |
| 875 | __u32 reserved[4]; /* must be 0 */ | 961 | __u32 reserved[4]; /* must be 0 */ |
| 876 | }; | 962 | }; |
| 877 | 963 | ||
| 878 | struct v4l2_sliced_vbi_data | 964 | struct v4l2_sliced_vbi_data |
| 879 | { | 965 | { |
| 880 | __u32 id; | 966 | __u32 id; |
| 881 | __u32 field; /* 0: first field, 1: second field */ | 967 | __u32 field; /* 0: first field, 1: second field */ |
| 882 | __u32 line; /* 1-23 */ | 968 | __u32 line; /* 1-23 */ |
| 883 | __u32 reserved; /* must be 0 */ | 969 | __u32 reserved; /* must be 0 */ |
| 884 | __u8 data[48]; | 970 | __u8 data[48]; |
| 885 | }; | 971 | }; |
| 886 | #endif | 972 | #endif |
| 887 | 973 | ||
| @@ -896,9 +982,9 @@ struct v4l2_format | |||
| 896 | enum v4l2_buf_type type; | 982 | enum v4l2_buf_type type; |
| 897 | union | 983 | union |
| 898 | { | 984 | { |
| 899 | struct v4l2_pix_format pix; // V4L2_BUF_TYPE_VIDEO_CAPTURE | 985 | struct v4l2_pix_format pix; // V4L2_BUF_TYPE_VIDEO_CAPTURE |
| 900 | struct v4l2_window win; // V4L2_BUF_TYPE_VIDEO_OVERLAY | 986 | struct v4l2_window win; // V4L2_BUF_TYPE_VIDEO_OVERLAY |
| 901 | struct v4l2_vbi_format vbi; // V4L2_BUF_TYPE_VBI_CAPTURE | 987 | struct v4l2_vbi_format vbi; // V4L2_BUF_TYPE_VBI_CAPTURE |
| 902 | #if 1 | 988 | #if 1 |
| 903 | struct v4l2_sliced_vbi_format sliced; // V4L2_BUF_TYPE_SLICED_VBI_CAPTURE | 989 | struct v4l2_sliced_vbi_format sliced; // V4L2_BUF_TYPE_SLICED_VBI_CAPTURE |
| 904 | #endif | 990 | #endif |
| @@ -981,6 +1067,7 @@ struct v4l2_streamparm | |||
| 981 | #if 1 | 1067 | #if 1 |
| 982 | #define VIDIOC_G_SLICED_VBI_CAP _IOR ('V', 69, struct v4l2_sliced_vbi_cap) | 1068 | #define VIDIOC_G_SLICED_VBI_CAP _IOR ('V', 69, struct v4l2_sliced_vbi_cap) |
| 983 | #endif | 1069 | #endif |
| 1070 | #define VIDIOC_LOG_STATUS _IO ('V', 70) | ||
| 984 | 1071 | ||
| 985 | /* for compatibility, will go away some day */ | 1072 | /* for compatibility, will go away some day */ |
| 986 | #define VIDIOC_OVERLAY_OLD _IOWR ('V', 14, int) | 1073 | #define VIDIOC_OVERLAY_OLD _IOWR ('V', 14, int) |
