diff options
author | Yicong Yang <yangyicong@hisilicon.com> | 2022-06-10 09:51:06 +0200 |
---|---|---|
committer | Wolfram Sang <wsa@kernel.org> | 2022-06-15 22:40:13 +0200 |
commit | 4dc1372ffb82c5f08ada7b9cb75a04dcfe49cd96 (patch) | |
tree | 8dafdfaef8bdbfd6f6acc60dc60b55489940bf7f /drivers/i2c | |
parent | i2c: qcom-cci: add msm8974 compatible (diff) | |
download | linux-4dc1372ffb82c5f08ada7b9cb75a04dcfe49cd96.tar.xz linux-4dc1372ffb82c5f08ada7b9cb75a04dcfe49cd96.zip |
i2c: hisi: use HZ_PER_KHZ macro in units.h
HZ macros has been centralized in units.h since [1]. Use it to avoid
duplicated definition.
[1] commit e2c77032fcbe ("units: add the HZ macros")
Signed-off-by: Yicong Yang <yangyicong@hisilicon.com>
Signed-off-by: Wolfram Sang <wsa@kernel.org>
Diffstat (limited to 'drivers/i2c')
-rw-r--r-- | drivers/i2c/busses/i2c-hisi.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/i2c/busses/i2c-hisi.c b/drivers/i2c/busses/i2c-hisi.c index acf394812061..76c3d8f6fc3c 100644 --- a/drivers/i2c/busses/i2c-hisi.c +++ b/drivers/i2c/busses/i2c-hisi.c @@ -15,6 +15,7 @@ #include <linux/mod_devicetable.h> #include <linux/platform_device.h> #include <linux/property.h> +#include <linux/units.h> #define HISI_I2C_FRAME_CTRL 0x0000 #define HISI_I2C_FRAME_CTRL_SPEED_MODE GENMASK(1, 0) @@ -80,8 +81,6 @@ #define HISI_I2C_TX_F_AE_THRESH 1 #define HISI_I2C_RX_F_AF_THRESH 60 -#define HZ_PER_KHZ 1000 - #define NSEC_TO_CYCLES(ns, clk_rate_khz) \ DIV_ROUND_UP_ULL((clk_rate_khz) * (ns), NSEC_PER_MSEC) |