open-power / pdbg

PowerPC FSI Debugger
Apache License 2.0
16 stars 39 forks source link

Soft FSI backend GPIO assignments #10

Closed GHF closed 7 years ago

GHF commented 7 years ago

The BMC soft FSI needs to handle different GPIO assignments across different boards. This can be accomplished in a few different ways:

  1. Provide a default hardcoded set of assignments in the code that get patched by OpenBMC machine layers
  2. Add pin assignments that are selectable at runtime (current solution in HEAD), and OpenBMC scripts can use board names to choose the assignments
  3. Read pin assignments from OpenBMC machine config (https://github.com/openbmc/skeleton/tree/master/configs)

3 is probably not desirable since it's a decent bit of code to make it work and both this soft FSI implementation and Python skeleton are meant to have short volatile lives.

apopple commented 7 years ago

The production plan for OpenBMC and pdbg is to move the GPIO bmcfsi backend into the OpenBMC kernel. pdbg would then use the kernel drivers to do the actual FSI protocol and they would read the GPIO assignments from the device-tree so that the userspace side doesn't need to know anything about GPIO pins.

williamspatrick commented 7 years ago

Is there an 'alias' we can add to GPIOs in the device tree to make it easier on userspace?

ozbenh commented 7 years ago

On Thu, 2016-12-08 at 04:00 -0800, Patrick Williams wrote:

Is there an 'alias' we can add to GPIOs in the device tree to make it easier on userspace?

Good idea. Can you create devalias entries ? Something like fsi- master0-clk, fsi-master0-data ?

Cheers, Ben.

apopple commented 7 years ago

Now that OpenFSI is in the kernel I'm assuming this is no longer an issue. Please re-open if there is still an issue here.