From 58cf8b1a7389d20494c909b3542beeb987c69581 Mon Sep 17 00:00:00 2001 From: "Jason M. Bills" Date: Tue, 26 May 2020 12:54:18 -0700 Subject: Update to internal 0.56 Signed-off-by: Jason M. Bills --- ...m-dts-add-DTS-for-Intel-ast2500-platforms.patch | 22 +++++-- ...m-dts-add-DTS-for-Intel-ast2600-platforms.patch | 22 +++++-- .../linux-aspeed/0005-128MB-flashmap-for-PFR.patch | 29 ++++++--- .../linux-aspeed/0103-Refine-clock-settings.patch | 72 ++-------------------- ...0104-Add-chip-unique-id-reading-interface.patch | 20 +++--- ...speed-fix-arbitration-loss-handling-logic.patch | 38 ++++++++++++ 6 files changed, 108 insertions(+), 95 deletions(-) mode change 100644 => 100755 meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0005-128MB-flashmap-for-PFR.patch create mode 100644 meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0105-i2c-aspeed-fix-arbitration-loss-handling-logic.patch (limited to 'meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed') diff --git a/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0001-arm-dts-add-DTS-for-Intel-ast2500-platforms.patch b/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0001-arm-dts-add-DTS-for-Intel-ast2500-platforms.patch index 5a01aaeed..5c4fb8a25 100644 --- a/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0001-arm-dts-add-DTS-for-Intel-ast2500-platforms.patch +++ b/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0001-arm-dts-add-DTS-for-Intel-ast2500-platforms.patch @@ -1,4 +1,4 @@ -From c2019bbf210e0e750478a3e6c0c9bfa557c5bc0f Mon Sep 17 00:00:00 2001 +From 2399c5d353e4b8dc55bd7c56bb3f1d01918bccd9 Mon Sep 17 00:00:00 2001 From: Yuan Li Date: Tue, 19 Sep 2017 15:55:39 +0800 Subject: [PATCH] arm: dts: add DTS for Intel ast2500 platforms @@ -16,17 +16,18 @@ Signed-off-by: Chen Yugang Signed-off-by: Zhikui Ren Signed-off-by: jayaprakash Mutyala Signed-off-by: AppaRao Puli +Signed-off-by: Arun P. Mohanan --- - arch/arm/boot/dts/aspeed-bmc-intel-ast2500.dts | 474 +++++++++++++++++++++++++ - 1 file changed, 474 insertions(+) + .../arm/boot/dts/aspeed-bmc-intel-ast2500.dts | 477 ++++++++++++++++++ + 1 file changed, 477 insertions(+) create mode 100644 arch/arm/boot/dts/aspeed-bmc-intel-ast2500.dts diff --git a/arch/arm/boot/dts/aspeed-bmc-intel-ast2500.dts b/arch/arm/boot/dts/aspeed-bmc-intel-ast2500.dts new file mode 100644 -index 000000000000..18fa1f804874 +index 000000000000..980e2b55a09a --- /dev/null +++ b/arch/arm/boot/dts/aspeed-bmc-intel-ast2500.dts -@@ -0,0 +1,468 @@ +@@ -0,0 +1,477 @@ +/dts-v1/; + +#include "aspeed-g5.dtsi" @@ -255,6 +256,15 @@ index 000000000000..18fa1f804874 + status = "okay"; +}; + ++&sio_regs { ++ status = "okay"; ++ sio_status { ++ offset = <0x8C>; ++ bit-mask = <0x1F>; ++ bit-shift = <4>; ++ }; ++}; ++ +&lpc_sio { + status = "okay"; +}; @@ -496,5 +506,5 @@ index 000000000000..18fa1f804874 + status = "okay"; +}; -- -2.7.4 +2.17.1 diff --git a/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0001-arm-dts-add-DTS-for-Intel-ast2600-platforms.patch b/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0001-arm-dts-add-DTS-for-Intel-ast2600-platforms.patch index b3e7342c5..e77f744ff 100644 --- a/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0001-arm-dts-add-DTS-for-Intel-ast2600-platforms.patch +++ b/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0001-arm-dts-add-DTS-for-Intel-ast2600-platforms.patch @@ -1,4 +1,4 @@ -From 0fca4f924e45f1968f610ad8903f18d638188784 Mon Sep 17 00:00:00 2001 +From 297e22a00a71d386c93b1e0d587a01c0386b31f3 Mon Sep 17 00:00:00 2001 From: Vernon Mauery Date: Tue, 19 Sep 2017 15:55:39 +0800 Subject: [PATCH] arm: dts: add DTS for Intel ast2600 platforms @@ -11,17 +11,18 @@ Signed-off-by: Chen Yugang Signed-off-by: Kuiying Wang Signed-off-by: arun-pm Signed-off-by: Ayushi Smriti +Signed-off-by: Arun P. Mohanan --- - arch/arm/boot/dts/aspeed-bmc-intel-ast2600.dts | 516 +++++++++++++++++++++++++ - 1 file changed, 516 insertions(+) + .../arm/boot/dts/aspeed-bmc-intel-ast2600.dts | 519 ++++++++++++++++++ + 1 file changed, 519 insertions(+) create mode 100644 arch/arm/boot/dts/aspeed-bmc-intel-ast2600.dts diff --git a/arch/arm/boot/dts/aspeed-bmc-intel-ast2600.dts b/arch/arm/boot/dts/aspeed-bmc-intel-ast2600.dts new file mode 100644 -index 000000000000..6d626338232e +index 000000000000..a95b5ac828b3 --- /dev/null +++ b/arch/arm/boot/dts/aspeed-bmc-intel-ast2600.dts -@@ -0,0 +1,510 @@ +@@ -0,0 +1,519 @@ +// SPDX-License-Identifier: GPL-2.0+ +/dts-v1/; + @@ -279,6 +280,15 @@ index 000000000000..6d626338232e + status = "okay"; +}; + ++&sio_regs { ++ status = "okay"; ++ sio_status { ++ offset = <0x8C>; ++ bit-mask = <0x1F>; ++ bit-shift = <4>; ++ }; ++}; ++ +&lpc_sio { + status = "okay"; +}; @@ -533,5 +543,5 @@ index 000000000000..6d626338232e + status = "okay"; +}; -- -2.7.4 +2.17.1 diff --git a/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0005-128MB-flashmap-for-PFR.patch b/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0005-128MB-flashmap-for-PFR.patch old mode 100644 new mode 100755 index ca54df9ee..7dd9990a9 --- a/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0005-128MB-flashmap-for-PFR.patch +++ b/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0005-128MB-flashmap-for-PFR.patch @@ -1,6 +1,6 @@ -From 9a71adc7aecbfdf066ba54c763c2ecd8fb09d3cd Mon Sep 17 00:00:00 2001 -From: Vikram Bodireddy -Date: Wed, 6 Feb 2019 15:59:34 +0530 +From ca0fa975d066b15637188e8fe37dd6d12e0e2bc4 Mon Sep 17 00:00:00 2001 +From: Kuiying Wang +Date: Tue, 28 Apr 2020 22:32:41 +0800 Subject: [PATCH] Selecting 128MB for PFR PFR platforms requires 128MB flash mapping. @@ -8,15 +8,17 @@ This will override the existing 64MB flash map and loads 128MB flash map. Signed-off-by: Vikram Bodireddy +Signed-off-by: Kuiying Wang --- arch/arm/boot/dts/aspeed-bmc-intel-ast2500.dts | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + arch/arm/boot/dts/aspeed-bmc-intel-ast2600.dts | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/boot/dts/aspeed-bmc-intel-ast2500.dts b/arch/arm/boot/dts/aspeed-bmc-intel-ast2500.dts -index 4815104459f1..df02bb1aaf36 100644 +index 13b94bdf5d62..2cab5fb38d4f 100644 --- a/arch/arm/boot/dts/aspeed-bmc-intel-ast2500.dts +++ b/arch/arm/boot/dts/aspeed-bmc-intel-ast2500.dts -@@ -89,7 +89,7 @@ +@@ -96,7 +96,7 @@ flash@0 { status = "okay"; m25p,fast-read; @@ -25,6 +27,19 @@ index 4815104459f1..df02bb1aaf36 100644 }; }; +diff --git a/arch/arm/boot/dts/aspeed-bmc-intel-ast2600.dts b/arch/arm/boot/dts/aspeed-bmc-intel-ast2600.dts +index a95b5ac828b3..bf66e1b6c0fd 100644 +--- a/arch/arm/boot/dts/aspeed-bmc-intel-ast2600.dts ++++ b/arch/arm/boot/dts/aspeed-bmc-intel-ast2600.dts +@@ -94,7 +94,7 @@ + spi-max-frequency = <40000000>; + spi-tx-bus-width = <4>; + m25p,fast-read; +-#include "openbmc-flash-layout-intel-64MB.dtsi" ++#include "openbmc-flash-layout-intel-128MB.dtsi" + }; + }; + -- -2.7.4 +2.17.1 diff --git a/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0103-Refine-clock-settings.patch b/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0103-Refine-clock-settings.patch index 4d7440185..ef234fffe 100644 --- a/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0103-Refine-clock-settings.patch +++ b/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0103-Refine-clock-settings.patch @@ -1,4 +1,4 @@ -From dd7498a847b3e908dabaed2e9a27b43a26d0dba0 Mon Sep 17 00:00:00 2001 +From 9fc2343bac42db2432f96db1bbfc6979822a7154 Mon Sep 17 00:00:00 2001 From: Jae Hyun Yoo Date: Thu, 26 Mar 2020 14:20:19 -0700 Subject: [PATCH] Refine clock settings @@ -8,11 +8,11 @@ code from Aspeed SDK v00.05.05 Signed-off-by: Jae Hyun Yoo --- - drivers/clk/clk-ast2600.c | 104 +++++++++++++++++++++++++++++++++++++--------- - 1 file changed, 85 insertions(+), 19 deletions(-) + drivers/clk/clk-ast2600.c | 60 +++++++++++++++++++++++++++++++++++++++++------ + 1 file changed, 53 insertions(+), 7 deletions(-) diff --git a/drivers/clk/clk-ast2600.c b/drivers/clk/clk-ast2600.c -index af908b2dbeb6..e5079c5f4fcf 100644 +index fb6b11440b97..e07326544fdc 100644 --- a/drivers/clk/clk-ast2600.c +++ b/drivers/clk/clk-ast2600.c @@ -31,6 +31,24 @@ @@ -86,69 +86,7 @@ index af908b2dbeb6..e5079c5f4fcf 100644 &aspeed_g6_clk_lock); if (IS_ERR(hw)) return PTR_ERR(hw); -@@ -650,12 +665,20 @@ static struct platform_driver aspeed_g6_clk_driver = { - }; - builtin_platform_driver(aspeed_g6_clk_driver); - --static const u32 ast2600_a0_axi_ahb_div_table[] = { -- 2, 2, 3, 5, -+static u32 ast2600_a0_axi_ahb_div_table[] = { -+ 2, 2, 3, 4, - }; - --static const u32 ast2600_a1_axi_ahb_div_table[] = { -- 4, 6, 2, 4, -+static u32 ast2600_a1_axi_ahb_div0_table[] = { -+ 3, 2, 3, 4, -+}; -+ -+static u32 ast2600_a1_axi_ahb_div1_table[] = { -+ 3, 4, 6, 8, -+}; -+ -+static const u32 ast2600_a1_axi_ahb_default_table[] = { -+ 3, 4, 3, 4, 2, 2, 2, 2, - }; - - static void __init aspeed_g6_cc(struct regmap *map) -@@ -686,16 +709,28 @@ static void __init aspeed_g6_cc(struct regmap *map) - - /* Strap bits 12:11 define the AXI/AHB clock frequency ratio (aka HCLK)*/ - regmap_read(map, ASPEED_G6_STRAP1, &val); -- if (val & BIT(16)) -- axi_div = 1; -- else -- axi_div = 2; -- - regmap_read(map, ASPEED_G6_SILICON_REV, &chip_id); -- if (chip_id & BIT(16)) -- ahb_div = ast2600_a1_axi_ahb_div_table[(val >> 11) & 0x3]; -- else -+ if (chip_id & BIT(16)) { -+ if (val & BIT(16)) { -+ axi_div = 1; -+ ast2600_a1_axi_ahb_div1_table[0] = -+ ast2600_a1_axi_ahb_default_table[(val >> 8) & -+ 0x3]; -+ ahb_div = ast2600_a1_axi_ahb_div1_table[(val >> 11) & -+ 0x3]; -+ } else { -+ axi_div = 2; -+ ast2600_a1_axi_ahb_div0_table[0] = -+ ast2600_a1_axi_ahb_default_table[(val >> 8) & -+ 0x3]; -+ ahb_div = ast2600_a1_axi_ahb_div0_table[(val >> 11) & -+ 0x3]; -+ } -+ } else { -+ /* a0 : fix axi = hpll/2 */ -+ axi_div = 2; - ahb_div = ast2600_a0_axi_ahb_div_table[(val >> 11) & 0x3]; -+ } - - hw = clk_hw_register_fixed_factor(NULL, "ahb", "hpll", 0, 1, axi_div * ahb_div); - aspeed_g6_clk_data->hws[ASPEED_CLK_AHB] = hw; -@@ -751,6 +786,37 @@ static void __init aspeed_g6_cc_init(struct device_node *np) +@@ -770,6 +785,37 @@ static void __init aspeed_g6_cc_init(struct device_node *np) return; } diff --git a/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0104-Add-chip-unique-id-reading-interface.patch b/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0104-Add-chip-unique-id-reading-interface.patch index f366287f1..ec215d07a 100644 --- a/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0104-Add-chip-unique-id-reading-interface.patch +++ b/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0104-Add-chip-unique-id-reading-interface.patch @@ -1,4 +1,4 @@ -From 61fd1c976a0867deec8607183849969e2d96aef7 Mon Sep 17 00:00:00 2001 +From 766f7e504cc2a0508c887c7625332c88f93c5729 Mon Sep 17 00:00:00 2001 From: Jae Hyun Yoo Date: Fri, 27 Mar 2020 14:42:05 -0700 Subject: [PATCH] Add chip unique id reading interface @@ -8,12 +8,13 @@ Optionally, the id can be encrypted using a dts-supplied hash data. Signed-off-by: Jae Hyun Yoo Signed-off-by: Vernon Mauery +Signed-off-by: Arun P. Mohanan --- drivers/soc/aspeed/aspeed-bmc-misc.c | 118 ++++++++++++++++++++++++--- 1 file changed, 105 insertions(+), 13 deletions(-) diff --git a/drivers/soc/aspeed/aspeed-bmc-misc.c b/drivers/soc/aspeed/aspeed-bmc-misc.c -index 04d97ab17274..c80b2e71f254 100644 +index 04d97ab17274..4aad3129f793 100644 --- a/drivers/soc/aspeed/aspeed-bmc-misc.c +++ b/drivers/soc/aspeed/aspeed-bmc-misc.c @@ -7,15 +7,18 @@ @@ -52,7 +53,7 @@ index 04d97ab17274..c80b2e71f254 100644 * label = "foo"; * } */ -@@ -48,9 +53,22 @@ static int aspeed_bmc_misc_parse_dt_child(struct device_node *child, +@@ -48,9 +53,21 @@ static int aspeed_bmc_misc_parse_dt_child(struct device_node *child, if (rc < 0) return rc; @@ -74,15 +75,13 @@ index 04d97ab17274..c80b2e71f254 100644 + if (rc < 0) + return rc; + } -+ ctrl->mask <<= ctrl->shift; rc = of_property_read_u32(child, "bit-shift", &ctrl->shift); if (rc < 0) -@@ -58,7 +76,9 @@ static int aspeed_bmc_misc_parse_dt_child(struct device_node *child, - +@@ -59,6 +76,9 @@ static int aspeed_bmc_misc_parse_dt_child(struct device_node *child, ctrl->read_only = of_property_read_bool(child, "read-only"); -- ctrl->mask <<= ctrl->shift; + ctrl->mask <<= ctrl->shift; + /* optional hash_data for obfuscating reads */ + if (of_property_read_string(child, "hash-data", &ctrl->hash_data)) + ctrl->hash_data = NULL; @@ -188,7 +187,7 @@ index 04d97ab17274..c80b2e71f254 100644 } static ssize_t aspeed_bmc_misc_store(struct kobject *kobj, -@@ -114,15 +206,15 @@ static ssize_t aspeed_bmc_misc_store(struct kobject *kobj, +@@ -114,17 +206,17 @@ static ssize_t aspeed_bmc_misc_store(struct kobject *kobj, long val; int rc; @@ -206,8 +205,11 @@ index 04d97ab17274..c80b2e71f254 100644 + return rc; + val <<= ctrl->shift; - rc = regmap_update_bits(ctrl->map, ctrl->offset, ctrl->mask, val); +- rc = regmap_update_bits(ctrl->map, ctrl->offset, ctrl->mask, val); ++ rc = regmap_write_bits(ctrl->map, ctrl->offset, ctrl->mask, val); + return rc < 0 ? rc : count; + } -- 2.17.1 diff --git a/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0105-i2c-aspeed-fix-arbitration-loss-handling-logic.patch b/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0105-i2c-aspeed-fix-arbitration-loss-handling-logic.patch new file mode 100644 index 000000000..f5c0a6ec8 --- /dev/null +++ b/meta-openbmc-mods/meta-common/recipes-kernel/linux/linux-aspeed/0105-i2c-aspeed-fix-arbitration-loss-handling-logic.patch @@ -0,0 +1,38 @@ +From 2cf0bee18a390a90cd1e5736ba79909a8feef94e Mon Sep 17 00:00:00 2001 +From: Jae Hyun Yoo +Date: Tue, 28 Apr 2020 12:08:14 -0700 +Subject: [PATCH] i2c: aspeed: fix arbitration loss handling logic + +When an arbitration loss happens in a multi-master bus, driver +drops the packet induce I2C subsystem to retry the transaction +by returning -EAGAIN. During this handling, tx_ack comes along +sometimes and it causes this this garbage printing +out: + +aspeed-i2c-bus 1e78a400.i2c-bus: irq handled != irq. expected 0x00000009, but was 0x00000008 + +To fix this issue, this commit adds the tx_ack flag clearing into +the arbitration loss handling logic. + +Signed-off-by: Jae Hyun Yoo +--- + drivers/i2c/busses/i2c-aspeed.c | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/drivers/i2c/busses/i2c-aspeed.c b/drivers/i2c/busses/i2c-aspeed.c +index b56e60508914..8625c0da440b 100644 +--- a/drivers/i2c/busses/i2c-aspeed.c ++++ b/drivers/i2c/busses/i2c-aspeed.c +@@ -896,6 +896,9 @@ static u32 aspeed_i2c_master_irq(struct aspeed_i2c_bus *bus, u32 irq_status) + if (bus->master_state != ASPEED_I2C_MASTER_INACTIVE) { + bus->cmd_err = ret; + bus->master_state = ASPEED_I2C_MASTER_INACTIVE; ++ if (ret == -EAGAIN) ++ irq_handled |= (irq_status & ++ ASPEED_I2CD_INTR_TX_ACK); + goto out_complete; + } + } +-- +2.7.4 + -- cgit v1.2.3