From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id D94EDC3DA7C for ; Mon, 2 Jan 2023 08:30:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231795AbjABIat (ORCPT ); Mon, 2 Jan 2023 03:30:49 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49704 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232007AbjABIap (ORCPT ); Mon, 2 Jan 2023 03:30:45 -0500 Received: from mail-lf1-x12d.google.com (mail-lf1-x12d.google.com [IPv6:2a00:1450:4864:20::12d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 06C69E6F for ; Mon, 2 Jan 2023 00:30:44 -0800 (PST) Received: by mail-lf1-x12d.google.com with SMTP id z26so40714452lfu.8 for ; Mon, 02 Jan 2023 00:30:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=rtiFQpyWhpU5ex37LxYmByZTtx64yGOprdYoXMKibYc=; b=n1TVVWwSUQdO4/Y6dHg574l1nbWHzqX5oWXwr1OUGxHMY+d7mxwhRUC8cPImKYCT/y 8xanzMicEq/864fBVGMZUtX26ZhqVicRuWkuzOsG4vNA0u1E2kOKrv9CYewbdsihSO9L DoqJA1EteBJzlyeZHC6PtaiwhNAy35R5D3QZby4GchWZi7HLxJJN/DgMoViPZyrjBR8y H6fyq8TnY9FVz+F4EysOmrGkzAp9oyeaOr4+dj0aYBl1RhNUUx/aJwsVRMxBJtCszwk3 FaiLgEXTLpoww25G0rdycB2Gfg2AgqH+gS7XNDxZoRbyjAv/ngBuXwDuJ80dJNA8290L 2zDw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=rtiFQpyWhpU5ex37LxYmByZTtx64yGOprdYoXMKibYc=; b=4I8yxJiUMNNjj80GBnyo1QWL3sdZpHWL0KO3ZbybWJidXlEO36mxjP1TV7OXhJFqAa a8qfx6X969R7py6Sd+YfQ+KXBDAkRZZvU6e6xoMfp7uDXM4QlyIkXFLaOEmSbkhSct8I te2Yu/lue0txCgtYd9M5HGao9cjn9veQXpVTKHvV1yI1jU3HJkn/XjMffwDyLmny1Cgk 84dJmCMVsHvVwjfw6w6R+s2T5xR2u2nBleFNIInv4baRgVA/Zz1pyrxl+g18S62+HM4t 9IKDxl5GjASNSjvKKVhcMGzJT2PemW7uVF89OXyYjf8t6HdlFCN8fiFIbmPTKw++ugRM 5Ozg== X-Gm-Message-State: AFqh2kr1rpz8TkUFX37nimyTiFq+u2m88uP9riftWAk5RCzMi8cbQ2gz 6zrgSvL4snWPXRGaGOUoOmXx4Q== X-Google-Smtp-Source: AMrXdXtHLYARNcvpffbs1r2sdcc97L2+H9iPXEjItpIwDj3p2J/1deLZLgAoR0gW2EMmnQmQT6waOQ== X-Received: by 2002:a05:6512:2316:b0:4b0:6023:6f6f with SMTP id o22-20020a056512231600b004b060236f6fmr13521416lfu.57.1672648242380; Mon, 02 Jan 2023 00:30:42 -0800 (PST) Received: from [192.168.0.20] (088156142067.dynamic-2-waw-k-3-2-0.vectranet.pl. [88.156.142.67]) by smtp.gmail.com with ESMTPSA id d13-20020a056512368d00b0049478cc4eb9sm4363058lfs.230.2023.01.02.00.30.41 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 02 Jan 2023 00:30:41 -0800 (PST) Message-ID: <6451aafa-7021-0769-d408-9dba40d58668@linaro.org> Date: Mon, 2 Jan 2023 09:30:40 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.6.1 Subject: Re: [RFC PATCH v2 1/3] usb: support Samsung Exynos xHCI Controller Content-Language: en-US To: Jung Daehwan Cc: Greg Kroah-Hartman , Rob Herring , Krzysztof Kozlowski , Thinh Nguyen , Mathias Nyman , Felipe Balbi , "open list:USB SUBSYSTEM" , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , open list , sc.suh@samsung.com, taehyun.cho@samsung.com, jh0801.jung@samsung.com, eomji.oh@samsung.com References: <1672307866-25839-1-git-send-email-dh10.jung@samsung.com> <1672307866-25839-2-git-send-email-dh10.jung@samsung.com> <20230102062448.GC74470@ubuntu> From: Krzysztof Kozlowski In-Reply-To: <20230102062448.GC74470@ubuntu> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-usb@vger.kernel.org On 02/01/2023 07:24, Jung Daehwan wrote: > On Thu, Dec 29, 2022 at 11:25:58AM +0100, Krzysztof Kozlowski wrote: >> On 29/12/2022 10:57, Daehwan Jung wrote: >>> Currently, dwc3 invokes just xhci platform driver without any data. >>> We add xhci node as child of dwc3 node in order to get data from >>> device tree. It populates "xhci" child by name during initialization >>> of host. This patch only effects if dwc3 node has a child named "xhci" >>> not to disturb original path. >>> >>> We add "samsung,exynos-xhci" compatible in xhci platform driver >> >> Where? It is not documented. > > I submitted the patch of dt bindings on same patchset. > Is there any missing documentation? This is your first patch in the series and in this patch there is no such bindings. Re-order the patches to have proper order. > >> >>> to support Exynos SOCs. >> >> That's so not true. You do nothing to support Exynos SoC here. Please >> stop pasting incorrect and misleading commit msgs. > > I agree misleading commit msgs. I will modify it. > >> >>> We introduce roothub wakeup, which uses roothub >>> as system wakeup source. It needs xhci platform driver to override >>> roothub ops. >> >> You did not explain why you introduced wakelocks... >> > > I'm sorry I didn't write description enough. > I add it below. > >> >> (...) >> >>> if (shared_hcd) { >>> usb_remove_hcd(shared_hcd); >>> xhci->shared_hcd = NULL; >>> diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c >>> index 79d7931c048a..693495054001 100644 >>> --- a/drivers/usb/host/xhci.c >>> +++ b/drivers/usb/host/xhci.c >>> @@ -5502,6 +5502,10 @@ void xhci_init_driver(struct hc_driver *drv, >>> drv->check_bandwidth = over->check_bandwidth; >>> if (over->reset_bandwidth) >>> drv->reset_bandwidth = over->reset_bandwidth; >>> + if (over->bus_suspend) >>> + drv->bus_suspend = over->bus_suspend; >>> + if (over->bus_resume) >>> + drv->bus_resume = over->bus_resume; >>> } >>> } >>> EXPORT_SYMBOL_GPL(xhci_init_driver); >>> diff --git a/drivers/usb/host/xhci.h b/drivers/usb/host/xhci.h >>> index c9f06c5e4e9d..cb9c54a6a22c 100644 >>> --- a/drivers/usb/host/xhci.h >>> +++ b/drivers/usb/host/xhci.h >>> @@ -1752,6 +1752,8 @@ struct xhci_hub { >>> struct xhci_hcd { >>> struct usb_hcd *main_hcd; >>> struct usb_hcd *shared_hcd; >>> + struct wakeup_source *main_wakelock; >>> + struct wakeup_source *shared_wakelock; >> >> Drop wakelocks. This is not related to USB and not needed here. Do you >> see anywhere else in core kernel code usage of the wakelocks? >> >> You got this comment already, didn't you? So why you do not address it? >> > > I want to add a new feature in xhci platform driver. I want to make it > possible to enter system sleep while usb host connected like USB Mouse. > It gets system enter sleep only if there's no usb transaction at all. > Deciding if there's tranaction or not is in root hub because it's parent > of all child usb devices. I have USB mouse connected to my system and the system enters suspend, thus I don't think this patch solves this particular issue. Best regards, Krzysztof