Merge branch 'i2c/for-4.19' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa...
[muen/linux.git] / drivers / i2c / busses / i2c-davinci.c
index 7379043711dfa89455abd65bce74ac08707073f9..11caafa0e050cd41e23885063b1ab12c16c5e8ee 100644 (file)
@@ -718,14 +718,14 @@ static int i2c_davinci_cpufreq_transition(struct notifier_block *nb,
 
        dev = container_of(nb, struct davinci_i2c_dev, freq_transition);
 
-       i2c_lock_adapter(&dev->adapter);
+       i2c_lock_bus(&dev->adapter, I2C_LOCK_ROOT_ADAPTER);
        if (val == CPUFREQ_PRECHANGE) {
                davinci_i2c_reset_ctrl(dev, 0);
        } else if (val == CPUFREQ_POSTCHANGE) {
                i2c_davinci_calc_clk_dividers(dev);
                davinci_i2c_reset_ctrl(dev, 1);
        }
-       i2c_unlock_adapter(&dev->adapter);
+       i2c_unlock_bus(&dev->adapter, I2C_LOCK_ROOT_ADAPTER);
 
        return 0;
 }