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 X-Spam-Level: X-Spam-Status: No, score=-18.2 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 968C6C4338F for ; Mon, 23 Aug 2021 04:33:25 +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 BB2D56124B for ; Mon, 23 Aug 2021 04:33:24 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org BB2D56124B 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 AF5A48311C; Mon, 23 Aug 2021 06:33:22 +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=1629693203; bh=ZyKzRlfoBsXGZZMexdqKWlexvYqNtWBK2z1PExo42uQ=; 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=WcR4MU8sPOgYnIASPUZzoMEb/xf49QUqsIaXxqW7kAOpWrNMM2O9rfvaRBaTMzfG1 wPs0HRKnQsf/cb8xPzFOpl4rGMjeXqY7xJBTjyd0SZ1e22zGEJBliv35B60elkP1n5 e5QcE1juMOITcJ8lFrMzR0V1viTpcOaq80ldI/leSgQVwPlHyEXISB9c36xTNS9Y2n wClR7+RE6AiQh0hZ6iERPNrIsR3K3prh+3vb8OmDknMe4R6Siq+A/ez4kD6WtTd9oS qYrsvXggwOSDu3SPa1+mNrvwbUlT4zg3Ky7gRxkzdyjqeL0jbnM7xyIV+fgHe69LHc yFMhh74/UHGjw== Received: from [192.168.1.107] (82-131-153-206.pool.digikabel.hu [82.131.153.206]) (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 0A60F8310F; Mon, 23 Aug 2021 06:33:19 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1629693200; bh=ZyKzRlfoBsXGZZMexdqKWlexvYqNtWBK2z1PExo42uQ=; h=Subject:To:Cc:References:Reply-To:From:Date:In-Reply-To:From; b=m9GTM0GpSGcskUG4H4ZKkVOyTjhzrADigGuo/4UFsURQ8bDZfcr37lsRhFMysLPmL UehKu6993Y6CsGxCnQ0OtDS1fleyfOd2XkEi0GpSK7NhfMb/BDbKgfyKiGfYQ3eyCO ChUcktMVZAYGonrP8Gh2AV+mRx1W0nOmQGKcIJGSmtH/PvVbHskcE9G3fmge2Uw4U0 ILRJ5ZDamRftA4d1Vf+5FyqQ3ZAWDu6vCMa5RBxZR5XeiWYYOBM9Q1Rbr6JcH/pvzt RNCPouZeQVqCQ+00C0Qq6HiTCK0yM3KFjyHX/uFRsSYGIIZMQuASg3BWcXIpMdgTLe bWcXwQUeWL/2A== Subject: Re: [PATCH v2 1/1] bootcount: add a new driver with syscon as backend To: Nandor Han , u-boot@lists.denx.de, trini@konsulko.com, sjg@chromium.org Cc: vesa.jaaskelainen@vaisala.com References: <3a1c85f25c7b071846759ad9a4ae21a1556f02c4.1623328711.git.nandor.han@vaisala.com> From: Heiko Schocher Message-ID: <37e98f64-034c-1960-4ca9-6fcce371ab41@denx.de> Date: Mon, 23 Aug 2021 06:33:24 +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: <3a1c85f25c7b071846759ad9a4ae21a1556f02c4.1623328711.git.nandor.han@vaisala.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 Nandor, On 10.06.21 14:40, Nandor Han wrote: > The driver will use a syscon regmap as backend and supports both > 16 and 32 size value. The value will be stored in the CPU's endianness. > > Signed-off-by: Nandor Han > --- > > Notes: > Description > ----------- > Add a new driver for bootcount feature that supports `syscon` device as > backend. > > Testing > ------- > UnitTests: > 1. Verify that unit-tests run successfully: PASS > ``` > ./test/py/test.py --bd sandbox --build -k ut_dm_bootcount -v > > test/py/tests/test_ut.py::test_ut[ut_dm_bootcount_rtc] PASSED [ 33%] > test/py/tests/test_ut.py::test_ut[ut_dm_bootcount_syscon_four_bytes] PASSED [ 66%] > test/py/tests/test_ut.py::test_ut[ut_dm_bootcount_syscon_two_bytes] PASSED [100%] > ``` > > Using hardware: > Board: i.MX6sx based dev board > U-Boot version: 2020.01 > 1. Use `bootcount` command to verity that value is updated > correctly: PASS > > > Changes since v1: > - rebased > > arch/sandbox/dts/test.dts | 14 ++ > configs/sandbox_defconfig | 1 + > doc/device-tree-bindings/bootcount-syscon.txt | 25 +++ > drivers/bootcount/Kconfig | 12 ++ > drivers/bootcount/Makefile | 1 + > drivers/bootcount/bootcount_syscon.c | 159 ++++++++++++++++++ > test/dm/bootcount.c | 48 +++++- > 7 files changed, 257 insertions(+), 3 deletions(-) > create mode 100644 doc/device-tree-bindings/bootcount-syscon.txt > create mode 100644 drivers/bootcount/bootcount_syscon.c Applied to u-boot-i2c.git master 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