Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp2014831imm; Thu, 19 Jul 2018 11:35:19 -0700 (PDT) X-Google-Smtp-Source: AAOMgpcYESs1vYQ6u+TMOMJm8ELcgn1W0LVv+5eKb4IE/x1gH3fThqsEHPq6P9q3h12BBlZJeRoN X-Received: by 2002:a17:902:a5:: with SMTP id a34-v6mr11379185pla.60.1532025319001; Thu, 19 Jul 2018 11:35:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1532025318; cv=none; d=google.com; s=arc-20160816; b=hqFihVLo1K1MJ22f6PAORHvMI/zOjCZ5Q1R8MCTuAKqgj7xoKmMQ0axpg9fAfq0/c5 WbPaWY2zUHJTos3m36aXkgleUPM0aim2yNZhoyz2zZ8GajX/mIyGKWxLExyPgfnHFI0F m9lfB/8gXBBkL9f93rTBcp4+S3UnooRZ4aJZQogMajipC62ivglGPrUh/20fqakDn5VK MQ7b2WbvFDk8HR8OoD9C3gAdAwp1w0DUKAfpaSbjQg2tstp7I+LzTElfR5yaUbsHbrd0 w14GkvsKH1xWGFq6r/WrweuSJjVkFgvQ4isl2jp2+RAFhhamvHjQFrY20DcODsVfpJFl oSjw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:mail-followup-to :message-id:subject:cc:to:from:date:dkim-signature :arc-authentication-results; bh=LR+wVegPcsrJwgcyyp2M5e7JGdgNRc+u1B0h55KHgS8=; b=o4ZaCJ9jDCt2jjNx8YM+as2tYaW+mMYyFPd18W/ydCHiJ+qJ1418ti18ZgBa8uR7wk gVlTC+8pKhBucy376w4Q+X7BANHzfQU+UBsPM6uqVP82XX2HdfZq5SiXcStJBHZnBS7Z i0p/ouRn3cHhmk+xluumIZ4gpBLw01gdZMUB2QixZtVoeFnAlGxKnO0x7DN8NOdXyQPT htQLwdTfAji/JesJfC5PriNELbl90lk5Pu/t1eJJ09g1lehNH763728ZEVFvSCgRlU0z qYy4Jn0Xzdj1xivxc5LqBKYx8YV0Fj5BtAWc4xdqORPfUv3aOoSCLhdsGQFsK4FpyrOK TxLg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=yrfhCsg7; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v22-v6si5914732plo.123.2018.07.19.11.35.03; Thu, 19 Jul 2018 11:35:18 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=yrfhCsg7; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732386AbeGSTSn (ORCPT + 99 others); Thu, 19 Jul 2018 15:18:43 -0400 Received: from lelv0142.ext.ti.com ([198.47.23.249]:60910 "EHLO lelv0142.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731847AbeGSTSn (ORCPT ); Thu, 19 Jul 2018 15:18:43 -0400 Received: from dlelxv90.itg.ti.com ([172.17.2.17]) by lelv0142.ext.ti.com (8.15.2/8.15.2) with ESMTP id w6JIYH8A085016; Thu, 19 Jul 2018 13:34:17 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1532025257; bh=LR+wVegPcsrJwgcyyp2M5e7JGdgNRc+u1B0h55KHgS8=; h=Date:From:To:CC:Subject:References:In-Reply-To; b=yrfhCsg77RnVSJpmmjV1xwk2x52bJVhkcXWPS3J5meEFu5YSoFY1rTbnrJsuJoGZZ s2tZHdysq9HYl/Fyj5zvz7/tkGHCc7H3cPJXaNSepOuDg+QZuHF1dJ4llOm1gqePEE m1uK9SimPxxc2M7sBJ89r+kpeCndx8T7xpERmtN0= Received: from DLEE100.ent.ti.com (dlee100.ent.ti.com [157.170.170.30]) by dlelxv90.itg.ti.com (8.14.3/8.13.8) with ESMTP id w6JIYH6g030820; Thu, 19 Jul 2018 13:34:17 -0500 Received: from DLEE106.ent.ti.com (157.170.170.36) by DLEE100.ent.ti.com (157.170.170.30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1466.3; Thu, 19 Jul 2018 13:34:16 -0500 Received: from dflp32.itg.ti.com (10.64.6.15) by DLEE106.ent.ti.com (157.170.170.36) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.1.1466.3 via Frontend Transport; Thu, 19 Jul 2018 13:34:16 -0500 Received: from localhost (ileax41-snat.itg.ti.com [10.172.224.153]) by dflp32.itg.ti.com (8.14.3/8.13.8) with ESMTP id w6JIYG3l005379; Thu, 19 Jul 2018 13:34:16 -0500 Date: Thu, 19 Jul 2018 13:34:16 -0500 From: Bin Liu To: Jagan Teki CC: Greg Kroah-Hartman , , linux-kernel Subject: Re: [PATCH] usb: musb: Call musb_platform_exit from musb_stop Message-ID: <20180719183416.GE3949@uda0271908> Mail-Followup-To: Bin Liu , Jagan Teki , Greg Kroah-Hartman , linux-usb@vger.kernel.org, linux-kernel References: <20180719101038.9465-1-jagan@amarulasolutions.com> <20180719153706.GD3949@uda0271908> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jul 19, 2018 at 11:16:18PM +0530, Jagan Teki wrote: > On Thu, Jul 19, 2018 at 9:07 PM, Bin Liu wrote: > > Hi, > > > > On Thu, Jul 19, 2018 at 03:40:38PM +0530, Jagan Teki wrote: > >> musb stop is musb core call during unregister or shutting down > >> gadget or host musb. For graceful exit add musb_platform_exit > >> on musb_stop so-that it can exit the musb platform driver as well. > > > > Thanks for the patch. but musb_stop() is called in the .udc_stop() and > > host .stop() hooks, which can stop (and restart) at any time by the udc > > or host core, not really during unregister. musb_platform_init() is not > > called in .udc_start() and .start() hooks, so we shouldn't add > > musb_platform_exit() in musb_stop(). > > Thanks for the explanation. > > Look like musb_platform_exit calling during musb_remove call of > platform driver. can you explain how the shutdown sequence happen > because of if udc_stop call musb_stop to shutdown how come musb_stop() only disables for example irq and session. I didn't read how udc_stop() is used though. > platform_exit will shutdown it's PHY and CLK bits. or is it in platform_exit() is called in musb_remove(). Not sure if this answers your question though. Regards, -Bin.