Re: [cip-dev] [PATCH 4.4.y-cip 04/11] cpufreq: ti: Add cpufreq driver to determine available OPPs at runtime

Pavel Machek
2020-09-09T06:45:38Z

[-- Attachment #1.1: Type: text/plain, Size: 1059 bytes --]

Hi!

> + /*
> + * The efuse on dra7 and am57 parts contains a specific
> + * value indicating the highest available OPP.
> + */
> +
> + switch (efuse) {
> + case DRA7_EFUSE_HAS_ALL_MPU_OPP:
> + case DRA7_EFUSE_HAS_HIGH_MPU_OPP:
> + calculated_efuse |= DRA7_EFUSE_HIGH_MPU_OPP;
> + case DRA7_EFUSE_HAS_OD_MPU_OPP:
> + calculated_efuse |= DRA7_EFUSE_OD_MPU_OPP;
> + }

Some kind of fallthrough marking would not be bad.

> + ret = ti_cpufreq_get_efuse(opp_data, &version[1]);
> + if (ret)
> + goto fail_put_node;
> +
> + of_node_put(opp_data->opp_node);
> +
> + ret = PTR_ERR_OR_ZERO(dev_pm_opp_set_supported_hw(opp_data->cpu_dev,
> + version, VERSION_COUNT));
> + if (ret) {
> + dev_err(opp_data->cpu_dev,
> + "Failed to set supported hardware\n");
> + goto fail_put_node;
> + }

of_node_put() is done twice in the last error path.

Best regards,
Pavel
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany

[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]

[-- Attachment #2: Type: text/plain, Size: 419 bytes --]

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#5433): https://lists.cip-project.org/g/cip-dev/message/5433
Mute This Topic: https://lists.cip-project.org/mt/76726425/4520388