rpmsgfs: add tty fd ioctl(TCGETS/TCSETS) support

rpmsgfs client ioctl support TCDRN/TCFLSH/TCGETS/TCSETS

Signed-off-by: fangzhenwei <fangzhenwei@xiaomi.com>
This commit is contained in:
fangzhenwei 2023-12-18 20:23:09 +08:00 committed by Mateusz Szafoni
parent 536ed46ac4
commit 439c52937a

View File

@ -27,6 +27,7 @@
#include <string.h>
#include <stdio.h>
#include <sys/uio.h>
#include <termios.h>
#include <fcntl.h>
#include <nuttx/kmalloc.h>
@ -396,6 +397,12 @@ static ssize_t rpmsgfs_ioctl_arglen(int cmd)
return sizeof(int);
case FIOC_FILEPATH:
return PATH_MAX;
case TCDRN:
case TCFLSH:
return 0;
case TCGETS:
case TCSETS:
return sizeof(struct termios);
case FIOC_SETLK:
case FIOC_GETLK:
case FIOC_SETLKW: