[PATCH v5 3/3] coresight: prevent deactivate active config while enabling the config
Leo Yan
leo.yan at arm.com
Wed May 14 05:47:10 PDT 2025
Hi Levi,
On Wed, May 14, 2025 at 12:04:39PM +0100, Yeoreum Yun wrote:
[...]
> > > +static bool cscfg_config_desc_get(struct cscfg_config_desc *config_desc)
> >
> > I would like to change the return type to int, so the error is handled
> > within the function. As a result, the caller _cscfg_activate_config()
> > does not need to explicitly return an error value.
>
> I think it's not good since cscfg_config_desc_get() failed only when
> try_module_get() failed and its return type is "bool".
Understood. I thought it would be easier for later maintenance if we
encapsulate error handling in the function, but I don't have strong
opinion. It is fine for me to return bool type.
Thanks,
Leo
More information about the linux-arm-kernel
mailing list