Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp471428iob; Tue, 3 May 2022 02:39:33 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzbqlkw16Rd1fIyVjKoGqaH8xNwMBptGAoawxKK69H5743TPzTqvtdqWr6tDGjPR4qFPD7k X-Received: by 2002:a17:902:f54e:b0:15e:9158:1237 with SMTP id h14-20020a170902f54e00b0015e91581237mr13329916plf.37.1651570773129; Tue, 03 May 2022 02:39:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1651570773; cv=none; d=google.com; s=arc-20160816; b=GUNoBD4w7ORq+L7l+Ew5b8uKXtvvyDv80YwGN6c3K1nfb5VxtrXq2Mt+uf34m1qVxj BoBKHV9w+i4yhI9Sw7D12AVD5pb77w+t/b212A7nQdOJmr9AYPBYOFFH6U3IY7S/Amp1 vXCPxlhsPiYcooy1/FyxEcDll/1j0BrsfLy05Wdpt/RCQ/lZ/Z75Pf8k548N3/KuptAJ WBGxsWbLBcp+EHpUGi9rBKTBbfLWSQ9hoNjAlsA33GQtwfcZa+w+0IGabLJz188IR2aI 2VQaGcpN0+UfUTftryieIBkf4Qc4e6akdzNYDZ+VdHUp1hAo0vr3XysT8EGooaFlXRZv xXYA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=75covTs22g2FzCwofQya71ubQ8oNGluD1Yj2cDPaqIE=; b=gaHoH0fJPXAEoRRDPitl0vWPKwxw5HoRUPle06mv7enVKvoBmXPHquFj8DpzNk0Mzw Qv0tC51aWCpOZqT+XV+BY9ySx/RL78IfTTvEopv1Xsl+rnMFaRBbhdgaIn9JZLj2h+8F jGiohr0n8hPzmxw2Rn6j3zh4IqYEewW3BbODgATR1z1cm0OcF41LhGGtUQae65SRsezq VFGzBco3XdQ9S6P+CN2ocKy4YqDOAOGSdI/IAZDG3zixGGtTFfkZYojZN+di5YXSWQI2 Y9bjMmCBM3WR8kPUYyqmF65Ykxvi8yKFkSxyCvfjNCw0tsUpMgnhfa24miyrZkmCjYpK Mfpw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g10-20020a63520a000000b003c25e0e0540si3229263pgb.233.2022.05.03.02.39.18; Tue, 03 May 2022 02:39:33 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232478AbiECH5D (ORCPT + 99 others); Tue, 3 May 2022 03:57:03 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36208 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232210AbiECH5C (ORCPT ); Tue, 3 May 2022 03:57:02 -0400 Received: from muru.com (muru.com [72.249.23.125]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 195A61EAE3; Tue, 3 May 2022 00:53:30 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by muru.com (Postfix) with ESMTPS id 8D9AC814C; Tue, 3 May 2022 07:50:13 +0000 (UTC) Date: Tue, 3 May 2022 10:53:28 +0300 From: Tony Lindgren To: Jakob Koschel Cc: Tero Kristo , Michael Turquette , Stephen Boyd , linux-omap@vger.kernel.org, linux-clk@vger.kernel.org, linux-kernel@vger.kernel.org, Mike Rapoport , Brian Johannesmeyer , Cristiano Giuffrida , "Bos, H.J." Subject: Re: [PATCH] clk: ti: clkctrl: replace usage of found with dedicated list iterator variable Message-ID: References: <20220324071019.59483-1-jakobkoschel@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220324071019.59483-1-jakobkoschel@gmail.com> X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org * Jakob Koschel [220324 09:08]: > To move the list iterator variable into the list_for_each_entry_*() > macro in the future it should be avoided to use the list iterator > variable after the loop body. > > To *never* use the list iterator variable after the loop it was > concluded to use a separate iterator variable instead of a > found boolean [1]. > > This removes the need to use a found variable and simply checking if > the variable was set, can determine if the break/goto was hit. > > Link: https://lore.kernel.org/all/CAHk-=wgRr_D8CB-D9Kg-c=EHreAsk5SqXPwr9Y7k9sA6cWXJ6w@mail.gmail.com/ Reviewed-by: Tony Lindgren Tested-by: Tony Lindgren