From: Stefan Roese <sr@denx.de>
To: Samuel Holland <samuel@sholland.org>,
u-boot@lists.denx.de, Jagan Teki <jagan@amarulasolutions.com>,
Andre Przywara <andre.przywara@arm.com>
Cc: Bin Meng <bmeng.cn@gmail.com>, Sean Anderson <seanga2@gmail.com>,
Heinrich Schuchardt <heinrich.schuchardt@canonical.com>,
Simon Glass <sjg@chromium.org>
Subject: Re: [PATCH v2 0/6] Improved sysreset/watchdog uclass integration
Date: Tue, 2 Nov 2021 11:21:29 +0100 [thread overview]
Message-ID: <2dfd11c8-7eaf-0dee-3ce2-4df979ac16ea@denx.de> (raw)
In-Reply-To: <20211029031656.24167-1-samuel@sholland.org>
Hi Samuel,
On 29.10.21 05:16, Samuel Holland wrote:
> This series hooks up the watchdog uclass to automatically register
> watchdog devices for use with sysreset, doing a bit of minor cleanup
> along the way.
>
> The goal is for this to replace the sunxi board-level non-DM reset_cpu()
> function. I was surprised to find that the wdt_reboot driver requires
> its own undocumented device tree node, which references the watchdog
> device by phandle. This is problematic for us, because sunxi-u-boot.dtsi
> file covers 20 different SoCs with varying watchdog node phandle names.
> So it would have required adding a -u-boot.dtsi file for each board.
>
> Hooking things up automatically makes sense to me; this is what Linux
> does. However, I put the code behind a new option to avoid surprises for
> other platforms.
>
> Changes in v2:
> - Extend the "if SYSRESET" block to the end of the file.
> - Also make gpio_reboot_probe function static.
> - Rebase on top of 492ee6b8d0e7 (now handle all watchdogs).
> - Added patches 5-6 as an example of how the new option will be used.
>
> Samuel Holland (6):
> sysreset: Add uclass Kconfig dependency to drivers
> sysreset: Mark driver probe functions as static
> sysreset: watchdog: Move watchdog reference to plat data
> watchdog: Automatically register device with sysreset
> sunxi: Avoid duplicate reset_cpu with SYSRESET enabled
> sunxi: Use sysreset framework for poweroff/reset
>
> arch/arm/Kconfig | 3 +++
> arch/arm/mach-sunxi/board.c | 2 ++
> drivers/sysreset/Kconfig | 11 ++++++--
> drivers/sysreset/sysreset_gpio.c | 2 +-
> drivers/sysreset/sysreset_resetctl.c | 2 +-
> drivers/sysreset/sysreset_syscon.c | 2 +-
> drivers/sysreset/sysreset_watchdog.c | 40 ++++++++++++++++++++++------
> drivers/watchdog/wdt-uclass.c | 5 ++++
> include/sysreset.h | 14 ++++++++++
> 9 files changed, 68 insertions(+), 13 deletions(-)
This patchset (applied to current master) generates multiple issues when
building "world" via CI (Azure in my case). Here one of those problems:
$ make sandbox_config
$ make -s -j20
In file included from ./arch/sandbox/include/asm/state.h:10,
from include/test/test.h:130,
from include/test/env.h:10,
from test/env/cmd_ut_env.c:9:
include/sysreset.h: In function ‘arch_reset_for_test’:
include/sysreset.h:147:19: error: invalid storage class for function
‘sysreset_register_wdt’
147 | static inline int sysreset_register_wdt(struct udevice *dev) {
return 0; }
| ^~~~~~~~~~~~~~~~~~~~~
make[1]: *** [scripts/Makefile.build:253: test/env/cmd_ut_env.o] Error 1
make: *** [Makefile:1804: test/env] Error 2
make: *** Waiting for unfinished jobs....
In file included from ./arch/sandbox/include/asm/state.h:10,
from include/test/test.h:130,
from include/test/lib.h:9,
from test/cmd/test_echo.c:12:
include/sysreset.h: In function ‘arch_reset_for_test’:
include/sysreset.h:147:19: error: invalid storage class for function
‘sysreset_register_wdt’
147 | static inline int sysreset_register_wdt(struct udevice *dev) {
return 0; }
| ^~~~~~~~~~~~~~~~~~~~~
make[2]: *** [scripts/Makefile.build:253: test/cmd/test_echo.o] Error 1
make[1]: *** [scripts/Makefile.build:394: test/cmd] Error 2
make: *** [Makefile:1804: test] Error 2
Could you please take a look here?
Thanks,
Stefan
prev parent reply other threads:[~2021-11-02 10:21 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-29 3:16 [PATCH v2 0/6] Improved sysreset/watchdog uclass integration Samuel Holland
2021-10-29 3:16 ` [PATCH v2 1/6] sysreset: Add uclass Kconfig dependency to drivers Samuel Holland
2021-11-03 13:11 ` Heinrich Schuchardt
2021-10-29 3:16 ` [PATCH v2 2/6] sysreset: Mark driver probe functions as static Samuel Holland
2021-11-03 14:19 ` Heinrich Schuchardt
2021-10-29 3:16 ` [PATCH v2 3/6] sysreset: watchdog: Move watchdog reference to plat data Samuel Holland
2021-10-29 3:16 ` [PATCH v2 4/6] watchdog: Automatically register device with sysreset Samuel Holland
2021-11-03 13:52 ` Heinrich Schuchardt
2021-10-29 3:16 ` [PATCH v2 5/6] sunxi: Avoid duplicate reset_cpu with SYSRESET enabled Samuel Holland
2021-10-29 3:16 ` [PATCH v2 6/6] sunxi: Use sysreset framework for poweroff/reset Samuel Holland
2021-11-02 10:21 ` Stefan Roese [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2dfd11c8-7eaf-0dee-3ce2-4df979ac16ea@denx.de \
--to=sr@denx.de \
--cc=andre.przywara@arm.com \
--cc=bmeng.cn@gmail.com \
--cc=heinrich.schuchardt@canonical.com \
--cc=jagan@amarulasolutions.com \
--cc=samuel@sholland.org \
--cc=seanga2@gmail.com \
--cc=sjg@chromium.org \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox