Move page alignment code from the protocol to the upper interface layer to avoid duplication.