xiaoxiang781216 commented on a change in pull request #2208: URL: https://github.com/apache/incubator-nuttx/pull/2208#discussion_r517081420
########## File path: drivers/lcd/lcd_dev.c ########## @@ -123,20 +123,56 @@ static int lcddev_ioctl(FAR struct file *filep, int cmd, unsigned long arg) { case LCDDEVIO_GETRUN: { - FAR struct lcddev_run_s *lcd_putrun = + FAR struct lcddev_run_s *lcd_run = (FAR struct lcddev_run_s *)arg; - ret = priv->planeinfo.getrun(lcd_putrun->row, lcd_putrun->col, - lcd_putrun->data, lcd_putrun->npixels); + ret = priv->planeinfo.getrun(lcd_run->row, lcd_run->col, + lcd_run->data, lcd_run->npixels); } break; case LCDDEVIO_PUTRUN: { - const FAR struct lcddev_run_s *lcd_putrun = + const FAR struct lcddev_run_s *lcd_run = (const FAR struct lcddev_run_s *)arg; - ret = priv->planeinfo.putrun(lcd_putrun->row, lcd_putrun->col, - lcd_putrun->data, lcd_putrun->npixels); + ret = priv->planeinfo.putrun(lcd_run->row, lcd_run->col, + lcd_run->data, lcd_run->npixels); + } + break; + case LCDDEVIO_PUTAREA: + { + const FAR struct lcddev_area_s *lcd_area = + (const FAR struct lcddev_area_s *)arg; + + if (priv->planeinfo.putarea) + { + ret = priv->planeinfo.putarea(lcd_area->row_start, Review comment: Yes, LVGL use the internal buffer to do the drawing, but there are many GUI library directly talk to the underlying "frame buffer" directly. In this case, lcd_framebuffer is very useful. Also the patch isn't complete from the implementation point: why lcd_dev support putarea but lcd_framebuffer not? We should support FB/LCD uerspace API equally unless you remove lcd_framebuffer.c from the code base. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org