Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp3521098pxf; Mon, 15 Mar 2021 11:23:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxCA3n81j0E2EDKlkoFk2Qt0b312fNAB4H5cIPLtI/K+Wxwj3SBnNJdDXVaFpMkzEncKFq6 X-Received: by 2002:aa7:d74d:: with SMTP id a13mr32749264eds.199.1615832638624; Mon, 15 Mar 2021 11:23:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1615832638; cv=none; d=google.com; s=arc-20160816; b=u7/vr6L+IKNrKXDBIr6eFEDE0RXjzOaHSHo69J50KpuBiIiVaNI54/lfrpt/wehdSl a77et5q2V4GsA6rcorvTFvJeVOpxrTmw6JeiN7JD/2av1KTPshWdbWWXkFxj/8XYuG7R hadspi49LOEKwSHu3OlafKpjo+PjbnPAaz2i/xoHhDs5TAoZnAo0qV3UgraVS/J2s6Bw gF06KvyhMrF5h0w0vu5YG86E38o2xCm26/TFgzSh8KK/0wrFTjEhxRc0ubuwKeFVx53u nl2xdRlrWAF8F5h37eeNMPEh4katiu93lUY71zhLiMceLTLGhP99HBLxXUUXrPLPdZ2t chVw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=ZIaR9mzlOXXMWDtCctto+35AiMsHZH8t/qJ+ep+HAoA=; b=XOXwwR9GGvNgvKisXfwCsbkXSGFAoWLEMvHLeTVc4KiOYS6xITC0YKeCFV1AX99anB nGhlVOc9/R824lmTEif8J/7UJ8aNph2w5+BdMoVIoYRNyc5C/T3b97+LSZInzhmh1XcX NdzoOPBOpIF16mupp8qXc1jJbRu14q8aUbxiak+upR+FexYAQRTqO4btiUju7kYHhYfa ofdYCW28s8OEnZLc2ZXmZjCdDeIkb6b5dO0i99CbLdnWppGTgzLm18NeH5oF/wmOKj6L reL+72WrwDCbyQCIwWdLbEYDVkMDmq3ztKA0CxcNfrlJH1yJfMlIet01dORWHBUCBhIV RLyQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=qF8gfT11; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id hr14si12277618ejc.394.2021.03.15.11.23.35; Mon, 15 Mar 2021 11:23:58 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=qF8gfT11; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238491AbhCOOXU (ORCPT + 99 others); Mon, 15 Mar 2021 10:23:20 -0400 Received: from mail.kernel.org ([198.145.29.99]:38284 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232766AbhCOOAR (ORCPT ); Mon, 15 Mar 2021 10:00:17 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 5D1BE64F5C; Mon, 15 Mar 2021 13:59:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1615816792; bh=31kDPtM0zHYIOc9UVzxVZTWXEYvH7Rx6TGQp70apgAE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=qF8gfT11rWMiILF2JJWLpi4JfVTzHDSRrdLSSpHijuCvVH87bgD6sCESF6sMTQKS+ tiM4cS/KaNpV/UQaAZlyu8DjHbJ7aYNUIbzKkWdNPOiOWJsRXZw/2TJaj9bnJCq3jA qkwVPtM9nMHPrWxPu5YgDRqv5gSC5QNHm9R0aaKU= From: gregkh@linuxfoundation.org To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Forest Crossman , Mathias Nyman Subject: [PATCH 5.4 113/168] usb: xhci: Fix ASMedia ASM1042A and ASM3242 DMA addressing Date: Mon, 15 Mar 2021 14:55:45 +0100 Message-Id: <20210315135554.071525001@linuxfoundation.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210315135550.333963635@linuxfoundation.org> References: <20210315135550.333963635@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Greg Kroah-Hartman From: Forest Crossman commit b71c669ad8390dd1c866298319ff89fe68b45653 upstream. I've confirmed that both the ASMedia ASM1042A and ASM3242 have the same problem as the ASM1142 and ASM2142/ASM3142, where they lose some of the upper bits of 64-bit DMA addresses. As with the other chips, this can cause problems on systems where the upper bits matter, and adding the XHCI_NO_64BIT_SUPPORT quirk completely fixes the issue. Cc: stable@vger.kernel.org Signed-off-by: Forest Crossman Signed-off-by: Mathias Nyman Link: https://lore.kernel.org/r/20210311115353.2137560-4-mathias.nyman@linux.intel.com Signed-off-by: Greg Kroah-Hartman --- drivers/usb/host/xhci-pci.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) --- a/drivers/usb/host/xhci-pci.c +++ b/drivers/usb/host/xhci-pci.c @@ -62,6 +62,7 @@ #define PCI_DEVICE_ID_ASMEDIA_1042A_XHCI 0x1142 #define PCI_DEVICE_ID_ASMEDIA_1142_XHCI 0x1242 #define PCI_DEVICE_ID_ASMEDIA_2142_XHCI 0x2142 +#define PCI_DEVICE_ID_ASMEDIA_3242_XHCI 0x3242 static const char hcd_name[] = "xhci_hcd"; @@ -258,11 +259,14 @@ static void xhci_pci_quirks(struct devic pdev->device == PCI_DEVICE_ID_ASMEDIA_1042_XHCI) xhci->quirks |= XHCI_BROKEN_STREAMS; if (pdev->vendor == PCI_VENDOR_ID_ASMEDIA && - pdev->device == PCI_DEVICE_ID_ASMEDIA_1042A_XHCI) + pdev->device == PCI_DEVICE_ID_ASMEDIA_1042A_XHCI) { xhci->quirks |= XHCI_TRUST_TX_LENGTH; + xhci->quirks |= XHCI_NO_64BIT_SUPPORT; + } if (pdev->vendor == PCI_VENDOR_ID_ASMEDIA && (pdev->device == PCI_DEVICE_ID_ASMEDIA_1142_XHCI || - pdev->device == PCI_DEVICE_ID_ASMEDIA_2142_XHCI)) + pdev->device == PCI_DEVICE_ID_ASMEDIA_2142_XHCI || + pdev->device == PCI_DEVICE_ID_ASMEDIA_3242_XHCI)) xhci->quirks |= XHCI_NO_64BIT_SUPPORT; if (pdev->vendor == PCI_VENDOR_ID_ASMEDIA &&