JosefR
Posts: 8
Joined: Tue Feb 10, 2015 7:50 pm

Linux mainline device tree config for the VC4 driver?

Sat May 07, 2016 11:08 am

Hi,

I am trying to get the VC4 graphics running with mainline Linux (not the Raspberry Pi fork). The driver is already available, but it looks like the device tree config is still missing the VC4 driver.

Did anybody managed to get this working? There is a device tree overlay for the VC4 (https://github.com/raspberrypi/linux/bl ... verlay.dts) but this is not compatible to the mainline Linux device tree files for the Raspberry Pi (https://git.kernel.org/cgit/linux/kerne ... s/v4.6-rc6).


Update::
I now tried to set up the config for the mainline kernel but the kernel log still shows some errors for the drm driver:

Code: Select all

[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Linux version 4.5.0-rose ([email protected]) (gcc version 5.3.0 (GCC) ) #1 Sat May 7 20:46:45 CEST 2016
[    0.000000] CPU: ARMv7 Processor [410fc075] revision 5 (ARMv7), cr=10c53c7d
[    0.000000] CPU: div instructions available: patching division code
[    0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[    0.000000] Machine model: Raspberry Pi 2 Model B
[    0.000000] cma: Failed to reserve 256 MiB
[    0.000000] Memory policy: Data cache writeback
[    0.000000] On node 0 totalpages: 32768
[    0.000000] free_area_init_node: node 0, pgdat c08377d8, node_mem_map c7efb000
[    0.000000]   Normal zone: 256 pages used for memmap
[    0.000000]   Normal zone: 0 pages reserved
[    0.000000]   Normal zone: 32768 pages, LIFO batch:7
[    0.000000] ------------[ cut here ]------------
[    0.000000] WARNING: CPU: 0 PID: 0 at /home/josef/Projects/Software/rose/villa-os/build/tmp-glibc/work-shared/raspberrypi2/kernel-source/arch/arm/kernel/devtree.c:149 arm_dt_init_cpu_maps+0xfc/0x1a4()
[    0.000000] DT /cpu 2 nodes greater than max cores 1, capping them
[    0.000000] CPU: 0 PID: 0 Comm: swapper Not tainted 4.5.0-rose #1
[    0.000000] Hardware name: BCM2835
[    0.000000] [<c00166ec>] (unwind_backtrace) from [<c0013db0>] (show_stack+0x20/0x24)
[    0.000000] [<c0013db0>] (show_stack) from [<c0249e40>] (dump_stack+0x20/0x28)
[    0.000000] [<c0249e40>] (dump_stack) from [<c0023960>] (warn_slowpath_common+0x94/0xbc)
[    0.000000] [<c0023960>] (warn_slowpath_common) from [<c0023a04>] (warn_slowpath_fmt+0x40/0x48)
[    0.000000] [<c0023a04>] (warn_slowpath_fmt) from [<c077a35c>] (arm_dt_init_cpu_maps+0xfc/0x1a4)
[    0.000000] [<c077a35c>] (arm_dt_init_cpu_maps) from [<c0779978>] (setup_arch+0x760/0x924)
[    0.000000] [<c0779978>] (setup_arch) from [<c0776a28>] (start_kernel+0xbc/0x400)
[    0.000000] [<c0776a28>] (start_kernel) from [<00008078>] (0x8078)
[    0.000000] ---[ end trace f24b6c88ae00fa9a ]---
[    0.000000] DT missing boot CPU MPIDR[23:0], fall back to default cpu_logical_map
[    0.000000] CPU: All CPU(s) started in HYP mode.
[    0.000000] CPU: Virtualization extensions available.
[    0.000000] pcpu-alloc: s0 r0 d32768 u32768 alloc=1*32768
[    0.000000] pcpu-alloc: [0] 0 
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 32512
[    0.000000] Kernel command line: earlyprintk console=tty0 console=ttyAMA0 root=/dev/mmcblk0p2 rootfstype=ext4 rootwait
[    0.000000] PID hash table entries: 512 (order: -1, 2048 bytes)
[    0.000000] Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
[    0.000000] Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
[    0.000000] Memory: 120692K/131072K available (6056K kernel code, 426K rwdata, 1548K rodata, 424K init, 686K bss, 10380K reserved, 0K cma-reserved)
[    0.000000] Virtual kernel memory layout:
[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
[    0.000000]     fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)
[    0.000000]     vmalloc : 0xc8800000 - 0xff800000   ( 880 MB)
[    0.000000]     lowmem  : 0xc0000000 - 0xc8000000   ( 128 MB)
[    0.000000]       .text : 0xc0008000 - 0xc077548c   (7606 kB)
[    0.000000]       .init : 0xc0776000 - 0xc07e0000   ( 424 kB)
[    0.000000]       .data : 0xc07e0000 - 0xc084abc0   ( 427 kB)
[    0.000000]        .bss : 0xc084d000 - 0xc08f8b54   ( 687 kB)
[    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[    0.000000] NR_IRQS:16 nr_irqs:16 16
[    0.000029] sched_clock: 32 bits at 1000kHz, resolution 1000ns, wraps every 2147483647500ns
[    0.000066] clocksource: timer: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 1911260446275 ns
[    0.000142] bcm2835: system timer (irq = 33)
[    0.000532] Architected cp15 timer(s) running at 19.20MHz (phys).
[    0.000556] clocksource: arch_sys_counter: mask: 0xffffffffffffff max_cycles: 0x46d987e47, max_idle_ns: 440795202767 ns
[    0.000580] sched_clock: 56 bits at 19MHz, resolution 52ns, wraps every 4398046511078ns
[    0.000599] Switching to timer-based delay loop, resolution 52ns
[    0.000855] Console: colour dummy device 80x30
[    0.002726] console [tty0] enabled
[    0.002772] Calibrating delay loop (skipped), value calculated using timer frequency.. 38.40 BogoMIPS (lpj=192000)
[    0.002850] pid_max: default: 32768 minimum: 301
[    0.003226] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.003282] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.004443] CPU: Testing write buffer coherency: ok
[    0.004551] ftrace: allocating 21374 entries in 63 pages
[    0.061362] Setting up static identity map for 0x8200 - 0x824c
[    0.066429] devtmpfs: initialized
[    0.070453] VFP support v0.3: implementor 41 architecture 2 part 30 variant 7 rev 5
[    0.070855] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.071250] pinctrl core: initialized pinctrl subsystem
[    0.072038] NET: Registered protocol family 16
[    0.072931] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.078618] No ATAGs?
[    0.078669] hw-breakpoint: found 5 (+1 reserved) breakpoint and 4 watchpoint registers.
[    0.078743] hw-breakpoint: maximum watchpoint size is 8 bytes.
[    0.078940] Serial: AMBA PL011 UART driver
[    0.088614] SCSI subsystem initialized
[    0.089041] usbcore: registered new interface driver usbfs
[    0.089141] usbcore: registered new interface driver hub
[    0.089270] usbcore: registered new device driver usb
[    0.089719] Advanced Linux Sound Architecture Driver Initialized.
[    0.091697] clocksource: Switched to clocksource arch_sys_counter
[    0.135043] simple-framebuffer e898000.framebuffer: framebuffer at 0xe898000, 0x35d540 bytes, mapped to 0xc8c00000
[    0.135141] simple-framebuffer e898000.framebuffer: format=r5g6b5, mode=1680x1050x16, linelength=3360
[    0.166889] Console: switching to colour frame buffer device 210x65
[    0.197562] simple-framebuffer e898000.framebuffer: fb0: simplefb registered!
[    0.207713] NET: Registered protocol family 2
[    0.208877] TCP established hash table entries: 1024 (order: 0, 4096 bytes)
[    0.209125] TCP bind hash table entries: 1024 (order: 0, 4096 bytes)
[    0.209337] TCP: Hash tables configured (established 1024 bind 1024)
[    0.209669] UDP hash table entries: 256 (order: 0, 4096 bytes)
[    0.209868] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
[    0.210276] NET: Registered protocol family 1
[    0.210920] RPC: Registered named UNIX socket transport module.
[    0.211118] RPC: Registered udp transport module.
[    0.211263] RPC: Registered tcp transport module.
[    0.211407] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    0.212883] hw perfevents: enabled with armv7_cortex_a7 PMU driver, 5 counters available
[    0.214088] futex hash table entries: 256 (order: -1, 3072 bytes)
[    0.231525] Installing knfsd (copyright (C) 1996 [email protected]).
[    0.237166] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 253)
[    0.237429] io scheduler noop registered
[    0.237569] io scheduler deadline registered
[    0.238003] io scheduler cfq registered (default)
[    1.182428] bcm2835-rng 3f104000.rng: hwrng registered
[    1.182889] [drm] Initialized drm 1.1.0 20060810
[    1.184484] [drm:vc4_hdmi_bind] *ERROR* Failed to get pixel clock
[    1.184727] vc4-drm soc:[email protected]: failed to bind 3f902000.hdmi (ops vc4_hdmi_ops): -517
[    1.185088] vc4-drm soc:[email protected]: master bind failed: -517
[    1.186256] usbcore: registered new interface driver zd1211rw
[    1.186534] usbcore: registered new interface driver asix
[    1.186787] usbcore: registered new interface driver ax88179_178a
[    1.187056] usbcore: registered new interface driver cdc_ether
[    1.187330] usbcore: registered new interface driver smsc95xx
[    1.187591] usbcore: registered new interface driver net1080
[    1.187851] usbcore: registered new interface driver cdc_subset
[    1.188116] usbcore: registered new interface driver zaurus
[    1.188425] usbcore: registered new interface driver cdc_ncm
[    1.188890] dwc2 3f980000.usb: Configuration mismatch. dr_mode forced to host
[    1.381908] dwc2 3f980000.usb: DWC OTG Controller
[    1.390641] dwc2 3f980000.usb: new USB bus registered, assigned bus number 1
[    1.399365] dwc2 3f980000.usb: irq 39, io mem 0x00000000
[    1.409117] hub 1-0:1.0: USB hub found
[    1.417706] hub 1-0:1.0: 1 port detected
[    1.426822] usbcore: registered new interface driver usb-storage
[    1.435791] mousedev: PS/2 mouse device common for all mice
[    1.444723] i2c /dev entries driver
[    1.453366] i2c-bcm2835 3f205000.i2c: Could not get clock
[    1.461871] i2c-bcm2835 3f804000.i2c: Could not get clock
[    1.470164] i2c-bcm2835 3f805000.i2c: Could not get clock
[    1.478816] bcm2835-wdt 3f100000.watchdog: Broadcom BCM2835 watchdog timer
[    1.487129] sdhci: Secure Digital Host Controller Interface driver
[    1.495245] sdhci: Copyright(c) Pierre Ossman
[    1.503301] sdhci-pltfm: SDHCI platform and OF driver helper
[    1.512224] ledtrig-cpu: registered to indicate activity on CPUs
[    1.520766] usbcore: registered new interface driver usbhid
[    1.528806] usbhid: USB HID core driver
[    1.538456] bcm2835-mbox 3f00b880.mailbox: mailbox enabled
[    1.547440] oprofile: using timer interrupt.
[    1.557170] NET: Registered protocol family 10
[    1.566704] sit: IPv6 over IPv4 tunneling driver
[    1.575878] NET: Registered protocol family 17
[    1.585761] 3f201000.uart: ttyAMA0 at MMIO 0x3f201000 (irq = 87, base_baud = 0) is a PL011 rev2
[    1.866530] usb 1-1: new high-speed USB device number 2 using dwc2
[    2.082866] hub 1-1:1.0: USB hub found
[    2.082978] hub 1-1:1.0: 5 ports detected
[    2.393899] usb 1-1.1: new high-speed USB device number 3 using dwc2
[    2.446546] console [ttyAMA0] enabled
[    2.459704] vc4-drm soc:[email protected]: failed to bind 3f902000.hdmi (ops vc4_hdmi_ops): -517
[    2.476551] vc4-drm soc:[email protected]: master bind failed: -517
[    2.492219] i2c-bcm2835 3f805000.i2c: Could not read clock-frequency property
[    2.515129] smsc95xx v1.0.4
[    2.551720] mmc0: SDHCI controller on 3f300000.sdhci [3f300000.sdhci] using PIO
[    2.568261] raspberrypi-firmware soc:firmware: Attached to firmware from 2016-03-24 12:37
[    2.593439] vc4-drm soc:[email protected]: bound 3f902000.hdmi (ops vc4_hdmi_ops)
[    2.609193] vc4-drm soc:[email protected]: bound 3f206000.pixelvalve (ops vc4_crtc_ops)
[    2.628516] vc4-drm soc:[email protected]: bound 3f207000.pixelvalve (ops vc4_crtc_ops)
[    2.644550] vc4-drm soc:[email protected]: bound 3f807000.pixelvalve (ops vc4_crtc_ops)
[    2.660297] vc4-drm soc:[email protected]: bound 3f400000.hvs (ops vc4_hvs_ops)
[    2.675277] [drm:vc4_v3d_bind] *ERROR* V3D_IDENT0 read 0xdeadbeef instead of 0x02443356
[    2.691377] vc4-drm soc:[email protected]: failed to bind 3fc00000.v3d (ops vc4_v3d_ops): -22
[    2.709377] vc4-drm soc:[email protected]: master bind failed: -22
[    2.723429] vc4-drm: probe of soc:[email protected] failed with error -22
[    2.740514] ALSA device list:
[    2.751605]   No soundcards found.
[    2.765870] smsc95xx 1-1.1:1.0 eth0: register 'smsc95xx' at usb-3f980000.usb-1.1, smsc95xx USB 2.0 Ethernet, 6a:41:92:b0:62:5c
[    2.785881] uart-pl011 3f201000.uart: no DMA platform data
[    2.800092] Waiting for root device /dev/mmcblk0p2...
[    2.813773] mmc0: new SDHC card at address aaaa
[    2.827730] mmcblk0: mmc0:aaaa SL32G 28.8 GiB 
[    2.842628]  mmcblk0: p1 p2
[    2.922256] usb 1-1.2: new low-speed USB device number 4 using dwc2
[    2.969504] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
[    2.986149] VFS: Mounted root (ext4 filesystem) readonly on device 179:2.
[    3.002662] devtmpfs: mounted
[    3.015595] Freeing unused kernel memory: 424K (c0776000 - c07e0000)
[    3.093813] input: Logitech USB Keyboard as /devices/platform/soc/3f980000.usb/usb1/1-1/1-1.2/1-1.2:1.0/0003:046D:C31D.0001/input/input0
[    3.185708] hid-generic 0003:046D:C31D.0001: input: USB HID v1.10 Keyboard [Logitech USB Keyboard] on usb-3f980000.usb-1.2/input0
[    3.262322] input: Logitech USB Keyboard as /devices/platform/soc/3f980000.usb/usb1/1-1/1-1.2/1-1.2:1.1/0003:046D:C31D.0002/input/input1
[    3.343446] hid-generic 0003:046D:C31D.0002: input: USB HID v1.10 Device [Logitech USB Keyboard] on usb-3f980000.usb-1.2/input1
[    3.451767] usb 1-1.3: new low-speed USB device number 5 using dwc2
[    3.618023] input: Logitech USB Laser Mouse as /devices/platform/soc/3f980000.usb/usb1/1-1/1-1.3/1-1.3:1.0/0003:046D:C069.0003/input/input2
[    3.651836] hid-generic 0003:046D:C069.0003: input: USB HID v1.10 Mouse [Logitech USB Laser Mouse] on usb-3f980000.usb-1.3/input0
[    4.164547] random: nonblocking pool is initialized
[    4.438947] udevd[87]: starting version 3.1.5
[    5.648055] EXT4-fs (mmcblk0p2): re-mounted. Opts: data=ordered
[    9.655394] smsc95xx 1-1.1:1.0 eth0: hardware isn't capable of remote wakeup
[    9.662922] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
And this is how the device tree has been changed:
https://github.com/rose-project/meta-ra ... -GPU.patch

Return to “Linux Kernel”