Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp4315612ybc; Fri, 22 Nov 2019 00:29:02 -0800 (PST) X-Google-Smtp-Source: APXvYqx3bQbJtanTPKnaWVeprYm91j01s9thMJxapUz3lVuhycsEWEz5baRsHIfiRfazg3mhMUFy X-Received: by 2002:a17:906:32d0:: with SMTP id k16mr19871278ejk.155.1574411342287; Fri, 22 Nov 2019 00:29:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574411342; cv=none; d=google.com; s=arc-20160816; b=EvhU7onKrzx9eCfw8V4KBYgZrm2wf4nNjpB7s6w0xcn8AMQRmtz5cAXQkjGP+c/F/X +v3boY4vjYUzISh02VvN1By3Z4KZVT5V0wKkQit6YN99AqbLUytrpxgjcR7OfVz9Q/XO xrxG0FoXtCQ28waR2b3K5MnjOW2N+2NWLnY1jlTWNRerelcooSBvUL/nc3qd9qB8bYob mucPYRFiUHv2xkjLPQegBLMDX5Nf5LA+yXcMUXkoNFUZYVPUm2ncYB9g6v9v7xZm1+tC FsIcCd+VEWCqBE7zDXxOZ+Fg2a48Bi94vOqyh5J7eaAUTG6J9nr5ySfC/d5mVW65ACo9 rNUA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:ironport-sdr:ironport-sdr; bh=D1qlhS/YfCC0HdrrV6cfa6oSX7iCpbZ0Pdouk7wwmsk=; b=Q3AeoYoZ0+lNLQIXU5iRp/++PnhikxtBU6K7Wk7l6XrWDHtfmDLHTtVlYILMRqJ+t8 zXPXEbSTRatgrdRqkPYvQKfeiNX67D7o0UxlgyCzjmLLB09hDxVIxhYhgcEkAmOPl0qu styS+xkF9w5TAWOw0D92A5a1O/nujgLEm3J/+H/ApcPgRf9bVCjwnDllNmRPvR1J6FSJ WiDFOr+AEFxBtg8qmcbzV76Sm0cfL+Crq80CkBTuzUxnsgQZjQpNMWbnfhSWiUg5Q8ef Iy20apZAA+ZPSVGsVtdDZ/yyPXqp196895V7GjPKmjf4cpHxKzoXEP9l4Pivx79zzwWh Nq2Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j23si3664828eja.393.2019.11.22.00.28.39; Fri, 22 Nov 2019 00:29:02 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727200AbfKVI01 (ORCPT + 99 others); Fri, 22 Nov 2019 03:26:27 -0500 Received: from esa2.mentor.iphmx.com ([68.232.141.98]:52542 "EHLO esa2.mentor.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726554AbfKVI0Y (ORCPT ); Fri, 22 Nov 2019 03:26:24 -0500 IronPort-SDR: MgzCr4Y+OvHazrB/sbK1R4XFjM4vAxEqIeD6x/PxzBfxQDdk5I7CC/2rtz2RVeGl/8KBEpiCwR e5gibqYXfM5V+XsFkMueOxHufOKEkA5gfvy2hRHCBanYDv1sCO/xIsF0JVW/x2kSTErD+xJ/Ew Qx2irjbO2d/UlcUGDpK0vXJNNh8IdtiflJK2WsmB+H/nKcGTFY1hJnKYtEFcywoIlmC9wda2VI gP+GRrFxTFBvixXaSqAk2UE/79+q5/ExcI9B1uh3T3g3KEpN0lAOhKbspyzoe237N3ASeb+L2p tns= X-IronPort-AV: E=Sophos;i="5.69,229,1571731200"; d="scan'208";a="43358973" Received: from orw-gwy-01-in.mentorg.com ([192.94.38.165]) by esa2.mentor.iphmx.com with ESMTP; 22 Nov 2019 00:26:23 -0800 IronPort-SDR: NovqKH9ZCndvBlGwCA9ax4Neqe1mUqUpc86PgIE1FKWkb8HZnY767l8N0IHX9ykyAs/Dc7UVl0 5R7X+jM/N9AuryY+DcWypzhNFN2Tw4Q1ZjZsjedC4ofnPKKXb5kFd3dE7ygT05jqajyRWmksjI jc5EOnnzYS4uBH/eQ6jn47+YMWbEGja9KG3KPvUx413xb6lExUv5FIGebEIBLKCvZ7L65Fon3c 6LVVI9mFmxxXxkHoYcMj5ieI0Jk4BoByQIhWEuS3qu0LMYegj9iy87amr5UR0g6LqdvxB1bUG5 MUs= From: Jiada Wang To: , , , , CC: , , , , Subject: [PATCH v6 37/48] Input: atmel_mxt_ts: return error from mxt_process_messages_until_invalid() Date: Fri, 22 Nov 2019 17:23:51 +0900 Message-ID: <20191122082402.18173-38-jiada_wang@mentor.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20191122082402.18173-1-jiada_wang@mentor.com> References: <20191122082402.18173-1-jiada_wang@mentor.com> MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Dean Jenkins mxt_process_messages_until_invalid() failed to propagate the error code from mxt_read_and_process_messages() so return the error code. Signed-off-by: Dean Jenkins Signed-off-by: Deepak Das Signed-off-by: George G. Davis Signed-off-by: Jiada Wang --- drivers/input/touchscreen/atmel_mxt_ts.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/input/touchscreen/atmel_mxt_ts.c b/drivers/input/touchscreen/atmel_mxt_ts.c index 054aacc768b8..a5af1f91d704 100644 --- a/drivers/input/touchscreen/atmel_mxt_ts.c +++ b/drivers/input/touchscreen/atmel_mxt_ts.c @@ -1564,6 +1564,8 @@ static int mxt_process_messages_until_invalid(struct mxt_data *data) /* Read messages until we force an invalid */ do { read = mxt_read_and_process_messages(data, count); + if (read < 0) + return read; if (read < count) return 0; } while (--tries); -- 2.17.1