From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 17460C3DA63 for ; Tue, 23 Jul 2024 14:30:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Type: Content-Transfer-Encoding:MIME-Version:Message-ID:Date:Subject:CC:To:From: Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender :Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=4up/RiundZ3XTKcmR14Em4WUczTg1vdCrb4iDskupjY=; b=Fa3RHta338LiN7a6K2IlAfaiCu iegJBaz3nAPjI61vkQeVFqH2tep17rnkeLB0VrNibqB+VHln/2rhT993dZqiYahvM0kbvRfB/D3LN fQFKpLPKD/ZQWg8Y7Y9rMex9Nt5O5q0+6RLBYWMpSrO/Y4xQ0txGO73FQwBRzUNj5VudzJaRMFxvf LIirweuWCRd2EDu/Okk0SEaiygFne7K6vdS8x4vx6sRb3Xx6PwTUISJzOEgK/nQndlTVHBTEIAx14 QGz1OzHcv4e6V3d8y3R2cLxZ6f6079N4Zh2/U4FkbLuJesSX9ZLlZNlvT/3wtT2ex//TbxYxr3CwG cF74Mb0Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sWGWg-0000000CiSX-3Ghc; Tue, 23 Jul 2024 14:30:02 +0000 Received: from mx0a-001ae601.pphosted.com ([67.231.149.25] helo=mx0b-001ae601.pphosted.com) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sWGWD-0000000CiEq-0cMr for linux-arm-kernel@lists.infradead.org; Tue, 23 Jul 2024 14:29:35 +0000 Received: from pps.filterd (m0077473.ppops.net [127.0.0.1]) by mx0a-001ae601.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 46N4q37n006527; Tue, 23 Jul 2024 09:29:20 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cirrus.com; h=cc :content-transfer-encoding:content-type:date:from:message-id :mime-version:subject:to; s=PODMain02222019; bh=4up/RiundZ3XTKcm R14Em4WUczTg1vdCrb4iDskupjY=; b=NlXQ6s9jZioibdi42M7mb+TokvfMhiFo F7IEfM6Ql8X0HG2MxhvKYroKvsWsNXFOdNb8zP6ju40SwsDtVZoL8OTa9FXDAcvz 9s9gydAeGRmhZT+ylyBekI58qPVCZnEaEMATPGRYsZI8sDwoYyKDj+uEnpKecAKg l1jMco8gWVdEZo7POeSysvfEEkMU6aOFd1R2llVHzWD6BP6DNCqteCl7wrEM+qXs HJdxFQWE5divI7/YBVJ845oiJf/HnD2KoC1zJN1FX+9zljs3zZVGmgXSD4HDGPZn 0onO6GWB1z1V8HlEsTOEb5dQucrkuhxBXXIKy4ag76+Fz4OkBtVVgw== Received: from ediex02.ad.cirrus.com ([84.19.233.68]) by mx0a-001ae601.pphosted.com (PPS) with ESMTPS id 40gamx3dt1-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 23 Jul 2024 09:29:20 -0500 (CDT) Received: from ediex01.ad.cirrus.com (198.61.84.80) by ediex02.ad.cirrus.com (198.61.84.81) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.9; Tue, 23 Jul 2024 15:29:18 +0100 Received: from ediswmail9.ad.cirrus.com (198.61.86.93) by anon-ediex01.ad.cirrus.com (198.61.84.80) with Microsoft SMTP Server id 15.2.1544.9 via Frontend Transport; Tue, 23 Jul 2024 15:29:18 +0100 Received: from ausswws10.ad.cirrus.com (ausswws10.ad.cirrus.com [141.131.147.77]) by ediswmail9.ad.cirrus.com (Postfix) with ESMTP id 09993820244; Tue, 23 Jul 2024 14:29:16 +0000 (UTC) From: James Minor To: , CC: , , , , , , "James Minor" Subject: [RFC PATCH] tty: xilinx_uartps: Fix break detection Date: Tue, 23 Jul 2024 14:28:58 +0000 Message-ID: <20240723142858.2905083-1-jminor1@opensource.cirrus.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Proofpoint-GUID: k74a1duqDx8rTF8RE0pa5-7_2Pcn2Yfl X-Proofpoint-ORIG-GUID: k74a1duqDx8rTF8RE0pa5-7_2Pcn2Yfl X-Proofpoint-Spam-Reason: safe X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240723_072933_374102_08C845BD X-CRM114-Status: GOOD ( 12.56 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Commit b8a6c3b3d465 ("tty: xilinx_uartps: Fix the ignore_status") used read_status_mask to mask the isrstatus, even though the commit appears to be fixing the application of the ignore_status_mask. This has a side effect of clearing any pending CDNS_UART_IXR_FRAMING bit, which in turn means that cdns_uart_handle_rx break detection will only process framing errors when parity is enabled (INPCK set via cdns_uart_set_termios). Fix this by removing the extra isrstatus masking with read_status_mask, which still allows the ignore_status_mask to be applied. Fixes: b8a6c3b3d465 ("tty: xilinx_uartps: Fix the ignore_status") Signed-off-by: James Minor --- The other alternative to this would be a straight revert of b8a6c3b3d465, since read_status_mask and ignore_status_mask are both applied in cnds_uart_handle_rx anyway. Let me know the preference here and I will change accordingly. drivers/tty/serial/xilinx_uartps.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/tty/serial/xilinx_uartps.c b/drivers/tty/serial/xilinx_uartps.c index 2acfcea403ce..e9165ae3c2e8 100644 --- a/drivers/tty/serial/xilinx_uartps.c +++ b/drivers/tty/serial/xilinx_uartps.c @@ -485,7 +485,6 @@ static irqreturn_t cdns_uart_isr(int irq, void *dev_id) isrstatus &= ~CDNS_UART_IXR_TXEMPTY; } - isrstatus &= port->read_status_mask; isrstatus &= ~port->ignore_status_mask; /* * Skip RX processing if RX is disabled as RXEMPTY will never be set -- 2.34.1