Merge in changes from upstream

Bring in changes from upstream.