Skip to contentSkip to conversation

Remove an unnecessary line in allocate_data_block.

PATCH Dongho Sim 3 participants 4 messages Jul 28, 2014 – Jul 30, 2014 F2FS file system

lore
Share & tools
lore

Dongho Sim

author
#0 lore raw

Hi, Chao.
It's my mistake.

Thanks :-)

---
 fs/f2fs/segment.c | 3 ---
 1 file changed, 3 deletions(-)
fs/f2fs/segment.c +0 -3
index 8a6e57d..7af4a8d 100644
@@ -973,14 +973,12 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
 {
 	struct sit_info *sit_i = SIT_I(sbi);
 	struct curseg_info *curseg;
-	unsigned int old_cursegno;
 
 	curseg = CURSEG_I(sbi, type);
 
 	mutex_lock(&curseg->curseg_mutex);
 
 	*new_blkaddr = NEXT_FREE_BLKADDR(sbi, curseg);
-	old_cursegno = curseg->segno;
 
 	/*
 	 * __add_sum_entry should be resided under the curseg_mutex
@@ -1001,7 +999,6 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
 	 * since SSR needs latest valid block information.
 	 */
 	refresh_sit_entry(sbi, old_blkaddr, *new_blkaddr);
-	locate_dirty_segment(sbi, old_cursegno);
 
 	mutex_unlock(&sit_i->sentry_lock);
 
Signature · 8 lines
1.9.1

------- Original Message -------
Sender : ?超<[email protected]> 工程?/SRC-Nanjing-Mobile Solution Lab/삼성전자
Date : 2014-07-28 16:21 (GMT+09:00)
Title : Re: [f2fs-dev] [PATCH] Remove an unnecessary line in allocate_data_block.

Hi Dongho,
Quoted 21 lines

----- Original Message -----

From: "Dongho Sim"
Sent: Monday, July 28, 2014 1:51 PM
To: "Chao Yu"
Cc: [email protected], [email protected] Subject: Re: [f2fs-dev] [PATCH] Remove an unnecessary line in allocate_data_block.

Yes, there was another one.
Thanks Chao, :-)

Signed-off-by Dongho Sim
---
 fs/f2fs/segment.c | 2 --
 1 file changed, 2 deletions(-)
fs/f2fs/segment.c +0 -0
index 8a6e57d..3ab7749 100644

fs/f2fs/segment.c void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page, · line 983

Quoted 4 lines
fs/f2fs/segment.c +0 -1
@@ -980,7 +980,6 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
        mutex_lock(&curseg->curseg_mutex);
 
        *new_blkaddr = NEXT_FREE_BLKADDR(sbi, curseg);
-       old_cursegno = curseg->segno;

The definition of old_cursegno also should be removed.

Thanks,
Yu

Quoted 71 lines
fs/f2fs/segment.c +0 -2
        /*
         * __add_sum_entry should be resided under the curseg_mutex
@@ -1001,7 +1000,6 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
         * since SSR needs latest valid block information.
         */
        refresh_sit_entry(sbi, old_blkaddr, *new_blkaddr);
-       locate_dirty_segment(sbi, old_cursegno);
 
        mutex_unlock(&sit_i->sentry_lock);
 
--

1.9.1

------- Original Message -------
Sender : Chao Yu
Date : 2014-07-28 14:35 (GMT+09:00)
Title : RE: [f2fs-dev] [PATCH] Remove an unnecessary line in allocate_data_block.

Hi Dongho,

Quoted 11 lines

-----Original Message-----
From: Dongho Sim [mailto:[email protected]]
Sent: Monday, July 28, 2014 7:03 AM
To: [email protected]; [email protected]
Subject: [f2fs-dev] [PATCH] Remove an unnecessary line in allocate_data_block.

Hi. There was an unnecessary line in function, allocate_data_block. It is already done in
refresh_sit_entry(sbi, old_blkaddr, *new_blkaddr);

Thanks.

Agreed,
How about removing old_cursegno too as it's no longer used in allocate_data_block?

Thanks,
Yu

Quoted 22 lines
Signed-off-by Dongho Sim
---
 fs/f2fs/segment.c | 1 -
 1 file changed, 1 deletion(-)
fs/f2fs/segment.c +0 -2
index 8a6e57d..a3c7aae 100644
@@ -1001,7 +1001,6 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
  * since SSR needs latest valid block information.
  */
  refresh_sit_entry(sbi, old_blkaddr, *new_blkaddr);
- locate_dirty_segment(sbi, old_cursegno);
 
  mutex_unlock(&sit_i->sentry_lock);
 
--

1.9.1
------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and

Quoted 8 lines

search up to 200,000 lines of code with a free copy of Black Duck Code Sight - the same software that powers the world's largest code search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
_______________________________________________
Linux-f2fs-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

------------------------------------------------------------------------------
Infragistics Professional

Quoted 8 lines

Build stunning WinForms apps today!
Reboot your WinForms applications with our WinForms controls. Build a bridge from your legacy apps to the future.
http://pubads.g.doubleclick.net/gampad/clk?id=153845071&iu=/4140/ostg.clktrk
_______________________________________________
Linux-f2fs-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

------------------------------------------------------------------------------
Infragistics Professional
Build stunning WinForms apps today!
Reboot your WinForms applications with our WinForms controls. Build a bridge from your legacy apps to the future.
http://pubads.g.doubleclick.net/gampad/clk?id=153845071&iu=/4140/ostg.clktrk
_______________________________________________
Linux-f2fs-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

maintainer
#1 lore raw

Hi Dongho,

At first, please write a patch under the correct rule. (e.g., description)

About this change, it's negative.
When considering SSR, we need to take care of the following scenario.
- old segno : X
- new address : Z
- old curseg : Y
This means, a new block is supposed to be written to Z from X. And Z is newly allocated in the same path from Y.

In that case, we should trigger locate_dirty_segment for Y, since it was a current_segment and can be dirty owing to SSR. But that was not included in the dirty list.

Thanks,

Quoted 157 lines · Dongho Sim

Hi, Chao.
It's my mistake.

Thanks :-)

---
 fs/f2fs/segment.c | 3 ---
 1 file changed, 3 deletions(-)
fs/f2fs/segment.c +0 -3
index 8a6e57d..7af4a8d 100644
@@ -973,14 +973,12 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
 {
 	struct sit_info *sit_i = SIT_I(sbi);
 	struct curseg_info *curseg;
-	unsigned int old_cursegno;
 
 	curseg = CURSEG_I(sbi, type);
 
 	mutex_lock(&curseg->curseg_mutex);
 
 	*new_blkaddr = NEXT_FREE_BLKADDR(sbi, curseg);
-	old_cursegno = curseg->segno;
 
 	/*
 	 * __add_sum_entry should be resided under the curseg_mutex
@@ -1001,7 +999,6 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
 	 * since SSR needs latest valid block information.
 	 */
 	refresh_sit_entry(sbi, old_blkaddr, *new_blkaddr);
-	locate_dirty_segment(sbi, old_cursegno);
 
 	mutex_unlock(&sit_i->sentry_lock);
 
Signature · 8 lines
1.9.1

------- Original Message -------
Sender : ?超<[email protected]> 工程?/SRC-Nanjing-Mobile Solution Lab/삼성전자
Date : 2014-07-28 16:21 (GMT+09:00)
Title : Re: [f2fs-dev] [PATCH] Remove an unnecessary line in allocate_data_block.

Hi Dongho,
Quoted 21 lines

----- Original Message -----

From: "Dongho Sim"
Sent: Monday, July 28, 2014 1:51 PM
To: "Chao Yu"
Cc: [email protected], [email protected] Subject: Re: [f2fs-dev] [PATCH] Remove an unnecessary line in allocate_data_block.

Yes, there was another one.
Thanks Chao, :-)

Signed-off-by Dongho Sim
---
 fs/f2fs/segment.c | 2 --
 1 file changed, 2 deletions(-)
fs/f2fs/segment.c +0 -0
index 8a6e57d..3ab7749 100644

fs/f2fs/segment.c void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page, · line 983

Quoted 4 lines
fs/f2fs/segment.c +0 -1
@@ -980,7 +980,6 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
        mutex_lock(&curseg->curseg_mutex);
 
        *new_blkaddr = NEXT_FREE_BLKADDR(sbi, curseg);
-       old_cursegno = curseg->segno;

The definition of old_cursegno also should be removed.

Thanks,
Yu

Quoted 79 lines
fs/f2fs/segment.c +0 -2
        /*
         * __add_sum_entry should be resided under the curseg_mutex
@@ -1001,7 +1000,6 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
         * since SSR needs latest valid block information.
         */
        refresh_sit_entry(sbi, old_blkaddr, *new_blkaddr);
-       locate_dirty_segment(sbi, old_cursegno);
 
        mutex_unlock(&sit_i->sentry_lock);
 
--

1.9.1

------- Original Message -------
Sender : Chao Yu
Date : 2014-07-28 14:35 (GMT+09:00)
Title : RE: [f2fs-dev] [PATCH] Remove an unnecessary line in allocate_data_block.

Hi Dongho,

Quoted 11 lines

-----Original Message-----
From: Dongho Sim [mailto:[email protected]]
Sent: Monday, July 28, 2014 7:03 AM
To: [email protected]; [email protected]
Subject: [f2fs-dev] [PATCH] Remove an unnecessary line in allocate_data_block.

Hi. There was an unnecessary line in function, allocate_data_block. It is already done in
refresh_sit_entry(sbi, old_blkaddr, *new_blkaddr);

Thanks.

Agreed,
How about removing old_cursegno too as it's no longer used in allocate_data_block?

Thanks,
Yu

Quoted 22 lines
Signed-off-by Dongho Sim
---
 fs/f2fs/segment.c | 1 -
 1 file changed, 1 deletion(-)
fs/f2fs/segment.c +0 -2
index 8a6e57d..a3c7aae 100644
@@ -1001,7 +1001,6 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
  * since SSR needs latest valid block information.
  */
  refresh_sit_entry(sbi, old_blkaddr, *new_blkaddr);
- locate_dirty_segment(sbi, old_cursegno);
 
  mutex_unlock(&sit_i->sentry_lock);
 
--

1.9.1
------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and

Quoted 8 lines

search up to 200,000 lines of code with a free copy of Black Duck Code Sight - the same software that powers the world's largest code search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
_______________________________________________
Linux-f2fs-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

------------------------------------------------------------------------------
Infragistics Professional
Build stunning WinForms apps today!
Reboot your WinForms applications with our WinForms controls. Build a bridge from your legacy apps to the future.
http://pubads.g.doubleclick.net/gampad/clk?id=153845071&iu=/4140/ostg.clktrk
_______________________________________________
Linux-f2fs-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

------------------------------------------------------------------------------
Infragistics Professional
Build stunning WinForms apps today!
Reboot your WinForms applications with our WinForms controls. Build a bridge from your legacy apps to the future.
http://pubads.g.doubleclick.net/gampad/clk?id=153845071&iu=/4140/ostg.clktrk
_______________________________________________
Linux-f2fs-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

#2 lore raw
Quoted 13 lines · Jaegeuk Kim

Hi Dongho,

At first, please write a patch under the correct rule. (e.g., description)

About this change, it's negative.
When considering SSR, we need to take care of the following scenario.
- old segno : X
- new address : Z
- old curseg : Y
This means, a new block is supposed to be written to Z from X. And Z is newly allocated in the same path from Y.

Quoted 6 lines

In that case, we should trigger locate_dirty_segment for Y, since it was a current_segment and can be dirty owing to SSR. But that was not included in the dirty list.

Thanks,

We already choosed old curseg(Y) and then we allocate new address(Z) from old curseg(Y). After that we call refresh_sit_entry(old address, new address). In the funcation, we call locate_dirty_segment with old seg and old curseg. So calling locate_dirty_segment after refresh_sit_entry again is redundant.

Thanks,

Quoted 159 lines · Dongho Sim
Quoted 157 lines

Hi, Chao.
It's my mistake.

Thanks :-)

---
 fs/f2fs/segment.c | 3 ---
 1 file changed, 3 deletions(-)
fs/f2fs/segment.c +0 -3
index 8a6e57d..7af4a8d 100644
@@ -973,14 +973,12 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
 {
 	struct sit_info *sit_i = SIT_I(sbi);
 	struct curseg_info *curseg;
-	unsigned int old_cursegno;
 
 	curseg = CURSEG_I(sbi, type);
 
 	mutex_lock(&curseg->curseg_mutex);
 
 	*new_blkaddr = NEXT_FREE_BLKADDR(sbi, curseg);
-	old_cursegno = curseg->segno;
 
 	/*
 	 * __add_sum_entry should be resided under the curseg_mutex
@@ -1001,7 +999,6 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
 	 * since SSR needs latest valid block information.
 	 */
 	refresh_sit_entry(sbi, old_blkaddr, *new_blkaddr);
-	locate_dirty_segment(sbi, old_cursegno);
 
 	mutex_unlock(&sit_i->sentry_lock);
 
Signature · 8 lines
1.9.1

------- Original Message -------
Sender : ?超<[email protected]> 工程?/SRC-Nanjing-Mobile Solution Lab/삼성전자
Date : 2014-07-28 16:21 (GMT+09:00)
Title : Re: [f2fs-dev] [PATCH] Remove an unnecessary line in allocate_data_block.

Hi Dongho,
Quoted 21 lines

----- Original Message -----

From: "Dongho Sim"
Sent: Monday, July 28, 2014 1:51 PM
To: "Chao Yu"
Cc: [email protected], [email protected] Subject: Re: [f2fs-dev] [PATCH] Remove an unnecessary line in allocate_data_block.

Yes, there was another one.
Thanks Chao, :-)

Signed-off-by Dongho Sim
---
 fs/f2fs/segment.c | 2 --
 1 file changed, 2 deletions(-)
fs/f2fs/segment.c +0 -0
index 8a6e57d..3ab7749 100644

fs/f2fs/segment.c void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page, · line 983

Quoted 4 lines
fs/f2fs/segment.c +0 -1
@@ -980,7 +980,6 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
        mutex_lock(&curseg->curseg_mutex);
 
        *new_blkaddr = NEXT_FREE_BLKADDR(sbi, curseg);
-       old_cursegno = curseg->segno;

The definition of old_cursegno also should be removed.

Thanks,
Yu

Quoted 79 lines
fs/f2fs/segment.c +0 -2
        /*
         * __add_sum_entry should be resided under the curseg_mutex
@@ -1001,7 +1000,6 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
         * since SSR needs latest valid block information.
         */
        refresh_sit_entry(sbi, old_blkaddr, *new_blkaddr);
-       locate_dirty_segment(sbi, old_cursegno);
 
        mutex_unlock(&sit_i->sentry_lock);
 
--

1.9.1

------- Original Message -------
Sender : Chao Yu
Date : 2014-07-28 14:35 (GMT+09:00)
Title : RE: [f2fs-dev] [PATCH] Remove an unnecessary line in allocate_data_block.

Hi Dongho,

Quoted 11 lines

-----Original Message-----
From: Dongho Sim [mailto:[email protected]]
Sent: Monday, July 28, 2014 7:03 AM
To: [email protected]; [email protected]
Subject: [f2fs-dev] [PATCH] Remove an unnecessary line in allocate_data_block.

Hi. There was an unnecessary line in function, allocate_data_block. It is already done in
refresh_sit_entry(sbi, old_blkaddr, *new_blkaddr);

Thanks.

Agreed,
How about removing old_cursegno too as it's no longer used in allocate_data_block?

Thanks,
Yu

Quoted 22 lines
Signed-off-by Dongho Sim
---
 fs/f2fs/segment.c | 1 -
 1 file changed, 1 deletion(-)
fs/f2fs/segment.c +0 -2
index 8a6e57d..a3c7aae 100644
@@ -1001,7 +1001,6 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
  * since SSR needs latest valid block information.
  */
  refresh_sit_entry(sbi, old_blkaddr, *new_blkaddr);
- locate_dirty_segment(sbi, old_cursegno);
 
  mutex_unlock(&sit_i->sentry_lock);
 
--

1.9.1
------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and

Quoted 8 lines

search up to 200,000 lines of code with a free copy of Black Duck Code Sight - the same software that powers the world's largest code search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
_______________________________________________
Linux-f2fs-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

------------------------------------------------------------------------------
Infragistics Professional
Build stunning WinForms apps today!
Reboot your WinForms applications with our WinForms controls. Build a bridge from your legacy apps to the future.
http://pubads.g.doubleclick.net/gampad/clk?id=153845071&iu=/4140/ostg.clktrk
_______________________________________________
Linux-f2fs-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

Quoted 10 lines

------------------------------------------------------------------------------
Infragistics Professional
Build stunning WinForms apps today!
Reboot your WinForms applications with our WinForms controls. Build a bridge from your legacy apps to the future.
http://pubads.g.doubleclick.net/gampad/clk?id=153845071&iu=/4140/ostg.clktrk
_______________________________________________
Linux-f2fs-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

------------------------------------------------------------------------------
Infragistics Professional
Build stunning WinForms apps today!
Reboot your WinForms applications with our WinForms controls. Build a bridge from your legacy apps to the future.
http://pubads.g.doubleclick.net/gampad/clk?id=153845071&iu=/4140/ostg.clktrk
_______________________________________________
Linux-f2fs-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

maintainer
#3 lore raw
Quoted 18 lines · Changman Lee
Quoted 17 lines · Jaegeuk Kim

Hi Dongho,

At first, please write a patch under the correct rule. (e.g., description)

About this change, it's negative.
When considering SSR, we need to take care of the following scenario.
- old segno : X
- new address : Z
- old curseg : Y
This means, a new block is supposed to be written to Z from X. And Z is newly allocated in the same path from Y.

In that case, we should trigger locate_dirty_segment for Y, since it was a current_segment and can be dirty owing to SSR. But that was not included in the dirty list.

Quoted 7 lines
Quoted 2 lines

Thanks,

We already choosed old curseg(Y) and then we allocate new address(Z) from old curseg(Y). After that we call refresh_sit_entry(old address, new address). In the funcation, we call locate_dirty_segment with old seg and old curseg. So calling locate_dirty_segment after refresh_sit_entry again is redundant.

Aha, the new address is always allocated from old_curseg. That's right. :)

Dongho,
Please, write a patch including this discussion and post v2.

Thanks,

Quoted 172 lines

Thanks,

Quoted 169 lines · Dongho Sim
Quoted 157 lines

Hi, Chao.
It's my mistake.

Thanks :-)

---
 fs/f2fs/segment.c | 3 ---
 1 file changed, 3 deletions(-)
fs/f2fs/segment.c +0 -3
index 8a6e57d..7af4a8d 100644
@@ -973,14 +973,12 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
 {
 	struct sit_info *sit_i = SIT_I(sbi);
 	struct curseg_info *curseg;
-	unsigned int old_cursegno;
 
 	curseg = CURSEG_I(sbi, type);
 
 	mutex_lock(&curseg->curseg_mutex);
 
 	*new_blkaddr = NEXT_FREE_BLKADDR(sbi, curseg);
-	old_cursegno = curseg->segno;
 
 	/*
 	 * __add_sum_entry should be resided under the curseg_mutex
@@ -1001,7 +999,6 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
 	 * since SSR needs latest valid block information.
 	 */
 	refresh_sit_entry(sbi, old_blkaddr, *new_blkaddr);
-	locate_dirty_segment(sbi, old_cursegno);
 
 	mutex_unlock(&sit_i->sentry_lock);
 
Signature · 8 lines
1.9.1

------- Original Message -------
Sender : ?超<[email protected]> 工程?/SRC-Nanjing-Mobile Solution Lab/삼성전자
Date : 2014-07-28 16:21 (GMT+09:00)
Title : Re: [f2fs-dev] [PATCH] Remove an unnecessary line in allocate_data_block.

Hi Dongho,
Quoted 21 lines

----- Original Message -----

From: "Dongho Sim"
Sent: Monday, July 28, 2014 1:51 PM
To: "Chao Yu"
Cc: [email protected], [email protected] Subject: Re: [f2fs-dev] [PATCH] Remove an unnecessary line in allocate_data_block.

Yes, there was another one.
Thanks Chao, :-)

Signed-off-by Dongho Sim
---
 fs/f2fs/segment.c | 2 --
 1 file changed, 2 deletions(-)
fs/f2fs/segment.c +0 -0
index 8a6e57d..3ab7749 100644

fs/f2fs/segment.c void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page, · line 983

Quoted 4 lines
fs/f2fs/segment.c +0 -1
@@ -980,7 +980,6 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
        mutex_lock(&curseg->curseg_mutex);
 
        *new_blkaddr = NEXT_FREE_BLKADDR(sbi, curseg);
-       old_cursegno = curseg->segno;

The definition of old_cursegno also should be removed.

Thanks,
Yu

Quoted 79 lines
fs/f2fs/segment.c +0 -2
        /*
         * __add_sum_entry should be resided under the curseg_mutex
@@ -1001,7 +1000,6 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
         * since SSR needs latest valid block information.
         */
        refresh_sit_entry(sbi, old_blkaddr, *new_blkaddr);
-       locate_dirty_segment(sbi, old_cursegno);
 
        mutex_unlock(&sit_i->sentry_lock);
 
--

1.9.1

------- Original Message -------
Sender : Chao Yu
Date : 2014-07-28 14:35 (GMT+09:00)
Title : RE: [f2fs-dev] [PATCH] Remove an unnecessary line in allocate_data_block.

Hi Dongho,

Quoted 11 lines

-----Original Message-----
From: Dongho Sim [mailto:[email protected]]
Sent: Monday, July 28, 2014 7:03 AM
To: [email protected]; [email protected]
Subject: [f2fs-dev] [PATCH] Remove an unnecessary line in allocate_data_block.

Hi. There was an unnecessary line in function, allocate_data_block. It is already done in
refresh_sit_entry(sbi, old_blkaddr, *new_blkaddr);

Thanks.

Agreed,
How about removing old_cursegno too as it's no longer used in allocate_data_block?

Thanks,
Yu

Quoted 22 lines
Signed-off-by Dongho Sim
---
 fs/f2fs/segment.c | 1 -
 1 file changed, 1 deletion(-)
fs/f2fs/segment.c +0 -2
index 8a6e57d..a3c7aae 100644
@@ -1001,7 +1001,6 @@ void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page,
  * since SSR needs latest valid block information.
  */
  refresh_sit_entry(sbi, old_blkaddr, *new_blkaddr);
- locate_dirty_segment(sbi, old_cursegno);
 
  mutex_unlock(&sit_i->sentry_lock);
 
--

1.9.1
------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and

Quoted 8 lines

search up to 200,000 lines of code with a free copy of Black Duck Code Sight - the same software that powers the world's largest code search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
_______________________________________________
Linux-f2fs-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

------------------------------------------------------------------------------
Infragistics Professional
Build stunning WinForms apps today!
Reboot your WinForms applications with our WinForms controls. Build a bridge from your legacy apps to the future.
http://pubads.g.doubleclick.net/gampad/clk?id=153845071&iu=/4140/ostg.clktrk
_______________________________________________
Linux-f2fs-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

------------------------------------------------------------------------------
Infragistics Professional
Build stunning WinForms apps today!
Reboot your WinForms applications with our WinForms controls. Build a bridge from your legacy apps to the future.
http://pubads.g.doubleclick.net/gampad/clk?id=153845071&iu=/4140/ostg.clktrk
_______________________________________________
Linux-f2fs-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

------------------------------------------------------------------------------
Infragistics Professional
Build stunning WinForms apps today!
Reboot your WinForms applications with our WinForms controls. Build a bridge from your legacy apps to the future.
http://pubads.g.doubleclick.net/gampad/clk?id=153845071&iu=/4140/ostg.clktrk
_______________________________________________
Linux-f2fs-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel