Skip to content

aspeed: Add I2C new register DMA slave mode support

Peter Delevoryas qemu-arm qemu-devel 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest13 of 14 patches 17 repliesIn review

13 of 14 patches are in this archive. The cover letter announces 14.

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/14hw/i2c: support multiple mastershw/i2c/core.c include/hw/i2c/i2c.h+47 -10 replies
2/14hw/i2c: add asynchronous sendhw/arm/pxa2xx.c hw/display/sii9022.c hw/display/ssd0303.c +6 more+67 -10 replies
3/14hw/i2c/aspeed: add slave device in old register modehw/i2c/aspeed_i2c.c include/hw/i2c/aspeed_i2c.h+88 -90 replies
4/14aspeed: i2c: Fix DMA len write-enable bit handlinghw/i2c/aspeed_i2c.c+4 -42 replies
5/14aspeed: i2c: Fix R_I2CD_FUN_CTRL referencehw/i2c/aspeed_i2c.c+1 -12 replies
7/14aspeed: Add PECI controllerhw/arm/aspeed_ast10x0.c hw/misc/aspeed_peci.c hw/misc/meson.build +2 more+275 -12 replies
8/14hw/misc: Add fby35-cpldhw/misc/fby35_cpld.c hw/misc/meson.build+139 -12 replies
9/14pmbus: Reset out buf after switching pageshw/i2c/pmbus_device.c+1 -02 replies
10/14pmbus: Add read-only IC_DEVICE_ID supporthw/i2c/pmbus_device.c hw/sensor/isl_pmbus_vr.c include/hw/i2c/pmbus_device.h +1 more+37 -00 replies
11/14aspeed: Add oby35-cl machinehw/arm/aspeed.c+40 -00 replies
12/14hw/misc: Add intel-mehw/arm/aspeed.c hw/misc/intel_me.c hw/misc/meson.build+179 -12 replies
13/14aspeed: Add intel-me on i2c6 instead of BMChw/arm/aspeed.c+1 -00 replies
14/14aspeed: Add I2C new register DMA slave mode supporthw/i2c/aspeed_i2c.c include/hw/i2c/aspeed_i2c.h+124 -122 replies

Reviews trailers per patch

2 of 13 patches have a Reviewed-by or Acked-by.

PatchCédric Le Goater
1/14
2/14
3/14
4/14R-b
5/14R-b
7/14
8/14
9/14
10/14
11/14
12/14
13/14
14/14

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 00/14] aspeed: Add I2C new register DMA slave mode support

Hey everyone,

I'm sending a big patch series for this, but only the last commit is really intended to be accepted right now. I'm just including the rest of them because it depends on them for testing.

Klaus's changes include the multi-master stuff in hw/i2c/core.c, and the old register mode slave mode support.

My series of patches includes a bunch of changes to eliminate most (if not all) of the I2C errors reported by the fb OpenBIC firmware for fby35 CraterLake Bridge Interconnect (BIC) (shortname: oby35-cl) upon startup.

In particular, I needed to add the IC_DEVICE_ID to the isl voltage regulator implementation, which required a fix to the pmbus implementation when switching pages. We weren't resetting the buffer state when switching pages there.

I also added a placeholder implementation of the PECI controller, that does almost nothing, but doesn't produce errors.

I added the fby35-cpld, which oby35-cl queries using master-mode TX and RX commands.

And finally, I added an "intel-me" device (Intel Management Engine) that attempts to respond to the first IPMB message sent by the BIC. I used this to test the final patch, which I actually want to merge, the I2C new register DMA slave mode support.

All the patches except the last one can be ignored for now if you want, again, I just included them for testing purposes.

The final patch is pretty rough, but I wanted to start the review instead of waiting too long. I expect the interrupt handling part will be the main blocker.

Thanks,
Peter

Klaus Jensen (3):
hw/i2c: support multiple masters
hw/i2c: add asynchronous send hw/i2c/aspeed: add slave device in old register mode

Peter Delevoryas (11):
aspeed: i2c: Fix DMA len write-enable bit handling
aspeed: i2c: Fix R_I2CD_FUN_CTRL reference
aspeed: i2c: Fix MASTER_EN missing error message
aspeed: Add PECI controller
hw/misc: Add fby35-cpld
pmbus: Reset out buf after switching pages
pmbus: Add read-only IC_DEVICE_ID support
aspeed: Add oby35-cl machine
hw/misc: Add intel-me
aspeed: Add intel-me on i2c6 instead of BMC
aspeed: Add I2C new register DMA slave mode support

 hw/arm/aspeed.c                  |  42 ++++++
 hw/arm/aspeed_ast10x0.c          |  11 ++
 hw/arm/pxa2xx.c                  |   2 +
 hw/display/sii9022.c             |   2 +
 hw/display/ssd0303.c             |   2 +
 hw/i2c/aspeed_i2c.c              | 234 +++++++++++++++++++++++++++----
 hw/i2c/core.c                    |  70 ++++++++-
 hw/i2c/pmbus_device.c            |   6 +
 hw/i2c/smbus_slave.c             |   4 +
 hw/i2c/trace-events              |   2 +
 hw/misc/aspeed_peci.c            | 225 +++++++++++++++++++++++++++++
 hw/misc/fby35_cpld.c             | 137 ++++++++++++++++++
 hw/misc/intel_me.c               | 176 +++++++++++++++++++++++
 hw/misc/meson.build              |   5 +-
 hw/nvram/eeprom_at24c.c          |   2 +
 hw/sensor/isl_pmbus_vr.c         |  30 ++++
 hw/sensor/lsm303dlhc_mag.c       |   2 +
 include/hw/arm/aspeed_soc.h      |   3 +
 include/hw/i2c/aspeed_i2c.h      |  11 ++
 include/hw/i2c/i2c.h             |  30 ++++
 include/hw/i2c/pmbus_device.h    |   1 +
 include/hw/misc/aspeed_peci.h    |  34 +++++
 include/hw/sensor/isl_pmbus_vr.h |   1 +
 23 files changed, 1002 insertions(+), 30 deletions(-)
 create mode 100644 hw/misc/aspeed_peci.c
 create mode 100644 hw/misc/fby35_cpld.c
 create mode 100644 hw/misc/intel_me.c
 create mode 100644 include/hw/misc/aspeed_peci.h
Signature · 1 line
2.30.2