Misc fixes for bad merge

This is likely to get squashed into the previous commit

Change-Id: Ie6c5ac30c16d7657ae8b0825dc151077407a76f4