t of_usb_update_otg_caps(struct
> device_node *np,
> {
> return NULL;
> }
> +static inline struct device *usb_of_get_companion_dev(struct device *dev)
> +{
> + return NULL;
> +}
> #endif
>
> #if IS_ENABLED(CONFIG_OF) && IS_ENABLED(CONFIG_USB_SUPPORT)
Acked-by: Peter Chen <peter.c...@nxp.com>
--
Best Regards,
Peter Chen
device *dev)
> return err;
> }
>
> + companion_dev = usb_of_get_companion_dev(hcd->self.controller);
> + if (companion_dev)
> + device_pm_wait_for_dev(hcd->self.controller, companion_dev);
> +
> ehci_resume(hcd, priv->reset_on_resume);
> return 0;
Reviewed-by: Peter Chen <peter.c...@nxp.com>
--
Best Regards,
Peter Chen
b_of_get_companion_dev(hcd->self.controller);
Maybe other EHCI controller has companion controller too, so it is ok
for you to let it as a common API.
> + if (companion_dev)
> + device_pm_wait_for_dev(hcd->self.controller, companion_dev);
> +
> ehci_resume(hcd, priv->reset_on_resume);
> return 0;
> }
You can send formal patch next time.
--
Best Regards,
Peter Chen
FINE_IDA(ci_ida);
>
> struct platform_device *ci_hdrc_add_device(struct device *dev,
> @@ -1053,7 +1037,6 @@ static int ci_hdrc_probe(struct platform_device *pdev)
> if (!ret)
> return 0;
>
> - ci_extcon_unregister(ci);
> stop:
> ci_role_destroy(ci);
> deinit_phy:
> @@ -1073,7 +1056,6 @@ static int ci_hdrc_remove(struct platform_device *pdev)
> }
>
> dbg_remove_files(ci);
> - ci_extcon_unregister(ci);
> ci_role_destroy(ci);
> ci_hdrc_enter_lpm(ci, true);
> ci_usb_phy_exit(ci);
> --
Acked-by: Peter Chen <peter.c...@nxp.com>
--
Best Regards,
Peter Chen
eck_id(ch);
> + is_host = rcar_gen3_is_host(ch);
> + if (!strncmp(buf, "host", strlen("host")))
> + new_mode_is_host = true;
> + else if (!strncmp(buf, "peripheral", strlen("peripheral")))
> + new_mode_is_host = false;
> + else
rent and new mode is the same, this returns the error */
> + if (is_host == new_mode_is_host)
> + return -EINVAL;
> +
> + if (new_mode_is_host) {
> + if (!is_b_device && !is_host) /* A-Peripheral */
> + rcar_gen3_init_from_a_peri_to_a_host(ch);
> + if (is_b_device && !is_host)/* B-Peripheral */
> + rcar_gen3_init_for_b_host(ch);
is_host must be false here
> + } else {
> + if (!is_b_device && is_host)/* A-Host */
> + rcar_gen3_init_for_a_peri(ch);
> + if (is_b_device && is_host) /* B-Host */
> + rcar_gen3_init_for_peri(ch);
is_host must be true here
> + }
> +
> + return count;
> +}
> +
How can you handle the case which ID pin is incorrect, eg, ID is 0, but
it is peripheral mode at the initialization?
--
Best Regards,
Peter Chen
ice_create_file(dev, _attr_otg_inputs);
> + if (ret < 0)
> + return ret;
> + }
>
> return PTR_ERR_OR_ZERO(provider);
> }
>
> +static int rcar_gen3_phy_usb2_remove(struct platform_device *pdev)
> +{
> + struct rcar_gen3_chan *channel = platform_get_drvdata(pdev);
> +
> + if (channel->has_otg)
> + device_remove_file(>dev, _attr_otg_inputs);
> +
> + return 0;
> +};
> +
> static struct platform_driver rcar_gen3_phy_usb2_driver = {
> .driver = {
> .name = "phy_rcar_gen3_usb2",
> .of_match_table = rcar_gen3_phy_usb2_match_table,
> },
> .probe = rcar_gen3_phy_usb2_probe,
> + .remove = rcar_gen3_phy_usb2_remove,
> };
> module_platform_driver(rcar_gen3_phy_usb2_driver);
>
> --
> 1.9.1
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-usb" in
> the body of a message to majord...@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
--
Best Regards,
Peter Chen
>
>On Fri, Jul 01, 2016 at 11:29:58AM +0100, Suzuki K Poulose wrote:
>> On 01/07/16 10:41, Peter Chen wrote:
>> >of_node_put needs to be called when the device node which is got from
>> >of_parse_phandle has finished using.
>> >
>> >Cc: Will Deaco
>On Fri, Jul 1, 2016 at 11:41 AM, Peter Chen <peter.c...@nxp.com> wrote:
>> of_node_put needs to be called when the device node which is got from
>> of_parse_phandle has finished using.
>>
>> Cc: Simon Horman <ho...@verge.net.au>
>> Cc: Magnus Damm &l
Hi all,
of_node_put needs to be called when the device node which is got
from of_parse_phandle has finished using, but there are many codes
do not follow that, this patch set fixes some of them.
Peter Chen (7):
extcon: add missing of_node_put after calling of_parse_phandle
arm: mach-shmobile
of_node_put needs to be called when the device node which is got
from of_parse_phandle has finished using.
Cc: Liviu Dudau <liviu.du...@arm.com>
Cc: Sudeep Holla <sudeep.ho...@arm.com>
Cc: Lorenzo Pieralisi <lorenzo.pieral...@arm.com>
Signed-off-by: Peter Chen <peter.c...@
of_node_put needs to be called when the device node which is got
from of_parse_phandle has finished using.
Cc: Will Deacon <will.dea...@arm.com>
Cc: Suzuki K Poulose <suzuki.poul...@arm.com>
Signed-off-by: Peter Chen <peter.c...@nxp.com>
---
drivers/bus/arm-cci.c | 5 -
of_node_put needs to be called when the device node which is got
from of_parse_phandle has finished using.
Cc: Simon Horman <ho...@verge.net.au>
Cc: Magnus Damm <magnus.d...@gmail.com>
Signed-off-by: Peter Chen <peter.c...@nxp.com>
---
arch/arm/mach-shmobile/pm-rmobile.c | 1 +
of_node_put needs to be called when the device node which is got
from of_parse_phandle has finished using.
Cc: MyungJoo Ham <myungjoo@samsung.com>
Cc: Chanwoo Choi <cw00.c...@samsung.com>
Signed-off-by: Peter Chen <peter.c...@nxp.com>
---
drivers/extcon/extcon.c | 2 ++
of_node_put needs to be called when the device node which is got
from of_parse_phandle has finished using.
Cc: MyungJoo Ham <myungjoo@samsung.com>
Cc: Kyungmin Park <kyungmin.p...@samsung.com>
Signed-off-by: Peter Chen <peter.c...@nxp.com>
---
drivers/devfreq/devfreq.c | 2
of_node_put needs to be called when the device node which is got
from of_parse_phandle has finished using.
Cc: Linus Walleij <linus.wall...@linaro.org>
Signed-off-by: Peter Chen <peter.c...@nxp.com>
---
arch/arm/mach-u300/regulator.c | 12 +---
1 file changed, 9 inse
Cc: Krzysztof Kozlowski <k.kozlow...@samsung.com>
Signed-off-by: Peter Chen <peter.c...@nxp.com>
---
drivers/devfreq/exynos-bus.c | 9 ++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/drivers/devfreq/exynos-bus.c b/drivers/devfreq/exynos-bus.c
index 2363d0a..
17 matches
Mail list logo