Odroid XU3/XU4 NEXT thread

Test and fix the Kernel 4.14 features
User avatar
mad_ady
Posts: 5454
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by mad_ady » Tue Oct 18, 2016 3:08 pm

Try running strace mplayer from a shell and observe what system calls are made when stopping the video

User avatar
rooted
Posts: 6440
Joined: Fri Dec 19, 2014 9:12 am
languages_spoken: english
Location: Gulf of Mexico, US
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by rooted » Tue Oct 18, 2016 8:33 pm

mad_ady wrote:Try running strace mplayer from a shell and observe what system calls are made when stopping the video
Great idea.

User avatar
mad_ady
Posts: 5454
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by mad_ady » Wed Oct 19, 2016 7:59 pm

Ok, I finally managed to get some time to compile the 4.8.x kernel on my xu4, and, as it's to be expected, I ran into a few problems.

I got the kernel from here:

Code: Select all

git clone --depth 1 -b odroidxu4-mihailescu2m-4.8 https://github.com/Dmole/linux.git 
I ran

Code: Select all

make exynos_defconfig
and made these changes:

Code: Select all

adrianp@odroid:~/development/linux-dmole-mihailescu2m-4.8$ diff .config .config-1
35c35
< CONFIG_LOCALVERSION=""
---
> CONFIG_LOCALVERSION="-dmole-1"
494,495c494,498
< # CONFIG_SCHED_MC is not set
< # CONFIG_HPERF_HMP is not set
---
> CONFIG_SCHED_MC=y
> CONFIG_HPERF_HMP=y
> # CONFIG_HPERF_HMP_DEBUG is not set
> CONFIG_HMP_FAST_CPU_MASK="F0"
> CONFIG_HMP_SLOW_CPU_MASK="0F"
501c504,505
< # CONFIG_BL_SWITCHER is not set
---
> CONFIG_BL_SWITCHER=y
> # CONFIG_BL_SWITCHER_DUMMY_IF is not set
764c768,770
< # CONFIG_VLAN_8021Q is not set
---
> CONFIG_VLAN_8021Q=m
> # CONFIG_VLAN_8021Q_GVRP is not set
> # CONFIG_VLAN_8021Q_MVRP is not set
3561a3568
> CONFIG_FS_IOMAP=y
3577c3584,3589
< # CONFIG_XFS_FS is not set
---
> CONFIG_XFS_FS=y
> # CONFIG_XFS_QUOTA is not set
> # CONFIG_XFS_POSIX_ACL is not set
> # CONFIG_XFS_RT is not set
> # CONFIG_XFS_WARN is not set
> # CONFIG_XFS_DEBUG is not set
3596c3608,3609
< # CONFIG_FUSE_FS is not set
---
> CONFIG_FUSE_FS=m
> # CONFIG_CUSE is not set
4108c4121
< # CONFIG_LIBCRC32C is not set
---
> CONFIG_LIBCRC32C=y

And installed it following the standard instructions over here: https://github.com/umiddelb/armhf/wiki/ ... ARM-device

The kernel boots just fine, but it seems I don't have a network interface nor USB3 ports:

Code: Select all

adrianp@odroid:~$ /sbin/ifconfig -a
lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:989 errors:0 dropped:0 overruns:0 frame:0
          TX packets:989 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1 
          RX bytes:90586 (90.5 KB)  TX bytes:90586 (90.5 KB)

sit0      Link encap:IPv6-in-IPv4  
          NOARP  MTU:1480  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

usb0      Link encap:Ethernet  HWaddr 8a:c4:26:8e:6f:53  
          BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
adrianp@odroid:~$ lsusb -t
/:  Bus 04.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 5000M
/:  Bus 03.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 480M
    |__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/2p, 480M
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=exynos-ohci/3p, 12M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=exynos-ehci/3p, 480M

I booted the system with both exynos5422-odroidxu3.dtb and exynos5422-odroidxu4.dtb and I get the same issues.

I'm guessing the problem is I probably shouldn't have used exynos_defconfig, so - could you guys recommend a different base configuration to start from?

daviessm
Posts: 110
Joined: Thu Jul 25, 2013 2:14 am
languages_spoken: English, German
ODROIDs: X2, XU4
Location: Belfast, UK
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by daviessm » Wed Oct 19, 2016 8:40 pm

First off, did you power off the Odroid before restarting with the new kernel? It sounds stupid but sometimes when changing kernels the network port isn't recognised unless you do that.

User avatar
mad_ady
Posts: 5454
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by mad_ady » Wed Oct 19, 2016 11:15 pm

Oops, I did not. I thought that was an issue only when I had HDMI as well. I will unpower it tomorrow and try again, thanks.

User avatar
mad_ady
Posts: 5454
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by mad_ady » Thu Oct 20, 2016 5:37 pm

Yup, removing power and repowering the board resolved the USB3 missing issue. Now I have ethernet and USB3 bus:

Code: Select all

adrianp@odroid:~> ifconfig -a
eth0      Link encap:Ethernet  HWaddr 00:1e:06:31:8c:5b  
          inet addr:80.97.238.203  Bcast:80.97.238.255  Mask:255.255.255.0
          inet6 addr: fe80::4623:a3f5:7703:579/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:237 errors:0 dropped:0 overruns:0 frame:0
          TX packets:198 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:32680 (32.6 KB)  TX bytes:30548 (30.5 KB)

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:69 errors:0 dropped:0 overruns:0 frame:0
          TX packets:69 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1 
          RX bytes:9748 (9.7 KB)  TX bytes:9748 (9.7 KB)

sit0      Link encap:IPv6-in-IPv4  
          NOARP  MTU:1480  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

adrianp@odroid:~> lsusb -t
/:  Bus 06.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 5000M
    |__ Port 1: Dev 2, If 0, Class=Vendor Specific Class, Driver=r8152, 5000M
/:  Bus 05.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 480M
/:  Bus 04.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 5000M
    |__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/2p, 5000M
/:  Bus 03.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 480M
    |__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/2p, 480M
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=exynos-ohci/3p, 12M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=exynos-ehci/3p, 480M
adrianp@odroid:~> uname -a
Linux odroid 4.8.2-dmole-1-g8df68ec #1 SMP PREEMPT Wed Oct 19 12:42:30 EEST 2016 armv7l armv7l armv7l GNU/Linux
Thank you daviessm for your suggestion.

One more thing. Now I only see 4 CPU cores. Is this because I enabled BL Switcher? CONFIG_BL_SWITCHER=y

moon.linux
Posts: 1162
Joined: Thu Oct 02, 2014 11:42 pm
languages_spoken: english
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by moon.linux » Thu Oct 20, 2016 5:48 pm

Yep CONFIG_BL_SWITCHER=y is dropped long time ago. As we use cpufreq-dt changes for cpufreq modules.

User avatar
mad_ady
Posts: 5454
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by mad_ady » Thu Oct 20, 2016 6:11 pm

So, if I understand it correctly, the BL_Switcher pairs a big and a little core and switches between them automagically when needed based on load, right? Shouldn't it provide better performance if you don't add the HMP patches and turn off the little cores?

Update: I recompiled with BL_SWITCHER disabled and now I get all the cores and sysbench uses them. However it seems the max frequency is limited to 1.3 on the little cores and 1.9 on the big cores (and big cores are preferred, which is fine). I think I remember reading somewhere in this thread that I needed to make a change somewhere to enable the extra frequencies (I'm running with exynos5422-odroidxu4.dtb). I need to look that up.

Edit: ... and I got my first panic after sysbench finished:

Code: Select all

[  759.540331] Unable to handle kernel NULL pointer dereference at virtual address 0000001c
[  759.543185] BUG: spinlock cpu recursion on CPU#0, swapper/0/0
[  759.543225]  lock: 0xeefa2800, .magic: dead4ead, .owner: <none>/-1, .owner_cpu: -1
[  759.543256] CPU: 0 PID: 0 Comm: swapper/0 Tainted: G        W       4.8.2-dmole-2-g8df68ec #2
[  759.543270] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[  759.543340] [<c010e124>] (unwind_backtrace) from [<c010ada8>] (show_stack+0x10/0x14)
[  759.543391] [<c010ada8>] (show_stack) from [<c039a8d0>] (dump_stack+0x78/0x8c)
[  759.543441] [<c039a8d0>] (dump_stack) from [<c015bd5c>] (do_raw_spin_lock+0x1a0/0x1d8)
[  759.543488] [<c015bd5c>] (do_raw_spin_lock) from [<c014e154>] (pick_next_task_fair+0x624/0xd6c)
[  759.543552] [<c014e154>] (pick_next_task_fair) from [<c0751968>] (__schedule+0x240/0x49c)
[  759.543624] [<c0751968>] (__schedule) from [<c0751c10>] (schedule+0x4c/0xac)
[  759.543678] [<c0751c10>] (schedule) from [<c07520f8>] (schedule_preempt_disabled+0x14/0x20)
[  759.543733] [<c07520f8>] (schedule_preempt_disabled) from [<c01553b0>] (cpu_startup_entry+0x118/0x248)
[  759.543785] [<c01553b0>] (cpu_startup_entry) from [<c0b00c5c>] (start_kernel+0x374/0x380)
[  759.647169] pgd = c0004000
[  759.649843] [0000001c] *pgd=00000000
[  759.653407] Internal error: Oops: 5 [#1] PREEMPT SMP ARM
[  759.658680] Modules linked in: fuse cpufreq_conservative cpufreq_userspace cpufreq_powersave s5p_mfc s5p_jpeg v4l2_mem2mem videobuf2_dma_contig v4l2_common videobuf2_memops videobuf2_v4l2 videobuf2_core videodev media
[  759.677935] CPU: 4 PID: 7 Comm: rcu_preempt Tainted: G        W       4.8.2-dmole-2-g8df68ec #2
[  759.686582] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[  759.692652] task: ee889e00 task.stack: ee8b4000
[  759.697176] PC is at set_next_entity+0x8/0xc9c
[  759.701584] LR is at pick_next_task_fair+0xa30/0xd6c
[  759.706524] pc : [<c0143cf8>]    lr : [<c014e560>]    psr: 600e0093
[  759.706524] sp : ee8b5db4  ip : afb50401  fp : ee8b5ebc
[  759.717953] r10: 00000004  r9 : 00000000  r8 : eefda800
[  759.723153] r7 : ee88a148  r6 : ffffff80  r5 : 00000000  r4 : eefda850
[  759.729652] r3 : 00000000  r2 : 00000000  r1 : 00000000  r0 : eefda850
[  759.736156] Flags: nZCv  IRQs off  FIQs on  Mode SVC_32  ISA ARM  Segment none
[  759.743345] Control: 10c5387d  Table: 6b81006a  DAC: 00000051
[  759.749062] Process rcu_preempt (pid: 7, stack limit = 0xee8b4210)
[  759.755215] Stack: (0xee8b5db4 to 0xee8b6000)
[  759.759556] 5da0:                                              eefda850 00000000 ffffff80
[  759.767709] 5dc0: ee88a148 eefda800 00000000 00000004 ee8b5ebc c014e560 ee8b5e6c 00000020
[  759.775857] 5de0: ffffffff eefda850 001d28d8 00000000 001d28d8 00000000 eefda850 eefda800
[  759.783998] 5e00: ee889e00 eefda800 eefda800 c0b65800 c0b65800 00000000 000002e1 c0c02614
[  759.792144] 5e20: 000002e1 00000400 00000001 afb50401 ee889e00 c0b60320 00000001 00000000
[  759.800289] 5e40: 00000001 00000000 ee889e80 eefda800 01fd9c81 00000000 02590003 00000000
[  759.808435] 5e60: 001cad05 00000000 001df209 00000000 eefda800 c08013a4 eefda800 ee889e00
[  759.816581] 5e80: ee88a148 c0c02614 00000000 00000004 ee8b5ebc c0751968 ee8b5ed8 c0c02100
[  759.824725] 5ea0: ee8b4000 00016704 ee8b5ed8 c0c02100 eefd7380 00000000 ee8b5ecc c0751c10
[  759.832870] 5ec0: eefd7380 00016704 00000000 c0755e1c 00000001 400e0013 00000000 eefd7400
[  759.841016] 5ee0: 00016704 c0172cf8 ee889e00 01400004 c0c0ac80 c0c0ae68 c0c0ae50 c0c02100
[  759.849161] 5f00: c0c0ae6a 00000001 00000001 c016f810 c0c0ac80 c0c024ec c0c42f27 c0990c34
[  759.857307] 5f20: ee8b4000 c0c02614 c0990968 c0c0ae50 01000000 ee889e00 c0c0ae60 c0c0ae60
[  759.865452] 5f40: 00000000 c016f1ac 00000000 c0135a4c 00000000 00000000 00000000 c0c0ac80
[  759.873597] 5f60: 00000000 00000000 dead4ead ffffffff ffffffff ee8b5f74 ee8b5f74 00000000
[  759.881743] 5f80: 00000000 dead4ead ffffffff ffffffff ee8b5f90 ee8b5f90 ee8b5fac ee859dc0
[  759.889888] 5fa0: c0135970 00000000 00000000 c01077f8 00000000 00000000 00000000 00000000
[  759.898032] 5fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
[  759.906180] 5fe0: 00000000 00000000 00000000 00000000 00000013 00000000 00000040 00000000
[  759.914336] [<c0143cf8>] (set_next_entity) from [<000002e1>] (0x2e1)
[  759.920657] Code: 0afb5040 afb50400 e92d4ff0 e1a05001 (e591301c)
[  759.926725] ---[ end trace a186ffdc27e1c733 ]---
[  759.931303] note: rcu_preempt[7] exited with preempt_count 2
[  770.354138] BUG: spinlock lockup suspected on CPU#6, tmux/16690
[  770.358678]  lock: 0xeefda800, .magic: dead4ead, .owner: rcu_preempt/7, .owner_cpu: 4
[  770.366459] CPU: 6 PID: 16690 Comm: tmux Tainted: G      D W       4.8.2-dmole-2-g8df68ec #2
[  770.374856] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)


User avatar
mad_ady
Posts: 5454
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by mad_ady » Thu Oct 20, 2016 7:08 pm

memeka wrote:
mad_ady wrote:Wow, this is BIG!
But - where is the connection to the hardware encoder? I see no reference in the command line. Does this mean that all h264 encoding is done through MFC? Also, where do we get this new ffmpeg code from?

h264 selects the MFC decoder by default.... you can select h264_v4l2m2m if you want to make sure :)

here's debug:

Code: Select all

ffmpeg version 3.0.2-1ubuntu4 Copyright (c) 2000-2016 the FFmpeg developers
  built with gcc 6.2.0 (Ubuntu 6.2.0-1ubuntu12) 20160824
  configuration: --prefix=/usr --extra-version=1ubuntu4 --toolchain=hardened --libdir=/usr/lib/arm-linux-gnueabihf --incdir=/usr/include/arm-linux-gnueabihf --cc=cc --cxx=g++ --enable-gpl --enable-shared --disable-stripping --disable-decoder=libopenjpeg --disable-decoder=libschroedinger --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-librubberband --enable-librtmp --enable-libschroedinger --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxvid --enable-libzvbi --enable-openal --enable-opengl --enable-x11grab --enable-libdc1394 --enable-libiec61883 --enable-libzmq --enable-frei0r --enable-chromaprint --enable-libx264
  libavutil      55. 17.103 / 55. 17.103
  libavcodec     57. 24.102 / 57. 24.102
  libavformat    57. 25.100 / 57. 25.100
  libavdevice    57.  0.101 / 57.  0.101
  libavfilter     6. 31.100 /  6. 31.100
  libavresample   3.  0.  0 /  3.  0.  0
  libswscale      4.  0.100 /  4.  0.100
  libswresample   2.  0.101 /  2.  0.101
  libpostproc    54.  0.100 / 54.  0.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from './test.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    creation_time   : 1970-01-01 00:00:00
    title           : Sintel Trailer
    artist          : Durian Open Movie Team
    encoder         : Lavf52.62.0
    copyright       : (c) copyright Blender Foundation | durian.blender.org
    description     : Trailer for the Sintel open movie project
  Duration: 00:00:52.21, start: 0.000000, bitrate: 1165 kb/s
    Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1280x720, 1033 kb/s, 24 fps, 24 tbr, 24 tbn, 48 tbc (default)
    Metadata:
      creation_time   : 1970-01-01 00:00:00
      handler_name    : VideoHandler
    Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 126 kb/s (default)
    Metadata:
      creation_time   : 1970-01-01 00:00:00
      handler_name    : SoundHandler
[h264_v4l2m2m @ 0x71ec0] Device path not set, probing /dev/video*
[h264_v4l2m2m @ 0x71ec0] Using device /dev/video5
[h264_v4l2m2m @ 0x71ec0] Suggested pixel format yuv420p is not accepted on output pool, will guess one.
[h264_v4l2m2m @ 0x71ec0] Pixelformat nv12 is accepted on output pool, using it.
Output #0, mp4, to 'encoded.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    description     : Trailer for the Sintel open movie project
    title           : Sintel Trailer
    artist          : Durian Open Movie Team
    copyright       : (c) copyright Blender Foundation | durian.blender.org
    encoder         : Lavf57.25.100
    Stream #0:0(und): Video: h264 (h264_v4l2m2m) ([33][0][0][0] / 0x0021), yuv420p, 1280x720, q=2-31, 200 kb/s, 24 fps, 12288 tbn, 24 tbc (default)
    Metadata:
      creation_time   : 1970-01-01 00:00:00
      handler_name    : VideoHandler
      encoder         : Lavc57.24.102 h264_v4l2m2m
    Stream #0:1(und): Audio: aac (LC) ([64][0][0][0] / 0x0040), 48000 Hz, stereo, fltp, 128 kb/s (default)
    Metadata:
      creation_time   : 1970-01-01 00:00:00
      handler_name    : SoundHandler
      encoder         : Lavc57.24.102 aac
Stream mapping:
  Stream #0:0 -> #0:0 (h264 (native) -> h264 (h264_v4l2m2m))
  Stream #0:1 -> #0:1 (aac (native) -> aac (native))
Press [q] to stop, [?] for help
[h264_v4l2m2m @ 0x71ec0] Performing useless memcpy() on output pool because buffers do not match
[h264_v4l2m2m @ 0x71ec0] This could be avoided by using av_v4l_buffer_pool_get_buffer*() or av_v4l_buffer_pool_make_pipe()
[mp4 @ 0x86e30] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly
[mp4 @ 0x86e30] Encoder did not produce proper pts, making some up.
frame=   32 fps=0.0 q=-0.0 size=     385kB time=00:00:01.60 bitrate=1972.1kbits/s speed=3.17x    ^Mframe=   67 fps= 67 q=-0.0 size=    2983kB time=00:00:03.07 bitrate=7955.8kbits/s speed=3.05x    ^Mframe=  101 fps= 67 q=-0.0 size=    6771kB time=00:00:04.50 bitrate=12322.1kbits/s speed=2.99x    ^Mframe=  136 fps= 68 q=-0.0 size=   10001kB time=00:00:05.95 bitrate=13765.4kbits/s speed=2.96x    ^Mframe=  168 fps= 67 q=-0.0 size=   14529kB time=00:00:07.25 bitrate=16408.9kbits/s speed=2.89x    ^Mframe=  200 fps= 66 q=-0.0 size=   19871kB time=00:00:08.59 bitrate=18933.9kbits/s speed=2.85x    ^Mframe=  249 fps= 71 q=-0.0 size=   22356kB time=00:00:10.66 bitrate=17169.2kbits/s speed=3.04x    ^Mframe=  309 fps= 77 q=-0.0 size=   26447kB time=00:00:13.14 bitrate=16486.2kbits/s speed=3.27x    ^Mframe=  352 fps= 78 q=-0.0 size=   33772kB time=00:00:14.95 bitrate=18499.8kbits/s speed=3.31x    ^Mframe=  407 fps= 81 q=-0.0 size=   39582kB time=00:00:17.21 bitrate=18834.4kbits/s speed=3.43x    ^Mframe=  458 fps= 83 q=-0.0 size=   45657kB time=00:00:19.37 bitrate=19308.7kbits/s speed=3.51x    ^Mframe=  499 fps= 83 q=-0.0 size=   55653kB time=00:00:21.07 bitrate=21630.4kbits/s speed= 3.5x    ^Mframe=  551 fps= 84 q=-0.0 size=   64440kB time=00:00:23.21 bitrate=22743.6kbits/s speed=3.56x    ^Mframe=  595 fps= 85 q=-0.0 size=   74299kB time=00:00:25.06 bitrate=24281.6kbits/s speed=3.56x    ^Mframe=  640 fps= 85 q=-0.0 size=   83697kB time=00:00:26.94 bitrate=25447.0kbits/s speed=3.58x    ^Mframe=  695 fps= 86 q=-0.0 size=   90978kB time=00:00:29.24 bitrate=25481.7kbits/s speed=3.64x    ^Mframe=  741 fps= 87 q=-0.0 size=  100310kB time=00:00:31.12 bitrate=26401.1kbits/s speed=3.64x    ^Mframe=  789 fps= 87 q=-0.0 size=  107524kB time=00:00:33.13 bitrate=26586.7kbits/s speed=3.67x    ^Mframe=  844 fps= 88 q=-0.0 size=  114773kB time=00:00:35.45 bitrate=26517.9kbits/s speed=3.71x    ^Mframe=  899 fps= 89 q=-0.0 size=  120878kB time=00:00:37.73 bitrate=26239.1kbits/s speed=3.76x    ^Mframe=  948 fps= 90 q=-0.0 size=  127485kB time=00:00:39.78 bitrate=26248.8kbits/s speed=3.77x    ^Mframe= 1000 fps= 90 q=-0.0 size=  133913kB time=00:00:41.96 bitrate=26142.7kbits/s speed= 3.8x    ^Mframe= 1069 fps= 93 q=-0.0 size=  135436kB time=00:00:44.80 bitrate=24765.5kbits/s speed=3.88x    ^Mframe= 1144 fps= 95 q=-0.0 size=  136373kB time=00:00:47.93 bitrate=23305.5kbits/s speed=3.98x    ^Mframe= 1225 fps= 98 q=-0.0 size=  136968kB time=00:00:51.32 bitrate=21860.2kbits/s speed=4.09x    ^M[h264_v4l2m2m @ 0x71ec0] No event occurred while waiting
frame= 1253 fps= 98 q=-0.0 Lsize=  137018kB time=00:00:52.25 bitrate=21482.3kbits/s speed=4.07x
video:136173kB audio:817kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.019993%
[aac @ 0x72e00] Qavg: 659.826

the original patches are already in my repo, based on ffmpeg 2.8.2 (from ubuntu 16.04)
@oversun's patch is 1 line of code :)
and i am now running all on ffmpeg 3.x from ubuntu 16.10... i will push those patches after i fix a few more things (e.g. currently the decoder/encoder grabs the first device it finds, so the decoder may grab the encoder and fail, or the gstreamer, etc... :D)

EDIT: also a divx to h264 encoding: http://paste.debian.net/794630/
@memeka: I am trying to replicate hardware encoding with your FFmpeg branch, but I wasn't able to compile support for the hardware encoder. Here's how I compiled ffmpeg:

Code: Select all

#get the patched ffmpeg version
$ git clone --depth 1 https://github.com/mihailescu2m/FFmpeg.git
#install ffmpeg dependencies so it can build
$ sudo apt-get build-dep ffmpeg
$ sudo apt-get install libv4l-0 libv4l-dev
$ cd FFmpeg
$ ./configure --prefix=/usr/local --extra-version=memeka1 --build-suffix=-ffmpeg --toolchain=hardened --libdir=/usr/lib/arm-linux-gnueabihf --incdir=/usr/include/arm-linux-gnueabihf --cc=cc --cxx=g++ --enable-gpl --enable-shared --disable-stripping --disable-decoder=libopenjpeg --disable-decoder=libschroedinger --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-librtmp --enable-libschroedinger --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxvid --enable-libzvbi --enable-openal --enable-opengl --enable-x11grab --enable-libdc1394 --enable-libiec61883 --enable-libzmq --enable-frei0r --enable-libx264 --enable-libopencv --enable-libv4l2
$ make -j 4
$ sudo make install
FFmpeg compiled fine and works, but does software encoding (@19fps) and it complains when called with -vcodec h264_v4l2m2m.

Code: Select all

Unknown encoder 'h264_v4l2m2m'
I guess I need to enable something extra in configure, but I couldn't find any reference to h264_v4lm2m.
[/code]

moon.linux
Posts: 1162
Joined: Thu Oct 02, 2014 11:42 pm
languages_spoken: english
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by moon.linux » Thu Oct 20, 2016 9:50 pm

So, if I understand it correctly, the BL_Switcher pairs a big and a little core and switches between them automagically when needed based on load, right? Shouldn't it provide better performance if you don't add the HMP patches and turn off the little cores?
By enable CONFIG_BL_SWITCHER and CONFIG_ARM_BIG_LITTLE_CPUFREQ is needed.
So by enable CONFIG_BL_SWITCHER we just enable cluster of cpu's.
This make the HMP scheduler for cpu's to maintain states of the big.LITTLE cpu task across the process.
So task migration from one cluster to another cluster is depend on the load and cpufreq scaling and temperature.

As the cpu temperature is increases the cpufreq module will scale down the frequency and migrate the task to another cpu.

3.10.x HMP scheduler is not complete BL_SWITCHER supported.
It tires migrates the task across big.Little depend on cpu mask and all 8 core are independent.

elatllat
Posts: 1190
Joined: Tue Sep 01, 2015 8:54 am
languages_spoken: english
ODROIDs: XU4, N1
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by elatllat » Thu Oct 20, 2016 11:07 pm

4.8.3 merged into odroidxu4 tobetter and mihailescu2m branches.

User avatar
mad_ady
Posts: 5454
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by mad_ady » Thu Oct 20, 2016 11:45 pm

Nice. I will give it a try tomorrow. Do you have a specific defconfig that goes with it?

elatllat
Posts: 1190
Joined: Tue Sep 01, 2015 8:54 am
languages_spoken: english
ODROIDs: XU4, N1
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by elatllat » Thu Oct 20, 2016 11:52 pm

mad_ady wrote:Nice. I will give it a try tomorrow. Do you have a specific defconfig that goes with it?
I use 'make odroidxu4_defconfig' on the tobetter branch and will merge any tested additions.

User avatar
rooted
Posts: 6440
Joined: Fri Dec 19, 2014 9:12 am
languages_spoken: english
Location: Gulf of Mexico, US
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by rooted » Fri Oct 21, 2016 12:00 am

elatllat wrote:
mad_ady wrote:Nice. I will give it a try tomorrow. Do you have a specific defconfig that goes with it?
I use 'make odroidxu4_defconfig' on the tobetter branch and will merge any tested additions.
So far it's the best defconfig, missing a few things but a very good starting point.

elatllat
Posts: 1190
Joined: Tue Sep 01, 2015 8:54 am
languages_spoken: english
ODROIDs: XU4, N1
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by elatllat » Fri Oct 21, 2016 12:14 am

rooted wrote:
elatllat wrote:
mad_ady wrote:Nice. I will give it a try tomorrow. Do you have a specific defconfig that goes with it?
I use 'make odroidxu4_defconfig' on the tobetter branch and will merge any tested additions.
So far it's the best defconfig, missing a few things but a very good starting point.
Please do send a pull request for those "few things".

User avatar
rooted
Posts: 6440
Joined: Fri Dec 19, 2014 9:12 am
languages_spoken: english
Location: Gulf of Mexico, US
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by rooted » Fri Oct 21, 2016 12:19 am

elatllat wrote:
rooted wrote:
elatllat wrote:
mad_ady wrote:Nice. I will give it a try tomorrow. Do you have a specific defconfig that goes with it?
I use 'make odroidxu4_defconfig' on the tobetter branch and will merge any tested additions.
So far it's the best defconfig, missing a few things but a very good starting point.
Please do send a pull request for those "few things".
Is the repo linked above yours?

The major thing for me that's missing is ATSC/DVB drivers, and RTC has to be built in for time to be correctly set upon boot when not connected to the Internet.

And zram with lz4hc as well.

User avatar
mad_ady
Posts: 5454
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by mad_ady » Fri Oct 21, 2016 2:09 am

+ various filesystem support. If the xu4 is a nas, it should support a wide array of filesystems.
I, for example, need XFS. But I think the defconfig should be as close as possible to HardKernel's 3.10.

elatllat
Posts: 1190
Joined: Tue Sep 01, 2015 8:54 am
languages_spoken: english
ODROIDs: XU4, N1
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by elatllat » Fri Oct 21, 2016 2:35 am

elatllat wrote:4.8.3 merged into odroidxu4 tobetter and mihailescu2m branches.
rooted wrote:...Is the repo linked above yours?...
Yes.
rooted wrote:...DVB...RTC...zram...
I enabled zram, make a tested pull request for the rest.
mad_ady wrote:...XFS...
If you have used XFS make a pull request for the details (Quota, POSIX ACL, Realtime subvolume, etc)
mad_ady wrote:...I think the defconfig should be as close as possible to HardKernel's 3.10...
Yes, and if people are using 3.10 with kernel options not enabled on HardKernel's default config just make a pull request to there.
(I won't be making any more pull requests to 3.10 as it crashes for my use case, so using 4.8 is the path of least resistance)

User avatar
rooted
Posts: 6440
Joined: Fri Dec 19, 2014 9:12 am
languages_spoken: english
Location: Gulf of Mexico, US
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by rooted » Fri Oct 21, 2016 2:46 am

Everything I listed has been thoroughly tested but I don't mind doing a pull request.

User avatar
mad_ady
Posts: 5454
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by mad_ady » Fri Oct 21, 2016 6:02 pm

I compiled the 4.8.3 branch (mihailescu2m) without HMP and so far it's stable. Sysbench reports a slightly slower performance (414.7891s vs 393.2770s on stock). I think I'm going to take my chances with cgroups and setting specific processes on the bigger cores for the things that matter in my use case.
Once I have tested XFS and other features I will make a pull request. (By the way, can I do that without cloning the kernel in my repository?)

Update: XFS works correctly over USB3, but I had to power off the box completely before the disk got any power:

Code: Select all

adrianp@odroid:~> sudo mkdir /media/usb
adrianp@odroid:~> sudo mount /dev/sda2 /media/usb
adrianp@odroid:~> ls -l /media/usb
total 20
drwxrwxrwx  21 root   odroid 4096 Aug 27 14:14 Music
drwxrwxr-x  34 nobody odroid 4096 Aug 27 14:03 Pictures
adrianp@odroid:~> mount | grep /media/usb
/dev/sda2 on /media/usb type xfs (rw,relatime,inode64,noquota)
adrianp@odroid:~> lsusb -t
/:  Bus 06.Port 1: Dev 1, Class=root_hub, Driver=exynos-ohci/3p, 12M
/:  Bus 05.Port 1: Dev 1, Class=root_hub, Driver=exynos-ehci/3p, 480M
/:  Bus 04.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 5000M
    |__ Port 1: Dev 2, If 0, Class=Vendor Specific Class, Driver=r8152, 5000M
/:  Bus 03.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 480M
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 5000M
    |__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/2p, 5000M
        |__ Port 1: Dev 3, If 0, Class=Mass Storage, Driver=uas, 5000M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 480M
    |__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/2p, 480M

I compiled the kernel only with

Code: Select all

CONFIG_XFS_FS=m
# CONFIG_XFS_QUOTA is not set
# CONFIG_XFS_POSIX_ACL is not set
# CONFIG_XFS_RT is not set
# CONFIG_XFS_WARN is not set
# CONFIG_XFS_DEBUG is not set
Edit 2: There is no longer an entry for fan control under sys (/sys/devices/odroid_fan.*):

Code: Select all

adrianp@odroid:~> cat /sys/devices/odroid_fan.*
cat: '/sys/devices/odroid_fan.*': No such file or directory
1 adrianp@odroid:~> ls /sys/devices/ 
breakpoint  platform  software  system  virtual
adrianp@odroid:~> sudo find /sys -name "odroid_fan*"
adrianp@odroid:~> 

adrianp@odroid:~> cat /sys/devices/virtual/thermal/
cooling_device0/ cooling_device2/ thermal_zone1/   thermal_zone3/
cooling_device1/ thermal_zone0/   thermal_zone2/   thermal_zone4/
adrianp@odroid:~> cat /sys/devices/virtual/thermal/cooling_device0/
cur_state  max_state  power/     subsystem/ type       uevent     
adrianp@odroid:~> cat /sys/devices/virtual/thermal/cooling_device0/cur_state
0
adrianp@odroid:~> cat /sys/devices/virtual/thermal/cooling_device0/max_state
3
adrianp@odroid:~> cat /sys/devices/virtual/thermal/cooling_device0/type     
pwm-fan
Is that the replacement? And if yes, how do I get the current "load" of the pwm?

User avatar
rooted
Posts: 6440
Joined: Fri Dec 19, 2014 9:12 am
languages_spoken: english
Location: Gulf of Mexico, US
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by rooted » Fri Oct 21, 2016 9:49 pm

Code: Select all

cat /sys/devices/virtual/thermal/thermal_zone0/temp
And you have to enable writeable trip points in the kernel to control the points, these are what I use.

Code: Select all

echo 65000 > /sys/devices/virtual/thermal/thermal_zone0/trip_point_0_temp
echo 75000 > /sys/devices/virtual/thermal/thermal_zone0/trip_point_1_temp
echo 82000 > /sys/devices/virtual/thermal/thermal_zone0/trip_point_2_temp
I will have to get back with you on PWM.

User avatar
rooted
Posts: 6440
Joined: Fri Dec 19, 2014 9:12 am
languages_spoken: english
Location: Gulf of Mexico, US
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by rooted » Fri Oct 21, 2016 11:42 pm

I just created a pull request for tobetter's branch to enable writeable trip points.

elatllat
Posts: 1190
Joined: Tue Sep 01, 2015 8:54 am
languages_spoken: english
ODROIDs: XU4, N1
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by elatllat » Sat Oct 22, 2016 1:21 am

mad_ady wrote:...XFS works correctly...

Code: Select all

CONFIG_XFS_FS=m
...
merged.

I also merged odroidxu4-tobetter-4.8 into odroidxu4-mihailescu2m-4.8 with the exception of

Code: Select all

arch/arm/boot/dts/exynos5800.dtsi
which memeka et al commented on here.
and

Code: Select all

drivers/usb/host/xhci-plat.c
which is an unexplained divergence so far.
Last edited by elatllat on Sat Oct 22, 2016 11:58 am, edited 1 time in total.

User avatar
memeka
Posts: 4244
Joined: Mon May 20, 2013 10:22 am
languages_spoken: english
ODROIDs: XU rev2 + eMMC + UART
U3 + eMMC + IO Shield + UART
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by memeka » Sat Oct 22, 2016 11:12 am

mad_ady wrote:
memeka wrote:
mad_ady wrote:Wow, this is BIG!
But - where is the connection to the hardware encoder? I see no reference in the command line. Does this mean that all h264 encoding is done through MFC? Also, where do we get this new ffmpeg code from?

h264 selects the MFC decoder by default.... you can select h264_v4l2m2m if you want to make sure :)

here's debug:

Code: Select all

ffmpeg version 3.0.2-1ubuntu4 Copyright (c) 2000-2016 the FFmpeg developers
  built with gcc 6.2.0 (Ubuntu 6.2.0-1ubuntu12) 20160824
  configuration: --prefix=/usr --extra-version=1ubuntu4 --toolchain=hardened --libdir=/usr/lib/arm-linux-gnueabihf --incdir=/usr/include/arm-linux-gnueabihf --cc=cc --cxx=g++ --enable-gpl --enable-shared --disable-stripping --disable-decoder=libopenjpeg --disable-decoder=libschroedinger --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-librubberband --enable-librtmp --enable-libschroedinger --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxvid --enable-libzvbi --enable-openal --enable-opengl --enable-x11grab --enable-libdc1394 --enable-libiec61883 --enable-libzmq --enable-frei0r --enable-chromaprint --enable-libx264
  libavutil      55. 17.103 / 55. 17.103
  libavcodec     57. 24.102 / 57. 24.102
  libavformat    57. 25.100 / 57. 25.100
  libavdevice    57.  0.101 / 57.  0.101
  libavfilter     6. 31.100 /  6. 31.100
  libavresample   3.  0.  0 /  3.  0.  0
  libswscale      4.  0.100 /  4.  0.100
  libswresample   2.  0.101 /  2.  0.101
  libpostproc    54.  0.100 / 54.  0.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from './test.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    creation_time   : 1970-01-01 00:00:00
    title           : Sintel Trailer
    artist          : Durian Open Movie Team
    encoder         : Lavf52.62.0
    copyright       : (c) copyright Blender Foundation | durian.blender.org
    description     : Trailer for the Sintel open movie project
  Duration: 00:00:52.21, start: 0.000000, bitrate: 1165 kb/s
    Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1280x720, 1033 kb/s, 24 fps, 24 tbr, 24 tbn, 48 tbc (default)
    Metadata:
      creation_time   : 1970-01-01 00:00:00
      handler_name    : VideoHandler
    Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 126 kb/s (default)
    Metadata:
      creation_time   : 1970-01-01 00:00:00
      handler_name    : SoundHandler
[h264_v4l2m2m @ 0x71ec0] Device path not set, probing /dev/video*
[h264_v4l2m2m @ 0x71ec0] Using device /dev/video5
[h264_v4l2m2m @ 0x71ec0] Suggested pixel format yuv420p is not accepted on output pool, will guess one.
[h264_v4l2m2m @ 0x71ec0] Pixelformat nv12 is accepted on output pool, using it.
Output #0, mp4, to 'encoded.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    description     : Trailer for the Sintel open movie project
    title           : Sintel Trailer
    artist          : Durian Open Movie Team
    copyright       : (c) copyright Blender Foundation | durian.blender.org
    encoder         : Lavf57.25.100
    Stream #0:0(und): Video: h264 (h264_v4l2m2m) ([33][0][0][0] / 0x0021), yuv420p, 1280x720, q=2-31, 200 kb/s, 24 fps, 12288 tbn, 24 tbc (default)
    Metadata:
      creation_time   : 1970-01-01 00:00:00
      handler_name    : VideoHandler
      encoder         : Lavc57.24.102 h264_v4l2m2m
    Stream #0:1(und): Audio: aac (LC) ([64][0][0][0] / 0x0040), 48000 Hz, stereo, fltp, 128 kb/s (default)
    Metadata:
      creation_time   : 1970-01-01 00:00:00
      handler_name    : SoundHandler
      encoder         : Lavc57.24.102 aac
Stream mapping:
  Stream #0:0 -> #0:0 (h264 (native) -> h264 (h264_v4l2m2m))
  Stream #0:1 -> #0:1 (aac (native) -> aac (native))
Press [q] to stop, [?] for help
[h264_v4l2m2m @ 0x71ec0] Performing useless memcpy() on output pool because buffers do not match
[h264_v4l2m2m @ 0x71ec0] This could be avoided by using av_v4l_buffer_pool_get_buffer*() or av_v4l_buffer_pool_make_pipe()
[mp4 @ 0x86e30] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly
[mp4 @ 0x86e30] Encoder did not produce proper pts, making some up.
frame=   32 fps=0.0 q=-0.0 size=     385kB time=00:00:01.60 bitrate=1972.1kbits/s speed=3.17x    ^Mframe=   67 fps= 67 q=-0.0 size=    2983kB time=00:00:03.07 bitrate=7955.8kbits/s speed=3.05x    ^Mframe=  101 fps= 67 q=-0.0 size=    6771kB time=00:00:04.50 bitrate=12322.1kbits/s speed=2.99x    ^Mframe=  136 fps= 68 q=-0.0 size=   10001kB time=00:00:05.95 bitrate=13765.4kbits/s speed=2.96x    ^Mframe=  168 fps= 67 q=-0.0 size=   14529kB time=00:00:07.25 bitrate=16408.9kbits/s speed=2.89x    ^Mframe=  200 fps= 66 q=-0.0 size=   19871kB time=00:00:08.59 bitrate=18933.9kbits/s speed=2.85x    ^Mframe=  249 fps= 71 q=-0.0 size=   22356kB time=00:00:10.66 bitrate=17169.2kbits/s speed=3.04x    ^Mframe=  309 fps= 77 q=-0.0 size=   26447kB time=00:00:13.14 bitrate=16486.2kbits/s speed=3.27x    ^Mframe=  352 fps= 78 q=-0.0 size=   33772kB time=00:00:14.95 bitrate=18499.8kbits/s speed=3.31x    ^Mframe=  407 fps= 81 q=-0.0 size=   39582kB time=00:00:17.21 bitrate=18834.4kbits/s speed=3.43x    ^Mframe=  458 fps= 83 q=-0.0 size=   45657kB time=00:00:19.37 bitrate=19308.7kbits/s speed=3.51x    ^Mframe=  499 fps= 83 q=-0.0 size=   55653kB time=00:00:21.07 bitrate=21630.4kbits/s speed= 3.5x    ^Mframe=  551 fps= 84 q=-0.0 size=   64440kB time=00:00:23.21 bitrate=22743.6kbits/s speed=3.56x    ^Mframe=  595 fps= 85 q=-0.0 size=   74299kB time=00:00:25.06 bitrate=24281.6kbits/s speed=3.56x    ^Mframe=  640 fps= 85 q=-0.0 size=   83697kB time=00:00:26.94 bitrate=25447.0kbits/s speed=3.58x    ^Mframe=  695 fps= 86 q=-0.0 size=   90978kB time=00:00:29.24 bitrate=25481.7kbits/s speed=3.64x    ^Mframe=  741 fps= 87 q=-0.0 size=  100310kB time=00:00:31.12 bitrate=26401.1kbits/s speed=3.64x    ^Mframe=  789 fps= 87 q=-0.0 size=  107524kB time=00:00:33.13 bitrate=26586.7kbits/s speed=3.67x    ^Mframe=  844 fps= 88 q=-0.0 size=  114773kB time=00:00:35.45 bitrate=26517.9kbits/s speed=3.71x    ^Mframe=  899 fps= 89 q=-0.0 size=  120878kB time=00:00:37.73 bitrate=26239.1kbits/s speed=3.76x    ^Mframe=  948 fps= 90 q=-0.0 size=  127485kB time=00:00:39.78 bitrate=26248.8kbits/s speed=3.77x    ^Mframe= 1000 fps= 90 q=-0.0 size=  133913kB time=00:00:41.96 bitrate=26142.7kbits/s speed= 3.8x    ^Mframe= 1069 fps= 93 q=-0.0 size=  135436kB time=00:00:44.80 bitrate=24765.5kbits/s speed=3.88x    ^Mframe= 1144 fps= 95 q=-0.0 size=  136373kB time=00:00:47.93 bitrate=23305.5kbits/s speed=3.98x    ^Mframe= 1225 fps= 98 q=-0.0 size=  136968kB time=00:00:51.32 bitrate=21860.2kbits/s speed=4.09x    ^M[h264_v4l2m2m @ 0x71ec0] No event occurred while waiting
frame= 1253 fps= 98 q=-0.0 Lsize=  137018kB time=00:00:52.25 bitrate=21482.3kbits/s speed=4.07x
video:136173kB audio:817kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.019993%
[aac @ 0x72e00] Qavg: 659.826

the original patches are already in my repo, based on ffmpeg 2.8.2 (from ubuntu 16.04)
@oversun's patch is 1 line of code :)
and i am now running all on ffmpeg 3.x from ubuntu 16.10... i will push those patches after i fix a few more things (e.g. currently the decoder/encoder grabs the first device it finds, so the decoder may grab the encoder and fail, or the gstreamer, etc... :D)

EDIT: also a divx to h264 encoding: http://paste.debian.net/794630/
@memeka: I am trying to replicate hardware encoding with your FFmpeg branch, but I wasn't able to compile support for the hardware encoder. Here's how I compiled ffmpeg:

Code: Select all

#get the patched ffmpeg version
$ git clone --depth 1 https://github.com/mihailescu2m/FFmpeg.git
#install ffmpeg dependencies so it can build
$ sudo apt-get build-dep ffmpeg
$ sudo apt-get install libv4l-0 libv4l-dev
$ cd FFmpeg
$ ./configure --prefix=/usr/local --extra-version=memeka1 --build-suffix=-ffmpeg --toolchain=hardened --libdir=/usr/lib/arm-linux-gnueabihf --incdir=/usr/include/arm-linux-gnueabihf --cc=cc --cxx=g++ --enable-gpl --enable-shared --disable-stripping --disable-decoder=libopenjpeg --disable-decoder=libschroedinger --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-librtmp --enable-libschroedinger --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxvid --enable-libzvbi --enable-openal --enable-opengl --enable-x11grab --enable-libdc1394 --enable-libiec61883 --enable-libzmq --enable-frei0r --enable-libx264 --enable-libopencv --enable-libv4l2
$ make -j 4
$ sudo make install
FFmpeg compiled fine and works, but does software encoding (@19fps) and it complains when called with -vcodec h264_v4l2m2m.

Code: Select all

Unknown encoder 'h264_v4l2m2m'
I guess I need to enable something extra in configure, but I couldn't find any reference to h264_v4lm2m.
[/code]
which branch of ffmpeg did you use?
you can look at my compile options here: https://github.com/mihailescu2m/FFmpeg/ ... bian/rules
(or https://github.com/mihailescu2m/FFmpeg/ ... bian/rules)

User avatar
memeka
Posts: 4244
Joined: Mon May 20, 2013 10:22 am
languages_spoken: english
ODROIDs: XU rev2 + eMMC + UART
U3 + eMMC + IO Shield + UART
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by memeka » Sat Oct 22, 2016 11:15 am

* BL_SWITCHER - worst of them all
* HMP - best, performance is great (hungry processes go to A15, background processes go to A7). BUT on very heavy loads/many threads (e.g. compile large sources) it will crash kernel.
* none selected - second best, you get 8 cores and threads are randomly distributed. for best results, assign manually processes to cores.

User avatar
memeka
Posts: 4244
Joined: Mon May 20, 2013 10:22 am
languages_spoken: english
ODROIDs: XU rev2 + eMMC + UART
U3 + eMMC + IO Shield + UART
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by memeka » Sat Oct 22, 2016 11:21 am

configs: there should be a pastebin somewhere with my config, that contains the settings for Mali, for those that want graphics.

many thanks to @elatllat for keeping my branch updated. I was away for a while :)
I will start looking at 4.9, which is going to be the next LTS. I think Samsung had some USB3 patches queued for 4.9 too.

User avatar
rooted
Posts: 6440
Joined: Fri Dec 19, 2014 9:12 am
languages_spoken: english
Location: Gulf of Mexico, US
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by rooted » Sat Oct 22, 2016 12:36 pm

memeka wrote:* BL_SWITCHER - worst of them all
* HMP - best, performance is great (hungry processes go to A15, background processes go to A7). BUT on very heavy loads/many threads (e.g. compile large sources) it will crash kernel.
* none selected - second best, you get 8 cores and threads are randomly distributed. for best results, assign manually processes to cores.
100%

elatllat
Posts: 1190
Joined: Tue Sep 01, 2015 8:54 am
languages_spoken: english
ODROIDs: XU4, N1
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by elatllat » Sat Oct 22, 2016 2:02 pm

memeka wrote:...my config...
I merged that into arch/arm/configs/odroidxu4_defconfig
memeka wrote:...thanks to @elatllat for keeping my branch updated...
your welcome.
memeka wrote:...Samsung had some USB3 patches queued for 4.9 too.
Someone might want to merge your and tobetters drivers/usb/host/xhci-plat.c first...

User avatar
mad_ady
Posts: 5454
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by mad_ady » Sat Oct 22, 2016 3:34 pm

@memeka: it was the correct repo, but not the m2m branch. I will try again on monday, thank you. So building it as a debian package should work, right?

User avatar
memeka
Posts: 4244
Joined: Mon May 20, 2013 10:22 am
languages_spoken: english
ODROIDs: XU rev2 + eMMC + UART
U3 + eMMC + IO Shield + UART
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by memeka » Sat Oct 22, 2016 8:52 pm

mad_ady wrote:@memeka: it was the correct repo, but not the m2m branch. I will try again on monday, thank you. So building it as a debian package should work, right?
yes

elatllat
Posts: 1190
Joined: Tue Sep 01, 2015 8:54 am
languages_spoken: english
ODROIDs: XU4, N1
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by elatllat » Sun Oct 23, 2016 4:14 am

4.8.4 merged into odroidxu4 tobetter and mihailescu2m branches.

User avatar
rooted
Posts: 6440
Joined: Fri Dec 19, 2014 9:12 am
languages_spoken: english
Location: Gulf of Mexico, US
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by rooted » Sun Oct 23, 2016 7:03 am

elatllat wrote:4.8.4 merged into odroidxu4 tobetter and mihailescu2m branches.
Just pulled memeka branch down and tried to compile with odroidxu4_defconfig but still errors out on the mali display driver (exynos5422) and if HMP is going to be enabled by default the masks need to be added (F0 and 0F).

*edit*
Got defconfig to work with mali, just needed to make clean.

I added to my pull request to tobetter's branch, RTC must be built in for system time to get updated at boot from RTC, I just tested this and mentioned it earlier.

So.

CONFIG_RTC_DRV_S5M=m

has to be

CONFIG_RTC_DRV_S5M=y

Giving my other changes a good days testing and will create a full pull request to your memeka (mihailescu2m) branch.

elatllat
Posts: 1190
Joined: Tue Sep 01, 2015 8:54 am
languages_spoken: english
ODROIDs: XU4, N1
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by elatllat » Sun Oct 23, 2016 4:41 pm

rooted wrote:...CONFIG_RTC_DRV_S5M=y...
merged.

User avatar
mad_ady
Posts: 5454
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by mad_ady » Tue Oct 25, 2016 3:58 pm

@memeka: I tried to build ffmpeg with these steps, but it fails near the end in the testing phase:

Code: Select all

#debian build tools
$ sudo apt-get install build-essential fakeroot devscripts
#get the patched ffmpeg version
$ git clone -b v4l2_m2m-3.0.2 --depth=1 https://github.com/mihailescu2m/FFmpeg.git
#install ffmpeg dependencies so it can build
$ sudo apt-get build-dep ffmpeg
$ sudo apt-get install libchromaprint-dev librubberband-dev
$ cd FFmpeg
$ debuild -b -uc -us
... output ommited ...
/home/adrianp/development/FFmpeg/tests/fate-run.sh fate-utvideoenc_yuv422_median "" "" "/home/adrianp/development/FFmpeg/debian/standard" 'framemd5 -f image2 -vcodec pgmyuv -i /home/adrianp/development/FFmpe
g/debian/standard/tests/vsynth1/%02d.pgm -vcodec utvideo -slices 1 -sws_flags +accurate_rnd+bitexact -pix_fmt yuv422p -pred median' '' '' '' '1' '' '' '' '' '' '' '' ''
 /home/adrianp/development/FFmpeg/debian/standard/ffmpeg -nostdin -nostats -cpuflags all -f image2 -vcodec pgmyuv -hwaccel none -threads 1 -thread_type frame+slice -i /home/adrianp/development/FFmpeg/debian/
standard/tests/vsynth1/%02d.pgm -vcodec utvideo -slices 1 -sws_flags +accurate_rnd+bitexact -pix_fmt yuv422p -pred median -flags +bitexact -fflags +bitexact -f framemd5 -
TEST    utvideoenc_yuv422_none
/home/adrianp/development/FFmpeg/tests/fate-run.sh fate-utvideoenc_yuv422_none "" "" "/home/adrianp/development/FFmpeg/debian/standard" 'framemd5 -f image2 -vcodec pgmyuv -i /home/adrianp/development/FFmpeg/
debian/standard/tests/vsynth1/%02d.pgm -vcodec utvideo -slices 1 -sws_flags +accurate_rnd+bitexact -pix_fmt yuv422p -pred none' '' '' '' '1' '' '' '' '' '' '' '' ''
 /home/adrianp/development/FFmpeg/debian/standard/ffmpeg -nostdin -nostats -cpuflags all -f image2 -vcodec pgmyuv -hwaccel none -threads 1 -thread_type frame+slice -i /home/adrianp/development/FFmpeg/debian/
standard/tests/vsynth1/%02d.pgm -vcodec utvideo -slices 1 -sws_flags +accurate_rnd+bitexact -pix_fmt yuv422p -pred none -flags +bitexact -fflags +bitexact -f framemd5 -
cp -f /home/adrianp/development/FFmpeg/tests/test.ffmeta tests/test_copy.ffmeta
/home/adrianp/development/FFmpeg/debian/standard/ffmpeg \
        -f lavfi -i "aevalsrc=sin(400*PI*2*t):d=0.125[out0]; testsrc=d=0.125[out1]; testsrc=s=100x100:d=0.125[out2]" \
        -f ffmetadata -i /home/adrianp/development/FFmpeg/debian/standard/tests/test_copy.ffmeta \
        -flags +bitexact -fflags +bitexact -map 0:0 -map 0:1 -map 0:2 -map_metadata 1 \
        -map_metadata:s:0 1:s:0 -map_metadata:s:1 1:s:1 \
        -vcodec rawvideo -acodec pcm_s16le \
        -y /home/adrianp/development/FFmpeg/debian/standard/tests/data/ffprobe-test.nut 2>/dev/null
TEST    ffprobe_compact
/home/adrianp/development/FFmpeg/tests/fate-run.sh fate-ffprobe_compact "" "" "/home/adrianp/development/FFmpeg/debian/standard" 'run ffprobe -show_streams -show_packets -show_format -show_frames -bitexact t
ests/data/ffprobe-test.nut -of compact' '' '' '' '1' '' '' '' '' '' '' '' ''
 /home/adrianp/development/FFmpeg/debian/standard/ffprobe -show_streams -show_packets -show_format -show_frames -bitexact tests/data/ffprobe-test.nut -of compact
TEST    ffprobe_csv
/home/adrianp/development/FFmpeg/tests/fate-run.sh fate-ffprobe_csv "" "" "/home/adrianp/development/FFmpeg/debian/standard" 'run ffprobe -show_streams -show_packets -show_format -show_frames -bitexact tests
/data/ffprobe-test.nut -of csv' '' '' '' '1' '' '' '' '' '' '' '' ''
 /home/adrianp/development/FFmpeg/debian/standard/ffprobe -show_streams -show_packets -show_format -show_frames -bitexact tests/data/ffprobe-test.nut -of csv
TEST    ffprobe_default
/home/adrianp/development/FFmpeg/tests/fate-run.sh fate-ffprobe_default "" "" "/home/adrianp/development/FFmpeg/debian/standard" 'run ffprobe -show_streams -show_packets -show_format -show_frames -bitexact t
ests/data/ffprobe-test.nut -of default' '' '' '' '1' '' '' '' '' '' '' '' ''
 /home/adrianp/development/FFmpeg/debian/standard/ffprobe -show_streams -show_packets -show_format -show_frames -bitexact tests/data/ffprobe-test.nut -of default
TEST    ffprobe_flat
/home/adrianp/development/FFmpeg/tests/fate-run.sh fate-ffprobe_flat "" "" "/home/adrianp/development/FFmpeg/debian/standard" 'run ffprobe -show_streams -show_packets -show_format -show_frames -bitexact test
s/data/ffprobe-test.nut -of flat' '' '' '' '1' '' '' '' '' '' '' '' ''
 /home/adrianp/development/FFmpeg/debian/standard/ffprobe -show_streams -show_packets -show_format -show_frames -bitexact tests/data/ffprobe-test.nut -of flat
TEST    ffprobe_ini
/home/adrianp/development/FFmpeg/tests/fate-run.sh fate-ffprobe_ini "" "" "/home/adrianp/development/FFmpeg/debian/standard" 'run ffprobe -show_streams -show_packets -show_format -show_frames -bitexact tests
/data/ffprobe-test.nut -of ini' '' '' '' '1' '' '' '' '' '' '' '' ''
 /home/adrianp/development/FFmpeg/debian/standard/ffprobe -show_streams -show_packets -show_format -show_frames -bitexact tests/data/ffprobe-test.nut -of ini
TEST    ffprobe_json
/home/adrianp/development/FFmpeg/tests/fate-run.sh fate-ffprobe_json "" "" "/home/adrianp/development/FFmpeg/debian/standard" 'run ffprobe -show_streams -show_packets -show_format -show_frames -bitexact test
s/data/ffprobe-test.nut -of json' '' '' '' '1' '' '' '' '' '' '' '' ''
 /home/adrianp/development/FFmpeg/debian/standard/ffprobe -show_streams -show_packets -show_format -show_frames -bitexact tests/data/ffprobe-test.nut -of json
TEST    ffprobe_xml
/home/adrianp/development/FFmpeg/tests/fate-run.sh fate-ffprobe_xml "" "" "/home/adrianp/development/FFmpeg/debian/standard" 'run ffprobe -show_streams -show_packets -show_format -show_frames -bitexact tests
/data/ffprobe-test.nut -of xml' '' '' '' '1' '' '' '' '' '' '' '' ''
 /home/adrianp/development/FFmpeg/debian/standard/ffprobe -show_streams -show_packets -show_format -show_frames -bitexact tests/data/ffprobe-test.nut -of xml
make[2]: Target 'check' not remade because of errors.
make[2]: Leaving directory '/home/adrianp/development/FFmpeg/debian/standard'
dh_auto_test: make -j1 check -k returned exit code 2
debian/rules:229: recipe for target 'override_dh_auto_test-arch' failed
make[1]: *** [override_dh_auto_test-arch] Error 2
make[1]: Leaving directory '/home/adrianp/development/FFmpeg'
debian/rules:189: recipe for target 'build' failed
make: *** [build] Error 2
dpkg-buildpackage: error: debian/rules build gave error exit status 2
debuild: fatal error at line 1376:
dpkg-buildpackage -rfakeroot -D -us -uc -b failed
adrianp@odroid:~/development/FFmpeg> file /home/adrianp/development/FFmpeg/debian/standard/ffmpeg
/home/adrianp/development/FFmpeg/debian/standard/ffmpeg: ELF 32-bit LSB executable, ARM, EABI5 version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux-armhf.so.3, for GNU/Linux 3.2.0, BuildID[sha1]=8ba97b73122ce16c28f487ac99d59624c572ae8c, not stripped

So, it built but failed some tests. Is there a way to skip tests and package it anyway? Do I have to edit anything in the debian/rules file?

Edit: also, it seems the defconfig lacks more advanced iptables support needed for lxc (and more advanced firewalls):

Code: Select all

Oct 24 16:03:43 odroid lxc-net[10832]: modprobe: FATAL: Module ip_tables not found in directory /lib/modules/4.8.3-dmole-memeka-1+
Oct 24 16:03:43 odroid lxc-net[10832]: iptables v1.6.0: can't initialize iptables table `nat': Table does not exist (do you need to insmod?)
Oct 24 16:03:43 odroid lxc-net[10832]: Perhaps iptables or your kernel needs to be upgraded.
Oct 24 16:03:43 odroid lxc-net[10832]: modprobe: FATAL: Module ip_tables not found in directory /lib/modules/4.8.3-dmole-memeka-1+
Oct 24 16:03:43 odroid lxc-net[10832]: iptables v1.6.0: can't initialize iptables table `mangle': Table does not exist (do you need to insmod?)
Oct 24 16:03:43 odroid lxc-net[10832]: Perhaps iptables or your kernel needs to be upgraded.

I'll see if I can create a list of features found in the original 3.10 kernel that are missing from this one.

User avatar
rooted
Posts: 6440
Joined: Fri Dec 19, 2014 9:12 am
languages_spoken: english
Location: Gulf of Mexico, US
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by rooted » Tue Oct 25, 2016 4:06 pm

@mad_ady
I am as interested in getting h264 HW encoding working but ffmpeg is outside the scope of this thread, could you start a new thread? I will participate there as well since I need this also.

User avatar
mad_ady
Posts: 5454
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by mad_ady » Tue Oct 25, 2016 4:35 pm

Edit: I'm running 4.8.4 without HMP and I'm getting lockups due to spinlock:

Code: Select all

[  440.950177] BUG: spinlock lockup suspected on CPU#1, migration/1/18
[  440.954994]  lock: 0xeede5c40, .magic: dead4ead, .owner: migration/4/39, .owner_cpu: 4
[  440.962869] CPU: 1 PID: 18 Comm: migration/1 Tainted: G      D         4.8.4-dmole-memeka-2-gd9d64b8 #1
[  440.972219] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[  440.978318] [<c010eaac>] (unwind_backtrace) from [<c010b200>] (show_stack+0x10/0x14)
[  440.986007] [<c010b200>] (show_stack) from [<c04226b0>] (dump_stack+0x78/0x8c)
[  440.993198] [<c04226b0>] (dump_stack) from [<c01674a0>] (do_raw_spin_lock+0xfc/0x1d8)
[  441.000993] [<c01674a0>] (do_raw_spin_lock) from [<c01441b4>] (move_queued_task+0xcc/0x19c)
[  441.009312] [<c01441b4>] (move_queued_task) from [<c0144e48>] (migration_cpu_stop+0x9c/0xa4)
[  441.017740] [<c0144e48>] (migration_cpu_stop) from [<c01abe40>] (cpu_stopper_thread+0x8c/0x110)
[  441.026400] [<c01abe40>] (cpu_stopper_thread) from [<c013f13c>] (smpboot_thread_fn+0x160/0x284)
[  441.035050] [<c013f13c>] (smpboot_thread_fn) from [<c013bfa0>] (kthread+0xdc/0xf4)
[  441.042588] [<c013bfa0>] (kthread) from [<c01077f8>] (ret_from_fork+0x14/0x3c)
[  441.049777] Sending NMI to all CPUs:
[  441.053328] NMI backtrace for cpu 1
[  441.056796] CPU: 1 PID: 18 Comm: migration/1 Tainted: G      D         4.8.4-dmole-memeka-2-gd9d64b8 #1
[  441.066151] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[  441.072225] [<c010eaac>] (unwind_backtrace) from [<c010b200>] (show_stack+0x10/0x14)
[  441.079935] [<c010b200>] (show_stack) from [<c04226b0>] (dump_stack+0x78/0x8c)
[  441.087133] [<c04226b0>] (dump_stack) from [<c0426a88>] (nmi_cpu_backtrace+0x78/0x7c)
[  441.094927] [<c0426a88>] (nmi_cpu_backtrace) from [<c010cf2c>] (raise_nmi+0x60/0x64)
[  441.102638] [<c010cf2c>] (raise_nmi) from [<c0426a08>] (nmi_trigger_all_cpu_backtrace+0x128/0x130)
[  441.111564] [<c0426a08>] (nmi_trigger_all_cpu_backtrace) from [<c01674a8>] (do_raw_spin_lock+0x104/0x1d8)
[  441.121095] [<c01674a8>] (do_raw_spin_lock) from [<c01441b4>] (move_queued_task+0xcc/0x19c)
[  441.129413] [<c01441b4>] (move_queued_task) from [<c0144e48>] (migration_cpu_stop+0x9c/0xa4)
[  441.137820] [<c0144e48>] (migration_cpu_stop) from [<c01abe40>] (cpu_stopper_thread+0x8c/0x110)
[  441.146486] [<c01abe40>] (cpu_stopper_thread) from [<c013f13c>] (smpboot_thread_fn+0x160/0x284)
[  441.155150] [<c013f13c>] (smpboot_thread_fn) from [<c013bfa0>] (kthread+0xdc/0xf4)
[  441.162689] [<c013bfa0>] (kthread) from [<c01077f8>] (ret_from_fork+0x14/0x3c)
[  441.170067] NMI backtrace for cpu 0
[  441.173346] CPU: 0 PID: 0 Comm: swapper/0 Tainted: G      D         4.8.4-dmole-memeka-2-gd9d64b8 #1
[  441.182441] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[  441.188506] task: c0c05c80 task.stack: c0c00000
[  441.193012] PC is at arch_cpu_idle+0x38/0x3c
[  441.197258] LR is at arch_cpu_idle+0x34/0x3c
[  441.201505] pc : [<c0108238>]    lr : [<c0108234>]    psr: 600f0013
[  441.207744] sp : c0c01fa0  ip : f0806340  fp : c0c02510
[  441.212943] r10: c0c02504  r9 : c0b69178  r8 : 00000000
[  441.218142] r7 : 00000000  r6 : 00000001  r5 : c0c0249c  r4 : c0c00000
[  441.224641] r3 : c0119a80  r2 : 00000000  r1 : 00000000  r0 : 00000001
[  441.231141] Flags: nZCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment none
[  441.238246] Control: 10c5387d  Table: 6b22406a  DAC: 00000051
[  441.243966] CPU: 0 PID: 0 Comm: swapper/0 Tainted: G      D         4.8.4-dmole-memeka-2-gd9d64b8 #1
[  441.253064] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[  441.259130] [<c010eaac>] (unwind_backtrace) from [<c010b200>] (show_stack+0x10/0x14)
[  441.266843] [<c010b200>] (show_stack) from [<c04226b0>] (dump_stack+0x78/0x8c)
[  441.274034] [<c04226b0>] (dump_stack) from [<c0426a6c>] (nmi_cpu_backtrace+0x5c/0x7c)
[  441.281833] [<c0426a6c>] (nmi_cpu_backtrace) from [<c010d7d8>] (handle_IPI+0xd8/0x1ac)
[  441.289719] [<c010d7d8>] (handle_IPI) from [<c0101500>] (gic_handle_irq+0x94/0x98)
[  441.297258] [<c0101500>] (gic_handle_irq) from [<c010bd4c>] (__irq_svc+0x6c/0xa8)
[  441.304710] Exception stack(0xc0c01f50 to 0xc0c01f98)
[  441.309736] 1f40:                                     00000001 00000000 00000000 c0119a80
[  441.317881] 1f60: c0c00000 c0c0249c 00000001 00000000 00000000 c0b69178 c0c02504 c0c02510
[  441.326027] 1f80: f0806340 c0c01fa0 c0108234 c0108238 600f0013 ffffffff
[  441.332612] [<c010bd4c>] (__irq_svc) from [<c0108238>] (arch_cpu_idle+0x38/0x3c)
[  441.339979] [<c0108238>] (arch_cpu_idle) from [<c015fe34>] (cpu_startup_entry+0x1cc/0x248)
[  441.348210] [<c015fe34>] (cpu_startup_entry) from [<c0b00c84>] (start_kernel+0x39c/0x3a8)
[  449.118338] INFO: rcu_preempt detected stalls on CPUs/tasks:
[  449.122542]  3-...: (0 ticks this GP) idle=f9f/140000000000000/0 softirq=8417/8417 fqs=13190 last_accelerate: 019a/7480, nonlazy_posted: 1, ..
[  449.135272]  4-...: (0 ticks this GP) idle=d37/140000000000001/0 softirq=3014/3014 fqs=13190 last_accelerate: 0199/7480, nonlazy_posted: 0, ..
[  449.148008]  6-...: (0 ticks this GP) idle=72d/140000000000000/0 softirq=1231/1231 fqs=13190 last_accelerate: 019a/7480, nonlazy_posted: 0, ..
[  449.160739]  (detected by 0, t=29415 jiffies, g=7904, c=7903, q=1732)
[  449.167154] Task dump for CPU 3:
[  449.170359] systemd-udevd   R running      0  6930    375 0x00000002
[  449.176731] [<c07aaccc>] (__schedule) from [<c010b1a4>] (dump_backtrace_entry+0x2c/0x78)
[  449.184751] [<c010b1a4>] (dump_backtrace_entry) from [<20000093>] (0x20000093)
[  449.191935] Task dump for CPU 4:
[  449.195141] migration/4     R running      0    39      2 0x00000000
[  449.201473] [<c07aaccc>] (__schedule) from [<00000004>] (0x4)
[  449.207186] Task dump for CPU 6:
[  449.210392] migration/6     S c07aaccc     0    53      2 0x00000000
[  449.216725] [<c07aaccc>] (__schedule) from [<c07ab11c>] (schedule+0x4c/0xac)
[  449.223747] [<c07ab11c>] (schedule) from [<c013f0e4>] (smpboot_thread_fn+0x108/0x284)
[  449.231542] [<c013f0e4>] (smpboot_thread_fn) from [<c013bfa0>] (kthread+0xdc/0xf4)
[  449.239080] [<c013bfa0>] (kthread) from [<c01077f8>] (ret_from_fork+0x14/0x3c)
[  449.246274] rcu_preempt kthread starved for 2897 jiffies! g7904 c7903 f0x0 RCU_GP_WAIT_FQS(3) ->state=0x1
[  449.255798] rcu_preempt     S c07aaccc     0     7      2 0x00000000
[  449.262132] [<c07aaccc>] (__schedule) from [<c07ab11c>] (schedule+0x4c/0xac)
[  449.269151] [<c07ab11c>] (schedule) from [<c07af348>] (schedule_timeout+0x150/0x24c)
[  449.276864] [<c07af348>] (schedule_timeout) from [<c017bef8>] (rcu_gp_kthread+0x670/0x9ac)
[  449.285093] [<c017bef8>] (rcu_gp_kthread) from [<c013bfa0>] (kthread+0xdc/0xf4)
[  449.292372] [<c013bfa0>] (kthread) from [<c01077f8>] (ret_from_fork+0x14/0x3c)
[  489.910851] BUG: spinlock lockup suspected on CPU#0, systemd/1
[  489.915230]  lock: 0xe8bf7b1c, .magic: dead4ead, .owner: systemd-udevd/6937, .owner_cpu: 7
[  489.923450] CPU: 0 PID: 1 Comm: systemd Tainted: G      D         4.8.4-dmole-memeka-2-gd9d64b8 #1
[  489.932367] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[  489.938466] [<c010eaac>] (unwind_backtrace) from [<c010b200>] (show_stack+0x10/0x14)
[  489.946156] [<c010b200>] (show_stack) from [<c04226b0>] (dump_stack+0x78/0x8c)
[  489.953346] [<c04226b0>] (dump_stack) from [<c01674a0>] (do_raw_spin_lock+0xfc/0x1d8)
[  489.961144] [<c01674a0>] (do_raw_spin_lock) from [<c07afd38>] (_raw_spin_lock_irqsave+0x20/0x28)
[  489.969894] [<c07afd38>] (_raw_spin_lock_irqsave) from [<c01447c8>] (try_to_wake_up+0x2c/0x2a8)
[  489.978559] [<c01447c8>] (try_to_wake_up) from [<c0144ab8>] (wake_up_q+0x58/0x9c)
[  489.986012] [<c0144ab8>] (wake_up_q) from [<c07ae07c>] (__mutex_unlock_slowpath+0x124/0x1d4)
[  489.994418] [<c07ae07c>] (__mutex_unlock_slowpath) from [<c0280664>] (kernfs_iop_permission+0x3c/0x54)
[  490.003690] [<c0280664>] (kernfs_iop_permission) from [<c0227e08>] (__inode_permission+0x8c/0xe8)
[  490.012528] [<c0227e08>] (__inode_permission) from [<c0228bd8>] (link_path_walk+0x68/0x4ac)
[  490.020846] [<c0228bd8>] (link_path_walk) from [<c022a004>] (path_openat+0x7c/0xed8)
[  490.028559] [<c022a004>] (path_openat) from [<c022bf6c>] (do_filp_open+0x60/0xc4)
[  490.036014] [<c022bf6c>] (do_filp_open) from [<c021bc3c>] (do_sys_open+0x114/0x1c4)
[  490.043638] [<c021bc3c>] (do_sys_open) from [<c0107740>] (ret_fast_syscall+0x0/0x3c)
[  490.051346] Sending NMI to all CPUs:
[  490.054897] NMI backtrace for cpu 0
[  490.058366] CPU: 0 PID: 1 Comm: systemd Tainted: G      D         4.8.4-dmole-memeka-2-gd9d64b8 #1
[  490.067288] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[  490.073361] [<c010eaac>] (unwind_backtrace) from [<c010b200>] (show_stack+0x10/0x14)
[  490.081072] [<c010b200>] (show_stack) from [<c04226b0>] (dump_stack+0x78/0x8c)
[  490.088265] [<c04226b0>] (dump_stack) from [<c0426a88>] (nmi_cpu_backtrace+0x78/0x7c)
[  490.096063] [<c0426a88>] (nmi_cpu_backtrace) from [<c010cf2c>] (raise_nmi+0x60/0x64)
[  490.103775] [<c010cf2c>] (raise_nmi) from [<c0426a08>] (nmi_trigger_all_cpu_backtrace+0x128/0x130)
[  490.112700] [<c0426a08>] (nmi_trigger_all_cpu_backtrace) from [<c01674a8>] (do_raw_spin_lock+0x104/0x1d8)
[  490.122232] [<c01674a8>] (do_raw_spin_lock) from [<c07afd38>] (_raw_spin_lock_irqsave+0x20/0x28)
[  490.130984] [<c07afd38>] (_raw_spin_lock_irqsave) from [<c01447c8>] (try_to_wake_up+0x2c/0x2a8)
[  490.139649] [<c01447c8>] (try_to_wake_up) from [<c0144ab8>] (wake_up_q+0x58/0x9c)
[  490.147101] [<c0144ab8>] (wake_up_q) from [<c07ae07c>] (__mutex_unlock_slowpath+0x124/0x1d4)
[  490.155507] [<c07ae07c>] (__mutex_unlock_slowpath) from [<c0280664>] (kernfs_iop_permission+0x3c/0x54)
[  490.164779] [<c0280664>] (kernfs_iop_permission) from [<c0227e08>] (__inode_permission+0x8c/0xe8)
[  490.173618] [<c0227e08>] (__inode_permission) from [<c0228bd8>] (link_path_walk+0x68/0x4ac)
[  490.181936] [<c0228bd8>] (link_path_walk) from [<c022a004>] (path_openat+0x7c/0xed8)
[  490.189648] [<c022a004>] (path_openat) from [<c022bf6c>] (do_filp_open+0x60/0xc4)
[  490.197101] [<c022bf6c>] (do_filp_open) from [<c021bc3c>] (do_sys_open+0x114/0x1c4)
[  490.204726] [<c021bc3c>] (do_sys_open) from [<c0107740>] (ret_fast_syscall+0x0/0x3c)
I am able to consistently reproduce the issue when I try to merge 3.10 defconfig into the current defconfig with this command:

Code: Select all

scripts/kconfig/merge_config.sh .config 3.10.defconfig | tee merge-output.txt
@rooted: Yes, that's a good idea. I'll start a new thread

User avatar
rooted
Posts: 6440
Joined: Fri Dec 19, 2014 9:12 am
languages_spoken: english
Location: Gulf of Mexico, US
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by rooted » Tue Oct 25, 2016 4:45 pm

How are you reproducing that? I'm running 4.9.0_rc2 and can try it on here.

User avatar
mad_ady
Posts: 5454
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by mad_ady » Tue Oct 25, 2016 4:50 pm

While in the kernel source directory try to merge the base config (generated by defconfig) with hardkernel's config for 3.10 - which you can wget from here: https://raw.githubusercontent.com/hardk ... _defconfig

Code: Select all

scripts/kconfig/merge_config.sh .config 3.10.defconfig | tee merge-output.txt
For me it locks up after a minute or so. Curiously, running sysbench was rock solid.

elatllat
Posts: 1190
Joined: Tue Sep 01, 2015 8:54 am
languages_spoken: english
ODROIDs: XU4, N1
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by elatllat » Tue Oct 25, 2016 7:07 pm

mad_ady wrote:...Edit: also, it seems the defconfig lacks more advanced iptables support needed for lxc (and more advanced firewalls):

Code: Select all

Oct 24 16:03:43 odroid lxc-net[10832]: modprobe: FATAL: Module ip_tables not found in directory /lib/modules/4.8.3-dmole-memeka-1+
Oct 24 16:03:43 odroid lxc-net[10832]: iptables v1.6.0: can't initialize iptables table `nat': Table does not exist (do you need to insmod?)
Oct 24 16:03:43 odroid lxc-net[10832]: Perhaps iptables or your kernel needs to be upgraded.
Oct 24 16:03:43 odroid lxc-net[10832]: modprobe: FATAL: Module ip_tables not found in directory /lib/modules/4.8.3-dmole-memeka-1+
Oct 24 16:03:43 odroid lxc-net[10832]: iptables v1.6.0: can't initialize iptables table `mangle': Table does not exist (do you need to insmod?)
Oct 24 16:03:43 odroid lxc-net[10832]: Perhaps iptables or your kernel needs to be upgraded.

I'll see if I can create a list of features found in the original 3.10 kernel that are missing from this one.
mad_ady wrote:Edit: I'm running 4.8.4 without HMP and I'm getting lockups due to spinlock:

Code: Select all

[  440.950177] BUG: spinlock lockup suspected on CPU#1, migration/1/18
[  440.954994]  lock: 0xeede5c40, .magic: dead4ead, .owner: migration/4/39, .owner_cpu: 4
[  440.962869] CPU: 1 PID: 18 Comm: migration/1 Tainted: G      D         4.8.4-dmole-memeka-2-gd9d64b8 #1
[  440.972219] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[  440.978318] [<c010eaac>] (unwind_backtrace) from [<c010b200>] (show_stack+0x10/0x14)
[  440.986007] [<c010b200>] (show_stack) from [<c04226b0>] (dump_stack+0x78/0x8c)
[  440.993198] [<c04226b0>] (dump_stack) from [<c01674a0>] (do_raw_spin_lock+0xfc/0x1d8)
[  441.000993] [<c01674a0>] (do_raw_spin_lock) from [<c01441b4>] (move_queued_task+0xcc/0x19c)
[  441.009312] [<c01441b4>] (move_queued_task) from [<c0144e48>] (migration_cpu_stop+0x9c/0xa4)
[  441.017740] [<c0144e48>] (migration_cpu_stop) from [<c01abe40>] (cpu_stopper_thread+0x8c/0x110)
[  441.026400] [<c01abe40>] (cpu_stopper_thread) from [<c013f13c>] (smpboot_thread_fn+0x160/0x284)
[  441.035050] [<c013f13c>] (smpboot_thread_fn) from [<c013bfa0>] (kthread+0xdc/0xf4)
[  441.042588] [<c013bfa0>] (kthread) from [<c01077f8>] (ret_from_fork+0x14/0x3c)
[  441.049777] Sending NMI to all CPUs:
[  441.053328] NMI backtrace for cpu 1
[  441.056796] CPU: 1 PID: 18 Comm: migration/1 Tainted: G      D         4.8.4-dmole-memeka-2-gd9d64b8 #1
[  441.066151] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[  441.072225] [<c010eaac>] (unwind_backtrace) from [<c010b200>] (show_stack+0x10/0x14)
[  441.079935] [<c010b200>] (show_stack) from [<c04226b0>] (dump_stack+0x78/0x8c)
[  441.087133] [<c04226b0>] (dump_stack) from [<c0426a88>] (nmi_cpu_backtrace+0x78/0x7c)
[  441.094927] [<c0426a88>] (nmi_cpu_backtrace) from [<c010cf2c>] (raise_nmi+0x60/0x64)
[  441.102638] [<c010cf2c>] (raise_nmi) from [<c0426a08>] (nmi_trigger_all_cpu_backtrace+0x128/0x130)
[  441.111564] [<c0426a08>] (nmi_trigger_all_cpu_backtrace) from [<c01674a8>] (do_raw_spin_lock+0x104/0x1d8)
[  441.121095] [<c01674a8>] (do_raw_spin_lock) from [<c01441b4>] (move_queued_task+0xcc/0x19c)
[  441.129413] [<c01441b4>] (move_queued_task) from [<c0144e48>] (migration_cpu_stop+0x9c/0xa4)
[  441.137820] [<c0144e48>] (migration_cpu_stop) from [<c01abe40>] (cpu_stopper_thread+0x8c/0x110)
[  441.146486] [<c01abe40>] (cpu_stopper_thread) from [<c013f13c>] (smpboot_thread_fn+0x160/0x284)
[  441.155150] [<c013f13c>] (smpboot_thread_fn) from [<c013bfa0>] (kthread+0xdc/0xf4)
[  441.162689] [<c013bfa0>] (kthread) from [<c01077f8>] (ret_from_fork+0x14/0x3c)
[  441.170067] NMI backtrace for cpu 0
[  441.173346] CPU: 0 PID: 0 Comm: swapper/0 Tainted: G      D         4.8.4-dmole-memeka-2-gd9d64b8 #1
[  441.182441] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[  441.188506] task: c0c05c80 task.stack: c0c00000
[  441.193012] PC is at arch_cpu_idle+0x38/0x3c
[  441.197258] LR is at arch_cpu_idle+0x34/0x3c
[  441.201505] pc : [<c0108238>]    lr : [<c0108234>]    psr: 600f0013
[  441.207744] sp : c0c01fa0  ip : f0806340  fp : c0c02510
[  441.212943] r10: c0c02504  r9 : c0b69178  r8 : 00000000
[  441.218142] r7 : 00000000  r6 : 00000001  r5 : c0c0249c  r4 : c0c00000
[  441.224641] r3 : c0119a80  r2 : 00000000  r1 : 00000000  r0 : 00000001
[  441.231141] Flags: nZCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment none
[  441.238246] Control: 10c5387d  Table: 6b22406a  DAC: 00000051
[  441.243966] CPU: 0 PID: 0 Comm: swapper/0 Tainted: G      D         4.8.4-dmole-memeka-2-gd9d64b8 #1
[  441.253064] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[  441.259130] [<c010eaac>] (unwind_backtrace) from [<c010b200>] (show_stack+0x10/0x14)
[  441.266843] [<c010b200>] (show_stack) from [<c04226b0>] (dump_stack+0x78/0x8c)
[  441.274034] [<c04226b0>] (dump_stack) from [<c0426a6c>] (nmi_cpu_backtrace+0x5c/0x7c)
[  441.281833] [<c0426a6c>] (nmi_cpu_backtrace) from [<c010d7d8>] (handle_IPI+0xd8/0x1ac)
[  441.289719] [<c010d7d8>] (handle_IPI) from [<c0101500>] (gic_handle_irq+0x94/0x98)
[  441.297258] [<c0101500>] (gic_handle_irq) from [<c010bd4c>] (__irq_svc+0x6c/0xa8)
[  441.304710] Exception stack(0xc0c01f50 to 0xc0c01f98)
[  441.309736] 1f40:                                     00000001 00000000 00000000 c0119a80
[  441.317881] 1f60: c0c00000 c0c0249c 00000001 00000000 00000000 c0b69178 c0c02504 c0c02510
[  441.326027] 1f80: f0806340 c0c01fa0 c0108234 c0108238 600f0013 ffffffff
[  441.332612] [<c010bd4c>] (__irq_svc) from [<c0108238>] (arch_cpu_idle+0x38/0x3c)
[  441.339979] [<c0108238>] (arch_cpu_idle) from [<c015fe34>] (cpu_startup_entry+0x1cc/0x248)
[  441.348210] [<c015fe34>] (cpu_startup_entry) from [<c0b00c84>] (start_kernel+0x39c/0x3a8)
[  449.118338] INFO: rcu_preempt detected stalls on CPUs/tasks:
[  449.122542]  3-...: (0 ticks this GP) idle=f9f/140000000000000/0 softirq=8417/8417 fqs=13190 last_accelerate: 019a/7480, nonlazy_posted: 1, ..
[  449.135272]  4-...: (0 ticks this GP) idle=d37/140000000000001/0 softirq=3014/3014 fqs=13190 last_accelerate: 0199/7480, nonlazy_posted: 0, ..
[  449.148008]  6-...: (0 ticks this GP) idle=72d/140000000000000/0 softirq=1231/1231 fqs=13190 last_accelerate: 019a/7480, nonlazy_posted: 0, ..
[  449.160739]  (detected by 0, t=29415 jiffies, g=7904, c=7903, q=1732)
[  449.167154] Task dump for CPU 3:
[  449.170359] systemd-udevd   R running      0  6930    375 0x00000002
[  449.176731] [<c07aaccc>] (__schedule) from [<c010b1a4>] (dump_backtrace_entry+0x2c/0x78)
[  449.184751] [<c010b1a4>] (dump_backtrace_entry) from [<20000093>] (0x20000093)
[  449.191935] Task dump for CPU 4:
[  449.195141] migration/4     R running      0    39      2 0x00000000
[  449.201473] [<c07aaccc>] (__schedule) from [<00000004>] (0x4)
[  449.207186] Task dump for CPU 6:
[  449.210392] migration/6     S c07aaccc     0    53      2 0x00000000
[  449.216725] [<c07aaccc>] (__schedule) from [<c07ab11c>] (schedule+0x4c/0xac)
[  449.223747] [<c07ab11c>] (schedule) from [<c013f0e4>] (smpboot_thread_fn+0x108/0x284)
[  449.231542] [<c013f0e4>] (smpboot_thread_fn) from [<c013bfa0>] (kthread+0xdc/0xf4)
[  449.239080] [<c013bfa0>] (kthread) from [<c01077f8>] (ret_from_fork+0x14/0x3c)
[  449.246274] rcu_preempt kthread starved for 2897 jiffies! g7904 c7903 f0x0 RCU_GP_WAIT_FQS(3) ->state=0x1
[  449.255798] rcu_preempt     S c07aaccc     0     7      2 0x00000000
[  449.262132] [<c07aaccc>] (__schedule) from [<c07ab11c>] (schedule+0x4c/0xac)
[  449.269151] [<c07ab11c>] (schedule) from [<c07af348>] (schedule_timeout+0x150/0x24c)
[  449.276864] [<c07af348>] (schedule_timeout) from [<c017bef8>] (rcu_gp_kthread+0x670/0x9ac)
[  449.285093] [<c017bef8>] (rcu_gp_kthread) from [<c013bfa0>] (kthread+0xdc/0xf4)
[  449.292372] [<c013bfa0>] (kthread) from [<c01077f8>] (ret_from_fork+0x14/0x3c)
[  489.910851] BUG: spinlock lockup suspected on CPU#0, systemd/1
[  489.915230]  lock: 0xe8bf7b1c, .magic: dead4ead, .owner: systemd-udevd/6937, .owner_cpu: 7
[  489.923450] CPU: 0 PID: 1 Comm: systemd Tainted: G      D         4.8.4-dmole-memeka-2-gd9d64b8 #1
[  489.932367] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[  489.938466] [<c010eaac>] (unwind_backtrace) from [<c010b200>] (show_stack+0x10/0x14)
[  489.946156] [<c010b200>] (show_stack) from [<c04226b0>] (dump_stack+0x78/0x8c)
[  489.953346] [<c04226b0>] (dump_stack) from [<c01674a0>] (do_raw_spin_lock+0xfc/0x1d8)
[  489.961144] [<c01674a0>] (do_raw_spin_lock) from [<c07afd38>] (_raw_spin_lock_irqsave+0x20/0x28)
[  489.969894] [<c07afd38>] (_raw_spin_lock_irqsave) from [<c01447c8>] (try_to_wake_up+0x2c/0x2a8)
[  489.978559] [<c01447c8>] (try_to_wake_up) from [<c0144ab8>] (wake_up_q+0x58/0x9c)
[  489.986012] [<c0144ab8>] (wake_up_q) from [<c07ae07c>] (__mutex_unlock_slowpath+0x124/0x1d4)
[  489.994418] [<c07ae07c>] (__mutex_unlock_slowpath) from [<c0280664>] (kernfs_iop_permission+0x3c/0x54)
[  490.003690] [<c0280664>] (kernfs_iop_permission) from [<c0227e08>] (__inode_permission+0x8c/0xe8)
[  490.012528] [<c0227e08>] (__inode_permission) from [<c0228bd8>] (link_path_walk+0x68/0x4ac)
[  490.020846] [<c0228bd8>] (link_path_walk) from [<c022a004>] (path_openat+0x7c/0xed8)
[  490.028559] [<c022a004>] (path_openat) from [<c022bf6c>] (do_filp_open+0x60/0xc4)
[  490.036014] [<c022bf6c>] (do_filp_open) from [<c021bc3c>] (do_sys_open+0x114/0x1c4)
[  490.043638] [<c021bc3c>] (do_sys_open) from [<c0107740>] (ret_fast_syscall+0x0/0x3c)
[  490.051346] Sending NMI to all CPUs:
[  490.054897] NMI backtrace for cpu 0
[  490.058366] CPU: 0 PID: 1 Comm: systemd Tainted: G      D         4.8.4-dmole-memeka-2-gd9d64b8 #1
[  490.067288] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[  490.073361] [<c010eaac>] (unwind_backtrace) from [<c010b200>] (show_stack+0x10/0x14)
[  490.081072] [<c010b200>] (show_stack) from [<c04226b0>] (dump_stack+0x78/0x8c)
[  490.088265] [<c04226b0>] (dump_stack) from [<c0426a88>] (nmi_cpu_backtrace+0x78/0x7c)
[  490.096063] [<c0426a88>] (nmi_cpu_backtrace) from [<c010cf2c>] (raise_nmi+0x60/0x64)
[  490.103775] [<c010cf2c>] (raise_nmi) from [<c0426a08>] (nmi_trigger_all_cpu_backtrace+0x128/0x130)
[  490.112700] [<c0426a08>] (nmi_trigger_all_cpu_backtrace) from [<c01674a8>] (do_raw_spin_lock+0x104/0x1d8)
[  490.122232] [<c01674a8>] (do_raw_spin_lock) from [<c07afd38>] (_raw_spin_lock_irqsave+0x20/0x28)
[  490.130984] [<c07afd38>] (_raw_spin_lock_irqsave) from [<c01447c8>] (try_to_wake_up+0x2c/0x2a8)
[  490.139649] [<c01447c8>] (try_to_wake_up) from [<c0144ab8>] (wake_up_q+0x58/0x9c)
[  490.147101] [<c0144ab8>] (wake_up_q) from [<c07ae07c>] (__mutex_unlock_slowpath+0x124/0x1d4)
[  490.155507] [<c07ae07c>] (__mutex_unlock_slowpath) from [<c0280664>] (kernfs_iop_permission+0x3c/0x54)
[  490.164779] [<c0280664>] (kernfs_iop_permission) from [<c0227e08>] (__inode_permission+0x8c/0xe8)
[  490.173618] [<c0227e08>] (__inode_permission) from [<c0228bd8>] (link_path_walk+0x68/0x4ac)
[  490.181936] [<c0228bd8>] (link_path_walk) from [<c022a004>] (path_openat+0x7c/0xed8)
[  490.189648] [<c022a004>] (path_openat) from [<c022bf6c>] (do_filp_open+0x60/0xc4)
[  490.197101] [<c022bf6c>] (do_filp_open) from [<c021bc3c>] (do_sys_open+0x114/0x1c4)
[  490.204726] [<c021bc3c>] (do_sys_open) from [<c0107740>] (ret_fast_syscall+0x0/0x3c)
I am able to consistently reproduce the issue when I try to merge 3.10 defconfig into the current defconfig with this command:

Code: Select all

scripts/kconfig/merge_config.sh .config 3.10.defconfig | tee merge-output.txt
...
I think that's a bug in merge_config.sh, maybe it's caused by referencing drivers that don't exist (from CONFIG_EXTRA_FIRMWARE, CONFIG_BACKPORT, or something). Anyway we can avoid by just merging another way;

Code: Select all

grep -vP "BACKPORT|CONFIG_EXTRA_FIRMWARE|#"  .config_odroidxu3-3.10.y > .config;
grep -v "#" ./arch/arm/configs/odroidxu4_defconfig >> .config 
make menuconfig # save and exit
diff ./arch/arm/configs/odroidxu4_defconfig .config
#981 options enabled 1 changed

User avatar
mad_ady
Posts: 5454
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by mad_ady » Tue Oct 25, 2016 10:30 pm

Wait - it seems HMP is on in the new defconfig - which explains the locks. @elatllat: is this correct?

Code: Select all

CONFIG_HPERF_HMP=y
CONFIG_HPERF_HMP_DEBUG=y
It should be off

elatllat
Posts: 1190
Joined: Tue Sep 01, 2015 8:54 am
languages_spoken: english
ODROIDs: XU4, N1
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by elatllat » Tue Oct 25, 2016 11:19 pm

mad_ady wrote: ...

Code: Select all

CONFIG_HPERF_HMP
should be off
Merged.

User avatar
rooted
Posts: 6440
Joined: Fri Dec 19, 2014 9:12 am
languages_spoken: english
Location: Gulf of Mexico, US
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by rooted » Wed Oct 26, 2016 12:48 am

I see mdrjr has created a 4.9 branch for the XU4, looks like we are finally getting official support soon.

https://github.com/mdrjr/linux

Pulling it down now.

I must say I'm impressed with 4.8/9 so far, not one single issue after running my configuration on 4.8 for 24 hours and 4.9 for 24 hours.

User avatar
Polypodiales
Posts: 26
Joined: Sun Oct 09, 2016 9:29 am
languages_spoken: english
ODROIDs: XU4
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by Polypodiales » Thu Oct 27, 2016 5:58 am

rooted wrote:I see mdrjr has created a 4.9 branch for the XU4, looks like we are finally getting official support soon.
Can we get an official confirmation on this? That would be just amazing~

elatllat
Posts: 1190
Joined: Tue Sep 01, 2015 8:54 am
languages_spoken: english
ODROIDs: XU4, N1
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by elatllat » Thu Oct 27, 2016 6:09 am

Polypodiales wrote:
rooted wrote:I see mdrjr has created a 4.9 branch for the XU4, looks like we are finally getting official support soon.
Can we get an official confirmation on this? That would be just amazing~
I'm sure they won't know until they are done testing and I'm sure they will let us know then.
I suspect HMP is unstable on 3.10 so If they have to re-write it or drop it they might as well aim for the latest LTS, assuming all of mihailescu2m's work is solid.

User avatar
rooted
Posts: 6440
Joined: Fri Dec 19, 2014 9:12 am
languages_spoken: english
Location: Gulf of Mexico, US
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by rooted » Thu Oct 27, 2016 6:39 am

Polypodiales wrote:
rooted wrote:I see mdrjr has created a 4.9 branch for the XU4, looks like we are finally getting official support soon.
Can we get an official confirmation on this? That would be just amazing~
When I said soon I meant perhaps this year, I didn't mean a week or two.

He is working on it, just follow the git.

User avatar
memeka
Posts: 4244
Joined: Mon May 20, 2013 10:22 am
languages_spoken: english
ODROIDs: XU rev2 + eMMC + UART
U3 + eMMC + IO Shield + UART
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by memeka » Thu Oct 27, 2016 8:42 am

mdrjr will probably be using the 4.9 kernel for exynos boards since it's going to be LTS.
also he probably won't be using my patches, esp. for Mali, since he will do his own integration with proper power management :) with mine, you can basically have only minimum or maximum performance on mali, no power gating, etc :D

NOW, SOME UPDATES ABOUT GNOME ON XU4-WAYLAND
==============================================

I got Gnome 3.22 working nicely on Debian Stretch. It was a bit difficult to port my patches from Gnome 3.20 (ubuntu yakkety) since mutter 3.22 has included forked and heavily modified versions of cogl and clutter. Also, Debian uses an older accountsservice package which prevents gnome reading users correctly => so gdm3 was not starting (cannot get list of users for login), gnome-control-center Users tab was empty, and you could not login back after the screensaver started. I had to port the Ubuntu version of that, too, but now all these issues are fixed. I also had to fix a gnome-plugins-good issue (with MFC), that was also crashing gnome-control-center.

The good news with Gnome 3.22 is that more apps work than in 3.20. The only app still having issues is gnome-maps, which works fine but crashes gnome when closing the app.

The bad news: recent versions of webkit-gtk don't render pages. This issue I found a while ago, before release, and filed this bug: https://bugs.webkit.org/show_bug.cgi?id=161599 - but webkit was released without a fix for it. So to have epiphany & co working, you need to install some older version of webkit. A reminder: webkit actually uses gstreamer (MFC) to decode videos, so it's hw-accelerated. BUT the older version does not have EGL support, so actually the videos are rendered poorly, and only 320p windowed playback is useful. The recent webkit supports EGL VIDEO acceleration, but like I said, pages don't render at all atm.

User avatar
rooted
Posts: 6440
Joined: Fri Dec 19, 2014 9:12 am
languages_spoken: english
Location: Gulf of Mexico, US
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by rooted » Thu Oct 27, 2016 9:42 am

Thumbs up meveric.

User avatar
odroid
Site Admin
Posts: 30052
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by odroid » Thu Oct 27, 2016 3:04 pm

rooted wrote:Thumbs up meveric.
Do you mean "memeka"? :mrgreen:

User avatar
rooted
Posts: 6440
Joined: Fri Dec 19, 2014 9:12 am
languages_spoken: english
Location: Gulf of Mexico, US
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by rooted » Thu Oct 27, 2016 10:45 pm

odroid wrote:
rooted wrote:Thumbs up meveric.
Do you mean "memeka"? :mrgreen:
yep, that's what happens when you post without sleep :)

oops

elatllat
Posts: 1190
Joined: Tue Sep 01, 2015 8:54 am
languages_spoken: english
ODROIDs: XU4, N1
Contact:

Re: Odroid XU3/XU4 NEXT thread

Unread post by elatllat » Sat Oct 29, 2016 5:41 pm

4.8.5 merged into odroidxu4 tobetter and mihailescu2m branches.
Last edited by elatllat on Wed Nov 16, 2016 1:40 am, edited 1 time in total.

Post Reply

Return to “Linux Kernel 4.14 Debugging Party”

Who is online

Users browsing this forum: No registered users and 1 guest