diff options
| author | Nicolas Pitre <npitre@baylibre.com> | 2025-04-11 20:43:58 +0300 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2025-04-15 15:36:55 +0300 |
| commit | 8bfabff0bfff8fbbe90673d1a557d15c42b4494a (patch) | |
| tree | 759fa7812e66522b6a03721faaee71d5a33baf0c | |
| parent | 043806bc9dbc6597dd15e6ca9220ae2746425f2f (diff) | |
| download | linux-8bfabff0bfff8fbbe90673d1a557d15c42b4494a.tar.xz | |
vt: fix comment vs definition mismatch
Fixes for:
ucs_is_zero_width()
ucs_is_double_width()
ucs_recompose()
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202504111036.YH1iEqBR-lkp@intel.com/
Closes: https://lore.kernel.org/oe-kbuild-all/202504111359.urXWyzvQ-lkp@intel.com/
Link: https://lore.kernel.org/r/o4974349-pp4p-4374-80q9-2oppqqr94r60@syhkavp.arg
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| -rwxr-xr-x | drivers/tty/vt/gen_ucs_recompose.py | 5 | ||||
| -rwxr-xr-x | drivers/tty/vt/gen_ucs_width.py | 4 | ||||
| -rw-r--r-- | drivers/tty/vt/ucs_recompose.c | 5 | ||||
| -rw-r--r-- | drivers/tty/vt/ucs_width.c | 4 |
4 files changed, 8 insertions, 10 deletions
diff --git a/drivers/tty/vt/gen_ucs_recompose.py b/drivers/tty/vt/gen_ucs_recompose.py index 64418803e49e..dc176d32e225 100755 --- a/drivers/tty/vt/gen_ucs_recompose.py +++ b/drivers/tty/vt/gen_ucs_recompose.py @@ -289,8 +289,8 @@ static int recomposition_compare(const void *key, const void *element) /** * Attempt to recompose two Unicode characters into a single character. * - * @param previous: Previous Unicode code point (UCS-4) - * @param current: Current Unicode code point (UCS-4) + * @param base: Base Unicode code point (UCS-4) + * @param combining: Combining mark Unicode code point (UCS-4) * Return: Recomposed Unicode code point, or 0 if no recomposition is possible */ uint32_t ucs_recompose(uint32_t base, uint32_t combining) @@ -301,7 +301,6 @@ uint32_t ucs_recompose(uint32_t base, uint32_t combining) return 0; struct compare_key key = {{ base, combining }}; - struct recomposition *result = __inline_bsearch(&key, recomposition_table, ARRAY_SIZE(recomposition_table), diff --git a/drivers/tty/vt/gen_ucs_width.py b/drivers/tty/vt/gen_ucs_width.py index c6cbc93e83f2..e65f43e2080a 100755 --- a/drivers/tty/vt/gen_ucs_width.py +++ b/drivers/tty/vt/gen_ucs_width.py @@ -292,7 +292,7 @@ static bool is_in_interval32(uint32_t cp, const struct interval32 *intervals, si /** * Determine if a Unicode code point is zero-width. * - * @param ucs: Unicode code point (UCS-4) + * @param cp: Unicode code point (UCS-4) * Return: true if the character is zero-width, false otherwise */ bool ucs_is_zero_width(uint32_t cp) @@ -305,7 +305,7 @@ bool ucs_is_zero_width(uint32_t cp) /** * Determine if a Unicode code point is double-width. * - * @param ucs: Unicode code point (UCS-4) + * @param cp: Unicode code point (UCS-4) * Return: true if the character is double-width, false otherwise */ bool ucs_is_double_width(uint32_t cp) diff --git a/drivers/tty/vt/ucs_recompose.c b/drivers/tty/vt/ucs_recompose.c index 5c30c989def3..52cde1517f89 100644 --- a/drivers/tty/vt/ucs_recompose.c +++ b/drivers/tty/vt/ucs_recompose.c @@ -147,8 +147,8 @@ static int recomposition_compare(const void *key, const void *element) /** * Attempt to recompose two Unicode characters into a single character. * - * @param previous: Previous Unicode code point (UCS-4) - * @param current: Current Unicode code point (UCS-4) + * @param base: Base Unicode code point (UCS-4) + * @param combining: Combining mark Unicode code point (UCS-4) * Return: Recomposed Unicode code point, or 0 if no recomposition is possible */ uint32_t ucs_recompose(uint32_t base, uint32_t combining) @@ -159,7 +159,6 @@ uint32_t ucs_recompose(uint32_t base, uint32_t combining) return 0; struct compare_key key = { base, combining }; - struct recomposition *result = __inline_bsearch(&key, recomposition_table, ARRAY_SIZE(recomposition_table), diff --git a/drivers/tty/vt/ucs_width.c b/drivers/tty/vt/ucs_width.c index 060aa8ae7f16..4d5a0021e33b 100644 --- a/drivers/tty/vt/ucs_width.c +++ b/drivers/tty/vt/ucs_width.c @@ -512,7 +512,7 @@ static bool is_in_interval32(uint32_t cp, const struct interval32 *intervals, si /** * Determine if a Unicode code point is zero-width. * - * @param ucs: Unicode code point (UCS-4) + * @param cp: Unicode code point (UCS-4) * Return: true if the character is zero-width, false otherwise */ bool ucs_is_zero_width(uint32_t cp) @@ -525,7 +525,7 @@ bool ucs_is_zero_width(uint32_t cp) /** * Determine if a Unicode code point is double-width. * - * @param ucs: Unicode code point (UCS-4) + * @param cp: Unicode code point (UCS-4) * Return: true if the character is double-width, false otherwise */ bool ucs_is_double_width(uint32_t cp) |
