Commit 656a48c4 authored by Thorsten Blum's avatar Thorsten Blum Committed by Greg Kroah-Hartman
Browse files

char/adi: Remove redundant less-than-zero check in adi_write()



The function parameter 'size_t count' is unsigned and cannot be less
than zero. Remove the redundant condition.

Signed-off-by: default avatarThorsten Blum <thorsten.blum@linux.dev>
Link: https://lore.kernel.org/r/20250903202350.182446-2-thorsten.blum@linux.dev


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 6b260538
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -131,7 +131,7 @@ static ssize_t adi_write(struct file *file, const char __user *buf,
	ssize_t ret;
	int i;

	if (count <= 0)
	if (count == 0)
		return -EINVAL;

	ver_buf_sz = min_t(size_t, count, MAX_BUF_SZ);