All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/3] boot: android: rework the bootargs concatenation
@ 2024-12-17 13:29 Nicolas Belin
  2024-12-17 13:29 ` [PATCH v2 1/3] boot: android: fix extra command line support Nicolas Belin
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Nicolas Belin @ 2024-12-17 13:29 UTC (permalink / raw)
  To: Tom Rini, Simon Glass, Safae Ouajih, Mattijs Korpershoek,
	Ahmad Draidi
  Cc: u-boot, Nicolas Belin

Rework the bootargs concatenation logic to make the logic clearer
and address several issues such as:
- checking the value at the address kcmdline_extra instead of
checking the address value itself
- freeing the string that was malloced for the concatenation
- making sure to malloc the right amount of bytes for the concatenated
string, not forgetting the byte for the NULL termination 

Signed-off-by: Nicolas Belin <nbelin@baylibre.com>
---
Changes in v2:
- Improve the logic to avoid trailing whitespaces in the concatenated
  bootargs
- Drop the last patch reordering the length calculation as it is already
  done by the improved logic
- Link to v1: https://lore.kernel.org/r/20241211-fix-bootargs-concatenation-v1-0-c6752bcb9dde@baylibre.com

---
Nicolas Belin (3):
      boot: android: fix extra command line support
      boot: android: free newbootargs when done
      boot: android: rework bootargs concatenation

 boot/image-android.c | 34 +++++++++++++++++++---------------
 1 file changed, 19 insertions(+), 15 deletions(-)
---
base-commit: b841e559cd26ffcb20f22e8ee75debed9616c002
change-id: 20241211-fix-bootargs-concatenation-8b616c110b63

Best regards,
-- 
Nicolas Belin <nbelin@baylibre.com>


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

end of thread, other threads:[~2024-12-18 13:05 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-12-17 13:29 [PATCH v2 0/3] boot: android: rework the bootargs concatenation Nicolas Belin
2024-12-17 13:29 ` [PATCH v2 1/3] boot: android: fix extra command line support Nicolas Belin
2024-12-17 13:29 ` [PATCH v2 2/3] boot: android: free newbootargs when done Nicolas Belin
2024-12-17 13:29 ` [PATCH v2 3/3] boot: android: rework bootargs concatenation Nicolas Belin
2024-12-18 10:49   ` Mattijs Korpershoek
2024-12-18 13:05 ` [PATCH v2 0/3] boot: android: rework the " Mattijs Korpershoek

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.