Maybe I should just stick with hardware solution:
54AHCT125 quad buffer (3V->5V logic converter) with 3-state outputs. It has output enable. I can have two of them convert pi's MOSI, SCK, from 3V to 5V, along with GPIO25 to reset Arduino and TX (serial) to Arduino RX. On Arduino side, switch off OE on these first two pins after reset so Arduino can use these pins. Upon arduino reset, these OE are pulled low by a pulldown resistor to allow pi to use the pins to program arduino.
For MISO, I'll find a corresponding chip that does 5V-3V with OE so I can disconnect it from pi.
Arduino data loggers, user interface, printed circuit board designer since 2009, RPI 3B 2B 2B Zero Jessie, assembly/C/C++/java/python programmer since the 80's