
本帖最后由 stone-363407 于 2018-12-7 16:42 编辑 6 o7 Q0 O% U4 {1 u/ P/ k6 ] 代码地址: http://github.com/huayuguo/uboot-stm32h743_eth- J: j# d3 D. x- A; T2 H2 w U-Boot 2018.09-rc2-gc16d658 (Dec 06 2018 - 16:00:30 +0800)6 ?! N" P7 ^' n0 E# C( Q- | : S0 E" Q6 I( t/ h8 e4 U% ^# J Model: STMicroelectronics STM32H743i-EVAL board. k; y6 N7 d( w' K# ] DRAM: 32 MiB MMC: STM32 SDMMC2: 0 In: serial@40011000 Out: serial@400110001 r ^" ]: Z7 @ T! }! p Err: serial@40011000 Net: Warning: ethernet@40028000 (eth0) using random MAC address - fe:f8:94:5f:5e:26 eth0: ethernet@400280000 |. n& w( d& \6 t" B# _ Hit SPACE in 3 seconds to stop autoboot. switch to partitions #0, OK u0 U/ Z/ ^$ O* [# F% |8 T mmc0 is current device Scanning mmc 0:1...8 V1 Q O0 |7 e @8 k U-Boot > setenv gatewayip 192.168.10.1;setenv ipaddr 192.168.10.22;setenv netmask 255.255.255.0;setenv ethaddr 1a:5a:38:ef:38:d8; U-Boot > env set bootargs "root=/dev/ram console=ttyS0,115200 " . S. z* l5 W' A$ R* E U-Boot > tftpboot 61000000 192.168.10.25:uImage;tftpboot 61300000 192.168.10.25:stm32h743i-eval.dtb; 4 R+ x* d0 @; n N ethernet@40028000 Waiting for PHY auto negotiation to complete. done Using ethernet@40028000 device TFTP from server 192.168.10.25; our IP address is 192.168.10.22* C8 H; h {' A' k7 v. ~( \ Filename 'uImage'.6 x" @3 b: J: D" b/ q Load address: 0x61000000. T" L5 g# k1 y: p Loading: #################################################################' U, F: z, u# a4 \ #################################################################7 n& r( a$ {! E; R- k ########## 1.4 MiB/s done1 G" s, }2 g# W( b Bytes transferred = 2048568 (1f4238 hex) ethernet@40028000 Waiting for PHY auto negotiation to complete. done Using ethernet@40028000 device TFTP from server 192.168.10.25; our IP address is 192.168.10.22 Filename 'stm32h743i-eval.dtb'. Load address: 0x61300000 Loading: #+ C/ E3 h6 m M- H& ]5 ?6 ^5 Y* l 999 KiB/s. [5 ?3 c8 i* m$ i2 |& X done Bytes transferred = 5115 (13fb hex) U-Boot > bootm 61000000 - 61300000 a6 M2 B& v2 X" |: T3 { ## Booting kernel from Legacy Image at 61000000 ..., }* N4 u, T6 g& a Image Name: linux Image Type: ARM Linux Kernel Image (uncompressed)- ?* t4 a4 x6 E; u Data Size: 2048504 Bytes = 2 MiB; ]3 K# E& L1 [$ w9 X' T Load Address: 61000000 Entry Point: 61000000' ~1 w9 a* X3 `& x c Verifying Checksum ... OK& i8 `4 m9 C# ^" Y9 x0 n ## Flattened Device Tree blob at 61300000 Booting using the fdt blob at 0x61300000: ?; G$ X: y0 C* U6 b- j$ M! U Loading Kernel Image ... OK Using Device Tree in place at 61300000, end 613043fa / G/ C/ F- b4 u% k8 q; A Starting kernel ... * B6 Y6 p, V1 u) i0 b' B. o1 L) J 1 D% O; A3 v& [ [ 0.000000] Booting Linux on physical CPU 0x0 [ 0.000000] Linux version 4.15.2-gb37c1e299-dirty (xiao@xd) (gcc version 6.3.1 20170620 (15:6.3.1+svn253039-1build1)) #134 PREEMPT Fri Dec 7 13:45:02 CST 2018( ]) c- W( ^& P# m% M4 C [ 0.000000] CPU: ARMv7-M [411fc271] revision 1 (ARMv7M), cr=00000000 [ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, PIPT instruction cache4 O. ^# W& x% t4 {: M p$ v [ 0.000000] OF: fdt: Machine model: STMicroelectronics STM32H743i-EVAL board+ O1 m2 y f5 V$ U [ 0.000000] Reserved memory: created DMA memory pool at 0x61000000, size 2 MiB! L. L% t1 _; q [ 0.000000] OF: reserved mem: initialized node linux,dma, compatible id shared-dma-pool [ 0.000000] Ignoring RAM after 0x61000000, memory at 0x61200000 ignored4 w3 I& p3 \- G& u [ 0.000000] Using ARMv7 PMSA Compliant MPU. Region independence: No, Used 2 of 16 regions0 W* F9 A4 W; U' [$ y# Z [ 0.000000] On node 0 totalpages: 4096. D* S( Y+ O8 \. N" U/ C [ 0.000000] Normal zone: 32 pages used for memmap [ 0.000000] Normal zone: 0 pages reserved- F6 A5 }6 D* y* y6 R7 C [ 0.000000] Normal zone: 4096 pages, LIFO batch:0 [ 0.000000] pcpu-alloc: s0 r0 d32768 u32768 alloc=1*32768! S+ N9 Z3 G) q+ l0 S [ 0.000000] pcpu-alloc: [0] 0 " ?3 S- Z- l2 _) U" I) G [ 0.000000] Built 1 zonelists, mobility grouping off. Total pages: 4064- q$ Q! ]; h' B) T8 t [ 0.000000] Kernel command line: root=/dev/ram console=ttyS0,115200 [ 0.000000] Dentry cache hash table entries: 2048 (order: 1, 8192 bytes)" F" \; t2 S7 ?6 `3 P* h4 o4 I [ 0.000000] Inode-cache hash table entries: 1024 (order: 0, 4096 bytes) z: l) Y2 f( H6 H$ `$ ?: K$ D3 D [ 0.000000] Memory: 13080K/16384K available (1596K kernel code, 154K rwdata, 496K rodata, 632K init, 130K bss, 3304K reserved, 0K cma-reserved) [ 0.000000] Virtual kernel memory layout: [ 0.000000] vector : 0x00000000 - 0x00001000 ( 4 kB)/ a# Y3 V9 l; I2 ~) J1 \5 v& A! N [ 0.000000] fixmap : 0xffc00000 - 0xfff00000 (3072 kB)$ z0 t& u+ B% V3 k/ ]$ K [ 0.000000] vmalloc : 0x00000000 - 0xffffffff (4095 MB)9 z0 F% d+ I! P' U [ 0.000000] lowmem : 0x60000000 - 0x61000000 ( 16 MB)) u5 b+ [8 e# p) o9 ~% y [ 0.000000] .text : 0x(ptrval) - 0x(ptrval) (1597 kB) [ 0.000000] .init : 0x(ptrval) - 0x(ptrval) ( 632 kB) [ 0.000000] .data : 0x(ptrval) - 0x(ptrval) ( 155 kB) [ 0.000000] .bss : 0x(ptrval) - 0x(ptrval) ( 131 kB)' u; j0 e/ ^4 M$ X1 k J9 R [ 0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1: \# M) D$ C+ M9 F [ 0.000000] Preemptible hierarchical RCU implementation.! R7 j8 p/ ] s [ 0.000000] Tasks RCU enabled.( Y' l+ V6 k) x" |# L" Q6 R [ 0.000000] NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16; `' L _' q, A [ 0.000000] clocksource: arm_system_timer: mask: 0xffffff max_cycles: 0xffffff, max_idle_ns: 18664651 ns [ 0.000000] ARM System timer initialized as clocksource4 ~# u6 ^0 b! {; t4 y$ b" J* c [ 0.000000] /soc/timer@40000c00: STM32 clockevent driver initialized (32 bits)# c0 Z! _4 O: w- u [ 0.000000] sched_clock: 32 bits at 100 Hz, resolution 10000000ns, wraps every 21474836475000000ns [ 0.010000] Calibrating delay loop... 795.44 BogoMIPS (lpj=3977216)) F: U. S" ]3 x) W2 Y: H [ 0.100000] pid_max: default: 4096 minimum: 301 [ 0.100000] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes) [ 0.100000] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes) [ 0.100000] Hierarchical SRCU implementation. [ 0.100000] devtmpfs: initialized [ 0.110000] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns8 R0 J. k+ r" G" D m- M [ 0.110000] pinctrl core: initialized pinctrl subsystem" d. {5 Y( n' ] [ 0.110000] DMA: default coherent area is set [ 0.110000] random: get_random_u32 called from bucket_table_alloc+0xc9/0xf4 with crng_init=0, t" g* ?5 J- \( g [ 0.110000] NET: Registered protocol family 167 L/ ]- y4 |0 M [ 0.120000] cpuidle: using governor ladder [ 0.120000] cpuidle: using governor menu, h6 M( u% B0 P [ 0.130000] stm32h743-pinctrl soc:pin-controller: GPIOA bank added0 G. K3 N' U* t. O [ 0.130000] stm32h743-pinctrl soc:pin-controller: GPIOB bank added8 {; V' u$ v) _$ |# ? [ 0.130000] stm32h743-pinctrl soc:pin-controller: GPIOC bank added [ 0.130000] stm32h743-pinctrl soc:pin-controller: GPIOD bank added [ 0.130000] stm32h743-pinctrl soc:pin-controller: GPIOE bank added [ 0.130000] stm32h743-pinctrl soc:pin-controller: GPIOF bank added [ 0.140000] stm32h743-pinctrl soc:pin-controller: GPIOG bank added [ 0.140000] stm32h743-pinctrl soc:pin-controller: GPIOH bank added [ 0.140000] stm32h743-pinctrl soc:pin-controller: GPIOI bank added [ 0.140000] stm32h743-pinctrl soc:pin-controller: GPIOJ bank added [ 0.140000] stm32h743-pinctrl soc:pin-controller: GPIOK bank added! |3 `2 W# C0 o: c [ 0.140000] stm32h743-pinctrl soc:pin-controller: Pinctrl STM32 initialized& ?- e( t5 d9 x% v! i9 q [ 0.160000] pps_core: LinuxPPS API ver. 1 registered; \3 M0 _# i6 ~8 p [ 0.160000] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it> [ 0.160000] PTP clock support registered2 [( H v% S/ u [ 0.160000] clocksource: Switched to clocksource arm_system_timer+ e5 Z8 i; u. Y [ 0.170000] NET: Registered protocol family 2 [ 0.170000] TCP established hash table entries: 1024 (order: 0, 4096 bytes)) u1 O; W0 W6 E: l [ 0.170000] TCP bind hash table entries: 1024 (order: 0, 4096 bytes)- y Z6 w! g2 i+ a$ v o8 L [ 0.170000] TCP: Hash tables configured (established 1024 bind 1024)2 w" p" L& N0 z" W% G( T [ 0.170000] UDP hash table entries: 256 (order: 0, 4096 bytes)2 }( n% A: R i, \ [ 0.170000] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)5 ?8 f p3 p: @9 W) F( Z [ 0.170000] NET: Registered protocol family 1 [ 0.360000] workingset: timestamp_bits=30 max_order=12 bucket_order=0" t: |3 X. N' n( L [ 0.380000] random: fast init done3 z; N B U' x" o. S [ 0.400000] io scheduler noop registered9 G( ?3 d: {) T' N4 b' s4 ] [ 0.400000] io scheduler deadline registered [ 0.400000] io scheduler cfq registered (default) [ 0.400000] io scheduler mq-deadline registered- j2 f3 K: K$ d6 R/ n1 p/ u% D: d [ 0.400000] io scheduler kyber registered [ 0.400000] STM32 USART driver initialized9 f: f" H6 t2 x2 l [ 0.400000] 40011000.serial: ttyS0 at MMIO 0x40011000 (irq = 17, base_baud = 12500000) is a stm32-usart$ P( U! r. o& j; R [ 0.850000] console [ttyS0] enabled [ 0.850000] stm32-usart 40011000.serial: rx dma alloc failed [ 0.860000] stm32-usart 40011000.serial: interrupt mode used for rx (no dma)/ k) @2 U K0 X0 E [ 0.870000] stm32-usart 40011000.serial: tx dma alloc failed [ 0.870000] stm32-usart 40011000.serial: interrupt mode used for tx (no dma)* ~4 V# W S5 m6 L. D) b [ 0.880000] libphy: Fixed MDIO Bus: probed [ 0.890000] tun: Universal TUN/TAP device driver, 1.64 y( V* y' \, K, f& Z; s3 d0 d [ 0.890000] stm32-dwmac 40028000.ethernet: Found phy-handle subnode [ 0.900000] stm32-dwmac 40028000.ethernet: Found MDIO subnode9 q) j' H/ g" D. ] [ 0.910000] stm32-dwmac 40028000.ethernet: use snps,dwmac-4.00..: z* Y" t" a Z1 Q2 [ [ 0.910000] stm32-dwmac 40028000.ethernet: PTP uses main clock [ 0.910000] stm32-dwmac 40028000.ethernet: no reset control found4 [7 I" f+ k* Z' s [ 0.930000] stmmac - user ID: 0x30, Synopsys ID: 0x41! X' |+ w, H; m* T# M5 W [ 0.930000] stm32-dwmac 40028000.ethernet: DMA HW capability register supported" a& B0 R8 s- S- y7 ^7 R% R; e [ 0.930000] stm32-dwmac 40028000.ethernet: RX Checksum Offload Engine supported: ~4 o: T5 J6 E: m [ 0.950000] stm32-dwmac 40028000.ethernet: TX Checksum insertion supported [ 0.950000] stm32-dwmac 40028000.ethernet: Wake-Up On Lan supported [ 0.950000] stm32-dwmac 40028000.ethernet: TSO supported [ 0.970000] stm32-dwmac 40028000.ethernet: Enable RX Mitigation via HW Watchdog Timer [ 0.970000] stmmac_mdio_reset : reset gpio direction num=28 [ 1.080000] libphy: stmmac: probed [ 1.090000] stm32-dwmac 40028000.ethernet: register the MDIO bus [ 1.100000] u32 classifier+ g8 m- f( j( Z# b% n: @ [ 1.100000] Initializing XFRM netlink socket [ 1.110000] NET: Registered protocol family 17 [ 1.110000] NET: Registered protocol family 15 [ 1.110000] 8021q: 802.1Q VLAN Support v1.8% m9 v+ j. {4 A: D# B: L [ 1.120000] Key type dns_resolver registered+ I3 [( M0 [0 E [ 1.130000] Freeing unused kernel memory: 632K+ k. l. H( Z. |2 e* k& d. v" _ [ 1.140000] This architecture does not have kernel memory protection. can't run '/sbin/swapon': No such file or directory Initializing random number generator... done.% c# _4 t6 f$ E( H4 e Jan 1 00:00:01 login[59]: root login on 'console'9 y& c1 n! T( |% ]6 O5 S# Q ~ # |
cpu 400Mhz sdram 100mhz cas=2
测试软件:iperf3
系统跑了25个线程测试速度如下。。。。没有原子裸奔的那个快............
65.8 Mbits/sec2 ?, y& E; r+ ]. K/ B. F" a- p$ \
~ # cat /proc/cpuinfo
processor : 09 a/ F! M2 V7 O, Q/ w- b5 P3 H! o! T
model name : ARMv7-M rev 1 (v7ml)5 g/ Q4 }4 w% S) \9 X( H
BogoMIPS : 795.44
Features : half thumb fastmult edsp idivt
CPU implementer : 0x41# z( W2 \$ B S% ~& j. P8 b
CPU architecture: 7M
CPU variant : 0x1 m5 S* T, H( ]
CPU part : 0xc27
CPU revision : 1' r/ U h9 E; q T7 {( C
$ y1 I: Y5 ~- i
Hardware : STM32 (Device Tree Support)
Revision : 00002 n4 b) p2 l! A2 d2 L* J6 N
Serial : 0000000000000000
~ # iperf3 -c 192.168.10.26 3 I8 G; t- d9 p) L* J. ~
Connecting to host 192.168.10.26, port 5201
[ 4] local 192.168.10.22 port 41328 connected to 192.168.10.26 port 5201
[ ID] Interval Transfer Bandwidth Retr Cwnd' q- J& W7 e7 L. H6 H7 }
[ 4] 0.00-1.01 sec 7.57 MBytes 63.0 Mbits/sec 0 173 KBytes
[ 4] 1.01-2.03 sec 8.22 MBytes 67.3 Mbits/sec 0 181 KBytes * G6 p9 A% A. |2 F
[ 4] 2.03-3.15 sec 8.75 MBytes 66.0 Mbits/sec 0 181 KBytes
[ 4] 3.15-4.04 sec 6.90 MBytes 65.0 Mbits/sec 0 181 KBytes # N6 i y9 x/ \/ H- ~' {9 o
[ 4] 4.04-5.15 sec 8.70 MBytes 65.4 Mbits/sec 0 181 KBytes 5 E5 S; N, U7 O- f3 e
[ 4] 5.15-6.10 sec 7.40 MBytes 65.5 Mbits/sec 0 181 KBytes # b6 l" k& x4 B1 e9 B
[ 4] 6.10-7.01 sec 7.37 MBytes 67.7 Mbits/sec 0 191 KBytes 0 I8 |7 E: q1 \: g
[ 4] 7.01-8.16 sec 8.95 MBytes 65.6 Mbits/sec 0 191 KBytes " J6 n, ?& k2 L0 U$ S
[ 4] 8.16-9.02 sec 6.86 MBytes 66.5 Mbits/sec 0 191 KBytes
[ 4] 9.02-10.13 sec 8.73 MBytes 65.9 Mbits/sec 0 191 KBytes * \5 h; j3 `3 E+ G* I- |
- - - - - - - - - - - - - - - - - - - - - - - - -* a9 y7 B" r# k+ W5 T* ]: }
[ ID] Interval Transfer Bandwidth Retr
[ 4] 0.00-10.13 sec 79.4 MBytes 65.8 Mbits/sec 0 sender
[ 4] 0.00-10.13 sec 79.4 MBytes 65.8 Mbits/sec receiver- W/ B; L l% x7 F/ U& \, z
iperf Done.
~ # ps
PID USER VSZ STAT COMMAND; L3 c# k P A9 x0 j
1 root 400 S init
2 root 0 SW [kthreadd]
4 root 0 IW< [kworker/0:0H]( z1 _5 O% X# s% e9 A: `) ^6 g
6 root 0 IW< [mm_percpu_wq]
7 root 0 SW [ksoftirqd/0]
8 root 0 IW [rcu_preempt]
9 root 0 IW [rcu_sched]$ y' `! g) ?8 B- z8 i' U* W. Q
10 root 0 IW [rcu_bh]
11 root 0 SW [kdevtmpfs]) U2 U$ t1 s; o# t' I2 O
12 root 0 SW [rcu_tasks_kthre]& L0 y3 P G1 I: w+ M; u {# b
14 root 0 IW< [writeback]3 \; Z+ ^' i" c, O( l) c
15 root 0 IW< [crypto]
16 root 0 IW< [kblockd]
17 root 0 IW< [watchdogd]
18 root 0 SW [kswapd0]
41 root 0 SW [irq/17-40011000]% `& F$ M. p' k6 g8 K
59 root 420 S -sh
60 root 0 IW [kworker/u2:1]
61 root 0 IW [kworker/u2:2]
64 root 0 IW [kworker/0:2]
65 root 0 IW [kworker/0:3]$ J0 F' V6 w; A2 k
71 root 0 IW [kworker/0:0]6 l4 k8 J% U( Q" c2 {' M( Q
75 root 396 R ps
楼主,您好,看了您的贴子,手头正好有一块stm32f746-disco 的板子,按照您的思路,移植了uboot2016.09,移植了uboot eth驱动,因为没有移植MMC驱动,就打算把linux内核加载在SDRAM上,再从SDRAM启动内核;使用的是linux4.19.24默认的stm32配置,但是现在一直卡在“Starting kernel ...”,内核应该是没有起来;不知道您调试过程中是否遇到这个问题。附上打印的信息:1 D8 L; L- d* Z2 L% m* \
U-Boot 2016.09-g83ec55b-dirty (Feb 22 2019 - 18:30:58 +0800)4 H* j5 Z* X' D: E0 ^( G Q
DRAM: 8 MiB: V% D$ R! Q! K7 Q! f, N0 I
WARNING: Caches not enabled! ~: u" }9 V m! J* v5 m3 l( @
Flash: 1 MiB) j' c$ y; Y$ ]# L7 p
Using default environment
9 _. Z6 C+ S+ Y% o; v4 _% ]( B2 S# ]
In: serial_stm32x7
Out: serial_stm32x7
Err: serial_stm32x7
Net:
stm32 eth probe start' C! u8 l+ f) D9 Q
stm32 eth probe end2 ^: z9 r0 g- \2 q
stm32_read_rom_hwaddr! t+ V7 G+ G$ v6 r
}8 D0 p% j2 n [! @
Warning: eth_stm32_eth using MAC address from ROM8 M& Z, {* r( ]4 T( r' @, ?4 `; i& [
eth0: eth_stm32_eth
stm32_write_hwaddr
9 x3 [' V0 k9 F" w8 b
Hit SPACE in 3 seconds to stop autoboot.9 s& U" j( C3 j |3 P/ L
U-Boot > set ipaddr 10.0.0.2' K! ~& a* ^; m- G% f" B/ O
U-Boot > set serverip 10.0.0.6
U-Boot > tftp c0400000 uImage.bin
) X7 @0 E7 _9 Y
stm32_eth_stop start
stm32_eth_stop end
5 K: H: h1 Z! J6 }' Z5 D! @" [
stm32_eth_start start& z7 X$ S' i! l* m( l: L- m
stm32_eth_start end
Using eth_stm32_eth device& U3 M7 d! q/ s2 k
TFTP from server 10.0.0.6; our IP address is 10.0.0.2
Filename 'uImage.bin'., V5 d7 W/ E1 o( s) `5 p
Load address: 0xc0400000
Loading: #################################################################
###########################
2 MiB/s
done+ H- S7 C( i/ P3 |% u# u; ^' e. d6 _
Bytes transferred = 1337888 (146a20 hex)
$ M8 ^" ?6 V$ u" o
stm32_eth_stop start$ q8 P# H5 k2 B' ]) u. N
stm32_eth_stop end
U-Boot > tftp c0600000 discodtb.bin
w; y% R' {4 t
stm32_eth_stop start2 h- h! w9 B- q: d$ q3 o5 b# }
stm32_eth_stop end
stm32_eth_start start
stm32_eth_start end8 |& f/ p8 D1 T( m7 h
Using eth_stm32_eth device
TFTP from server 10.0.0.6; our IP address is 10.0.0.2
Filename 'discodtb.bin'.4 G+ P O9 k$ A: n% F
Load address: 0xc0600000; T( S( G2 H7 U8 M4 ]
Loading: ##
966.8 KiB/s
done
Bytes transferred = 14858 (3a0a hex)) P( r+ L* l; Z1 J
" y/ {# T3 [2 ^7 t5 b- ]
stm32_eth_stop start
stm32_eth_stop end+ O$ |0 P# i$ p
U-Boot > bootm c0400000 - c06000009 }+ r% b$ ~3 U6 {
## Booting kernel from Legacy Image at c0400000 ...- t. H8 W ^) {6 c9 a) ]) }+ N
Image Name: Linux-4.19.24% y$ e1 v; d% `
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 1337824 Bytes = 1.3 MiB
Load Address: c00080000 j9 H! j- f* A: Q
Entry Point: c00080002 A9 T- L& \; T% ?2 P
Verifying Checksum ... OK* }. T( Z1 N3 W. J; V7 g, f4 E. H
## Flattened Device Tree blob at c0600000
Booting using the fdt blob at 0xc0600000
Loading Kernel Image ... OK
Loading Device Tree to c07c7000, end c07cda09 ... OK
6 I% y" J. q- z! H; Y3 I. u
Starting kernel ...
U-Boot 2018.09-rc2-g36b739b (Nov 25 2018 - 10:45:48 +0800): A2 X) i5 i+ \, p! n8 O* i
Model: STMicroelectronics STM32H743i-EVAL board$ |' u# v0 G6 A
DRAM: 32 MiB
MMC: STM32 SDMMC2: 0
In: serial@40011000
Out: serial@40011000
Err: serial@40011000
Net:
Warning: ethernet@40028000 (eth0) using random MAC address - b6:1d:0e:15:99:e3% O1 z& b- J5 V( v! O5 M+ [: k: h
eth0: ethernet@40028000
Hit SPACE in 3 seconds to stop autoboot.
Card did not respond to voltage select!% P9 \) Z5 Y3 K4 o
U-Boot > tftpboot 0x60001000 192.168.1.103:u-boot.bin . p( L2 O" S$ I6 t2 S
ethernet@40028000 Waiting for PHY auto negotiation to complete... done! @+ S4 |. A' h- [
*** ERROR: `ipaddr' not set
U-Boot > set ipaddr 192.168.1.101;set serverip 192.168.1.1;set ethaddr d6:54:97:9f:9a:90;
U-Boot > tftpboot 0x60001000 192.168.1.103:u-boot.bin * A8 Z) K' _# Q7 M
ethernet@40028000 Waiting for PHY auto negotiation to complete... done) @: O1 m* S# @/ ^) F+ H+ X
Using ethernet@40028000 device8 q! _% D( p# h( I3 o% V* m k; D
TFTP from server 192.168.1.103; our IP address is 192.168.1.101
Filename 'u-boot.bin'.( G# T1 |% b. S5 h
Load address: 0x60001000* J& l) P7 ^* p; \ D
Loading: ##################
1.8 MiB/s3 Y3 b/ T4 J" E' R. x$ S6 w7 X
done0 h( }- T, I$ Y) i3 y. p
Bytes transferred = 257336 (3ed38 hex)
U-Boot > cmp.b 60001000 8000000 3ed38 / B9 Q5 A! F, c) P0 v$ J
Total of 257336 byte(s) were the same
接下来看看kernel 咋能。
说下eth dma 最大的注意事项,就是cache dma ram 一致性, 卡了好个晚上,对于这个一致性,没有多少经验,希望大家给点经验指导下。
5 ]$ d" |( @- ?/ i- o
switch to partitions #0, OK, x- e8 l/ G# Y9 a
mmc0 is current device# r6 f& ?9 L' V5 a
Scanning mmc 0:1... I5 _; O0 W' \: f0 X9 ^& {
U-Boot > fatload mmc 0 60008000 uImage;fatload mmc 0 60800000 stm32h743i-eval.dtb
1926672 bytes read in 19 ms (96.7 MiB/s)8 N& D9 c& n8 m* C) P. j
9370 bytes read in 2 ms (4.5 MiB/s)/ z" j* l: L7 a2 F5 h
U-Boot >
请查看串口定义部分 高版本内核串口的定义不一样 ttys0 具体看下驱动代码
看下这个如果你用的内核版本是这样4 C2 C( o* H. x8 w
git\linux-4.19.9\drivers\tty\serial\stm32-usart.h) a' p: V: G% u6 E: G
9 G A6 M: u/ v8 x9 Z, M9 h" a
#define _SERIAL_NAME "ttySTM"9 I( m2 I/ q, e; ]& k8 M
把这个 U-Boot > env set bootargs "root=/dev/ram console=ttyS0,115200 "
: V( X: a2 v' o: ?+ o
改成这个
env set bootargs "root=/dev/ram console=ttySTM,115200 "
y+ g6 }9 g/ m9 u' l. X0 ~
6 o. ]$ W& m |: |2 p* B* ^
: q" R$ O$ Y2 m7 s1 K- ]
这个STM工程师比较那个,我也被坑了,各种分析,内存BUFF分析 等等 我就像骂一句 mmp
谢楼主啊
楼主您好,linux内核确实是你说的那样,但是改了uboot的bootargs后,仍然不能在启动内核后打印信息。。。stm的工程师看来是只管写不管有没有用啊。。。