From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-bk0-f51.google.com (mail-bk0-f51.google.com [209.85.214.51]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority" (not verified)) by ozlabs.org (Postfix) with ESMTPS id 2F632B6F9F for ; Mon, 21 May 2012 16:53:48 +1000 (EST) Received: by bkcjg15 with SMTP id jg15so3759369bkc.38 for ; Sun, 20 May 2012 23:53:45 -0700 (PDT) Subject: RE: [PATCH] usb: fsl_udc: errata - postpone freeing current dTD From: Christoph Fritz To: Chen Peter-B29397 In-Reply-To: References: <20120409200656.GD2640@local> <20120410001017.GF2640@local> <20120410021151.GB23044@lovely.krouter> <20120411073918.GA9180@lovely.krouter> <20120509000221.GA19525@lovely.krouter> <20120513225126.GA3683@lovely.krouter> <20120514042142.GD9750@kroah.com> <20120520231724.GA7941@mars> Content-Type: text/plain; charset="UTF-8" Date: Mon, 21 May 2012 08:53:41 +0200 Message-ID: <1337583221.3394.21.camel@mars> Mime-Version: 1.0 Cc: Oliver Neukum , Kukjin Kim , Eric Miao , Li Yang-R58472 , Greg Kroah-Hartman , Sascha Hauer , "linux-usb@vger.kernel.org" , Nicolas Ferre , "linuxppc-dev@lists.ozlabs.org" , Felipe Balbi , Ido Shayevitz , Thomas Dahlmann , Estevam Fabio-R49496 , "Hans J. Koch" , Haojian Zhuang , Daniel Mack , Christian Hemp , Russell King , Neil Zhang , Fabio Estevam , Ben Dooks List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Hi Chen, On Mon, 2012-05-21 at 01:05 +0000, Chen Peter-B29397 wrote: > > > > > > USB controller may access a wrong address for the dTD (endpoint transfer > > descriptor) and then hang. This happens a lot when doing tests with > > g_ether module and iperf, a tool for measuring maximum TCP and UDP > > bandwidth. > > > > This hardware bug is explained in detail by errata number 2858 for i.MX23: > > http://cache.freescale.com/files/dsp/doc/errata/IMX23CE.pdf > > > > Does this patch fix your problem? yes, it does! :-) > > +#if defined CONFIG_ARCH_MX51 || defined CONFIG_SOC_IMX35 > > +#define POSTPONE_FREE_LAST_DTD > > +#else > > +#undef POSTPONE_FREE_LAST_DTD > > +#endif > > + > All i.mx SoC has this problem, if PowerPC also has this problem, you can > delete #if defined. Else, you can define it for all i.mx SoC > (CONFIG_ARCH_MXC | CONFIG_ARCH_MXS) I was unsure about this too. I can only test imx35. And mx51 was defined in your tree. So these two should be defined anyway. Marvell doesn't use any defines in mv_udc_core for their fix, so I would be fine without ifdefs too. Any objections? Please see next mail with patch v2. Thanks, -- Christoph