Index: drivers/block/loop.c
===================================================================
RCS file: /var/cvs/linux-2.6/drivers/block/loop.c,v
retrieving revision 1.4
diff -u -p -r1.4 loop.c
--- drivers/block/loop.c	28 Sep 2003 04:05:15 -0000	1.4
+++ drivers/block/loop.c	31 Oct 2003 12:45:20 -0000
@@ -176,7 +176,7 @@ do_lo_send(struct loop_device *lo, struc
 {
 	struct file *file = lo->lo_backing_file; /* kudos to NFsckingS */
 	struct address_space *mapping = file->f_dentry->d_inode->i_mapping;
-	struct address_space_operations *aops = mapping->a_ops;
+	const struct address_space_operations *aops = mapping->a_ops;
 	struct page *page;
 	char *kaddr, *data;
 	pgoff_t index;
@@ -692,7 +692,8 @@ static int loop_set_fd(struct loop_devic
 		if (bdev_read_only(lo_device))
 			lo_flags |= LO_FLAGS_READ_ONLY;
 	} else if (S_ISREG(inode->i_mode)) {
-		struct address_space_operations *aops = inode->i_mapping->a_ops;
+		const struct address_space_operations *aops =
+				inode->i_mapping->a_ops;
 		/*
 		 * If we can't read - sorry. If we only can't write - well,
 		 * it's going to be read-only.
Index: drivers/input/input.c
===================================================================
RCS file: /var/cvs/linux-2.6/drivers/input/input.c,v
retrieving revision 1.4
diff -u -p -r1.4 input.c
--- drivers/input/input.c	28 Sep 2003 04:05:24 -0000	1.4
+++ drivers/input/input.c	31 Oct 2003 12:46:31 -0000
@@ -542,7 +542,7 @@ void input_unregister_handler(struct inp
 static int input_open_file(struct inode *inode, struct file *file)
 {
 	struct input_handler *handler = input_table[iminor(inode) >> 5];
-	struct file_operations *old_fops, *new_fops = NULL;
+	const struct file_operations *old_fops, *new_fops = NULL;
 	int err;
 
 	/* No load-on-demand here? */
Index: drivers/usb/core/file.c
===================================================================
RCS file: /var/cvs/linux-2.6/drivers/usb/core/file.c,v
retrieving revision 1.5
diff -u -p -r1.5 file.c
--- drivers/usb/core/file.c	8 Oct 2003 20:52:39 -0000	1.5
+++ drivers/usb/core/file.c	31 Oct 2003 12:50:08 -0000
@@ -37,7 +37,7 @@ static int usb_open(struct inode * inode
 	int minor = iminor(inode);
 	struct file_operations *c;
 	int err = -ENODEV;
-	struct file_operations *old_fops, *new_fops = NULL;
+	const struct file_operations *old_fops, *new_fops = NULL;
 
 	spin_lock (&minor_lock);
 	c = usb_minors[minor];
Index: fs/block_dev.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/block_dev.c,v
retrieving revision 1.5
diff -u -p -r1.5 block_dev.c
--- fs/block_dev.c	8 Oct 2003 20:52:41 -0000	1.5
+++ fs/block_dev.c	30 Oct 2003 22:55:25 -0000
@@ -264,7 +264,7 @@ static void bdev_clear_inode(struct inod
 	spin_unlock(&bdev_lock);
 }
 
-static struct super_operations bdev_sops = {
+static const struct super_operations bdev_sops = {
 	.statfs = simple_statfs,
 	.alloc_inode = bdev_alloc_inode,
 	.destroy_inode = bdev_destroy_inode,
@@ -499,7 +499,7 @@ EXPORT_SYMBOL(open_by_devnum);
 int check_disk_change(struct block_device *bdev)
 {
 	struct gendisk *disk = bdev->bd_disk;
-	struct block_device_operations * bdops = disk->fops;
+	const struct block_device_operations * bdops = disk->fops;
 
 	if (!bdops->media_changed)
 		return 0;
@@ -758,7 +758,7 @@ static ssize_t blkdev_file_aio_write(str
 }
 
 
-struct address_space_operations def_blk_aops = {
+const struct address_space_operations def_blk_aops = {
 	.readpage	= blkdev_readpage,
 	.writepage	= blkdev_writepage,
 	.sync_page	= block_sync_page,
@@ -768,7 +768,7 @@ struct address_space_operations def_blk_
 	.direct_IO	= blkdev_direct_IO,
 };
 
-struct file_operations def_blk_fops = {
+const struct file_operations def_blk_fops = {
 	.open		= blkdev_open,
 	.release	= blkdev_close,
 	.llseek		= block_llseek,
Index: fs/buffer.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/buffer.c,v
retrieving revision 1.4
diff -u -p -r1.4 buffer.c
--- fs/buffer.c	8 Oct 2003 20:52:41 -0000	1.4
+++ fs/buffer.c	30 Oct 2003 22:48:47 -0000
@@ -2479,7 +2479,7 @@ int nobh_truncate_page(struct address_sp
 	unsigned offset = from & (PAGE_CACHE_SIZE-1);
 	unsigned to;
 	struct page *page;
-	struct address_space_operations *a_ops = mapping->a_ops;
+	const struct address_space_operations *a_ops = mapping->a_ops;
 	char *kaddr;
 	int ret = 0;
 
Index: fs/char_dev.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/char_dev.c,v
retrieving revision 1.4
diff -u -p -r1.4 char_dev.c
--- fs/char_dev.c	28 Sep 2003 04:05:59 -0000	1.4
+++ fs/char_dev.c	30 Oct 2003 22:51:52 -0000
@@ -36,7 +36,7 @@ static struct char_device_struct {
 	unsigned int baseminor;
 	int minorct;
 	const char *name;
-	struct file_operations *fops;
+	const struct file_operations *fops;
 	struct cdev *cdev;		/* will die */
 } *chrdevs[MAX_PROBE_HASH];
 
@@ -189,7 +189,7 @@ int alloc_chrdev_region(dev_t *dev, unsi
 }
 
 int register_chrdev(unsigned int major, const char *name,
-		    struct file_operations *fops)
+		    const struct file_operations *fops)
 {
 	struct char_device_struct *cd;
 	struct cdev *cdev;
@@ -323,7 +323,7 @@ void cdev_purge(struct cdev *cdev)
  * is contain the open that then fills in the correct operations
  * depending on the special file...
  */
-struct file_operations def_chr_fops = {
+const struct file_operations def_chr_fops = {
 	.open = chrdev_open,
 };
 
@@ -423,7 +423,7 @@ struct cdev *cdev_alloc(void)
 	return p;
 }
 
-void cdev_init(struct cdev *cdev, struct file_operations *fops)
+void cdev_init(struct cdev *cdev, const struct file_operations *fops)
 {
 	INIT_LIST_HEAD(&cdev->list);
 	kobj_set_kset_s(cdev, cdev_subsys);
Index: fs/fifo.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/fifo.c,v
retrieving revision 1.1
diff -u -p -r1.1 fifo.c
--- fs/fifo.c	29 Jul 2003 17:01:37 -0000	1.1
+++ fs/fifo.c	30 Oct 2003 22:57:41 -0000
@@ -151,6 +151,6 @@ err_nolock_nocleanup:
  * is contain the open that then fills in the correct operations
  * depending on the access mode of the file...
  */
-struct file_operations def_fifo_fops = {
+const struct file_operations def_fifo_fops = {
 	.open		= fifo_open,	/* will set read or write pipe_fops */
 };
Index: fs/inode.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/inode.c,v
retrieving revision 1.6
diff -u -p -r1.6 inode.c
--- fs/inode.c	18 Oct 2003 00:23:19 -0000	1.6
+++ fs/inode.c	30 Oct 2003 22:49:37 -0000
@@ -981,7 +981,7 @@ EXPORT_SYMBOL(remove_inode_hash);
  */
 void generic_delete_inode(struct inode *inode)
 {
-	struct super_operations *op = inode->i_sb->s_op;
+	const struct super_operations *op = inode->i_sb->s_op;
 
 	list_del_init(&inode->i_list);
 	inode->i_state|=I_FREEING;
@@ -1066,7 +1066,7 @@ static void generic_drop_inode(struct in
  */
 static inline void iput_final(struct inode *inode)
 {
-	struct super_operations *op = inode->i_sb->s_op;
+	const struct super_operations *op = inode->i_sb->s_op;
 	void (*drop)(struct inode *) = generic_drop_inode;
 
 	if (op && op->drop_inode)
@@ -1084,7 +1084,7 @@ static inline void iput_final(struct ino
 void iput(struct inode *inode)
 {
 	if (inode) {
-		struct super_operations *op = inode->i_sb->s_op;
+		const struct super_operations *op = inode->i_sb->s_op;
 
 		if (inode->i_state == I_CLEAR)
 			BUG();
Index: fs/libfs.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/libfs.c,v
retrieving revision 1.5
diff -u -p -r1.5 libfs.c
--- fs/libfs.c	26 Oct 2003 15:16:58 -0000	1.5
+++ fs/libfs.c	30 Oct 2003 22:58:40 -0000
@@ -163,7 +163,7 @@ ssize_t generic_read_dir(struct file *fi
 	return -EISDIR;
 }
 
-struct file_operations simple_dir_operations = {
+const struct file_operations simple_dir_operations = {
 	.open		= dcache_dir_open,
 	.release	= dcache_dir_close,
 	.llseek		= dcache_dir_lseek,
@@ -171,7 +171,7 @@ struct file_operations simple_dir_operat
 	.readdir	= dcache_readdir,
 };
 
-struct inode_operations simple_dir_inode_operations = {
+const struct inode_operations simple_dir_inode_operations = {
 	.lookup		= simple_lookup,
 };
 
@@ -181,7 +181,7 @@ struct inode_operations simple_dir_inode
  */
 struct super_block *
 get_sb_pseudo(struct file_system_type *fs_type, char *name,
-	struct super_operations *ops, unsigned long magic)
+	const struct super_operations *ops, unsigned long magic)
 {
 	struct super_block *s = sget(fs_type, NULL, set_anon_super, NULL);
 	static struct super_operations default_ops = {.statfs = simple_statfs};
Index: fs/namei.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/namei.c,v
retrieving revision 1.5
diff -u -p -r1.5 namei.c
--- fs/namei.c	8 Oct 2003 20:52:42 -0000	1.5
+++ fs/namei.c	30 Oct 2003 22:57:16 -0000
@@ -2273,7 +2273,7 @@ fail:
 	return err;
 }
 
-struct inode_operations page_symlink_inode_operations = {
+const struct inode_operations page_symlink_inode_operations = {
 	.readlink	= page_readlink,
 	.follow_link	= page_follow_link,
 };
Index: fs/pipe.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/pipe.c,v
retrieving revision 1.3
diff -u -p -r1.3 pipe.c
--- fs/pipe.c	8 Oct 2003 20:52:42 -0000	1.3
+++ fs/pipe.c	30 Oct 2003 22:56:49 -0000
@@ -402,7 +402,7 @@ pipe_rdwr_open(struct inode *inode, stru
  * The file_operations structs are not static because they
  * are also used in linux/fs/fifo.c to do operations on FIFOs.
  */
-struct file_operations read_fifo_fops = {
+const struct file_operations read_fifo_fops = {
 	.llseek		= no_llseek,
 	.read		= pipe_read,
 	.write		= bad_pipe_w,
@@ -413,7 +413,7 @@ struct file_operations read_fifo_fops = 
 	.fasync		= pipe_read_fasync,
 };
 
-struct file_operations write_fifo_fops = {
+const struct file_operations write_fifo_fops = {
 	.llseek		= no_llseek,
 	.read		= bad_pipe_r,
 	.write		= pipe_write,
@@ -424,7 +424,7 @@ struct file_operations write_fifo_fops =
 	.fasync		= pipe_write_fasync,
 };
 
-struct file_operations rdwr_fifo_fops = {
+const struct file_operations rdwr_fifo_fops = {
 	.llseek		= no_llseek,
 	.read		= pipe_read,
 	.write		= pipe_write,
@@ -435,7 +435,7 @@ struct file_operations rdwr_fifo_fops = 
 	.fasync		= pipe_rdwr_fasync,
 };
 
-struct file_operations read_pipe_fops = {
+const struct file_operations read_pipe_fops = {
 	.llseek		= no_llseek,
 	.read		= pipe_read,
 	.write		= bad_pipe_w,
@@ -446,7 +446,7 @@ struct file_operations read_pipe_fops = 
 	.fasync		= pipe_read_fasync,
 };
 
-struct file_operations write_pipe_fops = {
+const struct file_operations write_pipe_fops = {
 	.llseek		= no_llseek,
 	.read		= bad_pipe_r,
 	.write		= pipe_write,
@@ -457,7 +457,7 @@ struct file_operations write_pipe_fops =
 	.fasync		= pipe_write_fasync,
 };
 
-struct file_operations rdwr_pipe_fops = {
+const struct file_operations rdwr_pipe_fops = {
 	.llseek		= no_llseek,
 	.read		= pipe_read,
 	.write		= pipe_write,
Index: fs/read_write.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/read_write.c,v
retrieving revision 1.2
diff -u -p -r1.2 read_write.c
--- fs/read_write.c	8 Oct 2003 20:52:42 -0000	1.2
+++ fs/read_write.c	30 Oct 2003 22:54:29 -0000
@@ -16,7 +16,7 @@
 
 #include <asm/uaccess.h>
 
-struct file_operations generic_ro_fops = {
+const struct file_operations generic_ro_fops = {
 	.llseek		= generic_file_llseek,
 	.read		= generic_file_read,
 	.mmap		= generic_file_readonly_mmap,
Index: fs/select.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/select.c,v
retrieving revision 1.2
diff -u -p -r1.2 select.c
--- fs/select.c	8 Oct 2003 20:52:42 -0000	1.2
+++ fs/select.c	30 Oct 2003 22:49:51 -0000
@@ -208,7 +208,7 @@ int do_select(int n, fd_set_bits *fds, l
 		for (i = 0; i < n; ++rinp, ++routp, ++rexp) {
 			unsigned long in, out, ex, all_bits, bit = 1, mask, j;
 			unsigned long res_in = 0, res_out = 0, res_ex = 0;
-			struct file_operations *f_op = NULL;
+			const struct file_operations *f_op = NULL;
 			struct file *file = NULL;
 
 			in = *inp++; out = *outp++; ex = *exp++;
Index: fs/super.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/super.c,v
retrieving revision 1.4
diff -u -p -r1.4 super.c
--- fs/super.c	8 Oct 2003 20:52:42 -0000	1.4
+++ fs/super.c	30 Oct 2003 22:50:14 -0000
@@ -52,7 +52,7 @@ spinlock_t sb_lock = SPIN_LOCK_UNLOCKED;
 static struct super_block *alloc_super(void)
 {
 	struct super_block *s = kmalloc(sizeof(struct super_block),  GFP_USER);
-	static struct super_operations default_op;
+	const static struct super_operations default_op;
 
 	if (s) {
 		memset(s, 0, sizeof(struct super_block));
@@ -182,7 +182,7 @@ static int grab_super(struct super_block
 void generic_shutdown_super(struct super_block *sb)
 {
 	struct dentry *root = sb->s_root;
-	struct super_operations *sop = sb->s_op;
+	const struct super_operations *sop = sb->s_op;
 
 	if (root) {
 		sb->s_root = NULL;
Index: fs/exportfs/expfs.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/exportfs/expfs.c,v
retrieving revision 1.1
diff -u -p -r1.1 expfs.c
--- fs/exportfs/expfs.c	29 Jul 2003 17:01:40 -0000	1.1
+++ fs/exportfs/expfs.c	30 Oct 2003 23:01:09 -0000
@@ -50,7 +50,7 @@ find_exported_dentry(struct super_block 
 	struct dentry *result = NULL;
 	struct dentry *target_dir;
 	int err;
-	struct export_operations *nops = sb->s_export_op;
+	const struct export_operations *nops = sb->s_export_op;
 	struct list_head *le, *head;
 	struct dentry *toput = NULL;
 	int noprogress;
Index: fs/ext2/dir.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/ext2/dir.c,v
retrieving revision 1.1
diff -u -p -r1.1 dir.c
--- fs/ext2/dir.c	29 Jul 2003 17:01:40 -0000	1.1
+++ fs/ext2/dir.c	30 Oct 2003 23:12:17 -0000
@@ -656,7 +656,7 @@ not_empty:
 	return 0;
 }
 
-struct file_operations ext2_dir_operations = {
+const struct file_operations ext2_dir_operations = {
 	.llseek		= generic_file_llseek,
 	.read		= generic_read_dir,
 	.readdir	= ext2_readdir,
Index: fs/ext2/ext2.h
===================================================================
RCS file: /var/cvs/linux-2.6/fs/ext2/ext2.h,v
retrieving revision 1.1
diff -u -p -r1.1 ext2.h
--- fs/ext2/ext2.h	29 Jul 2003 17:01:40 -0000	1.1
+++ fs/ext2/ext2.h	30 Oct 2003 23:11:59 -0000
@@ -144,20 +144,20 @@ extern void ext2_write_super (struct sup
  */
 
 /* dir.c */
-extern struct file_operations ext2_dir_operations;
+extern const struct file_operations ext2_dir_operations;
 
 /* file.c */
-extern struct inode_operations ext2_file_inode_operations;
-extern struct file_operations ext2_file_operations;
+extern const struct inode_operations ext2_file_inode_operations;
+extern const struct file_operations ext2_file_operations;
 
 /* inode.c */
-extern struct address_space_operations ext2_aops;
-extern struct address_space_operations ext2_nobh_aops;
+extern const struct address_space_operations ext2_aops;
+extern const struct address_space_operations ext2_nobh_aops;
 
 /* namei.c */
-extern struct inode_operations ext2_dir_inode_operations;
-extern struct inode_operations ext2_special_inode_operations;
+extern const struct inode_operations ext2_dir_inode_operations;
+extern const struct inode_operations ext2_special_inode_operations;
 
 /* symlink.c */
-extern struct inode_operations ext2_fast_symlink_inode_operations;
-extern struct inode_operations ext2_symlink_inode_operations;
+extern const struct inode_operations ext2_fast_symlink_inode_operations;
+extern const struct inode_operations ext2_symlink_inode_operations;
Index: fs/ext2/file.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/ext2/file.c,v
retrieving revision 1.1
diff -u -p -r1.1 file.c
--- fs/ext2/file.c	29 Jul 2003 17:01:40 -0000	1.1
+++ fs/ext2/file.c	30 Oct 2003 23:11:23 -0000
@@ -39,7 +39,7 @@ static int ext2_release_file (struct ino
  * We have mostly NULL's here: the current defaults are ok for
  * the ext2 filesystem.
  */
-struct file_operations ext2_file_operations = {
+const struct file_operations ext2_file_operations = {
 	.llseek		= generic_file_llseek,
 	.read		= generic_file_read,
 	.write		= generic_file_write,
@@ -55,7 +55,7 @@ struct file_operations ext2_file_operati
 	.sendfile	= generic_file_sendfile,
 };
 
-struct inode_operations ext2_file_inode_operations = {
+const struct inode_operations ext2_file_inode_operations = {
 	.truncate	= ext2_truncate,
 	.setxattr	= ext2_setxattr,
 	.getxattr	= ext2_getxattr,
Index: fs/ext2/inode.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/ext2/inode.c,v
retrieving revision 1.5
diff -u -p -r1.5 inode.c
--- fs/ext2/inode.c	8 Oct 2003 20:52:44 -0000	1.5
+++ fs/ext2/inode.c	30 Oct 2003 23:11:00 -0000
@@ -671,7 +671,7 @@ ext2_writepages(struct address_space *ma
 	return mpage_writepages(mapping, wbc, ext2_get_block);
 }
 
-struct address_space_operations ext2_aops = {
+const struct address_space_operations ext2_aops = {
 	.readpage		= ext2_readpage,
 	.readpages		= ext2_readpages,
 	.writepage		= ext2_writepage,
@@ -683,7 +683,7 @@ struct address_space_operations ext2_aop
 	.writepages		= ext2_writepages,
 };
 
-struct address_space_operations ext2_nobh_aops = {
+const struct address_space_operations ext2_nobh_aops = {
 	.readpage		= ext2_readpage,
 	.readpages		= ext2_readpages,
 	.writepage		= ext2_writepage,
Index: fs/ext2/namei.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/ext2/namei.c,v
retrieving revision 1.3
diff -u -p -r1.3 namei.c
--- fs/ext2/namei.c	28 Sep 2003 04:06:01 -0000	1.3
+++ fs/ext2/namei.c	30 Oct 2003 23:10:35 -0000
@@ -378,7 +378,7 @@ out:
 	return err;
 }
 
-struct inode_operations ext2_dir_inode_operations = {
+const struct inode_operations ext2_dir_inode_operations = {
 	.create		= ext2_create,
 	.lookup		= ext2_lookup,
 	.link		= ext2_link,
@@ -396,7 +396,7 @@ struct inode_operations ext2_dir_inode_o
 	.permission	= ext2_permission,
 };
 
-struct inode_operations ext2_special_inode_operations = {
+const struct inode_operations ext2_special_inode_operations = {
 	.setxattr	= ext2_setxattr,
 	.getxattr	= ext2_getxattr,
 	.listxattr	= ext2_listxattr,
Index: fs/ext2/super.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/ext2/super.c,v
retrieving revision 1.2
diff -u -p -r1.2 super.c
--- fs/ext2/super.c	8 Oct 2003 20:52:44 -0000	1.2
+++ fs/ext2/super.c	30 Oct 2003 23:09:59 -0000
@@ -222,7 +222,7 @@ static void ext2_clear_inode(struct inod
 # define ext2_clear_inode NULL
 #endif
 
-static struct super_operations ext2_sops = {
+static const struct super_operations ext2_sops = {
 	.alloc_inode	= ext2_alloc_inode,
 	.destroy_inode	= ext2_destroy_inode,
 	.read_inode	= ext2_read_inode,
Index: fs/ext2/symlink.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/ext2/symlink.c,v
retrieving revision 1.2
diff -u -p -r1.2 symlink.c
--- fs/ext2/symlink.c	28 Sep 2003 04:06:01 -0000	1.2
+++ fs/ext2/symlink.c	30 Oct 2003 23:09:30 -0000
@@ -33,7 +33,7 @@ static int ext2_follow_link(struct dentr
 	return vfs_follow_link(nd, (char *)ei->i_data);
 }
 
-struct inode_operations ext2_symlink_inode_operations = {
+const struct inode_operations ext2_symlink_inode_operations = {
 	.readlink	= page_readlink,
 	.follow_link	= page_follow_link,
 	.setxattr	= ext2_setxattr,
@@ -42,7 +42,7 @@ struct inode_operations ext2_symlink_ino
 	.removexattr	= ext2_removexattr,
 };
  
-struct inode_operations ext2_fast_symlink_inode_operations = {
+const struct inode_operations ext2_fast_symlink_inode_operations = {
 	.readlink	= ext2_readlink,
 	.follow_link	= ext2_follow_link,
 	.setxattr	= ext2_setxattr,
Index: fs/intermezzo/dcache.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/intermezzo/dcache.c,v
retrieving revision 1.3
diff -u -p -r1.3 dcache.c
--- fs/intermezzo/dcache.c	8 Oct 2003 20:52:46 -0000	1.3
+++ fs/intermezzo/dcache.c	31 Oct 2003 03:09:22 -0000
@@ -109,7 +109,7 @@ static void presto_d_release(struct dent
         }
 }
 
-struct dentry_operations presto_dentry_ops = 
+const struct dentry_operations presto_dentry_ops = 
 {
         .d_revalidate =  presto_d_revalidate,
         .d_release = presto_d_release
Index: fs/intermezzo/dir.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/intermezzo/dir.c,v
retrieving revision 1.12
diff -u -p -r1.12 dir.c
--- fs/intermezzo/dir.c	8 Oct 2003 20:52:46 -0000	1.12
+++ fs/intermezzo/dir.c	31 Oct 2003 03:10:01 -0000
@@ -245,7 +245,7 @@ struct dentry *presto_lookup(struct inod
         int minor;
         ino_t ino;
         unsigned int generation;
-        struct inode_operations *iops;
+        const struct inode_operations *iops;
         int is_ilookup = 0;
 
         ENTRY;
@@ -835,10 +835,9 @@ int presto_permission(struct inode *inod
 {
         unsigned short mode = inode->i_mode;
         struct presto_cache *cache;
-        int rc;
 
         ENTRY;
-        if ( presto_can_ilookup() && !(mask & S_IWOTH)) {
+        if (presto_can_ilookup() && !(mask & S_IWOTH)) {
                 CDEBUG(D_CACHE, "ilookup on %ld OK\n", inode->i_ino);
                 EXIT;
                 return 0;
@@ -846,10 +845,10 @@ int presto_permission(struct inode *inod
 
         cache = presto_get_cache(inode);
 
-        if ( cache ) {
+        if (cache) {
                 /* we only override the file/dir permission operations */
-                struct inode_operations *fiops = filter_c2cfiops(cache->cache_filter);
-                struct inode_operations *diops = filter_c2cdiops(cache->cache_filter);
+                const struct inode_operations *fiops = filter_c2cfiops(cache->cache_filter);
+                const struct inode_operations *diops = filter_c2cdiops(cache->cache_filter);
 
                 if ( S_ISREG(mode) && fiops && fiops->permission ) {
                         EXIT;
@@ -861,18 +860,8 @@ int presto_permission(struct inode *inod
                 }
         }
 
-        /* The cache filesystem doesn't have its own permission function,
-         * but we don't want to duplicate the VFS code here.  In order
-         * to avoid looping from permission calling this function again,
-         * we temporarily override the permission operation while we call
-         * the VFS permission function.
-         */
-        inode->i_op->permission = NULL;
-        rc = permission(inode, mask, nd);
-        inode->i_op->permission = &presto_permission;
-
         EXIT;
-        return rc;
+        return vfs_permission(inode, mask);
 }
 
 
@@ -1314,11 +1303,11 @@ int presto_ioctl(struct inode *inode, st
         return 0;
 }
 
-struct file_operations presto_dir_fops = {
+const struct file_operations presto_dir_fops = {
         .ioctl =  presto_ioctl
 };
 
-struct inode_operations presto_dir_iops = {
+const struct inode_operations presto_dir_iops = {
         .create       = presto_create,
         .lookup       = presto_lookup,
         .link         = presto_link,
Index: fs/intermezzo/file.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/intermezzo/file.c,v
retrieving revision 1.3
diff -u -p -r1.3 file.c
--- fs/intermezzo/file.c	8 Oct 2003 20:52:46 -0000	1.3
+++ fs/intermezzo/file.c	31 Oct 2003 03:07:26 -0000
@@ -143,7 +143,7 @@ static inline int open_check_dod(struct 
 static int presto_file_open(struct inode *inode, struct file *file)
 {
         int rc = 0;
-        struct file_operations *fops;
+        const struct file_operations *fops;
         struct presto_cache *cache;
         struct presto_file_set *fset;
         struct presto_file_data *fdata;
@@ -257,7 +257,7 @@ int presto_adjust_lml(struct file *file,
 static int presto_file_release(struct inode *inode, struct file *file)
 {
         int rc;
-        struct file_operations *fops;
+        const struct file_operations *fops;
         struct presto_cache *cache;
         struct presto_file_set *fset;
         struct presto_file_data *fdata = 
@@ -360,7 +360,7 @@ static ssize_t presto_file_write(struct 
         int error;
         struct presto_cache *cache;
         struct presto_file_set *fset;
-        struct file_operations *fops;
+        const struct file_operations *fops;
         ssize_t res;
         int do_lml_here;
         void *handle = NULL;
@@ -451,14 +451,14 @@ static ssize_t presto_file_write(struct 
         return res;
 }
 
-struct file_operations presto_file_fops = {
+const struct file_operations presto_file_fops = {
         .write   = presto_file_write,
         .open    = presto_file_open,
         .release = presto_file_release,
         .ioctl   = presto_ioctl
 };
 
-struct inode_operations presto_file_iops = {
+const struct inode_operations presto_file_iops = {
         .permission   = presto_permission,
         .setattr      = presto_setattr,
 #ifdef CONFIG_FS_EXT_ATTR
Index: fs/intermezzo/inode.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/intermezzo/inode.c,v
retrieving revision 1.3
diff -u -p -r1.3 inode.c
--- fs/intermezzo/inode.c	8 Oct 2003 20:52:46 -0000	1.3
+++ fs/intermezzo/inode.c	31 Oct 2003 03:11:25 -0000
@@ -106,7 +106,7 @@ static void presto_put_super(struct supe
 {
         struct presto_cache *cache;
         struct upc_channel *channel;
-        struct super_operations *sops;
+        const struct super_operations *sops;
         struct list_head *lh;
         int err;
 
@@ -164,16 +164,16 @@ exit:
         return ;
 }
 
-struct super_operations presto_super_ops = {
+const struct super_operations presto_super_ops = {
         .read_inode    = presto_read_inode,
         .put_super     = presto_put_super,
 };
 
 
 /* symlinks can be chowned */
-struct inode_operations presto_sym_iops = {
+const struct inode_operations presto_sym_iops = {
         .setattr       = presto_setattr
 };
 
 /* NULL for now */
-struct file_operations presto_sym_fops; 
+const struct file_operations presto_sym_fops; 
Index: fs/intermezzo/intermezzo_fs.h
===================================================================
RCS file: /var/cvs/linux-2.6/fs/intermezzo/intermezzo_fs.h,v
retrieving revision 1.1
diff -u -p -r1.1 intermezzo_fs.h
--- fs/intermezzo/intermezzo_fs.h	29 Jul 2003 17:01:40 -0000	1.1
+++ fs/intermezzo/intermezzo_fs.h	31 Oct 2003 03:08:53 -0000
@@ -339,7 +339,7 @@ inline int presto_lento_up(int minor);
 int izo_psdev_setchannel(struct file *file, int fd);
 
 /* inode.c */
-extern struct super_operations presto_super_ops;
+extern const struct super_operations presto_super_ops;
 void presto_set_ops(struct inode *inode, struct  filter_fs *filter);
 
 /* dcache.c */
@@ -350,15 +350,15 @@ inline struct presto_dentry_data *izo_al
 int presto_set_dd(struct dentry *);
 int presto_init_ddata_cache(void);
 void presto_cleanup_ddata_cache(void);
-extern struct dentry_operations presto_dentry_ops;
+extern const struct dentry_operations presto_dentry_ops;
 
 /* dir.c */
-extern struct inode_operations presto_dir_iops;
-extern struct inode_operations presto_file_iops;
-extern struct inode_operations presto_sym_iops;
-extern struct file_operations presto_dir_fops;
-extern struct file_operations presto_file_fops;
-extern struct file_operations presto_sym_fops;
+extern const struct inode_operations presto_dir_iops;
+extern const struct inode_operations presto_file_iops;
+extern const struct inode_operations presto_sym_iops;
+extern const struct file_operations presto_dir_fops;
+extern const struct file_operations presto_file_fops;
+extern const struct file_operations presto_sym_fops;
 int presto_setattr(struct dentry *de, struct iattr *iattr);
 int presto_settime(struct presto_file_set *fset, struct dentry *newobj,
                    struct dentry *parent, struct dentry *target,
Index: fs/intermezzo/methods.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/intermezzo/methods.c,v
retrieving revision 1.2
diff -u -p -r1.2 methods.c
--- fs/intermezzo/methods.c	8 Oct 2003 20:52:46 -0000	1.2
+++ fs/intermezzo/methods.c	31 Oct 2003 12:22:45 -0000
@@ -99,42 +99,42 @@ inline struct dentry_operations *filter_
 }
 
 /* get to the cache (lower) methods */
-inline struct super_operations *filter_c2csops(struct filter_fs *cache)
+inline const struct super_operations *filter_c2csops(struct filter_fs *cache)
 {
         return cache->o_caops.cache_sops;
 }
 
-inline struct inode_operations *filter_c2cdiops(struct filter_fs *cache)
+inline const struct inode_operations *filter_c2cdiops(struct filter_fs *cache)
 {
         return cache->o_caops.cache_dir_iops;
 }
 
-inline struct inode_operations *filter_c2cfiops(struct filter_fs *cache)
+inline const struct inode_operations *filter_c2cfiops(struct filter_fs *cache)
 {
         return cache->o_caops.cache_file_iops;
 }
 
-inline struct inode_operations *filter_c2csiops(struct filter_fs *cache)
+inline const struct inode_operations *filter_c2csiops(struct filter_fs *cache)
 {
         return cache->o_caops.cache_sym_iops;
 }
 
-inline struct file_operations *filter_c2cdfops(struct filter_fs *cache)
+inline const struct file_operations *filter_c2cdfops(struct filter_fs *cache)
 {
         return cache->o_caops.cache_dir_fops;
 }
 
-inline struct file_operations *filter_c2cffops(struct filter_fs *cache)
+inline const struct file_operations *filter_c2cffops(struct filter_fs *cache)
 {
         return cache->o_caops.cache_file_fops;
 }
 
-inline struct file_operations *filter_c2csfops(struct filter_fs *cache)
+inline const struct file_operations *filter_c2csfops(struct filter_fs *cache)
 {
         return cache->o_caops.cache_sym_fops;
 }
 
-inline struct dentry_operations *filter_c2cdops(struct filter_fs *cache)
+inline const struct dentry_operations *filter_c2cdops(struct filter_fs *cache)
 {
         return cache->o_caops.cache_dentry_ops;
 }
@@ -261,7 +261,7 @@ struct filter_fs *filter_get_filter_fs(c
  *    and the underlying file system used for the cache.
  */
 
-void filter_setup_super_ops(struct filter_fs *cache, struct super_operations *cache_sops, struct super_operations *filter_sops)
+void filter_setup_super_ops(struct filter_fs *cache, const struct super_operations *cache_sops, const struct super_operations *filter_sops)
 {
         /* Get ptr to the shared struct snapfs_ops structure. */
         struct filter_ops *props = &cache->o_fops;
@@ -303,11 +303,11 @@ void filter_setup_super_ops(struct filte
 }
 
 
-void filter_setup_dir_ops(struct filter_fs *cache, struct inode *inode, struct inode_operations *filter_iops, struct file_operations *filter_fops)
+void filter_setup_dir_ops(struct filter_fs *cache, struct inode *inode, const struct inode_operations *filter_iops, const struct file_operations *filter_fops)
 {
         struct inode_operations *cache_filter_iops;
-        struct inode_operations *cache_iops = inode->i_op;
-        struct file_operations *cache_fops = inode->i_fop;
+        const struct inode_operations *cache_iops = inode->i_op;
+        const struct file_operations *cache_fops = inode->i_fop;
         FENTRY;
 
         if ( cache->o_flags & FILTER_DID_DIR_OPS ) {
@@ -378,11 +378,11 @@ void filter_setup_dir_ops(struct filter_
 }
 
 
-void filter_setup_file_ops(struct filter_fs *cache, struct inode *inode, struct inode_operations *filter_iops, struct file_operations *filter_fops)
+void filter_setup_file_ops(struct filter_fs *cache, struct inode *inode, const struct inode_operations *filter_iops, const struct file_operations *filter_fops)
 {
         struct inode_operations *pr_iops;
-        struct inode_operations *cache_iops = inode->i_op;
-        struct file_operations *cache_fops = inode->i_fop;
+        const struct inode_operations *cache_iops = inode->i_op;
+        const struct file_operations *cache_fops = inode->i_fop;
         FENTRY;
 
         if ( cache->o_flags & FILTER_DID_FILE_OPS ) {
@@ -434,11 +434,11 @@ void filter_setup_file_ops(struct filter
 }
 
 /* XXX in 2.3 there are "fast" and "slow" symlink ops for ext2 XXX */
-void filter_setup_symlink_ops(struct filter_fs *cache, struct inode *inode, struct inode_operations *filter_iops, struct file_operations *filter_fops)
+void filter_setup_symlink_ops(struct filter_fs *cache, struct inode *inode, const struct inode_operations *filter_iops, const struct file_operations *filter_fops)
 {
         struct inode_operations *pr_iops;
-        struct inode_operations *cache_iops = inode->i_op;
-        struct file_operations *cache_fops = inode->i_fop;
+        const struct inode_operations *cache_iops = inode->i_op;
+        const struct file_operations *cache_fops = inode->i_fop;
         FENTRY;
 
         if ( cache->o_flags & FILTER_DID_SYMLINK_OPS ) {
@@ -473,8 +473,8 @@ void filter_setup_symlink_ops(struct fil
 }
 
 void filter_setup_dentry_ops(struct filter_fs *cache,
-                             struct dentry_operations *cache_dop,
-                             struct dentry_operations *filter_dop)
+                             const struct dentry_operations *cache_dop,
+                             const struct dentry_operations *filter_dop)
 {
         if ( cache->o_flags & FILTER_DID_DENTRY_OPS ) {
                 FEXIT;
Index: fs/intermezzo/vfs.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/intermezzo/vfs.c,v
retrieving revision 1.5
diff -u -p -r1.5 vfs.c
--- fs/intermezzo/vfs.c	8 Oct 2003 20:52:46 -0000	1.5
+++ fs/intermezzo/vfs.c	31 Oct 2003 12:28:40 -0000
@@ -78,7 +78,7 @@
 # endif
 #endif
 
-extern struct inode_operations presto_sym_iops;
+extern const struct inode_operations presto_sym_iops;
 
 /* Write the last_rcvd values to the last_rcvd file.  We don't know what the
  * UUID or last_ctime values are, so we have to read from the file first
@@ -229,7 +229,7 @@ int presto_settime(struct presto_file_se
         int error = 0;
         struct dentry *dentry;
         struct inode *inode;
-        struct inode_operations *iops;
+        const struct inode_operations *iops;
         struct iattr iattr;
 
         ENTRY;
@@ -364,7 +364,7 @@ int presto_do_setattr(struct presto_file
 {
         struct rec_info rec;
         struct inode *inode = dentry->d_inode;
-        struct inode_operations *iops;
+        const struct inode_operations *iops;
         int error;
         struct presto_version old_ver, new_ver;
         struct izo_rollback_data rb;
@@ -558,7 +558,7 @@ int presto_do_create(struct presto_file_
         struct rec_info rec;
         int error;
         struct presto_version tgt_dir_ver, new_file_ver;
-        struct inode_operations *iops;
+        const struct inode_operations *iops;
         void *handle;
 
         ENTRY;
@@ -720,7 +720,7 @@ int presto_do_link(struct presto_file_se
         struct rec_info rec;
         struct inode *inode;
         int error;
-        struct inode_operations *iops;
+        const struct inode_operations *iops;
         struct presto_version tgt_dir_ver;
         struct presto_version new_link_ver;
         void *handle;
@@ -867,7 +867,7 @@ int presto_do_unlink(struct presto_file_
                      struct dentry *dentry, struct lento_vfs_context *info)
 {
         struct rec_info rec;
-        struct inode_operations *iops;
+        const struct inode_operations *iops;
         struct presto_version tgt_dir_ver, old_file_ver;
         struct izo_rollback_data rb;
         void *handle;
@@ -934,7 +934,7 @@ int presto_do_unlink(struct presto_file_
 
                 if (S_ISLNK(dentry->d_inode->i_mode)) {
                         mm_segment_t old_fs;
-                        struct inode_operations *riops;
+                        const struct inode_operations *riops;
                         riops = filter_c2csiops(fset->fset_cache->cache_filter);
 
                         PRESTO_ALLOC(old_target, PATH_MAX);
@@ -1076,7 +1076,7 @@ int presto_do_symlink(struct presto_file
         struct rec_info rec;
         int error;
         struct presto_version tgt_dir_ver, new_link_ver;
-        struct inode_operations *iops;
+        const struct inode_operations *iops;
         void *handle;
 
         ENTRY;
@@ -1396,7 +1396,7 @@ int presto_do_rmdir(struct presto_file_s
         int error;
         struct presto_version tgt_dir_ver, old_dir_ver;
         struct izo_rollback_data rb;
-        struct inode_operations *iops;
+        const struct inode_operations *iops;
         void *handle;
         int do_kml, do_rcvd;
         int size;
@@ -1539,7 +1539,7 @@ int presto_do_mknod(struct presto_file_s
         struct rec_info rec;
         int error = -EPERM;
         struct presto_version tgt_dir_ver, new_node_ver;
-        struct inode_operations *iops;
+        const struct inode_operations *iops;
         void *handle;
 
         ENTRY;
@@ -1702,7 +1702,7 @@ int do_rename(struct presto_file_set *fs
 {
         struct rec_info rec;
         int error;
-        struct inode_operations *iops;
+        const struct inode_operations *iops;
         struct presto_version src_dir_ver, tgt_dir_ver;
         void *handle;
         int new_inode_unlink = 0;
@@ -2277,7 +2277,7 @@ int presto_setmode(struct presto_file_se
          */
         {    
         int error=0; 
-        struct super_operations *sops;
+        const struct super_operations *sops;
         struct iattr iattr;
 
         iattr.ia_mode = mode;
@@ -2309,7 +2309,7 @@ int presto_do_set_ext_attr(struct presto
 {
         struct rec_info rec;
         struct inode *inode = dentry->d_inode;
-        struct inode_operations *iops;
+        const struct inode_operations *iops;
         int error;
         struct presto_version ver;
         void *handle;
Index: fs/nfsd/nfsfh.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/nfsd/nfsfh.c,v
retrieving revision 1.2
diff -u -p -r1.2 nfsfh.c
--- fs/nfsd/nfsfh.c	28 Sep 2003 04:06:04 -0000	1.2
+++ fs/nfsd/nfsfh.c	30 Oct 2003 23:02:38 -0000
@@ -187,7 +187,8 @@ fh_verify(struct svc_rqst *rqstp, struct
 		if (fileid_type == 0)
 			dentry = dget(exp->ex_dentry);
 		else {
-			struct export_operations *nop = exp->ex_mnt->mnt_sb->s_export_op;
+			const struct export_operations *nop =
+					exp->ex_mnt->mnt_sb->s_export_op;
 				dentry = CALL(nop,decode_fh)(exp->ex_mnt->mnt_sb,
 							     datap, data_left,
 							     fileid_type,
@@ -284,7 +285,7 @@ out:
 inline int _fh_update(struct dentry *dentry, struct svc_export *exp,
 		      __u32 *datap, int *maxsize)
 {
-	struct export_operations *nop = exp->ex_mnt->mnt_sb->s_export_op;
+	const struct export_operations *nop = exp->ex_mnt->mnt_sb->s_export_op;
 	
 	if (dentry == exp->ex_dentry) {
 		*maxsize = 0;
Index: fs/nfsd/vfs.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/nfsd/vfs.c,v
retrieving revision 1.3
diff -u -p -r1.3 vfs.c
--- fs/nfsd/vfs.c	8 Oct 2003 20:52:48 -0000	1.3
+++ fs/nfsd/vfs.c	30 Oct 2003 23:03:01 -0000
@@ -528,7 +528,7 @@ nfsd_close(struct file *filp)
  * after it.
  */
 inline void nfsd_dosync(struct file *filp, struct dentry *dp, 
-			struct file_operations *fop)
+			const struct file_operations *fop)
 {
 	struct inode *inode = dp->d_inode;
 	int (*fsync) (struct file *, struct dentry *, int);
Index: fs/ntfs/time.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/ntfs/time.c,v
retrieving revision 1.1
diff -u -p -r1.1 time.c
--- fs/ntfs/time.c	29 Jul 2003 17:01:44 -0000	1.1
+++ fs/ntfs/time.c	31 Oct 2003 12:40:55 -0000
@@ -75,7 +75,7 @@ inline s64 get_current_ntfs_time(void)
 inline time_t ntfs2utc(const s64 time)
 {
 	/* Subtract the NTFS time offset, then convert to 1s intervals. */
-	s64 t = sle64_to_cpu(time) - NTFS_TIME_OFFSET;
+	u64 t = sle64_to_cpu(time) - NTFS_TIME_OFFSET;
 	do_div(t, 10000000);
 	return (time_t)t;
 }
Index: fs/proc/generic.c
===================================================================
RCS file: /var/cvs/linux-2.6/fs/proc/generic.c,v
retrieving revision 1.2
diff -u -p -r1.2 generic.c
--- fs/proc/generic.c	28 Sep 2003 04:06:06 -0000	1.2
+++ fs/proc/generic.c	30 Oct 2003 23:07:47 -0000
@@ -499,7 +499,7 @@ static void proc_kill_inodes(struct proc
 		struct file * filp = list_entry(p, struct file, f_list);
 		struct dentry * dentry = filp->f_dentry;
 		struct inode * inode;
-		struct file_operations *fops;
+		const struct file_operations *fops;
 
 		if (dentry->d_op != &proc_dentry_operations)
 			continue;
Index: include/linux/cdev.h
===================================================================
RCS file: /var/cvs/linux-2.6/include/linux/cdev.h,v
retrieving revision 1.1
diff -u -p -r1.1 cdev.h
--- include/linux/cdev.h	29 Jul 2003 17:02:11 -0000	1.1
+++ include/linux/cdev.h	30 Oct 2003 22:55:48 -0000
@@ -5,11 +5,11 @@
 struct cdev {
 	struct kobject kobj;
 	struct module *owner;
-	struct file_operations *ops;
+	const struct file_operations *ops;
 	struct list_head list;
 };
 
-void cdev_init(struct cdev *, struct file_operations *);
+void cdev_init(struct cdev *, const struct file_operations *);
 
 struct cdev *cdev_alloc(void);
 
Index: include/linux/dcache.h
===================================================================
RCS file: /var/cvs/linux-2.6/include/linux/dcache.h,v
retrieving revision 1.2
diff -u -p -r1.2 dcache.h
--- include/linux/dcache.h	12 Aug 2003 19:11:27 -0000	1.2
+++ include/linux/dcache.h	31 Oct 2003 03:00:54 -0000
@@ -88,7 +88,7 @@ struct dentry {
 	struct list_head d_subdirs;	/* our children */
 	struct list_head d_alias;	/* inode alias list */
 	unsigned long d_time;		/* used by d_revalidate */
-	struct dentry_operations  *d_op;
+	const struct dentry_operations  *d_op;
 	struct super_block * d_sb;	/* The root of the dentry tree */
 	unsigned int d_flags;
 	int d_mounted;
Index: include/linux/fs.h
===================================================================
RCS file: /var/cvs/linux-2.6/include/linux/fs.h,v
retrieving revision 1.5
diff -u -p -r1.5 fs.h
--- include/linux/fs.h	28 Sep 2003 04:06:20 -0000	1.5
+++ include/linux/fs.h	30 Oct 2003 23:03:58 -0000
@@ -325,7 +325,7 @@ struct address_space {
 	struct list_head	locked_pages;	/* list of locked pages */
 	struct list_head	io_pages;	/* being prepared for I/O */
 	unsigned long		nrpages;	/* number of total pages */
-	struct address_space_operations *a_ops;	/* methods */
+	const struct address_space_operations *a_ops;	/* methods */
 	struct list_head	i_mmap;		/* list of private mappings */
 	struct list_head	i_mmap_shared;	/* list of shared mappings */
 	struct semaphore	i_shared_sem;	/* protect both above lists */
@@ -388,8 +388,8 @@ struct inode {
 	unsigned short          i_bytes;
 	spinlock_t		i_lock;	/* i_blocks, i_bytes, maybe i_size */
 	struct semaphore	i_sem;
-	struct inode_operations	*i_op;
-	struct file_operations	*i_fop;	/* former ->i_op->default_file_ops */
+	const struct inode_operations	*i_op;
+	const struct file_operations	*i_fop;	/* former ->i_op->default_file_ops */
 	struct super_block	*i_sb;
 	struct file_lock	*i_flock;
 	struct address_space	*i_mapping;
@@ -507,7 +507,7 @@ struct file {
 	struct list_head	f_list;
 	struct dentry		*f_dentry;
 	struct vfsmount         *f_vfsmnt;
-	struct file_operations	*f_op;
+	const struct file_operations	*f_op;
 	atomic_t		f_count;
 	unsigned int 		f_flags;
 	mode_t			f_mode;
@@ -672,9 +672,9 @@ struct super_block {
 	unsigned char		s_dirt;
 	unsigned long long	s_maxbytes;	/* Max file size */
 	struct file_system_type	*s_type;
-	struct super_operations	*s_op;
-	struct dquot_operations	*dq_op;
- 	struct quotactl_ops	*s_qcop;
+	const struct super_operations	*s_op;
+	const struct dquot_operations	*dq_op;
+ 	const struct quotactl_ops	*s_qcop;
 	struct export_operations *s_export_op;
 	unsigned long		s_flags;
 	unsigned long		s_magic;
@@ -1031,7 +1031,7 @@ struct super_block *sget(struct file_sys
 			int (*set)(struct super_block *,void *),
 			void *data);
 struct super_block *get_sb_pseudo(struct file_system_type *, char *,
-			struct super_operations *ops, unsigned long);
+			const struct super_operations *ops, unsigned long);
 
 /* Alas, no aliases. Too much hassle with bringing module.h everywhere */
 #define fops_get(fops) \
@@ -1129,11 +1129,11 @@ extern void bdput(struct block_device *)
 extern int blkdev_open(struct inode *, struct file *);
 extern int blkdev_close(struct inode *, struct file *);
 extern struct block_device *open_by_devnum(dev_t, unsigned, int);
-extern struct file_operations def_blk_fops;
-extern struct address_space_operations def_blk_aops;
-extern struct file_operations def_chr_fops;
-extern struct file_operations bad_sock_fops;
-extern struct file_operations def_fifo_fops;
+extern const struct file_operations def_blk_fops;
+extern const struct address_space_operations def_blk_aops;
+extern const struct file_operations def_chr_fops;
+extern const struct file_operations bad_sock_fops;
+extern const struct file_operations def_fifo_fops;
 extern int ioctl_by_bdev(struct block_device *, unsigned, unsigned long);
 extern int blkdev_ioctl(struct inode *, struct file *, unsigned, unsigned long);
 extern int blkdev_get(struct block_device *, mode_t, unsigned, int);
@@ -1146,7 +1146,7 @@ extern void blk_run_queues(void);
 extern int alloc_chrdev_region(dev_t *, unsigned, unsigned, char *);
 extern int register_chrdev_region(dev_t, unsigned, char *);
 extern int register_chrdev(unsigned int, const char *,
-			   struct file_operations *);
+			   const struct file_operations *);
 extern int unregister_chrdev(unsigned int, const char *);
 extern void unregister_chrdev_region(dev_t, unsigned);
 extern int chrdev_open(struct inode *, struct file *);
@@ -1165,12 +1165,12 @@ extern void init_special_inode(struct in
 extern void make_bad_inode(struct inode *);
 extern int is_bad_inode(struct inode *);
 
-extern struct file_operations read_fifo_fops;
-extern struct file_operations write_fifo_fops;
-extern struct file_operations rdwr_fifo_fops;
-extern struct file_operations read_pipe_fops;
-extern struct file_operations write_pipe_fops;
-extern struct file_operations rdwr_pipe_fops;
+extern const struct file_operations read_fifo_fops;
+extern const struct file_operations write_fifo_fops;
+extern const struct file_operations rdwr_fifo_fops;
+extern const struct file_operations read_pipe_fops;
+extern const struct file_operations write_pipe_fops;
+extern const struct file_operations rdwr_pipe_fops;
 
 extern int fs_may_remount_ro(struct super_block *);
 
@@ -1338,7 +1338,7 @@ static inline void do_generic_file_read(
 				actor);
 }
 
-extern struct file_operations generic_ro_fops;
+extern const struct file_operations generic_ro_fops;
 
 #define special_file(m) (S_ISCHR(m)||S_ISBLK(m)||S_ISFIFO(m)||S_ISSOCK(m))
 
@@ -1347,7 +1347,7 @@ extern int vfs_follow_link(struct nameid
 extern int page_readlink(struct dentry *, char __user *, int);
 extern int page_follow_link(struct dentry *, struct nameidata *);
 extern int page_symlink(struct inode *inode, const char *symname, int len);
-extern struct inode_operations page_symlink_inode_operations;
+extern const struct inode_operations page_symlink_inode_operations;
 extern void generic_fillattr(struct inode *, struct kstat *);
 extern int vfs_getattr(struct vfsmount *, struct dentry *, struct kstat *);
 void inode_add_bytes(struct inode *inode, loff_t bytes);
@@ -1386,9 +1386,9 @@ extern int simple_commit_write(struct fi
 
 extern struct dentry *simple_lookup(struct inode *, struct dentry *, struct nameidata *);
 extern ssize_t generic_read_dir(struct file *, char __user *, size_t, loff_t *);
-extern struct file_operations simple_dir_operations;
-extern struct inode_operations simple_dir_inode_operations;
-struct tree_descr { char *name; struct file_operations *ops; int mode; };
+extern const struct file_operations simple_dir_operations;
+extern const struct inode_operations simple_dir_inode_operations;
+struct tree_descr { char *name; const struct file_operations *ops; int mode; };
 extern int simple_fill_super(struct super_block *, int, struct tree_descr *);
 extern int simple_pin_fs(char *name, struct vfsmount **mount, int *count);
 extern void simple_release_fs(struct vfsmount **mount, int *count);
Index: include/linux/fsfilter.h
===================================================================
RCS file: /var/cvs/linux-2.6/include/linux/fsfilter.h,v
retrieving revision 1.1
diff -u -p -r1.1 fsfilter.h
--- include/linux/fsfilter.h	29 Jul 2003 17:02:12 -0000	1.1
+++ include/linux/fsfilter.h	31 Oct 2003 12:22:03 -0000
@@ -33,17 +33,17 @@ struct filter_ops { 
 
 struct cache_ops {
         /* operations on the file store */
-        struct super_operations *cache_sops;
+        const struct super_operations *cache_sops;
 
-        struct inode_operations *cache_dir_iops;
-        struct inode_operations *cache_file_iops;
-        struct inode_operations *cache_sym_iops;
+        const struct inode_operations *cache_dir_iops;
+        const struct inode_operations *cache_file_iops;
+        const struct inode_operations *cache_sym_iops;
 
-        struct file_operations *cache_dir_fops;
-        struct file_operations *cache_file_fops;
-        struct file_operations *cache_sym_fops;
+        const struct file_operations *cache_dir_fops;
+        const struct file_operations *cache_file_fops;
+        const struct file_operations *cache_sym_fops;
 
-        struct dentry_operations *cache_dentry_ops;
+        const struct dentry_operations *cache_dentry_ops;
 };
 
 
@@ -81,21 +81,34 @@ inline struct inode_operations *filter_c
 inline struct file_operations *filter_c2uffops(struct filter_fs *cache);
 inline struct file_operations *filter_c2udfops(struct filter_fs *cache);
 inline struct file_operations *filter_c2usfops(struct filter_fs *cache);
-inline struct super_operations *filter_c2csops(struct filter_fs *cache);
-inline struct inode_operations *filter_c2cfiops(struct filter_fs *cache);
-inline struct inode_operations *filter_c2cdiops(struct filter_fs *cache);
-inline struct inode_operations *filter_c2csiops(struct filter_fs *cache);
-inline struct file_operations *filter_c2cffops(struct filter_fs *cache);
-inline struct file_operations *filter_c2cdfops(struct filter_fs *cache);
-inline struct file_operations *filter_c2csfops(struct filter_fs *cache);
-inline struct dentry_operations *filter_c2cdops(struct filter_fs *cache);
+inline const struct super_operations *filter_c2csops(struct filter_fs *cache);
+inline const struct inode_operations *filter_c2cfiops(struct filter_fs *cache);
+inline const struct inode_operations *filter_c2cdiops(struct filter_fs *cache);
+inline const struct inode_operations *filter_c2csiops(struct filter_fs *cache);
+inline const struct file_operations *filter_c2cffops(struct filter_fs *cache);
+inline const struct file_operations *filter_c2cdfops(struct filter_fs *cache);
+inline const struct file_operations *filter_c2csfops(struct filter_fs *cache);
+inline const struct dentry_operations *filter_c2cdops(struct filter_fs *cache);
 inline struct dentry_operations *filter_c2udops(struct filter_fs *cache);
 
-void filter_setup_super_ops(struct filter_fs *cache, struct super_operations *cache_ops, struct super_operations *filter_sops);
-void filter_setup_dir_ops(struct filter_fs *cache, struct inode *cache_inode, struct inode_operations *filter_iops, struct file_operations *ffops);
-void filter_setup_file_ops(struct filter_fs *cache, struct inode *cache_inode, struct inode_operations *filter_iops, struct file_operations *filter_op);
-void filter_setup_symlink_ops(struct filter_fs *cache, struct inode *cache_inode, struct inode_operations *filter_iops, struct file_operations *filter_op);
-void filter_setup_dentry_ops(struct filter_fs *cache, struct dentry_operations *cache_dop,  struct dentry_operations *filter_dop);
+void filter_setup_super_ops(struct filter_fs *cache,
+                const struct super_operations *cache_ops,
+                const struct super_operations *filter_sops);
+void filter_setup_dir_ops(struct filter_fs *cache,
+                struct inode *cache_inode,
+                const struct inode_operations *filter_iops,
+                const struct file_operations *ffops);
+void filter_setup_file_ops(struct filter_fs *cache,
+                struct inode *cache_inode,
+                const struct inode_operations *filter_iops,
+                const struct file_operations *filter_op);
+void filter_setup_symlink_ops(struct filter_fs *cache,
+                struct inode *cache_inode,
+                const struct inode_operations *filter_iops,
+                const struct file_operations *filter_op);
+void filter_setup_dentry_ops(struct filter_fs *cache,
+                const struct dentry_operations *cache_dop,
+                const struct dentry_operations *filter_dop);
 
 
 #define PRESTO_DEBUG
Index: mm/filemap.c
===================================================================
RCS file: /var/cvs/linux-2.6/mm/filemap.c,v
retrieving revision 1.6
diff -u -p -r1.6 filemap.c
--- mm/filemap.c	26 Oct 2003 15:17:06 -0000	1.6
+++ mm/filemap.c	30 Oct 2003 22:45:50 -0000
@@ -1697,7 +1697,7 @@ generic_file_aio_write_nolock(struct kio
 {
 	struct file *file = iocb->ki_filp;
 	struct address_space * mapping = file->f_dentry->d_inode->i_mapping;
-	struct address_space_operations *a_ops = mapping->a_ops;
+	const struct address_space_operations *a_ops = mapping->a_ops;
 	size_t ocount;		/* original count */
 	size_t count;		/* after file limit checks */
 	struct inode 	*inode = mapping->host;
Index: net/socket.c
===================================================================
RCS file: /var/cvs/linux-2.6/net/socket.c,v
retrieving revision 1.3
diff -u -p -r1.3 socket.c
--- net/socket.c	8 Oct 2003 20:53:07 -0000	1.3
+++ net/socket.c	31 Oct 2003 12:50:57 -0000
@@ -487,7 +487,7 @@ static int sock_no_open(struct inode *ir
 	return -ENXIO;
 }
 
-struct file_operations bad_sock_fops = {
+const struct file_operations bad_sock_fops = {
 	.owner = THIS_MODULE,
 	.open = sock_no_open,
 };
Index: sound/sound_core.c
===================================================================
RCS file: /var/cvs/linux-2.6/sound/sound_core.c,v
retrieving revision 1.2
diff -u -p -r1.2 sound_core.c
--- sound/sound_core.c	8 Sep 2003 21:43:07 -0000	1.2
+++ sound/sound_core.c	31 Oct 2003 12:51:14 -0000
@@ -524,7 +524,7 @@ int soundcore_open(struct inode *inode, 
 		 * switching ->f_op in the first place.
 		 */
 		int err = 0;
-		struct file_operations *old_fops = file->f_op;
+		const struct file_operations *old_fops = file->f_op;
 		file->f_op = new_fops;
 		spin_unlock(&sound_loader_lock);
 		if(file->f_op->open)
