Page 3 of 7

Re: Kernel 5.1

Posted: Thu Apr 04, 2019 1:47 am
by xeno74
I created a patch for solving the VLC issue today.

vdso_datapage_vlc.patch:

Code: Select all

diff -rupN a/arch/powerpc/include/asm/vdso_datapage.h b/arch/powerpc/include/asm/vdso_datapage.h
--- a/arch/powerpc/include/asm/vdso_datapage.h  2019-04-03 22:56:44.560645936 +0200
+++ b/arch/powerpc/include/asm/vdso_datapage.h  2019-04-04 02:20:09.479361827 +0200
@@ -82,10 +82,10 @@ struct vdso_data {
        __u32 icache_block_size;                /* L1 i-cache block size     */
        __u32 dcache_log_block_size;            /* L1 d-cache log block size */
        __u32 icache_log_block_size;            /* L1 i-cache log block size */
-       __u32 stamp_sec_fraction;               /* fractional seconds of stamp_xtime */
-       __s32 wtom_clock_nsec;                  /* Wall to monotonic clock nsec */
-       __s64 wtom_clock_sec;                   /* Wall to monotonic clock sec */
-       struct timespec stamp_xtime;            /* xtime as at tb_orig_stamp */
+       __s32 wtom_clock_sec;                   /* Wall to monotonic clock */
+       __s32 wtom_clock_nsec;
+       struct timespec stamp_xtime;    /* xtime as at tb_orig_stamp */
+       __u32 stamp_sec_fraction;       /* fractional seconds of stamp_xtime */
        __u32 syscall_map_64[SYSCALL_MAP_SIZE]; /* map of syscalls  */
        __u32 syscall_map_32[SYSCALL_MAP_SIZE]; /* map of syscalls */
 };

Re: Kernel 5.1

Posted: Thu Apr 04, 2019 11:05 am
by xeno74
FYI:
Christophe wrote: That change is part of the following commit:

https://git.kernel.org/pub/scm/linux/ke ... da32ecb60c

Just changing back the type of wtom_clock_sec to 32 bits without changing back the loading instruction is likely to give unexpected results on PPC64.

Are you using 32 bits or 64 bits powerpc ?

Can you please try below change:

Code: Select all

diff --git a/arch/powerpc/kernel/vdso32/gettimeofday.S b/arch/powerpc/kernel/vdso32/gettimeofday.S
index 1e0bc5955a40..afd516b572f8 100644
--- a/arch/powerpc/kernel/vdso32/gettimeofday.S
+++ b/arch/powerpc/kernel/vdso32/gettimeofday.S
@@ -98,7 +98,7 @@ V_FUNCTION_BEGIN(__kernel_clock_gettime)
      * can be used, r7 contains NSEC_PER_SEC.
      */

-    lwz    r5,WTOM_CLOCK_SEC(r9)
+    lwz    r5,(WTOM_CLOCK_SEC+LOPART)(r9)
     lwz    r6,WTOM_CLOCK_NSEC(r9)

     /* We now have our offset in r5,r6. We create a fake dependency

Re: Kernel 5.1

Posted: Thu Apr 04, 2019 12:33 pm
by xeno74
Christophe's patch works! VLC plays videos without any problems! :-)

Link to the test thread: VLC doesn't play videos anymore since the PowerPC fixes 5.1-3

Re: Kernel 5.1

Posted: Thu Apr 04, 2019 2:01 pm
by xeno74
Hi All,

Great news! :-)

The issue with the VLC in connection with the kernel 5.1 RC2 and higher is fixed!

Link to the test thread: VLC doesn't play videos anymore since the PowerPC fixes 5.1-3

Link to the patch: [PATCH] powerpc/vdso32: fix CLOCK_MONOTONIC on PPC64

Image

Cheers,
Christian

Re: Kernel 5.1

Posted: Sat Apr 06, 2019 11:48 pm
by xeno74
Hi All,

I released the RC3-3 of kernel 5.1 today.

New:
  • gettimeofday patch for solving the VLC issue (Thanks to Christophe Leroy)
  • Linux Git log
It also includes:
  • X1000: compressed kernel (zImage) and uncompressed kernel (vmlinux)
Download: linux-image-5.1-rc3-3-X1000_X5000.tar.gz

Screenshot of Fienix PowerPC with VLC 3.0.4 and with the RC3-3 of kernel 5.1:

Image

Please test it.

Thanks,
Christian

Re: Kernel 5.1

Posted: Sun Apr 07, 2019 2:52 am
by tbreeden
Download: linux-image-5.1-rc3-3-X1000_X5000.tar.gz
HI Christian,

I get no problems booting and running 5.1-rc3-3, but I think I've something
wrong with my VLC. On attempting to play any downloaded sample video
VLC crashes with the following message
Fontconfig error: failed reading config file
Gtk-Message: 21:37:37.726: GtkDialog mapped without a transient parent. This is discouraged.
: CommandLine Error: Option 'help-list' registered more than once!
LLVM ERROR: inconsistency in registered CommandLine options
QObject::~QObject: Timers cannot be stopped from another thread
Segmentation fault (core dumped)
This happens with 5.1-rc3-2 and 5.1-rc3, and also 5.0.0.

I may have messed up an install of VLC much earlier.
Remove and re-install?

thanks,

Tom

Re: Kernel 5.1

Posted: Sun Apr 07, 2019 9:48 am
by xeno74
Hi Tom,

Many thanks for testing the RC3-3. Please reinstall the VLC.

Have a nice weekend! :-)

Cheers,
Christian

Re: Kernel 5.1

Posted: Sun Apr 07, 2019 5:47 pm
by sailorMH
kernel 5.3-rc3 works with fienix + southern island

Re: Kernel 5.1

Posted: Mon Apr 08, 2019 5:49 am
by xeno74
sailorMH wrote:kernel 5.3-rc3 works with fienix + southern island
Hi SailorMH,

Thanks a lot for testing the RC3 (RC3-3)! :-)

Cheers,
Christian

Re: Kernel 5.1

Posted: Mon Apr 08, 2019 3:42 pm
by xeno74
The VLC solution is on the way to the official kernel source code:
Michael Ellerman wrote: On 8. Apr 2019, at 15:03, Michael Ellerman <patch-notifications@ellerman.id.au> wrote:

On Thu, 2019-04-04 at 12:20:05 UTC, Christophe Leroy wrote:
Commit b5b4453e7912 ("powerpc/vdso64: Fix CLOCK_MONOTONIC
inconsistencies across Y2038") changed the type of wtom_clock_sec
to s64 on PPC64. Therefore, VDSO32 needs to read it with a 4 bytes
shift in order to retrieve the lower part of it.

Fixes: b5b4453e7912 ("powerpc/vdso64: Fix CLOCK_MONOTONIC inconsistencies across Y2038")
Reported-by: Christian Zigotzky <chzigotzky@xenosoft.de>
Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>

Applied to powerpc fixes, thanks.

https://git.kernel.org/powerpc/c/dd9a99 ... 747e3366c5

cheers