mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH v2 0/3] PBL: enable timeouts in read_poll_timeout macros
@ 2026-08-11 10:13 Stefan Kerkmann
  2026-08-11 10:13 ` [PATCH v2 1/3] ARM64: lib64: pbl: implement get_time_ns and is_timeout Stefan Kerkmann
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Stefan Kerkmann @ 2026-08-11 10:13 UTC (permalink / raw)
  To: Sascha Hauer, open list:BAREBOX; +Cc: Stefan Kerkmann

Without a time source the read_poll_timeout functions will deadlock in the PBL
if the break condition is never met. This series introduces the necessary
timing functions in the PBL for ARMv7 and ARMv8 based on the ARM architected
timer and enable their usage if available.

Signed-off-by: Stefan Kerkmann <s.kerkmann@pengutronix.de>
---
Changes in v2:
- Strictly guard the pbl timer support on 32bit ARM for ARMv7 only builds
- Link to v1: https://lore.kernel.org/r/20250121-feature-pbl-get-time-ns-v1-0-c3d493397846@pengutronix.de

To: Sascha Hauer <s.hauer@pengutronix.de>
To: "open list:BAREBOX" <barebox@lists.infradead.org>

---
Stefan Kerkmann (3):
      ARM64: lib64: pbl: implement get_time_ns and is_timeout
      ARM: lib32: pbl: implement get_time_ns and is_timeout
      pbl: introduce HAS_PBL_CLOCKSOURCE marker

 arch/arm/cpu/Kconfig                   |  2 ++
 arch/arm/lib32/Makefile                |  2 +-
 arch/arm/lib32/arm_architected_timer.c | 15 ++++++++++++++-
 arch/arm/lib64/delay.c                 | 17 +++++++++++++++--
 include/linux/iopoll.h                 |  2 +-
 pbl/Kconfig                            |  3 +++
 6 files changed, 36 insertions(+), 5 deletions(-)
---
base-commit: 4705656eeeaba0dd3617b69172328daf4dbf9060
change-id: 20250121-feature-pbl-get-time-ns-6d9e8874d582

Best regards,
--  
Stefan Kerkmann <s.kerkmann@pengutronix.de>




^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2026-08-12  7:15 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-08-11 10:13 [PATCH v2 0/3] PBL: enable timeouts in read_poll_timeout macros Stefan Kerkmann
2026-08-11 10:13 ` [PATCH v2 1/3] ARM64: lib64: pbl: implement get_time_ns and is_timeout Stefan Kerkmann
2026-08-11 10:13 ` [PATCH v2 2/3] ARM: lib32: " Stefan Kerkmann
2026-08-11 10:21   ` Ahmad Fatoum
2026-08-12  5:56     ` Sascha Hauer
2026-08-11 10:13 ` [PATCH v2 3/3] pbl: introduce HAS_PBL_CLOCKSOURCE marker Stefan Kerkmann
2026-08-12  5:32   ` Sascha Hauer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox