Message ID | 20230802090642.1642-1-zhuyinbo@loongson.cn |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9f41:0:b0:3e4:2afc:c1 with SMTP id v1csp333882vqx; Wed, 2 Aug 2023 02:46:59 -0700 (PDT) X-Google-Smtp-Source: APBJJlHylxsWKUTXJypkiT8TP1HJnvgrHkJOAthkKsaZcG6z42A5R64eLB+NSaq2ytAud2yM8YwM X-Received: by 2002:a17:906:2d0:b0:993:f2c2:750b with SMTP id 16-20020a17090602d000b00993f2c2750bmr4709257ejk.17.1690969619462; Wed, 02 Aug 2023 02:46:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690969619; cv=none; d=google.com; s=arc-20160816; b=qK0rSEbHJLPuKGMSByeid14wVzo/JsOiUwGdAn+rDVhT3q82KNV9zLjjnqXD7dg9Bb TTkyOqINfk9dyjW16TA1aqo+2BQqgXNBNwuOTCQLnLaxV9BwrdW6SwpGTUiUKn+SZx7o NQUvflf0AOlpagh3z+dQCV9+tNBFk5Odi6X5SIjn8zV5npPNT4h8xdTj40S/vBmL1zfc 4wcl5BcT+ld2eMhZlGPaZaw68x/kfS/C2SOsxGLL7Stv5WXYTuzFCzhiJ+osgPgK3Q90 PPo89wCojrHwBkZRRIsV7HrWTs+3DQIiJJ+IJap9q+GoVHuR5LlU9/bp/TWXvL2ZGX3U LfWw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=cvu50lHiRZkjNcvlkI4UavsB73GrOtB8F9uLtF0y6OY=; fh=dMF8Xt+VFduQTLOxafuB116I1iPdfW8efLAwYMyzbWY=; b=XS/LTPL7cR/A72i99Vn9FuO7x8NzE46CtTavHDRXnLpK4DEQ5oYbm/JJml67hnJjqD wT2e1qRTLjCCkdELvOVz7gDy6nWnLqsO2/Gyvmo47oEmYmWHBA7RiYlTwbDKzF4Xl8Hj 8s3Ghq0A0aRjUoU35sD92vmJ17G5XyMACwdj9S5vb7NR2fDgXkz9sab5oBiISN7XPW7g YngLaEl4OOKbajxNM4CkVFLug1GwOeLiOCkznezib3XTwstyk+VW3N8QufKvkpiax2ZJ vPFh2sLRmfEkVqvBHrSG1oH1FVbqrWGoYWhKLqcoenhwEu5SpbAI2235urtcvWpf/xjT UoZQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id lu22-20020a170906fad600b00982a267a399si10224346ejb.561.2023.08.02.02.46.36; Wed, 02 Aug 2023 02:46:59 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233845AbjHBJHC (ORCPT <rfc822;maxi.paulin@gmail.com> + 99 others); Wed, 2 Aug 2023 05:07:02 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59164 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233840AbjHBJG5 (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Wed, 2 Aug 2023 05:06:57 -0400 Received: from mail.loongson.cn (mail.loongson.cn [114.242.206.163]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 86204272A; Wed, 2 Aug 2023 02:06:55 -0700 (PDT) Received: from loongson.cn (unknown [10.20.42.201]) by gateway (Coremail) with SMTP id _____8DxPOuuHMpkNdQOAA--.29482S3; Wed, 02 Aug 2023 17:06:54 +0800 (CST) Received: from localhost.localdomain (unknown [10.20.42.201]) by localhost.localdomain (Coremail) with SMTP id AQAAf8CxriOqHMpk_mZFAA--.8718S2; Wed, 02 Aug 2023 17:06:53 +0800 (CST) From: Yinbo Zhu <zhuyinbo@loongson.cn> To: Mathias Nyman <mathias.nyman@intel.com>, Greg Kroah-Hartman <gregkh@linuxfoundation.org>, linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Jianmin Lv <lvjianmin@loongson.cn>, wanghongliang@loongson.cn, Liu Peibao <liupeibao@loongson.cn>, loongson-kernel@lists.loongnix.cn, Yinbo Zhu <zhuyinbo@loongson.cn> Subject: [PATCH] usb: xhci-plat: fix usb disconnect issue after s4 Date: Wed, 2 Aug 2023 17:06:42 +0800 Message-Id: <20230802090642.1642-1-zhuyinbo@loongson.cn> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-CM-TRANSID: AQAAf8CxriOqHMpk_mZFAA--.8718S2 X-CM-SenderInfo: 52kx5xhqerqz5rrqw2lrqou0/ X-Coremail-Antispam: 1Uk129KBjDUn29KB7ZKAUJUUUUU529EdanIXcx71UUUUU7KY7 ZEXasCq-sGcSsGvfJ3UbIjqfuFe4nvWSU5nxnvy29KBjDU0xBIdaVrnUUvcSsGvfC2Kfnx nUUI43ZEXa7xR_UUUUUUUUU== X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1773110159549112799 X-GMAIL-MSGID: 1773110159549112799 |
Series |
usb: xhci-plat: fix usb disconnect issue after s4
|
|
Commit Message
Yinbo Zhu
Aug. 2, 2023, 9:06 a.m. UTC
The xhci retaining bogus hardware states cause usb disconnect devices
connected before hibernation(s4) and refer to the commit '547d55fa83
("usb: ohci-platform: fix usb disconnect issue after s4")' which set
flag "hibernated" as true when resume-from-hibernation and that the
drivers will reset the hardware to get rid of any existing state and
make sure resume from hibernation re-enumerates everything for xhci.
Signed-off-by: Yinbo Zhu <zhuyinbo@loongson.cn>
---
drivers/usb/host/xhci-plat.c | 21 ++++++++++++++++++---
1 file changed, 18 insertions(+), 3 deletions(-)
Comments
On Wed, Aug 02, 2023 at 05:06:42PM +0800, Yinbo Zhu wrote: > The xhci retaining bogus hardware states cause usb disconnect devices > connected before hibernation(s4) and refer to the commit '547d55fa83 > ("usb: ohci-platform: fix usb disconnect issue after s4")' which set > flag "hibernated" as true when resume-from-hibernation and that the > drivers will reset the hardware to get rid of any existing state and > make sure resume from hibernation re-enumerates everything for xhci. > > Signed-off-by: Yinbo Zhu <zhuyinbo@loongson.cn> > --- > drivers/usb/host/xhci-plat.c | 21 ++++++++++++++++++--- > 1 file changed, 18 insertions(+), 3 deletions(-) What commit id does this fix? Should it go to stable kernels? thanks, greg k-h
在 2023/8/2 下午5:39, Greg Kroah-Hartman 写道: > On Wed, Aug 02, 2023 at 05:06:42PM +0800, Yinbo Zhu wrote: >> The xhci retaining bogus hardware states cause usb disconnect devices >> connected before hibernation(s4) and refer to the commit '547d55fa83 >> ("usb: ohci-platform: fix usb disconnect issue after s4")' which set >> flag "hibernated" as true when resume-from-hibernation and that the >> drivers will reset the hardware to get rid of any existing state and >> make sure resume from hibernation re-enumerates everything for xhci. >> >> Signed-off-by: Yinbo Zhu <zhuyinbo@loongson.cn> >> --- >> drivers/usb/host/xhci-plat.c | 21 ++++++++++++++++++--- >> 1 file changed, 18 insertions(+), 3 deletions(-) > > What commit id does this fix? > > Should it go to stable kernels? Sorry, perhaps it has been rebased, that tree was mainline tree next branch, you can find this commit id "f3d478858bec4" Thanks, Yinbo
On Wed, Aug 02, 2023 at 05:58:17PM +0800, Yinbo Zhu wrote: > > > 在 2023/8/2 下午5:39, Greg Kroah-Hartman 写道: > > On Wed, Aug 02, 2023 at 05:06:42PM +0800, Yinbo Zhu wrote: > > > The xhci retaining bogus hardware states cause usb disconnect devices > > > connected before hibernation(s4) and refer to the commit '547d55fa83 > > > ("usb: ohci-platform: fix usb disconnect issue after s4")' which set > > > flag "hibernated" as true when resume-from-hibernation and that the > > > drivers will reset the hardware to get rid of any existing state and > > > make sure resume from hibernation re-enumerates everything for xhci. > > > > > > Signed-off-by: Yinbo Zhu <zhuyinbo@loongson.cn> > > > --- > > > drivers/usb/host/xhci-plat.c | 21 ++++++++++++++++++--- > > > 1 file changed, 18 insertions(+), 3 deletions(-) > > > > What commit id does this fix? > > > > Should it go to stable kernels? > > > Sorry, perhaps it has been rebased, that tree was mainline tree next > branch, you can find this commit id "f3d478858bec4" Please fix this up and add a proper Fixes: line and if needed a cc: stable line. thanks, greg k-h
在 2023/8/2 下午6:06, Greg Kroah-Hartman 写道: > On Wed, Aug 02, 2023 at 05:58:17PM +0800, Yinbo Zhu wrote: >> >> >> 在 2023/8/2 下午5:39, Greg Kroah-Hartman 写道: >>> On Wed, Aug 02, 2023 at 05:06:42PM +0800, Yinbo Zhu wrote: >>>> The xhci retaining bogus hardware states cause usb disconnect devices >>>> connected before hibernation(s4) and refer to the commit '547d55fa83 >>>> ("usb: ohci-platform: fix usb disconnect issue after s4")' which set >>>> flag "hibernated" as true when resume-from-hibernation and that the >>>> drivers will reset the hardware to get rid of any existing state and >>>> make sure resume from hibernation re-enumerates everything for xhci. >>>> >>>> Signed-off-by: Yinbo Zhu <zhuyinbo@loongson.cn> >>>> --- >>>> drivers/usb/host/xhci-plat.c | 21 ++++++++++++++++++--- >>>> 1 file changed, 18 insertions(+), 3 deletions(-) >>> >>> What commit id does this fix? >>> >>> Should it go to stable kernels? >> >> >> Sorry, perhaps it has been rebased, that tree was mainline tree next >> branch, you can find this commit id "f3d478858bec4" > > Please fix this up and add a proper Fixes: line and if needed a cc: > stable line. Sorry, I don't quite understand what you mean. Thanks, Yinbo.
在 2023/8/2 下午6:06, Greg Kroah-Hartman 写道: > On Wed, Aug 02, 2023 at 05:58:17PM +0800, Yinbo Zhu wrote: >> >> >> 在 2023/8/2 下午5:39, Greg Kroah-Hartman 写道: >>> On Wed, Aug 02, 2023 at 05:06:42PM +0800, Yinbo Zhu wrote: >>>> The xhci retaining bogus hardware states cause usb disconnect devices >>>> connected before hibernation(s4) and refer to the commit '547d55fa83 >>>> ("usb: ohci-platform: fix usb disconnect issue after s4")' which set >>>> flag "hibernated" as true when resume-from-hibernation and that the >>>> drivers will reset the hardware to get rid of any existing state and >>>> make sure resume from hibernation re-enumerates everything for xhci. >>>> >>>> Signed-off-by: Yinbo Zhu <zhuyinbo@loongson.cn> >>>> --- >>>> drivers/usb/host/xhci-plat.c | 21 ++++++++++++++++++--- >>>> 1 file changed, 18 insertions(+), 3 deletions(-) >>> >>> What commit id does this fix? Sorry, I misunderstood your meaning earlier. This patch is not meant to fix the bugs in the previous commit id. Actually, it was to fix xhci issue that refer to repair of ohci (commit id "f3d478858bec4"). >>> >>> Should it go to stable kernels? Do I need to add Cc about stable kernel for the above situation? Thanks, Yinbo
Hi Yinbo, kernel test robot noticed the following build errors: [auto build test ERROR on usb/usb-testing] [also build test ERROR on usb/usb-next usb/usb-linus linus/master v6.5-rc5 next-20230808] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch#_base_tree_information] url: https://github.com/intel-lab-lkp/linux/commits/Yinbo-Zhu/usb-xhci-plat-fix-usb-disconnect-issue-after-s4/20230802-170845 base: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git usb-testing patch link: https://lore.kernel.org/r/20230802090642.1642-1-zhuyinbo%40loongson.cn patch subject: [PATCH] usb: xhci-plat: fix usb disconnect issue after s4 config: xtensa-randconfig-r093-20230808 (https://download.01.org/0day-ci/archive/20230809/202308090755.GOjEaQQg-lkp@intel.com/config) compiler: xtensa-linux-gcc (GCC) 12.3.0 reproduce: (https://download.01.org/0day-ci/archive/20230809/202308090755.GOjEaQQg-lkp@intel.com/reproduce) If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot <lkp@intel.com> | Closes: https://lore.kernel.org/oe-kbuild-all/202308090755.GOjEaQQg-lkp@intel.com/ All errors (new ones prefixed by >>, old ones prefixed by <<): WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/pwm/pwm-mediatek.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/pwm/pwm-samsung.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/video/backlight/platform_lcd.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/video/fbdev/goldfishfb.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/imx/clk-imxrt1050.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt6779-mm.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt6779-img.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt6779-vdec.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt6779-venc.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt6779-mfg.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt6779-aud.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt2712-apmixedsys.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt2712.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt2712-bdp.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt2712-img.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt2712-vdec.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt2712-venc.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt7622-eth.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt7622-hif.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt7622-aud.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt7986-apmixed.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt7986-topckgen.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8183-audio.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8183-cam.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8183-vdec.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8188-img.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8188-ipe.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8188-mfg.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8188-vdec.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8188-wpe.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192-aud.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192-cam.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192-imp_iic_wrap.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192-mdp.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192-mm.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192-msdc.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192-scp_adsp.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192-vdec.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8365-apmixedsys.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8365.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8365-apu.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8365-cam.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8365-vdec.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8365-venc.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/clk_test.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/clk-gate_test.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/dma/qcom/hdma.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/soc/imx/soc-imx8m.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/soc/ixp4xx/ixp4xx-qmgr.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/soc/mediatek/mtk-cmdq-helper.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/soc/amlogic/meson-clk-measure.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/regulator/tps6286x-regulator.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/tty/serial/8250/8250_base.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/tty/serial/8250/serial_cs.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/tty/serial/owl-uart.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/tty/goldfish.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/char/ttyprintk.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/char/hw_random/omap-rng.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/char/hw_random/omap3-rom-rng.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/char/hw_random/nomadik-rng.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/char/hw_random/st-rng.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/base/regmap/regmap-kunit.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/base/regmap/regmap-ram.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/base/regmap/regmap-raw-ram.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/base/regmap/regmap-w1.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/block/brd.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/block/loop.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/mfd/qcom-pm8008.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/dax/dax.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/usb/host/xhci-pci-renesas.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/usb/storage/uas.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/usb/gadget/function/usb_f_acm.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/usb/gadget/function/usb_f_mass_storage.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/usb/gadget/function/usb_f_fs.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/usb/gadget/function/usb_f_hid.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/usb/mon/usbmon.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/i2c/busses/i2c-pxa.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/media/tuners/tda9887.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/leds/flash/leds-rt4505.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/platform/goldfish/goldfish_pipe.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/platform/chrome/cros_kunit.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/mailbox/mtk-cmdq-mailbox.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/devfreq/governor_performance.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/devfreq/governor_userspace.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/iio/adc/ingenic-adc.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/hwtracing/intel_th/intel_th_msu_sink.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/nvmem/nvmem_brcm_nvram.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/nvmem/nvmem_u-boot-env.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/interconnect/imx/imx8mn-interconnect.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/mtd/parsers/brcm_u-boot.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/mtd/parsers/tplink_safeloader.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/mtd/chips/cfi_util.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/mtd/maps/map_funcs.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/fsi/fsi-core.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/fsi/fsi-master-hub.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/fsi/fsi-master-gpio.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/fsi/fsi-master-ast-cf.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/fsi/fsi-scom.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/siox/siox-bus-gpio.o >> ERROR: modpost: "xhci_suspend" [drivers/usb/host/xhci-plat-hcd.ko] undefined! >> ERROR: modpost: "xhci_resume" [drivers/usb/host/xhci-plat-hcd.ko] undefined!
在 2023/8/9 上午7:41, kernel test robot 写道: > Hi Yinbo, > > kernel test robot noticed the following build errors: > > [auto build test ERROR on usb/usb-testing] > [also build test ERROR on usb/usb-next usb/usb-linus linus/master v6.5-rc5 next-20230808] > [If your patch is applied to the wrong git tree, kindly drop us a note. > And when submitting patch, we suggest to use '--base' as documented in > https://git-scm.com/docs/git-format-patch#_base_tree_information] > > url: https://github.com/intel-lab-lkp/linux/commits/Yinbo-Zhu/usb-xhci-plat-fix-usb-disconnect-issue-after-s4/20230802-170845 > base: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git usb-testing > patch link: https://lore.kernel.org/r/20230802090642.1642-1-zhuyinbo%40loongson.cn > patch subject: [PATCH] usb: xhci-plat: fix usb disconnect issue after s4 > config: xtensa-randconfig-r093-20230808 (https://download.01.org/0day-ci/archive/20230809/202308090755.GOjEaQQg-lkp@intel.com/config) > compiler: xtensa-linux-gcc (GCC) 12.3.0 > reproduce: (https://download.01.org/0day-ci/archive/20230809/202308090755.GOjEaQQg-lkp@intel.com/reproduce) > > If you fix the issue in a separate patch/commit (i.e. not just a new version of > the same patch/commit), kindly add following tags > | Reported-by: kernel test robot <lkp@intel.com> > | Closes: https://lore.kernel.org/oe-kbuild-all/202308090755.GOjEaQQg-lkp@intel.com/ > > All errors (new ones prefixed by >>, old ones prefixed by <<): > > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/pwm/pwm-mediatek.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/pwm/pwm-samsung.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/video/backlight/platform_lcd.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/video/fbdev/goldfishfb.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/imx/clk-imxrt1050.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt6779-mm.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt6779-img.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt6779-vdec.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt6779-venc.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt6779-mfg.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt6779-aud.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt2712-apmixedsys.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt2712.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt2712-bdp.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt2712-img.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt2712-vdec.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt2712-venc.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt7622-eth.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt7622-hif.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt7622-aud.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt7986-apmixed.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt7986-topckgen.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8183-audio.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8183-cam.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8183-vdec.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8188-img.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8188-ipe.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8188-mfg.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8188-vdec.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8188-wpe.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192-aud.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192-cam.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192-imp_iic_wrap.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192-mdp.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192-mm.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192-msdc.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192-scp_adsp.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8192-vdec.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8365-apmixedsys.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8365.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8365-apu.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8365-cam.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8365-vdec.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/mediatek/clk-mt8365-venc.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/clk_test.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/clk-gate_test.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/dma/qcom/hdma.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/soc/imx/soc-imx8m.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/soc/ixp4xx/ixp4xx-qmgr.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/soc/mediatek/mtk-cmdq-helper.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/soc/amlogic/meson-clk-measure.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/regulator/tps6286x-regulator.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/tty/serial/8250/8250_base.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/tty/serial/8250/serial_cs.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/tty/serial/owl-uart.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/tty/goldfish.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/char/ttyprintk.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/char/hw_random/omap-rng.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/char/hw_random/omap3-rom-rng.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/char/hw_random/nomadik-rng.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/char/hw_random/st-rng.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/base/regmap/regmap-kunit.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/base/regmap/regmap-ram.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/base/regmap/regmap-raw-ram.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/base/regmap/regmap-w1.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/block/brd.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/block/loop.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/mfd/qcom-pm8008.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/dax/dax.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/usb/host/xhci-pci-renesas.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/usb/storage/uas.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/usb/gadget/function/usb_f_acm.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/usb/gadget/function/usb_f_mass_storage.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/usb/gadget/function/usb_f_fs.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/usb/gadget/function/usb_f_hid.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/usb/mon/usbmon.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/i2c/busses/i2c-pxa.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/media/tuners/tda9887.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/leds/flash/leds-rt4505.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/platform/goldfish/goldfish_pipe.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/platform/chrome/cros_kunit.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/mailbox/mtk-cmdq-mailbox.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/devfreq/governor_performance.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/devfreq/governor_userspace.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/iio/adc/ingenic-adc.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/hwtracing/intel_th/intel_th_msu_sink.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/nvmem/nvmem_brcm_nvram.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/nvmem/nvmem_u-boot-env.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/interconnect/imx/imx8mn-interconnect.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/mtd/parsers/brcm_u-boot.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/mtd/parsers/tplink_safeloader.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/mtd/chips/cfi_util.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/mtd/maps/map_funcs.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/fsi/fsi-core.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/fsi/fsi-master-hub.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/fsi/fsi-master-gpio.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/fsi/fsi-master-ast-cf.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/fsi/fsi-scom.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/siox/siox-bus-gpio.o >>> ERROR: modpost: "xhci_suspend" [drivers/usb/host/xhci-plat-hcd.ko] undefined! >>> ERROR: modpost: "xhci_resume" [drivers/usb/host/xhci-plat-hcd.ko] undefined! This compile error was due to that suspend callback initialization doesn't use CONFIG_PM_SLEEP in xhci_plat_pm_ops, and I will add it and fix this compile error. Thanks, Yinbo
diff --git a/drivers/usb/host/xhci-plat.c b/drivers/usb/host/xhci-plat.c index 28218c8f1837..41a213070435 100644 --- a/drivers/usb/host/xhci-plat.c +++ b/drivers/usb/host/xhci-plat.c @@ -451,7 +451,7 @@ static int __maybe_unused xhci_plat_suspend(struct device *dev) return 0; } -static int __maybe_unused xhci_plat_resume(struct device *dev) +static int __maybe_unused xhci_plat_resume_common(struct device *dev, struct pm_message pmsg) { struct usb_hcd *hcd = dev_get_drvdata(dev); struct xhci_hcd *xhci = hcd_to_xhci(hcd); @@ -466,7 +466,7 @@ static int __maybe_unused xhci_plat_resume(struct device *dev) if (ret) return ret; - ret = xhci_resume(xhci, PMSG_RESUME); + ret = xhci_resume(xhci, pmsg); if (ret) return ret; @@ -477,6 +477,16 @@ static int __maybe_unused xhci_plat_resume(struct device *dev) return 0; } +static int __maybe_unused xhci_plat_resume(struct device *dev) +{ + return xhci_plat_resume_common(dev, PMSG_RESUME); +} + +static int __maybe_unused xhci_plat_restore(struct device *dev) +{ + return xhci_plat_resume_common(dev, PMSG_RESTORE); +} + static int __maybe_unused xhci_plat_runtime_suspend(struct device *dev) { struct usb_hcd *hcd = dev_get_drvdata(dev); @@ -499,7 +509,12 @@ static int __maybe_unused xhci_plat_runtime_resume(struct device *dev) } const struct dev_pm_ops xhci_plat_pm_ops = { - SET_SYSTEM_SLEEP_PM_OPS(xhci_plat_suspend, xhci_plat_resume) + .suspend = xhci_plat_suspend, + .resume = xhci_plat_resume, + .freeze = xhci_plat_suspend, + .thaw = xhci_plat_resume, + .poweroff = xhci_plat_suspend, + .restore = xhci_plat_restore, SET_RUNTIME_PM_OPS(xhci_plat_runtime_suspend, xhci_plat_runtime_resume,