lava-outerr: Avoid any chance of buffering on Python side
This fixes an issue when output on feedback connections of FVP (aka FastModels, for use with which this utility was written in the first place) appeared only after the process terminated. The fix:
- Runs Python interpreter with -u (ubuffered) switch.
- Instantiates subprocess.Popen with bufsize=0 param.
- Reads from process in small chunks, to avoid blocking for long time.
Perhaps only one of these was needed to fix the issue at hand, but be future-proof and apply all.
Signed-off-by: Paul Sokolovsky paul.sokolovsky@linaro.org