- mhw@mhw-VirtualBox:~/rk3399/kernel/drivers/pci$ tree endpoint/
- endpoint/
- ├── built-in.o
- ├── functions
- │ ├── built-in.o
- │ ├── Kconfig
- │ ├── Makefile
- │ ├── modules.builtin
- │ ├── modules.order
- │ ├── pci-epf-test.c
- │ └── pci-epf-test.o
- ├── Kconfig
- ├── Makefile
- ├── modules.builtin
- ├── modules.order
- ├── pci-epc-core.c
- ├── pci-epc-core.o
- ├── pci-ep-cfs.c
- ├── pci-ep-cfs.o
- ├── pci-epc-mem.c
- ├── pci-epc-mem.o
- ├── pci-epf-core.c
- └── pci-epf-core.o
- mhw@mhw-VirtualBox:~/rk3399/kernel/drivers/pci$ tree controller/
- controller/
- ├── built-in.o
- ├── Kconfig
- ├── Makefile
- ├── modules.builtin
- ├── modules.order
- ├── pcie-rockchip.c
- ├── pcie-rockchip-ep.c
- ├── pcie-rockchip-ep.o
- ├── pcie-rockchip.h
- ├── pcie-rockchip-host.c
- ├── pcie-rockchip-host.o
- ├── pcie-rockchip.o
- ├── pci-thunder-ecam.c
- ├── pci-thunder-pem.c
- └── pci-xgene.c
复制代码
- root@debian10:/home/toybrick# cd /sys/kernel/config/pci_ep/
- root@debian10:/sys/kernel/config/pci_ep# mkdir functions/pci_epf_test/func1
- root@debian10:/sys/kernel/config/pci_ep# ls functions/pci_epf_test/func1
- baseclass_code interrupt_pin progif_code subsys_id
- cache_line_size msi_interrupts revid subsys_vendor_id
- deviceid msix_interrupts subclass_code vendorid
- root@debian10:/sys/kernel/config/pci_ep# echo 0x104c > functions/pci_epf_test/func1/vendorid
- root@debian10:/sys/kernel/config/pci_ep# echo 0xb500 > functions/pci_epf_test/func1/deviceid
- root@debian10:/sys/kernel/config/pci_ep# ln -s functions/pci_epf_test/func1 controllers/fd000000.pcie-ep/
- [ 29.881158] [pci_epc_epf_link:97]mhwpcie start
- [ 29.884855] [rockchip_pcie_ep_set_bar:173]mhwpcie start!
- [ 29.885348] [rockchip_pcie_ep_set_bar:229]mhwpcie end!
- [ 29.885911] [rockchip_pcie_ep_set_bar:173]mhwpcie start!
- [ 29.886399] [rockchip_pcie_ep_set_bar:229]mhwpcie end!
- [ 29.886911] [rockchip_pcie_ep_set_bar:173]mhwpcie start!
- [ 29.887398] [rockchip_pcie_ep_set_bar:229]mhwpcie end!
- [ 29.887903] [rockchip_pcie_ep_set_bar:173]mhwpcie start!
- [ 29.888389] [rockchip_pcie_ep_set_bar:229]mhwpcie end!
- [ 29.888931] [rockchip_pcie_ep_set_bar:173]mhwpcie start!
- [ 29.889418] [rockchip_pcie_ep_set_bar:229]mhwpcie end!
- [ 29.889921] [rockchip_pcie_ep_set_bar:173]mhwpcie start!
- [ 29.890407] [rockchip_pcie_ep_set_bar:229]mhwpcie end!
- [ 29.890981] [pci_epc_epf_link:115]mhwpcie end
- root@debian10:/sys/kernel/config/pci_ep# echo 1 > controllers/fd000000.pcie-ep/start
- [ 29.893927] [rockchip_pcie_ep_start:502]mhwpcie start!
- [ 29.894399] [rockchip_pcie_ep_start:508]mhwpcie end!
复制代码
- [ 1.773968] nwl-pcie fd0e0000.pcie: Link is UP
- [ 1.777832] OF: PCI: host bridge /amba/pcie@fd0e0000 ranges:
- [ 1.783430] OF: PCI: MEM 0xe0000000..0xefffffff -> 0xe0000000
- [ 1.789303] OF: PCI: MEM 0x600000000..0x7ffffffff -> 0x600000000
- [ 1.795556] nwl-pcie fd0e0000.pcie: PCI host bridge to bus 0000:00
- [ 1.801582] pci_bus 0000:00: root bus resource [bus 00-ff]
- [ 1.807028] pci_bus 0000:00: root bus resource [mem 0xe0000000-0xefffffff]
- [ 1.813861] pci_bus 0000:00: root bus resource [mem 0x600000000-0x7ffffffff pref]
- [ 1.821331] pci 0000:00:00.0: ignoring class 0x068000 (doesn't match header type 01)
- [ 3.987047] Synchronous External Abort: synchronous external abort (0x96000210) at 0xffffff800b100000
- [ 3.990606] Internal error: : 96000210 [#1] SMP
- [ 3.995103] Modules linked in:
- [ 3.998133] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 4.14.0-xilinx-v2018.3 #10
- [ 4.005396] Hardware name: xlnx,zynqmp (DT)
- [ 4.009549] task: ffffffc87d858d00 task.stack: ffffff8008038000
- [ 4.015438] PC is at pci_generic_config_read+0x34/0xa8
- [ 4.020535] LR is at pci_generic_config_read+0x20/0xa8
- [ 4.025638] pc : [<ffffff800847f824>] lr : [<ffffff800847f810>] pstate: 200000c5
- [ 4.032989] sp : ffffff800803b990
- [ 4.036276] x29: ffffff800803b990 x28: ffffffc87ccaa000
- [ 4.041553] x27: 0000000000000001 x26: 0000000000000000
- [ 4.046829] x25: 000000000000000c x24: 0000000000000040
- [ 4.052106] x23: 0000000000000000 x22: ffffff800803ba8c
- [ 4.057383] x21: ffffff8008f02bc0 x20: ffffff800803b9fc
- [ 4.062659] x19: 0000000000000004 x18: 0000000000000000
- [ 4.067935] x17: 0000000000000001 x16: 0000000000000019
- [ 4.073212] x15: ffffffffffffffff x14: ffffffc87da8591c
- [ 4.078489] x13: ffffffc87da85198 x12: 0000000000000000
- [ 4.083765] x11: 0101010101010101 x10: 7f7f7f7f7f7f7f7f
- [ 4.089042] x9 : ffffff8008e0a000 x8 : ffffffc87d371e80
- [ 4.094318] x7 : 0000000000000000 x6 : 0000000000000001
- [ 4.099595] x5 : 0000000000000000 x4 : ffffffc87d254000
- [ 4.104871] x3 : ffffffc87ccaab98 x2 : 0000000000000000
- [ 4.110148] x1 : ffffff800b000000 x0 : ffffff800b100000
- [ 4.115426] Process swapper/0 (pid: 1, stack limit = 0xffffff8008038000)
- [ 4.122085] Call trace:
- [ 4.124509] Exception stack(0xffffff800803b850 to 0xffffff800803b990)
- [ 4.130910] b840: ffffff800b100000 ffffff800b000000
- [ 4.138696] b860: 0000000000000000 ffffffc87ccaab98 ffffffc87d254000 0000000000000000
- [ 4.146481] b880: 0000000000000001 0000000000000000 ffffffc87d371e80 ffffff8008e0a000
- [ 4.154266] b8a0: 7f7f7f7f7f7f7f7f 0101010101010101 0000000000000000 ffffffc87da85198
- [ 4.162051] b8c0: ffffffc87da8591c ffffffffffffffff 0000000000000019 0000000000000001
- [ 4.169836] b8e0: 0000000000000000 0000000000000004 ffffff800803b9fc ffffff8008f02bc0
- [ 4.177621] b900: ffffff800803ba8c 0000000000000000 0000000000000040 000000000000000c
- [ 4.185406] b920: 0000000000000000 0000000000000001 ffffffc87ccaa000 ffffff800803b990
- [ 4.193191] b940: ffffff800847f810 ffffff800803b990 ffffff800847f824 00000000200000c5
- [ 4.200976] b960: 0000000000000759 0000000000000000 ffffffffffffffff 0000000000000000
- [ 4.208760] b980: ffffff800803b990 ffffff800847f824
- [ 4.213607] [<ffffff800847f824>] pci_generic_config_read+0x34/0xa8
- [ 4.219747] [<ffffff800847f720>] pci_bus_read_config_dword+0x68/0xb8
- [ 4.226064] [<ffffff80084820b4>] pci_bus_read_dev_vendor_id+0x2c/0x1a0
- [ 4.232550] [<ffffff80084838a4>] pci_scan_single_device+0x54/0xe0
- [ 4.238605] [<ffffff800848395c>] pci_scan_slot+0x2c/0xf0
- [ 4.243881] [<ffffff80084849c8>] pci_scan_child_bus+0x30/0x118
- [ 4.249677] [<ffffff800848465c>] pci_scan_bridge+0x1e4/0x520
- [ 4.255300] [<ffffff8008484a24>] pci_scan_child_bus+0x8c/0x118
- [ 4.261095] [<ffffff8008484bec>] pci_scan_root_bus_bridge+0x54/0xd8
- [ 4.267323] [<ffffff800849baac>] nwl_pcie_probe+0x794/0xa18
- [ 4.272860] [<ffffff8008586368>] platform_drv_probe+0x58/0xb8
- [ 4.278569] [<ffffff800858474c>] driver_probe_device+0x22c/0x2d8
- [ 4.284537] [<ffffff80085848b4>] __driver_attach+0xbc/0xc0
- [ 4.289986] [<ffffff800858288c>] bus_for_each_dev+0x4c/0x98
- [ 4.295522] [<ffffff8008584048>] driver_attach+0x20/0x28
- [ 4.300799] [<ffffff8008583b98>] bus_add_driver+0x1b8/0x228
- [ 4.306334] [<ffffff8008585260>] driver_register+0x60/0xf8
- [ 4.311784] [<ffffff80085862b8>] __platform_driver_register+0x40/0x48
- [ 4.318188] [<ffffff8008dbf694>] nwl_pcie_driver_init+0x18/0x20
- [ 4.324068] [<ffffff8008083980>] do_one_initcall+0x38/0x128
- [ 4.329605] [<ffffff8008da0cc4>] kernel_init_freeable+0x138/0x1d8
- [ 4.335659] [<ffffff8008a5ce48>] kernel_init+0x10/0x100
- [ 4.340848] [<ffffff8008084a90>] ret_from_fork+0x10/0x18
- [ 4.346126] Code: 7100067f 54000140 71000a7f 54000200 (b9400001)
- [ 4.352181] ---[ end trace 10ac5e592c4ebb6e ]---
- [ 4.356774] nwl-pcie fd0e0000.pcie: Slave error
- [ 4.361290] Kernel panic - not syncing: Attempted to kill init! exitcode=0x0000000b
- [ 4.361290]
- [ 4.370344] SMP: stopping secondary CPUs
复制代码
欢迎光临 Toybrick (https://t.rock-chips.com/) | Powered by Discuz! X3.3 |