Skip to contentSkip to conversation

crypto: atmel-i2c - Replace hard-coded bus clock rate with constant

PATCH In review Thorsten Blum 2 participants 2 messages Feb 23 – Mar 7

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 crypto: atmel-i2c - Replace hard-coded bus clock rate with constant

Replace 1000000L with I2C_MAX_FAST_MODE_PLUS_FREQ.

---
 drivers/crypto/atmel-i2c.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/crypto/atmel-i2c.c +1 -1
index ba9d3f593601..316a0ad53cf6 100644
@@ -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;
Signature · 2 lines
Thorsten Blum <[email protected]>
GPG: 1D60 735E 8AEF 3BE4 73B6  9D84 7336 78FD 8DFE EAD4
maintainer
#1 lore raw
Quoted 6 lines · Thorsten Blum

Replace 1000000L with I2C_MAX_FAST_MODE_PLUS_FREQ.

---
 drivers/crypto/atmel-i2c.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch applied. Thanks.

Signature · 3 lines
Email: Herbert Xu <[email protected]>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt