summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2021-03-15 17:25:47 +1300
committerSimon Glass <sjg@chromium.org>2021-03-22 19:23:29 +1300
commit7564e2757c8b19ada9f3a317474abebc3eccade3 (patch)
tree0f0132f9e78cea24ce3f50af33e6acbac1040f9c
parentf3455114abeab9179f9b8f0fd1627651b0976e26 (diff)
downloadu-boot-7564e2757c8b19ada9f3a317474abebc3eccade3.tar.gz
x86: itss: Tidy up bind() for of-platdata-inst
With the standard of-platdata we must fix up driver_data manually. With of-platadata-inst this is not necessary, since it is added to the device by dtoc. Update the code to handle this. Signed-off-by: Simon Glass <sjg@chromium.org> Signed-off-by: Simon Glass <sjg@chromium.org>
-rw-r--r--arch/x86/cpu/intel_common/itss.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/arch/x86/cpu/intel_common/itss.c b/arch/x86/cpu/intel_common/itss.c
index 588a512ecd..1eff030983 100644
--- a/arch/x86/cpu/intel_common/itss.c
+++ b/arch/x86/cpu/intel_common/itss.c
@@ -153,8 +153,9 @@ static int route_pmc_gpio_gpe(struct udevice *dev, uint pmc_gpe_num)
static int itss_bind(struct udevice *dev)
{
- /* This is not set with of-platdata, so set it manually */
- if (CONFIG_IS_ENABLED(OF_PLATDATA))
+ /* This is not set with basic of-platdata, so set it manually */
+ if (CONFIG_IS_ENABLED(OF_PLATDATA) &&
+ !CONFIG_IS_ENABLED(OF_PLATDATA_INST))
dev->driver_data = X86_IRQT_ITSS;
return 0;