From ed8e18481a9e66625bae556ecdd09bdf7f432c76 Mon Sep 17 00:00:00 2001 From: alex Date: Fri, 9 Jan 2004 22:31:24 +0000 Subject: [PATCH] - 2.6 fixes: - mds_lock_new_child() uses specific namespace to avoid deadlock if i_generations == 0 - portals_debug_copy_to_user() uses kmap_atomic() instead of kmap() because it's called beinged locked with disabled interrupts - ugly hacks which prevent userspace tools to try to load modules - corrections in Makefiles - minor compatibility defines and tweaks - inode->c_index is used as orphans counter - ll_lookup_finish_locks() doesn't release intent because on 2.6 it may be needed several times - check that nd isn't NULL before using - ll_update_inode() decoded dev number wrong way - PDE define is used to retrieve procfs-related data - rw26.c is almost copy of rw24.c - super25.c registers lustre and lustre_lite - 2.6 kernel patches: - 2.6.0-mm2 - dev_read_only_2.6.0.patch stores dev number, not struct block_device * - ext3-init-generation-2.6.0.patch - lustre dislikes when ext3 resets s_next_generation to 0 upon mount - ext3-map_inode_page-2.6.0.patch - added fix to unmap underlaying metadata - ext3-start_this_handle-must-return-error.patch - jbd returned 0 always: posssible oops - vfs_nointent_2.6.0-test6.patch - small contexts changes - invalidate_show-2.6.0.patch - port onto 2.6 - iopen-2.6.0-test6.patch - several fixes - vfs_intent_2.6.0.patch - port onto 2.5.0 - kernel_text_address-2.6.0.patch - export_symbols-2.6.0.patch - kgdb_2.6.0 series --- lustre/llite/super25.c | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/lustre/llite/super25.c b/lustre/llite/super25.c index 6325ae1..233035f 100644 --- a/lustre/llite/super25.c +++ b/lustre/llite/super25.c @@ -43,6 +43,13 @@ struct super_block * ll_get_sb(struct file_system_type *fs_type, return get_sb_nodev(fs_type, flags, data, ll_fill_super); } +struct super_block * lustre_get_sb(struct file_system_type *fs_type, + int flags, const char *devname, void * data) +{ + /* calls back in fill super */ + return get_sb_nodev(fs_type, flags, data, lustre_fill_super); +} + static kmem_cache_t *ll_inode_cachep; static struct inode *ll_alloc_inode(struct super_block *sb) @@ -92,7 +99,7 @@ void ll_destroy_inodecache(void) } /* exported operations */ -struct super_operations ll_super_operations = +struct super_operations lustre_super_operations = { alloc_inode: ll_alloc_inode, destroy_inode: ll_destroy_inode, @@ -110,6 +117,13 @@ struct file_system_type lustre_lite_fs_type = { .kill_sb = kill_anon_super, }; +struct file_system_type lustre_fs_type = { + .owner = THIS_MODULE, + .name = "lustre", + .get_sb = lustre_get_sb, + .kill_sb = kill_anon_super, +}; + static int __init init_lustre_lite(void) { int rc; @@ -129,11 +143,18 @@ static int __init init_lustre_lite(void) proc_lustre_fs_root = proc_lustre_root ? proc_mkdir("llite", proc_lustre_root) : NULL; - return register_filesystem(&lustre_lite_fs_type); + rc = register_filesystem(&lustre_lite_fs_type); + if (!rc) { + rc = register_filesystem(&lustre_fs_type); + if (rc) + unregister_filesystem(&lustre_fs_type); + } + return rc; } static void __exit exit_lustre_lite(void) { + unregister_filesystem(&lustre_fs_type); unregister_filesystem(&lustre_lite_fs_type); ll_destroy_inodecache(); kmem_cache_destroy(ll_file_data_slab); -- 1.8.3.1