[RFC PATCH v10 0/7] PCI: rockchip: Move PCIe WAKE# handling into pci core

2017-10-27 Thread Jeffy Chen
eup" instead of "wake" Rebase. Changes in v3: Fix error handling. Changes in v2: Use dev_pm_set_dedicated_wake_irq. Jeffy Chen (7): dt-bindings: PCI: Add definition of PCIe WAKE# irq and PCI irq of/irq: Adjust of_pci_irq parsing for multiple interrupts mwifiex: Disable wakeup

[RFC PATCH v10 6/7] PCI / PM: Move acpi wakeup code to pci core

2017-10-27 Thread Jeffy Chen
Move acpi wakeup code to pci core as pci_set_wakeup(), so that other platforms could reuse it. Also add .setup_dev() / .setup_host_bridge() / .cleanup() platform pm ops's callbacks to setup and cleanup pci devices and host bridge for wakeup. Signed-off-by: Jeffy Chen --- Changes in v10:

[RFC PATCH v10 7/7] PCI / PM: Add support for the PCIe WAKE# signal for OF

2017-10-27 Thread Jeffy Chen
Add pci-of.c to handle the PCIe WAKE# interrupt. Also use the dedicated wakeirq infrastructure to simplify it. Signed-off-by: Jeffy Chen --- Changes in v10: Use device_set_wakeup_capable() instead of device_set_wakeup_enable(), since dedicated wakeirq will be lost in device_set_wakeup_enable

[RFC PATCH v10 5/7] PCI: Make pci_platform_pm_ops's callbacks optional

2017-10-27 Thread Jeffy Chen
Allow platforms not to provide some of the pci_platform_pm_ops's callbacks. Also change the return value from -ENOSYS to -ENODEV for: warning: drivers/pci/pci.c,594: ENOSYS means 'invalid syscall nr' and nothing else Signed-off-by: Jeffy Chen --- Changes in v10: None Chan

[RFC PATCH v10 3/7] mwifiex: Disable wakeup irq handling for pcie

2017-10-27 Thread Jeffy Chen
We are going to handle the wakeup irq in the pci core. Signed-off-by: Jeffy Chen --- Changes in v10: None Changes in v9: None Changes in v8: None Changes in v7: None Changes in v6: None Changes in v5: None Changes in v3: None Changes in v2: None drivers/net/wireless/marvell/mwifiex/main.c | 4

[RFC PATCH v10 2/7] of/irq: Adjust of_pci_irq parsing for multiple interrupts

2017-10-27 Thread Jeffy Chen
Currently we are considering the first irq as the PCI interrupt pin, but a PCI device may have multiple interrupts(e.g. PCIe WAKE# pin). Only parse the PCI interrupt pin when the irq is unnamed or named as "pci". Signed-off-by: Jeffy Chen --- Changes in v10: None Changes in v9: None

[RFC PATCH v10 4/7] arm64: dts: rockchip: Move PCIe WAKE# irq to pcie driver for Gru

2017-10-27 Thread Jeffy Chen
Currently we are handling PCIe WAKE# irq in mrvl wifi driver. Move it to rockchip pcie driver since we are going to handle it in the pci core. Also avoid this irq been considered as the PCI interrupt pin in the of_irq_parse_pci(). Signed-off-by: Jeffy Chen --- Changes in v10: None Changes in

[RFC PATCH v10 1/7] dt-bindings: PCI: Add definition of PCIe WAKE# irq and PCI irq

2017-10-27 Thread Jeffy Chen
. Signed-off-by: Jeffy Chen --- Changes in v10: None Changes in v9: Add section for PCI devices and rewrite the commit message. Changes in v8: Add optional "pci", and rewrite commit message. Changes in v7: None Changes in v6: None Changes in v5: Move to pci.txt Changes in v3: None Cha

[RFC PATCH v9 1/7] dt-bindings: PCI: Add definition of PCIe WAKE# irq and PCI irq

2017-10-27 Thread Jeffy Chen
. Signed-off-by: Jeffy Chen --- Changes in v9: Add section for PCI devices and rewrite the commit message. Changes in v8: Add optional "pci", and rewrite commit message. Changes in v7: None Changes in v6: None Changes in v5: Move to pci.txt Changes in v3: None Changes in v2: None Doc

[RFC PATCH v9 6/7] PCI / PM: Move acpi wakeup code to pci core

2017-10-27 Thread Jeffy Chen
Move acpi wakeup code to pci core as pci_set_wakeup(), so that other platforms could reuse it. Also add .setup_dev() / .setup_host_bridge() / .cleanup() platform pm ops's callbacks to setup and cleanup pci devices and host bridge for wakeup. Signed-off-by: Jeffy Chen --- Changes in v9:

[RFC PATCH v9 4/7] arm64: dts: rockchip: Move PCIe WAKE# irq to pcie driver for Gru

2017-10-27 Thread Jeffy Chen
Currently we are handling PCIe WAKE# irq in mrvl wifi driver. Move it to rockchip pcie driver since we are going to handle it in the pci core. Also avoid this irq been considered as the PCI interrupt pin in the of_irq_parse_pci(). Signed-off-by: Jeffy Chen --- Changes in v9: Rewrite the

[RFC PATCH v9 0/7] PCI: rockchip: Move PCIe WAKE# handling into pci core

2017-10-27 Thread Jeffy Chen
g into pci core. Changes in v6: Fix device_init_wake error handling, and add some comments. Changes in v5: Move to pci.txt Use "wakeup" instead of "wake" Rebase. Changes in v3: Fix error handling. Changes in v2: Use dev_pm_set_dedicated_wake_irq. Jeffy Chen (7): dt-binding

[RFC PATCH v9 7/7] PCI / PM: Add support for the PCIe WAKE# signal for OF

2017-10-27 Thread Jeffy Chen
Add pci-of.c to handle the PCIe WAKE# interrupt. Also use the dedicated wakeirq infrastructure to simplify it. Signed-off-by: Jeffy Chen --- Changes in v9: Fix check error in .cleanup(). Move dedicated wakeirq setup to setup() callback and use device_set_wakeup_enable() to enable/disable

[RFC PATCH v9 2/7] of/irq: Adjust of_pci_irq parsing for multiple interrupts

2017-10-27 Thread Jeffy Chen
Currently we are considering the first irq as the PCI interrupt pin, but a PCI device may have multiple interrupts(e.g. PCIe WAKE# pin). Only parse the PCI interrupt pin when the irq is unnamed or named as "pci". Signed-off-by: Jeffy Chen --- Changes in v9: None Changes in v8: None

[RFC PATCH v9 5/7] PCI: Make pci_platform_pm_ops's callbacks optional

2017-10-27 Thread Jeffy Chen
Allow platforms not to provide some of the pci_platform_pm_ops's callbacks. Also change the return value from -ENOSYS to -ENODEV for: warning: drivers/pci/pci.c,594: ENOSYS means 'invalid syscall nr' and nothing else Signed-off-by: Jeffy Chen --- Changes in v9: None Chan

[RFC PATCH v9 3/7] mwifiex: Disable wakeup irq handling for pcie

2017-10-27 Thread Jeffy Chen
We are going to handle the wakeup irq in the pci core. Signed-off-by: Jeffy Chen --- Changes in v9: None Changes in v8: None Changes in v7: None Changes in v6: None Changes in v5: None Changes in v3: None Changes in v2: None drivers/net/wireless/marvell/mwifiex/main.c | 4 1 file changed

[RFC PATCH v8 3/7] arm64: dts: rockchip: Handle PCIe WAKE# signal in pcie driver for Gru

2017-10-26 Thread Jeffy Chen
Currently we are handling PCIe WAKE# signal in mrvl wifi driver. Move it to rockchip pcie driver for Gru boards. Also avoid this irq been considered as the PCI interrupt pin in the of_irq_parse_pci(). Signed-off-by: Jeffy Chen --- Changes in v8: Rewrite the commit message. Changes in v7: None

[RFC PATCH v8 5/7] PCI: Make pci_platform_pm_ops's callbacks optional

2017-10-26 Thread Jeffy Chen
Allow platforms not to provide some of the pci_platform_pm_ops's callbacks. Also change the return value -ENOSYS to -ENODEV for: warning: drivers/pci/pci.c,594: ENOSYS means 'invalid syscall nr' and nothing else Signed-off-by: Jeffy Chen --- Changes in v8: None Changes in v7:

[RFC PATCH v8 6/7] PCI / PM: Move acpi wakeup code to pci core

2017-10-26 Thread Jeffy Chen
Move acpi wakeup code to pci core as pci_set_wakeup(), so that other platform could reuse it. Also add .setup_dev() / .setup_host_bridge() / .cleanup() platform pm ops's callbacks to setup and cleanup pci devices and host bridge for wakeup. Signed-off-by: Jeffy Chen --- Changes in v8:

[RFC PATCH v8 4/7] of/irq: Adjust of pci irq parsing for multiple interrupts

2017-10-26 Thread Jeffy Chen
Currently we are considering the first irq as the PCI interrupt pin, but a pci device may have multiple interrupts(e.g. PCIe WAKE# pin). Only parse the PCI interrupt pin when the irq is unnamed or named as "pci". Signed-off-by: Jeffy Chen --- Changes in v8: None Changes in v7: None

[RFC PATCH v8 7/7] PCI / PM: Add support for the PCIe WAKE# signal for OF

2017-10-26 Thread Jeffy Chen
Add pci-of.c to handle the PCIe WAKE# interrupt. Also use the dedicated wakeirq infrastructure to simplify it. Signed-off-by: Jeffy Chen --- Changes in v8: Add pci-of.c and use platform_pm_ops to handle the PCIe WAKE# signal. Changes in v7: Move PCIE_WAKE handling into pci core. Changes in

[RFC PATCH v8 0/7] PCI: rockchip: Move PCIe WAKE# handling into pci core

2017-10-26 Thread Jeffy Chen
dev_pm_set_dedicated_wake_irq. Jeffy Chen (7): dt-bindings: PCI: Add definition of PCIe WAKE# irq and PCI irq mwifiex: Disable wakeup irq handling for pcie arm64: dts: rockchip: Handle PCIe WAKE# signal in pcie driver for Gru of/irq: Adjust of pci irq parsing for multiple interrupts P

[RFC PATCH v8 2/7] mwifiex: Disable wakeup irq handling for pcie

2017-10-26 Thread Jeffy Chen
We are going to handle the wakeup irq in the pci core. Signed-off-by: Jeffy Chen --- Changes in v8: None Changes in v7: None Changes in v6: None Changes in v5: None Changes in v3: None Changes in v2: None drivers/net/wireless/marvell/mwifiex/main.c | 4 1 file changed, 4 insertions

[RFC PATCH v8 1/7] dt-bindings: PCI: Add definition of PCIe WAKE# irq and PCI irq

2017-10-26 Thread Jeffy Chen
Add optional interrupts for PCIe WAKE# pin and PCI interrupt pin. Signed-off-by: Jeffy Chen --- Changes in v8: Add optional "pci", and rewrite commit message. Changes in v7: None Changes in v6: None Changes in v5: Move to pci.txt Changes in v3: None Changes in v2: None Doc

[PATCH] scsi: .gitignore: Add scsi_devinfo_tbl.c

2017-10-25 Thread Jeffy Chen
Add generated scsi_devinfo_tbl.c into .gitignore. Signed-off-by: Jeffy Chen --- drivers/scsi/.gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/scsi/.gitignore b/drivers/scsi/.gitignore index c89ae9a04399..e2956741fbd1 100644 --- a/drivers/scsi/.gitignore +++ b/drivers/scsi

[PATCH v2] ARM: Remove .pad section when CONFIG_EFI_STUB enabled

2017-10-22 Thread Jeffy Chen
Currently we are using the .pad section to ensure the zImage file size aligned to 8 bytes. But that is not needed when CONFIG_EFI_STUB enabled, as it would followed by a 512 bytes aligned .data section. Signed-off-by: Jeffy Chen --- Changes in v2: Remove .pad section when CONFIG_EFI_STUB

[PATCH v4] driver core: Move device_links_purge() after bus_remove_device()

2017-10-20 Thread Jeffy Chen
device_links_purge() call in device_del() after the invocation of bus_remove_device() which calls device_release_driver(). Fixes: 9ed9895370ae (driver core: Functional dependencies tracking support) Signed-off-by: Jeffy Chen Reviewed-by: Rafael J. Wysocki --- Changes in v4: Add Fixes. Changes

[PATCH v3] driver core: Move device_links_purge() after bus_remove_device()

2017-10-19 Thread Jeffy Chen
device_links_purge() call in device_del() after the invocation of bus_remove_device() which calls device_release_driver(). Signed-off-by: Jeffy Chen Reviewed-by: Rafael J. Wysocki --- Changes in v3: Remove wrong signed-off-by. Changes in v2: Update commit message provided by Rafael. drivers

[PATCH v7 0/3] PCI: rockchip: Move PCIE_WAKE handling into pci core

2017-10-19 Thread Jeffy Chen
: Rebase Move to pci.txt Use "wakeup" instead of "wake" Changes in v3: Fix error handling Changes in v2: Use dev_pm_set_dedicated_wake_irq -- Suggested by Brian Norris Jeffy Chen (3): PCI: Add support for wake irq dt-bindings: PCI: Add definition of pcie wake irq

[PATCH v7 1/3] PCI: Add support for wake irq

2017-10-19 Thread Jeffy Chen
Add support for PCIE_WAKE pin. Signed-off-by: Jeffy Chen --- Changes in v7: Move PCIE_WAKE handling into pci core. Changes in v6: Fix device_init_wake error handling, and add some comments. Changes in v5: Rebase Changes in v3: Fix error handling Changes in v2: Use

[PATCH v7 3/3] arm64: dts: rockchip: Handle pcie wake in pcie driver for Gru

2017-10-19 Thread Jeffy Chen
Currently we are handling pcie wake irq in mrvl wifi driver. Move it to rockchip pcie driver for Gru boards. Signed-off-by: Jeffy Chen --- Changes in v7: None Changes in v6: None Changes in v5: Use "wakeup" instead of "wake" Changes in v3: None Changes in v2: None

[PATCH v7 2/3] dt-bindings: PCI: Add definition of pcie wake irq

2017-10-19 Thread Jeffy Chen
Add an optional interrupt for PCIE_WAKE pin. Signed-off-by: Jeffy Chen Acked-by: Rob Herring --- Changes in v7: None Changes in v6: None Changes in v5: Move to pci.txt Changes in v3: None Changes in v2: None Documentation/devicetree/bindings/pci/pci.txt | 2 ++ 1 file changed, 2 insertions

[PATCH v6 00/10] rockchip: kevin: Enable edp display

2017-10-18 Thread Jeffy Chen
hook in the error handling path like in unbind(). Update cleanup order in unbind(). Add disable to unbind(), and inline clk_prepare_enable() with bind(). Jeffy Chen (10): arm64: dts: rockchip: Enable edp disaplay on kevin drm/rockchip: analogix_dp: Remove unnecessary init code drm/bridge: ana

[PATCH v6 01/10] arm64: dts: rockchip: Enable edp disaplay on kevin

2017-10-18 Thread Jeffy Chen
Add edp panel and enable related nodes on kevin. Signed-off-by: Jeffy Chen Reviewed-by: Mark Yao --- Changes in v6: None Changes in v5: None arch/arm64/boot/dts/rockchip/rk3399-gru-kevin.dts | 29 +++ arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi | 16

[PATCH v6 04/10] drm/bridge: analogix_dp: Fix connector and encoder cleanup

2017-10-18 Thread Jeffy Chen
Since we are initing connector in the core driver and encoder in the plat driver, let's clean them up in the right places. Signed-off-by: Jeffy Chen Reviewed-by: Andrzej Hajda --- Changes in v6: Don't change order of rockchip_drm_psr_register(). Changes in v5: None drivers/gpu/

[PATCH v6 06/10] drm/rockchip: dw-mipi-dsi: Fix error handling path

2017-10-18 Thread Jeffy Chen
Add missing pm_runtime_disable() in bind()'s error handling path. Also cleanup encoder & connector in unbind(). Fixes: 80a9a059d4e4 ("drm/rockchip/dsi: add dw-mipi power domain support") Signed-off-by: Jeffy Chen --- Changes in v6: None Changes in v5: Call the destro

[PATCH v6 10/10] drm/rockchip: dw_hdmi: Fix error handling path

2017-10-18 Thread Jeffy Chen
Add missing clk_disable_unprepare() in bind()'s error handling path and unbind(). Also inline clk_prepare_enable() with bind(). Fixes: 12b9f204e804 ("drm: bridge/dw_hdmi: add rockchip rk3288 support") Signed-off-by: Jeffy Chen --- Changes in v6: None Changes in v5: Add disable t

[PATCH v6 09/10] drm/bridge/synopsys: dw-hdmi: Do not use device's drvdata

2017-10-18 Thread Jeffy Chen
Let plat drivers own the drvdata, so that they could cleanup resources in their unbind(). Signed-off-by: Jeffy Chen Reviewed-by: Neil Armstrong --- Changes in v6: None Changes in v5: None drivers/gpu/drm/bridge/synopsys/dw-hdmi.c | 43 ++--- drivers/gpu/drm/imx

[PATCH v6 08/10] drm/bridge/synopsys: dw-hdmi: Add missing bridge detach

2017-10-18 Thread Jeffy Chen
We inited connector in attach(), so need a detach() to cleanup. Also fix wrong use of dw_hdmi_remove() in bind(). Signed-off-by: Jeffy Chen --- Changes in v6: None Changes in v5: None drivers/gpu/drm/bridge/synopsys/dw-hdmi.c | 10 +- 1 file changed, 9 insertions(+), 1 deletion

[PATCH v6 07/10] drm/rockchip: inno_hdmi: Fix error handling path

2017-10-18 Thread Jeffy Chen
Add missing error handling in bind(). Fixes: 412d4ae6b7a5 ("drm/rockchip: hdmi: add Innosilicon HDMI support") Signed-off-by: Jeffy Chen --- Changes in v6: None Changes in v5: Call the destroy hook in the error handling path like in unbind(). Update cleanup order in unbind(). drive

[PATCH v6 05/10] drm/rockchip: analogix_dp: Add a sanity check for rockchip_drm_psr_register()

2017-10-18 Thread Jeffy Chen
The rockchip_drm_psr_register() can fail, so add a sanity check for that. Also reorder the calls in unbind() to match bind(). Signed-off-by: Jeffy Chen --- Changes in v6: None Changes in v5: None drivers/gpu/drm/rockchip/analogix_dp-rockchip.c | 15 +++ 1 file changed, 11

[PATCH v6 02/10] drm/rockchip: analogix_dp: Remove unnecessary init code

2017-10-18 Thread Jeffy Chen
Remove unnecessary init code, since we would do it in the power_on() callback. Also move of parse code to probe(). Fixes: 9e32e16e9e98 ("drm: rockchip: dp: add rockchip platform dp driver") Signed-off-by: Jeffy Chen --- Changes in v6: None Changes in v5: None drivers/gpu/dr

[PATCH v6 03/10] drm/bridge: analogix: Do not use device's drvdata

2017-10-18 Thread Jeffy Chen
practice and in fact has led to many bugs in this driver. Let's clean up this mess and change Analogix entry points to simply accept some opaque struct pointer, adjusting their users at the same time to avoid breaking the compilation. Signed-off-by: Tomasz Figa Signed-off-by: Jeffy Chen Review

[PATCH v2] driver core: Move device_links_purge() after bus_remove_device()

2017-10-18 Thread Jeffy Chen
device_links_purge() call in device_del() after the invocation of bus_remove_device() which calls device_release_driver(). Signed-off-by: Rafael J. Wysocki Signed-off-by: Jeffy Chen --- Changes in v2: Update commit message provided by Rafael. drivers/base/core.c | 2 +- 1 file changed, 1

[PATCH v5 1/9] arm64: dts: rockchip: Enable edp disaplay on kevin

2017-10-18 Thread Jeffy Chen
Add edp panel and enable related nodes on kevin. Signed-off-by: Jeffy Chen Reviewed-by: Mark Yao --- Changes in v5: None arch/arm64/boot/dts/rockchip/rk3399-gru-kevin.dts | 29 +++ arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi | 16 + 2 files changed, 45

[PATCH v5 5/9] drm/rockchip: dw-mipi-dsi: Fix error handling path

2017-10-18 Thread Jeffy Chen
Add missing pm_runtime_disable() in bind()'s error handling path. Also cleanup encoder & connector in unbind(). Fixes: 80a9a059d4e4 ("drm/rockchip/dsi: add dw-mipi power domain support") Signed-off-by: Jeffy Chen --- Changes in v5: Call the destroy hook in the error ha

[PATCH v5 8/9] drm/bridge/synopsys: dw-hdmi: Do not use device's drvdata

2017-10-18 Thread Jeffy Chen
Let plat drivers own the drvdata, so that they could cleanup resources in their unbind(). Signed-off-by: Jeffy Chen --- Changes in v5: None drivers/gpu/drm/bridge/synopsys/dw-hdmi.c | 43 ++--- drivers/gpu/drm/imx/dw_hdmi-imx.c | 22 +-- drivers

[PATCH v5 7/9] drm/bridge/synopsys: dw-hdmi: Add missing bridge detach

2017-10-18 Thread Jeffy Chen
We inited connector in attach(), so need a detach() to cleanup. Also fix wrong use of dw_hdmi_remove() in bind(). Signed-off-by: Jeffy Chen --- Changes in v5: None drivers/gpu/drm/bridge/synopsys/dw-hdmi.c | 10 +- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/drivers

[PATCH v5 9/9] drm/rockchip: dw_hdmi: Fix error handling path

2017-10-18 Thread Jeffy Chen
Add missing clk_disable_unprepare() in bind()'s error handling path and unbind(). Also inline clk_prepare_enable() with bind(). Fixes: 12b9f204e804 ("drm: bridge/dw_hdmi: add rockchip rk3288 support") Signed-off-by: Jeffy Chen --- Changes in v5: Add disable to unbin

[PATCH v5 2/9] drm/rockchip: analogix_dp: Remove unnecessary init code

2017-10-18 Thread Jeffy Chen
Remove unnecessary init code, since we would do it in the power_on() callback. Also move of parse code to probe(). Fixes: 9e32e16e9e98 ("drm: rockchip: dp: add rockchip platform dp driver") Signed-off-by: Jeffy Chen --- Changes in v5: None drivers/gpu/drm/rockchip/analogix_dp-rockc

[PATCH v5 6/9] drm/rockchip: inno_hdmi: Fix error handling path

2017-10-18 Thread Jeffy Chen
Add missing error handling in bind(). Fixes: 412d4ae6b7a5 ("drm/rockchip: hdmi: add Innosilicon HDMI support") Signed-off-by: Jeffy Chen --- Changes in v5: Call the destroy hook in the error handling path like in unbind(). Update cleanup order in unbind(). drivers/gpu/drm/rockchip/i

[PATCH v5 4/9] drm/bridge: analogix_dp: Fix connector & encoder cleanup

2017-10-18 Thread Jeffy Chen
Since we are initing connector in the core driver and encoder in the plat driver, let's clean them up in the right places. Signed-off-by: Jeffy Chen --- Changes in v5: None drivers/gpu/drm/bridge/analogix/analogix_dp_core.c | 2 -- drivers/gpu/drm/exynos/exynos_dp.c

[PATCH v5 3/9] drm/bridge: analogix: Do not use device's drvdata

2017-10-18 Thread Jeffy Chen
practice and in fact has led to many bugs in this driver. Let's clean up this mess and change Analogix entry points to simply accept some opaque struct pointer, adjusting their users at the same time to avoid breaking the compilation. Signed-off-by: Tomasz Figa Signed-off-by: Jeffy Chen Review

[PATCH] driver core: Move device_links_purge() after bus_remove_device()

2017-10-18 Thread Jeffy Chen
Currently we are unbinding device link consumers when detaching the supplier. So we need to make sure the detaching happens before purging the supplier's device links. Move device_links_purge() after bus_remove_device() in device_del() for that. Signed-off-by: Jeffy Chen --- drivers

[PATCH] spi: Detach spi device from driver when unregister it

2017-10-18 Thread Jeffy Chen
Make sure spi device detached before unregistering it. Signed-off-by: Jeffy Chen --- drivers/spi/spi.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/spi/spi.c b/drivers/spi/spi.c index 6e65524cbfd9..9114efb2eb8c 100644 --- a/drivers/spi/spi.c +++ b/drivers/spi/spi.c @@ -648,6

[PATCH] driver core: Make sure device detached from driver before deleting it

2017-10-17 Thread Jeffy Chen
There are cases we call device_del() without detaching it from the driver(e.g. spi core del children devices). Signed-off-by: Jeffy Chen --- drivers/base/core.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/base/core.c b/drivers/base/core.c index 12ebd055724c..717efc3020af

[PATCH] ARM: Fix zImage file size not aligned with CONFIG_EFI_STUB enabled

2017-10-17 Thread Jeffy Chen
The zImage file size should be aligned. Fixes: e4bae4d0b5f3 ("arm/efi: Split zImage code and data into separate PE/COFF sections") Signed-off-by: Jeffy Chen --- arch/arm/boot/compressed/vmlinux.lds.S | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/arc

[RFC PATCH v4 1/8] arm64: dts: rockchip: Enable edp disaplay on kevin

2017-10-17 Thread Jeffy Chen
Add edp panel and enable related nodes on kevin. Signed-off-by: Jeffy Chen Reviewed-by: Mark Yao --- Changes in v4: None Changes in v3: None Changes in v2: None arch/arm64/boot/dts/rockchip/rk3399-gru-kevin.dts | 29 +++ arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi

[RFC PATCH v4 4/8] drm/rockchip: dw_hdmi: Fix error handling path

2017-10-17 Thread Jeffy Chen
Add missing clk_disable_unprepare() in bind()'s error handling path. Fixes: 12b9f204e804 ("drm: bridge/dw_hdmi: add rockchip rk3288 support") Signed-off-by: Jeffy Chen --- Changes in v4: None Changes in v3: None Changes in v2: None drivers/gpu/drm/rockchip/dw_hdmi-rockchip.c |

[RFC PATCH v4 6/8] drm/bridge/analogix: Do not use device's drvdata

2017-10-17 Thread Jeffy Chen
barely a good practice and in fact has led to many bugs in this driver. Let's clean up this mess and change Analogix entry points to simply accept some opaque struct pointer, adjusting their users at the same time to avoid breaking the compilation. Signed-off-by: Tomasz Figa Signed-off-by:

[RFC PATCH v4 7/8] pwm: Add dummy pwmchip for orphan pwms

2017-10-17 Thread Jeffy Chen
crash the kernel when trying to access them later. Add a dummy pwmchip, and assign orphan pwms to it to avoid that. Signed-off-by: Jeffy Chen --- Changes in v4: Fix compile warning. Changes in v3: Assign orphan pwms to dummy pwmchip instead of adding device link in the customer driver. Changes in

[RFC PATCH v4 8/8] drm/rockchip: Add device links for master and components

2017-10-17 Thread Jeffy Chen
Since we are trying to access components' resources in the master's suspend/resume PM callbacks(e.g. panel), add device links to correct the suspend/resume and shutdown ordering. Signed-off-by: Jeffy Chen --- Changes in v4: None Changes in v3: None Changes in v2: Use device link to c

[RFC PATCH v4 2/8] drm/rockchip: analogix_dp: Fix error handling path

2017-10-17 Thread Jeffy Chen
Add missing error handling in rockchip_dp_bind(). Fixes: 9e32e16e9e98 ("drm: rockchip: dp: add rockchip platform dp driver") Signed-off-by: Jeffy Chen --- Changes in v4: None Changes in v3: None Changes in v2: None drivers/gpu/drm/rockchip/analogix_dp-rockchip.c | 14

[RFC PATCH v4 0/8] rockchip: kevin: Enable edp display

2017-10-17 Thread Jeffy Chen
link to correct the suspend/resume and shutdown ordering, instead of converting rockchip spi's suspend/resume PM callbacks to late suspend/resume PM callbacks. Jeffy Chen (7): arm64: dts: rockchip: Enable edp disaplay on kevin drm/rockchip: analogix_dp: Fix error handling path drm/rockchi

[RFC PATCH v4 3/8] drm/rockchip: dw-mipi-dsi: Fix error handling path

2017-10-17 Thread Jeffy Chen
Add missing pm_runtime_disable() in bind()'s error handling path. Also cleanup encoder & connector in unbind(). Fixes: 80a9a059d4e4 ("drm/rockchip/dsi: add dw-mipi power domain support") Signed-off-by: Jeffy Chen --- Changes in v4: None Changes in v3: None Changes in v2: Non

[RFC PATCH v4 5/8] drm/rockchip: inno_hdmi: Fix error handling path

2017-10-17 Thread Jeffy Chen
Add missing error handling in bind(). Fixes: 412d4ae6b7a5 ("drm/rockchip: hdmi: add Innosilicon HDMI support") Signed-off-by: Jeffy Chen --- Changes in v4: None Changes in v3: None Changes in v2: None drivers/gpu/drm/rockchip/inno_hdmi.c | 20 1 file c

[RFC PATCH v3 0/5] rockchip: kevin: Enable edp display

2017-10-17 Thread Jeffy Chen
shutdown ordering, instead of converting rockchip spi's suspend/resume PM callbacks to late suspend/resume PM callbacks. Jeffy Chen (4): arm64: dts: rockchip: Enable edp disaplay on kevin drm/rockchip: Fix error handling path in rockchip_dp_bind() pwm: Add dummy pwmchip for orphan pwms

[RFC PATCH v3 2/5] drm/rockchip: Fix error handling path in rockchip_dp_bind()

2017-10-17 Thread Jeffy Chen
Add missing error handling in rockchip_dp_bind(). Fixes: 9e32e16e9e98 ("drm: rockchip: dp: add rockchip platform dp driver") Signed-off-by: Jeffy Chen --- Changes in v3: None Changes in v2: None drivers/gpu/drm/rockchip/analogix_dp-rockchip.c | 14 -- 1 file changed, 12

[RFC PATCH v3 4/5] pwm: Add dummy pwmchip for orphan pwms

2017-10-17 Thread Jeffy Chen
crash the kernel when trying to access them later. Add a dummy pwmchip, and assign orphan pwms to it to avoid that. Signed-off-by: Jeffy Chen --- Changes in v3: Assign orphan pwms to dummy pwmchip instead of adding device link in the customer driver. Changes in v2: None drivers/pwm/core.c | 84

[RFC PATCH v3 5/5] drm/rockchip: Add device links for master and components

2017-10-17 Thread Jeffy Chen
Since we are trying to access components' resources in the master's suspend/resume PM callbacks(e.g. panel), add device links to correct the suspend/resume and shutdown ordering. Signed-off-by: Jeffy Chen --- Changes in v3: None Changes in v2: Use device link to correct the suspend/

[RFC PATCH v3 3/5] drm/bridge/analogix: Do not use device's drvdata

2017-10-17 Thread Jeffy Chen
barely a good practice and in fact has led to many bugs in this driver. Let's clean up this mess and change Analogix entry points to simply accept some opaque struct pointer, adjusting their users at the same time to avoid breaking the compilation. Signed-off-by: Tomasz Figa Signed-off-by:

[RFC PATCH v3 1/5] arm64: dts: rockchip: Enable edp disaplay on kevin

2017-10-17 Thread Jeffy Chen
Add edp panel and enable related nodes on kevin. Signed-off-by: Jeffy Chen Reviewed-by: Mark Yao --- Changes in v3: None Changes in v2: None arch/arm64/boot/dts/rockchip/rk3399-gru-kevin.dts | 29 +++ arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi | 16

[RESEND PATCH v2 5/5] drm/rockchip: Add device links for master and components

2017-10-16 Thread Jeffy Chen
Since we are trying to access components' resources in the master's suspend/resume PM callbacks(e.g. panel), add device links to correct the suspend/resume and shutdown ordering. Signed-off-by: Jeffy Chen --- Changes in v2: Use device link to correct the suspend/resume and shutdow

[RESEND PATCH v2 4/5] drm/bridge/analogix: Do not use device's drvdata

2017-10-16 Thread Jeffy Chen
barely a good practice and in fact has led to many bugs in this driver. Let's clean up this mess and change Analogix entry points to simply accept some opaque struct pointer, adjusting their users at the same time to avoid breaking the compilation. Signed-off-by: Tomasz Figa Signed-off-by:

[RESEND PATCH v2 2/5] backlight: pwm_bl: Add device link for pwm_bl and pwm

2017-10-16 Thread Jeffy Chen
When the pwm driver is unbound, the pwm_bl driver would still hold a reference to that pwm, and crash the kernel later(if someone trying to access that invalid pwm). Add a device link to avoid this. Signed-off-by: Jeffy Chen --- Changes in v2: None drivers/video/backlight/pwm_bl.c | 2 ++ 1

[RESEND PATCH v2 3/5] drm/rockchip: Fix error handling path in rockchip_dp_bind()

2017-10-16 Thread Jeffy Chen
Add missing error handling in rockchip_dp_bind(). Fixes: 9e32e16e9e98 ("drm: rockchip: dp: add rockchip platform dp driver") Signed-off-by: Jeffy Chen --- Changes in v2: None drivers/gpu/drm/rockchip/analogix_dp-rockchip.c | 14 -- 1 file changed, 12 insertions(+), 2

[RESEND PATCH v2 1/5] arm64: dts: rockchip: Enable edp disaplay on kevin

2017-10-16 Thread Jeffy Chen
Add edp panel and enable related nodes on kevin. Signed-off-by: Jeffy Chen --- Changes in v2: None arch/arm64/boot/dts/rockchip/rk3399-gru-kevin.dts | 29 +++ arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi | 16 + 2 files changed, 45 insertions(+) diff

[RESEND PATCH v2 0/5] rockchip: kevin: Enable edp display

2017-10-16 Thread Jeffy Chen
esume PM callbacks. Jeffy Chen (4): arm64: dts: rockchip: Enable edp disaplay on kevin backlight: pwm_bl: Add device link for pwm_bl and pwm drm/rockchip: Fix error handling path in rockchip_dp_bind() drm/rockchip: Add device links for master and components Tomasz Figa (1): drm/bridge/ana

[PATCH 0/5] rockchip: kevin: Enable edp display

2017-10-16 Thread Jeffy Chen
Make edp display works on chromebook kevin(at least for boot animation). Also solve some issues i meet during the bringup. Jeffy Chen (4): arm64: dts: rockchip: Enable edp disaplay on kevin backlight: pwm_bl: Add device link for pwm_bl and pwm drm/rockchip: Fix error handling path in

[PATCH 1/5] arm64: dts: rockchip: Enable edp disaplay on kevin

2017-10-16 Thread Jeffy Chen
Add edp panel and enable related nodes on kevin. Signed-off-by: Jeffy Chen --- arch/arm64/boot/dts/rockchip/rk3399-gru-kevin.dts | 29 +++ arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi | 16 + 2 files changed, 45 insertions(+) diff --git a/arch/arm64/boot

[PATCH v6 2/3] dt-bindings: PCI: Add definition of pcie wake irq

2017-10-13 Thread Jeffy Chen
Add an optional interrupt for PCIE_WAKE pin. Signed-off-by: Jeffy Chen --- Changes in v6: None Changes in v5: Move to pci.txt Changes in v3: None Changes in v2: None Documentation/devicetree/bindings/pci/pci.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Documentation/devicetree

[PATCH v6 3/3] arm64: dts: rockchip: Handle pcie wake in pcie driver for Gru

2017-10-13 Thread Jeffy Chen
Currently we are handling pcie wake irq in mrvl wifi driver. Move it to rockchip pcie driver for Gru boards. Signed-off-by: Jeffy Chen --- Changes in v6: None Changes in v5: Use "wakeup" instead of "wake" Changes in v3: None Changes in v2: None arch/arm64/boot/dts/rock

[PATCH v6 0/3] PCI: rockchip: Move PCIE_WAKE handling into rockchip pcie driver

2017-10-13 Thread Jeffy Chen
Use "wakeup" instead of "wake" Changes in v3: Fix error handling Changes in v2: Use dev_pm_set_dedicated_wake_irq -- Suggested by Brian Norris Jeffy Chen (3): PCI: rockchip: Add support for pcie wake irq dt-bindings: PCI: Add definition of pcie wake irq arm64: d

[PATCH v6 1/3] PCI: rockchip: Add support for pcie wake irq

2017-10-13 Thread Jeffy Chen
Add support for PCIE_WAKE pin in rockchip pcie driver. Signed-off-by: Jeffy Chen --- Changes in v6: Fix device_init_wake error handling, and add some comments. Changes in v5: Rebase Changes in v3: Fix error handling Changes in v2: Use dev_pm_set_dedicated_wake_irq -- Suggested by

[RESEND PATCH 2/2] arm64: dts: rockchip: Enable edp disaplay on kevin

2017-10-13 Thread Jeffy Chen
Add edp panel and enable related nodes on kevin. Signed-off-by: Jeffy Chen --- arch/arm64/boot/dts/rockchip/rk3399-gru-kevin.dts | 29 +++ arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi | 16 + 2 files changed, 45 insertions(+) diff --git a/arch/arm64/boot

[RESEND PATCH 0/2] rockchip: kevin: Enable edp display

2017-10-13 Thread Jeffy Chen
Make edp display works on chromebook kevin. Jeffy Chen (2): spi: rockchip: Convert to late and early system PM callbacks arm64: dts: rockchip: Enable edp disaplay on kevin arch/arm64/boot/dts/rockchip/rk3399-gru-kevin.dts | 29 +++ arch/arm64/boot/dts/rockchip/rk3399

[RESEND PATCH 1/2] spi: rockchip: Convert to late and early system PM callbacks

2017-10-13 Thread Jeffy Chen
Currently we are suspending the spi master in it's ->suspend callback, which is racy as some other drivers may still want to transmit messages on the bus(e.g. spi based pwm backlight). Convert to late and early system PM callbacks to avoid the race. Signed-off-by: Jeffy Chen --- dri

[PATCH 1/2] spi: rockchip: Convert to late and early system PM callbacks

2017-10-13 Thread Jeffy Chen
Currently we are suspending the spi master in it's ->suspend callback, which is racy as some other drivers may still want to transmit messages on the bus(e.g. spi based pwm backlight). Convert to late and early system PM callbacks to avoid the race. Signed-off-by: Jeffy Chen --- dri

[PATCH 2/2] arm64: dts: rockchip: Enable edp disaplay on kevin

2017-10-13 Thread Jeffy Chen
Add edp panel and enable related nodes on kevin. Signed-off-by: Jeffy Chen --- arch/arm64/boot/dts/rockchip/rk3399-gru-kevin.dts | 29 +++ arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi | 16 + 2 files changed, 45 insertions(+) diff --git a/arch/arm64/boot

[PATCH v2 1/2] block: Treat all read ops as synchronous

2017-10-12 Thread Jeffy Chen
The comment for op_is_sync() says "Reads are always treated as synchronous", but it only checks for REQ_OP_READ. Use op_is_write() to detect read ops and treat them as synchronous. Fixes: aebf526b53ae ("block: fold cmd_type into the REQ_OP_ space") Signed-off-by: Jeffy Chen

[PATCH v2 2/2] block/cfq: Fix memory leak without CFQ_GROUP_IOSCHED

2017-10-12 Thread Jeffy Chen
x1bc/0x444 [] elv_set_request+0x88/0x9c [] get_request+0x494/0x914 [] blk_get_request+0xdc/0x160 [] scsi_execute+0x70/0x23c [] scsi_test_unit_ready+0xf4/0x1ec Fixes: 60a837077e2b ("cfq-iosched: charge async IOs to the appropriate blkcg's instead of the root")

[PATCH v2] media: uvcvideo: Fix uvc dev reference management

2017-10-12 Thread Jeffy Chen
Remove the kref_get() in uvc_register_video(), which is not needed as the kref_init() already initializes refcount to 1 for us. Fixes: 9d15cd958c17 ("media: uvcvideo: Convert from using an atomic variable to a reference count") Signed-off-by: Jeffy Chen --- Changes in v2: Rewr

[PATCH v2] drm/atomic: Unref duplicated drm_atomic_state in drm_atomic_helper_resume()

2017-10-08 Thread Jeffy Chen
0x28/0x158 [] drm_atomic_helper_suspend+0x5c/0xf0 Problem here is that we are duplicating the drm_atomic_state in drm_atomic_helper_suspend(), but not unreference it in the resume path. Fixes: 1494276000db ("drm/atomic-helper: Implement subsystem-level suspend/resume") Signed-off-by: Jeffy Chen

[RESEND PATCH] media: uvcvideo: Fix memory leak of uvc resources

2017-10-08 Thread Jeffy Chen
The refcount would be inited to 1 in kref_init(), so we don't need to increase it at the end of uvc_register_video(). Fixes: 9d15cd958c17 ("media: uvcvideo: Convert from using an atomic variable to a reference count") Signed-off-by: Jeffy Chen --- drivers/media/usb/uvc/uvc_dr

[PATCH] media: uvcvideo: Fix memory leak of uvc resources

2017-10-08 Thread Jeffy Chen
The refcount would be inited to 1 in kref_init(), so we don't need to increase it at the end of uvc_probe(). Fixes: 9d15cd958c17 ("media: uvcvideo: Convert from using an atomic variable to a reference count") Signed-off-by: Jeffy Chen --- drivers/media/usb/uvc/uvc_driver.

[RFC PATCH 2/2] block/cfq: Fix memory leak of async cfqq

2017-09-30 Thread Jeffy Chen
x1bc/0x444 [] elv_set_request+0x88/0x9c [] get_request+0x494/0x914 [] blk_get_request+0xdc/0x160 [] scsi_execute+0x70/0x23c [] scsi_test_unit_ready+0xf4/0x1ec Signed-off-by: Jeffy Chen --- block/cfq-iosched.c | 28 ++-- 1 file changed, 18 insertions(+), 10

[RFC PATCH 1/2] block: Treat all read ops as synchronous

2017-09-30 Thread Jeffy Chen
We added some in/out ops(eg. REQ_OP_SCSI_IN/OUT), but currently the op_is_sync() is only checking REQ_OP_READ. So treat all read ops as synchronous. Fixes: aebf526b53ae ("block: fold cmd_type into the REQ_OP_ space") Signed-off-by: Jeffy Chen --- include/linux/blk_types.h | 3 +

[PATCH v2] xhci: Cleanup current_cmd in xhci_cleanup_command_queue()

2017-09-29 Thread Jeffy Chen
current_cmd in xhci_cleanup_command_queue() to avoid that. Fixes: d9f11ba9f107 ("xhci: Rework how we handle unresponsive or hoptlug removed hosts") Signed-off-by: Jeffy Chen --- Changes in v2: We cannot cancel cmd_timer in xhci_hc_died(), which would cause might_sleep warning. drivers/usb

[PATCH] cros_ec: sysfs: Fix memory leak in show/store_kb_wake_angle()

2017-09-29 Thread Jeffy Chen
Add missing kfree of allocated cros_ec_command. Fixes: ff00af859354 ("platform/chrome: cros_ec: Add sysfs entry to set keyboard wake lid angle") Signed-off-by: Jeffy Chen --- drivers/platform/chrome/cros_ec_sysfs.c | 15 ++- 1 file changed, 10 insertions(+), 5 deletion

[PATCH] xhci: Cancel cmd_timer before cleanup the command queue in xhci_hc_died()

2017-09-29 Thread Jeffy Chen
andle unresponsive or hoptlug removed hosts") Signed-off-by: Jeffy Chen --- drivers/usb/host/xhci-ring.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c index a9443651ce0f..69ac3deffb7b 100644 --- a/drivers/usb/host/xhci-ri

<    1   2   3   4   5   6   7   >