summaryrefslogtreecommitdiff
path: root/scripts/gdb
diff options
context:
space:
mode:
authorCen Zhang <zzzccc427@gmail.com>2026-10-22 17:08:42 +0800
committerAndrew Morton <akpm@linux-foundation.org>2026-10-24 00:46:52 -0700
commit5898987d4a92b70ae73fd8355cc3a388b4dfa4e6 (patch)
tree29f209bbcbf86784bcedd6ee2bbdf0b040289b0d /scripts/gdb
parent8cd3ff30659775a6831c66687a69d2b83d163591 (diff)
ocfs2: snapshot the dentry name while tracing file release
ocfs2_file_release() passes the live dentry name and length to a trace event while holding oi->ip_lock. This lock protects the open count and delays RCU reclamation of external names, but it does not serialize name changes during rename. The dentry can switch between inline and external names, and a separately loaded length can describe a different name. The ocfs2__file_ops event sizes and copies its __string separately. A concurrently rewritten inline name need not remain consistent between those operations. External names can also be selected at this call site; the existing spinlock critical section protects their allocation lifetime, while a snapshot additionally pairs a stable name with its length. Take a name snapshot before acquiring oi->ip_lock and release it after dropping the lock. Keep the trace call and open-count argument inside the original critical section. Cache the event-enabled check so the snapshot stays paired even if tracing is toggled meanwhile. Link: https://lore.kernel.org/pm-ocfs2-objects-candidate-0088-v7-6324344256f0c3b1c3d8-2@gmail.com Fixes: 468eedde23d6 ("ocfs2: Remove mlog(0) from fs/ocfs2/file.c") Signed-off-by: Cen Zhang <zzzccc427@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Reviewed-by: Joseph Qi <joseph.qi@linux.alibaba.com> Assisted-by: LLM Cc: Mark Fasheh <mark@fasheh.com> Cc: Joel Becker <jlbec@evilplan.org> Cc: Heming Zhao <heming.zhao@suse.com> Cc: Jia-Ju Bai <baijiaju1990@gmail.com> Cc: <jjzuming@gmail.com> Cc: <stable@vger.kernel.org>
Diffstat (limited to 'scripts/gdb')
0 files changed, 0 insertions, 0 deletions