mirror of
https://github.com/linux-msm/laptops-kernel.git
synced 2026-08-13 14:19:53 -07:00
crypto: atmel-i2c - Replace hard-coded bus clock rate with constant
Replace 1000000L with I2C_MAX_FAST_MODE_PLUS_FREQ. Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
This commit is contained in:
committed by
Herbert Xu
parent
3193dd7e84
commit
68e96c9736
@@ -370,7 +370,7 @@ int atmel_i2c_probe(struct i2c_client *client)
|
||||
}
|
||||
}
|
||||
|
||||
if (bus_clk_rate > 1000000L) {
|
||||
if (bus_clk_rate > I2C_MAX_FAST_MODE_PLUS_FREQ) {
|
||||
dev_err(dev, "%u exceeds maximum supported clock frequency (1MHz)\n",
|
||||
bus_clk_rate);
|
||||
return -EINVAL;
|
||||
|
||||
Reference in New Issue
Block a user