mbox series

[v2,00/17] x86: coral: Add support for Cr50

Message ID 20200204001945.234347-1-sjg@chromium.org
Headers show
Series x86: coral: Add support for Cr50 | expand

Message

Simon Glass Feb. 4, 2020, 12:19 a.m. UTC
This series adds a driver for the Cr50 security chip and enables it on
coral. This supports the 'tpm' command.

In order to make this work a few other changes are included:
- Additional UCLASS_IRQ operations to support requesting and reading
  interrupts, using the device tree
- A driver for ACPI general-purpose events

There are also a few small clean-ups to the recently landed Apollo Lake
support.

This series relies on this patch:

   http://patchwork.ozlabs.org/patch/1214541/

Changes in v2:
- Add new patch to allow iterating devices without uclass_get()
- Add new patch to find a device by drvdata
- Add new patch to change syscon to use helper function
- Add new patch to change tegra driver to use helper function
- Move intel-clock.h inclusion to the correct patch
- Move 'success' comment into this patch
- Update to use the new DM helper function
- Move 'success' comment into previous patch
- Move intel-clock.h inclusion to the correct patch
- Significant rewrite of cr50 init procedure
- Support use of interrupts
- Update the commit message
- Add new patches to handle requesting interrupts and interrupt state

Simon Glass (17):
  dm: core: Allow iterating devices without uclass_get()
  dm: core: Add a function to find a device by drvdata
  dm: core: Change syscon to use helper function
  tegra: i2c: Change driver to use helper function
  x86: Add a clock driver for Intel devices
  x86: apl: Use the clock driver
  x86: apl: Drop the I2C config in FSP-S
  x86: coral: Update i2c and rtc status
  dm: irq: Add support for interrupt controller types
  x86: Give each driver an IRQ type
  x86: itss: Add of-platdata support
  dm: irq: Add support for requesting interrupts
  x86: Add support for ACPI general-purpose events
  x86: coral: Add I2C and TPM device-tree definitions
  tpm: Add more TPM2 definitions
  tpm: Add a driver for H1/Cr50
  x86: coral: Enable TPM

 arch/sandbox/dts/test.dts                     |   5 +-
 arch/sandbox/include/asm/test.h               |   4 +
 arch/x86/Kconfig                              |  33 +
 arch/x86/cpu/Makefile                         |   1 +
 arch/x86/cpu/acpi_gpe.c                       |  85 +++
 arch/x86/cpu/apollolake/Kconfig               |   4 +
 arch/x86/cpu/apollolake/fsp_s.c               |  62 +-
 arch/x86/cpu/i386/interrupt.c                 |   3 +-
 arch/x86/cpu/intel_common/itss.c              |  12 +-
 arch/x86/cpu/irq.c                            |   3 +-
 arch/x86/dts/chromebook_coral.dts             |  93 +++
 configs/chromebook_coral_defconfig            |   3 +-
 doc/board/google/chromebook_coral.rst         |   2 -
 .../interrupt-controller/intel,acpi-gpe.txt   |  30 +
 .../interrupt-controller/interrupts.txt       | 131 ++++
 drivers/clk/Kconfig                           |  10 +
 drivers/clk/Makefile                          |   1 +
 drivers/clk/intel/Makefile                    |   6 +
 drivers/clk/intel/clk_intel.c                 |  41 ++
 drivers/core/syscon-uclass.c                  |  15 +-
 drivers/core/uclass.c                         |  17 +
 drivers/i2c/tegra_i2c.c                       |  13 +-
 drivers/misc/irq-uclass.c                     | 131 +++-
 drivers/misc/irq_sandbox.c                    |  43 +-
 drivers/pinctrl/intel/pinctrl.c               |   2 +-
 drivers/tpm/Kconfig                           |  10 +
 drivers/tpm/Makefile                          |   1 +
 drivers/tpm/cr50_i2c.c                        | 661 ++++++++++++++++++
 include/dm/test.h                             |   2 +
 include/dm/uclass.h                           |  31 +
 include/dt-bindings/clock/intel-clock.h       |  15 +
 include/irq.h                                 | 138 ++++
 include/tpm-v2.h                              |  31 +
 test/dm/irq.c                                 |  45 ++
 test/dm/test-fdt.c                            |  42 ++
 35 files changed, 1633 insertions(+), 93 deletions(-)
 create mode 100644 arch/x86/cpu/acpi_gpe.c
 create mode 100644 doc/device-tree-bindings/interrupt-controller/intel,acpi-gpe.txt
 create mode 100644 doc/device-tree-bindings/interrupt-controller/interrupts.txt
 create mode 100644 drivers/clk/intel/Makefile
 create mode 100644 drivers/clk/intel/clk_intel.c
 create mode 100644 drivers/tpm/cr50_i2c.c
 create mode 100644 include/dt-bindings/clock/intel-clock.h