i2c: pnx: Use generic definitions for bus frequencies
Subsystems (2)
PATCH 1/1 i2c: pnx: Use generic definitions for bus frequencies
Since we have generic definitions for bus frequencies, let's use them.
Signed-off-by Andy Shevchenko <[email protected]>
--- drivers/i2c/busses/i2c-pnx.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/i2c/busses/i2c-pnx.c +1 -2
@@ -24,7 +24,6 @@#include <linux/of.h> #define I2C_PNX_TIMEOUT_DEFAULT 10/* msec */ -#define I2C_PNX_SPEED_KHZ_DEFAULT 100#define I2C_PNX_REGION_SIZE 0x100struct i2c_pnx_mif {
@@ -606,12 +605,12 @@ static DEFINE_SIMPLE_DEV_PM_OPS(i2c_pnx_pm,static int i2c_pnx_probe (struct platform_device *pdev) { +u32 speed =I2C_MAX_STANDARD_MODE_FREQ ;unsigned long tmp;int ret =0 ;struct i2c_pnx_algo_data *alg_data;unsigned long freq;struct resource *res; -u32 speed =I2C_PNX_SPEED_KHZ_DEFAULT *1000 ; alg_data =devm_kzalloc (&pdev->dev,sizeof (*alg_data),GFP_KERNEL );if (!alg_data)
Signature · 1 line
2.50.1
Quoted 3 lines · Andy Shevchenko
Since we have generic definitions for bus frequencies, let's use them.
Signed-off-by Andy Shevchenko <[email protected]>
Reviewed-by Vladimir Zapolskiy <[email protected]>
Signature · 2 lines
Best wishes, Vladimir