Jump to content

Opi+2e / mainline / ethernet not working any more


vincele

Recommended Posts

Hello,

 

Just returning after a little while,

 

I cannot get ethernet working on my opi+2e with mainline kernel, direct cable

connection to PC, no serial console at hand, neither HDMI output, so I had

the habit of blindly booting then sshing into the box...

 

I tried my personal config + megous repo, xenial or jessie, current armbian repo

nothing coming out of eth on the PC (tcpdump -i eth0). LEDs, green solid on, red

heartbeating, orange eth led blinking slowly.

 

I then reverted back to montjoie's repo (default for dev BRANCH), for identical results.

 

Could this be the updated u-boot (I think I saw a new version being used) ?

 

Or is this expected to be working, and thus something on my side ?

 

Now trying to build a legacy-kernel based image, to double-check...

Edited by zador.blood.stained
Moved to development section
Link to comment
Share on other sites

You should succeed by choosing 'Banana Pi M2+' instead. It's just device tree stuff that's missing. When choosing BPi M2+ you 'loose' functionality of 3rd USB host port and one led. But using dtc tool you can simply add this later.

 

Alternative would be to patch the DT bits already in prior to building kernel/image but at least me got too annoyed since DT bits always have to match kernel version so I chose the 'patch it in later' approach all the time.

 

(I did all my GBit Ethernet tests for montjoe on OPi Plus 2E so it's known to work)

Link to comment
Share on other sites

Hmm... I just built an OS image with dev kernel, switched to megi's 4.9 branch before and used BPi M2+ settings: No network. Then I remembered what I did last time:

sed -i '1isetenv fdtfile sun8i-h3-orangepi-plus.dtb' /boot/boot.cmd
mkimage -C none -A arm -T script -d /boot/boot.cmd /boot/boot.scr
reboot

Wrong DT anyway (since no USB hub on Plus 2E and now one or two USB ports not useable) but Ethernet works fine. Just did a quick test again my MacBook:

root@orangepiplus2e:~# iperf3 -c 192.168.83.166
Connecting to host 192.168.83.166, port 5201
[  4] local 192.168.83.158 port 41112 connected to 192.168.83.166 port 5201
[ ID] Interval           Transfer     Bandwidth       Retr  Cwnd
[  4]   0.00-1.00   sec   103 MBytes   866 Mbits/sec    0    378 KBytes       
[  4]   1.00-2.00   sec   102 MBytes   858 Mbits/sec    0    395 KBytes       
[  4]   2.00-3.00   sec   102 MBytes   858 Mbits/sec    0    395 KBytes       
[  4]   3.00-4.00   sec   103 MBytes   860 Mbits/sec    0    395 KBytes       
[  4]   4.00-5.00   sec   102 MBytes   856 Mbits/sec    0    395 KBytes       
[  4]   5.00-6.00   sec   103 MBytes   860 Mbits/sec    0    395 KBytes       
[  4]   6.00-7.00   sec   102 MBytes   858 Mbits/sec    0    395 KBytes       
[  4]   7.00-8.00   sec   102 MBytes   859 Mbits/sec    0    395 KBytes       
[  4]   8.00-9.00   sec   102 MBytes   859 Mbits/sec    0    395 KBytes       
[  4]   9.00-10.00  sec   103 MBytes   863 Mbits/sec    0    591 KBytes       
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval           Transfer     Bandwidth       Retr
[  4]   0.00-10.00  sec  1.00 GBytes   860 Mbits/sec    0             sender
[  4]   0.00-10.00  sec  1023 MBytes   858 Mbits/sec                  receiver

iperf Done.

root@orangepiplus2e:~# iperf3 -R -c 192.168.83.166
Connecting to host 192.168.83.166, port 5201
Reverse mode, remote host 192.168.83.166 is sending
[  4] local 192.168.83.158 port 41120 connected to 192.168.83.166 port 5201
[ ID] Interval           Transfer     Bandwidth
[  4]   0.00-1.00   sec   112 MBytes   941 Mbits/sec                  
[  4]   1.00-2.00   sec   112 MBytes   941 Mbits/sec                  
[  4]   2.00-3.00   sec   112 MBytes   941 Mbits/sec                  
[  4]   3.00-4.00   sec   112 MBytes   941 Mbits/sec                  
[  4]   4.00-5.00   sec   112 MBytes   941 Mbits/sec                  
[  4]   5.00-6.00   sec   112 MBytes   941 Mbits/sec                  
[  4]   6.00-7.00   sec   112 MBytes   940 Mbits/sec                  
[  4]   7.00-8.00   sec   112 MBytes   941 Mbits/sec                  
[  4]   8.00-9.00   sec   112 MBytes   941 Mbits/sec                  
[  4]   9.00-10.00  sec   108 MBytes   907 Mbits/sec                  
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval           Transfer     Bandwidth
[  4]   0.00-10.00  sec  1.09 GBytes   938 Mbits/sec                  sender
[  4]   0.00-10.00  sec  1.09 GBytes   937 Mbits/sec                  receiver

iperf Done.

With legacy kernel we got only 630/930 Mbits/sec here. BTW: regarding Ethernet: https://irclog.whitequark.org/linux-sunxi/2016-11-26#18270413;

Link to comment
Share on other sites

OK, mounted the sdcard on the PC, did the above and it worked.

 

Now on to try it with the other branch & config...

 

What woud be needed to make it work properly as "./compile [...] BOARD=orangepiplus2e" ?

 

Copy sun8i-h3-orangepi-plus.dtb as sun8i-h3-orangepi-plus2e.dtb somewhere in userpatches ?

Anything else ?

 

Thanks

Link to comment
Share on other sites

Sorry, but I'm still lost...

 

which dts should I base my comparison on ?

 

- /boot/dtb/sun8i-h3-orangepi-plus{,2e}.dtb converted to dts ?

- megous branch kernel source code

- u-boot source code

 

I think I should diff /boot/dtb/sun8i-h3-orangepi-plus{,2e}.dts

Then apply this diff to sun8i-h3-orangepi-plus2e.dts in kernel or u-boot source code,

but replacing the adresses by handle to the right stuff.

 

Is that right ?

Link to comment
Share on other sites

Thanks a lot Martin, I think your DTS patch fixed it for my opi+2e.

 

I had been trying to understand why it broke, and why the old method from above was not working any more for the last few days.

 

I started to diff DTSes around but not really knowing what I was doing, and because of my total lack of output (no serial console, nor any HDMI) it was really painful to blindly test random changes...

 

I'll get serial tomorrow (or at least I hope so), so it will be easier to help

Link to comment
Share on other sites

@TKaiser gave me hint in the other thread.

 

The problem is that older u-Boot had the FDT file set wrongly to "orangepi-plus" not "orangepi-plus-2e", which make the loading DTB for Plus not for Plus2E.

So, diffing the DTS for Plus2E against PC+ was not revealing any thing, but diffing Plus against Plus2E reveal a big thing :

EMAC wasn't declared the same way ! There was also some GMAC-3V3 missing !

Looking at the schematics for PC+, there wasn't any PD6/EMAC-PWR-EN been used, but in both Plus and Plus2E there is a power switch.

In other words, Plus2E DTS never been completed since EMAC never got power, except if using wrong Plus DTS by pure concidence ...

Link to comment
Share on other sites

I now have serial, even if it's epic getting my tiny crappy connectors hooked to the opi pins...

 

So I was able to capture a crash happening at halt time (probably reboot too, not tested yet).

 

Does someone suffer similar problem ?

 

 

 

[ 1116.153691] cpu cpu0: Failed to find opp_table: -19
[ 1116.321516] Unable to handle kernel NULL pointer dereference at virtual address 000000a8
[ 1116.329682] pgd = c0004000
[ 1116.332479] [000000a8] *pgd=00000000
[ 1116.336109] Internal error: Oops: 17 [#1] SMP THUMB2
[ 1116.341098] Modules linked in: gpio_keys 8189fs fuse [last unloaded: uio]
[ 1116.348030] CPU: 2 PID: 133 Comm: kworker/2:2 Not tainted 4.9.0-sun8i #14
[ 1116.354844] Hardware name: Allwinner sun8i Family
[ 1116.359595] Workqueue: events_power_efficient phy_state_machine
[ 1116.365556] task: ee8faac0 task.stack: eeb22000
[ 1116.370118] PC is at phy_state_machine+0x18/0x2f0
[ 1116.374871] LR is at phy_state_machine+0x15/0x2f0
[ 1116.379610] pc : [] lr : [] psr: 600f0033
[ 1116.379610] sp : eeb23ef0 ip : eeb2203c fp : 00000000
[ 1116.391129] r10: 00000000 r9 : 00000000 r8 : eedcc100
[ 1116.396381] r7 : 00000000 r6 : ee34aa58 r5 : ee34aa24 r4 : ee34a800
[ 1116.402950] r3 : 00000000 r2 : 00000000 r1 : 00000004 r0 : ee34aa58
[ 1116.409509] Flags: nZCv IRQs on FIQs on Mode SVC_32 ISA Thumb Segment none
[ 1116.416860] Control: 50c5387d Table: 6d03006a DAC: 00000051
[ 1116.422633] Process kworker/2:2 (pid: 133, stack limit = 0xeeb22210)
[ 1116.429027] Stack: (0xeeb23ef0 to 0xeeb24000)
[ 1116.433419] 3ee0: ee34aa24 eeb89500 eedc86c0 00000000
[ 1116.441645] 3f00: eedcc100 c0128f23 eedc86c0 00000008 eeb23f28 eedc86c0 eeb89518 00000008
[ 1116.449893] 3f20: c0b02d00 eedc86d8 eeb22000 00000000 eeb89500 c01291f7 eeb8f4c0 eeb89500
[ 1116.458136] 3f40: eeb23f58 00000000 eeb8f4c0 eeb89500 c0129105 00000000 00000000 00000000
[ 1116.466363] 3f60: 00000000 c012cd91 00000000 00000000 00000000 eeb89500 00000000 00000000
[ 1116.474590] 3f80: eeb23f80 eeb23f80 00000000 00000000 eeb23f90 eeb23f90 ffffffff eeb8f4c0
[ 1116.482832] 3fa0: c012ccf9 00000000 00000000 c0105ef1 00000000 00000000 00000000 00000000
[ 1116.491061] 3fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
[ 1116.499286] 3fe0: 00000000 00000000 00000000 00000000 00000013 00000000 00000000 00000000
[ 1116.507555] [] (phy_state_machine) from [] (process_one_work+0xd7/0x2b8)
[ 1116.516054] [] (process_one_work) from [] (worker_thread+0xf3/0x438)
[ 1116.524199] [] (worker_thread) from [] (kthread+0x99/0xac)
[ 1116.531507] [] (kthread) from [] (ret_from_fork+0x11/0x20)
[ 1116.538786] Code: f1be f87c f8d4 31a0 (f8d3) 30a8
[ 1116.543702] ---[ end trace 232e771276b99ff4 ]---
[ 1116.548502] Unable to handle kernel paging request at virtual address ffffffec
[ 1116.555787] pgd = c0004000
[ 1116.558532] [ffffffec] *pgd=6fffd861, *pte=00000000, *ppte=00000000
[ 1116.564883] Internal error: Oops: 37 [#2] SMP THUMB2
[ 1116.569873] Modules linked in: gpio_keys 8189fs fuse [last unloaded: uio]
[ 1116.576773] CPU: 2 PID: 133 Comm: kworker/2:2 Tainted: G D 4.9.0-sun8i #14
[ 1116.584827] Hardware name: Allwinner sun8i Family
[ 1116.589576] task: ee8faac0 task.stack: eeb22000
[ 1116.594148] PC is at kthread_data+0x4/0xc
[ 1116.598187] LR is at wq_worker_sleeping+0x7/0x8c
[ 1116.602836] pc : [] lr : [] psr: 000f01b3
[ 1116.602836] sp : eeb23ca8 ip : 00000000 fp : c0b5a040
[ 1116.614370] r10: eedc8b40 r9 : ee8faee0 r8 : c0a56b40
[ 1116.619625] r7 : eeb23cc0 r6 : ee8faac0 r5 : eedc8b40 r4 : c0a56b40
[ 1116.626178] r3 : 00000000 r2 : 00000020 r1 : 00000000 r0 : ee8faac0
[ 1116.632745] Flags: nzcv IRQs off FIQs on Mode SVC_32 ISA Thumb Segment none
[ 1116.640208] Control: 50c5387d Table: 6d03006a DAC: 00000051
[ 1116.646002] Process kworker/2:2 (pid: 133, stack limit = 0xeeb22210)
[ 1116.652387] Stack: (0xeeb23ca8 to 0xeeb24000)
[ 1116.656777] 3ca0: c0b031f4 c069c2a7 c0a51280 ee928c80 ee928c80 00000000
[ 1116.665021] 3cc0: ee8faac0 00000000 2e372000 c013467f c0b031f4 c0b031f4 c0b02040 00000000
[ 1116.673253] 3ce0: c0a51280 ee8faac0 eeb2395c eeb23d10 eeb23d08 eeb23d10 ee8fae58 c04df3a0
[ 1116.681479] 3d00: eeb22000 c013467f ee873900 c011be57 eeb23d10 eeb23d10 c04df3a4 0000000b
[ 1116.689723] 3d20: eeb22000 c010903b eeb22210 0000000b 00000000 00000020 bf000000 00000004
[ 1116.697953] 3d40: 66000000 20656231 63373866 64386620 31332034 28203061 33643866 30332029
[ 1116.706180] 3d60: 00203861 00000000 00000000 c0152afb c08cdcd0 eeb23d94 00000000 000000a8
[ 1116.714425] 3d80: eeb23ea0 00000017 00000000 000000a8 c0b08f2c 00000000 00000000 c0114c5b
[ 1116.722654] 3da0: 00000017 c0111617 000897e3 00000000 eedc8b40 00000001 00000000 00000000
[ 1116.730881] 3dc0: ee3e4fc0 00000000 ee8fab40 c069c15f 00000004 c0b08ebc 00000017 000000a8
[ 1116.739123] 3de0: eeb23ed4 eeb23ea0 c0b08f2c 00000000 00000000 c010121b 00000004 eedc8b78
[ 1116.747354] 3e00: 00000001 00000001 ee8fab40 c0a56b40 ee8faee0 eedc8b40 c0b5a040 c013c979
[ 1116.755579] 3e20: 00000000 c069c45b 7fffffff 7fffffff 00000002 c069e337 ee805900 00000000
[ 1116.763806] 3e40: ee8fab40 eedc8b40 ee8faac0 eeb23ee0 ee807c00 c0127587 eedc8b40 eeb23eb0
[ 1116.772032] 3e60: eeb22000 eeb23eb4 09e6e325 00000000 20000013 eedc8b40 eedc8b40 00000002
[ 1116.780276] 3e80: ee8faac0 c04df39c 600f0033 ffffffff eeb23ed4 eedcc100 eeb22000 c0109653
[ 1116.788506] 3ea0: ee34aa58 00000004 00000000 00000000 ee34a800 ee34aa24 ee34aa58 00000000
[ 1116.796747] 3ec0: eedcc100 00000000 00000000 00000000 eeb2203c eeb23ef0 c04df399 c04df39c
[ 1116.804989] 3ee0: 600f0033 ffffffff 00000051 00000000 ee34aa24 eeb89500 eedc86c0 00000000
[ 1116.813220] 3f00: eedcc100 c0128f23 eedc86c0 00000008 eeb23f28 eedc86c0 eeb89518 00000008
[ 1116.821460] 3f20: c0b02d00 eedc86d8 eeb22000 00000000 eeb89500 c01291f7 eeb8f4c0 eeb89500
[ 1116.829702] 3f40: eeb23f58 00000000 eeb8f4c0 eeb89500 c0129105 00000000 00000000 00000000
[ 1116.837929] 3f60: 00000000 c012cd91 00000000 00000000 00000000 eeb89500 00000000 00000000
[ 1116.846156] 3f80: eeb23f80 eeb23f80 00000001 00010001 eeb23f90 eeb23f90 ffffffff eeb8f4c0
[ 1116.854381] 3fa0: c012ccf9 00000000 00000000 c0105ef1 00000000 00000000 00000000 00000000
[ 1116.862623] 3fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
[ 1116.862645] 3fe0: 00000000 00000000 00000000 00000000 00000013 00000000 00000000 00000000
[ 1116.862686] [] (kthread_data) from [] (wq_worker_sleeping+0x7/0x8c)
[ 1116.862712] [] (wq_worker_sleeping) from [] (__schedule+0x367/0x4f0)
[ 1116.862735] [] (__schedule) from [] (do_task_dead+0x63/0x64)
[ 1116.862757] [] (do_task_dead) from [] (do_exit+0x50f/0x7e4)
[ 1116.862776] [] (do_exit) from [] (die+0x1b7/0x35c)
[ 1116.862794] [] (die) from [] (__do_kernel_fault.part.0+0x4f/0x3f4)
[ 1116.862813] [] (__do_kernel_fault.part.0) from [] (do_page_fault+0x267/0x274)
[ 1116.862832] [] (do_page_fault) from [] (do_DataAbort+0x2f/0x88)
[ 1116.862848] [] (do_DataAbort) from [] (__dabt_svc+0x53/0x80)
[ 1116.862854] Exception stack(0xeeb23ea0 to 0xeeb23ee8)
[ 1116.862870] 3ea0: ee34aa58 00000004 00000000 00000000 ee34a800 ee34aa24 ee34aa58 00000000
[ 1116.862885] 3ec0: eedcc100 00000000 00000000 00000000 eeb2203c eeb23ef0 c04df399 c04df39c
[ 1116.862892] 3ee0: 600f0033 ffffffff
[ 1116.862918] [] (__dabt_svc) from [] (phy_state_machine+0x18/0x2f0)
[ 1116.862941] [] (phy_state_machine) from [] (process_one_work+0xd7/0x2b8)
[ 1116.862958] [] (process_one_work) from [] (worker_thread+0xf3/0x438)
[ 1116.862977] [] (worker_thread) from [] (kthread+0x99/0xac)
[ 1116.863002] [] (kthread) from [] (ret_from_fork+0x11/0x20)
[ 1116.863023] Code: fc4d e7e7 f8d0 33f0 (f853) 0c14
[ 1116.863034] ---[ end trace 232e771276b99ff5 ]---
[ 1116.863041] Fixing recursive fault but reboot is needed!
Stopping LSB: set CPUFreq kernel parameters...

 

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines