diff options
author | David S. Miller <davem@nuts.davemloft.net> | 2004-08-09 01:57:48 -0700 |
---|---|---|
committer | David S. Miller <davem@nuts.davemloft.net> | 2004-08-09 01:57:48 -0700 |
commit | ad2739b5d16a35e468f42aee26671c56de125018 (patch) | |
tree | abc4602e45c123a029a6e89ea1f1a5f49bfff0c2 /include | |
parent | 12cff028e892f21e6334b49f7903d0586d623daa (diff) | |
parent | 4a6d387e1576d261dc55ddf78f8a5d44b22a7965 (diff) | |
download | history-ad2739b5d16a35e468f42aee26671c56de125018.tar.gz |
Merge nuts.davemloft.net:/disk1/BK/sparcwork-2.6
into nuts.davemloft.net:/disk1/BK/sparc-2.6
Diffstat (limited to 'include')
-rw-r--r-- | include/asm-ia64/pgalloc.h | 20 | ||||
-rw-r--r-- | include/linux/coda_proc.h | 4 | ||||
-rw-r--r-- | include/linux/fs.h | 1 | ||||
-rw-r--r-- | include/linux/hugetlb.h | 2 | ||||
-rw-r--r-- | include/linux/mmzone.h | 4 | ||||
-rw-r--r-- | include/linux/sysctl.h | 18 | ||||
-rw-r--r-- | include/linux/writeback.h | 2 | ||||
-rw-r--r-- | include/net/ip.h | 2 | ||||
-rw-r--r-- | include/net/ndisc.h | 3 | ||||
-rw-r--r-- | include/scsi/scsi.h | 26 | ||||
-rw-r--r-- | include/scsi/sg.h | 2 |
11 files changed, 52 insertions, 32 deletions
diff --git a/include/asm-ia64/pgalloc.h b/include/asm-ia64/pgalloc.h index 68be9d57c7d076..973316828f028f 100644 --- a/include/asm-ia64/pgalloc.h +++ b/include/asm-ia64/pgalloc.h @@ -37,14 +37,20 @@ static inline pgd_t* pgd_alloc_one_fast (struct mm_struct *mm) { - unsigned long *ret = pgd_quicklist; + unsigned long *ret = NULL; + preempt_disable(); + + ret = pgd_quicklist; if (likely(ret != NULL)) { pgd_quicklist = (unsigned long *)(*ret); ret[0] = 0; --pgtable_cache_size; } else ret = NULL; + + preempt_enable(); + return (pgd_t *) ret; } @@ -65,9 +71,11 @@ pgd_alloc (struct mm_struct *mm) static inline void pgd_free (pgd_t *pgd) { + preempt_disable(); *(unsigned long *)pgd = (unsigned long) pgd_quicklist; pgd_quicklist = (unsigned long *) pgd; ++pgtable_cache_size; + preempt_enable(); } static inline void @@ -80,13 +88,19 @@ pgd_populate (struct mm_struct *mm, pgd_t *pgd_entry, pmd_t *pmd) static inline pmd_t* pmd_alloc_one_fast (struct mm_struct *mm, unsigned long addr) { - unsigned long *ret = (unsigned long *)pmd_quicklist; + unsigned long *ret = NULL; + preempt_disable(); + + ret = (unsigned long *)pmd_quicklist; if (likely(ret != NULL)) { pmd_quicklist = (unsigned long *)(*ret); ret[0] = 0; --pgtable_cache_size; } + + preempt_enable(); + return (pmd_t *)ret; } @@ -103,9 +117,11 @@ pmd_alloc_one (struct mm_struct *mm, unsigned long addr) static inline void pmd_free (pmd_t *pmd) { + preempt_disable(); *(unsigned long *)pmd = (unsigned long) pmd_quicklist; pmd_quicklist = (unsigned long *) pmd; ++pgtable_cache_size; + preempt_enable(); } #define __pmd_free_tlb(tlb, pmd) pmd_free(pmd) diff --git a/include/linux/coda_proc.h b/include/linux/coda_proc.h index 5bf75216379037..c061a22ed86d51 100644 --- a/include/linux/coda_proc.h +++ b/include/linux/coda_proc.h @@ -82,10 +82,10 @@ void reset_coda_cache_inv_stats( void ); * data structure for /proc/sys/... files */ int do_reset_coda_vfs_stats( ctl_table * table, int write, struct file * filp, - void __user * buffer, size_t * lenp ); + void __user * buffer, size_t * lenp, loff_t * ppos ); int do_reset_coda_cache_inv_stats( ctl_table * table, int write, struct file * filp, void __user * buffer, - size_t * lenp ); + size_t * lenp, loff_t * ppos ); /* these functions are called to form the content of /proc/fs/coda/... files */ int coda_vfs_stats_get_info( char * buffer, char ** start, off_t offset, diff --git a/include/linux/fs.h b/include/linux/fs.h index d352f867825898..e6f97b00fe34d5 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h @@ -1435,6 +1435,7 @@ extern loff_t no_llseek(struct file *file, loff_t offset, int origin); extern loff_t generic_file_llseek(struct file *file, loff_t offset, int origin); extern loff_t remote_llseek(struct file *file, loff_t offset, int origin); extern int generic_file_open(struct inode * inode, struct file * filp); +extern int nonseekable_open(struct inode * inode, struct file * filp); static inline void do_generic_file_read(struct file * filp, loff_t *ppos, read_descriptor_t * desc, diff --git a/include/linux/hugetlb.h b/include/linux/hugetlb.h index 5e578c036157af..954af9d82768c1 100644 --- a/include/linux/hugetlb.h +++ b/include/linux/hugetlb.h @@ -12,7 +12,7 @@ static inline int is_vm_hugetlb_page(struct vm_area_struct *vma) return vma->vm_flags & VM_HUGETLB; } -int hugetlb_sysctl_handler(struct ctl_table *, int, struct file *, void __user *, size_t *); +int hugetlb_sysctl_handler(struct ctl_table *, int, struct file *, void __user *, size_t *, loff_t *); int copy_hugetlb_page_range(struct mm_struct *, struct mm_struct *, struct vm_area_struct *); int follow_hugetlb_page(struct mm_struct *, struct vm_area_struct *, struct page **, struct vm_area_struct **, unsigned long *, int *, int); void zap_hugepage_range(struct vm_area_struct *, unsigned long, unsigned long); diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h index 8958b0e6af06d1..8a23709fe18a0e 100644 --- a/include/linux/mmzone.h +++ b/include/linux/mmzone.h @@ -374,9 +374,9 @@ static inline int is_normal(struct zone *zone) struct ctl_table; struct file; int min_free_kbytes_sysctl_handler(struct ctl_table *, int, struct file *, - void __user *, size_t *); + void __user *, size_t *, loff_t *); int lower_zone_protection_sysctl_handler(struct ctl_table *, int, struct file *, - void __user *, size_t *); + void __user *, size_t *, loff_t *); #include <linux/topology.h> /* Returns the number of the current Node. */ diff --git a/include/linux/sysctl.h b/include/linux/sysctl.h index 38acd5d4b69193..70ac59e6a41f11 100644 --- a/include/linux/sysctl.h +++ b/include/linux/sysctl.h @@ -762,24 +762,24 @@ typedef int ctl_handler (ctl_table *table, int __user *name, int nlen, void **context); typedef int proc_handler (ctl_table *ctl, int write, struct file * filp, - void __user *buffer, size_t *lenp); + void __user *buffer, size_t *lenp, loff_t *ppos); extern int proc_dostring(ctl_table *, int, struct file *, - void __user *, size_t *); + void __user *, size_t *, loff_t *); extern int proc_dointvec(ctl_table *, int, struct file *, - void __user *, size_t *); + void __user *, size_t *, loff_t *); extern int proc_dointvec_bset(ctl_table *, int, struct file *, - void __user *, size_t *); + void __user *, size_t *, loff_t *); extern int proc_dointvec_minmax(ctl_table *, int, struct file *, - void __user *, size_t *); + void __user *, size_t *, loff_t *); extern int proc_dointvec_jiffies(ctl_table *, int, struct file *, - void __user *, size_t *); + void __user *, size_t *, loff_t *); extern int proc_dointvec_userhz_jiffies(ctl_table *, int, struct file *, - void __user *, size_t *); + void __user *, size_t *, loff_t *); extern int proc_doulongvec_minmax(ctl_table *, int, struct file *, - void __user *, size_t *); + void __user *, size_t *, loff_t *); extern int proc_doulongvec_ms_jiffies_minmax(ctl_table *table, int, - struct file *, void __user *, size_t *); + struct file *, void __user *, size_t *, loff_t *); extern int do_sysctl (int __user *name, int nlen, void __user *oldval, size_t __user *oldlenp, diff --git a/include/linux/writeback.h b/include/linux/writeback.h index f557b55e8b0a8e..e4450070ac7852 100644 --- a/include/linux/writeback.h +++ b/include/linux/writeback.h @@ -86,7 +86,7 @@ extern int laptop_mode; struct ctl_table; struct file; int dirty_writeback_centisecs_handler(struct ctl_table *, int, struct file *, - void __user *, size_t *); + void __user *, size_t *, loff_t *); void page_writeback_init(void); void balance_dirty_pages_ratelimited(struct address_space *mapping); diff --git a/include/net/ip.h b/include/net/ip.h index 70bb6f887988a7..bacccde1c0788d 100644 --- a/include/net/ip.h +++ b/include/net/ip.h @@ -301,7 +301,7 @@ extern int ipv4_proc_init(void); */ int ipv4_doint_and_flush(ctl_table *ctl, int write, struct file* filp, void __user *buffer, - size_t *lenp); + size_t *lenp, loff_t *ppos); int ipv4_doint_and_flush_strategy(ctl_table *table, int __user *name, int nlen, void __user *oldval, size_t __user *oldlenp, void __user *newval, size_t newlen, diff --git a/include/net/ndisc.h b/include/net/ndisc.h index 95684d3363c1be..61d7033bca7fd8 100644 --- a/include/net/ndisc.h +++ b/include/net/ndisc.h @@ -103,7 +103,8 @@ extern int ndisc_ifinfo_sysctl_change(ctl_table *ctl, int write, struct file * filp, void __user *buffer, - size_t *lenp); + size_t *lenp, + loff_t *ppos); #endif extern void inet6_ifinfo_notify(int event, diff --git a/include/scsi/scsi.h b/include/scsi/scsi.h index ef5ef24cda1680..1c6d293846f069 100644 --- a/include/scsi/scsi.h +++ b/include/scsi/scsi.h @@ -214,25 +214,25 @@ static inline int scsi_status_is_good(int status) */ struct ccs_modesel_head { - u8 _r1; /* reserved */ - u8 medium; /* device-specific medium type */ - u8 _r2; /* reserved */ - u8 block_desc_length; /* block descriptor length */ - u8 density; /* device-specific density code */ - u8 number_blocks_hi; /* number of blocks in this block desc */ - u8 number_blocks_med; - u8 number_blocks_lo; - u8 _r3; - u8 block_length_hi; /* block length for blocks in this desc */ - u8 block_length_med; - u8 block_length_lo; + __u8 _r1; /* reserved */ + __u8 medium; /* device-specific medium type */ + __u8 _r2; /* reserved */ + __u8 block_desc_length; /* block descriptor length */ + __u8 density; /* device-specific density code */ + __u8 number_blocks_hi; /* number of blocks in this block desc */ + __u8 number_blocks_med; + __u8 number_blocks_lo; + __u8 _r3; + __u8 block_length_hi; /* block length for blocks in this desc */ + __u8 block_length_med; + __u8 block_length_lo; }; /* * ScsiLun: 8 byte LUN. */ struct scsi_lun { - u8 scsi_lun[8]; + __u8 scsi_lun[8]; }; /* diff --git a/include/scsi/sg.h b/include/scsi/sg.h index c8985dd1d4b2e7..0a487fe26d4fe1 100644 --- a/include/scsi/sg.h +++ b/include/scsi/sg.h @@ -1,6 +1,8 @@ #ifndef _SCSI_GENERIC_H #define _SCSI_GENERIC_H +#include <linux/compiler.h> + /* History: Started: Aug 9 by Lawrence Foard (entropy@world.std.com), to allow user |