Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934388AbbKSST6 (ORCPT ); Thu, 19 Nov 2015 13:19:58 -0500 Received: from devils.ext.ti.com ([198.47.26.153]:58378 "EHLO devils.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751888AbbKSST5 (ORCPT ); Thu, 19 Nov 2015 13:19:57 -0500 From: Felipe Balbi To: Doug Anderson , John Youn CC: Yunzhi Li , Heiko =?utf-8?Q?St=C3=BCbner?= , "open list:ARM/Rockchip SoC..." , Julius Werner , "Herrero, Gregory" , "Kaukab, Yousaf" , Dinh Nguyen , Greg Kroah-Hartman , "linux-usb@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH v2 2/2] usb: dwc2: host: Clear interrupts before handling them In-Reply-To: References: <1446582629-30091-1-git-send-email-dianders@chromium.org> <1446582629-30091-2-git-send-email-dianders@chromium.org> <87wpthnc2e.fsf@saruman.tx.rr.com> <2B3535C5ECE8B5419E3ECBE30077290901DC3D696B@US01WEMBX2.internal.synopsys.com> User-Agent: Notmuch/0.21 (http://notmuchmail.org) Emacs/24.5.1 (x86_64-pc-linux-gnu) Date: Thu, 19 Nov 2015 12:19:14 -0600 Message-ID: <877fldg8d9.fsf@saruman.tx.rr.com> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2497 Lines: 68 --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Hi, Doug Anderson writes: >>>> isn't this a regression ? You're first clearing the interrupts and only >>>> then reading to check what's pending, however, what's pending has just >>>> been cleared. Seems like this should be: >>>> >>>> hprt0 =3D dwc2_readl(HPRT0); >>>> dwc2_writeal(PRTINT, GINTSTS); >>> >>> Actually, we could probably remove the setting of GINTSTS_PRTINT >>> completely. The docs I have say that the GINTSTS_PRTINT is read only >>> and that: >>> >>>> The core sets this bit to indicate a change in port status of one of t= he >>>> DWC_otg core ports in Host mode. The application must read the >>>> Host Port Control and Status (HPRT) register to determine the exact >>>> event that caused this interrupt. The application must clear the >>>> appropriate status bit in the Host Port Control and Status register to >>>> clear this bit. >>> >>> ...so writing PRTINT is probably useless, but John can confirm. >>> >> >> Yup, it seems it can be removed. > > How do you guys want this handled? Should I send up a new version of > this patch? ...or should I send a followon patch that does this > removal? I'll leave the final decision to John, but my opinion is that a new version of the patch would be preferrable. =2D-=20 balbi --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBAgAGBQJWThKiAAoJEIaOsuA1yqRE1ekQAKYj764iLKBN/Lk5l+iMLUDf jrCSCk0DmMtbVwmvsrU0XdZe3MEtnU1iFGpznGAMLHd1qv93b5L3S/zU8+5WMDJB i4Mzg7gq/WrRWBXQRysZ+2WujOQI2zmWeggmtY9dye3DU8pEMy5tTJF+tU652nVl djO968MeXmdhXa/KEnaIe5+ehUnXpfPhavtv2gPDeNEsE5tv9I9u12+VbTbp82Em g3077mPBt1KmntVMa4wJNFxHD7wwHygpfoSZozeLHkbPv0GlvMq80+yElJRl+dIb iECASFSdI8gOsgfTu5urPCQTB61a9FlWjEo1BYQykUkvZIpu/5CQW7lG3ilpod3X 6zwNyI2FdB7BBE/k0Zm6RACzKgLN0vTJgkC0Ov3l+3isakI5SMPTath1fdxXCgoA rYGWKBt6gZeXvYVP7h4698uA7/TjabRS23IIlpAP4K7SB4QK1AUPUg+NjmFtxOqO o2LY9Oy6E3YLBGo9EPq4kTNe9HG0zK7Eu4X+NDDbyAPjbkChObv407nAnGXGGaWp Q1oSnzvH5f+El+kYMU26BVwgQ2dW3ryOYwU3uly68khFxaxsMv68HPUg1N1zH9fo T53YyLH4Tdl68Q+fRJSrMDQTpstxNP2mvngfSmbfzukRFFkpFrph1HsUpAap/xFl xblFbdSbtt+jnOrEyOfs =4W8F -----END PGP SIGNATURE----- --=-=-=-- -- 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/