Merge "Fix bug by re-reading int from parcel in DeviceState" into main