From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A5C171DDC2D for ; Tue, 3 Dec 2024 10:05:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1733220307; cv=none; b=jgYiuujAA72BPlx/cNAbz3IwNkVzFUYSXCZ5MfeLcCyyzCGuWZ+69wy1tGqr9qny3Y1r8HCbKJd0WKcsFsHmBhO08ez34nmPFVTd2p4zu4hM/AXfwOlipW7T5ocQAAYaDqVohaYXL/XMIhf4n/nAIBjLXUYLDmhB0SSTy5cKrJs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1733220307; c=relaxed/simple; bh=ERm/KOzZ0QofivaaoDdvvigFykiR1AkE5xep61df6Ho=; h=Subject:To:Cc:From:Date:Message-ID:MIME-Version:Content-Type; b=daNwoFwzDnj2evUUzmicDGZYAyw/NvavFybL70sVcFZG4SKxwVfRjxpwkX+fYtvmEckj3gBUkyszwUHUJaurRASyQJPP2ZFdp2zsCLwYxWQDErEoaTqIy2H6SHsymeR4fQmwzFossPfc/RwyPiVX3uVhIpvT7tuR5SGM/y1VyOo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=ZvPrTiMU; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="ZvPrTiMU" Received: by smtp.kernel.org (Postfix) with ESMTPSA id CF029C4CECF; Tue, 3 Dec 2024 10:05:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1733220307; bh=ERm/KOzZ0QofivaaoDdvvigFykiR1AkE5xep61df6Ho=; h=Subject:To:Cc:From:Date:From; b=ZvPrTiMUF/BDrNEJnNLLEoUPSdr/gwG6/yjPyuLwwjDAKY7WeNH8i5nX7MAPDuEWr axuzPXUAxYemSVkpQLrSSKg4AdrypoHfwqxus6tFbijXY6pUNZCw6l4up3rq37aUYC RsF1VO2zVmXjwKePxFVtZQ7XXUMLnUmaJuYH8gXE= Subject: FAILED: patch "[PATCH] serial: amba-pl011: Fix RX stall when DMA is used" failed to apply to 6.1-stable tree To: kkartik@nvidia.com,gregkh@linuxfoundation.org,linus.walleij@linaro.org Cc: From: Date: Tue, 03 Dec 2024 11:04:56 +0100 Message-ID: <2024120356-maturing-junkman-2988@gregkh> Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=ANSI_X3.4-1968 Content-Transfer-Encoding: 8bit The patch below does not apply to the 6.1-stable tree. If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to . To reproduce the conflict and resubmit, you may use the following commands: git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-6.1.y git checkout FETCH_HEAD git cherry-pick -x 2bcacc1c87acf9a8ebc17de18cb2b3cfeca547cf # git commit -s git send-email --to '' --in-reply-to '2024120356-maturing-junkman-2988@gregkh' --subject-prefix 'PATCH 6.1.y' HEAD^.. Possible dependencies: thanks, greg k-h ------------------ original commit in Linus's tree ------------------ >From 2bcacc1c87acf9a8ebc17de18cb2b3cfeca547cf Mon Sep 17 00:00:00 2001 From: Kartik Rajput Date: Wed, 13 Nov 2024 14:56:29 +0530 Subject: [PATCH] serial: amba-pl011: Fix RX stall when DMA is used Function pl011_throttle_rx() calls pl011_stop_rx() to disable RX, which also disables the RX DMA by clearing the RXDMAE bit of the DMACR register. However, to properly unthrottle RX when DMA is used, the function pl011_unthrottle_rx() is expected to set the RXDMAE bit of the DMACR register, which it currently lacks. This causes RX to stall after the throttle API is called. Set RXDMAE bit in the DMACR register while unthrottling RX if RX DMA is used. Fixes: 211565b10099 ("serial: pl011: UPSTAT_AUTORTS requires .throttle/unthrottle") Cc: stable@vger.kernel.org Signed-off-by: Kartik Rajput Reviewed-by: Linus Walleij Link: https://lore.kernel.org/r/20241113092629.60226-1-kkartik@nvidia.com Signed-off-by: Greg Kroah-Hartman diff --git a/drivers/tty/serial/amba-pl011.c b/drivers/tty/serial/amba-pl011.c index 56e587b94823..2facdbcd73eb 100644 --- a/drivers/tty/serial/amba-pl011.c +++ b/drivers/tty/serial/amba-pl011.c @@ -1819,6 +1819,11 @@ static void pl011_unthrottle_rx(struct uart_port *port) pl011_write(uap->im, uap, REG_IMSC); + if (uap->using_rx_dma) { + uap->dmacr |= UART011_RXDMAE; + pl011_write(uap->dmacr, uap, REG_DMACR); + } + uart_port_unlock_irqrestore(&uap->port, flags); }