Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0b987dcd authored by Jean Delvare's avatar Jean Delvare Committed by Jean Delvare
Browse files

i2c: Drop legacy locking in i2c_new_probed_device



It is no longer required to hold adapter->clist_lock to call
i2c_check_addr.

Signed-off-by: default avatarJean Delvare <khali@linux-fr.org>
Cc: David Brownell <david-b@pacbell.net>
parent 9ddced16
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -1086,7 +1086,6 @@ i2c_new_probed_device(struct i2c_adapter *adap,
		return NULL;
	}

	mutex_lock(&adap->clist_lock);
	for (i = 0; addr_list[i] != I2C_CLIENT_END; i++) {
		/* Check address validity */
		if (addr_list[i] < 0x03 || addr_list[i] > 0x77) {
@@ -1124,7 +1123,6 @@ i2c_new_probed_device(struct i2c_adapter *adap,
				break;
		}
	}
	mutex_unlock(&adap->clist_lock);

	if (addr_list[i] == I2C_CLIENT_END) {
		dev_dbg(&adap->dev, "Probing failed, no device found\n");