From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 108416D28 for ; Wed, 14 Apr 2021 14:39:22 +0000 (UTC) IronPort-HdrOrdr: =?us-ascii?q?A9a23=3AKyHtCaqWOi4LOXVnh17Oa/waV5rKeYIsi2QD?= =?us-ascii?q?101hICF9WMqeisyogbAnxQb54QxhPE0ItNicNMC7Kk/02oVy5eAqV4uKfA6jg2?= =?us-ascii?q?ewKZEn0I2K+VzdMgnf0sIY6qt6aah5D7TLfD1HpOL3+hOxHdpl4PTvysCVrNzT?= =?us-ascii?q?xXtsUg1mApsIhztRMQqVHlZ7QwNLH/MCZfmhz/BarDmtc2l/VKqGL0QCNtKum/?= =?us-ascii?q?T2jp78JTYJCxk7gTP+7w+A2frKVyKV2RoTSFp0rIsK+2KtqWPE2pk=3D?= X-IronPort-AV: E=Sophos;i="5.82,222,1613430000"; d="scan'208";a="378655164" Received: from 173.121.68.85.rev.sfr.net (HELO hadrien) ([85.68.121.173]) by mail3-relais-sop.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 14 Apr 2021 16:39:20 +0200 Date: Wed, 14 Apr 2021 16:39:20 +0200 (CEST) From: Julia Lawall X-X-Sender: jll@hadrien To: Dan Carpenter cc: Aline Santana Cordeiro , Mauro Carvalho Chehab , Sakari Ailus , Greg Kroah-Hartman , linux-media@vger.kernel.org, linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, outreachy-kernel@googlegroups.com Subject: Re: [Outreachy kernel] Re: [PATCH 1/2] staging: media: atomisp: pci: Correct identation in block of conditional statements in file atomisp_v4l2.c In-Reply-To: <20210414143011.GV6021@kadam> Message-ID: References: <0ef18a36d6905628fa596fd5e0a32fdb9c6a8ada.1618409028.git.alinesantanacordeiro@gmail.com> <20210414143011.GV6021@kadam> User-Agent: Alpine 2.22 (DEB 394 2020-01-19) X-Mailing-List: linux-staging@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII On Wed, 14 Apr 2021, Dan Carpenter wrote: > On Wed, Apr 14, 2021 at 11:06:02AM -0300, Aline Santana Cordeiro wrote: > > Correct identation in block of conditional statements. > > The function "v4l2_device_unregister_subdev()" depends on > > the results of the macro function "list_for_each_entry_safe()". > > > > Signed-off-by: Aline Santana Cordeiro > > --- > > drivers/staging/media/atomisp/pci/atomisp_v4l2.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/drivers/staging/media/atomisp/pci/atomisp_v4l2.c b/drivers/staging/media/atomisp/pci/atomisp_v4l2.c > > index 0295e2e..6d853f4 100644 > > --- a/drivers/staging/media/atomisp/pci/atomisp_v4l2.c > > +++ b/drivers/staging/media/atomisp/pci/atomisp_v4l2.c > > @@ -1178,7 +1178,7 @@ static void atomisp_unregister_entities(struct atomisp_device *isp) > > atomisp_mipi_csi2_unregister_entities(&isp->csi2_port[i]); > > > > list_for_each_entry_safe(sd, next, &isp->v4l2_dev.subdevs, list) > > - v4l2_device_unregister_subdev(sd); > > + v4l2_device_unregister_subdev(sd); > > > > It's really more common to use curly braces for list_for_each() one > liners. > > list_for_each_entry_safe(sd, next, &isp->v4l2_dev.subdevs, list) { > v4l2_device_unregister_subdev(sd); > } A quick test with grep shows 4000 lines containing list_for_each that contain no {, out of 15000 lines containing list_for_each in all. julia > > regards, > dan carpenter > > -- > You received this message because you are subscribed to the Google Groups "outreachy-kernel" group. > To unsubscribe from this group and stop receiving emails from it, send an email to outreachy-kernel+unsubscribe@googlegroups.com. > To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/20210414143011.GV6021%40kadam. >