From: Uladzislau Rezki <urezki@gmail.com>
To: Marcus Seyfarth <m.seyfarth@gmail.com>
Cc: Uladzislau Rezki <urezki@gmail.com>,
paulmck@kernel.org, Bagas Sanjaya <bagasdotme@gmail.com>,
Ziwei Dai <ziwei.dai@unisoc.com>,
linux-kernel@vger.kernel.org, rcu@vger.kernel.org
Subject: Re: Fwd: [6.5.1] Slow boot and opening files (RIP: kvfree_rcu_bulk)
Date: Tue, 5 Sep 2023 18:46:12 +0200 [thread overview]
Message-ID: <ZPdbVO8ySCHLIEGu@pc636> (raw)
In-Reply-To: <CA+FbhJMEqLycroz=J6VvC=4OBaJSwz8K+K6Zgki80M-5YdYp6A@mail.gmail.com>
>
> For a comparison, I've attached a journalctl log for my custom 6.4.14 Kernel.
>
1. I tried to apply your patches on stable 6.5.1 kernel. All of them can be
applied except of one. Its name is 0001-ms178.patch and it produces below
rejects:
<snip>
arch/alpha/kernel/syscalls/syscall.tbl.rej
arch/arm/tools/syscall.tbl.rej
arch/arm64/include/asm/unistd.h.rej
arch/arm64/include/asm/unistd32.h.rej
arch/ia64/kernel/syscalls/syscall.tbl.rej
arch/m68k/kernel/syscalls/syscall.tbl.rej
arch/microblaze/kernel/syscalls/syscall.tbl.rej
arch/mips/kernel/syscalls/syscall_n32.tbl.rej
arch/mips/kernel/syscalls/syscall_n64.tbl.rej
arch/mips/kernel/syscalls/syscall_o32.tbl.rej
arch/parisc/kernel/syscalls/syscall.tbl.rej
arch/powerpc/kernel/syscalls/syscall.tbl.rej
arch/s390/kernel/syscalls/syscall.tbl.rej
arch/sh/kernel/syscalls/syscall.tbl.rej
arch/sparc/kernel/syscalls/syscall.tbl.rej
arch/x86/entry/syscalls/syscall_32.tbl.rej
arch/x86/entry/syscalls/syscall_64.tbl.rej
arch/xtensa/kernel/syscalls/syscall.tbl.rej
include/uapi/asm-generic/unistd.h.rej
<snip>
But let's skip that part.
2. One of patches also modifies the kernel/rcu/tree.c file:
<snip>
diff --git a/kernel/rcu/tree.c b/kernel/rcu/tree.c
index 1449cb69a0e0..fbc20c6cdbeb 100644
--- a/kernel/rcu/tree.c
+++ b/kernel/rcu/tree.c
@@ -2810,6 +2810,7 @@ struct kfree_rcu_cpu_work {
/**
* struct kfree_rcu_cpu - batch up kfree_rcu() requests for RCU grace period
+ * @gp_snap: The GP snapshot recorded at the last scheduling of monitor work.
* @head: List of kfree_rcu() objects not yet waiting for a grace period
* @head_gp_snap: Snapshot of RCU state for objects placed to "@head"
* @bulk_head: Bulk-List of kvfree_rcu() objects not yet waiting for a grace period
@@ -2849,6 +2850,7 @@ struct kfree_rcu_cpu {
struct kfree_rcu_cpu_work krw_arr[KFREE_N_BATCHES];
raw_spinlock_t lock;
struct delayed_work monitor_work;
+ unsigned long gp_snap;
bool initialized;
struct delayed_work page_cache_work;
@@ -3095,6 +3097,7 @@ schedule_delayed_monitor_work(struct kfree_rcu_cpu *krcp)
mod_delayed_work(system_wq, &krcp->monitor_work, delay);
return;
}
+ krcp->gp_snap = get_state_synchronize_rcu();
queue_delayed_work(system_wq, &krcp->monitor_work, delay);
}
@@ -3187,7 +3190,10 @@ static void kfree_rcu_monitor(struct work_struct *work)
// be that the work is in the pending state when
// channels have been detached following by each
// other.
- queue_rcu_work(system_wq, &krwp->rcu_work);
+ if (poll_state_synchronize_rcu(krcp->gp_snap))
+ queue_work(system_wq, &krwp->rcu_work.work);
+ else
+ queue_rcu_work(system_wq, &krwp->rcu_work);
}
}
<snip>
i do not understand where you got this patch and what a reason behind of
applying is.
3. Could you please remove that patch(revert it) and try one more time?
4. When i apply all your patches i see that you modify:
urezki@pc638:~/data/raid0/coding/linux-stable.git$ git st | wc -l
455
urezki@pc638:~/data/raid0/coding/linux-stable.git$
455 files. The delta is huge. It touches arch, mm, rcu, drivers, crypto,
include/linux/ generic headers, init, kernel, lib, net, etc parts.
So as a result we have:
<snip>
451 files changed, 34218 insertions(+), 5576 deletions(-)
<snip>
--
Uladzislau Rezki
next prev parent reply other threads:[~2023-09-05 18:01 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-03 1:34 Fwd: [6.5.1] Slow boot and opening files (RIP: kvfree_rcu_bulk) Bagas Sanjaya
2023-09-03 3:29 ` Hugh Dickins
2023-09-03 10:45 ` Paul E. McKenney
[not found] ` <CA+FbhJOSfqcb3=ecL-y=13j81b1Ts13wHpzBSURyCRQUvd2NWQ@mail.gmail.com>
[not found] ` <c054b588-b029-4380-9ec5-4ae50ee37d08@paulmck-laptop>
[not found] ` <CA+FbhJO1FbOvP=GmUse-r8Yma1tSv6iqppDhz9Ut1JKpjN49qQ@mail.gmail.com>
[not found] ` <CA+FbhJPOkV4Xa7ZJ4QF2y_-5i24F+TkhByr=LzMPt9iy9EshSQ@mail.gmail.com>
[not found] ` <4009a6e0-198c-4f25-8e34-4774dcd8c537@paulmck-laptop>
[not found] ` <CA+FbhJPxU+QKf1tTBd8XcKcSsTeRmJ=ji_L4QYiad--hGqRB5w@mail.gmail.com>
2023-09-03 15:36 ` Paul E. McKenney
[not found] ` <CA+FbhJPtmFG2vKNXWr67Tuh-4HUi8n81PmKxwftv9iK1a3On-A@mail.gmail.com>
2023-09-04 11:23 ` Uladzislau Rezki
[not found] ` <CA+FbhJPNZ-E3e7WBH_jAvi3Rn-2gV4TVk9S9qmheXkqXw+Sakg@mail.gmail.com>
2023-09-04 15:05 ` Uladzislau Rezki
[not found] ` <CA+FbhJMr6LzmOpVNkYyiSERAsNEqqvQwQ7SwJK=CmwvV9d2Z-A@mail.gmail.com>
2023-09-04 16:53 ` Uladzislau Rezki
2023-09-04 19:13 ` Uladzislau Rezki
[not found] ` <CA+FbhJPNK=4s8J5OqOBaDC8EDNQzevQMQ+fwZnfxG92ReabQOA@mail.gmail.com>
[not found] ` <CA+FbhJMEqLycroz=J6VvC=4OBaJSwz8K+K6Zgki80M-5YdYp6A@mail.gmail.com>
2023-09-05 10:41 ` Uladzislau Rezki
2023-09-05 16:46 ` Uladzislau Rezki [this message]
[not found] ` <CA+FbhJOekDxBjQH6jUFXusgakRVx_Y0S3s5avko23c6XqCc2Mw@mail.gmail.com>
[not found] ` <CA+FbhJNQfGW5RMJc-WaOmjqmYuTnqdvRPYO_40TP5=P4LFPDYQ@mail.gmail.com>
2023-09-05 18:46 ` Uladzislau Rezki
[not found] ` <CA+FbhJO4xfdrUtZLWMRMaZdM2W-G+ZKtg9ESdwT8DUFJZKmW-Q@mail.gmail.com>
2023-09-06 10:31 ` Uladzislau Rezki
2023-09-11 13:25 ` Bagas Sanjaya
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ZPdbVO8ySCHLIEGu@pc636 \
--to=urezki@gmail.com \
--cc=bagasdotme@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=m.seyfarth@gmail.com \
--cc=paulmck@kernel.org \
--cc=rcu@vger.kernel.org \
--cc=ziwei.dai@unisoc.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox