* [PATCH 0/8] opp: Unconditionally call dev_pm_opp_of_remove_table()
@ 2020-08-20 10:43 Viresh Kumar
2020-08-20 10:43 ` [PATCH 7/8] tty: serial: qcom_geni_serial: " Viresh Kumar
0 siblings, 1 reply; 2+ messages in thread
From: Viresh Kumar @ 2020-08-20 10:43 UTC (permalink / raw)
To: rnayak, Adrian Hunter, Andy Gross, Bjorn Andersson,
Daniel Vetter, David Airlie, Fabio Estevam, Greg Kroah-Hartman,
Jiri Slaby, Mark Brown, NXP Linux Team, Pengutronix Kernel Team,
Qiang Yu, Rafael J. Wysocki, Rob Clark, Sascha Hauer, Sean Paul,
Shawn Guo, Ulf Hansson, Viresh Kumar
Cc: linux-pm, Vincent Guittot, Stephen Boyd, Nishanth Menon,
dri-devel, freedreno, lima, linux-arm-kernel, linux-arm-msm,
linux-kernel, linux-mmc, linux-serial, linux-spi
Hello,
This cleans up some of the user code around calls to
dev_pm_opp_of_remove_table().
All the patches can be picked by respective maintainers directly except
for the last patch, which needs the previous two to get merged first.
These are based for 5.9-rc1.
Rajendra, Since most of these changes are related to qcom stuff, it
would be great if you can give them a try. I wasn't able to test them
due to lack of hardware.
Viresh Kumar (8):
cpufreq: imx6q: Unconditionally call dev_pm_opp_of_remove_table()
drm/lima: Unconditionally call dev_pm_opp_of_remove_table()
drm/msm: Unconditionally call dev_pm_opp_of_remove_table()
mmc: sdhci-msm: Unconditionally call dev_pm_opp_of_remove_table()
spi: spi-geni-qcom: Unconditionally call dev_pm_opp_of_remove_table()
spi: spi-qcom-qspi: Unconditionally call dev_pm_opp_of_remove_table()
tty: serial: qcom_geni_serial: Unconditionally call
dev_pm_opp_of_remove_table()
qcom-geni-se: remove has_opp_table
drivers/cpufreq/imx6q-cpufreq.c | 10 ++--------
drivers/gpu/drm/lima/lima_devfreq.c | 6 +-----
drivers/gpu/drm/lima/lima_devfreq.h | 1 -
drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 10 +++-------
drivers/gpu/drm/msm/disp/dpu1/dpu_kms.h | 1 -
drivers/gpu/drm/msm/dsi/dsi_host.c | 8 ++------
drivers/mmc/host/sdhci-msm.c | 11 +++--------
drivers/spi/spi-geni-qcom.c | 10 +++-------
drivers/spi/spi-qcom-qspi.c | 11 +++--------
drivers/tty/serial/qcom_geni_serial.c | 10 +++-------
include/linux/qcom-geni-se.h | 2 --
11 files changed, 20 insertions(+), 60 deletions(-)
--
2.25.0.rc1.19.g042ed3e048af
^ permalink raw reply [flat|nested] 2+ messages in thread
* [PATCH 7/8] tty: serial: qcom_geni_serial: Unconditionally call dev_pm_opp_of_remove_table()
2020-08-20 10:43 [PATCH 0/8] opp: Unconditionally call dev_pm_opp_of_remove_table() Viresh Kumar
@ 2020-08-20 10:43 ` Viresh Kumar
0 siblings, 0 replies; 2+ messages in thread
From: Viresh Kumar @ 2020-08-20 10:43 UTC (permalink / raw)
To: rnayak, Andy Gross, Bjorn Andersson, Greg Kroah-Hartman, Jiri Slaby
Cc: Viresh Kumar, linux-pm, Vincent Guittot, Rafael Wysocki,
Stephen Boyd, Nishanth Menon, linux-arm-msm, linux-serial,
linux-kernel
dev_pm_opp_of_remove_table() doesn't report any errors when it fails to
find the OPP table with error -ENODEV (i.e. OPP table not present for
the device). And we can call dev_pm_opp_of_remove_table()
unconditionally here.
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
---
drivers/tty/serial/qcom_geni_serial.c | 10 +++-------
1 file changed, 3 insertions(+), 7 deletions(-)
diff --git a/drivers/tty/serial/qcom_geni_serial.c b/drivers/tty/serial/qcom_geni_serial.c
index 3aa29d201f54..e4c90a76e6ac 100644
--- a/drivers/tty/serial/qcom_geni_serial.c
+++ b/drivers/tty/serial/qcom_geni_serial.c
@@ -1433,9 +1433,7 @@ static int qcom_geni_serial_probe(struct platform_device *pdev)
return PTR_ERR(port->se.opp_table);
/* OPP table is optional */
ret = dev_pm_opp_of_add_table(&pdev->dev);
- if (!ret) {
- port->se.has_opp_table = true;
- } else if (ret != -ENODEV) {
+ if (ret != -ENODEV) {
dev_err(&pdev->dev, "invalid OPP table in device tree\n");
return ret;
}
@@ -1478,8 +1476,7 @@ static int qcom_geni_serial_probe(struct platform_device *pdev)
return 0;
err:
- if (port->se.has_opp_table)
- dev_pm_opp_of_remove_table(&pdev->dev);
+ dev_pm_opp_of_remove_table(&pdev->dev);
dev_pm_opp_put_clkname(port->se.opp_table);
return ret;
}
@@ -1489,8 +1486,7 @@ static int qcom_geni_serial_remove(struct platform_device *pdev)
struct qcom_geni_serial_port *port = platform_get_drvdata(pdev);
struct uart_driver *drv = port->private_data.drv;
- if (port->se.has_opp_table)
- dev_pm_opp_of_remove_table(&pdev->dev);
+ dev_pm_opp_of_remove_table(&pdev->dev);
dev_pm_opp_put_clkname(port->se.opp_table);
dev_pm_clear_wake_irq(&pdev->dev);
device_init_wakeup(&pdev->dev, false);
--
2.25.0.rc1.19.g042ed3e048af
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-08-20 10:46 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-20 10:43 [PATCH 0/8] opp: Unconditionally call dev_pm_opp_of_remove_table() Viresh Kumar
2020-08-20 10:43 ` [PATCH 7/8] tty: serial: qcom_geni_serial: " Viresh Kumar
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).