stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* FAILED: patch "[PATCH] btrfs: release metadata before running delayed refs" failed to apply to 4.4-stable tree
@ 2018-11-11 20:19 gregkh
  2018-11-20  8:11 ` [PATCH 1/3] btrfs: release metadata before running delayed refs Nikolay Borisov
  0 siblings, 1 reply; 9+ messages in thread
From: gregkh @ 2018-11-11 20:19 UTC (permalink / raw)
  To: josef, bo.liu, dsterba, nborisov, osandov; +Cc: stable


The patch below does not apply to the 4.4-stable tree.
If someone wants it applied there, or to any other stable or longterm
tree, then please email the backport, including the original git commit
id to <stable@vger.kernel.org>.

thanks,

greg k-h

------------------ original commit in Linus's tree ------------------

>From f45c752b65af46bf42963295c332865d95f97fff Mon Sep 17 00:00:00 2001
From: Josef Bacik <josef@toxicpanda.com>
Date: Fri, 28 Sep 2018 07:17:48 -0400
Subject: [PATCH] btrfs: release metadata before running delayed refs

We want to release the unused reservation we have since it refills the
delayed refs reserve, which will make everything go smoother when
running the delayed refs if we're short on our reservation.

CC: stable@vger.kernel.org # 4.4+
Reviewed-by: Omar Sandoval <osandov@fb.com>
Reviewed-by: Liu Bo <bo.liu@linux.alibaba.com>
Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Signed-off-by: Josef Bacik <josef@toxicpanda.com>
Signed-off-by: David Sterba <dsterba@suse.com>

diff --git a/fs/btrfs/transaction.c b/fs/btrfs/transaction.c
index cadc747292d9..e7f618b17b07 100644
--- a/fs/btrfs/transaction.c
+++ b/fs/btrfs/transaction.c
@@ -1932,6 +1932,9 @@ int btrfs_commit_transaction(struct btrfs_trans_handle *trans)
 		return ret;
 	}
 
+	btrfs_trans_release_metadata(trans);
+	trans->block_rsv = NULL;
+
 	/* make a pass through all the delayed refs we have so far
 	 * any runnings procs may add more while we are here
 	 */
@@ -1941,9 +1944,6 @@ int btrfs_commit_transaction(struct btrfs_trans_handle *trans)
 		return ret;
 	}
 
-	btrfs_trans_release_metadata(trans);
-	trans->block_rsv = NULL;
-
 	cur_trans = trans->transaction;
 
 	/*

^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 1/3] btrfs: release metadata before running delayed refs
  2018-11-11 20:19 FAILED: patch "[PATCH] btrfs: release metadata before running delayed refs" failed to apply to 4.4-stable tree gregkh
@ 2018-11-20  8:11 ` Nikolay Borisov
  2018-11-29 12:21   ` Greg KH
  0 siblings, 1 reply; 9+ messages in thread
From: Nikolay Borisov @ 2018-11-20  8:11 UTC (permalink / raw)
  To: stable; +Cc: josef, David Sterba

From: Josef Bacik <josef@toxicpanda.com>

We want to release the unused reservation we have since it refills the
delayed refs reserve, which will make everything go smoother when
running the delayed refs if we're short on our reservation.

CC: stable@vger.kernel.org # 4.4+
Reviewed-by: Omar Sandoval <osandov@fb.com>
Reviewed-by: Liu Bo <bo.liu@linux.alibaba.com>
Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Signed-off-by: Josef Bacik <josef@toxicpanda.com>
Signed-off-by: David Sterba <dsterba@suse.com>
---

Hello Greg, 

Here is a fixed up backport for upstream commit f45c752b65af46bf42963295c332865d95f97fff
This one applies cleanly to 4.4.y and 4.9.y
 fs/btrfs/transaction.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/fs/btrfs/transaction.c b/fs/btrfs/transaction.c
index be8eae80ff65..098016338f98 100644
--- a/fs/btrfs/transaction.c
+++ b/fs/btrfs/transaction.c
@@ -1821,6 +1821,9 @@ int btrfs_commit_transaction(struct btrfs_trans_handle *trans,
 		return ret;
 	}
 
+	btrfs_trans_release_metadata(trans, root);
+	trans->block_rsv = NULL;
+
 	/* make a pass through all the delayed refs we have so far
 	 * any runnings procs may add more while we are here
 	 */
@@ -1830,9 +1833,6 @@ int btrfs_commit_transaction(struct btrfs_trans_handle *trans,
 		return ret;
 	}
 
-	btrfs_trans_release_metadata(trans, root);
-	trans->block_rsv = NULL;
-
 	cur_trans = trans->transaction;
 
 	/*
-- 
2.17.1

^ permalink raw reply related	[flat|nested] 9+ messages in thread

* Re: [PATCH 1/3] btrfs: release metadata before running delayed refs
  2018-11-20  8:11 ` [PATCH 1/3] btrfs: release metadata before running delayed refs Nikolay Borisov
@ 2018-11-29 12:21   ` Greg KH
  2018-11-29 12:36     ` Nikolay Borisov
  2018-12-03 11:06     ` [PATCH] " Nikolay Borisov
  0 siblings, 2 replies; 9+ messages in thread
From: Greg KH @ 2018-11-29 12:21 UTC (permalink / raw)
  To: Nikolay Borisov; +Cc: stable, josef, David Sterba

On Tue, Nov 20, 2018 at 10:11:21AM +0200, Nikolay Borisov wrote:
> From: Josef Bacik <josef@toxicpanda.com>
> 
> We want to release the unused reservation we have since it refills the
> delayed refs reserve, which will make everything go smoother when
> running the delayed refs if we're short on our reservation.
> 
> CC: stable@vger.kernel.org # 4.4+
> Reviewed-by: Omar Sandoval <osandov@fb.com>
> Reviewed-by: Liu Bo <bo.liu@linux.alibaba.com>
> Reviewed-by: Nikolay Borisov <nborisov@suse.com>
> Signed-off-by: Josef Bacik <josef@toxicpanda.com>
> Signed-off-by: David Sterba <dsterba@suse.com>
> ---
> 
> Hello Greg, 
> 
> Here is a fixed up backport for upstream commit f45c752b65af46bf42963295c332865d95f97fff
> This one applies cleanly to 4.4.y and 4.9.y

What about 4.14.y?  I don't want to apply this to only 4.4 and 4.9 and
not 4.14.  Can you provide a working backport there too?

And I don't see the 2/3 patch in this series, has that already been
handled?

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH 1/3] btrfs: release metadata before running delayed refs
  2018-11-29 12:21   ` Greg KH
@ 2018-11-29 12:36     ` Nikolay Borisov
  2018-12-03 10:01       ` Greg KH
  2018-12-03 15:50       ` Sasha Levin
  2018-12-03 11:06     ` [PATCH] " Nikolay Borisov
  1 sibling, 2 replies; 9+ messages in thread
From: Nikolay Borisov @ 2018-11-29 12:36 UTC (permalink / raw)
  To: Greg KH; +Cc: stable, josef, David Sterba



On 29.11.18 г. 14:21 ч., Greg KH wrote:
> On Tue, Nov 20, 2018 at 10:11:21AM +0200, Nikolay Borisov wrote:
>> From: Josef Bacik <josef@toxicpanda.com>
>>
>> We want to release the unused reservation we have since it refills the
>> delayed refs reserve, which will make everything go smoother when
>> running the delayed refs if we're short on our reservation.
>>
>> CC: stable@vger.kernel.org # 4.4+
>> Reviewed-by: Omar Sandoval <osandov@fb.com>
>> Reviewed-by: Liu Bo <bo.liu@linux.alibaba.com>
>> Reviewed-by: Nikolay Borisov <nborisov@suse.com>
>> Signed-off-by: Josef Bacik <josef@toxicpanda.com>
>> Signed-off-by: David Sterba <dsterba@suse.com>
>> ---
>>
>> Hello Greg, 
>>
>> Here is a fixed up backport for upstream commit f45c752b65af46bf42963295c332865d95f97fff
>> This one applies cleanly to 4.4.y and 4.9.y
> 
> What about 4.14.y?  I don't want to apply this to only 4.4 and 4.9 and
> not 4.14.  Can you provide a working backport there too?

I've only made backports as a result of your "failed to apply" emails.
If there isn't a backport for 4.14 then this means it's either handled
or you didn't send such an email, or i wasn't cced

> 
> And I don't see the 2/3 patch in this series, has that already been
> handled?
> 
> thanks,
> 
> greg k-h
> 

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH 1/3] btrfs: release metadata before running delayed refs
  2018-11-29 12:36     ` Nikolay Borisov
@ 2018-12-03 10:01       ` Greg KH
  2018-12-03 15:50       ` Sasha Levin
  1 sibling, 0 replies; 9+ messages in thread
From: Greg KH @ 2018-12-03 10:01 UTC (permalink / raw)
  To: Nikolay Borisov; +Cc: stable, josef, David Sterba

On Thu, Nov 29, 2018 at 02:36:05PM +0200, Nikolay Borisov wrote:
> 
> 
> On 29.11.18 г. 14:21 ч., Greg KH wrote:
> > On Tue, Nov 20, 2018 at 10:11:21AM +0200, Nikolay Borisov wrote:
> >> From: Josef Bacik <josef@toxicpanda.com>
> >>
> >> We want to release the unused reservation we have since it refills the
> >> delayed refs reserve, which will make everything go smoother when
> >> running the delayed refs if we're short on our reservation.
> >>
> >> CC: stable@vger.kernel.org # 4.4+
> >> Reviewed-by: Omar Sandoval <osandov@fb.com>
> >> Reviewed-by: Liu Bo <bo.liu@linux.alibaba.com>
> >> Reviewed-by: Nikolay Borisov <nborisov@suse.com>
> >> Signed-off-by: Josef Bacik <josef@toxicpanda.com>
> >> Signed-off-by: David Sterba <dsterba@suse.com>
> >> ---
> >>
> >> Hello Greg, 
> >>
> >> Here is a fixed up backport for upstream commit f45c752b65af46bf42963295c332865d95f97fff
> >> This one applies cleanly to 4.4.y and 4.9.y
> > 
> > What about 4.14.y?  I don't want to apply this to only 4.4 and 4.9 and
> > not 4.14.  Can you provide a working backport there too?
> 
> I've only made backports as a result of your "failed to apply" emails.
> If there isn't a backport for 4.14 then this means it's either handled
> or you didn't send such an email, or i wasn't cced

If you got one for older kernels, you should have also gotten one for
4.14, I don't know what failed there, sorry.

Anyway, I need a 4.14 patch before I can apply this one.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [PATCH] btrfs: release metadata before running delayed refs
  2018-11-29 12:21   ` Greg KH
  2018-11-29 12:36     ` Nikolay Borisov
@ 2018-12-03 11:06     ` Nikolay Borisov
  2018-12-03 15:51       ` Sasha Levin
  1 sibling, 1 reply; 9+ messages in thread
From: Nikolay Borisov @ 2018-12-03 11:06 UTC (permalink / raw)
  To: gregkh; +Cc: stable, Josef Bacik, David Sterba

From: Josef Bacik <josef@toxicpanda.com>

We want to release the unused reservation we have since it refills the
delayed refs reserve, which will make everything go smoother when
running the delayed refs if we're short on our reservation.

CC: stable@vger.kernel.org # 4.4+
Reviewed-by: Omar Sandoval <osandov@fb.com>
Reviewed-by: Liu Bo <bo.liu@linux.alibaba.com>
Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Signed-off-by: Josef Bacik <josef@toxicpanda.com>
Signed-off-by: David Sterba <dsterba@suse.com>
---

Hi Greg, 

Please apply this backport of upstream commit f45c752b65af46bf42963295c332865d95f97fff
to 4.14.y. 
 fs/btrfs/transaction.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/fs/btrfs/transaction.c b/fs/btrfs/transaction.c
index f74005ca8f08..73c1fbca0c35 100644
--- a/fs/btrfs/transaction.c
+++ b/fs/btrfs/transaction.c
@@ -1955,6 +1955,9 @@ int btrfs_commit_transaction(struct btrfs_trans_handle *trans)
 		return ret;
 	}
 
+	btrfs_trans_release_metadata(trans, fs_info);
+	trans->block_rsv = NULL;
+
 	/* make a pass through all the delayed refs we have so far
 	 * any runnings procs may add more while we are here
 	 */
@@ -1964,9 +1967,6 @@ int btrfs_commit_transaction(struct btrfs_trans_handle *trans)
 		return ret;
 	}
 
-	btrfs_trans_release_metadata(trans, fs_info);
-	trans->block_rsv = NULL;
-
 	cur_trans = trans->transaction;
 
 	/*
-- 
2.17.1

^ permalink raw reply related	[flat|nested] 9+ messages in thread

* Re: [PATCH 1/3] btrfs: release metadata before running delayed refs
  2018-11-29 12:36     ` Nikolay Borisov
  2018-12-03 10:01       ` Greg KH
@ 2018-12-03 15:50       ` Sasha Levin
  2018-12-12 11:41         ` Nikolay Borisov
  1 sibling, 1 reply; 9+ messages in thread
From: Sasha Levin @ 2018-12-03 15:50 UTC (permalink / raw)
  To: Nikolay Borisov; +Cc: Greg KH, stable, josef, David Sterba

On Thu, Nov 29, 2018 at 02:36:05PM +0200, Nikolay Borisov wrote:
>
>
>On 29.11.18 г. 14:21 ч., Greg KH wrote:
>> On Tue, Nov 20, 2018 at 10:11:21AM +0200, Nikolay Borisov wrote:
>>> From: Josef Bacik <josef@toxicpanda.com>
>>>
>>> We want to release the unused reservation we have since it refills the
>>> delayed refs reserve, which will make everything go smoother when
>>> running the delayed refs if we're short on our reservation.
>>>
>>> CC: stable@vger.kernel.org # 4.4+
>>> Reviewed-by: Omar Sandoval <osandov@fb.com>
>>> Reviewed-by: Liu Bo <bo.liu@linux.alibaba.com>
>>> Reviewed-by: Nikolay Borisov <nborisov@suse.com>
>>> Signed-off-by: Josef Bacik <josef@toxicpanda.com>
>>> Signed-off-by: David Sterba <dsterba@suse.com>
>>> ---
>>>
>>> Hello Greg,
>>>
>>> Here is a fixed up backport for upstream commit f45c752b65af46bf42963295c332865d95f97fff
>>> This one applies cleanly to 4.4.y and 4.9.y
>>
>> What about 4.14.y?  I don't want to apply this to only 4.4 and 4.9 and
>> not 4.14.  Can you provide a working backport there too?
>
>I've only made backports as a result of your "failed to apply" emails.
>If there isn't a backport for 4.14 then this means it's either handled
>or you didn't send such an email, or i wasn't cced
>
>>
>> And I don't see the 2/3 patch in this series, has that already been
>> handled?

I see commit 2/3 failed to apply on 4.9 and 4.4:
https://www.spinics.net/lists/stable/msg267061.html would you send a
backport for it as well?

--
Thanks,
Sasha

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] btrfs: release metadata before running delayed refs
  2018-12-03 11:06     ` [PATCH] " Nikolay Borisov
@ 2018-12-03 15:51       ` Sasha Levin
  0 siblings, 0 replies; 9+ messages in thread
From: Sasha Levin @ 2018-12-03 15:51 UTC (permalink / raw)
  To: Nikolay Borisov; +Cc: gregkh, stable, Josef Bacik, David Sterba

On Mon, Dec 03, 2018 at 01:06:57PM +0200, Nikolay Borisov wrote:
>From: Josef Bacik <josef@toxicpanda.com>
>
>We want to release the unused reservation we have since it refills the
>delayed refs reserve, which will make everything go smoother when
>running the delayed refs if we're short on our reservation.
>
>CC: stable@vger.kernel.org # 4.4+
>Reviewed-by: Omar Sandoval <osandov@fb.com>
>Reviewed-by: Liu Bo <bo.liu@linux.alibaba.com>
>Reviewed-by: Nikolay Borisov <nborisov@suse.com>
>Signed-off-by: Josef Bacik <josef@toxicpanda.com>
>Signed-off-by: David Sterba <dsterba@suse.com>
>---
>
>Hi Greg,
>
>Please apply this backport of upstream commit f45c752b65af46bf42963295c332865d95f97fff
>to 4.14.y.

I've queued this one for 4.14, and the one you previously sent to 4.9
and 4.4. Thank you.

--
Thanks,
Sasha

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH 1/3] btrfs: release metadata before running delayed refs
  2018-12-03 15:50       ` Sasha Levin
@ 2018-12-12 11:41         ` Nikolay Borisov
  0 siblings, 0 replies; 9+ messages in thread
From: Nikolay Borisov @ 2018-12-12 11:41 UTC (permalink / raw)
  To: Sasha Levin; +Cc: Greg KH, stable, josef, David Sterba



On 3.12.18 г. 17:50 ч., Sasha Levin wrote:
> On Thu, Nov 29, 2018 at 02:36:05PM +0200, Nikolay Borisov wrote:
>>
>>
>> On 29.11.18 г. 14:21 ч., Greg KH wrote:
>>> On Tue, Nov 20, 2018 at 10:11:21AM +0200, Nikolay Borisov wrote:
>>>> From: Josef Bacik <josef@toxicpanda.com>
>>>>
>>>> We want to release the unused reservation we have since it refills the
>>>> delayed refs reserve, which will make everything go smoother when
>>>> running the delayed refs if we're short on our reservation.
>>>>
>>>> CC: stable@vger.kernel.org # 4.4+
>>>> Reviewed-by: Omar Sandoval <osandov@fb.com>
>>>> Reviewed-by: Liu Bo <bo.liu@linux.alibaba.com>
>>>> Reviewed-by: Nikolay Borisov <nborisov@suse.com>
>>>> Signed-off-by: Josef Bacik <josef@toxicpanda.com>
>>>> Signed-off-by: David Sterba <dsterba@suse.com>
>>>> ---
>>>>
>>>> Hello Greg,
>>>>
>>>> Here is a fixed up backport for upstream commit
>>>> f45c752b65af46bf42963295c332865d95f97fff
>>>> This one applies cleanly to 4.4.y and 4.9.y
>>>
>>> What about 4.14.y?  I don't want to apply this to only 4.4 and 4.9 and
>>> not 4.14.  Can you provide a working backport there too?
>>
>> I've only made backports as a result of your "failed to apply" emails.
>> If there isn't a backport for 4.14 then this means it's either handled
>> or you didn't send such an email, or i wasn't cced
>>
>>>
>>> And I don't see the 2/3 patch in this series, has that already been
>>> handled?
> 
> I see commit 2/3 failed to apply on 4.9 and 4.4:
> https://www.spinics.net/lists/stable/msg267061.html would you send a
> backport for it as well?

I think not, because the memalloc_xxx_save/restore infrastructure is
missing and actually plumbing GFP flags to btrfs_iget so that in only 1
unique context we can pass GFP_NOFS will be rather invasive.

> 
> -- 
> Thanks,
> Sasha
> 

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2018-12-12 11:41 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-11-11 20:19 FAILED: patch "[PATCH] btrfs: release metadata before running delayed refs" failed to apply to 4.4-stable tree gregkh
2018-11-20  8:11 ` [PATCH 1/3] btrfs: release metadata before running delayed refs Nikolay Borisov
2018-11-29 12:21   ` Greg KH
2018-11-29 12:36     ` Nikolay Borisov
2018-12-03 10:01       ` Greg KH
2018-12-03 15:50       ` Sasha Levin
2018-12-12 11:41         ` Nikolay Borisov
2018-12-03 11:06     ` [PATCH] " Nikolay Borisov
2018-12-03 15:51       ` Sasha Levin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).