Some other backportable changes inspired by the 2.11.x branch