Revert parts of r391855 that were not ready to go in to trunk