lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Thu, 23 Mar 2023 09:24:30 +0800
From:   zhuyinbo <zhuyinbo@...ngson.cn>
To:     Stephen Boyd <sboyd@...nel.org>,
        Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
        Michael Turquette <mturquette@...libre.com>,
        Rob Herring <robh+dt@...nel.org>, devicetree@...r.kernel.org,
        linux-clk@...r.kernel.org, linux-kernel@...r.kernel.org
Cc:     Jianmin Lv <lvjianmin@...ngson.cn>, wanghongliang@...ngson.cn,
        Liu Peibao <liupeibao@...ngson.cn>,
        loongson-kernel@...ts.loongnix.cn, zhuyinbo@...ngson.cn
Subject: Re: [PATCH v15 2/2] clk: clk-loongson2: add clock controller driver
 support


在 2023/3/22 下午11:16, Stephen Boyd 写道:
> Quoting zhuyinbo (2023-03-21 19:07:26)
>> 在 2023/3/22 上午7:42, Stephen Boyd 写道:
>>> Quoting Yinbo Zhu (2023-03-21 06:07:10)
>>>> diff --git a/drivers/clk/clk-loongson2.c b/drivers/clk/clk-loongson2.c
>>>> new file mode 100644
>>>> index 000000000000..090810655511
>>>> --- /dev/null
>>>> +++ b/drivers/clk/clk-loongson2.c
>>>> @@ -0,0 +1,344 @@
> [....]
>>>> +
>>>> +static void __iomem *loongson2_pll_base;
>>> Why is this a global?
>> Normally, this should be an element in the structure, but since there is
>> only one
>>
>> element, It is directly defined as a global variable for use by other
>> function.
>>
> Ok. Globals are frowned upon but it's just a single pointers so I guess
> it's Ok.
>
>>>> +               return PTR_ERR(loongson2_pll_base);
>>>> +
>>>> +       loongson2_clocks_init(dev);
>>> Please inline this function here.
>> The loongson2_clocks_init had inline in this version, or do you mean something else ? Need to inline the probe?
> I mean get rid of the function loongson2_clocks_init() and move the code
> in that function into this probe function. With this patch the probe is
> split to two functions when it should be one function.

okay, I got it.


Thanks.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ