summaryrefslogtreecommitdiff
path: root/kernel/sysctl_binary.c
diff options
context:
space:
mode:
authorJohannes Thumshirn <jthumshirn@suse.de>2017-07-17 15:11:42 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-03-22 09:23:32 +0100
commitdb259b6768cf52ae1c0c92b7fc6e093a28969d71 (patch)
treea6eb75e38f92c4dd60a79fa38c91bae633164681 /kernel/sysctl_binary.c
parent6d85835042a7f94b0ccc02d0103bd2000ebe25f6 (diff)
scsi: sg: fix static checker warning in sg_is_valid_dxfer
commit 14074aba4bcda3764c9a702b276308b89901d5b6 upstream. dxfer_len is an unsigned int and we always assign a value > 0 to it, so it doesn't make any sense to check if it is < 0. We can't really check dxferp as well as we have both NULL and not NULL cases in the possible call paths. So just return true for SG_DXFER_FROM_DEV transfer in sg_is_valid_dxfer(). Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de> Reported-by: Colin Ian King <colin.king@canonical.com> Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Cc: Douglas Gilbert <dgilbert@interlog.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'kernel/sysctl_binary.c')
0 files changed, 0 insertions, 0 deletions