staging: sep: Fix sign of error

One of our errors wasn't negative as intended. Fix this.
(Found by Hillf Danton)

While we are at it turn user causable messages down to dev_dbg level in the
ioctl paths.

Signed-off-by: Alan Cox <alan@linux.intel.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Alan Cox 2012-03-21 12:32:32 +00:00 коммит произвёл Greg Kroah-Hartman
Родитель 0034102808
Коммит fcff311c93
1 изменённых файлов: 3 добавлений и 3 удалений

Просмотреть файл

@ -3114,7 +3114,7 @@ static long sep_ioctl(struct file *filp, unsigned int cmd, unsigned long arg)
current->pid); current->pid);
if (1 == test_bit(SEP_LEGACY_SENDMSG_DONE_OFFSET, if (1 == test_bit(SEP_LEGACY_SENDMSG_DONE_OFFSET,
&call_status->status)) { &call_status->status)) {
dev_warn(&sep->pdev->dev, dev_dbg(&sep->pdev->dev,
"[PID%d] dcb prep needed before send msg\n", "[PID%d] dcb prep needed before send msg\n",
current->pid); current->pid);
error = -EPROTO; error = -EPROTO;
@ -3122,9 +3122,9 @@ static long sep_ioctl(struct file *filp, unsigned int cmd, unsigned long arg)
} }
if (!arg) { if (!arg) {
dev_warn(&sep->pdev->dev, dev_dbg(&sep->pdev->dev,
"[PID%d] dcb null arg\n", current->pid); "[PID%d] dcb null arg\n", current->pid);
error = EINVAL; error = -EINVAL;
goto end_function; goto end_function;
} }