[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240131111358.5506645a@gandalf.local.home>
Date: Wed, 31 Jan 2024 11:13:58 -0500
From: Steven Rostedt <rostedt@...dmis.org>
To: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: kernel test robot <oliver.sang@...el.com>, oe-lkp@...ts.linux.dev,
lkp@...el.com, linux-kernel@...r.kernel.org, Masami Hiramatsu
<mhiramat@...nel.org>, Mark Rutland <mark.rutland@....com>, Mathieu
Desnoyers <mathieu.desnoyers@...icios.com>, Christian Brauner
<brauner@...nel.org>, Al Viro <viro@...iv.linux.org.uk>, Ajay Kaher
<ajay.kaher@...adcom.com>, linux-trace-kernel@...r.kernel.org
Subject: Re: [linus:master] [eventfs] 852e46e239:
BUG:unable_to_handle_page_fault_for_address
On Wed, 31 Jan 2024 10:58:47 -0500
Steven Rostedt <rostedt@...dmis.org> wrote:
> @@ -788,6 +717,7 @@ static void init_once(void *foo)
> {
> struct tracefs_inode *ti = (struct tracefs_inode *) foo;
>
> + memset(ti, 0, sizeof(*ti));
> inode_init_once(&ti->vfs_inode);
> }
>
Note, that inode_init_once() also does a memset on the entire inode, so the
initial memset is redundant on the inode portion. But I didn't think it was
really worth the time to complicate the code by optimizing it. I guess if I
changed the structure to:
struct tracefs_inode {
+ struct inode vfs_inode;
unsigned long flags;
void *private;
- struct inode vfs_inode;
};
I could have it do:
memset_after(ti, 0, vfs_inode);
But this can be done as a separate clean up and doesn't need to be done now.
-- Steve
Powered by blists - more mailing lists