GIT kernel with the PowerPC updates 5.11-1 doesn't boot on a FSL P5040 board and in a virtual e5500 QEMU machine

11 messages, 4 authors, 2021-02-01 · open the first message on its own page

GIT kernel with the PowerPC updates 5.11-1 doesn't boot on a FSL P5040 board and in a virtual e5500 QEMU machine

From: Christian Zigotzky <hidden>
Date: 2020-12-18 17:50:22

Hello,

I compiled the latest Git kernel with the new PowerPC updates 5.11-1 [1] 
today. Unfortunately this kernel doesn't boot on my FSL P5040 board [2] 
and in a virtual e5500 QEMU machine [3].

I was able to revert the new PowerPC updates 5.11-1 [4] and after a new 
compiling, the kernel boots without any problems on my FSL P5040 board.

Please check the new PowerPC updates 5.11-1.

Thanks,
Christian


[1] 
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=8a5be36b9303ae167468d4f5e1b3c090b9981396
[2] http://wiki.amiga.org/index.php?title=X5000
[3] qemu-system-ppc64 -M ppce500 -cpu e5500 -m 1024 -kernel uImage 
-drive format=raw,file=MintPPC32-X5000.img,index=0,if=virtio -netdev 
user,id=mynet0 -device virtio-net-pci,netdev=mynet0 -append "rw 
root=/dev/vda" -device virtio-vga -usb -device usb-ehci,id=ehci -device 
usb-tablet -device virtio-keyboard-pci -smp 4 -vnc :1
[4] git revert 8a5be36b9303ae167468d4f5e1b3c090b9981396 -m 1

Re: GIT kernel with the PowerPC updates 5.11-1 doesn't boot on a FSL P5040 board and in a virtual e5500 QEMU machine

From: Denis Kirjanov <hidden>
Date: 2020-12-18 21:47:34

On Friday, December 18, 2020, Christian Zigotzky [off-list ref]
wrote:
Hello,

I compiled the latest Git kernel with the new PowerPC updates 5.11-1 [1]
today. Unfortunately this kernel doesn't boot on my FSL P5040 board [2] and
in a virtual e5500 QEMU machine [3].

I was able to revert the new PowerPC updates 5.11-1 [4] and after a new
compiling, the kernel boots without any problems on my FSL P5040 board.

Please check the new PowerPC updates 5.11-1.

Can you bisect the bad commit?


Thanks,
Christian


[1] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/lin
ux.git/commit/?id=8a5be36b9303ae167468d4f5e1b3c090b9981396
[2] http://wiki.amiga.org/index.php?title=X5000
[3] qemu-system-ppc64 -M ppce500 -cpu e5500 -m 1024 -kernel uImage -drive
format=raw,file=MintPPC32-X5000.img,index=0,if=virtio -netdev
user,id=mynet0 -device virtio-net-pci,netdev=mynet0 -append "rw
root=/dev/vda" -device virtio-vga -usb -device usb-ehci,id=ehci -device
usb-tablet -device virtio-keyboard-pci -smp 4 -vnc :1
[4] git revert 8a5be36b9303ae167468d4f5e1b3c090b9981396 -m 1

Re: GIT kernel with the PowerPC updates 5.11-1 doesn't boot on a FSL P5040 board and in a virtual e5500 QEMU machine

From: Christian Zigotzky <hidden>
Date: 2020-12-18 22:51:19

On 18 December 2020 at 10:25pm, Denis Kirjanov wrote:
 >
 >
 > On Friday, December 18, 2020, Christian Zigotzky 
[off-list ref] wrote:
 >
 >     Hello,
 >
 >     I compiled the latest Git kernel with the new PowerPC updates 
5.11-1 [1] today. Unfortunately this kernel doesn't boot on my FSL P5040 
board [2] and in a virtual e5500 QEMU machine [3].
 >
 >     I was able to revert the new PowerPC updates 5.11-1 [4] and after 
a new compiling, the kernel boots without any problems on my FSL P5040 
board.
 >
 >     Please check the new PowerPC updates 5.11-1.
 >
 >
 > Can you bisect the bad commit?
 >
Hello Denis,

I have bisected [5] and d0e3fc69d00d1f50d22d6b6acfc555ccda80ad1e 
(powerpc/vdso: Provide __kernel_clock_gettime64() on vdso32) [6] is the 
first bad commit.

I was able to revert this bad commit and after a new compiling, the 
kernel boots without any problems.

Thanks,
Christian

[5] https://forum.hyperion-entertainment.com/viewtopic.php?p=52077#p52077
[6] 
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=d0e3fc69d00d1f50d22d6b6acfc555ccda80ad1e

 >
 >
 >
 >     Thanks,
 >     Christian
 >
 >
 >     [1] 
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=8a5be36b9303ae167468d4f5e1b3c090b9981396
 >     [2] http://wiki.amiga.org/index.php?title=X5000
 >     [3] qemu-system-ppc64 -M ppce500 -cpu e5500 -m 1024 -kernel 
uImage -drive format=raw,file=MintPPC32-X5000.img,index=0,if=virtio 
-netdev user,id=mynet0 -device virtio-net-pci,netdev=mynet0 -append "rw 
root=/dev/vda" -device virtio-vga -usb -device usb-ehci,id=ehci -device 
usb-tablet -device virtio-keyboard-pci -smp 4 -vnc :1
 >     [4] git revert 8a5be36b9303ae167468d4f5e1b3c090b9981396 -m 1
 >

Re: GIT kernel with the PowerPC updates 5.11-1 doesn't boot on a FSL P5040 board and in a virtual e5500 QEMU machine

From: Christian Zigotzky <hidden>
Date: 2020-12-19 00:43:21

On 18 December 2020 at 11:49pm, Christian Zigotzky wrote:
On 18 December 2020 at 10:25pm, Denis Kirjanov wrote:
quoted

On Friday, December 18, 2020, Christian Zigotzky 
[off-list ref] wrote:
quoted
    Hello,

    I compiled the latest Git kernel with the new PowerPC updates 
5.11-1 [1] today. Unfortunately this kernel doesn't boot on my FSL 
P5040 board [2] and in a virtual e5500 QEMU machine [3].
quoted
    I was able to revert the new PowerPC updates 5.11-1 [4] and 
after a new compiling, the kernel boots without any problems on my FSL 
P5040 board.
quoted
    Please check the new PowerPC updates 5.11-1.


Can you bisect the bad commit?
Hello Denis,

I have bisected [5] and d0e3fc69d00d1f50d22d6b6acfc555ccda80ad1e 
(powerpc/vdso: Provide __kernel_clock_gettime64() on vdso32) [6] is 
the first bad commit.

I was able to revert this bad commit and after a new compiling, the 
kernel boots without any problems.

Thanks,
Christian

[5] https://forum.hyperion-entertainment.com/viewtopic.php?p=52077#p52077
[6] 
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=d0e3fc69d00d1f50d22d6b6acfc555ccda80ad1e
quoted


    Thanks,
    Christian


    [1] 
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=8a5be36b9303ae167468d4f5e1b3c090b9981396
quoted
    [2] http://wiki.amiga.org/index.php?title=X5000
    [3] qemu-system-ppc64 -M ppce500 -cpu e5500 -m 1024 -kernel 
uImage -drive format=raw,file=MintPPC32-X5000.img,index=0,if=virtio 
-netdev user,id=mynet0 -device virtio-net-pci,netdev=mynet0 -append 
"rw root=/dev/vda" -device virtio-vga -usb -device usb-ehci,id=ehci 
-device usb-tablet -device virtio-keyboard-pci -smp 4 -vnc :1
quoted
    [4] git revert 8a5be36b9303ae167468d4f5e1b3c090b9981396 -m 1
Hello,

I created a patch for reverting the bad commit. I can boot the latest 
Git kernel compiled with this patch on my FSL P5040 board and in a 
virtual e5500 QEMU machine.

------
diff -rupN a/arch/powerpc/include/asm/vdso/gettimeofday.h 
b/arch/powerpc/include/asm/vdso/gettimeofday.h
--- a/arch/powerpc/include/asm/vdso/gettimeofday.h    2020-12-19 
00:01:16.825846606 +0100
+++ b/arch/powerpc/include/asm/vdso/gettimeofday.h    2020-12-19 
00:00:38.213374736 +0100
@@ -187,8 +187,6 @@ int __c_kernel_clock_getres(clockid_t cl
  #else
  int __c_kernel_clock_gettime(clockid_t clock, struct old_timespec32 *ts,
                   const struct vdso_data *vd);
-int __c_kernel_clock_gettime64(clockid_t clock, struct 
__kernel_timespec *ts,
-                   const struct vdso_data *vd);
  int __c_kernel_clock_getres(clockid_t clock_id, struct old_timespec32 
*res,
                  const struct vdso_data *vd);
  #endif
diff -rupN a/arch/powerpc/kernel/vdso32/gettimeofday.S 
b/arch/powerpc/kernel/vdso32/gettimeofday.S
--- a/arch/powerpc/kernel/vdso32/gettimeofday.S    2020-12-19 
00:01:16.829846652 +0100
+++ b/arch/powerpc/kernel/vdso32/gettimeofday.S    2020-12-19 
00:00:37.817369691 +0100
@@ -35,15 +35,6 @@ V_FUNCTION_BEGIN(__kernel_clock_gettime)
      cvdso_call __c_kernel_clock_gettime
  V_FUNCTION_END(__kernel_clock_gettime)

-/*
- * Exact prototype of clock_gettime64()
- *
- * int __kernel_clock_gettime64(clockid_t clock_id, struct __timespec64 
*ts);
- *
- */
-V_FUNCTION_BEGIN(__kernel_clock_gettime64)
-    cvdso_call __c_kernel_clock_gettime64
-V_FUNCTION_END(__kernel_clock_gettime64)

  /*
   * Exact prototype of clock_getres()
diff -rupN a/arch/powerpc/kernel/vdso32/vdso32.lds.S 
b/arch/powerpc/kernel/vdso32/vdso32.lds.S
--- a/arch/powerpc/kernel/vdso32/vdso32.lds.S    2020-12-19 
00:01:16.829846652 +0100
+++ b/arch/powerpc/kernel/vdso32/vdso32.lds.S    2020-12-19 
00:00:38.209374686 +0100
@@ -118,7 +118,6 @@ VERSION
          __kernel_get_syscall_map;
          __kernel_gettimeofday;
          __kernel_clock_gettime;
-        __kernel_clock_gettime64;
          __kernel_clock_getres;
          __kernel_time;
          __kernel_get_tbfreq;
diff -rupN a/arch/powerpc/kernel/vdso32/vgettimeofday.c 
b/arch/powerpc/kernel/vdso32/vgettimeofday.c
--- a/arch/powerpc/kernel/vdso32/vgettimeofday.c    2020-12-19 
00:01:16.829846652 +0100
+++ b/arch/powerpc/kernel/vdso32/vgettimeofday.c    2020-12-19 
00:00:37.817369691 +0100
@@ -10,12 +10,6 @@ int __c_kernel_clock_gettime(clockid_t c
      return __cvdso_clock_gettime32_data(vd, clock, ts);
  }

-int __c_kernel_clock_gettime64(clockid_t clock, struct 
__kernel_timespec *ts,
-                   const struct vdso_data *vd)
-{
-    return __cvdso_clock_gettime_data(vd, clock, ts);
-}
-
  int __c_kernel_gettimeofday(struct __kernel_old_timeval *tv, struct 
timezone *tz,
                  const struct vdso_data *vd)
  {

------

Re: GIT kernel with the PowerPC updates 5.11-1 doesn't boot on a FSL P5040 board and in a virtual e5500 QEMU machine

From: Christophe Leroy <hidden>
Date: 2020-12-19 06:51:04


Le 18/12/2020 à 23:49, Christian Zigotzky a écrit :
On 18 December 2020 at 10:25pm, Denis Kirjanov wrote:
 >
 >
 > On Friday, December 18, 2020, Christian Zigotzky [off-list ref] wrote:
 >
 >     Hello,
 >
 >     I compiled the latest Git kernel with the new PowerPC updates 5.11-1 [1] today. Unfortunately 
this kernel doesn't boot on my FSL P5040 board [2] and in a virtual e5500 QEMU machine [3].
 >
 >     I was able to revert the new PowerPC updates 5.11-1 [4] and after a new compiling, the kernel 
boots without any problems on my FSL P5040 board.
 >
 >     Please check the new PowerPC updates 5.11-1.
 >
 >
 > Can you bisect the bad commit?
 >
Hello Denis,

I have bisected [5] and d0e3fc69d00d1f50d22d6b6acfc555ccda80ad1e (powerpc/vdso: Provide 
__kernel_clock_gettime64() on vdso32) [6] is the first bad commit.

I was able to revert this bad commit and after a new compiling, the kernel boots without any problems.
That's puzzling.

Can you describe the symptoms exactly ? What do you mean by "the kernel doesn't boot" ? Where and 
how does it stops booting ?

This commit only adds a new VDSO call, for getting y2038 compliant time. At the time I implemented 
it there was no libc using it yet. Is your libc using it ?

Where can I find all the elements you are using to boot with QEMU ? Especially the file 
MintPPC32-X5000.img

Can you also share you kernel config

Thanks
Christophe

Re: GIT kernel with the PowerPC updates 5.11-1 doesn't boot on a FSL P5040 board and in a virtual e5500 QEMU machine

From: Christian Zigotzky <hidden>
Date: 2020-12-19 12:37:03

On 19 December 2020 at 07:49am, Christophe Leroy wrote:

Le 18/12/2020 à 23:49, Christian Zigotzky a écrit :
quoted
On 18 December 2020 at 10:25pm, Denis Kirjanov wrote:
 >
 >
 > On Friday, December 18, 2020, Christian Zigotzky 
[off-list ref] wrote:
 >
 >     Hello,
 >
 >     I compiled the latest Git kernel with the new PowerPC updates 
5.11-1 [1] today. Unfortunately this kernel doesn't boot on my FSL 
P5040 board [2] and in a virtual e5500 QEMU machine [3].
 >
 >     I was able to revert the new PowerPC updates 5.11-1 [4] and 
after a new compiling, the kernel boots without any problems on my 
FSL P5040 board.
 >
 >     Please check the new PowerPC updates 5.11-1.
 >
 >
 > Can you bisect the bad commit?
 >
Hello Denis,

I have bisected [5] and d0e3fc69d00d1f50d22d6b6acfc555ccda80ad1e 
(powerpc/vdso: Provide __kernel_clock_gettime64() on vdso32) [6] is 
the first bad commit.

I was able to revert this bad commit and after a new compiling, the 
kernel boots without any problems.
That's puzzling.

Can you describe the symptoms exactly ? What do you mean by "the 
kernel doesn't boot" ? Where and how does it stops booting ?
It stops during the disk initialisation.
This commit only adds a new VDSO call, for getting y2038 compliant 
time. At the time I implemented it there was no libc using it yet. Is 
your libc using it ?
I tested it with ubuntu MATE 16.04.7 LTS (32-bit userland + 64-bit 
kernel) and with Debian Sid (MintPPC and Fienix 32-bit userland + 64-bit 
kernel) on my FSL P5040 board and in a virtual e5500 QEMU machine. How 
can I figure out if the libc use it?
Where can I find all the elements you are using to boot with QEMU ? 
Especially the file MintPPC32-X5000.img
Download: http://www.xenosoft.de/MintPPC32-X5000.tar.gz (md5sum: 
b31c1c1ca1fcf5d4cdf110c4bce11654) The password for both 'root' and 
'mintppc' is 'mintppc'.

QEMU command with KVM on my P5040 board: qemu-system-ppc64 -M ppce500 
-cpu e5500 -enable-kvm -m 1024 -kernel uImage -drive 
format=raw,file=MintPPC32-X5000.img,index=0,if=virtio -netdev 
user,id=mynet0 -device e1000,netdev=mynet0 -append "rw root=/dev/vda" 
-device virtio-vga -device virtio-mouse-pci -device virtio-keyboard-pci 
-device pci-ohci,id=newusb -device usb-audio,bus=newusb.0 -smp 4

QEMU command without KVM on macOS Intel: qemu-system-ppc64 -M ppce500 
-cpu e5500 -m 1024 -kernel uImage -drive 
format=raw,file=MintPPC32-X5000.img,index=0,if=virtio -netdev 
user,id=mynet0 -device virtio-net-pci,netdev=mynet0 -append "rw 
root=/dev/vda" -device virtio-vga -usb -device usb-ehci,id=ehci -device 
usb-tablet -device virtio-keyboard-pci -smp 4 -vnc :1
Can you also share you kernel config
See attachment.
Thanks
Christophe
Thanks
Christian

Re: GIT kernel with the PowerPC updates 5.11-1 doesn't boot on a FSL P5040 board and in a virtual e5500 QEMU machine

From: Christian Zigotzky <hidden>
Date: 2020-12-22 12:19:28

Hello,

I compiled the latest Git kernel today and unfortunately the boot issue 
still exists.

I was able to reduce the patch for reverting the changes. In this way we 
know the problematic code now.

vdso-v2.patch:

diff -rupN a/arch/powerpc/kernel/vdso32/vgettimeofday.c 
b/arch/powerpc/kernel/vdso32/vgettimeofday.c
--- a/arch/powerpc/kernel/vdso32/vgettimeofday.c    2020-12-19 
00:01:16.829846652 +0100
+++ b/arch/powerpc/kernel/vdso32/vgettimeofday.c    2020-12-19 
00:00:37.817369691 +0100
@@ -10,12 +10,6 @@ int __c_kernel_clock_gettime(clockid_t c
      return __cvdso_clock_gettime32_data(vd, clock, ts);
  }

-int __c_kernel_clock_gettime64(clockid_t clock, struct 
__kernel_timespec *ts,
-                   const struct vdso_data *vd)
-{
-    return __cvdso_clock_gettime_data(vd, clock, ts);
-}
-
  int __c_kernel_gettimeofday(struct __kernel_old_timeval *tv, struct 
timezone *tz,
                  const struct vdso_data *vd)
  {

----

With this patch, the uImage boots without any problems on my FSL P5040 
board and in a virtual e5500 QEMU machine. Please check the problematic 
code.

Thanks,
Christian



On 19 December 2020 at 01:33pm, Christian Zigotzky wrote:
On 19 December 2020 at 07:49am, Christophe Leroy wrote:
quoted

Le 18/12/2020 à 23:49, Christian Zigotzky a écrit :
quoted
On 18 December 2020 at 10:25pm, Denis Kirjanov wrote:
 >
 >
 > On Friday, December 18, 2020, Christian Zigotzky 
[off-list ref] wrote:
 >
 >     Hello,
 >
 >     I compiled the latest Git kernel with the new PowerPC updates 
5.11-1 [1] today. Unfortunately this kernel doesn't boot on my FSL 
P5040 board [2] and in a virtual e5500 QEMU machine [3].
 >
 >     I was able to revert the new PowerPC updates 5.11-1 [4] and 
after a new compiling, the kernel boots without any problems on my 
FSL P5040 board.
 >
 >     Please check the new PowerPC updates 5.11-1.
 >
 >
 > Can you bisect the bad commit?
 >
Hello Denis,

I have bisected [5] and d0e3fc69d00d1f50d22d6b6acfc555ccda80ad1e 
(powerpc/vdso: Provide __kernel_clock_gettime64() on vdso32) [6] is 
the first bad commit.

I was able to revert this bad commit and after a new compiling, the 
kernel boots without any problems.
That's puzzling.

Can you describe the symptoms exactly ? What do you mean by "the 
kernel doesn't boot" ? Where and how does it stops booting ?
It stops during the disk initialisation.
quoted
This commit only adds a new VDSO call, for getting y2038 compliant 
time. At the time I implemented it there was no libc using it yet. Is 
your libc using it ?
I tested it with ubuntu MATE 16.04.7 LTS (32-bit userland + 64-bit 
kernel) and with Debian Sid (MintPPC and Fienix 32-bit userland + 
64-bit kernel) on my FSL P5040 board and in a virtual e5500 QEMU 
machine. How can I figure out if the libc use it?
quoted
Where can I find all the elements you are using to boot with QEMU ? 
Especially the file MintPPC32-X5000.img
Download: http://www.xenosoft.de/MintPPC32-X5000.tar.gz (md5sum: 
b31c1c1ca1fcf5d4cdf110c4bce11654) The password for both 'root' and 
'mintppc' is 'mintppc'.

QEMU command with KVM on my P5040 board: qemu-system-ppc64 -M ppce500 
-cpu e5500 -enable-kvm -m 1024 -kernel uImage -drive 
format=raw,file=MintPPC32-X5000.img,index=0,if=virtio -netdev 
user,id=mynet0 -device e1000,netdev=mynet0 -append "rw root=/dev/vda" 
-device virtio-vga -device virtio-mouse-pci -device 
virtio-keyboard-pci -device pci-ohci,id=newusb -device 
usb-audio,bus=newusb.0 -smp 4

QEMU command without KVM on macOS Intel: qemu-system-ppc64 -M ppce500 
-cpu e5500 -m 1024 -kernel uImage -drive 
format=raw,file=MintPPC32-X5000.img,index=0,if=virtio -netdev 
user,id=mynet0 -device virtio-net-pci,netdev=mynet0 -append "rw 
root=/dev/vda" -device virtio-vga -usb -device usb-ehci,id=ehci 
-device usb-tablet -device virtio-keyboard-pci -smp 4 -vnc :1
quoted
Can you also share you kernel config
See attachment.
quoted
Thanks
Christophe
Thanks
Christian

Re: GIT kernel with the PowerPC updates 5.11-1 doesn't boot on a FSL P5040 board and in a virtual e5500 QEMU machine

From: Michael Ellerman <mpe@ellerman.id.au>
Date: 2020-12-22 13:31:33

Christian Zigotzky [off-list ref] writes:
...
Download: http://www.xenosoft.de/MintPPC32-X5000.tar.gz (md5sum: 
b31c1c1ca1fcf5d4cdf110c4bce11654) The password for both 'root' and 
'mintppc' is 'mintppc'.
...
QEMU command without KVM on macOS Intel: qemu-system-ppc64 -M ppce500 
-cpu e5500 -m 1024 -kernel uImage -drive 
format=raw,file=MintPPC32-X5000.img,index=0,if=virtio -netdev 
user,id=mynet0 -device virtio-net-pci,netdev=mynet0 -append "rw 
root=/dev/vda" -device virtio-vga -usb -device usb-ehci,id=ehci -device 
usb-tablet -device virtio-keyboard-pci -smp 4 -vnc :1
I was able to boot the above (on powerpc, but not using KVM), using my
fixes branch.

Please give that branch a test:
  https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git/log/?h=fixes


cheers

Re: GIT kernel with the PowerPC updates 5.11-1 doesn't boot on a FSL P5040 board and in a virtual e5500 QEMU machine

From: Christian Zigotzky <hidden>
Date: 2020-12-24 15:03:31

On 22 December 2020 at 02:14pm, Michael Ellerman wrote:
Christian Zigotzky [off-list ref] writes:
...
quoted
Download: http://www.xenosoft.de/MintPPC32-X5000.tar.gz (md5sum:
b31c1c1ca1fcf5d4cdf110c4bce11654) The password for both 'root' and
'mintppc' is 'mintppc'.
...
quoted
QEMU command without KVM on macOS Intel: qemu-system-ppc64 -M ppce500
-cpu e5500 -m 1024 -kernel uImage -drive
format=raw,file=MintPPC32-X5000.img,index=0,if=virtio -netdev
user,id=mynet0 -device virtio-net-pci,netdev=mynet0 -append "rw
root=/dev/vda" -device virtio-vga -usb -device usb-ehci,id=ehci -device
usb-tablet -device virtio-keyboard-pci -smp 4 -vnc :1
I was able to boot the above (on powerpc, but not using KVM), using my
fixes branch.

Please give that branch a test:
   https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git/log/?h=fixes


cheers
Hello Michael,

I tested your fixes branch today and the kernel boots without any problems.

Thanks a lot for fixing the issue.

Merry Christmas,

Christian

FSL P5040: KVM HV doesn't work with the RC5 of kernel 5.11

From: Christian Zigotzky <hidden>
Date: 2021-01-27 16:09:41

Hello,

I compiled the RC5 of kernel 5.11 today. Unfortunately KVM HV doesn't 
work anymore on my FSL P5040 board [1]. I tested it with QEMU 5.0.0 
today [2]. The virtual e5500 QEMU machine works with the "RC4 with KVM 
HV" and with the "RC5 without KVM HV". The complete system freezes if I 
use KVM HV with the RC5.

I have bisected and 785025820a6a565185ce9d47fdd8d23dbf91dee8 
(powerpc/mm/highmem: use __set_pte_at() for kmap_local()) [3] is the 
first bad commit.

I was able to revert this bad commit and after a new compiling, KVM HV 
works again.  I created a patch for reverting the commit. [4] Please 
find attached the kernel config. I use one uImage for the virtual 
machine and for the P5040 board.

Please check the first bad commit.

Thanks,
Christian


[1] http://wiki.amiga.org/index.php?title=X5000
[2] qemu-system-ppc64 -M ppce500 -cpu e5500 -enable-kvm -m 1024 -kernel 
uImage-5.11 -drive format=raw,file=MintPPC32-X5000.img,index=0,if=virtio 
-netdev user,id=mynet0 -device e1000,netdev=mynet0 -append "rw 
root=/dev/vda" -device virtio-vga -device virtio-mouse-pci -device 
virtio-keyboard-pci -device pci-ohci,id=newusb -device 
usb-audio,bus=newusb.0 -smp 4
[3] 
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?h=v5.11-rc5&id=785025820a6a565185ce9d47fdd8d23dbf91dee8
[4]
diff -rupN a/arch/powerpc/include/asm/highmem.h 
b/arch/powerpc/include/asm/highmem.h
--- a/arch/powerpc/include/asm/highmem.h        2021-01-27 
16:12:40.382164118 +0100
+++ b/arch/powerpc/include/asm/highmem.h        2021-01-27 
16:10:54.055249957 +0100
@@ -58,8 +58,6 @@ extern pte_t *pkmap_page_table;

  #define flush_cache_kmaps()    flush_cache_all()

-#define arch_kmap_local_set_pte(mm, vaddr, ptep, ptev) \
-       __set_pte_at(mm, vaddr, ptep, ptev, 1)
  #define arch_kmap_local_post_map(vaddr, pteval)        \
         local_flush_tlb_page(NULL, vaddr)
  #define arch_kmap_local_post_unmap(vaddr)      \

Re: FSL P5040: KVM HV doesn't work with the RC5 of kernel 5.11

From: Christian Zigotzky <hidden>
Date: 2021-02-01 08:31:19

Hello,

I compiled the RC6 of kernel 5.11 today and KVM HV works again. 
Therefore I don't need the patch below anymore.

Many thanks for solving the issue,
Christian


On 27 January 2021 at 05:07pm, Christian Zigotzky wrote:
quoted hunk
Hello,

I compiled the RC5 of kernel 5.11 today. Unfortunately KVM HV doesn't 
work anymore on my FSL P5040 board [1]. I tested it with QEMU 5.0.0 
today [2]. The virtual e5500 QEMU machine works with the "RC4 with KVM 
HV" and with the "RC5 without KVM HV". The complete system freezes if 
I use KVM HV with the RC5.

I have bisected and 785025820a6a565185ce9d47fdd8d23dbf91dee8 
(powerpc/mm/highmem: use __set_pte_at() for kmap_local()) [3] is the 
first bad commit.

I was able to revert this bad commit and after a new compiling, KVM HV 
works again.  I created a patch for reverting the commit. [4] Please 
find attached the kernel config. I use one uImage for the virtual 
machine and for the P5040 board.

Please check the first bad commit.

Thanks,
Christian


[1] http://wiki.amiga.org/index.php?title=X5000
[2] qemu-system-ppc64 -M ppce500 -cpu e5500 -enable-kvm -m 1024 
-kernel uImage-5.11 -drive 
format=raw,file=MintPPC32-X5000.img,index=0,if=virtio -netdev 
user,id=mynet0 -device e1000,netdev=mynet0 -append "rw root=/dev/vda" 
-device virtio-vga -device virtio-mouse-pci -device 
virtio-keyboard-pci -device pci-ohci,id=newusb -device 
usb-audio,bus=newusb.0 -smp 4
[3] 
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?h=v5.11-rc5&id=785025820a6a565185ce9d47fdd8d23dbf91dee8
[4]
diff -rupN a/arch/powerpc/include/asm/highmem.h 
b/arch/powerpc/include/asm/highmem.h
--- a/arch/powerpc/include/asm/highmem.h        2021-01-27 
16:12:40.382164118 +0100
+++ b/arch/powerpc/include/asm/highmem.h        2021-01-27 
16:10:54.055249957 +0100
@@ -58,8 +58,6 @@ extern pte_t *pkmap_page_table;
 #define flush_cache_kmaps()    flush_cache_all()

-#define arch_kmap_local_set_pte(mm, vaddr, ptep, ptev) \
-       __set_pte_at(mm, vaddr, ptep, ptev, 1)
 #define arch_kmap_local_post_map(vaddr, pteval)        \
        local_flush_tlb_page(NULL, vaddr)
 #define arch_kmap_local_post_unmap(vaddr)      \

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help