mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2025-01-14 23:56:06 +07:00
9bbf6a5341
[Why] The dce_i2c_hw code contained four funtcions that were only called in one place and did not have a clearly delineated purpose. [How] Inline these functions, keeping the same functionality. This is not a functional change. The functions disable_i2c_hw_engine and release_engine_dce_hw were pulled into their respective callers. The most interesting part of this change is the acquire functions. dce_i2c_hw_engine_acquire_engine was pulled into dce_i2c_engine_acquire_hw, and dce_i2c_engine_acquire_hw was pulled into acquire_i2c_hw_engine. Some notes to show that this change is not functional: -Failure conditions in any function resulted in a cascade of calls that ended in a 'return NULL'. Those are replaced with a direct 'return NULL'. -The variable result is the one from dce_i2c_hw_engine_acquire_engine. The boolean result used as part of return logic was removed. -As the second half of dce_i2c_hw_engine_acquire_engine is only executed if that function is returning true and therefore exiting the do-while loop in dce_i2c_engine_acquire_hw, those lines were moved outside of the loop. Signed-off-by: David Francis <David.Francis@amd.com> Acked-by: Leo Li <sunpeng.li@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> |
||
---|---|---|
.. | ||
basics | ||
bios | ||
calcs | ||
core | ||
dce | ||
dce80 | ||
dce100 | ||
dce110 | ||
dce112 | ||
dce120 | ||
dcn10 | ||
dml | ||
gpio | ||
i2caux | ||
inc | ||
irq | ||
virtual | ||
dc_bios_types.h | ||
dc_ddc_types.h | ||
dc_dp_types.h | ||
dc_helper.c | ||
dc_hw_types.h | ||
dc_link.h | ||
dc_stream.h | ||
dc_types.h | ||
dc.h | ||
dm_helpers.h | ||
dm_pp_smu.h | ||
dm_services_types.h | ||
dm_services.h | ||
irq_types.h | ||
Makefile | ||
os_types.h |