[PATCH v2] of: Fix of platform build on powerpc due to bad of disaply code

Erhard F. erhard_f at mailbox.org
Thu Jan 19 22:42:32 AEDT 2023


On Thu, 19 Jan 2023 10:53:23 +0100
Michal Suchanek <msuchanek at suse.de> wrote:

> The commit 2d681d6a23a1 ("of: Make of framebuffer devices unique")
> breaks build because of wrong argument to snprintf. That certainly
> avoids the runtime error but is not the intended outcome.
> 
> Also use standard device name format of-display.N for all created
> devices.
> 
> Fixes: 2d681d6a23a1 ("of: Make of framebuffer devices unique")
> Signed-off-by: Michal Suchanek <msuchanek at suse.de>
> ---
> v2: Update the device name format

Hi Michal!

Just tested your 'of: Make of framebuffer devices unique' + 'v2 of: Fix of platform build on powerpc due to bad of disaply code' on my G4 and can confirm they fix the original issue (https://bugzilla.kernel.org/show_bug.cgi?id=216095). Thanks!

Also ofdrm gets loaded now without error messages:
 # modprobe -v ofdrm
insmod /lib/modules/6.2.0-rc4-PMacG4+/kernel/drivers/video/fbdev/core/cfbcopyarea.ko 
insmod /lib/modules/6.2.0-rc4-PMacG4+/kernel/drivers/video/fbdev/core/sysimgblt.ko 
insmod /lib/modules/6.2.0-rc4-PMacG4+/kernel/drivers/video/fbdev/core/sysfillrect.ko 
insmod /lib/modules/6.2.0-rc4-PMacG4+/kernel/drivers/video/fbdev/core/cfbimgblt.ko 
insmod /lib/modules/6.2.0-rc4-PMacG4+/kernel/drivers/video/fbdev/core/syscopyarea.ko 
insmod /lib/modules/6.2.0-rc4-PMacG4+/kernel/drivers/video/fbdev/core/cfbfillrect.ko 
insmod /lib/modules/6.2.0-rc4-PMacG4+/kernel/drivers/gpu/drm/drm_kms_helper.ko 
insmod /lib/modules/6.2.0-rc4-PMacG4+/kernel/drivers/gpu/drm/drm_shmem_helper.ko 
insmod /lib/modules/6.2.0-rc4-PMacG4+/kernel/drivers/gpu/drm/tiny/ofdrm.ko 

However I get no monitor output yet, despite ofdrm is loaded:
 # lsmod | grep -i drm
ofdrm                   9736  0
drm_shmem_helper        5704  1 ofdrm
drm_kms_helper        101736  1 ofdrm
cfbfillrect             2896  1 drm_kms_helper
syscopyarea             2400  1 drm_kms_helper
cfbimgblt               2256  1 drm_kms_helper
sysfillrect             2920  1 drm_kms_helper
sysimgblt               2296  1 drm_kms_helper
cfbcopyarea             2376  1 drm_kms_helper
drm                   288960  3 drm_shmem_helper,ofdrm,drm_kms_helper
drm_panel_orientation_quirks       16  1 drm

I use DRM [=m], DRM_OFDRM [=m], DRM_RADEON [=n], DRM_FBDEV_EMULATION [=y], FB [=y] and FB_OF [=n] in my kernel test .config. As far as I understand  DRM_OFDRM and FB_OF would be mutually exclusive? Also does not seem to make a difference whether FB_SIMPLE [=y] is set.

Regards,
Erhard
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dmesg_62-rc4_g4
Type: application/octet-stream
Size: 65148 bytes
Desc: not available
URL: <http://lists.ozlabs.org/pipermail/linuxppc-dev/attachments/20230119/8db52fc2/attachment-0001.obj>


More information about the Linuxppc-dev mailing list