All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH linux dev-5.3 0/3] FSI Tweaks
@ 2019-10-16 12:19 Joel Stanley
  2019-10-16 12:19 ` [PATCH linux dev-5.3 1/3] ARM: dts: aspeed: tacoma: Add host FSI description Joel Stanley
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Joel Stanley @ 2019-10-16 12:19 UTC (permalink / raw)
  To: openbmc; +Cc: Andrew Jeffery, Jeremy Kerr

These patches attempt to get the FSI master working on Tacoma.

The host FSI device tree needs rethinking, which we can do when
upstreaming the changes.

Joel Stanley (3):
  ARM: dts: aspeed: tacoma: Add host FSI description
  ARM: dts: aspeed: tacoma: Use 64MB for firmware memory
  fsi: aspeed: Disable IPOLL

 arch/arm/boot/dts/aspeed-bmc-opp-tacoma.dts | 249 +++++++++++++++++++-
 drivers/fsi/fsi-master-aspeed.c             |   2 +-
 2 files changed, 249 insertions(+), 2 deletions(-)

-- 
2.23.0

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH linux dev-5.3 1/3] ARM: dts: aspeed: tacoma: Add host FSI description
  2019-10-16 12:19 [PATCH linux dev-5.3 0/3] FSI Tweaks Joel Stanley
@ 2019-10-16 12:19 ` Joel Stanley
  2019-10-16 12:19 ` [PATCH linux dev-5.3 2/3] ARM: dts: aspeed: tacoma: Use 64MB for firmware memory Joel Stanley
  2019-10-16 12:19 ` [PATCH linux dev-5.3 3/3] fsi: aspeed: Disable IPOLL Joel Stanley
  2 siblings, 0 replies; 5+ messages in thread
From: Joel Stanley @ 2019-10-16 12:19 UTC (permalink / raw)
  To: openbmc; +Cc: Andrew Jeffery, Jeremy Kerr

This adds the description of the Power9 CPUs that are attached to the
BMC.

Signed-off-by: Joel Stanley <joel@jms.id.au>
---
 arch/arm/boot/dts/aspeed-bmc-opp-tacoma.dts | 247 ++++++++++++++++++++
 1 file changed, 247 insertions(+)

diff --git a/arch/arm/boot/dts/aspeed-bmc-opp-tacoma.dts b/arch/arm/boot/dts/aspeed-bmc-opp-tacoma.dts
index b38498a317ce..c073ad8d071f 100644
--- a/arch/arm/boot/dts/aspeed-bmc-opp-tacoma.dts
+++ b/arch/arm/boot/dts/aspeed-bmc-opp-tacoma.dts
@@ -138,6 +138,253 @@
 
 &fsim0 {
 	status = "okay";
+	#address-cells = <2>;
+	#size-cells = <0>;
+
+	cfam@0,0 {
+		reg = <0 0>;
+		#address-cells = <1>;
+		#size-cells = <1>;
+		chip-id = <0>;
+
+		scom@1000 {
+			compatible = "ibm,fsi2pib";
+			reg = <0x1000 0x400>;
+		};
+
+		i2c@1800 {
+			compatible = "ibm,fsi-i2c-master";
+			reg = <0x1800 0x400>;
+			#address-cells = <1>;
+			#size-cells = <0>;
+
+			cfam0_i2c0: i2c-bus@0 {
+				reg = <0>;
+			};
+
+			cfam0_i2c1: i2c-bus@1 {
+				reg = <1>;
+			};
+
+			cfam0_i2c2: i2c-bus@2 {
+				reg = <2>;
+			};
+
+			cfam0_i2c3: i2c-bus@3 {
+				reg = <3>;
+			};
+
+			cfam0_i2c4: i2c-bus@4 {
+				reg = <4>;
+			};
+
+			cfam0_i2c5: i2c-bus@5 {
+				reg = <5>;
+			};
+
+			cfam0_i2c6: i2c-bus@6 {
+				reg = <6>;
+			};
+
+			cfam0_i2c7: i2c-bus@7 {
+				reg = <7>;
+			};
+
+			cfam0_i2c8: i2c-bus@8 {
+				reg = <8>;
+			};
+
+			cfam0_i2c9: i2c-bus@9 {
+				reg = <9>;
+			};
+
+			cfam0_i2c10: i2c-bus@a {
+				reg = <10>;
+			};
+
+			cfam0_i2c11: i2c-bus@b {
+				reg = <11>;
+			};
+
+			cfam0_i2c12: i2c-bus@c {
+				reg = <12>;
+			};
+
+			cfam0_i2c13: i2c-bus@d {
+				reg = <13>;
+			};
+
+			cfam0_i2c14: i2c-bus@e {
+				reg = <14>;
+			};
+		};
+
+		sbefifo@2400 {
+			compatible = "ibm,p9-sbefifo";
+			reg = <0x2400 0x400>;
+			#address-cells = <1>;
+			#size-cells = <0>;
+
+			fsi_occ0: occ {
+				compatible = "ibm,p9-occ";
+			};
+		};
+
+		fsi_hub0: hub@3400 {
+			compatible = "fsi-master-hub";
+			reg = <0x3400 0x400>;
+			#address-cells = <2>;
+			#size-cells = <0>;
+
+			no-scan-on-init;
+		};
+	};
+};
+
+&fsi_hub0 {
+	cfam@1,0 {
+		reg = <1 0>;
+		#address-cells = <1>;
+		#size-cells = <1>;
+		chip-id = <1>;
+
+		scom@1000 {
+			compatible = "ibm,fsi2pib";
+			reg = <0x1000 0x400>;
+		};
+
+		i2c@1800 {
+			compatible = "ibm,fsi-i2c-master";
+			reg = <0x1800 0x400>;
+			#address-cells = <1>;
+			#size-cells = <0>;
+
+			cfam1_i2c0: i2c-bus@0 {
+				reg = <0>;
+			};
+
+			cfam1_i2c1: i2c-bus@1 {
+				reg = <1>;
+			};
+
+			cfam1_i2c2: i2c-bus@2 {
+				reg = <2>;
+			};
+
+			cfam1_i2c3: i2c-bus@3 {
+				reg = <3>;
+			};
+
+			cfam1_i2c4: i2c-bus@4 {
+				reg = <4>;
+			};
+
+			cfam1_i2c5: i2c-bus@5 {
+				reg = <5>;
+			};
+
+			cfam1_i2c6: i2c-bus@6 {
+				reg = <6>;
+			};
+
+			cfam1_i2c7: i2c-bus@7 {
+				reg = <7>;
+			};
+
+			cfam1_i2c8: i2c-bus@8 {
+				reg = <8>;
+			};
+
+			cfam1_i2c9: i2c-bus@9 {
+				reg = <9>;
+			};
+
+			cfam1_i2c10: i2c-bus@a {
+				reg = <10>;
+			};
+
+			cfam1_i2c11: i2c-bus@b {
+				reg = <11>;
+			};
+
+			cfam1_i2c12: i2c-bus@c {
+				reg = <12>;
+			};
+
+			cfam1_i2c13: i2c-bus@d {
+				reg = <13>;
+			};
+
+			cfam1_i2c14: i2c-bus@e {
+				reg = <14>;
+			};
+		};
+
+		sbefifo@2400 {
+			compatible = "ibm,p9-sbefifo";
+			reg = <0x2400 0x400>;
+			#address-cells = <1>;
+			#size-cells = <0>;
+
+			fsi_occ1: occ {
+				compatible = "ibm,p9-occ";
+			};
+		};
+
+		fsi_hub1: hub@3400 {
+			compatible = "fsi-master-hub";
+			reg = <0x3400 0x400>;
+			#address-cells = <2>;
+			#size-cells = <0>;
+
+			no-scan-on-init;
+		};
+	};
+};
+
+/* Legacy OCC numbering (to get rid of when userspace is fixed) */
+&fsi_occ0 {
+	reg = <1>;
+};
+
+&fsi_occ1 {
+	reg = <2>;
+};
+
+/ {
+	aliases {
+		i2c100 = &cfam0_i2c0;
+		i2c101 = &cfam0_i2c1;
+		i2c102 = &cfam0_i2c2;
+		i2c103 = &cfam0_i2c3;
+		i2c104 = &cfam0_i2c4;
+		i2c105 = &cfam0_i2c5;
+		i2c106 = &cfam0_i2c6;
+		i2c107 = &cfam0_i2c7;
+		i2c108 = &cfam0_i2c8;
+		i2c109 = &cfam0_i2c9;
+		i2c110 = &cfam0_i2c10;
+		i2c111 = &cfam0_i2c11;
+		i2c112 = &cfam0_i2c12;
+		i2c113 = &cfam0_i2c13;
+		i2c114 = &cfam0_i2c14;
+		i2c200 = &cfam1_i2c0;
+		i2c201 = &cfam1_i2c1;
+		i2c202 = &cfam1_i2c2;
+		i2c203 = &cfam1_i2c3;
+		i2c204 = &cfam1_i2c4;
+		i2c205 = &cfam1_i2c5;
+		i2c206 = &cfam1_i2c6;
+		i2c207 = &cfam1_i2c7;
+		i2c208 = &cfam1_i2c8;
+		i2c209 = &cfam1_i2c9;
+		i2c210 = &cfam1_i2c10;
+		i2c211 = &cfam1_i2c11;
+		i2c212 = &cfam1_i2c12;
+		i2c213 = &cfam1_i2c13;
+		i2c214 = &cfam1_i2c14;
+	};
+
 };
 
 &i2c0 {
-- 
2.23.0

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH linux dev-5.3 2/3] ARM: dts: aspeed: tacoma: Use 64MB for firmware memory
  2019-10-16 12:19 [PATCH linux dev-5.3 0/3] FSI Tweaks Joel Stanley
  2019-10-16 12:19 ` [PATCH linux dev-5.3 1/3] ARM: dts: aspeed: tacoma: Add host FSI description Joel Stanley
@ 2019-10-16 12:19 ` Joel Stanley
  2019-10-16 19:10   ` Eddie James
  2019-10-16 12:19 ` [PATCH linux dev-5.3 3/3] fsi: aspeed: Disable IPOLL Joel Stanley
  2 siblings, 1 reply; 5+ messages in thread
From: Joel Stanley @ 2019-10-16 12:19 UTC (permalink / raw)
  To: openbmc; +Cc: Andrew Jeffery, Jeremy Kerr

Mbox's file mode needs a window the same size as the image being loaded.

Signed-off-by: Joel Stanley <joel@jms.id.au>
---
 arch/arm/boot/dts/aspeed-bmc-opp-tacoma.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/aspeed-bmc-opp-tacoma.dts b/arch/arm/boot/dts/aspeed-bmc-opp-tacoma.dts
index c073ad8d071f..f0d2f741800a 100644
--- a/arch/arm/boot/dts/aspeed-bmc-opp-tacoma.dts
+++ b/arch/arm/boot/dts/aspeed-bmc-opp-tacoma.dts
@@ -27,7 +27,7 @@
 
 		flash_memory: region@ba000000 {
 			no-map;
-			reg = <0xba000000 0x2000000>; /* 32M */
+			reg = <0xba000000 0x4000000>; /* 64M */
 		};
 	};
 
-- 
2.23.0

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH linux dev-5.3 3/3] fsi: aspeed: Disable IPOLL
  2019-10-16 12:19 [PATCH linux dev-5.3 0/3] FSI Tweaks Joel Stanley
  2019-10-16 12:19 ` [PATCH linux dev-5.3 1/3] ARM: dts: aspeed: tacoma: Add host FSI description Joel Stanley
  2019-10-16 12:19 ` [PATCH linux dev-5.3 2/3] ARM: dts: aspeed: tacoma: Use 64MB for firmware memory Joel Stanley
@ 2019-10-16 12:19 ` Joel Stanley
  2 siblings, 0 replies; 5+ messages in thread
From: Joel Stanley @ 2019-10-16 12:19 UTC (permalink / raw)
  To: openbmc; +Cc: Andrew Jeffery, Jeremy Kerr

Having IPOLL enabled when turning on the host causes FSI to stop
working.

In the future we will need to add a mechansim for the BMC to enable
IPOLL once it is ready.

Signed-off-by: Joel Stanley <joel@jms.id.au>
---
 drivers/fsi/fsi-master-aspeed.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/fsi/fsi-master-aspeed.c b/drivers/fsi/fsi-master-aspeed.c
index 4e7d8a4bbc19..95b7f833e8bc 100644
--- a/drivers/fsi/fsi-master-aspeed.c
+++ b/drivers/fsi/fsi-master-aspeed.c
@@ -421,7 +421,7 @@ static int aspeed_master_init(struct fsi_master_aspeed *aspeed)
 	reg = cpu_to_be32(FSI_MECTRL_EOAE | FSI_MECTRL_P8_AUTO_TERM);
 	opb_write(aspeed->base, ctrl_base + FSI_MECTRL, reg, 4);
 
-	reg = cpu_to_be32(FSI_MMODE_EIP | FSI_MMODE_ECRC | FSI_MMODE_EPC
+	reg = cpu_to_be32(FSI_MMODE_ECRC | FSI_MMODE_EPC
 			| fsi_mmode_crs0(0x7f) | fsi_mmode_crs1(0x7f)
 			| FSI_MMODE_P8_TO_LSB);
 	opb_write(aspeed->base, ctrl_base + FSI_MMODE, reg, 4);
-- 
2.23.0

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH linux dev-5.3 2/3] ARM: dts: aspeed: tacoma: Use 64MB for firmware memory
  2019-10-16 12:19 ` [PATCH linux dev-5.3 2/3] ARM: dts: aspeed: tacoma: Use 64MB for firmware memory Joel Stanley
@ 2019-10-16 19:10   ` Eddie James
  0 siblings, 0 replies; 5+ messages in thread
From: Eddie James @ 2019-10-16 19:10 UTC (permalink / raw)
  To: Joel Stanley, openbmc; +Cc: Andrew Jeffery


On 10/16/19 7:19 AM, Joel Stanley wrote:
> Mbox's file mode needs a window the same size as the image being loaded.
>
> Signed-off-by: Joel Stanley <joel@jms.id.au>
> ---
>   arch/arm/boot/dts/aspeed-bmc-opp-tacoma.dts | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/arm/boot/dts/aspeed-bmc-opp-tacoma.dts b/arch/arm/boot/dts/aspeed-bmc-opp-tacoma.dts
> index c073ad8d071f..f0d2f741800a 100644
> --- a/arch/arm/boot/dts/aspeed-bmc-opp-tacoma.dts
> +++ b/arch/arm/boot/dts/aspeed-bmc-opp-tacoma.dts
> @@ -27,7 +27,7 @@
>   
>   		flash_memory: region@ba000000 {
>   			no-map;
> -			reg = <0xba000000 0x2000000>; /* 32M */
> +			reg = <0xba000000 0x4000000>; /* 64M */


Milton pointed out that this should be aligned to 64M, so 0xb8000000.

Thanks,

Eddie


>   		};
>   	};
>   

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-10-16 19:18 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-16 12:19 [PATCH linux dev-5.3 0/3] FSI Tweaks Joel Stanley
2019-10-16 12:19 ` [PATCH linux dev-5.3 1/3] ARM: dts: aspeed: tacoma: Add host FSI description Joel Stanley
2019-10-16 12:19 ` [PATCH linux dev-5.3 2/3] ARM: dts: aspeed: tacoma: Use 64MB for firmware memory Joel Stanley
2019-10-16 19:10   ` Eddie James
2019-10-16 12:19 ` [PATCH linux dev-5.3 3/3] fsi: aspeed: Disable IPOLL Joel Stanley

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.