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=-3.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no 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 15D95C433DF for ; Mon, 17 Aug 2020 11:47:22 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id E085D20674 for ; Mon, 17 Aug 2020 11:47:21 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726585AbgHQLrV (ORCPT ); Mon, 17 Aug 2020 07:47:21 -0400 Received: from mga02.intel.com ([134.134.136.20]:57566 "EHLO mga02.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726161AbgHQLrU (ORCPT ); Mon, 17 Aug 2020 07:47:20 -0400 IronPort-SDR: 3WvTqaIfyVMOQcJm30aFGL4/hQloxYBvtYBN5ccUeeML1/vNGTYvLwR+WBK9HUO1Ag3OeQN/F2 2eEthrldu/VQ== X-IronPort-AV: E=McAfee;i="6000,8403,9715"; a="142510781" X-IronPort-AV: E=Sophos;i="5.76,322,1592895600"; d="scan'208";a="142510781" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga008.jf.intel.com ([10.7.209.65]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 17 Aug 2020 04:47:20 -0700 IronPort-SDR: mqbVvajN8UFRLi4aFrIck/QqHRB+zYtCr8VCb3Vc+TLXrs4Lh6tZugYiZtrAOJomTLAEro/voT CxCC6z6q9yAg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.76,322,1592895600"; d="scan'208";a="326385713" Received: from smile.fi.intel.com (HELO smile) ([10.237.68.40]) by orsmga008.jf.intel.com with ESMTP; 17 Aug 2020 04:47:18 -0700 Received: from andy by smile with local (Exim 4.94) (envelope-from ) id 1k7dbh-009Iz4-3b; Mon, 17 Aug 2020 14:47:17 +0300 Date: Mon, 17 Aug 2020 14:47:17 +0300 From: Andy Shevchenko To: Bingbu Cao Cc: Yong Zhi , Sakari Ailus , Bingbu Cao , Tian Shu Qiu , linux-media@vger.kernel.org, Mauro Carvalho Chehab Subject: Re: [PATCH v1 5/7] media: ipu3-cio2: Replace infinite loop by one with clear exit condition Message-ID: <20200817114717.GM1891694@smile.fi.intel.com> References: <20200814163017.35001-1-andriy.shevchenko@linux.intel.com> <20200814163017.35001-5-andriy.shevchenko@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org On Mon, Aug 17, 2020 at 06:21:23PM +0800, Bingbu Cao wrote: > On 8/15/20 12:30 AM, Andy Shevchenko wrote: > > Refactor cio2_buffer_done() to get rid of infinite loop by replacing it by one > > with clear exit condition. This change also allows to check for an error ahead. ... > > - int buffers_found = 0; > > + struct cio2_fbpt_entry *const entry; > No 'const' here. Sure, will not be in v2. -- With Best Regards, Andy Shevchenko