[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20161114104432.3bd2fb2c@gandalf.local.home>
Date: Mon, 14 Nov 2016 10:44:32 -0500
From: Steven Rostedt <rostedt@...dmis.org>
To: Russell King - ARM Linux <linux@...linux.org.uk>
Cc: Rabin Vincent <rabin.vincent@...s.com>,
linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
Rabin Vincent <rabinv@...s.com>
Subject: Re: [PATCH] ARM: ftrace: fix syscall name matching
On Mon, 14 Nov 2016 10:40:08 -0500
Steven Rostedt <rostedt@...dmis.org> wrote:
> > Is this really safe? What guarantees that we can wind forward four
> > bytes here? If it's always safe, it needs a better comment than just
> > two words.
>
> I believe it is, but a comment would do well.
Also, the generic function that is called if the arch does not define
ARCH_HAS_SYSCALL_MATCH_SYM_NAME does this too.
return !strcmp(sym + 3, name + 3);
And looking at this, it really should be + 4 and not + 3, because it
doesn't match the comment above, where it says it can handle both
".SyS" and "SyS", but it doesn't handle ".SyS" compared to ".sys".
-- Steve
Powered by blists - more mailing lists