prima: Reapply fixes after upgrade to 3.2.2.2

Change-Id: I9315c6a67312d4d43f92146262970b23d49b4824