diff options
| author | Tomasz Michalec <[email protected]> | 2025-07-22 13:28:26 +0000 |
|---|---|---|
| committer | Tzung-Bi Shih <[email protected]> | 2025-07-23 03:19:16 +0000 |
| commit | 731a4702b668ef28730e7d2414672b7085e757d6 (patch) | |
| tree | 69725e3e0dc40a55c78e3fd688cc5b6c2ddd9ec2 /drivers/platform/x86/intel/pmt/class.c | |
| parent | platform/chrome: cros_ec: Unregister notifier in cros_ec_unregister() (diff) | |
| download | kernel-731a4702b668ef28730e7d2414672b7085e757d6.tar.gz kernel-731a4702b668ef28730e7d2414672b7085e757d6.zip | |
platform/chrome: cros_ec_typec: Check ec platform device pointer
It is possible that parent device for cros_ec_typec device is already
available, but ec pointer in parent driver data isn't populated yet. It
may happen when cros_typec_probe is running in parallel with
cros_ec_register. This leads to NULL pointer dereference when
cros_typec_probe tries to get driver data from typec->ec->ec->dev.
Check if typec->ec->ec is set before using it in cros_typec_probe.
Signed-off-by: Tomasz Michalec <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Tzung-Bi Shih <[email protected]>
Diffstat (limited to 'drivers/platform/x86/intel/pmt/class.c')
0 files changed, 0 insertions, 0 deletions
