Attention is currently required from: Hung-Te Lin.
Hello Hung-Te Lin, build bot (Jenkins), Yu-Ping Wu,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/56793
to look at the new patch set (#8).
Change subject: soc/mediatek: Enable PCIe support for mt8195
......................................................................
soc/mediatek: Enable PCIe support for mt8195
Enable PCIe support for mt8195.
TEST=Build pass and boot up to kernel successfully via SSD on Cherry
board, here is the SSD information in boot log:
== NVME IDENTIFY CONTROLLER DATA ==
PCI VID : 0x1987
PCI SSVID : 0x1987
SN : 28F40713077B0012602
MN : Phison ESE1A043-X28
RAB : 0x1
AERL : 0x3
SQES : 0x66
CQES : 0x44
NN : 0x1
Identified NVMe model Phison ESE1A043-X28
BUG=b:178565024
Signed-off-by: Jianjun Wang <jianjun.wang(a)mediatek.com>
Change-Id: I314572955f1021abe9f2f0f4635670135ed08fff
---
M src/soc/mediatek/mt8195/Kconfig
M src/soc/mediatek/mt8195/Makefile.inc
M src/soc/mediatek/mt8195/soc.c
3 files changed, 10 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/93/56793/8
--
To view, visit https://review.coreboot.org/c/coreboot/+/56793
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I314572955f1021abe9f2f0f4635670135ed08fff
Gerrit-Change-Number: 56793
Gerrit-PatchSet: 8
Gerrit-Owner: Jianjun Wang <jianjun.wang(a)mediatek.corp-partner.google.com>
Gerrit-Reviewer: Hung-Te Lin <hungte(a)chromium.org>
Gerrit-Reviewer: Yu-Ping Wu <yupingso(a)google.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Paul Menzel <paulepanter(a)mailbox.org>
Gerrit-Attention: Hung-Te Lin <hungte(a)chromium.org>
Gerrit-MessageType: newpatchset
Attention is currently required from: Shelley Chen, Hung-Te Lin, Furquan Shaikh, Paul Menzel, Angel Pons, Yu-Ping Wu.
Hello Shelley Chen, Hung-Te Lin, build bot (Jenkins), Yu-Ping Wu,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/56791
to look at the new patch set (#8).
Change subject: soc/mediatek: Add PCIe support
......................................................................
soc/mediatek: Add PCIe support
Add PCIe support for MediaTek platform.
Reference:
- MT8195 Register Map V0.3-2, Chapter 3.18 PCIe controller (Page 1250)
- linux/drivers/pci/controller/pcie-mediatek-gen3.c
This code is based on MT8195 platform, but it should be common in each
platform with the same PCIe IP in the future.
TEST=Build pass and boot up to kernel successfully via SSD on Cherry
board, here is the SSD information in boot log:
== NVME IDENTIFY CONTROLLER DATA ==
PCI VID : 0x1987
PCI SSVID : 0x1987
SN : 28F40713077B0012602
MN : Phison ESE1A043-X28
RAB : 0x1
AERL : 0x3
SQES : 0x66
CQES : 0x44
NN : 0x1
Identified NVMe model Phison ESE1A043-X28
BUG=b:178565024
Signed-off-by: Jianjun Wang <jianjun.wang(a)mediatek.com>
Change-Id: Ib9b6adaafa20aeee136372ec9564273f86776da0
---
A src/soc/mediatek/common/include/soc/pcie_common.h
A src/soc/mediatek/common/pcie.c
2 files changed, 370 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/91/56791/8
--
To view, visit https://review.coreboot.org/c/coreboot/+/56791
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: Ib9b6adaafa20aeee136372ec9564273f86776da0
Gerrit-Change-Number: 56791
Gerrit-PatchSet: 8
Gerrit-Owner: Jianjun Wang <jianjun.wang(a)mediatek.corp-partner.google.com>
Gerrit-Reviewer: Hung-Te Lin <hungte(a)chromium.org>
Gerrit-Reviewer: Shelley Chen <shchen(a)google.com>
Gerrit-Reviewer: Yu-Ping Wu <yupingso(a)google.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-CC: Furquan Shaikh <furquan.m.shaikh(a)gmail.com>
Gerrit-CC: Paul Menzel <paulepanter(a)mailbox.org>
Gerrit-Attention: Shelley Chen <shchen(a)google.com>
Gerrit-Attention: Hung-Te Lin <hungte(a)chromium.org>
Gerrit-Attention: Furquan Shaikh <furquan.m.shaikh(a)gmail.com>
Gerrit-Attention: Paul Menzel <paulepanter(a)mailbox.org>
Gerrit-Attention: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Attention: Yu-Ping Wu <yupingso(a)google.com>
Gerrit-MessageType: newpatchset
Attention is currently required from: Tristan Corrick, Angel Pons, Patrick Rudolph.
Hello build bot (Jenkins), Tristan Corrick, Angel Pons, Patrick Rudolph,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/60549
to look at the new patch set (#3).
Change subject: src: Use 'stdint.h' when appropriate
......................................................................
src: Use 'stdint.h' when appropriate
Change-Id: I1df255d55b8f43a711d836c2565c367bd988098a
Signed-off-by: Elyes HAOUAS <ehaouas(a)noos.fr>
---
M src/mainboard/asrock/b85m_pro4/romstage.c
M src/mainboard/asrock/h81m-hds/romstage.c
M src/mainboard/google/beltino/romstage.c
M src/mainboard/hp/folio_9480m/romstage.c
M src/mainboard/intel/baskingridge/romstage.c
M src/mainboard/msi/h81m-p33/romstage.c
M src/mainboard/supermicro/x10slm-f/romstage.c
M src/northbridge/intel/gm45/early_init.c
M src/soc/intel/baytrail/include/soc/modphy_table.h
M src/soc/intel/baytrail/modphy_table.c
M src/southbridge/intel/i82801gx/early_init.c
11 files changed, 2 insertions(+), 10 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/49/60549/3
--
To view, visit https://review.coreboot.org/c/coreboot/+/60549
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I1df255d55b8f43a711d836c2565c367bd988098a
Gerrit-Change-Number: 60549
Gerrit-PatchSet: 3
Gerrit-Owner: HAOUAS Elyes <ehaouas(a)noos.fr>
Gerrit-Reviewer: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Reviewer: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-Reviewer: Tristan Corrick <tristan(a)corrick.kiwi>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Attention: Tristan Corrick <tristan(a)corrick.kiwi>
Gerrit-Attention: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Attention: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-MessageType: newpatchset
Attention is currently required from: Shelley Chen, Hung-Te Lin, Furquan Shaikh, Paul Menzel, Angel Pons, Yu-Ping Wu.
Jianjun Wang has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/56791 )
Change subject: soc/mediatek: Add PCIe support
......................................................................
Patch Set 7:
(11 comments)
Commit Message:
https://review.coreboot.org/c/coreboot/+/56791/comment/8f905163_abd95494
PS6, Line 18: SSD
> Which one exactly? On what board? […]
Sorry for the late response, updated the board info and boot log, thanks.
File src/soc/mediatek/common/pcie.c:
https://review.coreboot.org/c/coreboot/+/56791/comment/76b7937a_e1d8fde9
PS2, Line 329: mtk_pcie_gen3_probe
> Hi Jianjun, thanks for putting this together. […]
Sorry for the late response, the device_operations has been used by soc_ops, can we still add this pci_domain_ops?
File src/soc/mediatek/common/pcie.c:
https://review.coreboot.org/c/coreboot/+/56791/comment/3533ed27_744e1727
PS6, Line 106: setctions
> sections
Done
https://review.coreboot.org/c/coreboot/+/56791/comment/26c4f50c_53d5057f
PS6, Line 111: mdelay(100);
> One way to avoid this delay would be to assert PERST# earlier, and do something else in the meantime […]
Yes, it's truly a long time, but it defined by PCIe spec, remove it directly will cause some compatibility issues, we can make this driver as user configurable first, and try to found a way to assert PERST# earlier, thanks.
https://review.coreboot.org/c/coreboot/+/56791/comment/2f809e0c_e56fb118
PS6, Line 122: __func__, val);
> Error messages should be user understandable. Please elaborate, and also document the effects.
Done
https://review.coreboot.org/c/coreboot/+/56791/comment/6f02e355_146fbbbc
PS6, Line 159: res->cpu_addr | PCIE_ATR_SIZE(fls(res->size)));
> Should fit in one line.
Done
https://review.coreboot.org/c/coreboot/+/56791/comment/27fbc25e_47778c52
PS6, Line 174: static int mtk_pcie_dev_assign_resource(struct device *dev,
> Please excuse my ignorance, but what is special for assigning resources on MediaTek, that no common […]
Thanks for your review, the PCIe module in arm platform seems different from the X86 platform, we have a 64MBytes MMIO space starting from 0x2000_0000, but I can't found any common function that can assign this start address to the PCIe resources(e.g. BAR, Bridge window), so I add these functions for:
1. Use mtk_pcie_dev_assign_resource to maintain the usage of the MMIO space;
2. Use mtk_pcie_bridge_assign_resources to update the resource base/size information of the bridge, let the config space of the root port can get the correct memory/io base/limit.
https://review.coreboot.org/c/coreboot/+/56791/comment/03a2f7c2_23b15681
PS6, Line 180: printk(BIOS_INFO, "res->index = %#lx\n", res->index);
> Looks more like debugging or spew?
Done
https://review.coreboot.org/c/coreboot/+/56791/comment/27631b49_10378538
PS6, Line 194: __func__, ctrl->mmio_io_size);
> Plesae add the values to error message. […]
Done
https://review.coreboot.org/c/coreboot/+/56791/comment/26abe9ac_3d0742e8
PS6, Line 285: ret = mtk_pcie_startup_port(ctrl);
: if (ret)
: return;
> Rewrite as […]
Done
https://review.coreboot.org/c/coreboot/+/56791/comment/b0cb8a91_540d2458
PS6, Line 289: printk(BIOS_INFO, "%s: Try to probe PCIe bus\n", __func__);
> 1. Trying … […]
This messages seems redundant, it has been removed, thanks.
--
To view, visit https://review.coreboot.org/c/coreboot/+/56791
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: Ib9b6adaafa20aeee136372ec9564273f86776da0
Gerrit-Change-Number: 56791
Gerrit-PatchSet: 7
Gerrit-Owner: Jianjun Wang <jianjun.wang(a)mediatek.corp-partner.google.com>
Gerrit-Reviewer: Hung-Te Lin <hungte(a)chromium.org>
Gerrit-Reviewer: Shelley Chen <shchen(a)google.com>
Gerrit-Reviewer: Yu-Ping Wu <yupingso(a)google.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-CC: Furquan Shaikh <furquan.m.shaikh(a)gmail.com>
Gerrit-CC: Paul Menzel <paulepanter(a)mailbox.org>
Gerrit-Attention: Shelley Chen <shchen(a)google.com>
Gerrit-Attention: Hung-Te Lin <hungte(a)chromium.org>
Gerrit-Attention: Furquan Shaikh <furquan.m.shaikh(a)gmail.com>
Gerrit-Attention: Paul Menzel <paulepanter(a)mailbox.org>
Gerrit-Attention: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Attention: Yu-Ping Wu <yupingso(a)google.com>
Gerrit-Comment-Date: Fri, 31 Dec 2021 07:47:11 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Shelley Chen <shchen(a)google.com>
Comment-In-Reply-To: Furquan Shaikh <furquan.m.shaikh(a)gmail.com>
Comment-In-Reply-To: Paul Menzel <paulepanter(a)mailbox.org>
Comment-In-Reply-To: Angel Pons <th3fanbus(a)gmail.com>
Comment-In-Reply-To: Yu-Ping Wu <yupingso(a)google.com>
Comment-In-Reply-To: Jianjun Wang <jianjun.wang(a)mediatek.corp-partner.google.com>
Gerrit-MessageType: comment