[PATCH] clk: imx: imx93: introduce clk_bypassed module parameter

Peng Fan peng.fan at nxp.com
Wed May 10 00:49:20 PDT 2023


> Subject: Re: [PATCH] clk: imx: imx93: introduce clk_bypassed module
> parameter
> 
> On Thu, May 04, 2023 at 04:55:06PM +0800, Peng Fan (OSS) wrote:
> > From: Peng Fan <peng.fan at nxp.com>
> >
> > With the clk names specified in clk_bypassed module parameter, give
> > user an option to bypass the clk from managing them by Linux kernel.
> 
> As I said on another email, no, please do not add new module parameters
> for drivers, this is not the 1990s

After a search of the list,
https://lore.kernel.org/all/?q=module_param

I still see many drivers are adding module_param.

Is this is strict ban that new platform driver should not add
module_param?

Thanks,
Peng.

> 
> Also, another comment below:
> 
> > @@ -310,6 +357,8 @@ static int imx93_clocks_probe(struct
> > platform_device *pdev)
> >
> >  	for (i = 0; i < ARRAY_SIZE(root_array); i++) {
> >  		root = &root_array[i];
> > +		if (unlikely(imx_clk_bypass_check(root->name)))
> > +			continue;
> 
> Only ever use likely/unlikely if you can measure the difference.  Here on a
> probe function, you can not, this is not needed at all, the compiler and CPU
> will do a better job over time than you can guess at this.
> 
> But as this change isn't needed, this shouldn't be an issue either.
> 
> thanks,
> 
> greg k-h



More information about the linux-arm-kernel mailing list