From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marek Vasut Date: Mon, 3 Feb 2014 19:06:59 +0100 Subject: [U-Boot] [PATCH 2/6] usb:udc:samsung: Remove redundant cache operation from Samsung UDC driver In-Reply-To: <20140203090506.01cc3d97@amdc2363> References: <1391170589-14340-1-git-send-email-l.majewski@samsung.com> <201402012349.26505.marex@denx.de> <20140203090506.01cc3d97@amdc2363> Message-ID: <201402031906.59954.marex@denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Monday, February 03, 2014 at 09:05:06 AM, Lukasz Majewski wrote: [...] > > > To sum up: > > > > > > 1. s3c_udc_ep0_zlp - EP0 ZLP packets don't need to invalidate the > > > cache (since it is zero length transmission) > > > > > > 2. s3c_udc_pre_setup - cache invalidation is not needed when I setup > > > buffer for OUT EP0 transmission. > > > > > > The above two invalidation calls had been added by me, and are mine > > > mistakes. Those don't contribute to transmission speed up (and > > > shall be regarded as a cosmetic changes) > > > > > > 3. setdma_rx - here I invalidate parts of the s3c UDC driver's > > > internal buffer. This call is not needed anymore since we reuse the > > > buffers passed from gadgets. > > > > And you do correct cache management on those in the UDC driver or in > > the gadget driver ? > > For download, buffers are allocated in gadgets. Then buffer is passed > to the UDC driver in a USB request. > After receiving data via USB the UDC driver takes care to invalidate > cache, hence the gadget can work on the data. > > Cache management is performed in the UDC driver. OK, this is the correct place. I just wanted to make sure about this. Thanks :) > > > This is the key speed improvement here. > > > > This should be in the commit message really ;-) > > I wrongly assumed, that code explains what was the rationale :-). I'm > going to prepare more verbose commit message for v2. Please do, thanks! Best regards, Marek Vasut