I don't know when this is necessary, but sometimes the pl2303 on an espressobin board blocks on open() otherwise. kermit uses O_NONBLOCK, too. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> --- serial.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/serial.c b/serial.c index 00b817d9c94f..0778fe1d8698 100644 --- a/serial.c +++ b/serial.c @@ -203,7 +203,7 @@ struct ios_ops * serial_init(char *device) close(fd); force: /* open the device */ - fd = open(device, O_RDWR); + fd = open(device, O_RDWR | O_NONBLOCK); ops->fd = fd; if (fd < 0) { -- 2.16.1
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> --- COPYING | 3 ++- configure.ac | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/COPYING b/COPYING index 334c1fd31758..d7c552d86d0e 100644 --- a/COPYING +++ b/COPYING @@ -11,7 +11,8 @@ line reading: Signed-off-by: Random J Developer <random@developer.example.org> -with your real name and email address at the end of the patch description. +with your real name and email address at the end of the patch description +and send it to oss-tools@pengutronix.de. -------------------------------------------------------------------------------- GNU GENERAL PUBLIC LICENSE diff --git a/configure.ac b/configure.ac index 7c10785547da..b98cc6d21908 100644 --- a/configure.ac +++ b/configure.ac @@ -1,4 +1,4 @@ -AC_INIT([microcom], [2016.01.0]) +AC_INIT([microcom], [2016.01.0], [oss-tools@pengutronix.de]) AC_CONFIG_AUX_DIR([build-aux]) AC_CONFIG_MACRO_DIR([m4]) AM_INIT_AUTOMAKE([dist-xz]) -- 2.16.1
On Tue, Mar 06, 2018 at 10:44:43AM +0100, Uwe Kleine-König wrote: > I don't know when this is necessary, but sometimes the pl2303 on an > espressobin board blocks on open() otherwise. kermit uses O_NONBLOCK, > too. > > Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> I forgot to note: These are microcom patches. Best regards Uwe -- Pengutronix e.K. | Uwe Kleine-König | Industrial Linux Solutions | http://www.pengutronix.de/ | _______________________________________________ OSS-Tools mailing list OSS-Tools@pengutronix.de