Commit a73ccab0 authored by Tomasz Michalec's avatar Tomasz Michalec Committed by Greg Kroah-Hartman
Browse files

platform/chrome: cros_ec_typec: Defer probe on missing EC parent



[ Upstream commit 8866f4e5 ]

If cros_typec_probe is called before EC device is registered,
cros_typec_probe will fail. It may happen when cros-ec-typec.ko is
loaded before EC bus layer module (e.g. cros_ec_lpcs.ko,
cros_ec_spi.ko).

Return -EPROBE_DEFER when cros_typec_probe doesn't get EC device, so
the probe function can be called again after EC device is registered.

Signed-off-by: default avatarTomasz Michalec <tmichalec@google.com>
Reviewed-by: default avatarAbhishek Pandit-Subedi <abhishekpandit@chromium.org>
Link: https://lore.kernel.org/r/20250610153748.1858519-1-tmichalec@google.com


Signed-off-by: default avatarTzung-Bi Shih <tzungbi@kernel.org>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 93d700f5
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment