Commit c9add9b8 authored by Alexander Viro's avatar Alexander Viro Committed by Linus Torvalds

[PATCH] assorted kdev_t cleanups in filesystems

	* JFS uses its ->logdev only twice - one of the places assigns
it to_kdev_t(le32_to_cpu(...)), another uses kdev_t_to_nr() of it.
Switched to u32 - it's just a place where we store device number we'd got
from superblock.
	* several reiserfs_fs.h function prototypes removed - functions
in question don't exist anymore.
	* smbfs doesn't support device nodes; ->f_rdev removed.
parent ab6a5810
...@@ -122,7 +122,7 @@ struct jfs_sb_info { ...@@ -122,7 +122,7 @@ struct jfs_sb_info {
short nbperpage; /* 2: blocks per page */ short nbperpage; /* 2: blocks per page */
short l2nbperpage; /* 2: log2 blocks per page */ short l2nbperpage; /* 2: log2 blocks per page */
short l2niperblk; /* 2: log2 inodes per page */ short l2niperblk; /* 2: log2 inodes per page */
kdev_t logdev; /* 2: external log device */ u32 logdev; /* 2: external log device */
uint aggregate; /* volume identifier in log record */ uint aggregate; /* volume identifier in log record */
pxd_t logpxd; /* 8: pxd describing log */ pxd_t logpxd; /* 8: pxd describing log */
pxd_t ait2; /* 8: pxd describing AIT copy */ pxd_t ait2; /* 8: pxd describing AIT copy */
......
...@@ -1102,7 +1102,7 @@ int lmLogOpen(struct super_block *sb, log_t ** logptr) ...@@ -1102,7 +1102,7 @@ int lmLogOpen(struct super_block *sb, log_t ** logptr)
*/ */
externalLog: externalLog:
if (!(bdev = bdget(kdev_t_to_nr(JFS_SBI(sb)->logdev)))) { if (!(bdev = bdget(JFS_SBI(sb)->logdev))) {
rc = ENODEV; rc = ENODEV;
goto free; goto free;
} }
......
...@@ -406,7 +406,7 @@ static int chkSuper(struct super_block *sb) ...@@ -406,7 +406,7 @@ static int chkSuper(struct super_block *sb)
if (sbi->mntflag & JFS_INLINELOG) if (sbi->mntflag & JFS_INLINELOG)
sbi->logpxd = j_sb->s_logpxd; sbi->logpxd = j_sb->s_logpxd;
else { else {
sbi->logdev = to_kdev_t(le32_to_cpu(j_sb->s_logdev)); sbi->logdev = le32_to_cpu(j_sb->s_logdev);
memcpy(sbi->uuid, j_sb->s_uuid, sizeof(sbi->uuid)); memcpy(sbi->uuid, j_sb->s_uuid, sizeof(sbi->uuid));
memcpy(sbi->loguuid, j_sb->s_loguuid, sizeof(sbi->uuid)); memcpy(sbi->loguuid, j_sb->s_loguuid, sizeof(sbi->uuid));
} }
......
...@@ -145,7 +145,6 @@ smb_get_inode_attr(struct inode *inode, struct smb_fattr *fattr) ...@@ -145,7 +145,6 @@ smb_get_inode_attr(struct inode *inode, struct smb_fattr *fattr)
fattr->f_ino = inode->i_ino; fattr->f_ino = inode->i_ino;
fattr->f_uid = inode->i_uid; fattr->f_uid = inode->i_uid;
fattr->f_gid = inode->i_gid; fattr->f_gid = inode->i_gid;
fattr->f_rdev = inode->i_rdev;
fattr->f_size = inode->i_size; fattr->f_size = inode->i_size;
fattr->f_mtime = inode->i_mtime; fattr->f_mtime = inode->i_mtime;
fattr->f_ctime = inode->i_ctime; fattr->f_ctime = inode->i_ctime;
...@@ -183,7 +182,6 @@ smb_set_inode_attr(struct inode *inode, struct smb_fattr *fattr) ...@@ -183,7 +182,6 @@ smb_set_inode_attr(struct inode *inode, struct smb_fattr *fattr)
inode->i_nlink = fattr->f_nlink; inode->i_nlink = fattr->f_nlink;
inode->i_uid = fattr->f_uid; inode->i_uid = fattr->f_uid;
inode->i_gid = fattr->f_gid; inode->i_gid = fattr->f_gid;
inode->i_rdev = fattr->f_rdev;
inode->i_ctime = fattr->f_ctime; inode->i_ctime = fattr->f_ctime;
inode->i_blksize= fattr->f_blksize; inode->i_blksize= fattr->f_blksize;
inode->i_blocks = fattr->f_blocks; inode->i_blocks = fattr->f_blocks;
......
...@@ -1675,13 +1675,10 @@ int pop_journal_writer(int windex) ; ...@@ -1675,13 +1675,10 @@ int pop_journal_writer(int windex) ;
int journal_transaction_should_end(struct reiserfs_transaction_handle *, int) ; int journal_transaction_should_end(struct reiserfs_transaction_handle *, int) ;
int reiserfs_in_journal(struct super_block *p_s_sb, unsigned long bl, int searchall, unsigned long *next) ; int reiserfs_in_journal(struct super_block *p_s_sb, unsigned long bl, int searchall, unsigned long *next) ;
int journal_begin(struct reiserfs_transaction_handle *, struct super_block *p_s_sb, unsigned long) ; int journal_begin(struct reiserfs_transaction_handle *, struct super_block *p_s_sb, unsigned long) ;
struct super_block *reiserfs_get_super(kdev_t dev) ;
void flush_async_commits(struct super_block *p_s_sb) ; void flush_async_commits(struct super_block *p_s_sb) ;
int buffer_journaled(const struct buffer_head *bh) ; int buffer_journaled(const struct buffer_head *bh) ;
int mark_buffer_journal_new(struct buffer_head *bh) ; int mark_buffer_journal_new(struct buffer_head *bh) ;
int reiserfs_sync_all_buffers(kdev_t dev, int wait) ;
int reiserfs_sync_buffers(kdev_t dev, int wait) ;
int reiserfs_add_page_to_flush_list(struct reiserfs_transaction_handle *, int reiserfs_add_page_to_flush_list(struct reiserfs_transaction_handle *,
struct inode *, struct buffer_head *) ; struct inode *, struct buffer_head *) ;
int reiserfs_remove_page_from_flush_list(struct reiserfs_transaction_handle *, int reiserfs_remove_page_from_flush_list(struct reiserfs_transaction_handle *,
......
...@@ -160,7 +160,7 @@ struct reiserfs_transaction_handle { ...@@ -160,7 +160,7 @@ struct reiserfs_transaction_handle {
int t_blocks_allocated ; /* number of blocks this writer allocated */ int t_blocks_allocated ; /* number of blocks this writer allocated */
unsigned long t_trans_id ; /* sanity check, equals the current trans id */ unsigned long t_trans_id ; /* sanity check, equals the current trans id */
struct super_block *t_super ; /* super for this FS when journal_begin was struct super_block *t_super ; /* super for this FS when journal_begin was
called. saves calls to reiserfs_get_super */ called. */
} ; } ;
/* /*
......
...@@ -10,7 +10,6 @@ ...@@ -10,7 +10,6 @@
#define _LINUX_SMB_H #define _LINUX_SMB_H
#include <linux/types.h> #include <linux/types.h>
#include <linux/kdev_t.h>
enum smb_protocol { enum smb_protocol {
SMB_PROTOCOL_NONE, SMB_PROTOCOL_NONE,
...@@ -85,7 +84,6 @@ struct smb_fattr { ...@@ -85,7 +84,6 @@ struct smb_fattr {
nlink_t f_nlink; nlink_t f_nlink;
uid_t f_uid; uid_t f_uid;
gid_t f_gid; gid_t f_gid;
kdev_t f_rdev;
loff_t f_size; loff_t f_size;
time_t f_atime; time_t f_atime;
time_t f_mtime; time_t f_mtime;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment