Small fixes to make this work with rec1_c321d.