Here is the original patch, plus legal stuff. Do you want the follow-on patch, which adds a UUID to all v3.6 filesystems that do not already have one (in the kernel)? This is about 5 lines of code.
Cheers, Andreas -- Andreas Dilger http://sourceforge.net/projects/ext2resize/ http://www-mddsp.enel.ucalgary.ca/People/adilger/ ========================================================================== diff -ru linux.orig/fs/reiserfs/objectid.c linux/fs/reiserfs/objectid.c --- linux.orig/fs/reiserfs/objectid.c Thu Oct 25 03:05:11 2001 +++ linux/fs/reiserfs/objectid.c Thu Oct 25 02:55:49 2001 @@ -5,6 +5,7 @@ #include <linux/config.h> #include <linux/string.h> #include <linux/locks.h> +#include <linux/random.h> #include <linux/sched.h> #include <linux/reiserfs_fs.h> @@ -195,6 +195,7 @@ disk_sb->s_oid_maxsize = cpu_to_le16(new_size) ; /* finally, zero out the unused chunk of the new super */ + memset(disk_sb->s_label, 0, sizeof(disk_sb->s_label)) ; + generate_random_uuid(rs->s_uuid); memset(disk_sb->s_unused, 0, sizeof(disk_sb->s_unused)) ; return 0 ; } diff -ru linux.orig/include/linux/reiserfs_fs_sb.h linux/include/linux/reiserfs_fs_sb.h --- linux.orig/include/linux/reiserfs_fs_sb.h Thu Oct 25 03:05:15 2001 +++ linux/include/linux/reiserfs_fs_sb.h Thu Oct 25 10:02:34 2001 @@ -61,7 +61,12 @@ superblock. -Hans */ __u16 s_reserved; __u32 s_inode_generation; - char s_unused[124] ; /* zero filled by mkreiserfs */ + unsigned char s_uuid[16]; /* filesystem unique identifier */ + unsigned char s_label[16]; /* filesystem volume label */ + char s_unused[92] ; /* zero filled by mkreiserfs and + * reiserfs_convert_objectid_map_v1() + * so any additions must be updated + * there as well. */ } __attribute__ ((__packed__)); #define SB_SIZE (sizeof(struct reiserfs_super_block)) ========================================================================== You are contributing all code that is in files or portions of files labeled as Copyright Hans Reiser to Hans Reiser, and this is code that you, and only you, with your own resources, have drafted for ReiserFS, a copyrighted file storage system owned by Hans Reiser. In consideration of Hans Reiser examining the code that you have contributed for inclusion in ReiserFS, all such contributed code which is in files or portions of files labeled as Copyright Hans Reiser is deemed a Work Made For Hire for purposes of copyright law, with all rights, title, and interest in the code belonging exclusively to Hans Reiser. Neither you nor any other person or entity holds any copyrights, patent rights, or any other intellectual property rights, title or interest in your creative contributions which might encumber or otherwise relate to ReiserFS. You will not make any claims to any right, title, or interest in ReiserFS, and have not given the right to make any such claim to any other person or entity. As the owner of ReiserFS, Hans Reiser may sell, license, transfer or otherwise use any code you contribute to ReiserFS, and may do so without limitation. If using CVS, and you do not agree to the above, you must ABORT this submission of your code and resubmit the code after clearly and unambiguously labeling it as not being Copyright Hans Reiser, using the notice "copyright (your name), (the year you wrote the code)". For example, "copyright Gary Geek, 2001". This agreement is between you, and Hans Reiser who has permanent residence in Oakland California USA. If using CVS you are thereby causing a copy of your agreement to be sent to [EMAIL PROTECTED] (a server in the USA). If sending an email, you are requested to send it to [EMAIL PROTECTED] You are accepting that this agreement shall be bound by California Law, and you agree that it bears your electronic signature which is binding under US law.
