Age | Commit message (Collapse) | Author | Files | Lines |
|
This patch changes the naming of orphan-related data structures to use as
inode numbers managed globally.
Later, we can use this facility for managing any inode number lists.
Reviewed-by: Chao Yu <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
Signed-off-by: Gu Zheng <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
The NM_WOUT_THRESHOLD is now obsolete since f2fs starts to control on a basis
of the memory footprint.
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
The stat_show is just to show the current status of f2fs.
So, we can remove all the there-in locks.
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
This patch shows the counts of checkpoint in f2fs' status.
Signed-off-by: Changman Lee <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
This patch adds NODE_MAPPING which is similar as META_MAPPING introduced by
Gu Zheng.
Cc: Gu Zheng <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
Introduce help function META_MAPPING() to get the cache meta blocks'
address space.
Signed-off-by: Gu Zheng <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
Fixed a variety of trivial checkpatch warnings. The only delta should
be some minor formatting on log strings that were split / too long.
Signed-off-by: Chris Fries <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
Support for f2fs-tools/tools/f2stat to monitor
/sys/kernel/debug/f2fs/status
Signed-off-by: Changman Lee <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
This patch adds the number of inline_data files into the status information.
Note that the number is reset whenever the filesystem is newly mounted.
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
This minor change for the naming conventions of debugfs_root
to avoid any possible conflicts to the other filesystem.
Signed-off-by: Younger Liu <[email protected]>
Cc: Younger Liu <[email protected]>
Cc: Jaegeuk Kim <[email protected]>
[Jaegeuk Kim: change the patch name]
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
When debugfs_create_file() failed in f2fs_create_root_stats(),
debugfs_root should be remove.
Signed-off-by: Younger Liu <[email protected]>
Cc: Younger Liu <[email protected]>
Cc: Jaegeuk Kim <[email protected]>
Reviewed-by: Chao Yu <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
For string without format specifiers, using seq_puts()/seq_putc()
instead of seq_printf().
Signed-off-by: Gu Zheng <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
Add a help func F2FS_STAT() to get the f2fs_stat_info.
Signed-off-by: Gu Zheng <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
We can do this, since now we use a global mutex, f2fs_stat_mutex to protect its
list operations.
Signed-off-by: Jianpeng Ma <[email protected]>
[Jaegeuk Kim: add description]
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
debug entry.
Signed-off-by: Haicheng Li <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
This patch removes a bitmap for victim segments selected by foreground GC, and
modifies the other bitmap for victim segments selected by background GC.
1) foreground GC bitmap
: We don't need to manage this, since we just only one previous victim section
number instead of the whole victim history.
The f2fs uses the victim section number in order not to allocate currently
GC'ed section to current active logs.
2) background GC bitmap
: This bitmap is used to avoid selecting victims repeatedly by background GCs.
In addition, the victims are able to be selected by foreground GCs, since
there is no need to read victim blocks during foreground GCs.
By the fact that the foreground GC reclaims segments in a section unit, it'd
be better to manage this bitmap based on the section granularity.
Reviewed-by: Namjae Jeon <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
Let's use a macro to get the total number of sections.
Reviewed-by: Namjae Jeon <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
In file status, it can't distinguish between different devices.
So add device name to do this function.
Signed-off-by: Jianpeng Ma <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
As the "status" debugfs entry will be maintained for entire F2FS filesystem
irrespective of the number of partitions.
So, we can move the initialization to the init part of the f2fs and destroy will
be done from exit part. After making changes, for individual partition mount -
entry creation code will not be executed.
Signed-off-by: Jianpeng Ma <[email protected]>
Signed-off-by: Namjae Jeon <[email protected]>
Signed-off-by: Amit Sahrawat <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
There is an race condition between umounting f2fs and reading f2fs/status, which
results in oops.
Fox example:
Thread A Thread B
umount f2fs cat f2fs/status
f2fs_destroy_stats() { stat_show() {
list_for_each_entry_safe(&f2fs_stat_list)
list_del(&si->stat_list);
mutex_lock(&si->stat_lock);
si->sbi = NULL;
mutex_unlock(&si->stat_lock);
kfree(sbi->stat_info);
} mutex_lock(&si->stat_lock) <- si is gone.
...
}
Solution with a global lock: f2fs_stat_mutex:
Thread A Thread B
umount f2fs cat f2fs/status
f2fs_destroy_stats() { stat_show() {
mutex_lock(&f2fs_stat_mutex);
list_del(&si->stat_list);
mutex_unlock(&f2fs_stat_mutex);
kfree(sbi->stat_info); mutex_lock(&f2fs_stat_mutex);
} list_for_each_entry_safe(&f2fs_stat_list)
...
mutex_unlock(&f2fs_stat_mutex);
}
Signed-off-by: Jianpeng Ma <[email protected]>
[[email protected]: fix typos, description, and remove the existing lock]
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
Update partition info output under debug FS to reflect segment layout correctly.
Signed-off-by: Huajun Li <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
As pointed out by Randy Dunlap, this patch removes all usage of "/**" for comment
blocks. Instead, just use "/*".
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
This patch should resolve the bugs reported by the sparse tool.
Initial reports were written by "kbuild test robot" managed by fengguang.wu.
In my local machines, I've tested also by running:
> make C=2 CF="-D__CHECK_ENDIAN__"
Accordingly, I've found lots of warnings and bugs related to the endian
conversion. And I've fixed all at this moment.
Signed-off-by: Jaegeuk Kim <[email protected]>
|
|
This moves all of the f2fs debugging files into debugfs. The files are
located in /sys/kernel/debug/f2fs/
Note, I think we are generating all of the same information in each of
the files for every unique f2fs filesystem in the machine. This copies
the functionality that was present in the proc files, but this should be
fixed up in the future.
Signed-off-by: Greg Kroah-Hartman <[email protected]>
[[email protected]: merged 3 debugfs entries into a *status* entry]
Signed-off-by: Jaegeuk Kim <[email protected]>
|