Merge pull request #15759 from basilfx/feature/bmx280_release

drivers/bmx280: add missing _release
This commit is contained in:
Alexandre Abadie 2021-01-13 09:04:47 +01:00 committed by GitHub
commit 2e0e5a5477
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -255,6 +255,7 @@ int bmx280_init(bmx280_t *dev, const bmx280_params_t *params)
/* test the connection to the device by reading and verifying its chip ID */
if (_read_reg(dev, BMX280_CHIP_ID_REG, &reg) != BMX280_OK) {
DEBUG("[bmx280] error: unable to read chip ID from device\n");
_release(dev);
return BMX280_ERR_NODEV;
}
if (reg != BMX280_CHIP_ID_VAL) {