Skip to content
This repository was archived by the owner on Jun 24, 2025. It is now read-only.
This repository was archived by the owner on Jun 24, 2025. It is now read-only.

Getting mmap fail EINV with RPi4 #293

Description

@moroslantia

I try to use RPi4 with DRM dispplay driver

  drm_init();

    /*A small buffer for LittlevGL to draw the screen's content*/
    static lv_color_t buf[DISP_BUF_SIZE],buf1[DISP_BUF_SIZE];

    /*Initialize a descriptor for the buffer*/
    static lv_disp_draw_buf_t disp_buf;
    lv_disp_draw_buf_init(&disp_buf, buf, buf1, DISP_BUF_SIZE);

    /*Initialize and register a display driver*/
    static lv_disp_drv_t disp_drv;
    lv_disp_drv_init(&disp_drv);

    disp_drv.draw_buf   = &disp_buf;
    disp_drv.flush_cb   = drm_flush;
    disp_drv.wait_cb    = drm_wait_vsync;
    disp_drv.hor_res    = 800;
    disp_drv.ver_res    = 480;
    lv_disp_drv_register(&disp_drv);

When starting my program it fails with

drm: Found plane_id: 86 connector_id: 32 crtc_id: 96
drm: 2560x1440 (550mm X 310mm) pixel format AR24
error: mmap fail (errno 22)
error: DRM buffer allocation failed

Any idea what's wrong?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions