diff options
author | Jiri Slaby (SUSE) <jirislaby@kernel.org> | 2023-08-10 11:15:09 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2023-08-11 21:12:47 +0200 |
commit | 6fcd3b67284b83af144dafe45c2766933101cc2b (patch) | |
tree | 984b529bb9bb702fb98a4d3216a93570b18171c7 /lib/strscpy_kunit.c | |
parent | c3e5c706aefc3ceee941c1e7bd72084d3aeca37b (diff) | |
download | linux-6fcd3b67284b83af144dafe45c2766933101cc2b.tar.gz linux-6fcd3b67284b83af144dafe45c2766933101cc2b.tar.bz2 linux-6fcd3b67284b83af144dafe45c2766933101cc2b.zip |
tty: hso: simplify hso_serial_write()
There is no need for two more variables in hso_serial_write(). Switch to
min_t() and eliminate those.
Furthermore, the 'if-goto' is superfluous as memcpy() of zero count is a
nop. So is addition of zero. So remove the 'if-goto' completely.
Signed-off-by: "Jiri Slaby (SUSE)" <jirislaby@kernel.org>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Eric Dumazet <edumazet@google.com>
Cc: Jakub Kicinski <kuba@kernel.org>
Cc: Paolo Abeni <pabeni@redhat.com>
Link: https://lore.kernel.org/r/20230810091510.13006-36-jirislaby@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'lib/strscpy_kunit.c')
0 files changed, 0 insertions, 0 deletions