diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/fs.h | 2 | ||||
-rw-r--r-- | include/linux/lockd/lockd.h | 2 | ||||
-rw-r--r-- | include/linux/moduleparam.h | 2 | ||||
-rw-r--r-- | include/linux/nfs_fs.h | 65 | ||||
-rw-r--r-- | include/linux/nfs_idmap.h | 2 | ||||
-rw-r--r-- | include/linux/nfs_page.h | 12 | ||||
-rw-r--r-- | include/linux/nfs_xdr.h | 89 | ||||
-rw-r--r-- | include/linux/sunrpc/clnt.h | 5 | ||||
-rw-r--r-- | include/linux/sunrpc/gss_spkm3.h | 2 | ||||
-rw-r--r-- | include/linux/sunrpc/sched.h | 48 | ||||
-rw-r--r-- | include/linux/sunrpc/xdr.h | 6 | ||||
-rw-r--r-- | include/linux/sunrpc/xprt.h | 12 | ||||
-rw-r--r-- | include/linux/writeback.h | 9 | ||||
-rw-r--r-- | include/media/saa7146.h | 6 |
14 files changed, 165 insertions, 97 deletions
diff --git a/include/linux/fs.h b/include/linux/fs.h index 115e72be25d0..2c9c48d65630 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
@@ -760,7 +760,7 @@ extern struct file_lock *posix_test_lock(struct file *, struct file_lock *); | |||
760 | extern int posix_lock_file(struct file *, struct file_lock *); | 760 | extern int posix_lock_file(struct file *, struct file_lock *); |
761 | extern int posix_lock_file_wait(struct file *, struct file_lock *); | 761 | extern int posix_lock_file_wait(struct file *, struct file_lock *); |
762 | extern void posix_block_lock(struct file_lock *, struct file_lock *); | 762 | extern void posix_block_lock(struct file_lock *, struct file_lock *); |
763 | extern void posix_unblock_lock(struct file *, struct file_lock *); | 763 | extern int posix_unblock_lock(struct file *, struct file_lock *); |
764 | extern int posix_locks_deadlock(struct file_lock *, struct file_lock *); | 764 | extern int posix_locks_deadlock(struct file_lock *, struct file_lock *); |
765 | extern int flock_lock_file_wait(struct file *filp, struct file_lock *fl); | 765 | extern int flock_lock_file_wait(struct file *filp, struct file_lock *fl); |
766 | extern int __break_lease(struct inode *inode, unsigned int flags); | 766 | extern int __break_lease(struct inode *inode, unsigned int flags); |
diff --git a/include/linux/lockd/lockd.h b/include/linux/lockd/lockd.h index 16d4e5a08e1d..95c8fea293ba 100644 --- a/include/linux/lockd/lockd.h +++ b/include/linux/lockd/lockd.h | |||
@@ -172,7 +172,7 @@ extern struct nlm_host *nlm_find_client(void); | |||
172 | /* | 172 | /* |
173 | * Server-side lock handling | 173 | * Server-side lock handling |
174 | */ | 174 | */ |
175 | int nlmsvc_async_call(struct nlm_rqst *, u32, rpc_action); | 175 | int nlmsvc_async_call(struct nlm_rqst *, u32, const struct rpc_call_ops *); |
176 | u32 nlmsvc_lock(struct svc_rqst *, struct nlm_file *, | 176 | u32 nlmsvc_lock(struct svc_rqst *, struct nlm_file *, |
177 | struct nlm_lock *, int, struct nlm_cookie *); | 177 | struct nlm_lock *, int, struct nlm_cookie *); |
178 | u32 nlmsvc_unlock(struct nlm_file *, struct nlm_lock *); | 178 | u32 nlmsvc_unlock(struct nlm_file *, struct nlm_lock *); |
diff --git a/include/linux/moduleparam.h b/include/linux/moduleparam.h index 368ec8e45bd0..b5c98c43779e 100644 --- a/include/linux/moduleparam.h +++ b/include/linux/moduleparam.h | |||
@@ -10,7 +10,7 @@ | |||
10 | #ifdef MODULE | 10 | #ifdef MODULE |
11 | #define MODULE_PARAM_PREFIX /* empty */ | 11 | #define MODULE_PARAM_PREFIX /* empty */ |
12 | #else | 12 | #else |
13 | #define MODULE_PARAM_PREFIX __stringify(KBUILD_MODNAME) "." | 13 | #define MODULE_PARAM_PREFIX KBUILD_MODNAME "." |
14 | #endif | 14 | #endif |
15 | 15 | ||
16 | #ifdef MODULE | 16 | #ifdef MODULE |
diff --git a/include/linux/nfs_fs.h b/include/linux/nfs_fs.h index 2516adeccecf..547d649b274e 100644 --- a/include/linux/nfs_fs.h +++ b/include/linux/nfs_fs.h | |||
@@ -38,9 +38,6 @@ | |||
38 | # define NFS_DEBUG | 38 | # define NFS_DEBUG |
39 | #endif | 39 | #endif |
40 | 40 | ||
41 | #define NFS_MAX_FILE_IO_BUFFER_SIZE 32768 | ||
42 | #define NFS_DEF_FILE_IO_BUFFER_SIZE 4096 | ||
43 | |||
44 | /* Default timeout values */ | 41 | /* Default timeout values */ |
45 | #define NFS_MAX_UDP_TIMEOUT (60*HZ) | 42 | #define NFS_MAX_UDP_TIMEOUT (60*HZ) |
46 | #define NFS_MAX_TCP_TIMEOUT (600*HZ) | 43 | #define NFS_MAX_TCP_TIMEOUT (600*HZ) |
@@ -65,6 +62,7 @@ | |||
65 | #define FLUSH_STABLE 4 /* commit to stable storage */ | 62 | #define FLUSH_STABLE 4 /* commit to stable storage */ |
66 | #define FLUSH_LOWPRI 8 /* low priority background flush */ | 63 | #define FLUSH_LOWPRI 8 /* low priority background flush */ |
67 | #define FLUSH_HIGHPRI 16 /* high priority memory reclaim flush */ | 64 | #define FLUSH_HIGHPRI 16 /* high priority memory reclaim flush */ |
65 | #define FLUSH_NOCOMMIT 32 /* Don't send the NFSv3/v4 COMMIT */ | ||
68 | 66 | ||
69 | #ifdef __KERNEL__ | 67 | #ifdef __KERNEL__ |
70 | 68 | ||
@@ -394,6 +392,17 @@ extern int nfs_instantiate(struct dentry *dentry, struct nfs_fh *fh, struct nfs_ | |||
394 | extern struct inode_operations nfs_symlink_inode_operations; | 392 | extern struct inode_operations nfs_symlink_inode_operations; |
395 | 393 | ||
396 | /* | 394 | /* |
395 | * linux/fs/nfs/sysctl.c | ||
396 | */ | ||
397 | #ifdef CONFIG_SYSCTL | ||
398 | extern int nfs_register_sysctl(void); | ||
399 | extern void nfs_unregister_sysctl(void); | ||
400 | #else | ||
401 | #define nfs_register_sysctl() do { } while(0) | ||
402 | #define nfs_unregister_sysctl() do { } while(0) | ||
403 | #endif | ||
404 | |||
405 | /* | ||
397 | * linux/fs/nfs/unlink.c | 406 | * linux/fs/nfs/unlink.c |
398 | */ | 407 | */ |
399 | extern int nfs_async_unlink(struct dentry *); | 408 | extern int nfs_async_unlink(struct dentry *); |
@@ -406,10 +415,12 @@ extern int nfs_writepage(struct page *page, struct writeback_control *wbc); | |||
406 | extern int nfs_writepages(struct address_space *, struct writeback_control *); | 415 | extern int nfs_writepages(struct address_space *, struct writeback_control *); |
407 | extern int nfs_flush_incompatible(struct file *file, struct page *page); | 416 | extern int nfs_flush_incompatible(struct file *file, struct page *page); |
408 | extern int nfs_updatepage(struct file *, struct page *, unsigned int, unsigned int); | 417 | extern int nfs_updatepage(struct file *, struct page *, unsigned int, unsigned int); |
409 | extern void nfs_writeback_done(struct rpc_task *task); | 418 | extern void nfs_writeback_done(struct rpc_task *task, void *data); |
419 | extern void nfs_writedata_release(void *data); | ||
410 | 420 | ||
411 | #if defined(CONFIG_NFS_V3) || defined(CONFIG_NFS_V4) | 421 | #if defined(CONFIG_NFS_V3) || defined(CONFIG_NFS_V4) |
412 | extern void nfs_commit_done(struct rpc_task *); | 422 | extern void nfs_commit_done(struct rpc_task *, void *data); |
423 | extern void nfs_commit_release(void *data); | ||
413 | #endif | 424 | #endif |
414 | 425 | ||
415 | /* | 426 | /* |
@@ -460,18 +471,33 @@ static inline int nfs_wb_page(struct inode *inode, struct page* page) | |||
460 | */ | 471 | */ |
461 | extern mempool_t *nfs_wdata_mempool; | 472 | extern mempool_t *nfs_wdata_mempool; |
462 | 473 | ||
463 | static inline struct nfs_write_data *nfs_writedata_alloc(void) | 474 | static inline struct nfs_write_data *nfs_writedata_alloc(unsigned int pagecount) |
464 | { | 475 | { |
465 | struct nfs_write_data *p = mempool_alloc(nfs_wdata_mempool, SLAB_NOFS); | 476 | struct nfs_write_data *p = mempool_alloc(nfs_wdata_mempool, SLAB_NOFS); |
477 | |||
466 | if (p) { | 478 | if (p) { |
467 | memset(p, 0, sizeof(*p)); | 479 | memset(p, 0, sizeof(*p)); |
468 | INIT_LIST_HEAD(&p->pages); | 480 | INIT_LIST_HEAD(&p->pages); |
481 | if (pagecount < NFS_PAGEVEC_SIZE) | ||
482 | p->pagevec = &p->page_array[0]; | ||
483 | else { | ||
484 | size_t size = ++pagecount * sizeof(struct page *); | ||
485 | p->pagevec = kmalloc(size, GFP_NOFS); | ||
486 | if (p->pagevec) { | ||
487 | memset(p->pagevec, 0, size); | ||
488 | } else { | ||
489 | mempool_free(p, nfs_wdata_mempool); | ||
490 | p = NULL; | ||
491 | } | ||
492 | } | ||
469 | } | 493 | } |
470 | return p; | 494 | return p; |
471 | } | 495 | } |
472 | 496 | ||
473 | static inline void nfs_writedata_free(struct nfs_write_data *p) | 497 | static inline void nfs_writedata_free(struct nfs_write_data *p) |
474 | { | 498 | { |
499 | if (p && (p->pagevec != &p->page_array[0])) | ||
500 | kfree(p->pagevec); | ||
475 | mempool_free(p, nfs_wdata_mempool); | 501 | mempool_free(p, nfs_wdata_mempool); |
476 | } | 502 | } |
477 | 503 | ||
@@ -481,28 +507,45 @@ static inline void nfs_writedata_free(struct nfs_write_data *p) | |||
481 | extern int nfs_readpage(struct file *, struct page *); | 507 | extern int nfs_readpage(struct file *, struct page *); |
482 | extern int nfs_readpages(struct file *, struct address_space *, | 508 | extern int nfs_readpages(struct file *, struct address_space *, |
483 | struct list_head *, unsigned); | 509 | struct list_head *, unsigned); |
484 | extern void nfs_readpage_result(struct rpc_task *); | 510 | extern void nfs_readpage_result(struct rpc_task *, void *); |
511 | extern void nfs_readdata_release(void *data); | ||
512 | |||
485 | 513 | ||
486 | /* | 514 | /* |
487 | * Allocate and free nfs_read_data structures | 515 | * Allocate and free nfs_read_data structures |
488 | */ | 516 | */ |
489 | extern mempool_t *nfs_rdata_mempool; | 517 | extern mempool_t *nfs_rdata_mempool; |
490 | 518 | ||
491 | static inline struct nfs_read_data *nfs_readdata_alloc(void) | 519 | static inline struct nfs_read_data *nfs_readdata_alloc(unsigned int pagecount) |
492 | { | 520 | { |
493 | struct nfs_read_data *p = mempool_alloc(nfs_rdata_mempool, SLAB_NOFS); | 521 | struct nfs_read_data *p = mempool_alloc(nfs_rdata_mempool, SLAB_NOFS); |
494 | if (p) | 522 | |
523 | if (p) { | ||
495 | memset(p, 0, sizeof(*p)); | 524 | memset(p, 0, sizeof(*p)); |
525 | INIT_LIST_HEAD(&p->pages); | ||
526 | if (pagecount < NFS_PAGEVEC_SIZE) | ||
527 | p->pagevec = &p->page_array[0]; | ||
528 | else { | ||
529 | size_t size = ++pagecount * sizeof(struct page *); | ||
530 | p->pagevec = kmalloc(size, GFP_NOFS); | ||
531 | if (p->pagevec) { | ||
532 | memset(p->pagevec, 0, size); | ||
533 | } else { | ||
534 | mempool_free(p, nfs_rdata_mempool); | ||
535 | p = NULL; | ||
536 | } | ||
537 | } | ||
538 | } | ||
496 | return p; | 539 | return p; |
497 | } | 540 | } |
498 | 541 | ||
499 | static inline void nfs_readdata_free(struct nfs_read_data *p) | 542 | static inline void nfs_readdata_free(struct nfs_read_data *p) |
500 | { | 543 | { |
544 | if (p && (p->pagevec != &p->page_array[0])) | ||
545 | kfree(p->pagevec); | ||
501 | mempool_free(p, nfs_rdata_mempool); | 546 | mempool_free(p, nfs_rdata_mempool); |
502 | } | 547 | } |
503 | 548 | ||
504 | extern void nfs_readdata_release(struct rpc_task *task); | ||
505 | |||
506 | /* | 549 | /* |
507 | * linux/fs/nfs3proc.c | 550 | * linux/fs/nfs3proc.c |
508 | */ | 551 | */ |
diff --git a/include/linux/nfs_idmap.h b/include/linux/nfs_idmap.h index a0f1f25e0ead..102e56094296 100644 --- a/include/linux/nfs_idmap.h +++ b/include/linux/nfs_idmap.h | |||
@@ -71,6 +71,8 @@ int nfs_map_name_to_uid(struct nfs4_client *, const char *, size_t, __u32 *); | |||
71 | int nfs_map_group_to_gid(struct nfs4_client *, const char *, size_t, __u32 *); | 71 | int nfs_map_group_to_gid(struct nfs4_client *, const char *, size_t, __u32 *); |
72 | int nfs_map_uid_to_name(struct nfs4_client *, __u32, char *); | 72 | int nfs_map_uid_to_name(struct nfs4_client *, __u32, char *); |
73 | int nfs_map_gid_to_group(struct nfs4_client *, __u32, char *); | 73 | int nfs_map_gid_to_group(struct nfs4_client *, __u32, char *); |
74 | |||
75 | extern unsigned int nfs_idmap_cache_timeout; | ||
74 | #endif /* __KERNEL__ */ | 76 | #endif /* __KERNEL__ */ |
75 | 77 | ||
76 | #endif /* NFS_IDMAP_H */ | 78 | #endif /* NFS_IDMAP_H */ |
diff --git a/include/linux/nfs_page.h b/include/linux/nfs_page.h index da2e077b65e2..66e2ed658527 100644 --- a/include/linux/nfs_page.h +++ b/include/linux/nfs_page.h | |||
@@ -79,9 +79,7 @@ extern void nfs_clear_page_writeback(struct nfs_page *req); | |||
79 | static inline int | 79 | static inline int |
80 | nfs_lock_request_dontget(struct nfs_page *req) | 80 | nfs_lock_request_dontget(struct nfs_page *req) |
81 | { | 81 | { |
82 | if (test_and_set_bit(PG_BUSY, &req->wb_flags)) | 82 | return !test_and_set_bit(PG_BUSY, &req->wb_flags); |
83 | return 0; | ||
84 | return 1; | ||
85 | } | 83 | } |
86 | 84 | ||
87 | /* | 85 | /* |
@@ -125,9 +123,7 @@ nfs_list_remove_request(struct nfs_page *req) | |||
125 | static inline int | 123 | static inline int |
126 | nfs_defer_commit(struct nfs_page *req) | 124 | nfs_defer_commit(struct nfs_page *req) |
127 | { | 125 | { |
128 | if (test_and_set_bit(PG_NEED_COMMIT, &req->wb_flags)) | 126 | return !test_and_set_bit(PG_NEED_COMMIT, &req->wb_flags); |
129 | return 0; | ||
130 | return 1; | ||
131 | } | 127 | } |
132 | 128 | ||
133 | static inline void | 129 | static inline void |
@@ -141,9 +137,7 @@ nfs_clear_commit(struct nfs_page *req) | |||
141 | static inline int | 137 | static inline int |
142 | nfs_defer_reschedule(struct nfs_page *req) | 138 | nfs_defer_reschedule(struct nfs_page *req) |
143 | { | 139 | { |
144 | if (test_and_set_bit(PG_NEED_RESCHED, &req->wb_flags)) | 140 | return !test_and_set_bit(PG_NEED_RESCHED, &req->wb_flags); |
145 | return 0; | ||
146 | return 1; | ||
147 | } | 141 | } |
148 | 142 | ||
149 | static inline void | 143 | static inline void |
diff --git a/include/linux/nfs_xdr.h b/include/linux/nfs_xdr.h index 40718669b9c8..6d6f69ec5675 100644 --- a/include/linux/nfs_xdr.h +++ b/include/linux/nfs_xdr.h | |||
@@ -4,6 +4,16 @@ | |||
4 | #include <linux/sunrpc/xprt.h> | 4 | #include <linux/sunrpc/xprt.h> |
5 | #include <linux/nfsacl.h> | 5 | #include <linux/nfsacl.h> |
6 | 6 | ||
7 | /* | ||
8 | * To change the maximum rsize and wsize supported by the NFS client, adjust | ||
9 | * NFS_MAX_FILE_IO_SIZE. 64KB is a typical maximum, but some servers can | ||
10 | * support a megabyte or more. The default is left at 4096 bytes, which is | ||
11 | * reasonable for NFS over UDP. | ||
12 | */ | ||
13 | #define NFS_MAX_FILE_IO_SIZE (1048576U) | ||
14 | #define NFS_DEF_FILE_IO_SIZE (4096U) | ||
15 | #define NFS_MIN_FILE_IO_SIZE (1024U) | ||
16 | |||
7 | struct nfs4_fsid { | 17 | struct nfs4_fsid { |
8 | __u64 major; | 18 | __u64 major; |
9 | __u64 minor; | 19 | __u64 minor; |
@@ -137,7 +147,7 @@ struct nfs_openres { | |||
137 | */ | 147 | */ |
138 | struct nfs_open_confirmargs { | 148 | struct nfs_open_confirmargs { |
139 | const struct nfs_fh * fh; | 149 | const struct nfs_fh * fh; |
140 | nfs4_stateid stateid; | 150 | nfs4_stateid * stateid; |
141 | struct nfs_seqid * seqid; | 151 | struct nfs_seqid * seqid; |
142 | }; | 152 | }; |
143 | 153 | ||
@@ -165,66 +175,62 @@ struct nfs_closeres { | |||
165 | * * Arguments to the lock,lockt, and locku call. | 175 | * * Arguments to the lock,lockt, and locku call. |
166 | * */ | 176 | * */ |
167 | struct nfs_lowner { | 177 | struct nfs_lowner { |
168 | __u64 clientid; | 178 | __u64 clientid; |
169 | u32 id; | 179 | u32 id; |
170 | }; | 180 | }; |
171 | 181 | ||
172 | struct nfs_lock_opargs { | 182 | struct nfs_lock_args { |
183 | struct nfs_fh * fh; | ||
184 | struct file_lock * fl; | ||
173 | struct nfs_seqid * lock_seqid; | 185 | struct nfs_seqid * lock_seqid; |
174 | nfs4_stateid * lock_stateid; | 186 | nfs4_stateid * lock_stateid; |
175 | struct nfs_seqid * open_seqid; | 187 | struct nfs_seqid * open_seqid; |
176 | nfs4_stateid * open_stateid; | 188 | nfs4_stateid * open_stateid; |
177 | struct nfs_lowner lock_owner; | 189 | struct nfs_lowner lock_owner; |
178 | __u32 reclaim; | 190 | unsigned char block : 1; |
179 | __u32 new_lock_owner; | 191 | unsigned char reclaim : 1; |
192 | unsigned char new_lock_owner : 1; | ||
180 | }; | 193 | }; |
181 | 194 | ||
182 | struct nfs_locku_opargs { | 195 | struct nfs_lock_res { |
196 | nfs4_stateid stateid; | ||
197 | }; | ||
198 | |||
199 | struct nfs_locku_args { | ||
200 | struct nfs_fh * fh; | ||
201 | struct file_lock * fl; | ||
183 | struct nfs_seqid * seqid; | 202 | struct nfs_seqid * seqid; |
184 | nfs4_stateid * stateid; | 203 | nfs4_stateid * stateid; |
185 | }; | 204 | }; |
186 | 205 | ||
187 | struct nfs_lockargs { | 206 | struct nfs_locku_res { |
188 | struct nfs_fh * fh; | 207 | nfs4_stateid stateid; |
189 | __u32 type; | ||
190 | __u64 offset; | ||
191 | __u64 length; | ||
192 | union { | ||
193 | struct nfs_lock_opargs *lock; /* LOCK */ | ||
194 | struct nfs_lowner *lockt; /* LOCKT */ | ||
195 | struct nfs_locku_opargs *locku; /* LOCKU */ | ||
196 | } u; | ||
197 | }; | 208 | }; |
198 | 209 | ||
199 | struct nfs_lock_denied { | 210 | struct nfs_lockt_args { |
200 | __u64 offset; | 211 | struct nfs_fh * fh; |
201 | __u64 length; | 212 | struct file_lock * fl; |
202 | __u32 type; | 213 | struct nfs_lowner lock_owner; |
203 | struct nfs_lowner owner; | ||
204 | }; | 214 | }; |
205 | 215 | ||
206 | struct nfs_lockres { | 216 | struct nfs_lockt_res { |
207 | union { | 217 | struct file_lock * denied; /* LOCK, LOCKT failed */ |
208 | nfs4_stateid stateid;/* LOCK success, LOCKU */ | ||
209 | struct nfs_lock_denied denied; /* LOCK failed, LOCKT success */ | ||
210 | } u; | ||
211 | const struct nfs_server * server; | ||
212 | }; | 218 | }; |
213 | 219 | ||
214 | struct nfs4_delegreturnargs { | 220 | struct nfs4_delegreturnargs { |
215 | const struct nfs_fh *fhandle; | 221 | const struct nfs_fh *fhandle; |
216 | const nfs4_stateid *stateid; | 222 | const nfs4_stateid *stateid; |
223 | const u32 * bitmask; | ||
224 | }; | ||
225 | |||
226 | struct nfs4_delegreturnres { | ||
227 | struct nfs_fattr * fattr; | ||
228 | const struct nfs_server *server; | ||
217 | }; | 229 | }; |
218 | 230 | ||
219 | /* | 231 | /* |
220 | * Arguments to the read call. | 232 | * Arguments to the read call. |
221 | */ | 233 | */ |
222 | |||
223 | #define NFS_READ_MAXIOV (9U) | ||
224 | #if (NFS_READ_MAXIOV > (MAX_IOVEC -2)) | ||
225 | #error "NFS_READ_MAXIOV is too large" | ||
226 | #endif | ||
227 | |||
228 | struct nfs_readargs { | 234 | struct nfs_readargs { |
229 | struct nfs_fh * fh; | 235 | struct nfs_fh * fh; |
230 | struct nfs_open_context *context; | 236 | struct nfs_open_context *context; |
@@ -243,11 +249,6 @@ struct nfs_readres { | |||
243 | /* | 249 | /* |
244 | * Arguments to the write call. | 250 | * Arguments to the write call. |
245 | */ | 251 | */ |
246 | #define NFS_WRITE_MAXIOV (9U) | ||
247 | #if (NFS_WRITE_MAXIOV > (MAX_IOVEC -2)) | ||
248 | #error "NFS_WRITE_MAXIOV is too large" | ||
249 | #endif | ||
250 | |||
251 | struct nfs_writeargs { | 252 | struct nfs_writeargs { |
252 | struct nfs_fh * fh; | 253 | struct nfs_fh * fh; |
253 | struct nfs_open_context *context; | 254 | struct nfs_open_context *context; |
@@ -678,6 +679,8 @@ struct nfs4_server_caps_res { | |||
678 | 679 | ||
679 | struct nfs_page; | 680 | struct nfs_page; |
680 | 681 | ||
682 | #define NFS_PAGEVEC_SIZE (8U) | ||
683 | |||
681 | struct nfs_read_data { | 684 | struct nfs_read_data { |
682 | int flags; | 685 | int flags; |
683 | struct rpc_task task; | 686 | struct rpc_task task; |
@@ -686,13 +689,14 @@ struct nfs_read_data { | |||
686 | struct nfs_fattr fattr; /* fattr storage */ | 689 | struct nfs_fattr fattr; /* fattr storage */ |
687 | struct list_head pages; /* Coalesced read requests */ | 690 | struct list_head pages; /* Coalesced read requests */ |
688 | struct nfs_page *req; /* multi ops per nfs_page */ | 691 | struct nfs_page *req; /* multi ops per nfs_page */ |
689 | struct page *pagevec[NFS_READ_MAXIOV]; | 692 | struct page **pagevec; |
690 | struct nfs_readargs args; | 693 | struct nfs_readargs args; |
691 | struct nfs_readres res; | 694 | struct nfs_readres res; |
692 | #ifdef CONFIG_NFS_V4 | 695 | #ifdef CONFIG_NFS_V4 |
693 | unsigned long timestamp; /* For lease renewal */ | 696 | unsigned long timestamp; /* For lease renewal */ |
694 | #endif | 697 | #endif |
695 | void (*complete) (struct nfs_read_data *, int); | 698 | void (*complete) (struct nfs_read_data *, int); |
699 | struct page *page_array[NFS_PAGEVEC_SIZE + 1]; | ||
696 | }; | 700 | }; |
697 | 701 | ||
698 | struct nfs_write_data { | 702 | struct nfs_write_data { |
@@ -704,13 +708,14 @@ struct nfs_write_data { | |||
704 | struct nfs_writeverf verf; | 708 | struct nfs_writeverf verf; |
705 | struct list_head pages; /* Coalesced requests we wish to flush */ | 709 | struct list_head pages; /* Coalesced requests we wish to flush */ |
706 | struct nfs_page *req; /* multi ops per nfs_page */ | 710 | struct nfs_page *req; /* multi ops per nfs_page */ |
707 | struct page *pagevec[NFS_WRITE_MAXIOV]; | 711 | struct page **pagevec; |
708 | struct nfs_writeargs args; /* argument struct */ | 712 | struct nfs_writeargs args; /* argument struct */ |
709 | struct nfs_writeres res; /* result struct */ | 713 | struct nfs_writeres res; /* result struct */ |
710 | #ifdef CONFIG_NFS_V4 | 714 | #ifdef CONFIG_NFS_V4 |
711 | unsigned long timestamp; /* For lease renewal */ | 715 | unsigned long timestamp; /* For lease renewal */ |
712 | #endif | 716 | #endif |
713 | void (*complete) (struct nfs_write_data *, int); | 717 | void (*complete) (struct nfs_write_data *, int); |
718 | struct page *page_array[NFS_PAGEVEC_SIZE + 1]; | ||
714 | }; | 719 | }; |
715 | 720 | ||
716 | struct nfs_access_entry; | 721 | struct nfs_access_entry; |
diff --git a/include/linux/sunrpc/clnt.h b/include/linux/sunrpc/clnt.h index ab151bbb66df..f147e6b84332 100644 --- a/include/linux/sunrpc/clnt.h +++ b/include/linux/sunrpc/clnt.h | |||
@@ -49,7 +49,6 @@ struct rpc_clnt { | |||
49 | 49 | ||
50 | unsigned int cl_softrtry : 1,/* soft timeouts */ | 50 | unsigned int cl_softrtry : 1,/* soft timeouts */ |
51 | cl_intr : 1,/* interruptible */ | 51 | cl_intr : 1,/* interruptible */ |
52 | cl_chatty : 1,/* be verbose */ | ||
53 | cl_autobind : 1,/* use getport() */ | 52 | cl_autobind : 1,/* use getport() */ |
54 | cl_oneshot : 1,/* dispose after use */ | 53 | cl_oneshot : 1,/* dispose after use */ |
55 | cl_dead : 1;/* abandoned */ | 54 | cl_dead : 1;/* abandoned */ |
@@ -126,7 +125,8 @@ int rpc_register(u32, u32, int, unsigned short, int *); | |||
126 | void rpc_call_setup(struct rpc_task *, struct rpc_message *, int); | 125 | void rpc_call_setup(struct rpc_task *, struct rpc_message *, int); |
127 | 126 | ||
128 | int rpc_call_async(struct rpc_clnt *clnt, struct rpc_message *msg, | 127 | int rpc_call_async(struct rpc_clnt *clnt, struct rpc_message *msg, |
129 | int flags, rpc_action callback, void *clntdata); | 128 | int flags, const struct rpc_call_ops *tk_ops, |
129 | void *calldata); | ||
130 | int rpc_call_sync(struct rpc_clnt *clnt, struct rpc_message *msg, | 130 | int rpc_call_sync(struct rpc_clnt *clnt, struct rpc_message *msg, |
131 | int flags); | 131 | int flags); |
132 | void rpc_restart_call(struct rpc_task *); | 132 | void rpc_restart_call(struct rpc_task *); |
@@ -134,6 +134,7 @@ void rpc_clnt_sigmask(struct rpc_clnt *clnt, sigset_t *oldset); | |||
134 | void rpc_clnt_sigunmask(struct rpc_clnt *clnt, sigset_t *oldset); | 134 | void rpc_clnt_sigunmask(struct rpc_clnt *clnt, sigset_t *oldset); |
135 | void rpc_setbufsize(struct rpc_clnt *, unsigned int, unsigned int); | 135 | void rpc_setbufsize(struct rpc_clnt *, unsigned int, unsigned int); |
136 | size_t rpc_max_payload(struct rpc_clnt *); | 136 | size_t rpc_max_payload(struct rpc_clnt *); |
137 | void rpc_force_rebind(struct rpc_clnt *); | ||
137 | int rpc_ping(struct rpc_clnt *clnt, int flags); | 138 | int rpc_ping(struct rpc_clnt *clnt, int flags); |
138 | 139 | ||
139 | static __inline__ | 140 | static __inline__ |
diff --git a/include/linux/sunrpc/gss_spkm3.h b/include/linux/sunrpc/gss_spkm3.h index 0beb2cf00a84..336e218c2782 100644 --- a/include/linux/sunrpc/gss_spkm3.h +++ b/include/linux/sunrpc/gss_spkm3.h | |||
@@ -48,7 +48,7 @@ u32 spkm3_read_token(struct spkm3_ctx *ctx, struct xdr_netobj *read_token, struc | |||
48 | #define CKSUMTYPE_RSA_MD5 0x0007 | 48 | #define CKSUMTYPE_RSA_MD5 0x0007 |
49 | 49 | ||
50 | s32 make_checksum(s32 cksumtype, char *header, int hdrlen, struct xdr_buf *body, | 50 | s32 make_checksum(s32 cksumtype, char *header, int hdrlen, struct xdr_buf *body, |
51 | struct xdr_netobj *cksum); | 51 | int body_offset, struct xdr_netobj *cksum); |
52 | void asn1_bitstring_len(struct xdr_netobj *in, int *enclen, int *zerobits); | 52 | void asn1_bitstring_len(struct xdr_netobj *in, int *enclen, int *zerobits); |
53 | int decode_asn1_bitstring(struct xdr_netobj *out, char *in, int enclen, | 53 | int decode_asn1_bitstring(struct xdr_netobj *out, char *in, int enclen, |
54 | int explen); | 54 | int explen); |
diff --git a/include/linux/sunrpc/sched.h b/include/linux/sunrpc/sched.h index 4d77e90d0b30..8b25629accd8 100644 --- a/include/linux/sunrpc/sched.h +++ b/include/linux/sunrpc/sched.h | |||
@@ -27,6 +27,7 @@ struct rpc_message { | |||
27 | struct rpc_cred * rpc_cred; /* Credentials */ | 27 | struct rpc_cred * rpc_cred; /* Credentials */ |
28 | }; | 28 | }; |
29 | 29 | ||
30 | struct rpc_call_ops; | ||
30 | struct rpc_wait_queue; | 31 | struct rpc_wait_queue; |
31 | struct rpc_wait { | 32 | struct rpc_wait { |
32 | struct list_head list; /* wait queue links */ | 33 | struct list_head list; /* wait queue links */ |
@@ -41,6 +42,7 @@ struct rpc_task { | |||
41 | #ifdef RPC_DEBUG | 42 | #ifdef RPC_DEBUG |
42 | unsigned long tk_magic; /* 0xf00baa */ | 43 | unsigned long tk_magic; /* 0xf00baa */ |
43 | #endif | 44 | #endif |
45 | atomic_t tk_count; /* Reference count */ | ||
44 | struct list_head tk_task; /* global list of tasks */ | 46 | struct list_head tk_task; /* global list of tasks */ |
45 | struct rpc_clnt * tk_client; /* RPC client */ | 47 | struct rpc_clnt * tk_client; /* RPC client */ |
46 | struct rpc_rqst * tk_rqstp; /* RPC request */ | 48 | struct rpc_rqst * tk_rqstp; /* RPC request */ |
@@ -50,8 +52,6 @@ struct rpc_task { | |||
50 | * RPC call state | 52 | * RPC call state |
51 | */ | 53 | */ |
52 | struct rpc_message tk_msg; /* RPC call info */ | 54 | struct rpc_message tk_msg; /* RPC call info */ |
53 | __u32 * tk_buffer; /* XDR buffer */ | ||
54 | size_t tk_bufsize; | ||
55 | __u8 tk_garb_retry; | 55 | __u8 tk_garb_retry; |
56 | __u8 tk_cred_retry; | 56 | __u8 tk_cred_retry; |
57 | 57 | ||
@@ -61,13 +61,12 @@ struct rpc_task { | |||
61 | * timeout_fn to be executed by timer bottom half | 61 | * timeout_fn to be executed by timer bottom half |
62 | * callback to be executed after waking up | 62 | * callback to be executed after waking up |
63 | * action next procedure for async tasks | 63 | * action next procedure for async tasks |
64 | * exit exit async task and report to caller | 64 | * tk_ops caller callbacks |
65 | */ | 65 | */ |
66 | void (*tk_timeout_fn)(struct rpc_task *); | 66 | void (*tk_timeout_fn)(struct rpc_task *); |
67 | void (*tk_callback)(struct rpc_task *); | 67 | void (*tk_callback)(struct rpc_task *); |
68 | void (*tk_action)(struct rpc_task *); | 68 | void (*tk_action)(struct rpc_task *); |
69 | void (*tk_exit)(struct rpc_task *); | 69 | const struct rpc_call_ops *tk_ops; |
70 | void (*tk_release)(struct rpc_task *); | ||
71 | void * tk_calldata; | 70 | void * tk_calldata; |
72 | 71 | ||
73 | /* | 72 | /* |
@@ -78,7 +77,6 @@ struct rpc_task { | |||
78 | struct timer_list tk_timer; /* kernel timer */ | 77 | struct timer_list tk_timer; /* kernel timer */ |
79 | unsigned long tk_timeout; /* timeout for rpc_sleep() */ | 78 | unsigned long tk_timeout; /* timeout for rpc_sleep() */ |
80 | unsigned short tk_flags; /* misc flags */ | 79 | unsigned short tk_flags; /* misc flags */ |
81 | unsigned char tk_active : 1;/* Task has been activated */ | ||
82 | unsigned char tk_priority : 2;/* Task priority */ | 80 | unsigned char tk_priority : 2;/* Task priority */ |
83 | unsigned long tk_runstate; /* Task run status */ | 81 | unsigned long tk_runstate; /* Task run status */ |
84 | struct workqueue_struct *tk_workqueue; /* Normally rpciod, but could | 82 | struct workqueue_struct *tk_workqueue; /* Normally rpciod, but could |
@@ -111,6 +109,13 @@ struct rpc_task { | |||
111 | 109 | ||
112 | typedef void (*rpc_action)(struct rpc_task *); | 110 | typedef void (*rpc_action)(struct rpc_task *); |
113 | 111 | ||
112 | struct rpc_call_ops { | ||
113 | void (*rpc_call_prepare)(struct rpc_task *, void *); | ||
114 | void (*rpc_call_done)(struct rpc_task *, void *); | ||
115 | void (*rpc_release)(void *); | ||
116 | }; | ||
117 | |||
118 | |||
114 | /* | 119 | /* |
115 | * RPC task flags | 120 | * RPC task flags |
116 | */ | 121 | */ |
@@ -129,7 +134,6 @@ typedef void (*rpc_action)(struct rpc_task *); | |||
129 | #define RPC_IS_SWAPPER(t) ((t)->tk_flags & RPC_TASK_SWAPPER) | 134 | #define RPC_IS_SWAPPER(t) ((t)->tk_flags & RPC_TASK_SWAPPER) |
130 | #define RPC_DO_ROOTOVERRIDE(t) ((t)->tk_flags & RPC_TASK_ROOTCREDS) | 135 | #define RPC_DO_ROOTOVERRIDE(t) ((t)->tk_flags & RPC_TASK_ROOTCREDS) |
131 | #define RPC_ASSASSINATED(t) ((t)->tk_flags & RPC_TASK_KILLED) | 136 | #define RPC_ASSASSINATED(t) ((t)->tk_flags & RPC_TASK_KILLED) |
132 | #define RPC_IS_ACTIVATED(t) ((t)->tk_active) | ||
133 | #define RPC_DO_CALLBACK(t) ((t)->tk_callback != NULL) | 137 | #define RPC_DO_CALLBACK(t) ((t)->tk_callback != NULL) |
134 | #define RPC_IS_SOFT(t) ((t)->tk_flags & RPC_TASK_SOFT) | 138 | #define RPC_IS_SOFT(t) ((t)->tk_flags & RPC_TASK_SOFT) |
135 | #define RPC_TASK_UNINTERRUPTIBLE(t) ((t)->tk_flags & RPC_TASK_NOINTR) | 139 | #define RPC_TASK_UNINTERRUPTIBLE(t) ((t)->tk_flags & RPC_TASK_NOINTR) |
@@ -138,6 +142,7 @@ typedef void (*rpc_action)(struct rpc_task *); | |||
138 | #define RPC_TASK_QUEUED 1 | 142 | #define RPC_TASK_QUEUED 1 |
139 | #define RPC_TASK_WAKEUP 2 | 143 | #define RPC_TASK_WAKEUP 2 |
140 | #define RPC_TASK_HAS_TIMER 3 | 144 | #define RPC_TASK_HAS_TIMER 3 |
145 | #define RPC_TASK_ACTIVE 4 | ||
141 | 146 | ||
142 | #define RPC_IS_RUNNING(t) (test_bit(RPC_TASK_RUNNING, &(t)->tk_runstate)) | 147 | #define RPC_IS_RUNNING(t) (test_bit(RPC_TASK_RUNNING, &(t)->tk_runstate)) |
143 | #define rpc_set_running(t) (set_bit(RPC_TASK_RUNNING, &(t)->tk_runstate)) | 148 | #define rpc_set_running(t) (set_bit(RPC_TASK_RUNNING, &(t)->tk_runstate)) |
@@ -168,6 +173,15 @@ typedef void (*rpc_action)(struct rpc_task *); | |||
168 | smp_mb__after_clear_bit(); \ | 173 | smp_mb__after_clear_bit(); \ |
169 | } while (0) | 174 | } while (0) |
170 | 175 | ||
176 | #define RPC_IS_ACTIVATED(t) (test_bit(RPC_TASK_ACTIVE, &(t)->tk_runstate)) | ||
177 | #define rpc_set_active(t) (set_bit(RPC_TASK_ACTIVE, &(t)->tk_runstate)) | ||
178 | #define rpc_clear_active(t) \ | ||
179 | do { \ | ||
180 | smp_mb__before_clear_bit(); \ | ||
181 | clear_bit(RPC_TASK_ACTIVE, &(t)->tk_runstate); \ | ||
182 | smp_mb__after_clear_bit(); \ | ||
183 | } while(0) | ||
184 | |||
171 | /* | 185 | /* |
172 | * Task priorities. | 186 | * Task priorities. |
173 | * Note: if you change these, you must also change | 187 | * Note: if you change these, you must also change |
@@ -228,11 +242,16 @@ struct rpc_wait_queue { | |||
228 | /* | 242 | /* |
229 | * Function prototypes | 243 | * Function prototypes |
230 | */ | 244 | */ |
231 | struct rpc_task *rpc_new_task(struct rpc_clnt *, rpc_action, int flags); | 245 | struct rpc_task *rpc_new_task(struct rpc_clnt *, int flags, |
246 | const struct rpc_call_ops *ops, void *data); | ||
247 | struct rpc_task *rpc_run_task(struct rpc_clnt *clnt, int flags, | ||
248 | const struct rpc_call_ops *ops, void *data); | ||
232 | struct rpc_task *rpc_new_child(struct rpc_clnt *, struct rpc_task *parent); | 249 | struct rpc_task *rpc_new_child(struct rpc_clnt *, struct rpc_task *parent); |
233 | void rpc_init_task(struct rpc_task *, struct rpc_clnt *, | 250 | void rpc_init_task(struct rpc_task *task, struct rpc_clnt *clnt, |
234 | rpc_action exitfunc, int flags); | 251 | int flags, const struct rpc_call_ops *ops, |
252 | void *data); | ||
235 | void rpc_release_task(struct rpc_task *); | 253 | void rpc_release_task(struct rpc_task *); |
254 | void rpc_exit_task(struct rpc_task *); | ||
236 | void rpc_killall_tasks(struct rpc_clnt *); | 255 | void rpc_killall_tasks(struct rpc_clnt *); |
237 | int rpc_execute(struct rpc_task *); | 256 | int rpc_execute(struct rpc_task *); |
238 | void rpc_run_child(struct rpc_task *parent, struct rpc_task *child, | 257 | void rpc_run_child(struct rpc_task *parent, struct rpc_task *child, |
@@ -247,9 +266,11 @@ struct rpc_task *rpc_wake_up_next(struct rpc_wait_queue *); | |||
247 | void rpc_wake_up_status(struct rpc_wait_queue *, int); | 266 | void rpc_wake_up_status(struct rpc_wait_queue *, int); |
248 | void rpc_delay(struct rpc_task *, unsigned long); | 267 | void rpc_delay(struct rpc_task *, unsigned long); |
249 | void * rpc_malloc(struct rpc_task *, size_t); | 268 | void * rpc_malloc(struct rpc_task *, size_t); |
269 | void rpc_free(struct rpc_task *); | ||
250 | int rpciod_up(void); | 270 | int rpciod_up(void); |
251 | void rpciod_down(void); | 271 | void rpciod_down(void); |
252 | void rpciod_wake_up(void); | 272 | void rpciod_wake_up(void); |
273 | int __rpc_wait_for_completion_task(struct rpc_task *task, int (*)(void *)); | ||
253 | #ifdef RPC_DEBUG | 274 | #ifdef RPC_DEBUG |
254 | void rpc_show_tasks(void); | 275 | void rpc_show_tasks(void); |
255 | #endif | 276 | #endif |
@@ -259,7 +280,12 @@ void rpc_destroy_mempool(void); | |||
259 | static inline void rpc_exit(struct rpc_task *task, int status) | 280 | static inline void rpc_exit(struct rpc_task *task, int status) |
260 | { | 281 | { |
261 | task->tk_status = status; | 282 | task->tk_status = status; |
262 | task->tk_action = NULL; | 283 | task->tk_action = rpc_exit_task; |
284 | } | ||
285 | |||
286 | static inline int rpc_wait_for_completion_task(struct rpc_task *task) | ||
287 | { | ||
288 | return __rpc_wait_for_completion_task(task, NULL); | ||
263 | } | 289 | } |
264 | 290 | ||
265 | #ifdef RPC_DEBUG | 291 | #ifdef RPC_DEBUG |
diff --git a/include/linux/sunrpc/xdr.h b/include/linux/sunrpc/xdr.h index 5da968729cf8..84c35d42d250 100644 --- a/include/linux/sunrpc/xdr.h +++ b/include/linux/sunrpc/xdr.h | |||
@@ -91,7 +91,6 @@ struct xdr_buf { | |||
91 | u32 * xdr_encode_opaque_fixed(u32 *p, const void *ptr, unsigned int len); | 91 | u32 * xdr_encode_opaque_fixed(u32 *p, const void *ptr, unsigned int len); |
92 | u32 * xdr_encode_opaque(u32 *p, const void *ptr, unsigned int len); | 92 | u32 * xdr_encode_opaque(u32 *p, const void *ptr, unsigned int len); |
93 | u32 * xdr_encode_string(u32 *p, const char *s); | 93 | u32 * xdr_encode_string(u32 *p, const char *s); |
94 | u32 * xdr_decode_string(u32 *p, char **sp, int *lenp, int maxlen); | ||
95 | u32 * xdr_decode_string_inplace(u32 *p, char **sp, int *lenp, int maxlen); | 94 | u32 * xdr_decode_string_inplace(u32 *p, char **sp, int *lenp, int maxlen); |
96 | u32 * xdr_encode_netobj(u32 *p, const struct xdr_netobj *); | 95 | u32 * xdr_encode_netobj(u32 *p, const struct xdr_netobj *); |
97 | u32 * xdr_decode_netobj(u32 *p, struct xdr_netobj *); | 96 | u32 * xdr_decode_netobj(u32 *p, struct xdr_netobj *); |
@@ -135,11 +134,6 @@ xdr_adjust_iovec(struct kvec *iov, u32 *p) | |||
135 | } | 134 | } |
136 | 135 | ||
137 | /* | 136 | /* |
138 | * Maximum number of iov's we use. | ||
139 | */ | ||
140 | #define MAX_IOVEC (12) | ||
141 | |||
142 | /* | ||
143 | * XDR buffer helper functions | 137 | * XDR buffer helper functions |
144 | */ | 138 | */ |
145 | extern void xdr_shift_buf(struct xdr_buf *, size_t); | 139 | extern void xdr_shift_buf(struct xdr_buf *, size_t); |
diff --git a/include/linux/sunrpc/xprt.h b/include/linux/sunrpc/xprt.h index 3b8b6e823c70..6ef99b14ff09 100644 --- a/include/linux/sunrpc/xprt.h +++ b/include/linux/sunrpc/xprt.h | |||
@@ -79,21 +79,19 @@ struct rpc_rqst { | |||
79 | void (*rq_release_snd_buf)(struct rpc_rqst *); /* release rq_enc_pages */ | 79 | void (*rq_release_snd_buf)(struct rpc_rqst *); /* release rq_enc_pages */ |
80 | struct list_head rq_list; | 80 | struct list_head rq_list; |
81 | 81 | ||
82 | __u32 * rq_buffer; /* XDR encode buffer */ | ||
83 | size_t rq_bufsize; | ||
84 | |||
82 | struct xdr_buf rq_private_buf; /* The receive buffer | 85 | struct xdr_buf rq_private_buf; /* The receive buffer |
83 | * used in the softirq. | 86 | * used in the softirq. |
84 | */ | 87 | */ |
85 | unsigned long rq_majortimeo; /* major timeout alarm */ | 88 | unsigned long rq_majortimeo; /* major timeout alarm */ |
86 | unsigned long rq_timeout; /* Current timeout value */ | 89 | unsigned long rq_timeout; /* Current timeout value */ |
87 | unsigned int rq_retries; /* # of retries */ | 90 | unsigned int rq_retries; /* # of retries */ |
88 | /* | ||
89 | * For authentication (e.g. auth_des) | ||
90 | */ | ||
91 | u32 rq_creddata[2]; | ||
92 | 91 | ||
93 | /* | 92 | /* |
94 | * Partial send handling | 93 | * Partial send handling |
95 | */ | 94 | */ |
96 | |||
97 | u32 rq_bytes_sent; /* Bytes we have sent */ | 95 | u32 rq_bytes_sent; /* Bytes we have sent */ |
98 | 96 | ||
99 | unsigned long rq_xtime; /* when transmitted */ | 97 | unsigned long rq_xtime; /* when transmitted */ |
@@ -106,7 +104,10 @@ struct rpc_xprt_ops { | |||
106 | void (*set_buffer_size)(struct rpc_xprt *xprt, size_t sndsize, size_t rcvsize); | 104 | void (*set_buffer_size)(struct rpc_xprt *xprt, size_t sndsize, size_t rcvsize); |
107 | int (*reserve_xprt)(struct rpc_task *task); | 105 | int (*reserve_xprt)(struct rpc_task *task); |
108 | void (*release_xprt)(struct rpc_xprt *xprt, struct rpc_task *task); | 106 | void (*release_xprt)(struct rpc_xprt *xprt, struct rpc_task *task); |
107 | void (*set_port)(struct rpc_xprt *xprt, unsigned short port); | ||
109 | void (*connect)(struct rpc_task *task); | 108 | void (*connect)(struct rpc_task *task); |
109 | void * (*buf_alloc)(struct rpc_task *task, size_t size); | ||
110 | void (*buf_free)(struct rpc_task *task); | ||
110 | int (*send_request)(struct rpc_task *task); | 111 | int (*send_request)(struct rpc_task *task); |
111 | void (*set_retrans_timeout)(struct rpc_task *task); | 112 | void (*set_retrans_timeout)(struct rpc_task *task); |
112 | void (*timer)(struct rpc_task *task); | 113 | void (*timer)(struct rpc_task *task); |
@@ -253,6 +254,7 @@ int xs_setup_tcp(struct rpc_xprt *xprt, struct rpc_timeout *to); | |||
253 | #define XPRT_LOCKED (0) | 254 | #define XPRT_LOCKED (0) |
254 | #define XPRT_CONNECTED (1) | 255 | #define XPRT_CONNECTED (1) |
255 | #define XPRT_CONNECTING (2) | 256 | #define XPRT_CONNECTING (2) |
257 | #define XPRT_CLOSE_WAIT (3) | ||
256 | 258 | ||
257 | static inline void xprt_set_connected(struct rpc_xprt *xprt) | 259 | static inline void xprt_set_connected(struct rpc_xprt *xprt) |
258 | { | 260 | { |
diff --git a/include/linux/writeback.h b/include/linux/writeback.h index 64a36ba43b2f..b096159086e8 100644 --- a/include/linux/writeback.h +++ b/include/linux/writeback.h | |||
@@ -53,10 +53,11 @@ struct writeback_control { | |||
53 | loff_t start; | 53 | loff_t start; |
54 | loff_t end; | 54 | loff_t end; |
55 | 55 | ||
56 | unsigned nonblocking:1; /* Don't get stuck on request queues */ | 56 | unsigned nonblocking:1; /* Don't get stuck on request queues */ |
57 | unsigned encountered_congestion:1; /* An output: a queue is full */ | 57 | unsigned encountered_congestion:1; /* An output: a queue is full */ |
58 | unsigned for_kupdate:1; /* A kupdate writeback */ | 58 | unsigned for_kupdate:1; /* A kupdate writeback */ |
59 | unsigned for_reclaim:1; /* Invoked from the page allocator */ | 59 | unsigned for_reclaim:1; /* Invoked from the page allocator */ |
60 | unsigned for_writepages:1; /* This is a writepages() call */ | ||
60 | }; | 61 | }; |
61 | 62 | ||
62 | /* | 63 | /* |
diff --git a/include/media/saa7146.h b/include/media/saa7146.h index e5be2b9b846b..2bc634fcb7bb 100644 --- a/include/media/saa7146.h +++ b/include/media/saa7146.h | |||
@@ -21,14 +21,14 @@ | |||
21 | 21 | ||
22 | extern unsigned int saa7146_debug; | 22 | extern unsigned int saa7146_debug; |
23 | 23 | ||
24 | //#define DEBUG_PROLOG printk("(0x%08x)(0x%08x) %s: %s(): ",(dev==0?-1:(dev->mem==0?-1:saa7146_read(dev,RPS_ADDR0))),(dev==0?-1:(dev->mem==0?-1:saa7146_read(dev,IER))),__stringify(KBUILD_MODNAME),__FUNCTION__) | 24 | //#define DEBUG_PROLOG printk("(0x%08x)(0x%08x) %s: %s(): ",(dev==0?-1:(dev->mem==0?-1:saa7146_read(dev,RPS_ADDR0))),(dev==0?-1:(dev->mem==0?-1:saa7146_read(dev,IER))),KBUILD_MODNAME,__FUNCTION__) |
25 | 25 | ||
26 | #ifndef DEBUG_VARIABLE | 26 | #ifndef DEBUG_VARIABLE |
27 | #define DEBUG_VARIABLE saa7146_debug | 27 | #define DEBUG_VARIABLE saa7146_debug |
28 | #endif | 28 | #endif |
29 | 29 | ||
30 | #define DEBUG_PROLOG printk("%s: %s(): ",__stringify(KBUILD_MODNAME),__FUNCTION__) | 30 | #define DEBUG_PROLOG printk("%s: %s(): ",KBUILD_MODNAME,__FUNCTION__) |
31 | #define INFO(x) { printk("%s: ",__stringify(KBUILD_MODNAME)); printk x; } | 31 | #define INFO(x) { printk("%s: ",KBUILD_MODNAME); printk x; } |
32 | 32 | ||
33 | #define ERR(x) { DEBUG_PROLOG; printk x; } | 33 | #define ERR(x) { DEBUG_PROLOG; printk x; } |
34 | 34 | ||