Revert "Merged changes from upstream"

This reverts commit 17e808ca0588d946abb38fcc96a0ede61337ef5b, reversing
changes made to c692f58d2c7510b1955c0a0624bee8cf79118eb2.