mirror of
https://github.com/apache/nuttx.git
synced 2026-05-30 13:27:01 +08:00
video/fb: initializes the info structure
Signed-off-by: pengyiqiang <pengyiqiang@xiaomi.com>
This commit is contained in:
committed by
Petro Karashchenko
parent
fd0d6a9bf5
commit
72fdea5c13
@@ -388,6 +388,7 @@ static int fb_ioctl(FAR struct file *filep, int cmd, unsigned long arg)
|
|||||||
|
|
||||||
DEBUGASSERT(fb->vtable != NULL &&
|
DEBUGASSERT(fb->vtable != NULL &&
|
||||||
fb->vtable->getoverlayinfo != NULL);
|
fb->vtable->getoverlayinfo != NULL);
|
||||||
|
memset(&oinfo, 0, sizeof(oinfo));
|
||||||
ret = fb->vtable->getoverlayinfo(fb->vtable, arg, &oinfo);
|
ret = fb->vtable->getoverlayinfo(fb->vtable, arg, &oinfo);
|
||||||
if (ret == OK)
|
if (ret == OK)
|
||||||
{
|
{
|
||||||
@@ -555,6 +556,7 @@ static int fb_ioctl(FAR struct file *filep, int cmd, unsigned long arg)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
memset(&pinfo, 0, sizeof(pinfo));
|
||||||
ret = fb->vtable->getplaneinfo(fb->vtable, fb->plane, &pinfo);
|
ret = fb->vtable->getplaneinfo(fb->vtable, fb->plane, &pinfo);
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
{
|
{
|
||||||
@@ -648,6 +650,7 @@ static int fb_ioctl(FAR struct file *filep, int cmd, unsigned long arg)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
memset(&pinfo, 0, sizeof(pinfo));
|
||||||
ret = fb->vtable->getplaneinfo(fb->vtable, fb->plane, &pinfo);
|
ret = fb->vtable->getplaneinfo(fb->vtable, fb->plane, &pinfo);
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
{
|
{
|
||||||
@@ -826,6 +829,7 @@ int fb_register(int display, int plane)
|
|||||||
DEBUGASSERT(vinfo.nplanes > 0 && (unsigned)plane < vinfo.nplanes);
|
DEBUGASSERT(vinfo.nplanes > 0 && (unsigned)plane < vinfo.nplanes);
|
||||||
|
|
||||||
DEBUGASSERT(fb->vtable->getplaneinfo != NULL);
|
DEBUGASSERT(fb->vtable->getplaneinfo != NULL);
|
||||||
|
memset(&pinfo, 0, sizeof(pinfo));
|
||||||
ret = fb->vtable->getplaneinfo(fb->vtable, plane, &pinfo);
|
ret = fb->vtable->getplaneinfo(fb->vtable, plane, &pinfo);
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
{
|
{
|
||||||
@@ -845,6 +849,7 @@ int fb_register(int display, int plane)
|
|||||||
/* Initialize first overlay but do not select */
|
/* Initialize first overlay but do not select */
|
||||||
|
|
||||||
DEBUGASSERT(fb->vtable->getoverlayinfo != NULL);
|
DEBUGASSERT(fb->vtable->getoverlayinfo != NULL);
|
||||||
|
memset(&oinfo, 0, sizeof(oinfo));
|
||||||
ret = fb->vtable->getoverlayinfo(fb->vtable, 0, &oinfo);
|
ret = fb->vtable->getoverlayinfo(fb->vtable, 0, &oinfo);
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user