summaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/affs_fs.h2
-rw-r--r--include/linux/blk.h16
-rw-r--r--include/linux/blkdev.h55
-rw-r--r--include/linux/devfs_fs_kernel.h15
-rw-r--r--include/linux/elevator.h114
-rw-r--r--include/linux/elf.h1
-rw-r--r--include/linux/elfcore.h1
-rw-r--r--include/linux/ext2_fs.h6
-rw-r--r--include/linux/fb.h2
-rw-r--r--include/linux/fs.h92
-rw-r--r--include/linux/gameport.h142
-rw-r--r--include/linux/input.h7
-rw-r--r--include/linux/irq.h1
-rw-r--r--include/linux/joystick.h169
-rw-r--r--include/linux/linkage.h2
-rw-r--r--include/linux/minix_fs.h2
-rw-r--r--include/linux/mm.h9
-rw-r--r--include/linux/mount.h1
-rw-r--r--include/linux/msdos_fs.h2
-rw-r--r--include/linux/ncp_fs_i.h3
-rw-r--r--include/linux/nfsd/syscall.h2
-rw-r--r--include/linux/pci_ids.h11
-rw-r--r--include/linux/poll.h1
-rw-r--r--include/linux/qnx4_fs.h2
-rw-r--r--include/linux/serio.h110
-rw-r--r--include/linux/swap.h14
-rw-r--r--include/linux/sysv_fs.h4
-rw-r--r--include/linux/timer.h7
-rw-r--r--include/linux/types.h3
-rw-r--r--include/linux/ufs_fs.h3
-rw-r--r--include/linux/umsdos_fs.p2
31 files changed, 454 insertions, 347 deletions
diff --git a/include/linux/affs_fs.h b/include/linux/affs_fs.h
index 8a09cd72d..60af0d40c 100644
--- a/include/linux/affs_fs.h
+++ b/include/linux/affs_fs.h
@@ -84,7 +84,7 @@ extern int affs_add_entry(struct inode *dir, struct inode *link,
extern void affs_put_inode(struct inode *inode);
extern void affs_delete_inode(struct inode *inode);
extern void affs_read_inode(struct inode *inode);
-extern void affs_write_inode(struct inode *inode, int);
+extern void affs_write_inode(struct inode *inode);
/* super.c */
diff --git a/include/linux/blk.h b/include/linux/blk.h
index 777469870..e8b5e5a85 100644
--- a/include/linux/blk.h
+++ b/include/linux/blk.h
@@ -14,13 +14,6 @@
extern spinlock_t io_request_lock;
/*
- * NR_REQUEST is the number of entries in the request-queue.
- * NOTE that writes may use only the low 2/3 of these: reads
- * take precedence.
- */
-#define NR_REQUEST 256
-
-/*
* Initialization functions.
*/
extern int isp16_init(void);
@@ -94,12 +87,9 @@ void initrd_init(void);
extern inline void blkdev_dequeue_request(struct request * req)
{
- if (req->q)
- {
- if (req->cmd == READ)
- req->q->elevator.read_pendings--;
- req->q->elevator.nr_segments -= req->nr_segments;
- req->q = NULL;
+ if (req->e) {
+ req->e->dequeue_fn(req);
+ req->e = NULL;
}
list_del(&req->queue);
}
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
index 371069369..5b62f88ad 100644
--- a/include/linux/blkdev.h
+++ b/include/linux/blkdev.h
@@ -9,6 +9,8 @@
struct request_queue;
typedef struct request_queue request_queue_t;
+struct elevator_s;
+typedef struct elevator_s elevator_t;
/*
* Ok, this is an expanded form so that we can use the same
@@ -19,7 +21,11 @@ typedef struct request_queue request_queue_t;
struct request {
struct list_head queue;
int elevator_sequence;
+ struct list_head table;
+ /*
+ * queue free list belongs to
+ */
volatile int rq_status; /* should split this into a few status bits */
#define RQ_INACTIVE (-1)
#define RQ_ACTIVE 1
@@ -41,7 +47,8 @@ struct request {
struct semaphore * sem;
struct buffer_head * bh;
struct buffer_head * bhtail;
- request_queue_t * q;
+ request_queue_t *q;
+ elevator_t *e;
};
#include <linux/elevator.h>
@@ -60,11 +67,25 @@ typedef int (make_request_fn) (request_queue_t *q, int rw, struct buffer_head *b
typedef void (plug_device_fn) (request_queue_t *q, kdev_t device);
typedef void (unplug_device_fn) (void *q);
+/*
+ * Default nr free requests per queue
+ */
+#define QUEUE_NR_REQUESTS 512
+#define QUEUE_WRITES_MAX ((2 * QUEUE_NR_REQUESTS) / 3)
+
struct request_queue
{
- struct list_head queue_head;
- /* together with queue_head for cacheline sharing */
- elevator_t elevator;
+ /*
+ * the queue request freelist, one for reads and one for writes
+ */
+ struct list_head request_freelist;
+ int queue_requests;
+
+ /*
+ * Together with queue_head for cacheline sharing
+ */
+ struct list_head queue_head;
+ elevator_t elevator;
request_fn_proc * request_fn;
merge_request_fn * back_merge_fn;
@@ -76,22 +97,34 @@ struct request_queue
* The queue owner gets to use this for whatever they like.
* ll_rw_blk doesn't touch it.
*/
- void * queuedata;
+ void * queuedata;
/*
* This is used to remove the plug when tq_disk runs.
*/
- struct tq_struct plug_tq;
+ struct tq_struct plug_tq;
+
/*
* Boolean that indicates whether this queue is plugged or not.
*/
- char plugged;
+ char plugged;
/*
* Boolean that indicates whether current_request is active or
* not.
*/
- char head_active;
+ char head_active;
+
+ /*
+ * Is meant to protect the queue in the future instead of
+ * io_request_lock
+ */
+ spinlock_t request_lock;
+
+ /*
+ * Tasks wait here for free request
+ */
+ wait_queue_head_t wait_for_request;
};
struct blk_dev_struct {
@@ -118,13 +151,13 @@ struct sec_size {
extern struct sec_size * blk_sec[MAX_BLKDEV];
extern struct blk_dev_struct blk_dev[MAX_BLKDEV];
-extern wait_queue_head_t wait_for_request;
extern void grok_partitions(struct gendisk *dev, int drive, unsigned minors, long size);
extern void register_disk(struct gendisk *dev, kdev_t first, unsigned minors, struct block_device_operations *ops, long size);
-extern void generic_unplug_device(void * data);
+extern void generic_unplug_device(void *data);
extern int generic_make_request(request_queue_t *q, int rw,
struct buffer_head * bh);
-extern request_queue_t * blk_get_queue(kdev_t dev);
+extern request_queue_t *blk_get_queue(kdev_t dev);
+extern void blkdev_release_request(struct request *);
/*
* Access functions for manipulating queue properties
diff --git a/include/linux/devfs_fs_kernel.h b/include/linux/devfs_fs_kernel.h
index b35fbe6e1..8173779f3 100644
--- a/include/linux/devfs_fs_kernel.h
+++ b/include/linux/devfs_fs_kernel.h
@@ -35,6 +35,7 @@
#define DEVFS_FL_REMOVABLE 0x020 /* This is a removable media device */
#define DEVFS_FL_WAIT 0x040 /* Wait for devfsd to finish */
#define DEVFS_FL_NO_PERSISTENCE 0x080 /* Forget changes after unregister */
+#define DEVFS_FL_CURRENT_OWNER 0x100 /* Set initial ownership to current */
#define DEVFS_FL_DEFAULT DEVFS_FL_NONE
@@ -52,12 +53,10 @@ typedef struct devfs_entry * devfs_handle_t;
#ifdef CONFIG_DEVFS_FS
-extern devfs_handle_t devfs_register (devfs_handle_t dir,
- const char *name, unsigned int namelen,
+extern devfs_handle_t devfs_register (devfs_handle_t dir, const char *name,
unsigned int flags,
unsigned int major, unsigned int minor,
- umode_t mode, uid_t uid, gid_t gid,
- void *ops, void *info);
+ umode_t mode, void *ops, void *info);
extern void devfs_unregister (devfs_handle_t de);
extern int devfs_mk_symlink (devfs_handle_t dir,
const char *name, unsigned int namelen,
@@ -98,8 +97,7 @@ extern void devfs_register_series (devfs_handle_t dir, const char *format,
unsigned int num_entries,
unsigned int flags, unsigned int major,
unsigned int minor_start,
- umode_t mode, uid_t uid, gid_t gid,
- void *ops, void *info);
+ umode_t mode, void *ops, void *info);
extern int init_devfs_fs (void);
extern void mount_devfs_fs (void);
@@ -107,12 +105,10 @@ extern void devfs_make_root (const char *name);
#else /* CONFIG_DEVFS_FS */
static inline devfs_handle_t devfs_register (devfs_handle_t dir,
const char *name,
- unsigned int namelen,
unsigned int flags,
unsigned int major,
unsigned int minor,
umode_t mode,
- uid_t uid, gid_t gid,
void *ops, void *info)
{
return NULL;
@@ -239,8 +235,7 @@ static inline void devfs_register_series (devfs_handle_t dir,
unsigned int flags,
unsigned int major,
unsigned int minor_start,
- umode_t mode, uid_t uid, gid_t gid,
- void *ops, void *info)
+ umode_t mode, void *ops, void *info)
{
return;
}
diff --git a/include/linux/elevator.h b/include/linux/elevator.h
index 988862534..b1f56316b 100644
--- a/include/linux/elevator.h
+++ b/include/linux/elevator.h
@@ -3,13 +3,15 @@
#define ELEVATOR_DEBUG
-struct elevator_s;
-typedef struct elevator_s elevator_t;
-
typedef void (elevator_fn) (struct request *, elevator_t *,
struct list_head *,
struct list_head *, int);
+typedef int (elevator_merge_fn) (request_queue_t *, struct request **,
+ struct buffer_head *, int, int *, int *);
+
+typedef void (elevator_dequeue_fn) (struct request *);
+
struct elevator_s
{
int sequence;
@@ -22,24 +24,20 @@ struct elevator_s
int read_pendings;
elevator_fn * elevator_fn;
+ elevator_merge_fn *elevator_merge_fn;
+ elevator_dequeue_fn *dequeue_fn;
unsigned int queue_ID;
};
-#define ELEVATOR_DEFAULTS \
-((elevator_t) { \
- 0, /* sequence */ \
- \
- 128, /* read_latency */ \
- 8192, /* write_latency */ \
- 32, /* max_bomb_segments */ \
- \
- 0, /* nr_segments */ \
- 0, /* read_pendings */ \
- \
- elevator_default, /* elevator_fn */ \
- })
-
+void elevator_default(struct request *, elevator_t *, struct list_head *, struct list_head *, int);
+int elevator_default_merge(request_queue_t *, struct request **, struct buffer_head *, int, int *, int *);
+void elevator_default_dequeue(struct request *);
+void elevator_noop(struct request *, elevator_t *, struct list_head *, struct list_head *, int);
+int elevator_noop_merge(request_queue_t *, struct request **, struct buffer_head *, int, int *, int *);
+void elevator_noop_dequeue(struct request *);
+void elevator_linus(struct request *, elevator_t *, struct list_head *, struct list_head *, int);
+int elevator_linus_merge(request_queue_t *, struct request **, struct buffer_head *, int, int *, int *);
typedef struct blkelv_ioctl_arg_s {
int queue_ID;
@@ -54,13 +52,12 @@ typedef struct blkelv_ioctl_arg_s {
extern int blkelvget_ioctl(elevator_t *, blkelv_ioctl_arg_t *);
extern int blkelvset_ioctl(elevator_t *, const blkelv_ioctl_arg_t *);
-
-extern void elevator_init(elevator_t *);
+extern void elevator_init(elevator_t *, elevator_t);
#ifdef ELEVATOR_DEBUG
-extern void elevator_debug(request_queue_t *, kdev_t);
+extern void elevator_default_debug(request_queue_t *, kdev_t);
#else
-#define elevator_debug(a,b) do { } while(0)
+#define elevator_default_debug(a,b) do { } while(0)
#endif
#define elevator_sequence_after(a,b) ((int)((b)-(a)) < 0)
@@ -69,6 +66,13 @@ extern void elevator_debug(request_queue_t *, kdev_t);
#define elevator_sequence_before_eq(a,b) elevator_sequence_after_eq(b,a)
/*
+ * Return values from elevator merger
+ */
+#define ELEVATOR_NO_MERGE 0
+#define ELEVATOR_FRONT_MERGE 1
+#define ELEVATOR_BACK_MERGE 2
+
+/*
* This is used in the elevator algorithm. We don't prioritise reads
* over writes any more --- although reads are more time-critical than
* writes, by treating them equally we increase filesystem throughput.
@@ -79,12 +83,12 @@ extern void elevator_debug(request_queue_t *, kdev_t);
(s1)->sector < (s2)->sector)) || \
(s1)->rq_dev < (s2)->rq_dev)
-static inline void elevator_merge_requests(elevator_t * e, struct request * req, struct request * next)
+static inline void elevator_merge_requests(struct request * req, struct request * next)
{
if (elevator_sequence_before(next->elevator_sequence, req->elevator_sequence))
req->elevator_sequence = next->elevator_sequence;
if (req->cmd == READ)
- e->read_pendings--;
+ req->e->read_pendings--;
}
@@ -93,23 +97,23 @@ static inline int elevator_sequence(elevator_t * e, int latency)
return latency + e->sequence;
}
-#define elevator_merge_before(q, req, lat) __elevator_merge((q), (req), (lat), 0)
-#define elevator_merge_after(q, req, lat) __elevator_merge((q), (req), (lat), 1)
-static inline void __elevator_merge(elevator_t * elevator, struct request * req, int latency, int after)
+#define elevator_merge_before(req, lat) __elevator_merge((req), (lat), 0)
+#define elevator_merge_after(req, lat) __elevator_merge((req), (lat), 1)
+static inline void __elevator_merge(struct request * req, int latency, int after)
{
- int sequence = elevator_sequence(elevator, latency);
+ int sequence = elevator_sequence(req->e, latency);
if (after)
sequence -= req->nr_segments;
if (elevator_sequence_before(sequence, req->elevator_sequence))
req->elevator_sequence = sequence;
}
-static inline void elevator_account_request(elevator_t * elevator, struct request * req)
+static inline void elevator_account_request(struct request * req)
{
- elevator->sequence++;
+ req->e->sequence++;
if (req->cmd == READ)
- elevator->read_pendings++;
- elevator->nr_segments++;
+ req->e->read_pendings++;
+ req->e->nr_segments++;
}
static inline int elevator_request_latency(elevator_t * elevator, int rw)
@@ -123,4 +127,52 @@ static inline int elevator_request_latency(elevator_t * elevator, int rw)
return latency;
}
+#define ELEVATOR_DEFAULT \
+((elevator_t) { \
+ 0, /* sequence */ \
+ \
+ 100000, /* read_latency */ \
+ 100000, /* write_latency */ \
+ 128, /* max_bomb_segments */ \
+ \
+ 0, /* nr_segments */ \
+ 0, /* read_pendings */ \
+ \
+ elevator_default, /* elevator_fn */ \
+ elevator_default_merge, /* elevator_merge_fn */ \
+ elevator_default_dequeue, /* dequeue_fn */ \
+ })
+
+#define ELEVATOR_NOOP \
+((elevator_t) { \
+ 0, /* sequence */ \
+ \
+ 0, /* read_latency */ \
+ 0, /* write_latency */ \
+ 0, /* max_bomb_segments */ \
+ \
+ 0, /* nr_segments */ \
+ 0, /* read_pendings */ \
+ \
+ elevator_noop, /* elevator_fn */ \
+ elevator_noop_merge, /* elevator_merge_fn */ \
+ elevator_noop_dequeue, /* dequeue_fn */ \
+ })
+
+#define ELEVATOR_LINUS \
+((elevator_t) { \
+ 0, /* not used */ \
+ \
+ 1000000, /* read passovers */ \
+ 2000000, /* write passovers */ \
+ 0, /* max_bomb_segments */ \
+ \
+ 0, /* not used */ \
+ 0, /* not used */ \
+ \
+ elevator_linus, /* elevator_fn */ \
+ elevator_linus_merge, /* elevator_merge_fn */ \
+ elevator_noop_dequeue, /* dequeue_fn */ \
+ })
+
#endif
diff --git a/include/linux/elf.h b/include/linux/elf.h
index 6f70727ab..f22e7387e 100644
--- a/include/linux/elf.h
+++ b/include/linux/elf.h
@@ -565,6 +565,7 @@ typedef struct elf64_shdr {
#define NT_PRFPREG 2
#define NT_PRPSINFO 3
#define NT_TASKSTRUCT 4
+#define NT_PRFPXREG 20
/* Note header in a PT_NOTE section */
typedef struct elf32_note {
diff --git a/include/linux/elfcore.h b/include/linux/elfcore.h
index 6dd1a31b2..3129abe82 100644
--- a/include/linux/elfcore.h
+++ b/include/linux/elfcore.h
@@ -20,6 +20,7 @@ struct elf_siginfo
typedef elf_greg_t greg_t;
typedef elf_gregset_t gregset_t;
typedef elf_fpregset_t fpregset_t;
+typedef elf_fpxregset_t fpxregset_t;
#define NGREG ELF_NGREG
#endif
diff --git a/include/linux/ext2_fs.h b/include/linux/ext2_fs.h
index 4bd6a5d72..25178b66b 100644
--- a/include/linux/ext2_fs.h
+++ b/include/linux/ext2_fs.h
@@ -548,9 +548,7 @@ extern int ext2_read (struct inode *, struct file *, char *, int);
extern int ext2_write (struct inode *, struct file *, char *, int);
/* fsync.c */
-extern int ext2_fsync_file (struct file *, struct dentry *, int);
-extern int ext2_fsync_inode (struct inode *, int);
-extern int ext2_osync_inode (struct inode *, int);
+extern int ext2_sync_file (struct file *, struct dentry *);
/* ialloc.c */
extern struct inode * ext2_new_inode (const struct inode *, int, int *);
@@ -564,7 +562,7 @@ extern struct buffer_head * ext2_getblk (struct inode *, long, int, int *);
extern struct buffer_head * ext2_bread (struct inode *, int, int, int *);
extern void ext2_read_inode (struct inode *);
-extern void ext2_write_inode (struct inode *, int);
+extern void ext2_write_inode (struct inode *);
extern void ext2_put_inode (struct inode *);
extern void ext2_delete_inode (struct inode *);
extern int ext2_sync_inode (struct inode *);
diff --git a/include/linux/fb.h b/include/linux/fb.h
index 4147f05ad..896dadef5 100644
--- a/include/linux/fb.h
+++ b/include/linux/fb.h
@@ -27,6 +27,8 @@
#define FBIOGET_VBLANK _IOR('F', 0x12, struct fb_vblank)
#define FBIO_ALLOC 0x4613
#define FBIO_FREE 0x4614
+#define FBIOGET_GLYPH 0x4615
+#define FBIOGET_HWCINFO 0x4616
#define FB_TYPE_PACKED_PIXELS 0 /* Packed Pixels */
#define FB_TYPE_PLANES 1 /* Non interleaved planes */
diff --git a/include/linux/fs.h b/include/linux/fs.h
index 3eafb9a55..8a1f8e9b6 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -47,12 +47,7 @@ struct poll_table_struct;
#define BLOCK_SIZE (1<<BLOCK_SIZE_BITS)
/* And dynamically-tunable limits and defaults: */
-struct files_stat_struct {
- int nr_files; /* read only */
- int nr_free_files; /* read only */
- int max_files; /* tunable */
-};
-extern struct files_stat_struct files_stat;
+extern int max_files, nr_files, nr_free_files;
extern int max_super_blocks, nr_super_blocks;
#define NR_FILE 8192 /* this can well be larger on a larger system */
@@ -241,9 +236,6 @@ struct buffer_head {
unsigned long b_rsector; /* Real buffer location on disk */
wait_queue_head_t b_wait;
struct kiobuf * b_kiobuf; /* kiobuf which owns this IO */
-
- struct inode * b_inode;
- struct list_head b_inode_buffers; /* doubly linked list of inode dirty buffers */
};
typedef void (bh_end_io_t)(struct buffer_head *bh, int uptodate);
@@ -383,8 +375,6 @@ struct inode {
struct list_head i_list;
struct list_head i_dentry;
- struct list_head i_dirty_buffers;
-
unsigned long i_ino;
atomic_t i_count;
kdev_t i_dev;
@@ -451,24 +441,16 @@ struct inode {
};
/* Inode state bits.. */
-#define I_DIRTY_SYNC 1 /* Not dirty enough for O_DATASYNC */
-#define I_DIRTY_DATASYNC 2 /* Data-related inode changes pending */
-#define I_LOCK 4
-#define I_FREEING 8
-#define I_CLEAR 16
+#define I_DIRTY 1
+#define I_LOCK 2
+#define I_FREEING 4
+#define I_CLEAR 8
-#define I_DIRTY (I_DIRTY_SYNC | I_DIRTY_DATASYNC)
-
-extern void __mark_inode_dirty(struct inode *, int);
+extern void __mark_inode_dirty(struct inode *);
static inline void mark_inode_dirty(struct inode *inode)
{
- if ((inode->i_state & I_DIRTY) != I_DIRTY)
- __mark_inode_dirty(inode, I_DIRTY);
-}
-static inline void mark_inode_dirty_sync(struct inode *inode)
-{
- if (!(inode->i_state & I_DIRTY_SYNC))
- __mark_inode_dirty(inode, I_DIRTY_SYNC);
+ if (!(inode->i_state & I_DIRTY))
+ __mark_inode_dirty(inode);
}
struct fown_struct {
@@ -522,8 +504,10 @@ typedef struct files_struct *fl_owner_t;
struct file_lock {
struct file_lock *fl_next; /* singly linked list for this inode */
- struct list_head fl_link; /* doubly linked list of all locks */
- struct list_head fl_block; /* circular list of blocked processes */
+ struct file_lock *fl_nextlink; /* doubly linked list of all locks */
+ struct file_lock *fl_prevlink; /* used to simplify lock removal */
+ struct file_lock *fl_nextblock; /* circular list of blocked processes */
+ struct file_lock *fl_prevblock;
fl_owner_t fl_owner;
unsigned int fl_pid;
wait_queue_head_t fl_wait;
@@ -548,7 +532,7 @@ struct file_lock {
#define OFFSET_MAX INT_LIMIT(loff_t)
#endif
-extern struct list_head file_lock_list;
+extern struct file_lock *file_lock_table;
#include <linux/fcntl.h>
@@ -737,7 +721,7 @@ struct file_operations {
int (*open) (struct inode *, struct file *);
int (*flush) (struct file *);
int (*release) (struct inode *, struct file *);
- int (*fsync) (struct file *, struct dentry *, int datasync);
+ int (*fsync) (struct file *, struct dentry *);
int (*fasync) (int, struct file *, int);
int (*lock) (struct file *, int, struct file_lock *);
ssize_t (*readv) (struct file *, const struct iovec *, unsigned long, loff_t *);
@@ -770,7 +754,7 @@ struct inode_operations {
*/
struct super_operations {
void (*read_inode) (struct inode *);
- void (*write_inode) (struct inode *, int);
+ void (*write_inode) (struct inode *);
void (*put_inode) (struct inode *);
void (*delete_inode) (struct inode *);
void (*put_super) (struct super_block *);
@@ -875,8 +859,8 @@ static inline int locks_verify_truncate(struct inode *inode,
return locks_mandatory_area(
FLOCK_VERIFY_WRITE, inode, filp,
size < inode->i_size ? size : inode->i_size,
- size < inode->i_size ? inode->i_size - size
- : size - inode->i_size);
+ abs(inode->i_size - size)
+ );
return 0;
}
@@ -997,44 +981,23 @@ static inline void buffer_IO_error(struct buffer_head * bh)
bh->b_end_io(bh, 0);
}
-extern void buffer_insert_inode_queue(struct buffer_head *, struct inode *);
-static inline void mark_buffer_dirty_inode(struct buffer_head *bh, int flag, struct inode *inode)
-{
- mark_buffer_dirty(bh, flag);
- buffer_insert_inode_queue(bh, inode);
-}
-
extern void balance_dirty(kdev_t);
extern int check_disk_change(kdev_t);
extern int invalidate_inodes(struct super_block *);
extern void invalidate_inode_pages(struct inode *);
-extern void invalidate_inode_buffers(struct inode *);
#define invalidate_buffers(dev) __invalidate_buffers((dev), 0)
#define destroy_buffers(dev) __invalidate_buffers((dev), 1)
extern void __invalidate_buffers(kdev_t dev, int);
extern void sync_inodes(kdev_t);
-extern void write_inode_now(struct inode *, int);
+extern void write_inode_now(struct inode *);
extern void sync_dev(kdev_t);
extern int fsync_dev(kdev_t);
-extern int fsync_inode_buffers(struct inode *);
-extern int osync_inode_buffers(struct inode *);
-extern int generic_osync_inode(struct inode *, int);
-extern int inode_has_buffers(struct inode *);
extern void sync_supers(kdev_t);
extern int bmap(struct inode *, int);
extern int notify_change(struct dentry *, struct iattr *);
extern int permission(struct inode *, int);
extern int get_write_access(struct inode *);
-extern int deny_write_access(struct file *);
-static inline void put_write_access(struct inode * inode)
-{
- atomic_dec(&inode->i_writecount);
-}
-static inline void allow_write_access(struct file *file)
-{
- if (file)
- atomic_inc(&file->f_dentry->d_inode->i_writecount);
-}
+extern void put_write_access(struct inode *);
extern int do_pipe(int *);
extern int open_namei(const char *, int, int, struct nameidata *);
@@ -1156,7 +1119,6 @@ typedef int (get_block_t)(struct inode*,long,struct buffer_head*,int);
/* Generic buffer handling for block filesystems.. */
extern int block_flushpage(struct page *, unsigned long);
-extern void block_destroy_buffers(struct page *);
extern int block_symlink(struct inode *, const char *, int);
extern int block_write_full_page(struct page*, get_block_t*);
extern int block_read_full_page(struct page*, get_block_t*);
@@ -1210,7 +1172,7 @@ extern int read_ahead[];
extern ssize_t char_write(struct file *, const char *, size_t, loff_t *);
extern ssize_t block_write(struct file *, const char *, size_t, loff_t *);
-extern int file_fsync(struct file *, struct dentry *, int);
+extern int file_fsync(struct file *, struct dentry *);
extern int generic_buffer_fdatasync(struct inode *inode, unsigned long start_idx, unsigned long end_idx);
extern int inode_change_ok(struct inode *, struct iattr *);
@@ -1224,6 +1186,20 @@ extern void inode_setattr(struct inode *, struct iattr *);
*/
/*
+ * We need to do a check-parent every time
+ * after we have locked the parent - to verify
+ * that the parent is still our parent and
+ * that we are still hashed onto it..
+ *
+ * This is required in case two processes race
+ * on removing (or moving) the same entry: the
+ * parent lock will serialize them, but the
+ * other process will be too late..
+ */
+#define check_parent(dir, dentry) \
+ ((dir) == (dentry)->d_parent && !d_unhashed(dentry))
+
+/*
* Locking the parent is needed to:
* - serialize directory operations
* - make sure the parent doesn't change from
diff --git a/include/linux/gameport.h b/include/linux/gameport.h
new file mode 100644
index 000000000..972dd0bfb
--- /dev/null
+++ b/include/linux/gameport.h
@@ -0,0 +1,142 @@
+#ifndef _GAMEPORT_H
+#define _GAMEPORT_H
+
+/*
+ * $Id: gameport.h,v 1.8 2000/06/03 20:18:52 vojtech Exp $
+ *
+ * Copyright (c) 1999-2000 Vojtech Pavlik
+ *
+ * Sponsored by SuSE
+ */
+
+/*
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Should you need to contact me, the author, you can do so either by
+ * e-mail - mail your message to <vojtech@ucw.cz>, or by paper mail:
+ * Vojtech Pavlik, Ucitelska 1576, Prague 8, 182 00 Czech Republic
+ */
+
+#include <asm/io.h>
+
+struct gameport;
+
+struct gameport {
+
+ void *private;
+ void *driver;
+
+ int number;
+
+ int io;
+ int size;
+ int speed;
+ int fuzz;
+ int type;
+ struct pci_dev *pci;
+
+ void (*trigger)(struct gameport *);
+ unsigned char (*read)(struct gameport *);
+ int (*cooked_read)(struct gameport *, int *, int *);
+ int (*calibrate)(struct gameport *, int *, int *);
+ int (*open)(struct gameport *, int);
+ void (*close)(struct gameport *);
+
+ struct gameport_dev *dev;
+
+ struct gameport *next;
+};
+
+struct gameport_dev {
+
+ void *private;
+
+ void (*connect)(struct gameport *, struct gameport_dev *dev);
+ void (*disconnect)(struct gameport *);
+
+ struct gameport_dev *next;
+};
+
+int gameport_open(struct gameport *gameport, struct gameport_dev *dev, int mode);
+void gameport_close(struct gameport *gameport);
+void gameport_rescan(struct gameport *gameport);
+
+void gameport_register_port(struct gameport *gameport);
+void gameport_unregister_port(struct gameport *gameport);
+void gameport_register_device(struct gameport_dev *dev);
+void gameport_unregister_device(struct gameport_dev *dev);
+
+#define GAMEPORT_MODE_DISABLED 0
+#define GAMEPORT_MODE_RAW 1
+#define GAMEPORT_MODE_COOKED 2
+
+#define GAMEPORT_ISA 0
+#define GAMEPORT_PNP 1
+#define GAMEPORT_EXT 2
+
+#define GAMEPORT_ID_VENDOR_ANALOG 0x0001
+#define GAMEPORT_ID_VENDOR_MADCATZ 0x0002
+#define GAMEPORT_ID_VENDOR_LOGITECH 0x0003
+#define GAMEPORT_ID_VENDOR_CREATIVE 0x0004
+#define GAMEPORT_ID_VENDOR_GENIUS 0x0005
+#define GAMEPORT_ID_VENDOR_INTERACT 0x0006
+#define GAMEPORT_ID_VENDOR_MICROSOFT 0x0007
+#define GAMEPORT_ID_VENDOR_THRUSTMASTER 0x0008
+#define GAMEPORT_ID_VENDOR_GRAVIS 0x0009
+
+static __inline__ void gameport_trigger(struct gameport *gameport)
+{
+ if (gameport->trigger)
+ gameport->trigger(gameport);
+ else
+ outb(0xff, gameport->io);
+}
+
+static __inline__ unsigned char gameport_read(struct gameport *gameport)
+{
+ if (gameport->read)
+ return gameport->read(gameport);
+ else
+ return inb(gameport->io);
+}
+
+static __inline__ int gameport_cooked_read(struct gameport *gameport, int *axes, int *buttons)
+{
+ if (gameport->cooked_read)
+ return gameport->cooked_read(gameport, axes, buttons);
+ else
+ return -1;
+}
+
+static __inline__ int gameport_calibrate(struct gameport *gameport, int *axes, int *max)
+{
+ if (gameport->calibrate)
+ return gameport->calibrate(gameport, axes, max);
+ else
+ return -1;
+}
+
+static __inline__ int gameport_time(struct gameport *gameport, int time)
+{
+ return (time * gameport->speed) / 1000;
+}
+
+static __inline__ void wait_ms(unsigned int ms)
+{
+ current->state = TASK_UNINTERRUPTIBLE;
+ schedule_timeout(1 + ms * HZ / 1000);
+}
+
+#endif
diff --git a/include/linux/input.h b/include/linux/input.h
index 6d19fc2a9..a44e6f8e1 100644
--- a/include/linux/input.h
+++ b/include/linux/input.h
@@ -2,7 +2,7 @@
#define _INPUT_H
/*
- * $Id: input.h,v 1.13 2000/05/29 10:54:53 vojtech Exp $
+ * $Id: input.h,v 1.14 2000/06/03 20:18:52 vojtech Exp $
*
* Copyright (c) 1999-2000 Vojtech Pavlik
*
@@ -359,8 +359,9 @@ struct input_event {
#define ABS_RZ 0x05
#define ABS_THROTTLE 0x06
#define ABS_RUDDER 0x07
-#define ABS_TL 0x08
-#define ABS_TR 0x09
+#define ABS_WHEEL 0x08
+#define ABS_GAS 0x09
+#define ABS_BRAKE 0x0a
#define ABS_HAT0X 0x10
#define ABS_HAT0Y 0x11
#define ABS_HAT1X 0x12
diff --git a/include/linux/irq.h b/include/linux/irq.h
index 69040207e..de2476503 100644
--- a/include/linux/irq.h
+++ b/include/linux/irq.h
@@ -18,6 +18,7 @@
#define IRQ_WAITING 32 /* IRQ not yet seen - for autodetection */
#define IRQ_LEVEL 64 /* IRQ level triggered */
#define IRQ_MASKED 128 /* IRQ masked - shouldn't be seen again */
+#define IRQ_PER_CPU 256 /* IRQ is per CPU */
/*
* Interrupt controller descriptor. This is all we need
diff --git a/include/linux/joystick.h b/include/linux/joystick.h
index c0e148171..1836aa95a 100644
--- a/include/linux/joystick.h
+++ b/include/linux/joystick.h
@@ -2,11 +2,11 @@
#define _LINUX_JOYSTICK_H
/*
- * /usr/include/linux/joystick.h Version 1.2
+ * $Id: joystick.h,v 1.2 2000/05/29 10:54:53 vojtech Exp $
*
- * Copyright (C) 1996-1999 Vojtech Pavlik
+ * Copyright (C) 1996-2000 Vojtech Pavlik
*
- * Sponsored by SuSE
+ * Sponsored by SuSE
*/
/*
@@ -30,13 +30,12 @@
*/
#include <asm/types.h>
-#include <linux/module.h>
/*
* Version
*/
-#define JS_VERSION 0x01020f
+#define JS_VERSION 0x020000
/*
* Types and constants for reading from /dev/js
@@ -120,164 +119,4 @@ struct JS_DATA_SAVE_TYPE {
struct JS_DATA_TYPE JS_CORR;
};
-/*
- * Internal definitions
- */
-
-#ifdef __KERNEL__
-
-#define JS_BUFF_SIZE 64 /* output buffer size */
-
-#include <linux/version.h>
-#include <linux/devfs_fs_kernel.h>
-
-#if LINUX_VERSION_CODE < KERNEL_VERSION(2,2,0)
-#error "You need to use at least v2.2 Linux kernel."
-#endif
-
-#if LINUX_VERSION_CODE < KERNEL_VERSION(2,3,0)
-#include <asm/spinlock.h>
-typedef struct wait_queue *wait_queue_head_t;
-#define __setup(a,b)
-#define BASE_ADDRESS(x,i) ((x)->base_address[i])
-#define DECLARE_WAITQUEUE(x,y) struct wait_queue x = { y, NULL }
-#define init_waitqueue_head(x) do { *(x) = NULL; } while (0)
-#define __set_current_state(x) current->state = x
-#define SETUP_PARAM char *str, int *ints
-#define SETUP_PARSE(x) do {} while (0)
-#else
-#include <linux/spinlock.h>
-#define BASE_ADDRESS(x,i) ((x)->resource[i].start)
-#define SETUP_PARAM char *str
-#define SETUP_PARSE(x) int ints[x]; get_options(str, x, ints)
-#endif
-
-#define PCI_VENDOR_ID_AUREAL 0x12eb
-
-/*
- * Parport stuff
- */
-
-#include <linux/parport.h>
-
-#define JS_PAR_STATUS_INVERT (0x80)
-#define JS_PAR_CTRL_INVERT (0x04)
-#define JS_PAR_DATA_IN(y) parport_read_data(y->port)
-#define JS_PAR_DATA_OUT(x,y) parport_write_data(y->port, x)
-#define JS_PAR_STATUS(y) parport_read_status(y->port)
-
-#ifndef PARPORT_NEED_GENERIC_OPS
-#define JS_PAR_CTRL_IN(y) parport_read_control(y->port)
-#else
-#define JS_PAR_CTRL_IN(y) inb(y->port->base+2)
-#endif
-
-#if LINUX_VERSION_CODE < KERNEL_VERSION(2,3,0)
-#define JS_PAR_CTRL_OUT(x,y) parport_write_control(y->port, x)
-#define JS_PAR_ECTRL_OUT(x,y) parport_write_econtrol(y->port, x)
-#else
-#define JS_PAR_CTRL_OUT(x,y) \
- do { \
- if ((x) & 0x20) parport_data_reverse(y->port); \
- else parport_data_forward(y->port); \
- parport_write_control(y->port, (x) & ~0x20); \
- } while (0)
-#define JS_PAR_ECTRL_OUT(x,y) /*parport sets PS/2 mode on ECR chips */
-#define PARPORT_MODE_PCPS2 PARPORT_MODE_TRISTATE
-#define PARPORT_MODE_PCECPPS2 PARPORT_MODE_TRISTATE
-#endif
-
-/*
- * Internal types
- */
-
-struct js_dev;
-
-typedef int (*js_read_func)(void *info, int **axes, int **buttons);
-typedef int (*js_ops_func)(struct js_dev *dev);
-
-struct js_data {
- int *axes;
- int *buttons;
-};
-
-struct js_dev {
- struct js_dev *next;
- struct js_list *list;
- struct js_port *port;
- wait_queue_head_t wait;
- struct js_data cur;
- struct js_data new;
- struct js_corr *corr;
- struct js_event buff[JS_BUFF_SIZE];
- js_ops_func open;
- js_ops_func close;
- int ahead;
- int bhead;
- int tail;
- int num_axes;
- int num_buttons;
- char *name;
- devfs_handle_t devfs_handle;
- struct module *owner;
-};
-
-struct js_list {
- struct js_list *next;
- struct js_dev *dev;
- int tail;
- int startup;
-};
-
-struct js_port {
- struct js_port *next;
- struct js_port *prev;
- js_read_func read;
- struct js_dev **devs;
- int **axes;
- int **buttons;
- struct js_corr **corr;
- void *info;
- int ndevs;
- int fail;
- int total;
-};
-
-/*
- * Sub-module interface
- */
-
-extern struct js_port *js_register_port(struct js_port *port, void *info,
- int devs, int infos, js_read_func read);
-extern struct js_port *js_unregister_port(struct js_port *port);
-
-extern int js_register_device(struct js_port *port, int number, int axes,
- int buttons, char *name, struct module *owner, js_ops_func open, js_ops_func close);
-extern void js_unregister_device(struct js_dev *dev);
-
-/*
- * Kernel interface
- */
-
-extern int js_init(void);
-extern int js_am_init(void);
-extern int js_an_init(void);
-extern int js_as_init(void);
-extern int js_console_init(void);
-extern int js_cr_init(void);
-extern int js_db9_init(void);
-extern int js_gr_init(void);
-extern int js_l4_init(void);
-extern int js_lt_init(void);
-extern int js_mag_init(void);
-extern int js_pci_init(void);
-extern int js_sw_init(void);
-extern int js_sball_init(void);
-extern int js_orb_init(void);
-extern int js_tm_init(void);
-extern int js_tg_init(void);
-extern int js_war_init(void);
-
-#endif /* __KERNEL__ */
-
#endif /* _LINUX_JOYSTICK_H */
diff --git a/include/linux/linkage.h b/include/linux/linkage.h
index d1f1c2861..aaf6edf02 100644
--- a/include/linux/linkage.h
+++ b/include/linux/linkage.h
@@ -9,7 +9,7 @@
#define CPP_ASMLINKAGE
#endif
-#if defined __i386__ && (__GNUC__ > 2 || __GNUC__ == 2 && __GNUC_MINOR__ > 7)
+#if defined __i386__ && (__GNUC__ > 2 || __GNUC_MINOR__ > 7)
#define asmlinkage CPP_ASMLINKAGE __attribute__((regparm(0)))
#elif defined __ia64__
#define asmlinkage CPP_ASMLINKAGE __attribute__((syscall_linkage))
diff --git a/include/linux/minix_fs.h b/include/linux/minix_fs.h
index 99cd63717..1eca767b4 100644
--- a/include/linux/minix_fs.h
+++ b/include/linux/minix_fs.h
@@ -101,7 +101,7 @@ extern struct buffer_head * minix_bread(struct inode *, int, int);
extern void minix_truncate(struct inode *);
extern int minix_sync_inode(struct inode *);
-extern int minix_sync_file(struct file *, struct dentry *, int);
+extern int minix_sync_file(struct file *, struct dentry *);
extern struct address_space_operations minix_aops;
extern struct inode_operations minix_file_inode_operations;
diff --git a/include/linux/mm.h b/include/linux/mm.h
index 5875fa8bf..37cb9664e 100644
--- a/include/linux/mm.h
+++ b/include/linux/mm.h
@@ -153,7 +153,6 @@ typedef struct page {
struct buffer_head * buffers;
unsigned long virtual; /* nonzero if kmapped */
struct zone_struct *zone;
- unsigned int age;
} mem_map_t;
#define get_page(p) atomic_inc(&(p)->count)
@@ -170,7 +169,7 @@ typedef struct page {
#define PG_dirty 4
#define PG_decr_after 5
#define PG_unused_01 6
-#define PG_active 7
+#define PG__unused_02 7
#define PG_slab 8
#define PG_swap_cache 9
#define PG_skip 10
@@ -186,7 +185,6 @@ typedef struct page {
#define ClearPageUptodate(page) clear_bit(PG_uptodate, &(page)->flags)
#define PageDirty(page) test_bit(PG_dirty, &(page)->flags)
#define SetPageDirty(page) set_bit(PG_dirty, &(page)->flags)
-#define ClearPageDirty(page) clear_bit(PG_dirty, &(page)->flags)
#define PageLocked(page) test_bit(PG_locked, &(page)->flags)
#define LockPage(page) set_bit(PG_locked, &(page)->flags)
#define TryLockPage(page) test_and_set_bit(PG_locked, &(page)->flags)
@@ -194,15 +192,11 @@ typedef struct page {
clear_bit(PG_locked, &(page)->flags); \
wake_up(&page->wait); \
} while (0)
-#define PageActive(page) test_bit(PG_active, &(page)->flags)
-#define SetPageActive(page) set_bit(PG_active, &(page)->flags)
-#define ClearPageActive(page) clear_bit(PG_active, &(page)->flags)
#define PageError(page) test_bit(PG_error, &(page)->flags)
#define SetPageError(page) set_bit(PG_error, &(page)->flags)
#define ClearPageError(page) clear_bit(PG_error, &(page)->flags)
#define PageReferenced(page) test_bit(PG_referenced, &(page)->flags)
#define SetPageReferenced(page) set_bit(PG_referenced, &(page)->flags)
-#define ClearPageReferenced(page) clear_bit(PG_referenced, &(page)->flags)
#define PageTestandClearReferenced(page) test_and_clear_bit(PG_referenced, &(page)->flags)
#define PageDecrAfter(page) test_bit(PG_decr_after, &(page)->flags)
#define SetPageDecrAfter(page) set_bit(PG_decr_after, &(page)->flags)
@@ -463,7 +457,6 @@ extern void remove_inode_page(struct page *);
extern unsigned long page_unuse(struct page *);
extern int shrink_mmap(int, int);
extern void truncate_inode_pages(struct address_space *, loff_t);
-extern void truncate_all_inode_pages(struct address_space *);
/* generic vm_area_ops exported for stackable file systems */
extern int filemap_swapout(struct page * page, struct file *file);
diff --git a/include/linux/mount.h b/include/linux/mount.h
index adb571de2..61ab19b1f 100644
--- a/include/linux/mount.h
+++ b/include/linux/mount.h
@@ -26,6 +26,7 @@ struct vfsmount
atomic_t mnt_count;
char *mnt_devname; /* Name of device e.g. /dev/dsk/hda1 */
+ char *mnt_dirname; /* Name of directory mounted on */
struct list_head mnt_list;
uid_t mnt_owner;
};
diff --git a/include/linux/msdos_fs.h b/include/linux/msdos_fs.h
index cbbf78528..4897f2ec9 100644
--- a/include/linux/msdos_fs.h
+++ b/include/linux/msdos_fs.h
@@ -248,7 +248,7 @@ extern struct inode *fat_build_inode(struct super_block*,struct msdos_dir_entry*
extern struct super_block *fat_read_super(struct super_block *s, void *data, int silent, struct inode_operations *dir_ops);
extern void msdos_put_super(struct super_block *sb);
extern int fat_statfs(struct super_block *sb,struct statfs *buf);
-extern void fat_write_inode(struct inode *inode, int);
+extern void fat_write_inode(struct inode *inode);
/* dir.c */
extern struct file_operations fat_dir_operations;
diff --git a/include/linux/ncp_fs_i.h b/include/linux/ncp_fs_i.h
index ffdf49f4c..96728bcdd 100644
--- a/include/linux/ncp_fs_i.h
+++ b/include/linux/ncp_fs_i.h
@@ -19,8 +19,7 @@ struct ncp_inode_info {
__u32 DosDirNum __attribute__((packed));
__u32 volNumber __attribute__((packed));
__u32 nwattr;
- struct semaphore open_sem;
- atomic_t opened;
+ int opened;
int access;
__u32 server_file_handle __attribute__((packed));
__u8 open_create_action __attribute__((packed));
diff --git a/include/linux/nfsd/syscall.h b/include/linux/nfsd/syscall.h
index 4f20ad01f..e98c9fa8a 100644
--- a/include/linux/nfsd/syscall.h
+++ b/include/linux/nfsd/syscall.h
@@ -133,7 +133,7 @@ union nfsctl_res {
* Kernel syscall implementation.
*/
#if defined(CONFIG_NFSD) || defined(CONFIG_NFSD_MODULE)
-extern asmlinkage int sys_nfsservctl(int, void *, void *);
+extern asmlinkage long sys_nfsservctl(int, void *, void *);
#else
#define sys_nfsservctl sys_ni_syscall
#endif
diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h
index 42a85261f..5512d2a51 100644
--- a/include/linux/pci_ids.h
+++ b/include/linux/pci_ids.h
@@ -330,11 +330,12 @@
#define PCI_DEVICE_ID_SI_6205 0x0205
#define PCI_DEVICE_ID_SI_501 0x0406
#define PCI_DEVICE_ID_SI_496 0x0496
+#define PCI_DEVICE_ID_SI_300 0x0300
#define PCI_DEVICE_ID_SI_530 0x0530
-#define PCI_DEVICE_ID_SI_540 0x0540
+#define PCI_DEVICE_ID_SI_540 0x5300
#define PCI_DEVICE_ID_SI_601 0x0601
#define PCI_DEVICE_ID_SI_620 0x0620
-#define PCI_DEVICE_ID_SI_630 0x0630
+#define PCI_DEVICE_ID_SI_630 0x6300
#define PCI_DEVICE_ID_SI_5107 0x5107
#define PCI_DEVICE_ID_SI_5511 0x5511
#define PCI_DEVICE_ID_SI_5513 0x5513
@@ -1201,7 +1202,6 @@
#define PCI_DEVICE_ID_INTEL_82443BX_0 0x7190
#define PCI_DEVICE_ID_INTEL_82443BX_1 0x7191
#define PCI_DEVICE_ID_INTEL_82443BX_2 0x7192
-#define PCI_DEVICE_ID_INTEL_82440MX_1 0x7194
#define PCI_DEVICE_ID_INTEL_82443MX_0 0x7198
#define PCI_DEVICE_ID_INTEL_82443MX_1 0x7199
#define PCI_DEVICE_ID_INTEL_82443MX_2 0x719a
@@ -1286,8 +1286,3 @@
#define PCI_DEVICE_ID_ARK_STING 0xa091
#define PCI_DEVICE_ID_ARK_STINGARK 0xa099
#define PCI_DEVICE_ID_ARK_2000MT 0xa0a1
-
-#define PCI_VENDOR_ID_SIS 0x1039
-#define PCI_DEVICE_ID_SIS_300 0x0300
-#define PCI_DEVICE_ID_SIS_540 0x5300
-#define PCI_DEVICE_ID_SIS_630 0x6300
diff --git a/include/linux/poll.h b/include/linux/poll.h
index b83e62d74..b56cdcf4c 100644
--- a/include/linux/poll.h
+++ b/include/linux/poll.h
@@ -20,7 +20,6 @@ struct poll_table_entry {
typedef struct poll_table_struct {
struct poll_table_struct * next;
unsigned int nr;
- int err;
struct poll_table_entry * entry;
} poll_table;
diff --git a/include/linux/qnx4_fs.h b/include/linux/qnx4_fs.h
index dd9b7cb6e..ad5ca5543 100644
--- a/include/linux/qnx4_fs.h
+++ b/include/linux/qnx4_fs.h
@@ -116,7 +116,7 @@ extern void qnx4_truncate(struct inode *inode);
extern void qnx4_free_inode(struct inode *inode);
extern int qnx4_unlink(struct inode *dir, struct dentry *dentry);
extern int qnx4_rmdir(struct inode *dir, struct dentry *dentry);
-extern int qnx4_sync_file(struct file *file, struct dentry *dentry, int);
+extern int qnx4_sync_file(struct file *file, struct dentry *dentry);
extern int qnx4_sync_inode(struct inode *inode);
extern int qnx4_get_block(struct inode *inode, long iblock, struct buffer_head *bh, int create);
diff --git a/include/linux/serio.h b/include/linux/serio.h
new file mode 100644
index 000000000..9cb8bb525
--- /dev/null
+++ b/include/linux/serio.h
@@ -0,0 +1,110 @@
+#ifndef _SERIO_H
+#define _SERIO_H
+
+/*
+ * $Id: serio.h,v 1.7 2000/06/01 11:39:46 vojtech Exp $
+ *
+ * Copyright (C) 1999 Vojtech Pavlik
+ *
+ * Sponsored by SuSE
+ */
+
+/*
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Should you need to contact me, the author, you can do so either by
+ * e-mail - mail your message to <vojtech@ucw.cz>, or by paper mail:
+ * Vojtech Pavlik, Ucitelska 1576, Prague 8, 182 00 Czech Republic
+ */
+
+/*
+ * The serial port set type ioctl.
+ */
+
+#include <linux/ioctl.h>
+#define SPIOCSTYPE _IOW('q', 0x01, unsigned long)
+
+struct serio;
+
+struct serio {
+
+ void *private;
+ void *driver;
+
+ unsigned long type;
+ int number;
+
+ int (*write)(struct serio *, unsigned char);
+ int (*open)(struct serio *);
+ void (*close)(struct serio *);
+
+ struct serio_dev *dev;
+
+ struct serio *next;
+};
+
+struct serio_dev {
+
+ void *private;
+
+ void (*interrupt)(struct serio *, unsigned char, unsigned int);
+ void (*connect)(struct serio *, struct serio_dev *dev);
+ void (*disconnect)(struct serio *);
+
+ struct serio_dev *next;
+};
+
+int serio_open(struct serio *serio, struct serio_dev *dev);
+void serio_close(struct serio *serio);
+void serio_rescan(struct serio *serio);
+
+void serio_register_port(struct serio *serio);
+void serio_unregister_port(struct serio *serio);
+void serio_register_device(struct serio_dev *dev);
+void serio_unregister_device(struct serio_dev *dev);
+
+static __inline__ int serio_write(struct serio *serio, unsigned char data)
+{
+ return serio->write(serio, data);
+}
+
+#define SERIO_TIMEOUT 1
+#define SERIO_PARITY 2
+
+#define SERIO_TYPE 0xff000000UL
+#define SERIO_XT 0x00000000UL
+#define SERIO_8042 0x01000000UL
+#define SERIO_RS232 0x02000000UL
+
+#define SERIO_PROTO 0xFFUL
+#define SERIO_MSC 0x01
+#define SERIO_SUN 0x02
+#define SERIO_MS 0x03
+#define SERIO_MP 0x04
+#define SERIO_MZ 0x05
+#define SERIO_MZP 0x06
+#define SERIO_MZPP 0x07
+#define SERIO_SUNKBD 0x10
+#define SERIO_WARRIOR 0x18
+#define SERIO_SPACEORB 0x19
+#define SERIO_MAGELLAN 0x1a
+#define SERIO_SPACEBALL 0x1b
+#define SERIO_GUNZE 0x1c
+#define SERIO_IFORCE 0x1d
+
+#define SERIO_ID 0xff00UL
+#define SERIO_EXTRA 0xff0000UL
+
+#endif
diff --git a/include/linux/swap.h b/include/linux/swap.h
index 5ee3b7b77..9226ce0a5 100644
--- a/include/linux/swap.h
+++ b/include/linux/swap.h
@@ -161,16 +161,6 @@ static inline int is_page_shared(struct page *page)
extern spinlock_t pagemap_lru_lock;
/*
- * Magic constants for page aging. If the system is programmed
- * right, tweaking these should have almost no effect...
- * The 2.4 code, however, is mostly simple and stable ;)
- */
-#define PG_AGE_MAX 64
-#define PG_AGE_START 2
-#define PG_AGE_ADV 3
-#define PG_AGE_DECL 1
-
-/*
* Helper macros for lru_pages handling.
*/
#define lru_cache_add(page) \
@@ -178,16 +168,12 @@ do { \
spin_lock(&pagemap_lru_lock); \
list_add(&(page)->lru, &lru_cache); \
nr_lru_pages++; \
- page->age = PG_AGE_START; \
- ClearPageReferenced(page); \
- SetPageActive(page); \
spin_unlock(&pagemap_lru_lock); \
} while (0)
#define __lru_cache_del(page) \
do { \
list_del(&(page)->lru); \
- ClearPageActive(page); \
nr_lru_pages--; \
} while (0)
diff --git a/include/linux/sysv_fs.h b/include/linux/sysv_fs.h
index 4cff4260c..d9c2557e5 100644
--- a/include/linux/sysv_fs.h
+++ b/include/linux/sysv_fs.h
@@ -377,9 +377,9 @@ extern unsigned long sysv_count_free_blocks(struct super_block *sb);
extern struct buffer_head * sysv_file_bread(struct inode *, int, int);
extern void sysv_truncate(struct inode *);
-extern void sysv_write_inode(struct inode *, int);
+extern void sysv_write_inode(struct inode *);
extern int sysv_sync_inode(struct inode *);
-extern int sysv_sync_file(struct file *, struct dentry *, int);
+extern int sysv_sync_file(struct file *, struct dentry *);
extern int sysv_notify_change(struct dentry *, struct iattr *);
extern struct inode_operations sysv_file_inode_operations;
diff --git a/include/linux/timer.h b/include/linux/timer.h
index 45887372a..2de8050ea 100644
--- a/include/linux/timer.h
+++ b/include/linux/timer.h
@@ -1,8 +1,6 @@
#ifndef _LINUX_TIMER_H
#define _LINUX_TIMER_H
-#ifdef __KERNEL__
-
#include <linux/config.h>
#include <linux/list.h>
@@ -93,11 +91,9 @@ extern int del_timer_sync(struct timer_list * timer);
#define timer_set_running(t) (void)(t)
#define timer_is_running(t) (0)
#define timer_synchronize(t) do { (void)(t); barrier(); } while(0)
-#define del_timer_sync del_timer
+#define del_timer_sync(t) del_timer(t)
#endif
-#define del_timer_async del_timer
-
/*
* These inlines deal with timer wrapping correctly. You are
* strongly encouraged to use them
@@ -116,4 +112,3 @@ extern int del_timer_sync(struct timer_list * timer);
#define time_before_eq(a,b) time_after_eq(b,a)
#endif
-#endif
diff --git a/include/linux/types.h b/include/linux/types.h
index df4808fcd..196c5f4e0 100644
--- a/include/linux/types.h
+++ b/include/linux/types.h
@@ -1,10 +1,7 @@
#ifndef _LINUX_TYPES_H
#define _LINUX_TYPES_H
-#ifdef __KERNEL__
#include <linux/config.h>
-#endif
-
#include <linux/posix_types.h>
#include <asm/types.h>
diff --git a/include/linux/ufs_fs.h b/include/linux/ufs_fs.h
index 3c8f1d415..96cb38e67 100644
--- a/include/linux/ufs_fs.h
+++ b/include/linux/ufs_fs.h
@@ -560,8 +560,9 @@ extern struct inode * ufs_new_inode (const struct inode *, int, int *);
extern int ufs_frag_map (struct inode *, int);
extern void ufs_read_inode (struct inode *);
extern void ufs_put_inode (struct inode *);
-extern void ufs_write_inode (struct inode *, int);
+extern void ufs_write_inode (struct inode *);
extern int ufs_sync_inode (struct inode *);
+extern void ufs_write_inode (struct inode *);
extern void ufs_delete_inode (struct inode *);
extern struct buffer_head * ufs_getfrag (struct inode *, unsigned, int, int *);
extern struct buffer_head * ufs_bread (struct inode *, unsigned, int, int *);
diff --git a/include/linux/umsdos_fs.p b/include/linux/umsdos_fs.p
index 677bee22e..76436a479 100644
--- a/include/linux/umsdos_fs.p
+++ b/include/linux/umsdos_fs.p
@@ -48,7 +48,7 @@ int umsdos_isempty (struct dentry *);
/* inode.c 12/06/95 09.49.40 */
void fill_new_filp (struct file *filp, struct dentry *dentry);
void UMSDOS_read_inode (struct inode *);
-void UMSDOS_write_inode (struct inode *, int);
+void UMSDOS_write_inode (struct inode *);
int UMSDOS_notify_change (struct dentry *, struct iattr *attr);
int umsdos_notify_change_locked(struct dentry *, struct iattr *attr);
void UMSDOS_put_inode (struct inode *);