Re: [PATCH 1/1] i2c: designware: reverts "i2c: designware: Add support for AMD I2C controller"
On Fri, Oct 23, 2015 at 01:28:47PM +0800, Ken Xue wrote: > The patch reverts commit a445900c9060 (i2c: designware: Add support for > AMD I2C controller) > > Since kernel starts to support APD(drivers/acpi/acpi_apd.c), there is > no need to get freq from id->driver_data for AMD0010. clkdev is supposed > to be already registered in APD. > > So, revert old design and make AMD0010 looks like other ones. > > Signed-off-by: Ken Xue > Signed-off-by: Xiangliang Yu Updated the commit msg a little and applied to for-next, thanks! signature.asc Description: Digital signature
Re: [PATCH 1/1] i2c: designware: reverts "i2c: designware: Add support for AMD I2C controller"
On Fri, Oct 23, 2015 at 01:28:47PM +0800, Ken Xue wrote: > The patch reverts commit a445900c9060 (i2c: designware: Add support for > AMD I2C controller) > > Since kernel starts to support APD(drivers/acpi/acpi_apd.c), there is > no need to get freq from id->driver_data for AMD0010. clkdev is supposed > to be already registered in APD. > > So, revert old design and make AMD0010 looks like other ones. > > Signed-off-by: Ken Xue > Signed-off-by: Xiangliang Yu You could also mention that the commit never even worked. Anyway, I'm happy that this is removed so Acked-by: Mika Westerberg -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH 1/1] i2c: designware: reverts "i2c: designware: Add support for AMD I2C controller"
On Fri, Oct 23, 2015 at 01:28:47PM +0800, Ken Xue wrote: > The patch reverts commit a445900c9060 (i2c: designware: Add support for > AMD I2C controller) > > Since kernel starts to support APD(drivers/acpi/acpi_apd.c), there is > no need to get freq from id->driver_data for AMD0010. clkdev is supposed > to be already registered in APD. > > So, revert old design and make AMD0010 looks like other ones. > > Signed-off-by: Ken Xue> Signed-off-by: Xiangliang Yu Updated the commit msg a little and applied to for-next, thanks! signature.asc Description: Digital signature
Re: [PATCH 1/1] i2c: designware: reverts "i2c: designware: Add support for AMD I2C controller"
On Fri, Oct 23, 2015 at 01:28:47PM +0800, Ken Xue wrote: > The patch reverts commit a445900c9060 (i2c: designware: Add support for > AMD I2C controller) > > Since kernel starts to support APD(drivers/acpi/acpi_apd.c), there is > no need to get freq from id->driver_data for AMD0010. clkdev is supposed > to be already registered in APD. > > So, revert old design and make AMD0010 looks like other ones. > > Signed-off-by: Ken Xue> Signed-off-by: Xiangliang Yu You could also mention that the commit never even worked. Anyway, I'm happy that this is removed so Acked-by: Mika Westerberg -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[PATCH 1/1] i2c: designware: reverts "i2c: designware: Add support for AMD I2C controller"
The patch reverts commit a445900c9060 (i2c: designware: Add support for AMD I2C controller) Since kernel starts to support APD(drivers/acpi/acpi_apd.c), there is no need to get freq from id->driver_data for AMD0010. clkdev is supposed to be already registered in APD. So, revert old design and make AMD0010 looks like other ones. Signed-off-by: Ken Xue Signed-off-by: Xiangliang Yu --- drivers/i2c/busses/i2c-designware-platdrv.c | 27 +-- 1 file changed, 1 insertion(+), 26 deletions(-) diff --git a/drivers/i2c/busses/i2c-designware-platdrv.c b/drivers/i2c/busses/i2c-designware-platdrv.c index 472b882..4bf5fc1 100644 --- a/drivers/i2c/busses/i2c-designware-platdrv.c +++ b/drivers/i2c/busses/i2c-designware-platdrv.c @@ -97,7 +97,6 @@ static void dw_i2c_acpi_params(struct platform_device *pdev, char method[], static int dw_i2c_acpi_configure(struct platform_device *pdev) { struct dw_i2c_dev *dev = platform_get_drvdata(pdev); - const struct acpi_device_id *id; dev->adapter.nr = -1; dev->tx_fifo_depth = 32; @@ -111,29 +110,9 @@ static int dw_i2c_acpi_configure(struct platform_device *pdev) dw_i2c_acpi_params(pdev, "FMCN", >fs_hcnt, >fs_lcnt, >sda_hold_time); - /* -* Provide a way for Designware I2C host controllers that are not -* based on Intel LPSS to specify their input clock frequency via -* id->driver_data. -*/ - id = acpi_match_device(pdev->dev.driver->acpi_match_table, >dev); - if (id && id->driver_data) - clk_register_fixed_rate(>dev, dev_name(>dev), NULL, - CLK_IS_ROOT, id->driver_data); - return 0; } -static void dw_i2c_acpi_unconfigure(struct platform_device *pdev) -{ - struct dw_i2c_dev *dev = platform_get_drvdata(pdev); - const struct acpi_device_id *id; - - id = acpi_match_device(pdev->dev.driver->acpi_match_table, >dev); - if (id && id->driver_data) - clk_unregister(dev->clk); -} - static const struct acpi_device_id dw_i2c_acpi_match[] = { { "INT33C2", 0 }, { "INT33C3", 0 }, @@ -141,7 +120,7 @@ static const struct acpi_device_id dw_i2c_acpi_match[] = { { "INT3433", 0 }, { "80860F41", 0 }, { "808622C1", 0 }, - { "AMD0010", 133 * 1000 * 1000 }, + { "AMD0010", 0 }, { } }; MODULE_DEVICE_TABLE(acpi, dw_i2c_acpi_match); @@ -150,7 +129,6 @@ static inline int dw_i2c_acpi_configure(struct platform_device *pdev) { return -ENODEV; } -static inline void dw_i2c_acpi_unconfigure(struct platform_device *pdev) { } #endif static int dw_i2c_probe(struct platform_device *pdev) @@ -306,9 +284,6 @@ static int dw_i2c_remove(struct platform_device *pdev) pm_runtime_put_sync(>dev); pm_runtime_disable(>dev); - if (has_acpi_companion(>dev)) - dw_i2c_acpi_unconfigure(pdev); - return 0; } -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[PATCH 1/1] i2c: designware: reverts "i2c: designware: Add support for AMD I2C controller"
The patch reverts commit a445900c9060 (i2c: designware: Add support for AMD I2C controller) Since kernel starts to support APD(drivers/acpi/acpi_apd.c), there is no need to get freq from id->driver_data for AMD0010. clkdev is supposed to be already registered in APD. So, revert old design and make AMD0010 looks like other ones. Signed-off-by: Ken XueSigned-off-by: Xiangliang Yu --- drivers/i2c/busses/i2c-designware-platdrv.c | 27 +-- 1 file changed, 1 insertion(+), 26 deletions(-) diff --git a/drivers/i2c/busses/i2c-designware-platdrv.c b/drivers/i2c/busses/i2c-designware-platdrv.c index 472b882..4bf5fc1 100644 --- a/drivers/i2c/busses/i2c-designware-platdrv.c +++ b/drivers/i2c/busses/i2c-designware-platdrv.c @@ -97,7 +97,6 @@ static void dw_i2c_acpi_params(struct platform_device *pdev, char method[], static int dw_i2c_acpi_configure(struct platform_device *pdev) { struct dw_i2c_dev *dev = platform_get_drvdata(pdev); - const struct acpi_device_id *id; dev->adapter.nr = -1; dev->tx_fifo_depth = 32; @@ -111,29 +110,9 @@ static int dw_i2c_acpi_configure(struct platform_device *pdev) dw_i2c_acpi_params(pdev, "FMCN", >fs_hcnt, >fs_lcnt, >sda_hold_time); - /* -* Provide a way for Designware I2C host controllers that are not -* based on Intel LPSS to specify their input clock frequency via -* id->driver_data. -*/ - id = acpi_match_device(pdev->dev.driver->acpi_match_table, >dev); - if (id && id->driver_data) - clk_register_fixed_rate(>dev, dev_name(>dev), NULL, - CLK_IS_ROOT, id->driver_data); - return 0; } -static void dw_i2c_acpi_unconfigure(struct platform_device *pdev) -{ - struct dw_i2c_dev *dev = platform_get_drvdata(pdev); - const struct acpi_device_id *id; - - id = acpi_match_device(pdev->dev.driver->acpi_match_table, >dev); - if (id && id->driver_data) - clk_unregister(dev->clk); -} - static const struct acpi_device_id dw_i2c_acpi_match[] = { { "INT33C2", 0 }, { "INT33C3", 0 }, @@ -141,7 +120,7 @@ static const struct acpi_device_id dw_i2c_acpi_match[] = { { "INT3433", 0 }, { "80860F41", 0 }, { "808622C1", 0 }, - { "AMD0010", 133 * 1000 * 1000 }, + { "AMD0010", 0 }, { } }; MODULE_DEVICE_TABLE(acpi, dw_i2c_acpi_match); @@ -150,7 +129,6 @@ static inline int dw_i2c_acpi_configure(struct platform_device *pdev) { return -ENODEV; } -static inline void dw_i2c_acpi_unconfigure(struct platform_device *pdev) { } #endif static int dw_i2c_probe(struct platform_device *pdev) @@ -306,9 +284,6 @@ static int dw_i2c_remove(struct platform_device *pdev) pm_runtime_put_sync(>dev); pm_runtime_disable(>dev); - if (has_acpi_companion(>dev)) - dw_i2c_acpi_unconfigure(pdev); - return 0; } -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/