0

I am just using the drm driver for coding my custom vop driver for rockchip. It's working but I have a problem, the vop is not triggering the irqs and I am not able to use the status registers for detect the vblank region. Here's my code

status=*((unsigned int *)(vop+RK3328_INTR_STATUS0))

but it is always 0. I enabled the irqs in the vop register but nothing happens. Thanks for help

Lino
  • 7
  • 4
  • What's the type of `vop`? Also, you should probably cast it to `volatile unsigned int *` to ensure the compiler doesn't reorder the read. – G. Sliepen Sep 09 '21 at 10:45
  • Excuse me...vop is visual output processor...anyway vop is base address for 32bits IO ports. Sure I am using volatile keyword and I am using it for draw a red rectangle on video. I need the blank signal for vsync but the status register is always empty. I am using this repo https://github.com/hanwckf/linux-rk3328-box/tree/master/drivers/gpu/drm/rockchip – Lino Sep 09 '21 at 12:58
  • I meant, what is the type of the *variable* `vop`? If it's not something like `char *` or `uint8_t *`, you're probably doing something wrong. Without seeing the rest of *your* code, it's hard for us to know what's wrong. – G. Sliepen Sep 09 '21 at 14:25
  • Ohh yeah pardon It is a costant like #define 0xffff0000. Try here https://github.com/linoma/rk3328-bare-metal/blob/main/main.c It is a old version. Line 347 – Lino Sep 09 '21 at 15:24

0 Answers0