lkml.org 
[lkml]   [2021]   [Oct]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2 2/2] mailbox: mtk-cmdq: Fix local clock ID usage
On Thu, Oct 14, 2021 at 08:03:52PM +0800, Fei Shao wrote:
> In the probe function, the clock IDs were pointed to local variables
> which should only be used in the same code block, and any access to them
> after the probing stage becomes an use-after-free case.
>
> Since there are only limited variants of the gce clock names so far, we
> can just declare them as static constants to fix the issue.
>
> Fixes: 85dfdbfc13ea ("mailbox: cmdq: add multi-gce clocks support for
> mt8195")
> Signed-off-by: Fei Shao <fshao@chromium.org>
Reviewed-by: Tzung-Bi Shih <tzungbi@google.com>

\
 
 \ /
  Last update: 2021-10-14 17:55    [W:0.077 / U:0.100 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site