Only modify the 3 related bits when setting a GPIO function.