diff options
| -rw-r--r-- | arch/um/include/asm/Kbuild | 1 | ||||
| -rw-r--r-- | arch/um/include/asm/processor-generic.h | 3 | ||||
| -rw-r--r-- | fs/hostfs/hostfs_kern.c | 53 |
3 files changed, 29 insertions, 28 deletions
diff --git a/arch/um/include/asm/Kbuild b/arch/um/include/asm/Kbuild index 75de4abe4f94..88a330dcdede 100644 --- a/arch/um/include/asm/Kbuild +++ b/arch/um/include/asm/Kbuild | |||
| @@ -5,3 +5,4 @@ generic-y += switch_to.h clkdev.h | |||
| 5 | generic-y += trace_clock.h | 5 | generic-y += trace_clock.h |
| 6 | generic-y += preempt.h | 6 | generic-y += preempt.h |
| 7 | generic-y += hash.h | 7 | generic-y += hash.h |
| 8 | generic-y += barrier.h | ||
diff --git a/arch/um/include/asm/processor-generic.h b/arch/um/include/asm/processor-generic.h index d89b02bb6262..cbc5edd5a901 100644 --- a/arch/um/include/asm/processor-generic.h +++ b/arch/um/include/asm/processor-generic.h | |||
| @@ -25,10 +25,8 @@ struct thread_struct { | |||
| 25 | void *fault_addr; | 25 | void *fault_addr; |
| 26 | jmp_buf *fault_catcher; | 26 | jmp_buf *fault_catcher; |
| 27 | struct task_struct *prev_sched; | 27 | struct task_struct *prev_sched; |
| 28 | unsigned long temp_stack; | ||
| 29 | struct arch_thread arch; | 28 | struct arch_thread arch; |
| 30 | jmp_buf switch_buf; | 29 | jmp_buf switch_buf; |
| 31 | int mm_count; | ||
| 32 | struct { | 30 | struct { |
| 33 | int op; | 31 | int op; |
| 34 | union { | 32 | union { |
| @@ -52,7 +50,6 @@ struct thread_struct { | |||
| 52 | .regs = EMPTY_REGS, \ | 50 | .regs = EMPTY_REGS, \ |
| 53 | .fault_addr = NULL, \ | 51 | .fault_addr = NULL, \ |
| 54 | .prev_sched = NULL, \ | 52 | .prev_sched = NULL, \ |
| 55 | .temp_stack = 0, \ | ||
| 56 | .arch = INIT_ARCH_THREAD, \ | 53 | .arch = INIT_ARCH_THREAD, \ |
| 57 | .request = { 0 } \ | 54 | .request = { 0 } \ |
| 58 | } | 55 | } |
diff --git a/fs/hostfs/hostfs_kern.c b/fs/hostfs/hostfs_kern.c index db23ce1bd903..fe649d325b1f 100644 --- a/fs/hostfs/hostfs_kern.c +++ b/fs/hostfs/hostfs_kern.c | |||
| @@ -186,7 +186,7 @@ static struct inode *hostfs_iget(struct super_block *sb) | |||
| 186 | return inode; | 186 | return inode; |
| 187 | } | 187 | } |
| 188 | 188 | ||
| 189 | int hostfs_statfs(struct dentry *dentry, struct kstatfs *sf) | 189 | static int hostfs_statfs(struct dentry *dentry, struct kstatfs *sf) |
| 190 | { | 190 | { |
| 191 | /* | 191 | /* |
| 192 | * do_statfs uses struct statfs64 internally, but the linux kernel | 192 | * do_statfs uses struct statfs64 internally, but the linux kernel |
| @@ -268,7 +268,7 @@ static const struct super_operations hostfs_sbops = { | |||
| 268 | .show_options = hostfs_show_options, | 268 | .show_options = hostfs_show_options, |
| 269 | }; | 269 | }; |
| 270 | 270 | ||
| 271 | int hostfs_readdir(struct file *file, struct dir_context *ctx) | 271 | static int hostfs_readdir(struct file *file, struct dir_context *ctx) |
| 272 | { | 272 | { |
| 273 | void *dir; | 273 | void *dir; |
| 274 | char *name; | 274 | char *name; |
| @@ -293,7 +293,7 @@ int hostfs_readdir(struct file *file, struct dir_context *ctx) | |||
| 293 | return 0; | 293 | return 0; |
| 294 | } | 294 | } |
| 295 | 295 | ||
| 296 | int hostfs_file_open(struct inode *ino, struct file *file) | 296 | static int hostfs_file_open(struct inode *ino, struct file *file) |
| 297 | { | 297 | { |
| 298 | static DEFINE_MUTEX(open_mutex); | 298 | static DEFINE_MUTEX(open_mutex); |
| 299 | char *name; | 299 | char *name; |
| @@ -359,7 +359,8 @@ static int hostfs_file_release(struct inode *inode, struct file *file) | |||
| 359 | return 0; | 359 | return 0; |
| 360 | } | 360 | } |
| 361 | 361 | ||
| 362 | int hostfs_fsync(struct file *file, loff_t start, loff_t end, int datasync) | 362 | static int hostfs_fsync(struct file *file, loff_t start, loff_t end, |
| 363 | int datasync) | ||
| 363 | { | 364 | { |
| 364 | struct inode *inode = file->f_mapping->host; | 365 | struct inode *inode = file->f_mapping->host; |
| 365 | int ret; | 366 | int ret; |
| @@ -394,7 +395,7 @@ static const struct file_operations hostfs_dir_fops = { | |||
| 394 | .read = generic_read_dir, | 395 | .read = generic_read_dir, |
| 395 | }; | 396 | }; |
| 396 | 397 | ||
| 397 | int hostfs_writepage(struct page *page, struct writeback_control *wbc) | 398 | static int hostfs_writepage(struct page *page, struct writeback_control *wbc) |
| 398 | { | 399 | { |
| 399 | struct address_space *mapping = page->mapping; | 400 | struct address_space *mapping = page->mapping; |
| 400 | struct inode *inode = mapping->host; | 401 | struct inode *inode = mapping->host; |
| @@ -430,7 +431,7 @@ int hostfs_writepage(struct page *page, struct writeback_control *wbc) | |||
| 430 | return err; | 431 | return err; |
| 431 | } | 432 | } |
| 432 | 433 | ||
| 433 | int hostfs_readpage(struct file *file, struct page *page) | 434 | static int hostfs_readpage(struct file *file, struct page *page) |
| 434 | { | 435 | { |
| 435 | char *buffer; | 436 | char *buffer; |
| 436 | long long start; | 437 | long long start; |
| @@ -455,9 +456,9 @@ int hostfs_readpage(struct file *file, struct page *page) | |||
| 455 | return err; | 456 | return err; |
| 456 | } | 457 | } |
| 457 | 458 | ||
| 458 | int hostfs_write_begin(struct file *file, struct address_space *mapping, | 459 | static int hostfs_write_begin(struct file *file, struct address_space *mapping, |
| 459 | loff_t pos, unsigned len, unsigned flags, | 460 | loff_t pos, unsigned len, unsigned flags, |
| 460 | struct page **pagep, void **fsdata) | 461 | struct page **pagep, void **fsdata) |
| 461 | { | 462 | { |
| 462 | pgoff_t index = pos >> PAGE_CACHE_SHIFT; | 463 | pgoff_t index = pos >> PAGE_CACHE_SHIFT; |
| 463 | 464 | ||
| @@ -467,9 +468,9 @@ int hostfs_write_begin(struct file *file, struct address_space *mapping, | |||
| 467 | return 0; | 468 | return 0; |
| 468 | } | 469 | } |
| 469 | 470 | ||
| 470 | int hostfs_write_end(struct file *file, struct address_space *mapping, | 471 | static int hostfs_write_end(struct file *file, struct address_space *mapping, |
| 471 | loff_t pos, unsigned len, unsigned copied, | 472 | loff_t pos, unsigned len, unsigned copied, |
| 472 | struct page *page, void *fsdata) | 473 | struct page *page, void *fsdata) |
| 473 | { | 474 | { |
| 474 | struct inode *inode = mapping->host; | 475 | struct inode *inode = mapping->host; |
| 475 | void *buffer; | 476 | void *buffer; |
| @@ -549,8 +550,8 @@ static int read_name(struct inode *ino, char *name) | |||
| 549 | return 0; | 550 | return 0; |
| 550 | } | 551 | } |
| 551 | 552 | ||
| 552 | int hostfs_create(struct inode *dir, struct dentry *dentry, umode_t mode, | 553 | static int hostfs_create(struct inode *dir, struct dentry *dentry, umode_t mode, |
| 553 | bool excl) | 554 | bool excl) |
| 554 | { | 555 | { |
| 555 | struct inode *inode; | 556 | struct inode *inode; |
| 556 | char *name; | 557 | char *name; |
| @@ -591,8 +592,8 @@ int hostfs_create(struct inode *dir, struct dentry *dentry, umode_t mode, | |||
| 591 | return error; | 592 | return error; |
| 592 | } | 593 | } |
| 593 | 594 | ||
| 594 | struct dentry *hostfs_lookup(struct inode *ino, struct dentry *dentry, | 595 | static struct dentry *hostfs_lookup(struct inode *ino, struct dentry *dentry, |
| 595 | unsigned int flags) | 596 | unsigned int flags) |
| 596 | { | 597 | { |
| 597 | struct inode *inode; | 598 | struct inode *inode; |
| 598 | char *name; | 599 | char *name; |
| @@ -628,7 +629,8 @@ struct dentry *hostfs_lookup(struct inode *ino, struct dentry *dentry, | |||
| 628 | return ERR_PTR(err); | 629 | return ERR_PTR(err); |
| 629 | } | 630 | } |
| 630 | 631 | ||
| 631 | int hostfs_link(struct dentry *to, struct inode *ino, struct dentry *from) | 632 | static int hostfs_link(struct dentry *to, struct inode *ino, |
| 633 | struct dentry *from) | ||
| 632 | { | 634 | { |
| 633 | char *from_name, *to_name; | 635 | char *from_name, *to_name; |
| 634 | int err; | 636 | int err; |
| @@ -646,7 +648,7 @@ int hostfs_link(struct dentry *to, struct inode *ino, struct dentry *from) | |||
| 646 | return err; | 648 | return err; |
| 647 | } | 649 | } |
| 648 | 650 | ||
| 649 | int hostfs_unlink(struct inode *ino, struct dentry *dentry) | 651 | static int hostfs_unlink(struct inode *ino, struct dentry *dentry) |
| 650 | { | 652 | { |
| 651 | char *file; | 653 | char *file; |
| 652 | int err; | 654 | int err; |
| @@ -662,7 +664,8 @@ int hostfs_unlink(struct inode *ino, struct dentry *dentry) | |||
| 662 | return err; | 664 | return err; |
| 663 | } | 665 | } |
| 664 | 666 | ||
| 665 | int hostfs_symlink(struct inode *ino, struct dentry *dentry, const char *to) | 667 | static int hostfs_symlink(struct inode *ino, struct dentry *dentry, |
| 668 | const char *to) | ||
| 666 | { | 669 | { |
| 667 | char *file; | 670 | char *file; |
| 668 | int err; | 671 | int err; |
| @@ -674,7 +677,7 @@ int hostfs_symlink(struct inode *ino, struct dentry *dentry, const char *to) | |||
| 674 | return err; | 677 | return err; |
| 675 | } | 678 | } |
| 676 | 679 | ||
| 677 | int hostfs_mkdir(struct inode *ino, struct dentry *dentry, umode_t mode) | 680 | static int hostfs_mkdir(struct inode *ino, struct dentry *dentry, umode_t mode) |
| 678 | { | 681 | { |
| 679 | char *file; | 682 | char *file; |
| 680 | int err; | 683 | int err; |
| @@ -686,7 +689,7 @@ int hostfs_mkdir(struct inode *ino, struct dentry *dentry, umode_t mode) | |||
| 686 | return err; | 689 | return err; |
| 687 | } | 690 | } |
| 688 | 691 | ||
| 689 | int hostfs_rmdir(struct inode *ino, struct dentry *dentry) | 692 | static int hostfs_rmdir(struct inode *ino, struct dentry *dentry) |
| 690 | { | 693 | { |
| 691 | char *file; | 694 | char *file; |
| 692 | int err; | 695 | int err; |
| @@ -738,8 +741,8 @@ static int hostfs_mknod(struct inode *dir, struct dentry *dentry, umode_t mode, | |||
| 738 | return err; | 741 | return err; |
| 739 | } | 742 | } |
| 740 | 743 | ||
| 741 | int hostfs_rename(struct inode *from_ino, struct dentry *from, | 744 | static int hostfs_rename(struct inode *from_ino, struct dentry *from, |
| 742 | struct inode *to_ino, struct dentry *to) | 745 | struct inode *to_ino, struct dentry *to) |
| 743 | { | 746 | { |
| 744 | char *from_name, *to_name; | 747 | char *from_name, *to_name; |
| 745 | int err; | 748 | int err; |
| @@ -756,7 +759,7 @@ int hostfs_rename(struct inode *from_ino, struct dentry *from, | |||
| 756 | return err; | 759 | return err; |
| 757 | } | 760 | } |
| 758 | 761 | ||
| 759 | int hostfs_permission(struct inode *ino, int desired) | 762 | static int hostfs_permission(struct inode *ino, int desired) |
| 760 | { | 763 | { |
| 761 | char *name; | 764 | char *name; |
| 762 | int r = 0, w = 0, x = 0, err; | 765 | int r = 0, w = 0, x = 0, err; |
| @@ -782,7 +785,7 @@ int hostfs_permission(struct inode *ino, int desired) | |||
| 782 | return err; | 785 | return err; |
| 783 | } | 786 | } |
| 784 | 787 | ||
| 785 | int hostfs_setattr(struct dentry *dentry, struct iattr *attr) | 788 | static int hostfs_setattr(struct dentry *dentry, struct iattr *attr) |
| 786 | { | 789 | { |
| 787 | struct inode *inode = dentry->d_inode; | 790 | struct inode *inode = dentry->d_inode; |
| 788 | struct hostfs_iattr attrs; | 791 | struct hostfs_iattr attrs; |
