Bug 203201

Summary: [mgag200] Unable to do mmap call on mgadrmfb device - Returns -EINVAL
Product: Drivers Reporter: Olivier Bonhomme (olivier)
Component: Video(DRI - non Intel)Assignee: drivers_video-dri
Status: NEW ---    
Severity: normal CC: devzero
Priority: P1    
Hardware: Intel   
OS: Linux   
Kernel Version: 4.4 LTS Subsystem:
Regression: No Bisected commit-id:

Description Olivier Bonhomme 2019-04-09 15:11:56 UTC
Hello dear kernel maintainers,

I'm trying to map memory on the frame buffer device fb0 provided by the mgag200 driver. However, that mmap call always returns -EINVAL code while the same mmmap call works with other drivers (uvesafb for example).

After some investigations, I discovered that a patch which resolves that problem has been produced by SuSe guys. The patch is available here : https://lists.freedesktop.org/archives/dri-devel/2017-July/147650.html

I tested that patch on my 4.4.150 kernel and it resolved the problem.

I checked in the GIT kernel tree and it seems that this patch hasn't been included in 4.4 branch nor in the current kernel branch while the same kind of patch has been done for ast driver (https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/drivers/gpu/drm/ast?h=linux-4.4.y&id=28fb4cb7fa6f63dc2fbdb5f2564dcbead8e3eee0)

It would be nice if that patch for mgag200 would be imported in the kernel source tree.

Thanks

Regards,
Olivier Bonhomme
Comment 1 Roland Kletzing 2024-01-08 10:31:48 UTC
apparently the patch has never got merged, apparently it seems Dave Airlie did not find it useful enough

https://yhbt.net/lore/all/CAPM=9tzMT3hdOpdwPhRr07SW-3iu6OhnKY6NOO3e_21Vyf6ozg@mail.gmail.com/