Registering device with server for GCM