Received: by 10.213.65.68 with SMTP id h4csp515377imn; Fri, 16 Mar 2018 10:06:08 -0700 (PDT) X-Google-Smtp-Source: AG47ELsSU7BDjKwHsKf6xelKn984ygJaPcdPi8RFthUZ6UNpb2AMOAy+59O8I2G0OjucHmCsqn8/ X-Received: by 10.98.70.198 with SMTP id o67mr2133076pfi.173.1521219968718; Fri, 16 Mar 2018 10:06:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521219968; cv=none; d=google.com; s=arc-20160816; b=ZL/+SxVlnvmYdfrTKMbdxkSUeSV73CxOn3Gv6n8lX5XO94t+ToCUlUgDe6K5xa0S6o txDjjocZ+/8CzC9ttXFlUFvdOMnIp1zBoY/LBPV9kiw3UPOC8SzXN3TGXiAQSF1v9ROC 4QOPexTb/n6iWDMLCk55QLDQHAJMF0DxLawHYuF139Z8cYTkzRqmNIQtmvajr98Idhgl K4drpHRToITF5A+1pvFfk64IArXfEYoeZhHc2dBstF4Ny14wsHbU8ubP/HZDxQTu2I42 dGlzysxhwMH0d2//Yy8+fMoRll/Hr6iU4JnaCW2sDBEeX9YGKmdlvOyYBFOsXSoC+WCG IrdQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=M0Z6M4mnyEYvsj9fJElnO3dRTFFdQOqmcnpLbl8G4hs=; b=ai7ZU/EsEmFq2Ge7d0+4UvIkzWm6Uf0X8krFdQ2N8Wwyp4Q1JCLiUIKkU/z9n/YZqL cKM6c1kQQhPNfIbNpGg6FGMJyHdMH5MJrq4LzdJYrc2qELz6I2mDXc9Ay0P22VCuQ/cb t6cIpZFZHnlNWLuyDYQQggBDSTt+Dpr6ZopGrKwyPKAU3oZV8iegFSVS/wvYAVut7u+K Zpii86pJiEvixLno1eLhQuAh/ZnQJvxSaOlAeo4TFDooKcqzxos5Mwg/T2550odTU/Pe T6onk7/Nl1pf6T0pbb9ALbFsD/T4PxpxErZOvlEshSZUiJpQ5yz7zmoE0KlphsiAcErP lVSg== 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 d8-v6si3387326pli.332.2018.03.16.10.05.53; Fri, 16 Mar 2018 10:06:08 -0700 (PDT) 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 S933475AbeCPPcH (ORCPT + 99 others); Fri, 16 Mar 2018 11:32:07 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:37768 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932303AbeCPPb7 (ORCPT ); Fri, 16 Mar 2018 11:31:59 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 0791611B0; Fri, 16 Mar 2018 15:31:58 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Hans Verkuil , Mauro Carvalho Chehab , Philipp Zabel , Arnd Bergmann , Hans Verkuil , Ben Hutchings Subject: [PATCH 4.9 53/86] [media] tc358743: fix register i2c_rd/wr function fix Date: Fri, 16 Mar 2018 16:23:16 +0100 Message-Id: <20180316152320.963513071@linuxfoundation.org> X-Mailer: git-send-email 2.16.2 In-Reply-To: <20180316152317.167709497@linuxfoundation.org> References: <20180316152317.167709497@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.9-stable review patch. If anyone has any objections, please let me know. ------------------ From: Philipp Zabel commit f2c61f98e0b5f8b53b8fb860e5dcdd661bde7d0b upstream. The below mentioned fix contains a small but severe bug, fix it to make the driver work again. Fixes: 3538aa6ecfb2 ("[media] tc358743: fix register i2c_rd/wr functions") Cc: Hans Verkuil Cc: Mauro Carvalho Chehab Signed-off-by: Philipp Zabel Acked-by: Arnd Bergmann Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab Cc: Ben Hutchings Signed-off-by: Greg Kroah-Hartman --- drivers/media/i2c/tc358743.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/media/i2c/tc358743.c +++ b/drivers/media/i2c/tc358743.c @@ -222,7 +222,7 @@ static void i2c_wr8(struct v4l2_subdev * static void i2c_wr8_and_or(struct v4l2_subdev *sd, u16 reg, u8 mask, u8 val) { - i2c_wrreg(sd, reg, (i2c_rdreg(sd, reg, 2) & mask) | val, 2); + i2c_wrreg(sd, reg, (i2c_rdreg(sd, reg, 1) & mask) | val, 1); } static u16 i2c_rd16(struct v4l2_subdev *sd, u16 reg)