From patchwork Mon Mar 14 22:40:08 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 8584081 Return-Path: X-Original-To: patchwork-linux-media@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id BC03DC0553 for ; Mon, 14 Mar 2016 22:41:46 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id F194720375 for ; Mon, 14 Mar 2016 22:41:45 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 1220E2034B for ; Mon, 14 Mar 2016 22:41:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753962AbcCNWlM (ORCPT ); Mon, 14 Mar 2016 18:41:12 -0400 Received: from mout.kundenserver.de ([217.72.192.74]:55729 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752005AbcCNWlK (ORCPT ); Mon, 14 Mar 2016 18:41:10 -0400 Received: from wuerfel.lan. ([78.42.132.4]) by mrelayeu.kundenserver.de (mreue102) with ESMTPA (Nemesis) id 0LZvn3-1ZyVyb3R1R-00lmE2; Mon, 14 Mar 2016 23:40:52 +0100 From: Arnd Bergmann To: "Lad, Prabhakar" , Mauro Carvalho Chehab Cc: Arnd Bergmann , Hans Verkuil , Seung-Woo Kim , Benoit Parrot , Junghak Sung , linux-media@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/3] [media] am437x-vfpe: fix typo in vpfe_get_app_input_index Date: Mon, 14 Mar 2016 23:40:08 +0100 Message-Id: <1457995225-1199991-2-git-send-email-arnd@arndb.de> X-Mailer: git-send-email 2.7.0 In-Reply-To: <1457995225-1199991-1-git-send-email-arnd@arndb.de> References: <1457995225-1199991-1-git-send-email-arnd@arndb.de> X-Provags-ID: V03:K0:E89C6tdF7V0VLPB9ZIfUhCHYD/RFUixXPfESF7aWCz7XBXJUV9Q /dr36Yuj49jKQzOCiUWWc7RqZSZoSZO0en9I8gzJQlvmtsFE3/kmKIx4wyoSOuI5AVMK760 /v7UB/C/Qy2shrd0WvBK4TL2dO3vDiaIUenID2uXfM4BWM01AmIBz9VGAv3PVCTwjaMoYSu 51aW4dP6eW/Y4IQZO40dw== X-UI-Out-Filterresults: notjunk:1; V01:K0:3Dvzz97BDFE=:yMjEGrsDrPljk7TrhnNPXd Sm5PjKgP7nWYhu20Z3ozIiGftE5ltyd+zRML4wg/5V1J31iVG3phgA+z+UEVUtydrg8xc+svs Vr1Wood3A88WAHIBY8kxQ0J7JbDYK9VAizr9jcDxYazKdH1pojZLdKnmjua5792C9x06GrK5N 4NP0dQ0CwBCy7Dz/UeoIrlqA8kr6usVCDG8oINB+zzcDml1GkocbkHQ+B5O0iRmwEZuDnJ/aX ljI9DKsiJ38VfLDxRh2UGqtc6Dnf6JvE7CuiSMPiC7GntjT2kqPUqcG4q22epEJpQaNJlmu5A g/UM2D5r5UpzvWYX1JIJs9pxlRAYoXoZfYJ85mcrFcETDXpapPzCztY3o90qCM5nPWOiv+dMZ YINTya3/vfOtmFAjlKontEioWuMf/rSdTLMv2rEPndRDBWMWWlOW73MucNOZ24n6fkHGaR+h1 VALQdlhjuYtSvF8nJpPka9a52OwoxAEueXGKnOuX3tC18CbnsKKS7bLJYy0b6mi29nzt/aB2k CGHuevMaNmby6amkhoK5XowJHYdyMd3CeWIbyMZEB2RQz2IRYijlxqMqX6Rjsi+r2WPG79mVp Kknr1SPW1rYa6MarECCWBli/0x3uOO6mUcflZW0nE3rMcWfheqyyqokDSyePXQRQxkZEvbtq9 Rj7fLVAJD8ZxZM7PBQpJnh+qnToB4NCEu+tTZzQlNacx+f6M8fxWdQnMdZrY2/ROzDac= Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP gcc-6 points out an obviously silly comparison in vpfe_get_app_input_index(): drivers/media/platform/am437x/am437x-vpfe.c: In function 'vpfe_get_app_input_index': drivers/media/platform/am437x/am437x-vpfe.c:1709:27: warning: self-comparison always evaluats to true [-Wtautological-compare] client->adapter->nr == client->adapter->nr) { ^~ This was introduced in a slighly incorrect conversion, and it's clear that the comparison was meant to compare the iterator to the current subdev instead, as we do in the line above. Signed-off-by: Arnd Bergmann Fixes: d37232390fd4 ("[media] media: am437x-vpfe: match the OF node/i2c addr instead of name") Acked-by: Lad, Prabhakar --- drivers/media/platform/am437x/am437x-vpfe.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/platform/am437x/am437x-vpfe.c b/drivers/media/platform/am437x/am437x-vpfe.c index de32e3a3d4d1..e6a7bff4650c 100644 --- a/drivers/media/platform/am437x/am437x-vpfe.c +++ b/drivers/media/platform/am437x/am437x-vpfe.c @@ -1706,7 +1706,7 @@ static int vpfe_get_app_input_index(struct vpfe_device *vpfe, sdinfo = &cfg->sub_devs[i]; client = v4l2_get_subdevdata(sdinfo->sd); if (client->addr == curr_client->addr && - client->adapter->nr == client->adapter->nr) { + client->adapter->nr == curr_client->adapter->nr) { if (vpfe->current_input >= 1) return -1; *app_input_index = j + vpfe->current_input;