fsi: sbefifo: Prevent async FFDC collection for Odyssey SBEFIFOs
Subsystems (3)
Eddie James
maintainerv3 cover fsi: sbefifo: Prevent async FFDC collection for Odyssey SBEFIFOs
A new type of SBE, found on the Odyssey chip, will return any async FFDC in the next transaction, so collecting the FFDC is unnecessary and results in unexpected behavior. This difference in behavior between the Odyssey SBE and the POWER9/10 SBEs wasn't apparent when support for the Odyssey was added. To fix the unexpected behavior, turn off the async collection fot Odyssey SBEFIFOs.
Changes since v2:
- Update commit messages slightly
- Rename dts binding file
- Remove '|' after description in dts binding
- Change generic node name in dts binding to match fsi.txt
Changes since v1:
- Change "ody" to "odyssey"
- Fix minor issues in binding document
Eddie James (3):
dt-bindings: fsi: Document the IBM SBEFIFO engine
fsi: sbefifo: Prevent async FFDC collection for Odyssey SBEFIFOs
ARM: dts: aspeed: Update Odyssey SBEFIFO compatible strings
.../bindings/fsi/ibm,p9-sbefifo.yaml | 39 +++++++++++ .../dts/aspeed/aspeed-bmc-ibm-everest.dts | 64 +++++++++---------- .../arm/boot/dts/aspeed/ibm-power10-quad.dtsi | 64 +++++++++---------- drivers/fsi/fsi-sbefifo.c | 37 +++++++++++ 4 files changed, 140 insertions(+), 64 deletions(-) create mode 100644 Documentation/devicetree/bindings/fsi/ibm,p9-sbefifo.yaml
Signature · 1 line
2.39.3
Eddie James
maintainerPATCH v3 1/3 dt-bindings: fsi: Document the IBM SBEFIFO engine
The SBEFIFO engine provides an interface to the POWER processor Self Boot Engine (SBE).
---
Changes since v1:
- Chance "ody" to "odyssey"
- Fix typo in commit message
- Reword description to describe the hardware only
Changes since v2:
- Rename file
- Remove '|' after description
- Change generic node name to match fsi.txt
.../bindings/fsi/ibm,p9-sbefifo.yaml | 39 +++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 Documentation/devicetree/bindings/fsi/ibm,p9-sbefifo.yaml
Documentation/devicetree/bindings/fsi/ibm,p9-sbefifo.yaml new file +39 -0
@@ -0,0 +1,39 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/fsi/ibm,p9-sbefifo.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: IBM FSI-attached SBEFIFO engine + +maintainers: + - Eddie James <[email protected]> + +description: + The SBEFIFO is an FSI CFAM engine that provides an interface to the + POWER processor Self Boot Engine (SBE). This node will always be a child + of an FSI CFAM node; see fsi.txt for details on FSI slave and CFAM + nodes. + +properties: + compatible: + enum: + - ibm,p9-sbefifo + - ibm,odyssey-sbefifo + + reg: + items: + - description: FSI slave address + +required: + - compatible + - reg + +additionalProperties: false + +examples: + - | + fsi-slave-engine at 2400 { + compatible = "ibm,p9-sbefifo"; + reg = <0x2400 0x400>; + };
Signature · 1 line
2.39.3
PATCH v3 1/3 dt-bindings: fsi: Document the IBM SBEFIFO engine
Quoted 4 lines · Eddie James
The SBEFIFO engine provides an interface to the POWER processor Self Boot Engine (SBE).
Signed-off-by Eddie James <[email protected]>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 228 bytes
Desc: not available
URL: <http://lists.ozlabs.org/pipermail/linux-aspeed/attachments/20240420/118ad94a/attachment.sig>
Andrew Jeffery
maintainerPATCH v3 1/3 dt-bindings: fsi: Document the IBM SBEFIFO engine
In reply to Eddie JamesQuoted 4 lines · Eddie James
The SBEFIFO engine provides an interface to the POWER processor Self Boot Engine (SBE).
Signed-off-by Eddie James <[email protected]>
Eddie James
maintainerPATCH v3 1/3 dt-bindings: fsi: Document the IBM SBEFIFO engine
Quoted 6 lines · Andrew Jeffery
Quoted 4 lines · Eddie James
The SBEFIFO engine provides an interface to the POWER processor Self Boot Engine (SBE).
Signed-off-by Eddie James <[email protected]>Reviewed-by Andrew Jeffery <[email protected]>
I'm sending this patch in my new series for P11 BMC systems, with an additional change for the OCC child nodes. Hopefully that's OK, I kept the tags.
Eddie
Andrew Jeffery
maintainerPATCH v3 1/3 dt-bindings: fsi: Document the IBM SBEFIFO engine
Quoted 5 lines · Eddie James
Quoted 4 lines · Andrew Jeffery
Quoted 3 lines · Eddie James
The SBEFIFO engine provides an interface to the POWER processor Self Boot Engine (SBE).
Quoted 7 lines
Quoted 2 lines
Quoted 1 line
Signed-off-by Eddie James <[email protected]>Reviewed-by Andrew Jeffery <[email protected]>I'm sending this patch in my new series for P11 BMC systems, with an additional change for the OCC child nodes. Hopefully that's OK, I kept the tags.
From a quick look I think that's fine.
Thanks,
Andrew
Eddie James
maintainerPATCH v3 2/3 fsi: sbefifo: Prevent async FFDC collection for Odyssey SBEFIFOs
In reply to Eddie JamesA new type of SBE, found on the Odyssey chip, will return any async FFDC in the next transaction, so collecting the FFDC is unnecessary and results in unexpected behavior. This difference in behavior between the Odyssey SBE and the POWER9/10 SBEs wasn't apparent when support for the Odyssey was added. To fix the unexpected behavior, turn off the async collection fot Odyssey SBEFIFOs.
---
Changes since v2:
- Update commit message
Changes since v1:
- Change "ody" to "odyssey"
drivers/fsi/fsi-sbefifo.c | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+)
drivers/fsi/fsi-sbefifo.c +37 -0
@@ -125,6 +125,7 @@ struct sbefifo {struct mutex lock;bool broken;bool dead; +bool need_async;bool async_ffdc;bool timed_out;u32 timeout_in_cmd_ms;
@@ -141,6 +142,10 @@ struct sbefifo_user {u32 read_timeout_ms; }; +struct sbefifo_data { +bool need_async; +}; +static DEFINE_MUTEX (sbefifo_ffdc_mutex); static ssize_t timeout_show(struct device *dev, struct device_attribute *attr,
@@ -317,6 +322,10 @@ static int sbefifo_check_sbe_state(struct sbefifo *sbefifo)return -ESHUTDOWN ; } +/* Newer SBEFIFOs don't need async FFDC collection */ +if (!sbefifo->need_async) +return 0 ; +/* Is there async FFDC available ? Remember it */ if (sbm &CFAM_SBM_SBE_ASYNC_FFDC ) sbefifo->async_ffdc = true;
@@ -1031,6 +1040,7 @@ static void sbefifo_free(struct device *dev)static int sbefifo_probe (struct device *dev) { +const struct sbefifo_data *md =of_device_get_match_data (dev);struct fsi_device *fsi_dev =to_fsi_dev (dev);struct sbefifo *sbefifo;struct device_node *np;
@@ -1044,6 +1054,11 @@ static int sbefifo_probe(struct device *dev)if (!sbefifo)return -ENOMEM ; +if (md) + sbefifo->need_async = md->need_async; +else + sbefifo->need_async = true; +/* Grab a reference to the device (parent of our cdev), we'll drop it later */ if (!get_device (dev)) {kfree (sbefifo);
@@ -1128,6 +1143,27 @@ static int sbefifo_remove(struct device *dev)return 0 ; } +static const struct sbefifo_data p9_sbefifo_data = { + .need_async = true, +}; + +static const struct sbefifo_data odyssey_sbefifo_data = { + .need_async = false, +}; + +static const struct of_device_id sbefifo_of_ids[] = { + { + .compatible ="ibm,p9-sbefifo" , + .data = &p9_sbefifo_data, + }, + { + .compatible ="ibm,odyssey-sbefifo" , + .data = &odyssey_sbefifo_data, + }, + { } +}; +MODULE_DEVICE_TABLE (of, sbefifo_of_ids); +static const struct fsi_device_id sbefifo_ids[] = { { .engine_type =FSI_ENGID_SBE ,
@@ -1141,6 +1177,7 @@ static struct fsi_driver sbefifo_drv = { .drv = { .name = DEVICE_NAME, .bus = &fsi_bus_type, + .of_match_table = sbefifo_of_ids, .probe = sbefifo_probe, .remove = sbefifo_remove, }
Signature · 1 line
2.39.3
Eddie James
maintainerPATCH v3 3/3 ARM: dts: aspeed: Update Odyssey SBEFIFO compatible strings
In reply to Eddie JamesA new type of SBE, found on the Odyssey chip, will return any async FFDC in the next transaction, so collecting the FFDC is unnecessary and results in unexpected behavior. This difference in behavior between the Odyssey SBE and the POWER9/10 SBEs wasn't apparent when support for the Odyssey was added. To fix the unexpected behavior, set the new compatible string for Odyssey SBEFIFOs so that they don't collect async FFDC.
---
Changes since v2:
- Update commit message
Changes since v1:
- Change "ody" to "odyssey"
.../dts/aspeed/aspeed-bmc-ibm-everest.dts | 64 +++++++++---------- .../arm/boot/dts/aspeed/ibm-power10-quad.dtsi | 64 +++++++++---------- 2 files changed, 64 insertions(+), 64 deletions(-)
arch/arm/boot/dts/aspeed/aspeed-bmc-ibm-everest.dts +32 -32
@@ -2545,7 +2545,7 @@ scom500: scom at 1000 { }; sbefifo500: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -2577,7 +2577,7 @@ scom501: scom at 1000 { }; sbefifo501: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -2609,7 +2609,7 @@ scom510: scom at 1000 { }; sbefifo510: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -2641,7 +2641,7 @@ scom511: scom at 1000 { }; sbefifo511: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -2673,7 +2673,7 @@ scom512: scom at 1000 { }; sbefifo512: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -2705,7 +2705,7 @@ scom513: scom at 1000 { }; sbefifo513: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -2737,7 +2737,7 @@ scom514: scom at 1000 { }; sbefifo514: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -2769,7 +2769,7 @@ scom515: scom at 1000 { }; sbefifo515: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -2918,7 +2918,7 @@ scom602: scom at 1000 { }; sbefifo602: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -2950,7 +2950,7 @@ scom603: scom at 1000 { }; sbefifo603: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -2982,7 +2982,7 @@ scom610: scom at 1000 { }; sbefifo610: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3014,7 +3014,7 @@ scom611: scom at 1000 { }; sbefifo611: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3046,7 +3046,7 @@ scom614: scom at 1000 { }; sbefifo614: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3078,7 +3078,7 @@ scom615: scom at 1000 { }; sbefifo615: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3110,7 +3110,7 @@ scom616: scom at 1000 { }; sbefifo616: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3142,7 +3142,7 @@ scom617: scom at 1000 { }; sbefifo617: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3291,7 +3291,7 @@ scom700: scom at 1000 { }; sbefifo700: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3323,7 +3323,7 @@ scom701: scom at 1000 { }; sbefifo701: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3355,7 +3355,7 @@ scom710: scom at 1000 { }; sbefifo710: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3387,7 +3387,7 @@ scom711: scom at 1000 { }; sbefifo711: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3419,7 +3419,7 @@ scom712: scom at 1000 { }; sbefifo712: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3451,7 +3451,7 @@ scom713: scom at 1000 { }; sbefifo713: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3483,7 +3483,7 @@ scom714: scom at 1000 { }; sbefifo714: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3515,7 +3515,7 @@ scom715: scom at 1000 { }; sbefifo715: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3664,7 +3664,7 @@ scom802: scom at 1000 { }; sbefifo802: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3696,7 +3696,7 @@ scom803: scom at 1000 { }; sbefifo803: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3728,7 +3728,7 @@ scom810: scom at 1000 { }; sbefifo810: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3760,7 +3760,7 @@ scom811: scom at 1000 { }; sbefifo811: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3792,7 +3792,7 @@ scom814: scom at 1000 { }; sbefifo814: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3824,7 +3824,7 @@ scom815: scom at 1000 { }; sbefifo815: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3856,7 +3856,7 @@ scom816: scom at 1000 { }; sbefifo816: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
@@ -3888,7 +3888,7 @@ scom817: scom at 1000 { }; sbefifo817: sbefifo at 2400 { - compatible = "ibm,p9-sbefifo"; + compatible = "ibm,odyssey-sbefifo"; reg = <0x2400 0x400>; #address-cells = <1>; #size-cells = <0>;
arch/arm/boot/dts/aspeed/ibm-power10-quad.dtsi +32 -32
256 lines not on this page · raw message
Signature · 1 line
2.39.3