cgpt: Use subprocess_run to call flashrom with 1>/dev/null
Closing fd=1 is a bad idea, as flashrom will then reuse fd=1 for
the MTD device and directly write to it.
Luckily, we have a subprocess_run function in vboot that does
what we need. There will be some cleanup required after this,
but hopefully this is enough to clear the P0 on hand.
TEST=`cgpt find -t kernel` (fails?!), but at least does not
`flashrom -r /usr/local/x.bin && hexdump -C /usr/local/x.bin | head`
Signed-off-by: Nicolas Boichat <firstname.lastname@example.org>
Reviewed-by: Mike Frysinger <email@example.com>
Reviewed-by: Jack Rosenthal <firstname.lastname@example.org>
Commit-Queue: Jack Rosenthal <email@example.com>
1 file changed