- 14 4月, 2021 4 次提交
-
-
由 Sandeep Maheswaram 提交于
This patch adds a shutdown callback to USB DWC core driver to ensure that it is properly shutdown in reboot/shutdown path. This is required where SMMU address translation is enabled like on SC7180 SoC and few others. If the hardware is still accessing memory after SMMU translation is disabled as part of SMMU shutdown callback in system reboot or shutdown path, then IOVAs(I/O virtual address) which it was using will go on the bus as the physical addresses which might result in unknown crashes (NoC/interconnect errors). Acked-by: NFelipe Balbi <balbi@kernel.org> Signed-off-by: NSandeep Maheswaram <sanm@codeaurora.org> Link: https://lore.kernel.org/r/1618380209-20114-1-git-send-email-sanm@codeaurora.orgSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Thinh Nguyen 提交于
Currently the controller handles single stream only. So, Ignore Packet Pending bit for stream selection and don't search for another stream if the host sends Data Packet with PP=0 (for OUT direction) or ACK with NumP=0 and PP=0 (for IN direction). This slightly improves the stream performance. Acked-by: NFelipe Balbi <balbi@kernel.org> Signed-off-by: NThinh Nguyen <Thinh.Nguyen@synopsys.com> Link: https://lore.kernel.org/r/097ba9e104c143f7ba0195ebff29390ec3043692.1618282705.git.Thinh.Nguyen@synopsys.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Kai-Heng Feng 提交于
This is another branded 8153 device that doesn't work well with LPM enabled: [ 400.597506] r8152 5-1.1:1.0 enx482ae3a2a6f0: Tx status -71 So disable LPM to resolve the issue. Signed-off-by: NKai-Heng Feng <kai.heng.feng@canonical.com> BugLink: https://bugs.launchpad.net/bugs/1922651 Link: https://lore.kernel.org/r/20210412135455.791971-1-kai.heng.feng@canonical.com Cc: stable <stable@vger.kernel.org> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Dan Carpenter 提交于
Smatch complains about a potential missing error code: drivers/usb/typec/port-mapper.c:168 typec_link_port() warn: missing error code 'ret' This is a false positive and returning zero is intentional. Let's re-arrange the code to silence the warning and make the intent more clear. Reviewed-by: NHeikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: NDan Carpenter <dan.carpenter@oracle.com> Link: https://lore.kernel.org/r/YHadaACH8Mq/10F7@mwandaSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
- 13 4月, 2021 12 次提交
-
-
由 Artur Petrosyan 提交于
When dwc2 core is in clock gating mode loading driver again causes driver fail. Because in that mode registers are not accessible. Added a flow of exiting clock gating mode to avoid the driver reload failure. Signed-off-by: NArtur Petrosyan <Arthur.Petrosyan@synopsys.com> Link: https://lore.kernel.org/r/20210413073731.3C81BA022E@mailhost.synopsys.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Artur Petrosyan 提交于
If not hibernation nor partial power down are supported, port resume is done using the clock gating programming flow. Adds a new flow of exiting clock gating when PC is resumed. Signed-off-by: NArtur Petrosyan <Arthur.Petrosyan@synopsys.com> Link: https://lore.kernel.org/r/20210413073723.BA0FEA022E@mailhost.synopsys.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Artur Petrosyan 提交于
If not hibernation nor partial power down are supported, clock gating is used to save power. Adds a new flow of entering clock gating when PC is suspended. Signed-off-by: NArtur Petrosyan <Arthur.Petrosyan@synopsys.com> Link: https://lore.kernel.org/r/20210413073716.30C13A0094@mailhost.synopsys.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Artur Petrosyan 提交于
When core is in clock gating state and an external hub is connected, upper layer sends URB enqueue request, which results in port reset issue. Added exit from clock gating state to avoid port reset issue and process upper layer request properly. Signed-off-by: NArtur Petrosyan <Arthur.Petrosyan@synopsys.com> Link: https://lore.kernel.org/r/20210413073708.ADFC6A0094@mailhost.synopsys.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Artur Petrosyan 提交于
Updates the implementation of exiting clock gating mode when core receives port resume. Instead of setting the required bit fields of the registers inline, called the "dwc2_host_exit_clock_gating()" function. Signed-off-by: NArtur Petrosyan <Arthur.Petrosyan@synopsys.com> Link: https://lore.kernel.org/r/20210413073701.367E0A022E@mailhost.synopsys.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Artur Petrosyan 提交于
Updates the implementation of entering clock gating mode when core receives port suspend. Instead of setting the required bit fields of the registers inline, called the "dwc2_host_enter_clock_gating()" function. Signed-off-by: NArtur Petrosyan <Arthur.Petrosyan@synopsys.com> Link: https://lore.kernel.org/r/20210413073653.9F493A0094@mailhost.synopsys.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Artur Petrosyan 提交于
Adds clock gating exit flow when set port feature reset is received in suspended state. Signed-off-by: NArtur Petrosyan <Arthur.Petrosyan@synopsys.com> Link: https://lore.kernel.org/r/20210413073646.27217A0094@mailhost.synopsys.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Artur Petrosyan 提交于
Added clock gating exit flow from session request interrupt handler according programming guide. Signed-off-by: NArtur Petrosyan <Arthur.Petrosyan@synopsys.com> Link: https://lore.kernel.org/r/20210413073638.921E8A0099@mailhost.synopsys.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Artur Petrosyan 提交于
Added exit from clock gating mode when wakeup interrupt is detected. To exit from the clock gating in device mode "dwc2_gadget_exit_clock_gating()" function is used with rem_wakeup parameter 0. To exit clock gating in host mode "dwc2_host_exit_clock_gating()" with rem_wakeup parameter 1. Acked-by: NMinas Harutyunyan <Minas.Harutyunyan@synopsys.com> Signed-off-by: NArtur Petrosyan <Arthur.Petrosyan@synopsys.com> Link: https://lore.kernel.org/r/20210413073630.EF2CEA0094@mailhost.synopsys.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Artur Petrosyan 提交于
If core doesn't support hibernation or partial power down power saving options, power can still be saved using clock gating on all the clocks. - Added entering clock gating state from USB_SUSPEND interrupt. Acked-by: NMinas Harutyunyan <Minas.Harutyunyan@synopsys.com> Signed-off-by: NArtur Petrosyan <Arthur.Petrosyan@synopsys.com> Link: https://lore.kernel.org/r/20210413073623.65355A022E@mailhost.synopsys.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Artur Petrosyan 提交于
Added host clock gating support functions according programming guide. Added function names: dwc2_host_enter_clock_gating() dwc2_host_exit_clock_gating() Acked-by: NMinas Harutyunyan <Minas.Harutyunyan@synopsys.com> Signed-off-by: NArtur Petrosyan <Arthur.Petrosyan@synopsys.com> Link: https://lore.kernel.org/r/20210413073615.B3E84A022E@mailhost.synopsys.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Artur Petrosyan 提交于
Added device clock gating support functions according programming guide. Moved "bus_suspended" flag to "dwc2_hsotg" struct because we need to set that flag while entering to clock gating in case when the driver is built in peripheral mode. Added function names: dwc2_gadget_enter_clock_gating() dwc2_gadget_exit_clock_gating() Acked-by: NMinas Harutyunyan <Minas.Harutyunyan@synopsys.com> Signed-off-by: NArtur Petrosyan <Arthur.Petrosyan@synopsys.com> Link: https://lore.kernel.org/r/20210413073607.F41E8A0094@mailhost.synopsys.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
- 12 4月, 2021 12 次提交
-
-
由 Greg Kroah-Hartman 提交于
This reverts commit 63cd7861 as it causes a build error: depmod: ERROR: Cycle detected: usbcore -> typec -> usbcore depmod: ERROR: Found 2 modules in dependency cycles! Reported-by: NStephen Rothwell <sfr@canb.auug.org.au> Link: https://lore.kernel.org/r/20210412213655.3776e15e@canb.auug.org.au Cc: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Pawel Laszczak 提交于
Patch adds flag EP_UNCONFIGURED to detect whether endpoint was unconfigured. This flag is set in cdnsp_reset_device after Reset Device command. Among others this command disables all non control endpoints. Flag is used in cdnsp_gadget_ep_disable to protect controller against invoking Configure Endpoint command on disabled endpoint. Lack of this protection in some cases caused that Configure Endpoint command completed with Context State Error code completion. Fixes: 3d829045 ("usb: cdnsp: cdns3 Add main part of Cadence USBSSP DRD Driver") Signed-off-by: NPawel Laszczak <pawell@cadence.com> Signed-off-by: NPeter Chen <peter.chen@kernel.org>
-
由 Colin Ian King 提交于
The variable ret is being initialized with a value that is never read and it is being updated later with a new value. The initialization is redundant and can be removed. Addresses-Coverity: ("Unused value") Signed-off-by: NColin Ian King <colin.king@canonical.com> Reviewed-by: NPawel Laszczak <pawell@cadence.com> Signed-off-by: NPeter Chen <peter.chen@kernel.org>
-
由 Wang Qing 提交于
dma_alloc_coherent already zeroes out memory, so memset is not needed. Signed-off-by: NWang Qing <wangqing@vivo.com> Reviewed-by: NPawel Laszczak <pawell@cadence.com> Acked-by: NPawel Laszczak <pawell@cadence.com> Signed-off-by: NPeter Chen <peter.chen@kernel.org>
-
由 Sanket Parmar 提交于
dma_alloc_coherent() might fail on the platform with a small DMA region. To avoid such failure in cdns3_prepare_aligned_request_buf(), dma_alloc_coherent() is replaced with dma_alloc_noncoherent() to allocate aligned request buffer of dynamic length. Reported-by: NAswath Govindraju <a-govindraju@ti.com> Signed-off-by: NSanket Parmar <sparmar@cadence.com> Signed-off-by: NPeter Chen <peter.chen@kernel.org>
-
由 Sanket Parmar 提交于
Allocation of DMA coherent memory in atomic context using dma_alloc_coherent() might fail on platforms with smaller DMA region. To fix it, dma_alloc_coherent() is replaced with dma_pool API to allocate a smaller chunk of DMA coherent memory for TRB rings. Reported-by: NAswath Govindraju <a-govindraju@ti.com> Signed-off-by: NSanket Parmar <sparmar@cadence.com> Signed-off-by: NPeter Chen <peter.chen@kernel.org>
-
由 Frank Li 提交于
The patch c450e48eb570: "usb: cdns3: add power lost support for system resume" from Feb 18, 2021, leads to the following static checker warning: drivers/usb/cdns3/core.c:551 cdns_resume() error: uninitialized symbol 'ret'. drivers/usb/cdns3/core.c 544 545 if (!role_changed) { 546 if (cdns->role == USB_ROLE_HOST) 547 ret = cdns_drd_host_on(cdns); 548 else if (cdns->role == USB_ROLE_DEVICE) 549 ret = cdns_drd_gadget_on(cdns); "ret" is uninitialized at else branch. Reported-by: NDan Carpenter <dan.carpenter@oracle.com> Signed-off-by: NFrank Li <frank.li@nxp.com> Signed-off-by: NPeter Chen <peter.chen@kernel.org>
-
由 Wei Yongjun 提交于
The function cdns_imx_system_resume() may have no callers depending on configuration, so it must be marked __maybe_unused to avoid harmless warning: drivers/usb/cdns3/cdns3-imx.c:378:12: warning: 'cdns_imx_system_resume' defined but not used [-Wunused-function] 378 | static int cdns_imx_system_resume(struct device *dev) | ^~~~~~~~~~~~~~~~~~~~~~ Fixes: 67982dfa59de ("usb: cdns3: imx: add power lost support for system resume") Reported-by: NHulk Robot <hulkci@huawei.com> Signed-off-by: NWei Yongjun <weiyongjun1@huawei.com> Signed-off-by: NPeter Chen <peter.chen@kernel.org>
-
由 Peter Chen 提交于
It is not correct using %pa to print virtual address of request->trb, and it is hard to print its physical address due to the virtual address is zero before using. It could use index (start_trb/end_trb) to know the current trb position, so no matter virtual address or physical address for request-trb is not so meaningful. Reported-by: NSteven Rostedt <rostedt@goodmis.org> Signed-off-by: NPeter Chen <peter.chen@kernel.org>
-
由 Frank Li 提交于
imx need special handle when controller lost power Signed-off-by: NPeter Chen <peter.chen@nxp.com> Signed-off-by: NFrank Li <frank.li@nxp.com> Signed-off-by: NPeter Chen <peter.chen@kernel.org>
-
由 Frank Li 提交于
If the controller lost its power during the system suspend, we need to do all initialiation operations. Signed-off-by: NPeter Chen <peter.chen@nxp.com> Signed-off-by: NFrank Li <frank.li@nxp.com> Signed-off-by: NPeter Chen <peter.chen@kernel.org>
-
由 Ye Bin 提交于
Add the missing unlock before return from function usbip_sockfd_store() in the error handling case. Fixes: bd8b8204 ("usbip: vudc synchronize sysfs code paths") Reported-by: NHulk Robot <hulkci@huawei.com> Acked-by: NShuah Khan <skhan@linuxfoundation.org> Signed-off-by: NYe Bin <yebin10@huawei.com> Link: https://lore.kernel.org/r/20210408112305.1022247-1-yebin10@huawei.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
- 10 4月, 2021 12 次提交
-
-
由 Serge Semin 提交于
In accordance with the USB HCD/DRD schema all the USB controllers are supposed to have DT-nodes named with prefix "^usb(@.*)?". Since the existing DT-nodes will be renamed in a subsequent patch let's fix the DWC3 Qcom-specific code to detect the DWC3 sub-node just by checking its compatible string to match the "snps,dwc3". The semantic of the code won't change seeing all the DWC USB3 nodes are supposed to have the compatible property with any of those strings set. Signed-off-by: NSerge Semin <Sergey.Semin@baikalelectronics.ru> Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Link: https://lore.kernel.org/r/20210409113029.7144-7-Sergey.Semin@baikalelectronics.ruSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Bixuan Cui 提交于
There is a error message within devm_ioremap_resource already, so remove the dev_err call to avoid redundant error message. Reported-by: NHulk Robot <hulkci@huawei.com> Signed-off-by: NBixuan Cui <cuibixuan@huawei.com> Link: https://lore.kernel.org/r/20210410024818.65659-1-cuibixuan@huawei.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Chunfeng Yun 提交于
Return the exactly delay time given by root hub descriptor, this helps to reduce resume time etc. Due to the root hub descriptor is usually provided by the host controller driver, if there is compatibility for a root hub, we can fix it easily without affect other root hub Acked-by: NAlan Stern <stern@rowland.harvard.edu> Signed-off-by: NChunfeng Yun <chunfeng.yun@mediatek.com> Link: https://lore.kernel.org/r/1618017645-12259-1-git-send-email-chunfeng.yun@mediatek.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Longfang Liu 提交于
Kunpeng920's EHCI controller does not have SBRN register. Reading the SBRN register when the controller driver is initialized will get 0. When rebooting the EHCI driver, ehci_shutdown() will be called. if the sbrn flag is 0, ehci_shutdown() will return directly. The sbrn flag being 0 will cause the EHCI interrupt signal to not be turned off after reboot. this interrupt that is not closed will cause an exception to the device sharing the interrupt. Therefore, the EHCI controller of Kunpeng920 needs to skip the read operation of the SBRN register. Acked-by: NAlan Stern <stern@rowland.harvard.edu> Signed-off-by: NLongfang Liu <liulongfang@huawei.com> Link: https://lore.kernel.org/r/1617958081-17999-1-git-send-email-liulongfang@huawei.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Marek Behún 提交于
Change my e-mail address to kabel@kernel.org, and fix my name in non-code parts (add diacritical mark). Link: https://lkml.kernel.org/r/20210325171123.28093-2-kabel@kernel.orgSigned-off-by: NMarek Behún <kabel@kernel.org> Cc: Bartosz Golaszewski <bgolaszewski@baylibre.com> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Jassi Brar <jassisinghbrar@gmail.com> Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Pavel Machek <pavel@ucw.cz> Signed-off-by: NAndrew Morton <akpm@linux-foundation.org> Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
-
由 Salil Mehta 提交于
Some trivial spelling mistakes which caught my eye during the review of the code. Signed-off-by: NSalil Mehta <salil.mehta@huawei.com> Link: https://lore.kernel.org/r/20210409074223.32480-1-salil.mehta@huawei.comSigned-off-by: NJakub Kicinski <kuba@kernel.org>
-
由 Sven Van Asbroeck 提交于
The ethernet frame length is calculated incorrectly. Depending on the value of RX_HEAD_PADDING, this may result in ethernet frames that are too short (cut off at the end), or too long (garbage added to the end). Fix by calculating the ethernet frame length correctly. For added clarity, use the ETH_FCS_LEN constant in the calculation. Many thanks to Heiner Kallweit for suggesting this solution. Suggested-by: NHeiner Kallweit <hkallweit1@gmail.com> Fixes: 3e21a10f ("lan743x: trim all 4 bytes of the FCS; not just 2") Link: https://lore.kernel.org/lkml/20210408172353.21143-1-TheSven73@gmail.com/Signed-off-by: NSven Van Asbroeck <thesven73@gmail.com> Reviewed-by: NGeorge McCollister <george.mccollister@gmail.com> Tested-by: NGeorge McCollister <george.mccollister@gmail.com> Link: https://lore.kernel.org/r/20210409003904.8957-1-TheSven73@gmail.comSigned-off-by: NJakub Kicinski <kuba@kernel.org>
-
由 Ilya Lipnitskiy 提交于
[<vendor>,]nr-gpios property is used by some GPIO drivers[0] to indicate the number of GPIOs present on a system, not define a GPIO. nr-gpios is not configured by #gpio-cells and can't be parsed along with other "*-gpios" properties. nr-gpios without the "<vendor>," prefix is not allowed by the DT spec[1], so only add exception for the ",nr-gpios" suffix and let the error message continue being printed for non-compliant implementations. [0] nr-gpios is referenced in Documentation/devicetree/bindings/gpio: - gpio-adnp.txt - gpio-xgene-sb.txt - gpio-xlp.txt - snps,dw-apb-gpio.yaml [1] Link: https://github.com/devicetree-org/dt-schema/blob/cb53a16a1eb3e2169ce170c071e47940845ec26e/schemas/gpio/gpio-consumer.yaml#L20 Fixes errors such as: OF: /palmbus@300000/gpio@600: could not find phandle Fixes: 7f00be96 ("of: property: Add device link support for interrupt-parent, dmas and -gpio(s)") Signed-off-by: NIlya Lipnitskiy <ilya.lipnitskiy@gmail.com> Cc: Saravana Kannan <saravanak@google.com> Cc: stable@vger.kernel.org # v5.5+ Link: https://lore.kernel.org/r/20210405222540.18145-1-ilya.lipnitskiy@gmail.comSigned-off-by: NRob Herring <robh@kernel.org>
-
由 Eli Cohen 提交于
When we suspend the VM, the VDPA interface will be reset. When the VM is resumed again, clear_virtqueues() will clear the available and used indices resulting in hardware virqtqueue objects becoming out of sync. We can avoid this function alltogether since qemu will clear them if required, e.g. when the VM went through a reboot. Moreover, since the hw available and used indices should always be identical on query and should be restored to the same value same value for virtqueues that complete in order, we set the single value provided by set_vq_state(). In get_vq_state() we return the value of hardware used index. Fixes: b35ccebe ("vdpa/mlx5: Restore the hardware used index after change map") Fixes: 1a86b377 ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices") Signed-off-by: NEli Cohen <elic@nvidia.com> Link: https://lore.kernel.org/r/20210408091047.4269-6-elic@nvidia.comSigned-off-by: NMichael S. Tsirkin <mst@redhat.com> Acked-by: NJason Wang <jasowang@redhat.com>
-
由 Eli Cohen 提交于
VIRTIO_F_VERSION_1 is a bit number. Use BIT_ULL() with mask conditionals. Also, in mlx5_vdpa_is_little_endian() use BIT_ULL for consistency with the rest of the code. Fixes: 1a86b377 ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices") Signed-off-by: NEli Cohen <elic@nvidia.com> Link: https://lore.kernel.org/r/20210408091047.4269-5-elic@nvidia.comSigned-off-by: NMichael S. Tsirkin <mst@redhat.com> Acked-by: NJason Wang <jasowang@redhat.com>
-
由 Eli Cohen 提交于
struct mlx5_core_dev has a bar_addr field that contains the correct bar address for the function regardless of whether it is pci function or sub function. Use it. Fixes: 1958fc2f ("net/mlx5: SF, Add auxiliary device driver") Signed-off-by: NEli Cohen <elic@nvidia.com> Reviewed-by: NParav Pandit <parav@nvidia.com> Link: https://lore.kernel.org/r/20210408091047.4269-4-elic@nvidia.comSigned-off-by: NMichael S. Tsirkin <mst@redhat.com> Acked-by: NJason Wang <jasowang@redhat.com>
-
由 Eli Cohen 提交于
In cases where the vdpa instance uses a SF (sub function), the DMA device is the parent device. Use a function to retrieve the correct DMA device. Fixes: 1958fc2f ("net/mlx5: SF, Add auxiliary device driver") Signed-off-by: NEli Cohen <elic@nvidia.com> Reviewed-by: NParav Pandit <parav@nvidia.com> Link: https://lore.kernel.org/r/20210408091047.4269-3-elic@nvidia.comSigned-off-by: NMichael S. Tsirkin <mst@redhat.com> Acked-by: NJason Wang <jasowang@redhat.com>
-