Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754692AbbG0JcF (ORCPT ); Mon, 27 Jul 2015 05:32:05 -0400 Received: from bear.ext.ti.com ([192.94.94.41]:39942 "EHLO bear.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753305AbbG0JcB (ORCPT ); Mon, 27 Jul 2015 05:32:01 -0400 Message-ID: <55B5FA84.1040508@ti.com> Date: Mon, 27 Jul 2015 12:31:48 +0300 From: Roger Quadros User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.8.0 MIME-Version: 1.0 To: Peter Chen CC: Li Jun , , , , , , , , , , , Subject: Re: [PATCH v3 10/11] usb: otg: Add dual-role device (DRD) support References: <1436350777-28056-1-git-send-email-rogerq@ti.com> <1436350777-28056-11-git-send-email-rogerq@ti.com> <20150717090212.GC4515@shlinux2> <55A8DD30.5030407@ti.com> <20150720012308.GB4584@shlinux2> In-Reply-To: <20150720012308.GB4584@shlinux2> Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1334 Lines: 47 On 20/07/15 04:23, Peter Chen wrote: > On Fri, Jul 17, 2015 at 01:47:12PM +0300, Roger Quadros wrote: >>>> + * DRD mode hardware Inputs >>>> + * >>>> + * @id: TRUE for B-device, FALSE for A-device. >>>> + * @vbus: VBUS voltage in regulation. >>>> + * >>>> * OTG hardware Inputs >>>> * >>>> * Common inputs for A and B device >>>> @@ -122,7 +127,8 @@ enum otg_fsm_timer { >>>> */ >>>> struct otg_fsm { >>>> /* Input */ >>>> - int id; >>>> + int id; /* DRD + OTG */ >>>> + int vbus; /* DRD only */ >>> >>> Existing b_sess_vld can be also used for drd only case, no need create >>> a new flag. >> >> b_sess_vld is a bit confusing to people not familiar with OTG. >> My suggestion is to use dedicated 'vbus' flag for DRD case >> for simplicity. >> > > Since OTG DRD is the subset in OTG FSM (FSM, data structure, APIs, etc), > I agree with Jun to reuse existing variables, and we can add some comments > for b_sess_vld if needed. OK then. I'll get rid of vbus and use b_sess_vld. cheers, -roger > > >>> >>>> int adp_change; >>>> int power_up; >>>> int a_srp_det; >> -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/