notro / gud

GUD USB Display
153 stars 7 forks source link

Add postmarketOS implemention in Wiki #9

Closed ZenithalHourlyRate closed 2 years ago

ZenithalHourlyRate commented 2 years ago

https://github.com/notro/gud/wiki/Gadget-Implementations mentioned old tablets/phones.

One way is to port f_gud to Android kernel, another way is to use mainline kernel with these old tablets/phones.

One implementation using postmarketOS is detailed in https://gist.github.com/ZenithalHourlyRate/220186818bae434386e80c62ee1bc7bc

notro commented 2 years ago

That's really cool and nice writeup!

I've added the link to the wiki page. The wiki should be writeable for all, so you can make the changes you want.

notro commented 2 years ago

I added a section in the wiki regarding your userspace implementation note: https://github.com/notro/gud/wiki/Gadget-Implementations#userspace-linux

ZenithalHourlyRate commented 2 years ago

That's really cool and nice writeup!

Thanks!

I've added the link to the wiki page. The wiki should be writeable for all, so you can make the changes you want.

I think I should notify you about the changes are to made.

notro commented 2 years ago

Made a short note in the wiki about buffer sharing which I guess is the problem with the Nvidia driver: https://github.com/notro/gud/wiki/Linux-Host-Driver#prime-buffer-sharing

Seems to be 2 problems:

  1. The GUD driver uses the drm shmem helper and it doesn't support buffers that set map->is_iomem.
  2. There's a bug somewhere that triggers a BUG_ON() in dma-buf. Probably an error path somewhere that doesn't clean up properly.
ZenithalHourlyRate commented 2 years ago

Made a short note in the wiki about buffer sharing which I guess is the problem with the Nvidia driver: https://github.com/notro/gud/wiki/Linux-Host-Driver#prime-buffer-sharing

Partial log for the host here (Repeated warnings ignored).

This happened when I unplugged GUD device from the host.

It seemds that the host can not find the buffer? Thus causing dma panic? Related line

gud 1-3:1.0: Failed to flush framebuffer: error=-5
ZenithalHourlyRate commented 2 years ago

Made a short note in the wiki about buffer sharing which I guess is the problem with the Nvidia driver: https://github.com/notro/gud/wiki/Linux-Host-Driver#prime-buffer-sharing

DRM PRIME Log here http://shz.al/xr7C. Generated by appending drm.debug=0x8 to kernel cmdline.

notro commented 2 years ago

Made a short note in the wiki about buffer sharing which I guess is the problem with the Nvidia driver: https://github.com/notro/gud/wiki/Linux-Host-Driver#prime-buffer-sharing

DRM PRIME Log here http://shz.al/xr7C. Generated by appending drm.debug=0x8 to kernel cmdline.

Looks like you forgot to plug in the USB display, there are no prime messages nor any splat.

ZenithalHourlyRate commented 2 years ago

Looks like you forgot to plug in the USB display, there are no prime messages nor any splat.

http://shz.al/P3SB. This time I booted up with GUD plugged in.