Kernel 5.9

AmigaOne X5000 platform specific issues related to Linux only.
User avatar
xeno74
Posts: 9379
Joined: Fri Mar 23, 2012 7:58 am

Re: Kernel 5.9

Post by xeno74 »

Roland wrote: Mon Aug 10, 2020 7:04 pm Kernel 5.9 alpha3 works here with Ubuntu and Fienix. Onboard ethernet still needs unplug/replug.
Skateman wrote: Mon Aug 10, 2020 7:19 pm Kernel 5.9 A3 up and running on my AmigaOne X5000
Thanks a lot for testing! :-)
http://www.amigalinux.org
http://www.supertuxkart-amiga.de

Running Linux on AmigaONEs can require some tinkering.
User avatar
xeno74
Posts: 9379
Joined: Fri Mar 23, 2012 7:58 am

Re: Kernel 5.9

Post by xeno74 »

Hi All,

Here is the alpha4 for testing.

New:
Download: linux-image-5.9-alpha4-X1000_X5000.tar.gz

Image

Please test the kernels.

Thanks,
Christian
http://www.amigalinux.org
http://www.supertuxkart-amiga.de

Running Linux on AmigaONEs can require some tinkering.
User avatar
Skateman
Posts: 863
Joined: Thu Aug 10, 2017 8:36 pm
Location: The Netherlands

Re: Kernel 5.9

Post by Skateman »

From a bloody hot attic in the Netherlands i can say that....

Kernel 5.9 Alpha4 is running nice on my AmigaOne X5000

Image

Big picture http://www.skateman.nl/wp-content/uploa ... 231520.png
AmigaOne X5000 -> 2GHz / 16GB RAM / Radeon RX 570 / Radeon X1950 / M-Audio 5.1 -> AmigaOS / Linux
Amiga 1200 -> Recapped / 68ec020 ACA 1221ec / CF HDD / RetroNET connected to the world
Vampire 4SA - RPi4 Running AmiKitXE Full
User avatar
xeno74
Posts: 9379
Joined: Fri Mar 23, 2012 7:58 am

Re: Kernel 5.9

Post by xeno74 »

Skateman wrote: Tue Aug 11, 2020 8:18 pm From a bloody hot attic in the Netherlands i can say that....

Kernel 5.9 Alpha4 is running nice on my AmigaOne X5000
Thank you for testing the alpha4! :-)
http://www.amigalinux.org
http://www.supertuxkart-amiga.de

Running Linux on AmigaONEs can require some tinkering.
User avatar
xeno74
Posts: 9379
Joined: Fri Mar 23, 2012 7:58 am

Re: Kernel 5.9

Post by xeno74 »

xeno74 wrote: Mon Aug 10, 2020 1:50 pm It seems there is an other issue but only in virtual e5500 QEMU machines (ppce500):

Code: Select all

virtio_gpu virtio0: swiotlb buffer is full (sz: 4096 bytes), total 0 (slots), used 0 (slots)
BUG: Kernel NULL pointer dereference on read at 0x00000010
Faulting instruction address: 0xc0000000000c7324
Oops: Kernel access of bad area, sig: 11 [#1]
BE PAGE_SIZE=4K PREEMPT SMP NR_CPUS=4 QEMU e500
Modules linked in:
CPU: 2 PID: 1678 Comm: kworker/2:2 Not tainted 5.9-a3_A-EON_X5000-11735-g06a81c1c7db9-dirty #1
Workqueue: events .virtio_gpu_dequeue_ctrl_func
NIP:  c0000000000c7324 LR: c0000000000c72e4 CTR: c000000000462930
REGS: c00000003dba75e0 TRAP: 0300   Not tainted  (5.9-a3_A-EON_X5000-11735-g06a81c1c7db9-dirty)
MSR:  0000000090029000 <CE,EE,ME>  CR: 24002288  XER: 00000000
DEAR: 0000000000000010 ESR: 0000000000000000 IRQMASK: 0 
GPR00: c0000000000c6188 c00000003dba7870 c0000000017f2300 c00000003d893010 
GPR04: 0000000000000000 0000000000000001 0000000000000000 0000000000000000 
GPR08: 0000000000000000 0000000000000000 0000000000000000 7f7f7f7f7f7f7f7f 
GPR12: 0000000024002284 c00000003fff9200 c00000000008c3a0 c0000000061566c0 
GPR16: 0000000000000000 0000000000000000 0000000000000000 0000000000000000 
GPR20: 0000000000000000 0000000000000000 0000000000000000 0000000000000000 
GPR24: 0000000000000001 0000000000110000 0000000000000000 0000000000000000 
GPR28: c00000003d893010 0000000000000000 0000000000000000 c00000003d893010 
NIP [c0000000000c7324] .dma_direct_unmap_sg+0x4c/0xd8
LR [c0000000000c72e4] .dma_direct_unmap_sg+0xc/0xd8
Call Trace:
[c00000003dba7870] [c00000003dba7950] 0xc00000003dba7950 (unreliable)
[c00000003dba7920] [c0000000000c6188] .dma_unmap_sg_attrs+0x5c/0x98
[c00000003dba79d0] [c0000000005cd438] .drm_gem_shmem_free_object+0x98/0xcc
[c00000003dba7a50] [c0000000006af5b4] .virtio_gpu_cleanup_object+0xc8/0xd4
[c00000003dba7ad0] [c0000000006ad3bc] .virtio_gpu_cmd_unref_cb+0x1c/0x30
[c00000003dba7b40] [c0000000006adab8] .virtio_gpu_dequeue_ctrl_func+0x208/0x28c
[c00000003dba7c10] [c000000000086b70] .process_one_work+0x1a4/0x258
[c00000003dba7cb0] [c0000000000870f4] .worker_thread+0x214/0x284
[c00000003dba7d70] [c00000000008c4f0] .kthread+0x150/0x158
[c00000003dba7e20] [c00000000000082c] .ret_from_kernel_thread+0x58/0x60
Instruction dump:
f821ff51 7cb82b78 7cdb3378 4e000000 7cfa3b78 3bc00000 7f9ec000 41fc0014 
382100b0 81810008 7d808120 48bc1ba8 <e93d0010> ebfc0248 833d0018 7fff4850 
---[ end trace f28d194d9f0955a8 ]---

virtio_gpu virtio0: swiotlb buffer is full (sz: 4096 bytes), total 0 (slots), used 0 (slots)
virtio_gpu virtio0: swiotlb buffer is full (sz: 16384 bytes), total 0 (slots), used 0 (slots)
QEMU command:

Code: Select all

qemu-system-ppc64 -M ppce500 -cpu e5500 -enable-kvm -m 1024 -kernel uImage -drive format=raw,file=fienix-soar_3.0-2020608-net.img,index=0,if=virtio -nic user,model=e1000 -append "rw root=/dev/vda2" -device virtio-vga -device virtio-mouse-pci -device virtio-keyboard-pci -device pci-ohci,id=newusb -device usb-audio,bus=newusb.0 -smp 4
Hi All,

I compiled the latest Git kernel today. The issue with the VirtIO-GPU in a virtual e5500 QEMU machine still exists.

I bisected today.
  1. Code: Select all

    git bisect start
  2. Code: Select all

    git bisect good bcf876870b95592b52519ed4aafcf9d95999bc9c
    (Good: Linux 5.8)
  3. Code: Select all

    git bisect bad 7b9de97711225559af213dc52b6ea883ef1ea7a8
    (Bad: powerpc/ptrace: Fix build error in pkey_get() -- 2020-08-07 18:27:26 -0700)
  4. git bisect bad
  5. git bisect good
  6. git bisect bad
  7. git bisect bad
  8. git bisect good
  9. git bisect bad
  10. git bisect good
  11. git bisect bad
  12. git bisect bad
  13. git bisect good
  14. git bisect good
  15. git bisect good
  16. git bisect bad
  17. git bisect good
Result: drm/virtio: Call the right shmem helpers ( d323bb44e4d23802eb25d13de1f93f2335bd60d0) is the first bad commit.

Code: Select all

d323bb44e4d23802eb25d13de1f93f2335bd60d0 is the first bad commit
commit d323bb44e4d23802eb25d13de1f93f2335bd60d0
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date:   Mon May 11 11:35:49 2020 +0200

    drm/virtio: Call the right shmem helpers
    
    drm_gem_shmem_get_sg_table is meant to implement
    obj->funcs->get_sg_table, for prime exporting. The one we want is
    drm_gem_shmem_get_pages_sgt, which also handles imported dma-buf, not
    just native objects.
    
    v2: Rebase, this stuff moved around in
    
    commit 2f2aa13724d56829d910b2fa8e80c502d388f106
    Author: Gerd Hoffmann <kraxel@redhat.com>
    Date:   Fri Feb 7 08:46:38 2020 +0100
    
        drm/virtio: move virtio_gpu_mem_entry initialization to new function
    
    Acked-by: Thomas Zimmermann <tzimmermann@suse.de>
    Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
    Cc: David Airlie <airlied@linux.ie>
    Cc: Gerd Hoffmann <kraxel@redhat.com>
    Cc: virtualization@lists.linux-foundation.org
    Link: https://patchwork.freedesktop.org/patch/msgid/20200511093554.211493-5-daniel.vetter@ffwll.ch

:040000 040000 662a02f494e4145ccc04d8e385211c3f7209f5a4 a295c95bf4b9479b2a959084c5b42b870af54e02 M	drivers
I was able to revert the first bad commit.

Code: Select all

git revert d323bb44e4d23802eb25d13de1f93f2335bd60d0
Output:

Code: Select all

[master 966950f724e4] Revert "drm/virtio: Call the right shmem helpers"
 1 file changed, 1 insertion(+), 1 deletion(-)
After that I compiled the X5000 kernel again. Then I was able to boot Fienix with this X5000 kernel in a virtual e5500 QEMU machine with the VirtIO-GPU. :-)


I created a patch.

Code: Select all

diff --git a/drivers/gpu/drm/virtio/virtgpu_object.c b/drivers/gpu/drm/virtio/virtgpu_object.c
index 6ccbd01cd888..346cef5ce251 100644
--- a/drivers/gpu/drm/virtio/virtgpu_object.c
+++ b/drivers/gpu/drm/virtio/virtgpu_object.c
@@ -150,7 +150,7 @@ static int virtio_gpu_object_shmem_init(struct virtio_gpu_device *vgdev,
 	if (ret < 0)
 		return -EINVAL;
 
-	shmem->pages = drm_gem_shmem_get_pages_sgt(&bo->base.base);
+	shmem->pages = drm_gem_shmem_get_sg_table(&bo->base.base);
 	if (!shmem->pages) {
 		drm_gem_shmem_unpin(&bo->base.base);
 		return -EINVAL;
With this patch I can use the VirtIO-GPU again.

I reported this issue to the kernel developers today.
Link: [Virtual ppce500] virtio_gpu virtio0: swiotlb buffer is full

Cheers,
Christian
http://www.amigalinux.org
http://www.supertuxkart-amiga.de

Running Linux on AmigaONEs can require some tinkering.
User avatar
xeno74
Posts: 9379
Joined: Fri Mar 23, 2012 7:58 am

Re: Kernel 5.9

Post by xeno74 »

Hi All,

I released the alpha5 for testing today.

New:
Download: linux-image-5.9-alpha5-X1000_X5000.tar.gz

Image

Please test the kernels.

Thanks,
Christian
http://www.amigalinux.org
http://www.supertuxkart-amiga.de

Running Linux on AmigaONEs can require some tinkering.
User avatar
Skateman
Posts: 863
Joined: Thu Aug 10, 2017 8:36 pm
Location: The Netherlands

Re: Kernel 5.9

Post by Skateman »

Kernel 5.9 Alpha5 running fine on the AmigaOne X5000 and Ubuntu 16.04.7

Image

Big picture http://www.skateman.nl/wp-content/uploa ... 223256.png
AmigaOne X5000 -> 2GHz / 16GB RAM / Radeon RX 570 / Radeon X1950 / M-Audio 5.1 -> AmigaOS / Linux
Amiga 1200 -> Recapped / 68ec020 ACA 1221ec / CF HDD / RetroNET connected to the world
Vampire 4SA - RPi4 Running AmiKitXE Full
User avatar
xeno74
Posts: 9379
Joined: Fri Mar 23, 2012 7:58 am

Re: Kernel 5.9

Post by xeno74 »

Skateman wrote: Fri Aug 14, 2020 7:35 pm Kernel 5.9 Alpha5 running fine on the AmigaOne X5000 and Ubuntu 16.04.7
Great to see ubuntu MATE 16.04.7 with the alpha5 of kernel 5.9. Thank you for testing! :-)
http://www.amigalinux.org
http://www.supertuxkart-amiga.de

Running Linux on AmigaONEs can require some tinkering.
User avatar
xeno74
Posts: 9379
Joined: Fri Mar 23, 2012 7:58 am

Re: Kernel 5.9

Post by xeno74 »

Hi All,

I released the alpha6 of kernel 5.9 for the X1000 and X5000 today.

New:
Download: linux-image-5.9-alpha6-X1000_X5000.tar.gz

Image

Please test the kernels.

Thanks,
Christian
http://www.amigalinux.org
http://www.supertuxkart-amiga.de

Running Linux on AmigaONEs can require some tinkering.
User avatar
Skateman
Posts: 863
Joined: Thu Aug 10, 2017 8:36 pm
Location: The Netherlands

Re: Kernel 5.9

Post by Skateman »

Kernel 5.9 Alpha6 running fine on the AmigaOne X5000

Image

Big picture http://www.skateman.nl/wp-content/uploa ... 155728.png
AmigaOne X5000 -> 2GHz / 16GB RAM / Radeon RX 570 / Radeon X1950 / M-Audio 5.1 -> AmigaOS / Linux
Amiga 1200 -> Recapped / 68ec020 ACA 1221ec / CF HDD / RetroNET connected to the world
Vampire 4SA - RPi4 Running AmiKitXE Full
Post Reply