backport upstream patches