mbox series

[00/10] tty: tty_buffer: cleanup

Message ID 20230816105530.3335-1-jirislaby@kernel.org
Headers show
Series tty: tty_buffer: cleanup | expand

Message

Jiri Slaby Aug. 16, 2023, 10:55 a.m. UTC
This is another part (say part II.) of the previous type unification
across the tty layer[1]. This time, in tty_buffer. Apart from type
changes, this series contains a larger set of refactoring of the code.
Namely, unification of byte stuffing into the tty buffers into a single
function.

[1] https://lore.kernel.org/all/20230810091510.13006-1-jirislaby@kernel.org/

Jiri Slaby (SUSE) (10):
  tty: tty_buffer: switch data type to u8
  tty: tty_buffer: use struct_size() in tty_buffer_alloc()
  tty: tty_buffer: unify tty_insert_flip_string_{fixed_flag,flags}()
  tty: tty_buffer: warn if losing flags in
    __tty_insert_flip_string_flags()
  tty: tty_buffer: switch insert functions to size_t
  tty: tty_buffer: let tty_prepare_flip_string() return size_t
  tty: tty_buffer: use __tty_insert_flip_string_flags() in
    tty_insert_flip_char()
  tty: tty_buffer: better types in __tty_buffer_request_room()
  tty: tty_buffer: initialize variables in initializers already
  tty: tty_buffer: invert conditions in __tty_buffer_request_room()

 Documentation/driver-api/tty/tty_buffer.rst |   7 +-
 drivers/tty/tty_buffer.c                    | 169 ++++++--------------
 include/linux/tty_buffer.h                  |   4 +-
 include/linux/tty_flip.h                    |  64 ++++++--
 4 files changed, 111 insertions(+), 133 deletions(-)

Comments

Greg Kroah-Hartman Aug. 22, 2023, 12:58 p.m. UTC | #1
On Wed, Aug 16, 2023 at 12:55:20PM +0200, Jiri Slaby (SUSE) wrote:
> This is another part (say part II.) of the previous type unification
> across the tty layer[1]. This time, in tty_buffer. Apart from type
> changes, this series contains a larger set of refactoring of the code.
> Namely, unification of byte stuffing into the tty buffers into a single
> function.
> 
> [1] https://lore.kernel.org/all/20230810091510.13006-1-jirislaby@kernel.org/
> 
> Jiri Slaby (SUSE) (10):
>   tty: tty_buffer: switch data type to u8
>   tty: tty_buffer: use struct_size() in tty_buffer_alloc()
>   tty: tty_buffer: unify tty_insert_flip_string_{fixed_flag,flags}()
>   tty: tty_buffer: warn if losing flags in
>     __tty_insert_flip_string_flags()
>   tty: tty_buffer: switch insert functions to size_t
>   tty: tty_buffer: let tty_prepare_flip_string() return size_t
>   tty: tty_buffer: use __tty_insert_flip_string_flags() in
>     tty_insert_flip_char()
>   tty: tty_buffer: better types in __tty_buffer_request_room()
>   tty: tty_buffer: initialize variables in initializers already
>   tty: tty_buffer: invert conditions in __tty_buffer_request_room()
> 
>  Documentation/driver-api/tty/tty_buffer.rst |   7 +-
>  drivers/tty/tty_buffer.c                    | 169 ++++++--------------
>  include/linux/tty_buffer.h                  |   4 +-
>  include/linux/tty_flip.h                    |  64 ++++++--
>  4 files changed, 111 insertions(+), 133 deletions(-)
> 
> -- 
> 2.41.0
> 

Nice work, thanks, all now queued up.

greg k-h