Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
061dbc6b
Commit
061dbc6b
authored
Jul 26, 2010
by
Al Viro
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
convert btrfs
Signed-off-by:
Al Viro
<
viro@zeniv.linux.org.uk
>
parent
a7f9fb20
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
9 deletions
+6
-9
fs/btrfs/super.c
fs/btrfs/super.c
+6
-9
No files found.
fs/btrfs/super.c
View file @
061dbc6b
...
@@ -560,8 +560,8 @@ static int btrfs_test_super(struct super_block *s, void *data)
...
@@ -560,8 +560,8 @@ static int btrfs_test_super(struct super_block *s, void *data)
* Note: This is based on get_sb_bdev from fs/super.c with a few additions
* Note: This is based on get_sb_bdev from fs/super.c with a few additions
* for multiple device setup. Make sure to keep it in sync.
* for multiple device setup. Make sure to keep it in sync.
*/
*/
static
int
btrfs_get_sb
(
struct
file_system_type
*
fs_type
,
int
flags
,
static
struct
dentry
*
btrfs_mount
(
struct
file_system_type
*
fs_type
,
int
flags
,
const
char
*
dev_name
,
void
*
data
,
struct
vfsmount
*
mnt
)
const
char
*
dev_name
,
void
*
data
)
{
{
struct
block_device
*
bdev
=
NULL
;
struct
block_device
*
bdev
=
NULL
;
struct
super_block
*
s
;
struct
super_block
*
s
;
...
@@ -580,7 +580,7 @@ static int btrfs_get_sb(struct file_system_type *fs_type, int flags,
...
@@ -580,7 +580,7 @@ static int btrfs_get_sb(struct file_system_type *fs_type, int flags,
&
subvol_name
,
&
subvol_objectid
,
&
subvol_name
,
&
subvol_objectid
,
&
fs_devices
);
&
fs_devices
);
if
(
error
)
if
(
error
)
return
error
;
return
ERR_PTR
(
error
)
;
error
=
btrfs_scan_one_device
(
dev_name
,
mode
,
fs_type
,
&
fs_devices
);
error
=
btrfs_scan_one_device
(
dev_name
,
mode
,
fs_type
,
&
fs_devices
);
if
(
error
)
if
(
error
)
...
@@ -656,11 +656,8 @@ static int btrfs_get_sb(struct file_system_type *fs_type, int flags,
...
@@ -656,11 +656,8 @@ static int btrfs_get_sb(struct file_system_type *fs_type, int flags,
root
=
new_root
;
root
=
new_root
;
}
}
mnt
->
mnt_sb
=
s
;
mnt
->
mnt_root
=
root
;
kfree
(
subvol_name
);
kfree
(
subvol_name
);
return
0
;
return
root
;
error_s:
error_s:
error
=
PTR_ERR
(
s
);
error
=
PTR_ERR
(
s
);
...
@@ -669,7 +666,7 @@ static int btrfs_get_sb(struct file_system_type *fs_type, int flags,
...
@@ -669,7 +666,7 @@ static int btrfs_get_sb(struct file_system_type *fs_type, int flags,
error_free_subvol_name:
error_free_subvol_name:
kfree
(
subvol_name
);
kfree
(
subvol_name
);
error:
error:
return
error
;
return
ERR_PTR
(
error
)
;
}
}
static
int
btrfs_remount
(
struct
super_block
*
sb
,
int
*
flags
,
char
*
data
)
static
int
btrfs_remount
(
struct
super_block
*
sb
,
int
*
flags
,
char
*
data
)
...
@@ -746,7 +743,7 @@ static int btrfs_statfs(struct dentry *dentry, struct kstatfs *buf)
...
@@ -746,7 +743,7 @@ static int btrfs_statfs(struct dentry *dentry, struct kstatfs *buf)
static
struct
file_system_type
btrfs_fs_type
=
{
static
struct
file_system_type
btrfs_fs_type
=
{
.
owner
=
THIS_MODULE
,
.
owner
=
THIS_MODULE
,
.
name
=
"btrfs"
,
.
name
=
"btrfs"
,
.
get_sb
=
btrfs_get_sb
,
.
mount
=
btrfs_mount
,
.
kill_sb
=
kill_anon_super
,
.
kill_sb
=
kill_anon_super
,
.
fs_flags
=
FS_REQUIRES_DEV
,
.
fs_flags
=
FS_REQUIRES_DEV
,
};
};
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment