Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp3557322pxb; Mon, 1 Mar 2021 13:16:24 -0800 (PST) X-Google-Smtp-Source: ABdhPJzdWsgEays7IYuX3R2zQ3EpF3WGt6FiPqyx7umL4iULF89VV8V58Bk43gYYcnH5CHcxUz9n X-Received: by 2002:a17:906:3603:: with SMTP id q3mr16804434ejb.201.1614633383768; Mon, 01 Mar 2021 13:16:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614633383; cv=none; d=google.com; s=arc-20160816; b=oTnnskZdRma+nIMiYPspsDSCGAAatKK22CHkB/MGw+lFMuWgrn+bMgsirP6E7Lc9MF UCO5n9f2up/CSLjHdVsgeFhrClTkttHzXNo3OM3y9VO9Itg615SAOsBAl/dqriJlzab2 9vbJj3Mb+4rG5tdv/Tn5l+qFhWaXIOJ4ieD8BhOBiy7bwLB4qrYMgd1ppd+ewKo7NWZh 3Mw0gr/M+38PuJ4lgz69MvADhxd34F9fRlTgnoSoPk0yQJfi8cvDXH0ucBeDzxsE9jcB EQ6e7ZB2hFstU+hgpWwr1yk0cQ+123+YpxhDsrXclHMFBGgFas3qC9HHQp98faXrYMgp R0vg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=M8s3QcFSFdEhf1BsjJQxP6lMB8isDhoW3XEZpGedAyw=; b=SoXFhYmVtIR4GAhsAXpyMtcCEjC9wlCXGDXy6LxZbVIFvlEJD9RQNffZQOBdIFHQHy 3gPgcwLE+Zl7vPfWeBFHUIl16GrXIpeep7JesrpSiYoYNdMM0fQYkkYCPpoDG369fQ1i Yl0aPK6xcB+nLtBsPZq8kNE2AD7AAh68ujNBrrhVKzUEZn9QqxvmQJXw/nv/BgcFIn5w fk74sJj+Xms9aw8osrtcbyrDLnU6y9l8FmJlRrvgbPWQ19ZXf1EMhXMQ/5NUDy9Dp2a5 oSWtW6dQILQfSza+E2XkihL3Xs5Gsv2lDSU/0JqL+qsGEaGYIsCpYNInv6Cvm1r0RC1a PqWg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=wCF4zSPi; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c12si13154472eja.386.2021.03.01.13.16.00; Mon, 01 Mar 2021 13:16:23 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=wCF4zSPi; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237782AbhCAVMH (ORCPT + 99 others); Mon, 1 Mar 2021 16:12:07 -0500 Received: from mail.kernel.org ([198.145.29.99]:52722 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237876AbhCARNl (ORCPT ); Mon, 1 Mar 2021 12:13:41 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id D441164EE9; Mon, 1 Mar 2021 16:44:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1614617043; bh=cG00EA4GqSE9VrsMiGmD1BFl2y/v11PU4dDaZHNRsrk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=wCF4zSPinLYM1yDw/Z05hzojs8As56iac8v2j+BfXwbMbl8eTXlG62OIrNkaCjU5X LHNvSDHF9x637mR5ft4z6ED5k1hs+BG6UnGG+8r0CNMrbwYfiXWa9LtYR3qW2bQ6RG wUCEQeEuij4Ha39MmovH49m/tS44aHxxPIoUxmG8= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, "jeffrey.lin" , Dmitry Torokhov Subject: [PATCH 4.19 182/247] Input: raydium_ts_i2c - do not send zero length Date: Mon, 1 Mar 2021 17:13:22 +0100 Message-Id: <20210301161040.568707268@linuxfoundation.org> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210301161031.684018251@linuxfoundation.org> References: <20210301161031.684018251@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: jeffrey.lin commit fafd320ae51b9c72d371585b2501f86640ea7b7d upstream. Add default write command package to prevent i2c quirk error of zero data length as Raydium touch firmware update is executed. Signed-off-by: jeffrey.lin Link: https://lore.kernel.org/r/1608031217-7247-1-git-send-email-jeffrey.lin@raydium.corp-partner.google.com Cc: stable@vger.kernel.org Signed-off-by: Dmitry Torokhov Signed-off-by: Greg Kroah-Hartman --- drivers/input/touchscreen/raydium_i2c_ts.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) --- a/drivers/input/touchscreen/raydium_i2c_ts.c +++ b/drivers/input/touchscreen/raydium_i2c_ts.c @@ -419,6 +419,7 @@ static int raydium_i2c_write_object(stru enum raydium_bl_ack state) { int error; + static const u8 cmd[] = { 0xFF, 0x39 }; error = raydium_i2c_send(client, RM_CMD_BOOT_WRT, data, len); if (error) { @@ -427,7 +428,7 @@ static int raydium_i2c_write_object(stru return error; } - error = raydium_i2c_send(client, RM_CMD_BOOT_ACK, NULL, 0); + error = raydium_i2c_send(client, RM_CMD_BOOT_ACK, cmd, sizeof(cmd)); if (error) { dev_err(&client->dev, "Ack obj command failed: %d\n", error); return error;