diff options
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/bfs_fs.h | 23 | ||||
-rw-r--r-- | include/linux/dccp.h | 3 | ||||
-rw-r--r-- | include/linux/fb.h | 28 | ||||
-rw-r--r-- | include/linux/file.h | 30 | ||||
-rw-r--r-- | include/linux/fs.h | 4 | ||||
-rw-r--r-- | include/linux/fuse.h | 259 | ||||
-rw-r--r-- | include/linux/init_task.h | 18 | ||||
-rw-r--r-- | include/linux/pci.h | 1 | ||||
-rw-r--r-- | include/linux/rcupdate.h | 4 | ||||
-rw-r--r-- | include/linux/rcuref.h | 220 | ||||
-rw-r--r-- | include/linux/sched.h | 5 | ||||
-rw-r--r-- | include/linux/security.h | 180 | ||||
-rw-r--r-- | include/linux/timer.h | 4 | ||||
-rw-r--r-- | include/linux/tty.h | 3 | ||||
-rw-r--r-- | include/linux/videodev.h | 3 | ||||
-rw-r--r-- | include/linux/videodev2.h | 4 |
16 files changed, 614 insertions, 175 deletions
diff --git a/include/linux/bfs_fs.h b/include/linux/bfs_fs.h index f7f0913cd110..c1237aa92e38 100644 --- a/include/linux/bfs_fs.h +++ b/include/linux/bfs_fs.h | |||
@@ -14,8 +14,9 @@ | |||
14 | #define BFS_INODES_PER_BLOCK 8 | 14 | #define BFS_INODES_PER_BLOCK 8 |
15 | 15 | ||
16 | /* SVR4 vnode type values (bfs_inode->i_vtype) */ | 16 | /* SVR4 vnode type values (bfs_inode->i_vtype) */ |
17 | #define BFS_VDIR 2 | 17 | #define BFS_VDIR 2L |
18 | #define BFS_VREG 1 | 18 | #define BFS_VREG 1L |
19 | |||
19 | 20 | ||
20 | /* BFS inode layout on disk */ | 21 | /* BFS inode layout on disk */ |
21 | struct bfs_inode { | 22 | struct bfs_inode { |
@@ -58,22 +59,22 @@ struct bfs_super_block { | |||
58 | __u32 s_padding[118]; | 59 | __u32 s_padding[118]; |
59 | }; | 60 | }; |
60 | 61 | ||
61 | #define BFS_NZFILESIZE(ip) \ | ||
62 | (((ip)->i_eoffset + 1) - (ip)->i_sblock * BFS_BSIZE) | ||
63 | |||
64 | #define BFS_FILESIZE(ip) \ | ||
65 | ((ip)->i_sblock == 0 ? 0 : BFS_NZFILESIZE(ip)) | ||
66 | |||
67 | #define BFS_FILEBLOCKS(ip) \ | ||
68 | ((ip)->i_sblock == 0 ? 0 : ((ip)->i_eblock + 1) - (ip)->i_sblock) | ||
69 | 62 | ||
70 | #define BFS_OFF2INO(offset) \ | 63 | #define BFS_OFF2INO(offset) \ |
71 | ((((offset) - BFS_BSIZE) / sizeof(struct bfs_inode)) + BFS_ROOT_INO) | 64 | ((((offset) - BFS_BSIZE) / sizeof(struct bfs_inode)) + BFS_ROOT_INO) |
72 | 65 | ||
73 | #define BFS_INO2OFF(ino) \ | 66 | #define BFS_INO2OFF(ino) \ |
74 | ((__u32)(((ino) - BFS_ROOT_INO) * sizeof(struct bfs_inode)) + BFS_BSIZE) | 67 | ((__u32)(((ino) - BFS_ROOT_INO) * sizeof(struct bfs_inode)) + BFS_BSIZE) |
68 | #define BFS_NZFILESIZE(ip) \ | ||
69 | ((cpu_to_le32((ip)->i_eoffset) + 1) - cpu_to_le32((ip)->i_sblock) * BFS_BSIZE) | ||
70 | |||
71 | #define BFS_FILESIZE(ip) \ | ||
72 | ((ip)->i_sblock == 0 ? 0 : BFS_NZFILESIZE(ip)) | ||
75 | 73 | ||
74 | #define BFS_FILEBLOCKS(ip) \ | ||
75 | ((ip)->i_sblock == 0 ? 0 : (cpu_to_le32((ip)->i_eblock) + 1) - cpu_to_le32((ip)->i_sblock)) | ||
76 | #define BFS_UNCLEAN(bfs_sb, sb) \ | 76 | #define BFS_UNCLEAN(bfs_sb, sb) \ |
77 | ((bfs_sb->s_from != -1) && (bfs_sb->s_to != -1) && !(sb->s_flags & MS_RDONLY)) | 77 | ((cpu_to_le32(bfs_sb->s_from) != -1) && (cpu_to_le32(bfs_sb->s_to) != -1) && !(sb->s_flags & MS_RDONLY)) |
78 | |||
78 | 79 | ||
79 | #endif /* _LINUX_BFS_FS_H */ | 80 | #endif /* _LINUX_BFS_FS_H */ |
diff --git a/include/linux/dccp.h b/include/linux/dccp.h index 007c290f74d4..8bf4bacb5051 100644 --- a/include/linux/dccp.h +++ b/include/linux/dccp.h | |||
@@ -432,7 +432,10 @@ struct dccp_sock { | |||
432 | struct ccid *dccps_hc_rx_ccid; | 432 | struct ccid *dccps_hc_rx_ccid; |
433 | struct ccid *dccps_hc_tx_ccid; | 433 | struct ccid *dccps_hc_tx_ccid; |
434 | struct dccp_options_received dccps_options_received; | 434 | struct dccp_options_received dccps_options_received; |
435 | struct timeval dccps_epoch; | ||
435 | enum dccp_role dccps_role:2; | 436 | enum dccp_role dccps_role:2; |
437 | __u8 dccps_hc_rx_insert_options:1; | ||
438 | __u8 dccps_hc_tx_insert_options:1; | ||
436 | }; | 439 | }; |
437 | 440 | ||
438 | static inline struct dccp_sock *dccp_sk(const struct sock *sk) | 441 | static inline struct dccp_sock *dccp_sk(const struct sock *sk) |
diff --git a/include/linux/fb.h b/include/linux/fb.h index bc24beeed971..82e39cd0c4fb 100644 --- a/include/linux/fb.h +++ b/include/linux/fb.h | |||
@@ -107,6 +107,8 @@ | |||
107 | #define FB_ACCEL_NV_20 44 /* nVidia Arch 20 */ | 107 | #define FB_ACCEL_NV_20 44 /* nVidia Arch 20 */ |
108 | #define FB_ACCEL_NV_30 45 /* nVidia Arch 30 */ | 108 | #define FB_ACCEL_NV_30 45 /* nVidia Arch 30 */ |
109 | #define FB_ACCEL_NV_40 46 /* nVidia Arch 40 */ | 109 | #define FB_ACCEL_NV_40 46 /* nVidia Arch 40 */ |
110 | #define FB_ACCEL_XGI_VOLARI_V 47 /* XGI Volari V3XT, V5, V8 */ | ||
111 | #define FB_ACCEL_XGI_VOLARI_Z 48 /* XGI Volari Z7 */ | ||
110 | #define FB_ACCEL_NEOMAGIC_NM2070 90 /* NeoMagic NM2070 */ | 112 | #define FB_ACCEL_NEOMAGIC_NM2070 90 /* NeoMagic NM2070 */ |
111 | #define FB_ACCEL_NEOMAGIC_NM2090 91 /* NeoMagic NM2090 */ | 113 | #define FB_ACCEL_NEOMAGIC_NM2090 91 /* NeoMagic NM2090 */ |
112 | #define FB_ACCEL_NEOMAGIC_NM2093 92 /* NeoMagic NM2093 */ | 114 | #define FB_ACCEL_NEOMAGIC_NM2093 92 /* NeoMagic NM2093 */ |
@@ -495,6 +497,9 @@ struct fb_cursor_user { | |||
495 | #define FB_EVENT_BLANK 0x08 | 497 | #define FB_EVENT_BLANK 0x08 |
496 | /* Private modelist is to be replaced */ | 498 | /* Private modelist is to be replaced */ |
497 | #define FB_EVENT_NEW_MODELIST 0x09 | 499 | #define FB_EVENT_NEW_MODELIST 0x09 |
500 | /* The resolution of the passed in fb_info about to change and | ||
501 | all vc's should be changed */ | ||
502 | #define FB_EVENT_MODE_CHANGE_ALL 0x0A | ||
498 | 503 | ||
499 | struct fb_event { | 504 | struct fb_event { |
500 | struct fb_info *info; | 505 | struct fb_info *info; |
@@ -820,13 +825,29 @@ extern void fb_pad_unaligned_buffer(u8 *dst, u32 d_pitch, u8 *src, u32 idx, | |||
820 | u32 height, u32 shift_high, u32 shift_low, u32 mod); | 825 | u32 height, u32 shift_high, u32 shift_low, u32 mod); |
821 | extern void fb_pad_aligned_buffer(u8 *dst, u32 d_pitch, u8 *src, u32 s_pitch, u32 height); | 826 | extern void fb_pad_aligned_buffer(u8 *dst, u32 d_pitch, u8 *src, u32 s_pitch, u32 height); |
822 | extern void fb_set_suspend(struct fb_info *info, int state); | 827 | extern void fb_set_suspend(struct fb_info *info, int state); |
823 | extern int fb_get_color_depth(struct fb_var_screeninfo *var); | 828 | extern int fb_get_color_depth(struct fb_var_screeninfo *var, |
829 | struct fb_fix_screeninfo *fix); | ||
824 | extern int fb_get_options(char *name, char **option); | 830 | extern int fb_get_options(char *name, char **option); |
825 | extern int fb_new_modelist(struct fb_info *info); | 831 | extern int fb_new_modelist(struct fb_info *info); |
826 | 832 | ||
827 | extern struct fb_info *registered_fb[FB_MAX]; | 833 | extern struct fb_info *registered_fb[FB_MAX]; |
828 | extern int num_registered_fb; | 834 | extern int num_registered_fb; |
829 | 835 | ||
836 | static inline void __fb_pad_aligned_buffer(u8 *dst, u32 d_pitch, | ||
837 | u8 *src, u32 s_pitch, u32 height) | ||
838 | { | ||
839 | int i, j; | ||
840 | |||
841 | d_pitch -= s_pitch; | ||
842 | |||
843 | for (i = height; i--; ) { | ||
844 | /* s_pitch is a few bytes at the most, memcpy is suboptimal */ | ||
845 | for (j = 0; j < s_pitch; j++) | ||
846 | *dst++ = *src++; | ||
847 | dst += d_pitch; | ||
848 | } | ||
849 | } | ||
850 | |||
830 | /* drivers/video/fbsysfs.c */ | 851 | /* drivers/video/fbsysfs.c */ |
831 | extern struct fb_info *framebuffer_alloc(size_t size, struct device *dev); | 852 | extern struct fb_info *framebuffer_alloc(size_t size, struct device *dev); |
832 | extern void framebuffer_release(struct fb_info *info); | 853 | extern void framebuffer_release(struct fb_info *info); |
@@ -856,8 +877,11 @@ extern int fb_get_mode(int flags, u32 val, struct fb_var_screeninfo *var, | |||
856 | extern int fb_validate_mode(const struct fb_var_screeninfo *var, | 877 | extern int fb_validate_mode(const struct fb_var_screeninfo *var, |
857 | struct fb_info *info); | 878 | struct fb_info *info); |
858 | extern int fb_parse_edid(unsigned char *edid, struct fb_var_screeninfo *var); | 879 | extern int fb_parse_edid(unsigned char *edid, struct fb_var_screeninfo *var); |
859 | extern void fb_edid_to_monspecs(unsigned char *edid, struct fb_monspecs *specs); | 880 | extern const unsigned char *fb_firmware_edid(struct device *device); |
881 | extern void fb_edid_to_monspecs(unsigned char *edid, | ||
882 | struct fb_monspecs *specs); | ||
860 | extern void fb_destroy_modedb(struct fb_videomode *modedb); | 883 | extern void fb_destroy_modedb(struct fb_videomode *modedb); |
884 | extern int fb_find_mode_cvt(struct fb_videomode *mode, int margins, int rb); | ||
861 | 885 | ||
862 | /* drivers/video/modedb.c */ | 886 | /* drivers/video/modedb.c */ |
863 | #define VESA_MODEDB_SIZE 34 | 887 | #define VESA_MODEDB_SIZE 34 |
diff --git a/include/linux/file.h b/include/linux/file.h index 5206beb9a80e..f5bbd4c508b3 100644 --- a/include/linux/file.h +++ b/include/linux/file.h | |||
@@ -9,6 +9,7 @@ | |||
9 | #include <linux/posix_types.h> | 9 | #include <linux/posix_types.h> |
10 | #include <linux/compiler.h> | 10 | #include <linux/compiler.h> |
11 | #include <linux/spinlock.h> | 11 | #include <linux/spinlock.h> |
12 | #include <linux/rcupdate.h> | ||
12 | 13 | ||
13 | /* | 14 | /* |
14 | * The default fd array needs to be at least BITS_PER_LONG, | 15 | * The default fd array needs to be at least BITS_PER_LONG, |
@@ -16,23 +17,33 @@ | |||
16 | */ | 17 | */ |
17 | #define NR_OPEN_DEFAULT BITS_PER_LONG | 18 | #define NR_OPEN_DEFAULT BITS_PER_LONG |
18 | 19 | ||
20 | struct fdtable { | ||
21 | unsigned int max_fds; | ||
22 | int max_fdset; | ||
23 | int next_fd; | ||
24 | struct file ** fd; /* current fd array */ | ||
25 | fd_set *close_on_exec; | ||
26 | fd_set *open_fds; | ||
27 | struct rcu_head rcu; | ||
28 | struct files_struct *free_files; | ||
29 | struct fdtable *next; | ||
30 | }; | ||
31 | |||
19 | /* | 32 | /* |
20 | * Open file table structure | 33 | * Open file table structure |
21 | */ | 34 | */ |
22 | struct files_struct { | 35 | struct files_struct { |
23 | atomic_t count; | 36 | atomic_t count; |
24 | spinlock_t file_lock; /* Protects all the below members. Nests inside tsk->alloc_lock */ | 37 | spinlock_t file_lock; /* Protects all the below members. Nests inside tsk->alloc_lock */ |
25 | int max_fds; | 38 | struct fdtable *fdt; |
26 | int max_fdset; | 39 | struct fdtable fdtab; |
27 | int next_fd; | ||
28 | struct file ** fd; /* current fd array */ | ||
29 | fd_set *close_on_exec; | ||
30 | fd_set *open_fds; | ||
31 | fd_set close_on_exec_init; | 40 | fd_set close_on_exec_init; |
32 | fd_set open_fds_init; | 41 | fd_set open_fds_init; |
33 | struct file * fd_array[NR_OPEN_DEFAULT]; | 42 | struct file * fd_array[NR_OPEN_DEFAULT]; |
34 | }; | 43 | }; |
35 | 44 | ||
45 | #define files_fdtable(files) (rcu_dereference((files)->fdt)) | ||
46 | |||
36 | extern void FASTCALL(__fput(struct file *)); | 47 | extern void FASTCALL(__fput(struct file *)); |
37 | extern void FASTCALL(fput(struct file *)); | 48 | extern void FASTCALL(fput(struct file *)); |
38 | 49 | ||
@@ -59,13 +70,16 @@ extern fd_set *alloc_fdset(int); | |||
59 | extern void free_fdset(fd_set *, int); | 70 | extern void free_fdset(fd_set *, int); |
60 | 71 | ||
61 | extern int expand_files(struct files_struct *, int nr); | 72 | extern int expand_files(struct files_struct *, int nr); |
73 | extern void free_fdtable(struct fdtable *fdt); | ||
74 | extern void __init files_defer_init(void); | ||
62 | 75 | ||
63 | static inline struct file * fcheck_files(struct files_struct *files, unsigned int fd) | 76 | static inline struct file * fcheck_files(struct files_struct *files, unsigned int fd) |
64 | { | 77 | { |
65 | struct file * file = NULL; | 78 | struct file * file = NULL; |
79 | struct fdtable *fdt = files_fdtable(files); | ||
66 | 80 | ||
67 | if (fd < files->max_fds) | 81 | if (fd < fdt->max_fds) |
68 | file = files->fd[fd]; | 82 | file = rcu_dereference(fdt->fd[fd]); |
69 | return file; | 83 | return file; |
70 | } | 84 | } |
71 | 85 | ||
diff --git a/include/linux/fs.h b/include/linux/fs.h index fd93ab7da905..7f61227827d7 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
@@ -9,6 +9,7 @@ | |||
9 | #include <linux/config.h> | 9 | #include <linux/config.h> |
10 | #include <linux/limits.h> | 10 | #include <linux/limits.h> |
11 | #include <linux/ioctl.h> | 11 | #include <linux/ioctl.h> |
12 | #include <linux/rcuref.h> | ||
12 | 13 | ||
13 | /* | 14 | /* |
14 | * It's silly to have NR_OPEN bigger than NR_FILE, but you can change | 15 | * It's silly to have NR_OPEN bigger than NR_FILE, but you can change |
@@ -597,12 +598,13 @@ struct file { | |||
597 | spinlock_t f_ep_lock; | 598 | spinlock_t f_ep_lock; |
598 | #endif /* #ifdef CONFIG_EPOLL */ | 599 | #endif /* #ifdef CONFIG_EPOLL */ |
599 | struct address_space *f_mapping; | 600 | struct address_space *f_mapping; |
601 | struct rcu_head f_rcuhead; | ||
600 | }; | 602 | }; |
601 | extern spinlock_t files_lock; | 603 | extern spinlock_t files_lock; |
602 | #define file_list_lock() spin_lock(&files_lock); | 604 | #define file_list_lock() spin_lock(&files_lock); |
603 | #define file_list_unlock() spin_unlock(&files_lock); | 605 | #define file_list_unlock() spin_unlock(&files_lock); |
604 | 606 | ||
605 | #define get_file(x) atomic_inc(&(x)->f_count) | 607 | #define get_file(x) rcuref_inc(&(x)->f_count) |
606 | #define file_count(x) atomic_read(&(x)->f_count) | 608 | #define file_count(x) atomic_read(&(x)->f_count) |
607 | 609 | ||
608 | #define MAX_NON_LFS ((1UL<<31) - 1) | 610 | #define MAX_NON_LFS ((1UL<<31) - 1) |
diff --git a/include/linux/fuse.h b/include/linux/fuse.h new file mode 100644 index 000000000000..acbeb96a3353 --- /dev/null +++ b/include/linux/fuse.h | |||
@@ -0,0 +1,259 @@ | |||
1 | /* | ||
2 | FUSE: Filesystem in Userspace | ||
3 | Copyright (C) 2001-2005 Miklos Szeredi <miklos@szeredi.hu> | ||
4 | |||
5 | This program can be distributed under the terms of the GNU GPL. | ||
6 | See the file COPYING. | ||
7 | */ | ||
8 | |||
9 | /* This file defines the kernel interface of FUSE */ | ||
10 | |||
11 | #include <asm/types.h> | ||
12 | |||
13 | /** Version number of this interface */ | ||
14 | #define FUSE_KERNEL_VERSION 7 | ||
15 | |||
16 | /** Minor version number of this interface */ | ||
17 | #define FUSE_KERNEL_MINOR_VERSION 2 | ||
18 | |||
19 | /** The node ID of the root inode */ | ||
20 | #define FUSE_ROOT_ID 1 | ||
21 | |||
22 | /** The major number of the fuse character device */ | ||
23 | #define FUSE_MAJOR 10 | ||
24 | |||
25 | /** The minor number of the fuse character device */ | ||
26 | #define FUSE_MINOR 229 | ||
27 | |||
28 | /* Make sure all structures are padded to 64bit boundary, so 32bit | ||
29 | userspace works under 64bit kernels */ | ||
30 | |||
31 | struct fuse_attr { | ||
32 | __u64 ino; | ||
33 | __u64 size; | ||
34 | __u64 blocks; | ||
35 | __u64 atime; | ||
36 | __u64 mtime; | ||
37 | __u64 ctime; | ||
38 | __u32 atimensec; | ||
39 | __u32 mtimensec; | ||
40 | __u32 ctimensec; | ||
41 | __u32 mode; | ||
42 | __u32 nlink; | ||
43 | __u32 uid; | ||
44 | __u32 gid; | ||
45 | __u32 rdev; | ||
46 | }; | ||
47 | |||
48 | struct fuse_kstatfs { | ||
49 | __u64 blocks; | ||
50 | __u64 bfree; | ||
51 | __u64 bavail; | ||
52 | __u64 files; | ||
53 | __u64 ffree; | ||
54 | __u32 bsize; | ||
55 | __u32 namelen; | ||
56 | }; | ||
57 | |||
58 | #define FATTR_MODE (1 << 0) | ||
59 | #define FATTR_UID (1 << 1) | ||
60 | #define FATTR_GID (1 << 2) | ||
61 | #define FATTR_SIZE (1 << 3) | ||
62 | #define FATTR_ATIME (1 << 4) | ||
63 | #define FATTR_MTIME (1 << 5) | ||
64 | #define FATTR_CTIME (1 << 6) | ||
65 | |||
66 | /** | ||
67 | * Flags returned by the OPEN request | ||
68 | * | ||
69 | * FOPEN_DIRECT_IO: bypass page cache for this open file | ||
70 | * FOPEN_KEEP_CACHE: don't invalidate the data cache on open | ||
71 | */ | ||
72 | #define FOPEN_DIRECT_IO (1 << 0) | ||
73 | #define FOPEN_KEEP_CACHE (1 << 1) | ||
74 | |||
75 | enum fuse_opcode { | ||
76 | FUSE_LOOKUP = 1, | ||
77 | FUSE_FORGET = 2, /* no reply */ | ||
78 | FUSE_GETATTR = 3, | ||
79 | FUSE_SETATTR = 4, | ||
80 | FUSE_READLINK = 5, | ||
81 | FUSE_SYMLINK = 6, | ||
82 | FUSE_MKNOD = 8, | ||
83 | FUSE_MKDIR = 9, | ||
84 | FUSE_UNLINK = 10, | ||
85 | FUSE_RMDIR = 11, | ||
86 | FUSE_RENAME = 12, | ||
87 | FUSE_LINK = 13, | ||
88 | FUSE_OPEN = 14, | ||
89 | FUSE_READ = 15, | ||
90 | FUSE_WRITE = 16, | ||
91 | FUSE_STATFS = 17, | ||
92 | FUSE_RELEASE = 18, | ||
93 | FUSE_FSYNC = 20, | ||
94 | FUSE_SETXATTR = 21, | ||
95 | FUSE_GETXATTR = 22, | ||
96 | FUSE_LISTXATTR = 23, | ||
97 | FUSE_REMOVEXATTR = 24, | ||
98 | FUSE_FLUSH = 25, | ||
99 | FUSE_INIT = 26, | ||
100 | FUSE_OPENDIR = 27, | ||
101 | FUSE_READDIR = 28, | ||
102 | FUSE_RELEASEDIR = 29, | ||
103 | FUSE_FSYNCDIR = 30 | ||
104 | }; | ||
105 | |||
106 | /* Conservative buffer size for the client */ | ||
107 | #define FUSE_MAX_IN 8192 | ||
108 | |||
109 | #define FUSE_NAME_MAX 1024 | ||
110 | #define FUSE_SYMLINK_MAX 4096 | ||
111 | #define FUSE_XATTR_SIZE_MAX 4096 | ||
112 | |||
113 | struct fuse_entry_out { | ||
114 | __u64 nodeid; /* Inode ID */ | ||
115 | __u64 generation; /* Inode generation: nodeid:gen must | ||
116 | be unique for the fs's lifetime */ | ||
117 | __u64 entry_valid; /* Cache timeout for the name */ | ||
118 | __u64 attr_valid; /* Cache timeout for the attributes */ | ||
119 | __u32 entry_valid_nsec; | ||
120 | __u32 attr_valid_nsec; | ||
121 | struct fuse_attr attr; | ||
122 | }; | ||
123 | |||
124 | struct fuse_forget_in { | ||
125 | __u64 nlookup; | ||
126 | }; | ||
127 | |||
128 | struct fuse_attr_out { | ||
129 | __u64 attr_valid; /* Cache timeout for the attributes */ | ||
130 | __u32 attr_valid_nsec; | ||
131 | __u32 dummy; | ||
132 | struct fuse_attr attr; | ||
133 | }; | ||
134 | |||
135 | struct fuse_mknod_in { | ||
136 | __u32 mode; | ||
137 | __u32 rdev; | ||
138 | }; | ||
139 | |||
140 | struct fuse_mkdir_in { | ||
141 | __u32 mode; | ||
142 | __u32 padding; | ||
143 | }; | ||
144 | |||
145 | struct fuse_rename_in { | ||
146 | __u64 newdir; | ||
147 | }; | ||
148 | |||
149 | struct fuse_link_in { | ||
150 | __u64 oldnodeid; | ||
151 | }; | ||
152 | |||
153 | struct fuse_setattr_in { | ||
154 | __u32 valid; | ||
155 | __u32 padding; | ||
156 | struct fuse_attr attr; | ||
157 | }; | ||
158 | |||
159 | struct fuse_open_in { | ||
160 | __u32 flags; | ||
161 | __u32 padding; | ||
162 | }; | ||
163 | |||
164 | struct fuse_open_out { | ||
165 | __u64 fh; | ||
166 | __u32 open_flags; | ||
167 | __u32 padding; | ||
168 | }; | ||
169 | |||
170 | struct fuse_release_in { | ||
171 | __u64 fh; | ||
172 | __u32 flags; | ||
173 | __u32 padding; | ||
174 | }; | ||
175 | |||
176 | struct fuse_flush_in { | ||
177 | __u64 fh; | ||
178 | __u32 flush_flags; | ||
179 | __u32 padding; | ||
180 | }; | ||
181 | |||
182 | struct fuse_read_in { | ||
183 | __u64 fh; | ||
184 | __u64 offset; | ||
185 | __u32 size; | ||
186 | __u32 padding; | ||
187 | }; | ||
188 | |||
189 | struct fuse_write_in { | ||
190 | __u64 fh; | ||
191 | __u64 offset; | ||
192 | __u32 size; | ||
193 | __u32 write_flags; | ||
194 | }; | ||
195 | |||
196 | struct fuse_write_out { | ||
197 | __u32 size; | ||
198 | __u32 padding; | ||
199 | }; | ||
200 | |||
201 | struct fuse_statfs_out { | ||
202 | struct fuse_kstatfs st; | ||
203 | }; | ||
204 | |||
205 | struct fuse_fsync_in { | ||
206 | __u64 fh; | ||
207 | __u32 fsync_flags; | ||
208 | __u32 padding; | ||
209 | }; | ||
210 | |||
211 | struct fuse_setxattr_in { | ||
212 | __u32 size; | ||
213 | __u32 flags; | ||
214 | }; | ||
215 | |||
216 | struct fuse_getxattr_in { | ||
217 | __u32 size; | ||
218 | __u32 padding; | ||
219 | }; | ||
220 | |||
221 | struct fuse_getxattr_out { | ||
222 | __u32 size; | ||
223 | __u32 padding; | ||
224 | }; | ||
225 | |||
226 | struct fuse_init_in_out { | ||
227 | __u32 major; | ||
228 | __u32 minor; | ||
229 | }; | ||
230 | |||
231 | struct fuse_in_header { | ||
232 | __u32 len; | ||
233 | __u32 opcode; | ||
234 | __u64 unique; | ||
235 | __u64 nodeid; | ||
236 | __u32 uid; | ||
237 | __u32 gid; | ||
238 | __u32 pid; | ||
239 | __u32 padding; | ||
240 | }; | ||
241 | |||
242 | struct fuse_out_header { | ||
243 | __u32 len; | ||
244 | __s32 error; | ||
245 | __u64 unique; | ||
246 | }; | ||
247 | |||
248 | struct fuse_dirent { | ||
249 | __u64 ino; | ||
250 | __u64 off; | ||
251 | __u32 namelen; | ||
252 | __u32 type; | ||
253 | char name[0]; | ||
254 | }; | ||
255 | |||
256 | #define FUSE_NAME_OFFSET ((unsigned) ((struct fuse_dirent *) 0)->name) | ||
257 | #define FUSE_DIRENT_ALIGN(x) (((x) + sizeof(__u64) - 1) & ~(sizeof(__u64) - 1)) | ||
258 | #define FUSE_DIRENT_SIZE(d) \ | ||
259 | FUSE_DIRENT_ALIGN(FUSE_NAME_OFFSET + (d)->namelen) | ||
diff --git a/include/linux/init_task.h b/include/linux/init_task.h index c727c195a91a..68ab5f2ab9cd 100644 --- a/include/linux/init_task.h +++ b/include/linux/init_task.h | |||
@@ -2,17 +2,27 @@ | |||
2 | #define _LINUX__INIT_TASK_H | 2 | #define _LINUX__INIT_TASK_H |
3 | 3 | ||
4 | #include <linux/file.h> | 4 | #include <linux/file.h> |
5 | #include <linux/rcupdate.h> | ||
5 | 6 | ||
6 | #define INIT_FILES \ | 7 | #define INIT_FDTABLE \ |
7 | { \ | 8 | { \ |
8 | .count = ATOMIC_INIT(1), \ | ||
9 | .file_lock = SPIN_LOCK_UNLOCKED, \ | ||
10 | .max_fds = NR_OPEN_DEFAULT, \ | 9 | .max_fds = NR_OPEN_DEFAULT, \ |
11 | .max_fdset = __FD_SETSIZE, \ | 10 | .max_fdset = __FD_SETSIZE, \ |
12 | .next_fd = 0, \ | 11 | .next_fd = 0, \ |
13 | .fd = &init_files.fd_array[0], \ | 12 | .fd = &init_files.fd_array[0], \ |
14 | .close_on_exec = &init_files.close_on_exec_init, \ | 13 | .close_on_exec = &init_files.close_on_exec_init, \ |
15 | .open_fds = &init_files.open_fds_init, \ | 14 | .open_fds = &init_files.open_fds_init, \ |
15 | .rcu = RCU_HEAD_INIT, \ | ||
16 | .free_files = NULL, \ | ||
17 | .next = NULL, \ | ||
18 | } | ||
19 | |||
20 | #define INIT_FILES \ | ||
21 | { \ | ||
22 | .count = ATOMIC_INIT(1), \ | ||
23 | .file_lock = SPIN_LOCK_UNLOCKED, \ | ||
24 | .fdt = &init_files.fdtab, \ | ||
25 | .fdtab = INIT_FDTABLE, \ | ||
16 | .close_on_exec_init = { { 0, } }, \ | 26 | .close_on_exec_init = { { 0, } }, \ |
17 | .open_fds_init = { { 0, } }, \ | 27 | .open_fds_init = { { 0, } }, \ |
18 | .fd_array = { NULL, } \ | 28 | .fd_array = { NULL, } \ |
diff --git a/include/linux/pci.h b/include/linux/pci.h index 9c7aecf0c599..e5e24e13a114 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h | |||
@@ -329,6 +329,7 @@ extern struct pci_dev *pci_dev_get(struct pci_dev *dev); | |||
329 | extern void pci_dev_put(struct pci_dev *dev); | 329 | extern void pci_dev_put(struct pci_dev *dev); |
330 | extern void pci_remove_bus(struct pci_bus *b); | 330 | extern void pci_remove_bus(struct pci_bus *b); |
331 | extern void pci_remove_bus_device(struct pci_dev *dev); | 331 | extern void pci_remove_bus_device(struct pci_dev *dev); |
332 | void pci_setup_cardbus(struct pci_bus *bus); | ||
332 | 333 | ||
333 | /* Generic PCI functions exported to card drivers */ | 334 | /* Generic PCI functions exported to card drivers */ |
334 | 335 | ||
diff --git a/include/linux/rcupdate.h b/include/linux/rcupdate.h index fd276adf0fd5..4e65eb44adfd 100644 --- a/include/linux/rcupdate.h +++ b/include/linux/rcupdate.h | |||
@@ -52,8 +52,8 @@ struct rcu_head { | |||
52 | void (*func)(struct rcu_head *head); | 52 | void (*func)(struct rcu_head *head); |
53 | }; | 53 | }; |
54 | 54 | ||
55 | #define RCU_HEAD_INIT(head) { .next = NULL, .func = NULL } | 55 | #define RCU_HEAD_INIT { .next = NULL, .func = NULL } |
56 | #define RCU_HEAD(head) struct rcu_head head = RCU_HEAD_INIT(head) | 56 | #define RCU_HEAD(head) struct rcu_head head = RCU_HEAD_INIT |
57 | #define INIT_RCU_HEAD(ptr) do { \ | 57 | #define INIT_RCU_HEAD(ptr) do { \ |
58 | (ptr)->next = NULL; (ptr)->func = NULL; \ | 58 | (ptr)->next = NULL; (ptr)->func = NULL; \ |
59 | } while (0) | 59 | } while (0) |
diff --git a/include/linux/rcuref.h b/include/linux/rcuref.h new file mode 100644 index 000000000000..e1adbba14b67 --- /dev/null +++ b/include/linux/rcuref.h | |||
@@ -0,0 +1,220 @@ | |||
1 | /* | ||
2 | * rcuref.h | ||
3 | * | ||
4 | * Reference counting for elements of lists/arrays protected by | ||
5 | * RCU. | ||
6 | * | ||
7 | * This program is free software; you can redistribute it and/or modify | ||
8 | * it under the terms of the GNU General Public License as published by | ||
9 | * the Free Software Foundation; either version 2 of the License, or | ||
10 | * (at your option) any later version. | ||
11 | * | ||
12 | * This program is distributed in the hope that it will be useful, | ||
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
15 | * GNU General Public License for more details. | ||
16 | * | ||
17 | * You should have received a copy of the GNU General Public License | ||
18 | * along with this program; if not, write to the Free Software | ||
19 | * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | ||
20 | * | ||
21 | * Copyright (C) IBM Corporation, 2005 | ||
22 | * | ||
23 | * Author: Dipankar Sarma <dipankar@in.ibm.com> | ||
24 | * Ravikiran Thirumalai <kiran_th@gmail.com> | ||
25 | * | ||
26 | * See Documentation/RCU/rcuref.txt for detailed user guide. | ||
27 | * | ||
28 | */ | ||
29 | |||
30 | #ifndef _RCUREF_H_ | ||
31 | #define _RCUREF_H_ | ||
32 | |||
33 | #ifdef __KERNEL__ | ||
34 | |||
35 | #include <linux/types.h> | ||
36 | #include <linux/interrupt.h> | ||
37 | #include <linux/spinlock.h> | ||
38 | #include <asm/atomic.h> | ||
39 | |||
40 | /* | ||
41 | * These APIs work on traditional atomic_t counters used in the | ||
42 | * kernel for reference counting. Under special circumstances | ||
43 | * where a lock-free get() operation races with a put() operation | ||
44 | * these APIs can be used. See Documentation/RCU/rcuref.txt. | ||
45 | */ | ||
46 | |||
47 | #ifdef __HAVE_ARCH_CMPXCHG | ||
48 | |||
49 | /** | ||
50 | * rcuref_inc - increment refcount for object. | ||
51 | * @rcuref: reference counter in the object in question. | ||
52 | * | ||
53 | * This should be used only for objects where we use RCU and | ||
54 | * use the rcuref_inc_lf() api to acquire a reference | ||
55 | * in a lock-free reader-side critical section. | ||
56 | */ | ||
57 | static inline void rcuref_inc(atomic_t *rcuref) | ||
58 | { | ||
59 | atomic_inc(rcuref); | ||
60 | } | ||
61 | |||
62 | /** | ||
63 | * rcuref_dec - decrement refcount for object. | ||
64 | * @rcuref: reference counter in the object in question. | ||
65 | * | ||
66 | * This should be used only for objects where we use RCU and | ||
67 | * use the rcuref_inc_lf() api to acquire a reference | ||
68 | * in a lock-free reader-side critical section. | ||
69 | */ | ||
70 | static inline void rcuref_dec(atomic_t *rcuref) | ||
71 | { | ||
72 | atomic_dec(rcuref); | ||
73 | } | ||
74 | |||
75 | /** | ||
76 | * rcuref_dec_and_test - decrement refcount for object and test | ||
77 | * @rcuref: reference counter in the object. | ||
78 | * @release: pointer to the function that will clean up the object | ||
79 | * when the last reference to the object is released. | ||
80 | * This pointer is required. | ||
81 | * | ||
82 | * Decrement the refcount, and if 0, return 1. Else return 0. | ||
83 | * | ||
84 | * This should be used only for objects where we use RCU and | ||
85 | * use the rcuref_inc_lf() api to acquire a reference | ||
86 | * in a lock-free reader-side critical section. | ||
87 | */ | ||
88 | static inline int rcuref_dec_and_test(atomic_t *rcuref) | ||
89 | { | ||
90 | return atomic_dec_and_test(rcuref); | ||
91 | } | ||
92 | |||
93 | /* | ||
94 | * cmpxchg is needed on UP too, if deletions to the list/array can happen | ||
95 | * in interrupt context. | ||
96 | */ | ||
97 | |||
98 | /** | ||
99 | * rcuref_inc_lf - Take reference to an object in a read-side | ||
100 | * critical section protected by RCU. | ||
101 | * @rcuref: reference counter in the object in question. | ||
102 | * | ||
103 | * Try and increment the refcount by 1. The increment might fail if | ||
104 | * the reference counter has been through a 1 to 0 transition and | ||
105 | * is no longer part of the lock-free list. | ||
106 | * Returns non-zero on successful increment and zero otherwise. | ||
107 | */ | ||
108 | static inline int rcuref_inc_lf(atomic_t *rcuref) | ||
109 | { | ||
110 | int c, old; | ||
111 | c = atomic_read(rcuref); | ||
112 | while (c && (old = cmpxchg(&rcuref->counter, c, c + 1)) != c) | ||
113 | c = old; | ||
114 | return c; | ||
115 | } | ||
116 | |||
117 | #else /* !__HAVE_ARCH_CMPXCHG */ | ||
118 | |||
119 | extern spinlock_t __rcuref_hash[]; | ||
120 | |||
121 | /* | ||
122 | * Use a hash table of locks to protect the reference count | ||
123 | * since cmpxchg is not available in this arch. | ||
124 | */ | ||
125 | #ifdef CONFIG_SMP | ||
126 | #define RCUREF_HASH_SIZE 4 | ||
127 | #define RCUREF_HASH(k) \ | ||
128 | (&__rcuref_hash[(((unsigned long)k)>>8) & (RCUREF_HASH_SIZE-1)]) | ||
129 | #else | ||
130 | #define RCUREF_HASH_SIZE 1 | ||
131 | #define RCUREF_HASH(k) &__rcuref_hash[0] | ||
132 | #endif /* CONFIG_SMP */ | ||
133 | |||
134 | /** | ||
135 | * rcuref_inc - increment refcount for object. | ||
136 | * @rcuref: reference counter in the object in question. | ||
137 | * | ||
138 | * This should be used only for objects where we use RCU and | ||
139 | * use the rcuref_inc_lf() api to acquire a reference in a lock-free | ||
140 | * reader-side critical section. | ||
141 | */ | ||
142 | static inline void rcuref_inc(atomic_t *rcuref) | ||
143 | { | ||
144 | unsigned long flags; | ||
145 | spin_lock_irqsave(RCUREF_HASH(rcuref), flags); | ||
146 | rcuref->counter += 1; | ||
147 | spin_unlock_irqrestore(RCUREF_HASH(rcuref), flags); | ||
148 | } | ||
149 | |||
150 | /** | ||
151 | * rcuref_dec - decrement refcount for object. | ||
152 | * @rcuref: reference counter in the object in question. | ||
153 | * | ||
154 | * This should be used only for objects where we use RCU and | ||
155 | * use the rcuref_inc_lf() api to acquire a reference in a lock-free | ||
156 | * reader-side critical section. | ||
157 | */ | ||
158 | static inline void rcuref_dec(atomic_t *rcuref) | ||
159 | { | ||
160 | unsigned long flags; | ||
161 | spin_lock_irqsave(RCUREF_HASH(rcuref), flags); | ||
162 | rcuref->counter -= 1; | ||
163 | spin_unlock_irqrestore(RCUREF_HASH(rcuref), flags); | ||
164 | } | ||
165 | |||
166 | /** | ||
167 | * rcuref_dec_and_test - decrement refcount for object and test | ||
168 | * @rcuref: reference counter in the object. | ||
169 | * @release: pointer to the function that will clean up the object | ||
170 | * when the last reference to the object is released. | ||
171 | * This pointer is required. | ||
172 | * | ||
173 | * Decrement the refcount, and if 0, return 1. Else return 0. | ||
174 | * | ||
175 | * This should be used only for objects where we use RCU and | ||
176 | * use the rcuref_inc_lf() api to acquire a reference in a lock-free | ||
177 | * reader-side critical section. | ||
178 | */ | ||
179 | static inline int rcuref_dec_and_test(atomic_t *rcuref) | ||
180 | { | ||
181 | unsigned long flags; | ||
182 | spin_lock_irqsave(RCUREF_HASH(rcuref), flags); | ||
183 | rcuref->counter--; | ||
184 | if (!rcuref->counter) { | ||
185 | spin_unlock_irqrestore(RCUREF_HASH(rcuref), flags); | ||
186 | return 1; | ||
187 | } else { | ||
188 | spin_unlock_irqrestore(RCUREF_HASH(rcuref), flags); | ||
189 | return 0; | ||
190 | } | ||
191 | } | ||
192 | |||
193 | /** | ||
194 | * rcuref_inc_lf - Take reference to an object of a lock-free collection | ||
195 | * by traversing a lock-free list/array. | ||
196 | * @rcuref: reference counter in the object in question. | ||
197 | * | ||
198 | * Try and increment the refcount by 1. The increment might fail if | ||
199 | * the reference counter has been through a 1 to 0 transition and | ||
200 | * object is no longer part of the lock-free list. | ||
201 | * Returns non-zero on successful increment and zero otherwise. | ||
202 | */ | ||
203 | static inline int rcuref_inc_lf(atomic_t *rcuref) | ||
204 | { | ||
205 | int ret; | ||
206 | unsigned long flags; | ||
207 | spin_lock_irqsave(RCUREF_HASH(rcuref), flags); | ||
208 | if (rcuref->counter) | ||
209 | ret = rcuref->counter++; | ||
210 | else | ||
211 | ret = 0; | ||
212 | spin_unlock_irqrestore(RCUREF_HASH(rcuref), flags); | ||
213 | return ret; | ||
214 | } | ||
215 | |||
216 | |||
217 | #endif /* !__HAVE_ARCH_CMPXCHG */ | ||
218 | |||
219 | #endif /* __KERNEL__ */ | ||
220 | #endif /* _RCUREF_H_ */ | ||
diff --git a/include/linux/sched.h b/include/linux/sched.h index ea1b5f32ec5c..c551e6a1447e 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h | |||
@@ -604,6 +604,11 @@ extern int groups_search(struct group_info *group_info, gid_t grp); | |||
604 | #define GROUP_AT(gi, i) \ | 604 | #define GROUP_AT(gi, i) \ |
605 | ((gi)->blocks[(i)/NGROUPS_PER_BLOCK][(i)%NGROUPS_PER_BLOCK]) | 605 | ((gi)->blocks[(i)/NGROUPS_PER_BLOCK][(i)%NGROUPS_PER_BLOCK]) |
606 | 606 | ||
607 | #ifdef ARCH_HAS_PREFETCH_SWITCH_STACK | ||
608 | extern void prefetch_stack(struct task_struct*); | ||
609 | #else | ||
610 | static inline void prefetch_stack(struct task_struct *t) { } | ||
611 | #endif | ||
607 | 612 | ||
608 | struct audit_context; /* See audit.c */ | 613 | struct audit_context; /* See audit.c */ |
609 | struct mempolicy; | 614 | struct mempolicy; |
diff --git a/include/linux/security.h b/include/linux/security.h index 7aab6ab7c57f..55b02e1c73f4 100644 --- a/include/linux/security.h +++ b/include/linux/security.h | |||
@@ -250,29 +250,37 @@ struct swap_info_struct; | |||
250 | * @inode contains the inode structure. | 250 | * @inode contains the inode structure. |
251 | * Deallocate the inode security structure and set @inode->i_security to | 251 | * Deallocate the inode security structure and set @inode->i_security to |
252 | * NULL. | 252 | * NULL. |
253 | * @inode_init_security: | ||
254 | * Obtain the security attribute name suffix and value to set on a newly | ||
255 | * created inode and set up the incore security field for the new inode. | ||
256 | * This hook is called by the fs code as part of the inode creation | ||
257 | * transaction and provides for atomic labeling of the inode, unlike | ||
258 | * the post_create/mkdir/... hooks called by the VFS. The hook function | ||
259 | * is expected to allocate the name and value via kmalloc, with the caller | ||
260 | * being responsible for calling kfree after using them. | ||
261 | * If the security module does not use security attributes or does | ||
262 | * not wish to put a security attribute on this particular inode, | ||
263 | * then it should return -EOPNOTSUPP to skip this processing. | ||
264 | * @inode contains the inode structure of the newly created inode. | ||
265 | * @dir contains the inode structure of the parent directory. | ||
266 | * @name will be set to the allocated name suffix (e.g. selinux). | ||
267 | * @value will be set to the allocated attribute value. | ||
268 | * @len will be set to the length of the value. | ||
269 | * Returns 0 if @name and @value have been successfully set, | ||
270 | * -EOPNOTSUPP if no security attribute is needed, or | ||
271 | * -ENOMEM on memory allocation failure. | ||
253 | * @inode_create: | 272 | * @inode_create: |
254 | * Check permission to create a regular file. | 273 | * Check permission to create a regular file. |
255 | * @dir contains inode structure of the parent of the new file. | 274 | * @dir contains inode structure of the parent of the new file. |
256 | * @dentry contains the dentry structure for the file to be created. | 275 | * @dentry contains the dentry structure for the file to be created. |
257 | * @mode contains the file mode of the file to be created. | 276 | * @mode contains the file mode of the file to be created. |
258 | * Return 0 if permission is granted. | 277 | * Return 0 if permission is granted. |
259 | * @inode_post_create: | ||
260 | * Set the security attributes on a newly created regular file. This hook | ||
261 | * is called after a file has been successfully created. | ||
262 | * @dir contains the inode structure of the parent directory of the new file. | ||
263 | * @dentry contains the the dentry structure for the newly created file. | ||
264 | * @mode contains the file mode. | ||
265 | * @inode_link: | 278 | * @inode_link: |
266 | * Check permission before creating a new hard link to a file. | 279 | * Check permission before creating a new hard link to a file. |
267 | * @old_dentry contains the dentry structure for an existing link to the file. | 280 | * @old_dentry contains the dentry structure for an existing link to the file. |
268 | * @dir contains the inode structure of the parent directory of the new link. | 281 | * @dir contains the inode structure of the parent directory of the new link. |
269 | * @new_dentry contains the dentry structure for the new link. | 282 | * @new_dentry contains the dentry structure for the new link. |
270 | * Return 0 if permission is granted. | 283 | * Return 0 if permission is granted. |
271 | * @inode_post_link: | ||
272 | * Set security attributes for a new hard link to a file. | ||
273 | * @old_dentry contains the dentry structure for the existing link. | ||
274 | * @dir contains the inode structure of the parent directory of the new file. | ||
275 | * @new_dentry contains the dentry structure for the new file link. | ||
276 | * @inode_unlink: | 284 | * @inode_unlink: |
277 | * Check the permission to remove a hard link to a file. | 285 | * Check the permission to remove a hard link to a file. |
278 | * @dir contains the inode structure of parent directory of the file. | 286 | * @dir contains the inode structure of parent directory of the file. |
@@ -284,13 +292,6 @@ struct swap_info_struct; | |||
284 | * @dentry contains the dentry structure of the symbolic link. | 292 | * @dentry contains the dentry structure of the symbolic link. |
285 | * @old_name contains the pathname of file. | 293 | * @old_name contains the pathname of file. |
286 | * Return 0 if permission is granted. | 294 | * Return 0 if permission is granted. |
287 | * @inode_post_symlink: | ||
288 | * @dir contains the inode structure of the parent directory of the new link. | ||
289 | * @dentry contains the dentry structure of new symbolic link. | ||
290 | * @old_name contains the pathname of file. | ||
291 | * Set security attributes for a newly created symbolic link. Note that | ||
292 | * @dentry->d_inode may be NULL, since the filesystem might not | ||
293 | * instantiate the dentry (e.g. NFS). | ||
294 | * @inode_mkdir: | 295 | * @inode_mkdir: |
295 | * Check permissions to create a new directory in the existing directory | 296 | * Check permissions to create a new directory in the existing directory |
296 | * associated with inode strcture @dir. | 297 | * associated with inode strcture @dir. |
@@ -298,11 +299,6 @@ struct swap_info_struct; | |||
298 | * @dentry contains the dentry structure of new directory. | 299 | * @dentry contains the dentry structure of new directory. |
299 | * @mode contains the mode of new directory. | 300 | * @mode contains the mode of new directory. |
300 | * Return 0 if permission is granted. | 301 | * Return 0 if permission is granted. |
301 | * @inode_post_mkdir: | ||
302 | * Set security attributes on a newly created directory. | ||
303 | * @dir contains the inode structure of parent of the directory to be created. | ||
304 | * @dentry contains the dentry structure of new directory. | ||
305 | * @mode contains the mode of new directory. | ||
306 | * @inode_rmdir: | 302 | * @inode_rmdir: |
307 | * Check the permission to remove a directory. | 303 | * Check the permission to remove a directory. |
308 | * @dir contains the inode structure of parent of the directory to be removed. | 304 | * @dir contains the inode structure of parent of the directory to be removed. |
@@ -318,13 +314,6 @@ struct swap_info_struct; | |||
318 | * @mode contains the mode of the new file. | 314 | * @mode contains the mode of the new file. |
319 | * @dev contains the the device number. | 315 | * @dev contains the the device number. |
320 | * Return 0 if permission is granted. | 316 | * Return 0 if permission is granted. |
321 | * @inode_post_mknod: | ||
322 | * Set security attributes on a newly created special file (or socket or | ||
323 | * fifo file created via the mknod system call). | ||
324 | * @dir contains the inode structure of parent of the new node. | ||
325 | * @dentry contains the dentry structure of the new node. | ||
326 | * @mode contains the mode of the new node. | ||
327 | * @dev contains the the device number. | ||
328 | * @inode_rename: | 317 | * @inode_rename: |
329 | * Check for permission to rename a file or directory. | 318 | * Check for permission to rename a file or directory. |
330 | * @old_dir contains the inode structure for parent of the old link. | 319 | * @old_dir contains the inode structure for parent of the old link. |
@@ -332,12 +321,6 @@ struct swap_info_struct; | |||
332 | * @new_dir contains the inode structure for parent of the new link. | 321 | * @new_dir contains the inode structure for parent of the new link. |
333 | * @new_dentry contains the dentry structure of the new link. | 322 | * @new_dentry contains the dentry structure of the new link. |
334 | * Return 0 if permission is granted. | 323 | * Return 0 if permission is granted. |
335 | * @inode_post_rename: | ||
336 | * Set security attributes on a renamed file or directory. | ||
337 | * @old_dir contains the inode structure for parent of the old link. | ||
338 | * @old_dentry contains the dentry structure of the old link. | ||
339 | * @new_dir contains the inode structure for parent of the new link. | ||
340 | * @new_dentry contains the dentry structure of the new link. | ||
341 | * @inode_readlink: | 324 | * @inode_readlink: |
342 | * Check the permission to read the symbolic link. | 325 | * Check the permission to read the symbolic link. |
343 | * @dentry contains the dentry structure for the file link. | 326 | * @dentry contains the dentry structure for the file link. |
@@ -1080,34 +1063,21 @@ struct security_operations { | |||
1080 | 1063 | ||
1081 | int (*inode_alloc_security) (struct inode *inode); | 1064 | int (*inode_alloc_security) (struct inode *inode); |
1082 | void (*inode_free_security) (struct inode *inode); | 1065 | void (*inode_free_security) (struct inode *inode); |
1066 | int (*inode_init_security) (struct inode *inode, struct inode *dir, | ||
1067 | char **name, void **value, size_t *len); | ||
1083 | int (*inode_create) (struct inode *dir, | 1068 | int (*inode_create) (struct inode *dir, |
1084 | struct dentry *dentry, int mode); | 1069 | struct dentry *dentry, int mode); |
1085 | void (*inode_post_create) (struct inode *dir, | ||
1086 | struct dentry *dentry, int mode); | ||
1087 | int (*inode_link) (struct dentry *old_dentry, | 1070 | int (*inode_link) (struct dentry *old_dentry, |
1088 | struct inode *dir, struct dentry *new_dentry); | 1071 | struct inode *dir, struct dentry *new_dentry); |
1089 | void (*inode_post_link) (struct dentry *old_dentry, | ||
1090 | struct inode *dir, struct dentry *new_dentry); | ||
1091 | int (*inode_unlink) (struct inode *dir, struct dentry *dentry); | 1072 | int (*inode_unlink) (struct inode *dir, struct dentry *dentry); |
1092 | int (*inode_symlink) (struct inode *dir, | 1073 | int (*inode_symlink) (struct inode *dir, |
1093 | struct dentry *dentry, const char *old_name); | 1074 | struct dentry *dentry, const char *old_name); |
1094 | void (*inode_post_symlink) (struct inode *dir, | ||
1095 | struct dentry *dentry, | ||
1096 | const char *old_name); | ||
1097 | int (*inode_mkdir) (struct inode *dir, struct dentry *dentry, int mode); | 1075 | int (*inode_mkdir) (struct inode *dir, struct dentry *dentry, int mode); |
1098 | void (*inode_post_mkdir) (struct inode *dir, struct dentry *dentry, | ||
1099 | int mode); | ||
1100 | int (*inode_rmdir) (struct inode *dir, struct dentry *dentry); | 1076 | int (*inode_rmdir) (struct inode *dir, struct dentry *dentry); |
1101 | int (*inode_mknod) (struct inode *dir, struct dentry *dentry, | 1077 | int (*inode_mknod) (struct inode *dir, struct dentry *dentry, |
1102 | int mode, dev_t dev); | 1078 | int mode, dev_t dev); |
1103 | void (*inode_post_mknod) (struct inode *dir, struct dentry *dentry, | ||
1104 | int mode, dev_t dev); | ||
1105 | int (*inode_rename) (struct inode *old_dir, struct dentry *old_dentry, | 1079 | int (*inode_rename) (struct inode *old_dir, struct dentry *old_dentry, |
1106 | struct inode *new_dir, struct dentry *new_dentry); | 1080 | struct inode *new_dir, struct dentry *new_dentry); |
1107 | void (*inode_post_rename) (struct inode *old_dir, | ||
1108 | struct dentry *old_dentry, | ||
1109 | struct inode *new_dir, | ||
1110 | struct dentry *new_dentry); | ||
1111 | int (*inode_readlink) (struct dentry *dentry); | 1081 | int (*inode_readlink) (struct dentry *dentry); |
1112 | int (*inode_follow_link) (struct dentry *dentry, struct nameidata *nd); | 1082 | int (*inode_follow_link) (struct dentry *dentry, struct nameidata *nd); |
1113 | int (*inode_permission) (struct inode *inode, int mask, struct nameidata *nd); | 1083 | int (*inode_permission) (struct inode *inode, int mask, struct nameidata *nd); |
@@ -1442,6 +1412,17 @@ static inline void security_inode_free (struct inode *inode) | |||
1442 | return; | 1412 | return; |
1443 | security_ops->inode_free_security (inode); | 1413 | security_ops->inode_free_security (inode); |
1444 | } | 1414 | } |
1415 | |||
1416 | static inline int security_inode_init_security (struct inode *inode, | ||
1417 | struct inode *dir, | ||
1418 | char **name, | ||
1419 | void **value, | ||
1420 | size_t *len) | ||
1421 | { | ||
1422 | if (unlikely (IS_PRIVATE (inode))) | ||
1423 | return -EOPNOTSUPP; | ||
1424 | return security_ops->inode_init_security (inode, dir, name, value, len); | ||
1425 | } | ||
1445 | 1426 | ||
1446 | static inline int security_inode_create (struct inode *dir, | 1427 | static inline int security_inode_create (struct inode *dir, |
1447 | struct dentry *dentry, | 1428 | struct dentry *dentry, |
@@ -1452,15 +1433,6 @@ static inline int security_inode_create (struct inode *dir, | |||
1452 | return security_ops->inode_create (dir, dentry, mode); | 1433 | return security_ops->inode_create (dir, dentry, mode); |
1453 | } | 1434 | } |
1454 | 1435 | ||
1455 | static inline void security_inode_post_create (struct inode *dir, | ||
1456 | struct dentry *dentry, | ||
1457 | int mode) | ||
1458 | { | ||
1459 | if (dentry->d_inode && unlikely (IS_PRIVATE (dentry->d_inode))) | ||
1460 | return; | ||
1461 | security_ops->inode_post_create (dir, dentry, mode); | ||
1462 | } | ||
1463 | |||
1464 | static inline int security_inode_link (struct dentry *old_dentry, | 1436 | static inline int security_inode_link (struct dentry *old_dentry, |
1465 | struct inode *dir, | 1437 | struct inode *dir, |
1466 | struct dentry *new_dentry) | 1438 | struct dentry *new_dentry) |
@@ -1470,15 +1442,6 @@ static inline int security_inode_link (struct dentry *old_dentry, | |||
1470 | return security_ops->inode_link (old_dentry, dir, new_dentry); | 1442 | return security_ops->inode_link (old_dentry, dir, new_dentry); |
1471 | } | 1443 | } |
1472 | 1444 | ||
1473 | static inline void security_inode_post_link (struct dentry *old_dentry, | ||
1474 | struct inode *dir, | ||
1475 | struct dentry *new_dentry) | ||
1476 | { | ||
1477 | if (new_dentry->d_inode && unlikely (IS_PRIVATE (new_dentry->d_inode))) | ||
1478 | return; | ||
1479 | security_ops->inode_post_link (old_dentry, dir, new_dentry); | ||
1480 | } | ||
1481 | |||
1482 | static inline int security_inode_unlink (struct inode *dir, | 1445 | static inline int security_inode_unlink (struct inode *dir, |
1483 | struct dentry *dentry) | 1446 | struct dentry *dentry) |
1484 | { | 1447 | { |
@@ -1496,15 +1459,6 @@ static inline int security_inode_symlink (struct inode *dir, | |||
1496 | return security_ops->inode_symlink (dir, dentry, old_name); | 1459 | return security_ops->inode_symlink (dir, dentry, old_name); |
1497 | } | 1460 | } |
1498 | 1461 | ||
1499 | static inline void security_inode_post_symlink (struct inode *dir, | ||
1500 | struct dentry *dentry, | ||
1501 | const char *old_name) | ||
1502 | { | ||
1503 | if (dentry->d_inode && unlikely (IS_PRIVATE (dentry->d_inode))) | ||
1504 | return; | ||
1505 | security_ops->inode_post_symlink (dir, dentry, old_name); | ||
1506 | } | ||
1507 | |||
1508 | static inline int security_inode_mkdir (struct inode *dir, | 1462 | static inline int security_inode_mkdir (struct inode *dir, |
1509 | struct dentry *dentry, | 1463 | struct dentry *dentry, |
1510 | int mode) | 1464 | int mode) |
@@ -1514,15 +1468,6 @@ static inline int security_inode_mkdir (struct inode *dir, | |||
1514 | return security_ops->inode_mkdir (dir, dentry, mode); | 1468 | return security_ops->inode_mkdir (dir, dentry, mode); |
1515 | } | 1469 | } |
1516 | 1470 | ||
1517 | static inline void security_inode_post_mkdir (struct inode *dir, | ||
1518 | struct dentry *dentry, | ||
1519 | int mode) | ||
1520 | { | ||
1521 | if (dentry->d_inode && unlikely (IS_PRIVATE (dentry->d_inode))) | ||
1522 | return; | ||
1523 | security_ops->inode_post_mkdir (dir, dentry, mode); | ||
1524 | } | ||
1525 | |||
1526 | static inline int security_inode_rmdir (struct inode *dir, | 1471 | static inline int security_inode_rmdir (struct inode *dir, |
1527 | struct dentry *dentry) | 1472 | struct dentry *dentry) |
1528 | { | 1473 | { |
@@ -1540,15 +1485,6 @@ static inline int security_inode_mknod (struct inode *dir, | |||
1540 | return security_ops->inode_mknod (dir, dentry, mode, dev); | 1485 | return security_ops->inode_mknod (dir, dentry, mode, dev); |
1541 | } | 1486 | } |
1542 | 1487 | ||
1543 | static inline void security_inode_post_mknod (struct inode *dir, | ||
1544 | struct dentry *dentry, | ||
1545 | int mode, dev_t dev) | ||
1546 | { | ||
1547 | if (dentry->d_inode && unlikely (IS_PRIVATE (dentry->d_inode))) | ||
1548 | return; | ||
1549 | security_ops->inode_post_mknod (dir, dentry, mode, dev); | ||
1550 | } | ||
1551 | |||
1552 | static inline int security_inode_rename (struct inode *old_dir, | 1488 | static inline int security_inode_rename (struct inode *old_dir, |
1553 | struct dentry *old_dentry, | 1489 | struct dentry *old_dentry, |
1554 | struct inode *new_dir, | 1490 | struct inode *new_dir, |
@@ -1561,18 +1497,6 @@ static inline int security_inode_rename (struct inode *old_dir, | |||
1561 | new_dir, new_dentry); | 1497 | new_dir, new_dentry); |
1562 | } | 1498 | } |
1563 | 1499 | ||
1564 | static inline void security_inode_post_rename (struct inode *old_dir, | ||
1565 | struct dentry *old_dentry, | ||
1566 | struct inode *new_dir, | ||
1567 | struct dentry *new_dentry) | ||
1568 | { | ||
1569 | if (unlikely (IS_PRIVATE (old_dentry->d_inode) || | ||
1570 | (new_dentry->d_inode && IS_PRIVATE (new_dentry->d_inode)))) | ||
1571 | return; | ||
1572 | security_ops->inode_post_rename (old_dir, old_dentry, | ||
1573 | new_dir, new_dentry); | ||
1574 | } | ||
1575 | |||
1576 | static inline int security_inode_readlink (struct dentry *dentry) | 1500 | static inline int security_inode_readlink (struct dentry *dentry) |
1577 | { | 1501 | { |
1578 | if (unlikely (IS_PRIVATE (dentry->d_inode))) | 1502 | if (unlikely (IS_PRIVATE (dentry->d_inode))) |
@@ -2171,6 +2095,15 @@ static inline int security_inode_alloc (struct inode *inode) | |||
2171 | 2095 | ||
2172 | static inline void security_inode_free (struct inode *inode) | 2096 | static inline void security_inode_free (struct inode *inode) |
2173 | { } | 2097 | { } |
2098 | |||
2099 | static inline int security_inode_init_security (struct inode *inode, | ||
2100 | struct inode *dir, | ||
2101 | char **name, | ||
2102 | void **value, | ||
2103 | size_t *len) | ||
2104 | { | ||
2105 | return -EOPNOTSUPP; | ||
2106 | } | ||
2174 | 2107 | ||
2175 | static inline int security_inode_create (struct inode *dir, | 2108 | static inline int security_inode_create (struct inode *dir, |
2176 | struct dentry *dentry, | 2109 | struct dentry *dentry, |
@@ -2179,11 +2112,6 @@ static inline int security_inode_create (struct inode *dir, | |||
2179 | return 0; | 2112 | return 0; |
2180 | } | 2113 | } |
2181 | 2114 | ||
2182 | static inline void security_inode_post_create (struct inode *dir, | ||
2183 | struct dentry *dentry, | ||
2184 | int mode) | ||
2185 | { } | ||
2186 | |||
2187 | static inline int security_inode_link (struct dentry *old_dentry, | 2115 | static inline int security_inode_link (struct dentry *old_dentry, |
2188 | struct inode *dir, | 2116 | struct inode *dir, |
2189 | struct dentry *new_dentry) | 2117 | struct dentry *new_dentry) |
@@ -2191,11 +2119,6 @@ static inline int security_inode_link (struct dentry *old_dentry, | |||
2191 | return 0; | 2119 | return 0; |
2192 | } | 2120 | } |
2193 | 2121 | ||
2194 | static inline void security_inode_post_link (struct dentry *old_dentry, | ||
2195 | struct inode *dir, | ||
2196 | struct dentry *new_dentry) | ||
2197 | { } | ||
2198 | |||
2199 | static inline int security_inode_unlink (struct inode *dir, | 2122 | static inline int security_inode_unlink (struct inode *dir, |
2200 | struct dentry *dentry) | 2123 | struct dentry *dentry) |
2201 | { | 2124 | { |
@@ -2209,11 +2132,6 @@ static inline int security_inode_symlink (struct inode *dir, | |||
2209 | return 0; | 2132 | return 0; |
2210 | } | 2133 | } |
2211 | 2134 | ||
2212 | static inline void security_inode_post_symlink (struct inode *dir, | ||
2213 | struct dentry *dentry, | ||
2214 | const char *old_name) | ||
2215 | { } | ||
2216 | |||
2217 | static inline int security_inode_mkdir (struct inode *dir, | 2135 | static inline int security_inode_mkdir (struct inode *dir, |
2218 | struct dentry *dentry, | 2136 | struct dentry *dentry, |
2219 | int mode) | 2137 | int mode) |
@@ -2221,11 +2139,6 @@ static inline int security_inode_mkdir (struct inode *dir, | |||
2221 | return 0; | 2139 | return 0; |
2222 | } | 2140 | } |
2223 | 2141 | ||
2224 | static inline void security_inode_post_mkdir (struct inode *dir, | ||
2225 | struct dentry *dentry, | ||
2226 | int mode) | ||
2227 | { } | ||
2228 | |||
2229 | static inline int security_inode_rmdir (struct inode *dir, | 2142 | static inline int security_inode_rmdir (struct inode *dir, |
2230 | struct dentry *dentry) | 2143 | struct dentry *dentry) |
2231 | { | 2144 | { |
@@ -2239,11 +2152,6 @@ static inline int security_inode_mknod (struct inode *dir, | |||
2239 | return 0; | 2152 | return 0; |
2240 | } | 2153 | } |
2241 | 2154 | ||
2242 | static inline void security_inode_post_mknod (struct inode *dir, | ||
2243 | struct dentry *dentry, | ||
2244 | int mode, dev_t dev) | ||
2245 | { } | ||
2246 | |||
2247 | static inline int security_inode_rename (struct inode *old_dir, | 2155 | static inline int security_inode_rename (struct inode *old_dir, |
2248 | struct dentry *old_dentry, | 2156 | struct dentry *old_dentry, |
2249 | struct inode *new_dir, | 2157 | struct inode *new_dir, |
@@ -2252,12 +2160,6 @@ static inline int security_inode_rename (struct inode *old_dir, | |||
2252 | return 0; | 2160 | return 0; |
2253 | } | 2161 | } |
2254 | 2162 | ||
2255 | static inline void security_inode_post_rename (struct inode *old_dir, | ||
2256 | struct dentry *old_dentry, | ||
2257 | struct inode *new_dir, | ||
2258 | struct dentry *new_dentry) | ||
2259 | { } | ||
2260 | |||
2261 | static inline int security_inode_readlink (struct dentry *dentry) | 2163 | static inline int security_inode_readlink (struct dentry *dentry) |
2262 | { | 2164 | { |
2263 | return 0; | 2165 | return 0; |
diff --git a/include/linux/timer.h b/include/linux/timer.h index 221f81ac2002..3340f3bd135d 100644 --- a/include/linux/timer.h +++ b/include/linux/timer.h | |||
@@ -32,6 +32,10 @@ extern struct timer_base_s __init_timer_base; | |||
32 | .magic = TIMER_MAGIC, \ | 32 | .magic = TIMER_MAGIC, \ |
33 | } | 33 | } |
34 | 34 | ||
35 | #define DEFINE_TIMER(_name, _function, _expires, _data) \ | ||
36 | struct timer_list _name = \ | ||
37 | TIMER_INITIALIZER(_function, _expires, _data) | ||
38 | |||
35 | void fastcall init_timer(struct timer_list * timer); | 39 | void fastcall init_timer(struct timer_list * timer); |
36 | 40 | ||
37 | /*** | 41 | /*** |
diff --git a/include/linux/tty.h b/include/linux/tty.h index 59ff42c629ec..1267f88ece6e 100644 --- a/include/linux/tty.h +++ b/include/linux/tty.h | |||
@@ -74,7 +74,8 @@ struct screen_info { | |||
74 | u16 vesapm_off; /* 0x30 */ | 74 | u16 vesapm_off; /* 0x30 */ |
75 | u16 pages; /* 0x32 */ | 75 | u16 pages; /* 0x32 */ |
76 | u16 vesa_attributes; /* 0x34 */ | 76 | u16 vesa_attributes; /* 0x34 */ |
77 | /* 0x36 -- 0x3f reserved for future expansion */ | 77 | u32 capabilities; /* 0x36 */ |
78 | /* 0x3a -- 0x3f reserved for future expansion */ | ||
78 | }; | 79 | }; |
79 | 80 | ||
80 | extern struct screen_info screen_info; | 81 | extern struct screen_info screen_info; |
diff --git a/include/linux/videodev.h b/include/linux/videodev.h index 9d6fbde3d29c..1cc8c31b7988 100644 --- a/include/linux/videodev.h +++ b/include/linux/videodev.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #include <linux/compiler.h> | 4 | #include <linux/compiler.h> |
5 | #include <linux/types.h> | 5 | #include <linux/types.h> |
6 | #include <linux/version.h> | ||
7 | 6 | ||
8 | #define HAVE_V4L2 1 | 7 | #define HAVE_V4L2 1 |
9 | #include <linux/videodev2.h> | 8 | #include <linux/videodev2.h> |
@@ -29,7 +28,6 @@ struct video_device | |||
29 | void (*release)(struct video_device *vfd); | 28 | void (*release)(struct video_device *vfd); |
30 | 29 | ||
31 | 30 | ||
32 | #if 1 /* to be removed in 2.7.x */ | ||
33 | /* obsolete -- fops->owner is used instead */ | 31 | /* obsolete -- fops->owner is used instead */ |
34 | struct module *owner; | 32 | struct module *owner; |
35 | /* dev->driver_data will be used instead some day. | 33 | /* dev->driver_data will be used instead some day. |
@@ -37,7 +35,6 @@ struct video_device | |||
37 | * so the switch over will be transparent for you. | 35 | * so the switch over will be transparent for you. |
38 | * Or use {pci|usb}_{get|set}_drvdata() directly. */ | 36 | * Or use {pci|usb}_{get|set}_drvdata() directly. */ |
39 | void *priv; | 37 | void *priv; |
40 | #endif | ||
41 | 38 | ||
42 | /* for videodev.c intenal usage -- please don't touch */ | 39 | /* for videodev.c intenal usage -- please don't touch */ |
43 | int users; /* video_exclusive_{open|close} ... */ | 40 | int users; /* video_exclusive_{open|close} ... */ |
diff --git a/include/linux/videodev2.h b/include/linux/videodev2.h index acbfc525576d..f623a33b9abe 100644 --- a/include/linux/videodev2.h +++ b/include/linux/videodev2.h | |||
@@ -270,7 +270,6 @@ struct v4l2_timecode | |||
270 | /* The above is based on SMPTE timecodes */ | 270 | /* The above is based on SMPTE timecodes */ |
271 | 271 | ||
272 | 272 | ||
273 | #if 1 | ||
274 | /* | 273 | /* |
275 | * M P E G C O M P R E S S I O N P A R A M E T E R S | 274 | * M P E G C O M P R E S S I O N P A R A M E T E R S |
276 | * | 275 | * |
@@ -357,7 +356,6 @@ struct v4l2_mpeg_compression { | |||
357 | /* I don't expect the above being perfect yet ;) */ | 356 | /* I don't expect the above being perfect yet ;) */ |
358 | __u32 reserved_5[8]; | 357 | __u32 reserved_5[8]; |
359 | }; | 358 | }; |
360 | #endif | ||
361 | 359 | ||
362 | struct v4l2_jpegcompression | 360 | struct v4l2_jpegcompression |
363 | { | 361 | { |
@@ -871,10 +869,8 @@ struct v4l2_streamparm | |||
871 | #define VIDIOC_ENUM_FMT _IOWR ('V', 2, struct v4l2_fmtdesc) | 869 | #define VIDIOC_ENUM_FMT _IOWR ('V', 2, struct v4l2_fmtdesc) |
872 | #define VIDIOC_G_FMT _IOWR ('V', 4, struct v4l2_format) | 870 | #define VIDIOC_G_FMT _IOWR ('V', 4, struct v4l2_format) |
873 | #define VIDIOC_S_FMT _IOWR ('V', 5, struct v4l2_format) | 871 | #define VIDIOC_S_FMT _IOWR ('V', 5, struct v4l2_format) |
874 | #if 1 /* experimental */ | ||
875 | #define VIDIOC_G_MPEGCOMP _IOR ('V', 6, struct v4l2_mpeg_compression) | 872 | #define VIDIOC_G_MPEGCOMP _IOR ('V', 6, struct v4l2_mpeg_compression) |
876 | #define VIDIOC_S_MPEGCOMP _IOW ('V', 7, struct v4l2_mpeg_compression) | 873 | #define VIDIOC_S_MPEGCOMP _IOW ('V', 7, struct v4l2_mpeg_compression) |
877 | #endif | ||
878 | #define VIDIOC_REQBUFS _IOWR ('V', 8, struct v4l2_requestbuffers) | 874 | #define VIDIOC_REQBUFS _IOWR ('V', 8, struct v4l2_requestbuffers) |
879 | #define VIDIOC_QUERYBUF _IOWR ('V', 9, struct v4l2_buffer) | 875 | #define VIDIOC_QUERYBUF _IOWR ('V', 9, struct v4l2_buffer) |
880 | #define VIDIOC_G_FBUF _IOR ('V', 10, struct v4l2_framebuffer) | 876 | #define VIDIOC_G_FBUF _IOR ('V', 10, struct v4l2_framebuffer) |