** Also affects: linux-raspi (Ubuntu Focal)
   Importance: Undecided
       Status: New

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux-raspi in Ubuntu.
https://bugs.launchpad.net/bugs/1880125

Title:
  v3d driver clock problem forces OpenGL to use software rendering

Status in linux-raspi package in Ubuntu:
  Confirmed
Status in linux-raspi source package in Focal:
  New

Bug description:
  release: 32-bit ubuntu 20.04 running on a raspberry pi 4
  package: linux-raspi 5.4.0.1008.8

  I made the configuration change described in:
        https://bugs.launchpad.net/ubuntu/+source/linux-raspi/+bug/1876862
  and am running a kernel with v3d on a raspberry pi 4.

  Unfortunately, OpenGL is still not using the GPU; it's using the
  software renderer, llvmpipe.

  Setting LIBGL_DEBUG=verbose and running an OpenGL program shows that
  OpenGL can't open any /dev/dri/renderD* device.

  Looking in /dev/dri, there are no device files that begin with
  "render," indicating the v3d driver isn't starting up properly.

  Adding debugging code to the kernel, I find that:
  (1) drivers/gpu/drm/v3d/v3d_drv.c:v3d_platform_drm_probe() fails because it 
can't get a clock - devm_clk_get() returns an error.
  (2) in drivers/clk/clk.c:of_clk_get_hw(), the call to of_parse_clkspec() for 
the v3d driver yields a desired clock source of "firmware-clocks".
  (3) drivers/clk/clk.c:of_clk_get_hw_from_clkspec() fails because it can only 
find six clock providers (aux@7e215000, cprman@7e101000, clock@7ef00000, 
clk-108M, clk-usb, clk-osc) none of which match the requested "firmware-clocks".

  The solution is to add a clock definition to the kernel source and a
  corresponding change to the device tree, but I'm not familiar enough
  with either to create that solution myself.

  In the raspbian kernel source tree, drivers/clk/bcm/clk-raspberrypi.c
  defines BCM2835_CLOCK_V3D, but there is no corresponding definition in
  the ubuntu source tree.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux-raspi/+bug/1880125/+subscriptions

-- 
Mailing list: https://launchpad.net/~kernel-packages
Post to     : kernel-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kernel-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to