Message ID | 1589449416-2245-1-git-send-email-jun.li@nxp.com |
---|---|
State | New |
Headers | show
Return-Path: <SRS0=j7Ff=64=vger.kernel.org=stable-owner@kernel.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.8 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, MSGID_FROM_MTA_HEADER, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5832CC433E3 for <stable@archiver.kernel.org>; Thu, 14 May 2020 09:53:24 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 352BB20671 for <stable@archiver.kernel.org>; Thu, 14 May 2020 09:53:24 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="BXj+4reo" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725999AbgENJxW (ORCPT <rfc822;stable@archiver.kernel.org>); Thu, 14 May 2020 05:53:22 -0400 Received: from mail-eopbgr30053.outbound.protection.outlook.com ([40.107.3.53]:6195 "EHLO EUR03-AM5-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726024AbgENJxU (ORCPT <rfc822;stable@vger.kernel.org>); Thu, 14 May 2020 05:53:20 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=dK7ycujFfBZHnLpSQz2VwHOeqBCGKP+SiDjKgSjtkPv2wE/o6A+oDl/FhO0ToQVM50VmuxOJusO0Mkv11mxOmWaJbUYm4icMCQwAHOHLVuNUF4/PnvoCcSxYqFJFDduVIpHi6jnPehJiIr/WJYlyTdiCKDyxxYB1cMod/NVW9sbehp9rM6s2h4HLsCjaLIliPoMaXOVSPvTwFRCoKsycJRVCH8aSJXzgcUPle69c1JiQAdgekMh91IFb6w9g1QmHxDnPcRFz06r11ATlR860HcS9DIRfHlpBvJsw/jJVeRH5gJ4LITz4EVScaw4+8f51hpD8n6CCz1B+1m22H32d9w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=rsRTRtXV2DIyiEFEKdQre5EIcdGvgE4waxws/7kfMkw=; b=XIMbQpeCwiGqw3vnftbCTJTb4YX3Gq7IYVLdCeUFV6EYconUNZJUIJB/H7LblwkurhsAgWW22ymc6R3vStsyRep3VPJXIBV5j40iDt77WUFiXjbkrrf5YKnpFRP3u4T3iiT0m2MFUac7PWjUFA6l1txxkzDBtTTucL7f4wKD/55etSzB26Tj10GUz+pGS2sO7/zWUXqXm63Ue8/jGFD32joRobmMTSe5EuutD9oCYX2UK/06hn893UwGODp46bvDC7o0mQY4bfyWacCZqMGgjyvB0064Ug5AL2wxM8W+EBbAHZGvu364NBZd1a1RjkGxt5B4L//sfFs7u54CH3udcw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=rsRTRtXV2DIyiEFEKdQre5EIcdGvgE4waxws/7kfMkw=; b=BXj+4reoA2IRlwnFZ6lK3CZ1nzfZ/tPzAm2x/OWXhLkuSPcJiyAYjLRZ2jStoMD6VCRThx3EweBcBbGzLjfkEcH2hK+8Kmwhrh+c60obO06CDduL2sIp0TbNBCwhd/HOdpOtQLQRhbrw0kvb5Bhh+zsDLn2QUbpyPrSeaaeYPeg= Authentication-Results: intel.com; dkim=none (message not signed) header.d=none; intel.com; dmarc=none action=none header.from=nxp.com; Received: from VE1PR04MB6528.eurprd04.prod.outlook.com (2603:10a6:803:127::18) by VE1PR04MB6431.eurprd04.prod.outlook.com (2603:10a6:803:12a::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3000.25; Thu, 14 May 2020 09:53:13 +0000 Received: from VE1PR04MB6528.eurprd04.prod.outlook.com ([fe80::5086:ae9e:6397:6b03]) by VE1PR04MB6528.eurprd04.prod.outlook.com ([fe80::5086:ae9e:6397:6b03%7]) with mapi id 15.20.2979.033; Thu, 14 May 2020 09:53:13 +0000 From: Li Jun <jun.li@nxp.com> To: mathias.nyman@intel.com Cc: gregkh@linuxfoundation.org, baolin.wang@linaro.org, linux-usb@vger.kernel.org, stable@vger.kernel.org, linux-imx@nxp.com, peter.chen@nxp.com, stern@rowland.harvard.edu, mgautam@codeaurora.org, mathias.nyman@linux.intel.com Subject: [PATCH v2] usb: host: xhci-plat: keep runtime active when remove host Date: Thu, 14 May 2020 17:43:36 +0800 Message-Id: <1589449416-2245-1-git-send-email-jun.li@nxp.com> X-Mailer: git-send-email 2.7.4 Content-Type: text/plain X-ClientProxiedBy: SG2PR06CA0201.apcprd06.prod.outlook.com (2603:1096:4:1::33) To VE1PR04MB6528.eurprd04.prod.outlook.com (2603:10a6:803:127::18) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from localhost.localdomain (119.31.174.66) by SG2PR06CA0201.apcprd06.prod.outlook.com (2603:1096:4:1::33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3000.24 via Frontend Transport; Thu, 14 May 2020 09:53:09 +0000 X-Mailer: git-send-email 2.7.4 X-Originating-IP: [119.31.174.66] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 3ddf55ec-74db-48e7-7121-08d7f7ec9daa X-MS-TrafficTypeDiagnostic: VE1PR04MB6431: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: <VE1PR04MB64312C44CA833DA470911BF789BC0@VE1PR04MB6431.eurprd04.prod.outlook.com> X-MS-Oob-TLC-OOBClassifiers: OLM:2803; X-Forefront-PRVS: 040359335D X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: DgZBuw142udWZ5IiY9SLaXpUQAH2DzMuZ6KstuPr5XHUpTicafiE69FOEGi6hM/xg1vUq/09pFgbQWgZElRE3CBmV7vt0vgs6ZYqmCp2ZvtAgfaCNJrjMAc8r+lSVxGBB9uut/ihwBJ3XsIs+NqQMHuegyHsimwdKmaMu/iBblGpG4Dhk4/67Hz+VLJ4MasL/P4S/2eXi11BaLeWfjnOWJL65n/vWvIsc/Hwzv+1qQP3Be0PQ3lTMYC1HVEn/OcWiEf2jucvK46oY08add8vjbRazvGtOoFreVEQCgbf8L5D+3kl9/tkigzo0EnGYYhpIo+d+pBwr+2lkWQUndGMSDRb3BASOjlQnokK1avox9AGf6FguB+RIpW05gcTAcGWbdHeUROwyTlITAAi9ODjQpUkLZ9N32Ufcjfaz2pPBeq5xgHBRikCqVeofeMXZ6jHs7hrmTW9MIy2LsPk8O1R0LVPScci/uESOM8PD0w6tAfQpCMpqWwi367DX2R38xE8 X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:VE1PR04MB6528.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFTY:; SFS:(4636009)(396003)(136003)(346002)(39860400002)(366004)(376002)(36756003)(86362001)(6666004)(5660300002)(66556008)(66476007)(66946007)(2906002)(4326008)(186003)(16526019)(8676002)(6486002)(8936002)(45080400002)(6506007)(478600001)(26005)(69590400007)(6916009)(6512007)(956004)(316002)(52116002)(2616005); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData: zBPYVq20Jfz+xlQDCKkOBs/MKmS17tmIhKykHeSWEz4iYrz5r/BpslIOjXXa6cxJ//DStD2xEkBeb7WrByEwEpYqtLJRf53hPG0qOAgguqCmxDLO/JgdTl6dEfPKLKTnUToWKE+hbUQDEcayQgs0yL41ixsnGjJYUA5vOlPh48m59JygyigPIoRUhgEmspYn5AFQ75piBN4XY9pxN7xmh4DJzBszXfytGuqgsb7b4fRZNgC7KcpkouwqzIOEgIMDzBPY3ulsDX0st5iPkpLPW8TfkS1ARLtAC2r2Xaao2I/2vwzTmgE0pI+khlmANrGe9Dnte/03GrIpzkwr1AD/uH3Unq+BjnYCZwXwcZdz0HzUbh2W3cIHV+lzWTKVmh7I1AA39MxfYqXe467a7Rz6db6usuJZU9/UrGhoUmg2qxg/qNMLSMNG4Qc0XGQNDiPjt2vJoJZdlO2CboqUvSy0u7hf+j2FiylCPCSz9f1DTaM= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3ddf55ec-74db-48e7-7121-08d7f7ec9daa X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 May 2020 09:53:13.0507 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: gkWBde1KVU5a8erhyuq8n2x1eewEIE974YWdWaEQlLzsggv48l8W/VxmB2pq1fUT X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB6431 Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: <stable.vger.kernel.org> X-Mailing-List: stable@vger.kernel.org |
Series |
[v2] usb: host: xhci-plat: keep runtime active when remove host
|
expand
|
diff --git a/drivers/usb/host/xhci-plat.c b/drivers/usb/host/xhci-plat.c index 1d4f6f8..ea460b9 100644 --- a/drivers/usb/host/xhci-plat.c +++ b/drivers/usb/host/xhci-plat.c @@ -362,6 +362,7 @@ static int xhci_plat_remove(struct platform_device *dev) struct clk *reg_clk = xhci->reg_clk; struct usb_hcd *shared_hcd = xhci->shared_hcd; + pm_runtime_get_sync(&dev->dev); xhci->xhc_state |= XHCI_STATE_REMOVING; usb_remove_hcd(shared_hcd); @@ -375,8 +376,9 @@ static int xhci_plat_remove(struct platform_device *dev) clk_disable_unprepare(reg_clk); usb_put_hcd(hcd); - pm_runtime_set_suspended(&dev->dev); pm_runtime_disable(&dev->dev); + pm_runtime_put_noidle(&dev->dev); + pm_runtime_set_suspended(&dev->dev); return 0; }