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=-9.0 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,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 65286C43381 for ; Fri, 22 Mar 2019 11:59:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 2B29820830 for ; Fri, 22 Mar 2019 11:59:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1553255961; bh=P5S75PlBCwQQLSrvpSucLsgGi/fDtrawVYMrB0L4y5I=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=opMWzk6rQgu+rnnqf3mE4TmKiXjrI433IjOigsu5AGUQ+rF0RxGBth2w3GGhKmlhJ +YMuov95sWEDA+dr6bVinKkBqh69iewru3XCEXU8nknsgwBJEFReCZ0EH82oure5po YO6/7oEfG9mvZOGf25K/+/N5xS94aPwr005hZGRY= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387953AbfCVL7T (ORCPT ); Fri, 22 Mar 2019 07:59:19 -0400 Received: from mail.kernel.org ([198.145.29.99]:36236 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387395AbfCVL7P (ORCPT ); Fri, 22 Mar 2019 07:59:15 -0400 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 49CFD20830; Fri, 22 Mar 2019 11:59:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1553255954; bh=P5S75PlBCwQQLSrvpSucLsgGi/fDtrawVYMrB0L4y5I=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=fXF+aorldrw2bWDtdN0b0DRgta7Ddk7I5/FC5XQqAMvZ1vImQelaJtiLTOegylZ1z NFxat9Mdt7fNuXQxhsnV+kvTzsbQp0wU00sXpZYDRMYmNIobphMT2CT0isA92vkVfg Jbnf3ir/fz5OaRiu5CwIBkcT83HpLPGNwaoA9PqQ= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Dmitry Torokhov , Sasha Levin Subject: [PATCH 4.19 047/280] Input: matrix_keypad - use flush_delayed_work() Date: Fri, 22 Mar 2019 12:13:20 +0100 Message-Id: <20190322111308.951114771@linuxfoundation.org> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190322111306.356185024@linuxfoundation.org> References: <20190322111306.356185024@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review X-Patchwork-Hint: ignore 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 4.19-stable review patch. If anyone has any objections, please let me know. ------------------ [ Upstream commit a342083abe576db43594a32d458a61fa81f7cb32 ] We should be using flush_delayed_work() instead of flush_work() in matrix_keypad_stop() to ensure that we are not missing work that is scheduled but not yet put in the workqueue (i.e. its delay timer has not expired yet). Signed-off-by: Dmitry Torokhov Signed-off-by: Sasha Levin --- drivers/input/keyboard/matrix_keypad.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/input/keyboard/matrix_keypad.c b/drivers/input/keyboard/matrix_keypad.c index 403452ef00e6..3d1cb7bf5e35 100644 --- a/drivers/input/keyboard/matrix_keypad.c +++ b/drivers/input/keyboard/matrix_keypad.c @@ -222,7 +222,7 @@ static void matrix_keypad_stop(struct input_dev *dev) keypad->stopped = true; spin_unlock_irq(&keypad->lock); - flush_work(&keypad->work.work); + flush_delayed_work(&keypad->work); /* * matrix_keypad_scan() will leave IRQs enabled; * we should disable them now. -- 2.19.1