From: Marek Vasut Date: Wed, 9 Jan 2019 16:04:12 +0100 Subject: [U-Boot] [PATCH v2] usb: xhci-mem: Fix scratchpad array issue In-Reply-To: References: <1546829104-8904-1-git-send-email-ye.li@nxp.com> <77085b10-d944-1824-e8ef-407436385f0f@denx.de> Message-ID: <0066590a-dfbe-a6bd-1ef9-e9db641e63a1@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 1/9/19 8:05 AM, Bin Meng wrote: > On Tue, Jan 8, 2019 at 7:19 PM Marek Vasut wrote: >> >> On 1/8/19 7:34 AM, Bin Meng wrote: >>> On Tue, Jan 8, 2019 at 12:00 PM Ye Li wrote: >>>> >>>> On 1/7/2019 5:54 PM, Bin Meng wrote: >>>>> On Mon, Jan 7, 2019 at 10:45 AM Ye Li wrote: >>>>>> >>>>>> After updating the value of dev_context_ptrs[0], we should flush this >>>>>> from cache to memory. Otherwise the xhci controller won't use it. >>>>>> >>>>>> Signed-off-by: Ye Li >>>>>> Reviewed-by: Marek Vasut >>>>>> --- >>>>>> Changes for v2: >>>>>> - Change to use sizeof(ctrl->dcbaa->dev_context_ptrs[0]) >>>>>> >>>>>> drivers/usb/host/xhci-mem.c | 3 +++ >>>>>> 1 file changed, 3 insertions(+) >>>>>> >>>>> >>>>> Reviewed-by: Bin Meng >>>>> >>>>> But you need do the same in xhci_scratchpad_free() too. Please fix it in v3. >>>>> >>>> The xhci controller has been stopped before calling xhci_scratchpad_free, is it necessary to >>>> add flush in this function? And I don't see other buffers are flushed when freeing. >>>> >>> >>> Ah, yes. It's called after HCD reset, so that's not needed. >> >> Shall I pick this for this release then, Bin ? >> > > Yes, I think so. Applied, thanks. -- Best regards, Marek Vasut