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 DA8B0ECAAD3 for ; Wed, 31 Aug 2022 07:07:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230416AbiHaHHl (ORCPT ); Wed, 31 Aug 2022 03:07:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48954 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230443AbiHaHHc (ORCPT ); Wed, 31 Aug 2022 03:07:32 -0400 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 67650BB01E for ; Wed, 31 Aug 2022 00:07:30 -0700 (PDT) Received: from ptz.office.stw.pengutronix.de ([2a0a:edc0:0:900:1d::77] helo=irc.pengutronix.de) by metis.ext.pengutronix.de with esmtp (Exim 4.92) (envelope-from ) id 1oTHot-0002Fy-Vm; Wed, 31 Aug 2022 09:07:28 +0200 Message-ID: <116168b9e870353d7f607e11f91e4dcc3650ef40.camel@pengutronix.de> Subject: Re: [PATCH 02/16] dt-bindings: fpga: machxo2-slave: add erasure properties From: Johannes Zink To: Rob Herring Cc: devicetree@vger.kernel.org, linux-fpga@vger.kernel.org, Moritz Fischer , kernel@pengutronix.de, Xu Yilun , Wu Hao Date: Wed, 31 Aug 2022 09:07:11 +0200 In-Reply-To: <20220830203642.GA2011859-robh@kernel.org> References: <20220825141343.1375690-1-j.zink@pengutronix.de> <20220825141343.1375690-3-j.zink@pengutronix.de> <20220830203642.GA2011859-robh@kernel.org> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.38.3-1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SA-Exim-Connect-IP: 2a0a:edc0:0:900:1d::77 X-SA-Exim-Mail-From: j.zink@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: devicetree@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Hi Rob,  On Tue, 2022-08-30 at 15:36 -0500, Rob Herring wrote: > On Thu, Aug 25, 2022 at 04:13:29PM +0200, Johannes Zink wrote: > > This patch introduces additional memory areas of the machxo2-slave > > fpga > > to be erased. > > Why? > Depending on the bitstream loaded to the FPGA, parts of the Flash Memory or SRAM can hold configuration data which is non-volatile over erase cycles. With this property, the board integrator, who knows about the fpga design, can decide whether these areas shall be erased on update or not. As an example, think of MAC addresses for a softcore network interface stored in UFM (user flash memory), the board integrator might want to decide to protect this memory area over reflashing the fpga. > > > > Signed-off-by: Johannes Zink > > --- > >  .../bindings/fpga/lattice,machxo2-slave.yaml      | 15 > > +++++++++++++++ > >  1 file changed, 15 insertions(+) > > > > diff --git > > a/Documentation/devicetree/bindings/fpga/lattice,machxo2-slave.yaml > > b/Documentation/devicetree/bindings/fpga/lattice,machxo2-slave.yaml > > index d05acd6b0fc6..78f0da8f772f 100644 > > --- a/Documentation/devicetree/bindings/fpga/lattice,machxo2- > > slave.yaml > > +++ b/Documentation/devicetree/bindings/fpga/lattice,machxo2- > > slave.yaml > > @@ -26,6 +26,19 @@ properties: > >      enum: > >        - lattice,machxo2-slave-spi > >   > > +  lattice,erase-sram: > > +    type: boolean > > +    description: SRAM is to be erased during flash erase operation > > + > > +  lattice,erase-feature-row: > > +    type: boolean > > +    description: Feature row is to be erased during flash erase > > operation > > + > > +  lattice,erase-userflash: > > +    type: boolean > > +    description: | > > +      UFM (user flash memory) is to be erased during flash erase > > operation > > These seem like policy. It this something that's really static to a > particular board rather than something the user would configure each > time. >From the usecases I can think of, for a given board with a given FPGA design this is static. Best regards Johannes > > Rob > > -- Pengutronix e.K. | Johannes Zink | Steuerwalder Str. 21 | https://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686| Fax: +49-5121-206917-5555 |