diff options
author | Namjae Jeon <namjae.jeon@samsung.com> | 2013-06-16 02:49:11 +0200 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk.kim@samsung.com> | 2013-07-02 01:48:14 +0200 |
commit | 8736fbf00372dcc0bc7b04b86d737eb5db31fff6 (patch) | |
tree | 32daf73a5157e2a72cae11fb9fdace1f78488cac /fs/f2fs/gc.c | |
parent | f2fs: fix an endian conversion bug detected by sparse (diff) | |
download | linux-8736fbf00372dcc0bc7b04b86d737eb5db31fff6.tar.xz linux-8736fbf00372dcc0bc7b04b86d737eb5db31fff6.zip |
f2fs: optimize the init_dirty_segmap function
Optimize the while loop condition
Since this condition will always be true and while loop will
be terminated by the following condition in code:
if (segno >= TOTAL_SEGS(sbi))
break;
Hence we can replace the while loop condition with while(1)
instead of always checking for segno to be less than Total segs.
Also we do not need to use TOTAL_SEGS() everytime. We can store
this value in a local variable since this value is constant.
Signed-off-by: Namjae Jeon <namjae.jeon@samsung.com>
Signed-off-by: Pankaj Kumar <pankaj.km@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>
Diffstat (limited to '')
0 files changed, 0 insertions, 0 deletions