[libosmocore PATCH v3] src/serial.c: Add serial helper read and write function