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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 92AB8C433FE for ; Tue, 1 Mar 2022 23:11:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238588AbiCAXMc (ORCPT ); Tue, 1 Mar 2022 18:12:32 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36718 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238502AbiCAXMb (ORCPT ); Tue, 1 Mar 2022 18:12:31 -0500 Received: from mail-ed1-x52c.google.com (mail-ed1-x52c.google.com [IPv6:2a00:1450:4864:20::52c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5972C79397 for ; Tue, 1 Mar 2022 15:11:46 -0800 (PST) Received: by mail-ed1-x52c.google.com with SMTP id w3so23991981edu.8 for ; Tue, 01 Mar 2022 15:11:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=ojIOUCrgcIak8ZCc1skMdXRKcTVmt9Elm/o+1+I6jGA=; b=fmg4LXx5HRB2mrrWsHndl76rC2chdk1sBRQyNWtz+o2V+K2vg9psF6vr/ppax24roG 0IEY6nkgVM6qwn95jhK4YeupoNeTj8/flkbxBQUDmf863ReCVguQlY3gsMWixLyIz8Mx ewpCP9yjbapnom8xtoCAmNy70uRnweYHKzlsw= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=ojIOUCrgcIak8ZCc1skMdXRKcTVmt9Elm/o+1+I6jGA=; b=kkz6lzGM+7QlVI3Ijk2/V6zMp8Xl7nBDUBIlwvL+aCZw9j3KiT19U8vVR2H8whqQtm u0iy0ez7WMGPeHUIxlQ0uSS+yg5ysmW8oGhTX13Zx0hDkBGtNotNXKUx0IeK4fkUBfH8 dww5zBkUuS+wC9/OFRUVmN7iMS2LvI0vawlsRfbpecfqkPtx/etNEvQAdw2oO8a4esEN sFGpN6glDJcgyj/Ue4vIlD+ETIA0UdJh4Zn5XHqqzd0jW1W1tx+KZF38rWuMXNrvzFBu NFcNYjxBJBnUPTUm7vOjGc2jXTmLjCOfdOAEveK63UfG8Va2jMM236Hl/0Qui4tZRxSp fgQA== X-Gm-Message-State: AOAM532Q8cylefoJGaYXsyptV7nz2ULlAqPC2rVGJ1x763348qrAXUMI yp9flQYpaWzOVCElH3MpBA+x0XWwbTgF58CvA1Q= X-Google-Smtp-Source: ABdhPJxafPGlM1BpaZIGSajUXTJzN8ETyuMbKexudk3aV8VNPJn+C+YsptUgpFVrhIyX0H0j4DEGlA== X-Received: by 2002:a05:6402:4491:b0:413:162a:fc85 with SMTP id er17-20020a056402449100b00413162afc85mr26834389edb.115.1646176304739; Tue, 01 Mar 2022 15:11:44 -0800 (PST) Received: from mail-ej1-f41.google.com (mail-ej1-f41.google.com. [209.85.218.41]) by smtp.gmail.com with ESMTPSA id kw3-20020a170907770300b006d2a835ac33sm5744963ejc.197.2022.03.01.15.11.44 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 01 Mar 2022 15:11:44 -0800 (PST) Received: by mail-ej1-f41.google.com with SMTP id gb39so98841ejc.1 for ; Tue, 01 Mar 2022 15:11:44 -0800 (PST) X-Received: by 2002:a2e:924d:0:b0:246:370c:5618 with SMTP id v13-20020a2e924d000000b00246370c5618mr18436468ljg.358.1646175815802; Tue, 01 Mar 2022 15:03:35 -0800 (PST) MIME-Version: 1.0 References: <20220228110822.491923-1-jakobkoschel@gmail.com> <20220228110822.491923-3-jakobkoschel@gmail.com> <2e4e95d6-f6c9-a188-e1cd-b1eae465562a@amd.com> <282f0f8d-f491-26fc-6ae0-604b367a5a1a@amd.com> <7D0C2A5D-500E-4F38-AD0C-A76E132A390E@kernel.org> <73fa82a20910c06784be2352a655acc59e9942ea.camel@HansenPartnership.com> <7dc860874d434d2288f36730d8ea3312@AcuMS.aculab.com> In-Reply-To: <7dc860874d434d2288f36730d8ea3312@AcuMS.aculab.com> From: Linus Torvalds Date: Tue, 1 Mar 2022 15:03:19 -0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr To: David Laight Cc: James Bottomley , linux-wireless , "alsa-devel@alsa-project.org" , KVM list , "Gustavo A. R. Silva" , "linux-iio@vger.kernel.org" , "nouveau@lists.freedesktop.org" , Rasmus Villemoes , dri-devel , Cristiano Giuffrida , "Bos, H.J." , "linux1394-devel@lists.sourceforge.net" , "drbd-dev@lists.linbit.com" , linux-arch , CIFS , "linux-aspeed@lists.ozlabs.org" , linux-scsi , linux-rdma , "linux-staging@lists.linux.dev" , amd-gfx list , Jason Gunthorpe , "intel-wired-lan@lists.osuosl.org" , "kgdb-bugreport@lists.sourceforge.net" , "bcm-kernel-feedback-list@broadcom.com" , Dan Carpenter , Linux Media Mailing List , Kees Cook , Arnd Bergman , Linux PM , intel-gfx , Brian Johannesmeyer , Nathan Chancellor , dma , Christophe JAILLET , Jakob Koschel , "v9fs-developer@lists.sourceforge.net" , linux-tegra , Thomas Gleixner , Andy Shevchenko , Linux ARM , "linux-sgx@vger.kernel.org" , linux-block , Netdev , "linux-usb@vger.kernel.org" , "samba-technical@lists.samba.org" , Linux Kernel Mailing List , Linux F2FS Dev Mailing List , "tipc-discussion@lists.sourceforge.net" , Linux Crypto Mailing List , linux-fsdevel , "linux-mediatek@lists.infradead.org" , Andrew Morton , linuxppc-dev , =?UTF-8?Q?Christian_K=C3=B6nig?= , Mike Rapoport Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org On Tue, Mar 1, 2022 at 2:58 PM David Laight wrote: > > Can it be resolved by making: > #define list_entry_is_head(pos, head, member) ((pos) == NULL) > and double-checking that it isn't used anywhere else (except in > the list macros themselves). Well, yes, except for the fact that then the name is entirely misleading... And somebody possibly uses it together with list_first_entry() etc, so it really is completely broken to mix that change with the list traversal change. Linus Linus