Backport from 72X scramv1.