From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1759539AbdJQSxy (ORCPT ); Tue, 17 Oct 2017 14:53:54 -0400 Received: from mail-pf0-f196.google.com ([209.85.192.196]:56492 "EHLO mail-pf0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757554AbdJQSxw (ORCPT ); Tue, 17 Oct 2017 14:53:52 -0400 X-Google-Smtp-Source: AOwi7QBO79ZKzi+tWsmwjvMXzad4HxeI3iHifuyocYvuVxe/eu2JQLCBfzPrShh7Td+RyUpeP399tQ== Subject: Re: [PATCH v2 03/12] of: overlay: rename identifiers to more reflect what they do To: Rob Herring References: <1508203074-26917-1-git-send-email-frowand.list@gmail.com> <1508203074-26917-4-git-send-email-frowand.list@gmail.com> Cc: Pantelis Antoniou , David Airlie , Jyri Sarha , "devicetree@vger.kernel.org" , "linux-kernel@vger.kernel.org" , Mark Rutland , Tomi Valkeinen , dri-devel From: Frank Rowand Message-ID: <59E651BC.6030802@gmail.com> Date: Tue, 17 Oct 2017 11:53:48 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.4.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 10/17/17 07:38, Rob Herring wrote: > On Mon, Oct 16, 2017 at 8:17 PM, wrote: >> From: Frank Rowand >> >> This patch is aimed primarily at drivers/of/overlay.c, but those >> changes also have a small impact in a few other files. >> >> overlay.c is difficult to read and maintain. Improve readability: >> - Rename functions, types and variables to better reflect what >> they do and to be consistent with names in other places, >> such as the device tree overlay FDT (flattened device tree), >> and make the algorithms more clear >> - Use the same names consistently throughout the file >> - Update comments for name changes >> - Fix incorrect comments >> >> This patch is intended to not introduce any functional change. >> >> Signed-off-by: Frank Rowand >> --- >> Documentation/devicetree/overlay-notes.txt | 12 +- >> drivers/gpu/drm/tilcdc/tilcdc_slave_compat.c | 5 +- >> drivers/of/dynamic.c | 2 +- >> drivers/of/overlay.c | 506 ++++++++++++++------------- >> drivers/of/unittest.c | 20 +- >> include/linux/of.h | 12 +- >> 6 files changed, 294 insertions(+), 263 deletions(-) > > Doesn't build: > > ../drivers/of/overlay.c:397:41: warning: ‘struct of_overlay_info’ > declared inside parameter list will not be visible outside of this > definition or declaration > struct device_node *info_node, struct of_overlay_info *ovinfo) > ^~~~~~~~~~~~~~~ > ../drivers/of/overlay.c:396:40: warning: ‘struct of_overlay’ declared > inside parameter list will not be visible outside of this definition > or declaration > static int of_fill_overlay_info(struct of_overlay *ov, > ^~~~~~~~~~ > ../drivers/of/overlay.c: In function ‘of_fill_overlay_info’: > ../drivers/of/overlay.c:399:8: error: dereferencing pointer to > incomplete type ‘struct of_overlay_info’ > ovinfo->overlay = of_get_child_by_name(info_node, "__overlay__"); > ^~ > ../drivers/of/overlay.c: In function ‘init_overlay_changeset’: > ../drivers/of/overlay.c:450:30: error: passing argument 1 of > ‘of_fill_overlay_info’ from incompatible pointer type > [-Werror=incompatible-pointer-types] > ret = of_fill_overlay_info(ovcs, node, &fragments[cnt]); > ^~~~ > ../drivers/of/overlay.c:396:12: note: expected ‘struct of_overlay *’ > but argument is of type ‘struct overlay_changeset *’ > static int of_fill_overlay_info(struct of_overlay *ov, > ^~~~~~~~~~~~~~~~~~~~ > ../drivers/of/overlay.c:450:42: error: passing argument 3 of > ‘of_fill_overlay_info’ from incompatible pointer type > [-Werror=incompatible-pointer-types] > ret = of_fill_overlay_info(ovcs, node, &fragments[cnt]); > ^ > ../drivers/of/overlay.c:396:12: note: expected ‘struct of_overlay_info > *’ but argument is of type ‘struct fragment *’ > static int of_fill_overlay_info(struct of_overlay *ov, > ^~~~~~~~~~~~~~~~~~~~ > > > I could have messed something up as every commit so far conflicts with > "of: overlay: fix memory leak related to duplicated property". Can you > rebase on to my dt/next branch too. > > Rob > OK, I'll rebase. -Frank