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 mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C15ECC433EF for ; Tue, 28 Sep 2021 06:30:15 +0000 (UTC) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 672CD611BD for ; Tue, 28 Sep 2021 06:30:14 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 672CD611BD Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id ABBC980F30; Tue, 28 Sep 2021 08:30:11 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1632810612; bh=kO5mmS4lJjAf9uajyCaNkiI+dv7CwY2FQ/gsV3whkJ4=; h=Subject:To:Cc:References:From:Date:In-Reply-To:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: Reply-To:From; b=sdPXUmEGJrxKra+AMWsnKt1R5S9DPcAWmkBhBKLHyoodDFqgtLNTKkG+GWBylzIDY A9CdaCPt3q2bQCrYUBqsfwV8GBZOdDwq2JiypQuE0fL7kdW0nSZyuiKk7hphb2Yym6 LRyFUtBAJ4QVtmXv/lz8lUDqmUWT57kErBVSbT2N8bctzBlwGm8jT2Yu8cI8mwdo76 /hYXP/X4rTpc4P75g2FLsFVyRiMxprXmeK4bHkilvvjuE/tdvMHPxNY6uBE4G9oXYO EJ4oq2a0HQTDfvpNIUDiAv/vFww0TD3ghJVF078NEY1yE5RiSkAe3WcjquGMOFAUjO AV3STZHAyCLXQ== Received: from [192.168.1.107] (82-131-156-90.pool.digikabel.hu [82.131.156.90]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: hs@denx.de) by phobos.denx.de (Postfix) with ESMTPSA id 7239480C58; Tue, 28 Sep 2021 08:30:07 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1632810608; bh=kO5mmS4lJjAf9uajyCaNkiI+dv7CwY2FQ/gsV3whkJ4=; h=Subject:To:Cc:References:Reply-To:From:Date:In-Reply-To:From; b=emm1J10FJBcNEelwrkvE3W7+MQQ9yU1TOKa0b7LT5owXGWRiaGYJha4lHi8eg39yk nWc29kD7wWrSyoNxzdUUuYVqp7XUV2aL2cWoMmGLeKuWqDzN6hwRwCibgUm9QGTegf mJZ6BfyfiQydTWYIhkkB2k/PdtkPAOhHB++mKhBjUtqm3CwfiwN4VYkWQWlbURhfA5 NZob8Haa1TFzR8I/KN1Gir8BO9qWmfYkpOvDlCh0LwbXRzpb46/GoKnoDRahpQ0mLO enwSB2LlmoJCPpRj0BkapXvCH2LVjrnxBgqvjgwX1grRbY2ZfoCY+vRDfQPIuH9AR+ d5zFvtH+AWieQ== Subject: Re: [PATCH] mtd: nand: raw: convert nand_dt_init() to ofnode_xx() interface To: Patrice Chotard , u-boot@lists.denx.de Cc: Patrick DELAUNAY , U-Boot STM32 , Farhan Ali , Sean Anderson , Simon Glass References: <20210913142553.24333-1-patrice.chotard@foss.st.com> From: Heiko Schocher Message-ID: <0e5077de-9765-2bd3-1938-ae6382b06929@denx.de> Date: Tue, 28 Sep 2021 08:30:11 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1 MIME-Version: 1.0 In-Reply-To: <20210913142553.24333-1-patrice.chotard@foss.st.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: hs@denx.de Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean Hello Patrice, On 13.09.21 16:25, Patrice Chotard wrote: > nand_dt_init() is still using fdtdec_xx() interface. > If OF_LIVE flag is enabled, dt property can't be get anymore. > Updating all fdtdec_xx() interface to ofnode_xx() to solve this issue. > > For doing this, node parameter type must be ofnode. > > First idea was to convert "node" parameter to ofnode type inside > nand_dt_init() using offset_to_ofnode(node). But offset_to_ofnode() > is not bijective, in case OF_LIVE flag is enabled, it performs an assert(). > > So, this leads to update nand_chip struct flash_node field from int to > ofnode and to update all nand_dt_init() callers. > > Signed-off-by: Patrice Chotard > --- > > drivers/mtd/nand/raw/denali.c | 2 +- > drivers/mtd/nand/raw/mxs_nand.c | 2 +- > drivers/mtd/nand/raw/nand_base.c | 27 +++++++++++--------------- > drivers/mtd/nand/raw/stm32_fmc2_nand.c | 2 +- > drivers/mtd/nand/raw/sunxi_nand.c | 2 +- > include/linux/mtd/rawnand.h | 6 +++--- > 6 files changed, 18 insertions(+), 23 deletions(-) Applied to u-boot-i2c next Thanks! bye, Heiko -- DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-52 Fax: +49-8142-66989-80 Email: hs@denx.de