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 X-Spam-Level: X-Spam-Status: No, score=-6.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7B7BDC43215 for ; Tue, 19 Nov 2019 06:00:38 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 445CD21850 for ; Tue, 19 Nov 2019 06:00:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1574143238; bh=W9hljRTPfD9xTRTujr2m9ZfS2Reoa3BMcfnnVV8pCEQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=zQmN1KQzVAhM4zredMVERUdbUCPfMVSNTufAXB0fi0sG37J8iYHyUVJXhg7I4Inmu YsXG12iNnyZiqGpoGEj8n2mMzErkKolYaCMxB654QeIeCvMqu44s/S6bQF3Sz23TYj 5kgPp8Z2qqmdnsuzXMnuBGUhTOWK7xsVuC0C3eDE= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730950AbfKSFpW (ORCPT ); Tue, 19 Nov 2019 00:45:22 -0500 Received: from mail.kernel.org ([198.145.29.99]:40936 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730299AbfKSFpS (ORCPT ); Tue, 19 Nov 2019 00:45:18 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id DDB9B2071B; Tue, 19 Nov 2019 05:45:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1574142317; bh=W9hljRTPfD9xTRTujr2m9ZfS2Reoa3BMcfnnVV8pCEQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=f2k4jNrrke0khBjaiw102jSXWBIsWjs8mOiDc2ki0OzN92LJaxVH/yiv7GY8ZjV7u GEleq4UlejRZmeNFGRJ62hldnHg+m9aT2JjbNNE2xN8pQxy7fWwsqMkv0T2pgeebdB kF24Y1eggr13ux0ci7pVfRj8TgZ6Ct/3uDHiDrhY= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Evan Green Subject: [PATCH 4.14 005/239] Revert "Input: synaptics-rmi4 - avoid processing unknown IRQs" Date: Tue, 19 Nov 2019 06:16:45 +0100 Message-Id: <20191119051257.800659852@linuxfoundation.org> X-Mailer: git-send-email 2.24.0 In-Reply-To: <20191119051255.850204959@linuxfoundation.org> References: <20191119051255.850204959@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Evan Green This reverts commit 7b9f7a928255a232012be55cb95db30e963b83a7. That change should have had a fixes tag for commit 24d28e4f1271 ("Input: synaptics-rmi4 - convert irq distribution to irq_domain"). The conversion to irq_domain introduced the issue being fixed by this commit. In older kernels the bitmap IRQ accounting is done differently, and it doesn't suffer from the same issue of calling handle_nested_irq(0). Keeping this commit on kernels 4.14 and older causes problems with touchpads due to the different semantics of the IRQ bitmasks. Signed-off-by: Evan Green Signed-off-by: Greg Kroah-Hartman --- drivers/input/rmi4/rmi_driver.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) --- a/drivers/input/rmi4/rmi_driver.c +++ b/drivers/input/rmi4/rmi_driver.c @@ -165,7 +165,7 @@ static int rmi_process_interrupt_request } mutex_lock(&data->irq_mutex); - bitmap_and(data->irq_status, data->irq_status, data->fn_irq_bits, + bitmap_and(data->irq_status, data->irq_status, data->current_irq_mask, data->irq_count); /* * At this point, irq_status has all bits that are set in the @@ -412,8 +412,6 @@ static int rmi_driver_set_irq_bits(struc bitmap_copy(data->current_irq_mask, data->new_irq_mask, data->num_of_irq_regs); - bitmap_or(data->fn_irq_bits, data->fn_irq_bits, mask, data->irq_count); - error_unlock: mutex_unlock(&data->irq_mutex); return error; @@ -427,8 +425,6 @@ static int rmi_driver_clear_irq_bits(str struct device *dev = &rmi_dev->dev; mutex_lock(&data->irq_mutex); - bitmap_andnot(data->fn_irq_bits, - data->fn_irq_bits, mask, data->irq_count); bitmap_andnot(data->new_irq_mask, data->current_irq_mask, mask, data->irq_count);