qeth: return with -EPERM if sniffing is not enabled

Without appropriate configuration at the SE, a HiperSockets device
cannot be used for sniffing. Setting the sniffer attribute is rejected
with -EPERM.

Signed-off-by: Ursula Braun <ursula.braun@de.ibm.com>
Signed-off-by: Frank Blaschka <frank.blaschka@de.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Ursula Braun 2011-11-15 02:31:12 +00:00 committed by David S. Miller
parent 709e8697af
commit 6cc31d09be
1 changed files with 2 additions and 2 deletions

View File

@ -335,10 +335,10 @@ static ssize_t qeth_l3_dev_sniffer_store(struct device *dev,
QETH_IN_BUF_COUNT_MAX)
qeth_realloc_buffer_pool(card,
QETH_IN_BUF_COUNT_MAX);
break;
} else
rc = -EPERM;
default: /* fall through */
break;
default:
rc = -EINVAL;
}
out: