Court reverses earlier ruling to clear way for Musk’s US$56bn pay package