Hello,
I came accross strange behavior of psplash, that it draws only every second frame on the display. I have found out that it fails to wait to vsync and pan the buffers.
From the psplash debug messages I am getting:
Error, FB vsync ioctl [-1]
psplash_fb_flip: FBIOPAN_DISPLAY failed
In the code handling the FB, these parts are
int err = ioctl(fb->fd, FBIO_WAITFORVSYNC, 0);
if (err != 0)
fprintf(stderr, "Error, FB vsync ioctl [%d]\n", err);
...
if (ioctl(fb->fd, FBIOPAN_DISPLAY, &fb->fb_var) == -1 ) {
fprintf(stderr, "psplash_fb_flip: FBIOPAN_DISPLAY failed\n");
}
So it means both are failing with error -1. I added some more debug code to the source code to get the exact error and these are:
Error, FB vsync ioctl [-1]: Inappropriate ioctl for device
psplash_fb_flip: FBIOPAN_DISPLAY failed: Invalid argument
When the fb is created in psplash, the double buffering would be disabled by
/* Setup double virtual resolution for double buffering */
if (ioctl(fb->fd, FBIOPAN_DISPLAY, &fb_var) == -1) {
fprintf(stderr, "FBIOPAN_DISPLAY not supported, double buffering disabled");
But it is not disabled, so this means the ioctl must have passed once before. By adding more verbose debug messages into the code, I see it really passes. I don't know why now and not afterwards.
And that is where I end, because I have no experience with framebuffers.
So I would like to ask for help. Is there some settings needed in DTS to enable double buffering? Disabling it completely would also be fine for me. But I don't know how.
Any hints will be appreciated.
Thanks, Michal