[PATCH 4/8] string: remove unused strswab() function
Simon Glass
sjg at chromium.org
Thu Jul 2 10:30:04 CEST 2026
On 2026-07-01T17:15:27, Rasmus Villemoes <rv at rasmusvillemoes.dk> wrote:
> string: remove unused strswab() function
>
> The last use of this function with rather peculiar semantics[*] vanished
> in 2021 with 0a527fda782 ("Fix IDE commands issued, fix endian issues,
> fix non MMIO"). It has no tests, and should a need for something
> similar ever appear, it is better done with some proper
> utf16le/utf16be/utf16 abstractions rather than cluttering code with
> '#ifdef __LITTLE_ENDIAN'.
>
> [*] The byte-swapping itself is weird enough. But why is an input string
> of odd length ok, while the empty string is not allowed?
>
> Signed-off-by: Rasmus Villemoes <rv at rasmusvillemoes.dk>
>
> include/linux/string.h | 4 ----
> lib/string.c | 28 ----------------------------
> 2 files changed, 32 deletions(-)
Reviewed-by: Simon Glass <sjg at chromium.org>
More information about the U-Boot
mailing list