In short, values of registers are not changed or set to 0 automatically.
Assuming a new stack frame is created via the save instruction (or some other means), the arguments passed to the %o0 to %o5 registers become %i0 to %i5 to the callee and that routine can change those register values.
So, when the register window is restored, you are not even guaranteed the values you put in the %ox registers are preserved as the callee may have changed them.
Remember that the out registers become the in registers to the callee. That's why the callee puts the return value in %i0 and restores the register window. Then back at the caller, the return value is in %o0.
The same holds true for leaf routines. In this case however, the routine only has access to the %o0 to %o5 registers to perform its work.
When returning from either routine, the contents of the %ox registers will be whatever was left.
In addition, %o6 and %o7 hold the addresses of the stack pointer and program counter, respectively.