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
e71775ef
Commit
e71775ef
authored
Nov 18, 2003
by
Andrew Morton
Committed by
Linus Torvalds
Nov 18, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PATCH] remove ext2_reserve_inode()
It now has no callers.
parent
0fa7a1a9
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
35 deletions
+0
-35
fs/ext2/ialloc.c
fs/ext2/ialloc.c
+0
-35
No files found.
fs/ext2/ialloc.c
View file @
e71775ef
...
...
@@ -63,41 +63,6 @@ read_inode_bitmap(struct super_block * sb, unsigned long block_group)
return
bh
;
}
/*
* Speculatively reserve an inode in a blockgroup which used to have some
* spare ones. Later, when we come to actually claim the inode in the bitmap
* it may be that it was taken. In that case the allocator will undo this
* reservation and try again.
*
* The inode allocator does not physically alter the superblock. But we still
* set sb->s_dirt, because the superblock was "logically" altered - we need to
* go and add up the free inodes counts again and flush out the superblock.
*/
static
void
ext2_reserve_inode
(
struct
super_block
*
sb
,
int
group
,
int
dir
)
{
struct
ext2_group_desc
*
desc
;
struct
buffer_head
*
bh
;
desc
=
ext2_get_group_desc
(
sb
,
group
,
&
bh
);
if
(
!
desc
)
{
ext2_error
(
sb
,
"ext2_reserve_inode"
,
"can't get descriptor for group %d"
,
group
);
return
;
}
spin_lock
(
sb_bgl_lock
(
EXT2_SB
(
sb
),
group
));
desc
->
bg_free_inodes_count
=
cpu_to_le16
(
le16_to_cpu
(
desc
->
bg_free_inodes_count
)
-
1
);
if
(
dir
)
desc
->
bg_used_dirs_count
=
cpu_to_le16
(
le16_to_cpu
(
desc
->
bg_used_dirs_count
)
+
1
);
spin_unlock
(
sb_bgl_lock
(
EXT2_SB
(
sb
),
group
));
if
(
dir
)
percpu_counter_inc
(
&
EXT2_SB
(
sb
)
->
s_dirs_counter
);
sb
->
s_dirt
=
1
;
mark_buffer_dirty
(
bh
);
}
static
void
ext2_release_inode
(
struct
super_block
*
sb
,
int
group
,
int
dir
)
{
struct
ext2_group_desc
*
desc
;
...
...
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