summaryrefslogtreecommitdiff
path: root/drivers/net/netconsole.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2011-10-25 02:18:09 +0400
committerDavid S. Miller <davem@davemloft.net>2011-10-25 02:18:09 +0400
commit1805b2f04855f07afe3a71d620a68f483b0ed74f (patch)
treeb823b90f37f5404fcaef70f785c70112ca74a329 /drivers/net/netconsole.c
parent78d81d15b74246c7cedf84894434890b33da3907 (diff)
parentf42af6c486aa5ca6ee62800cb45c5b252020509d (diff)
downloadlinux-1805b2f04855f07afe3a71d620a68f483b0ed74f.tar.xz
Merge branch 'master' of ra.kernel.org:/pub/scm/linux/kernel/git/davem/net
Diffstat (limited to 'drivers/net/netconsole.c')
-rw-r--r--drivers/net/netconsole.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/net/netconsole.c b/drivers/net/netconsole.c
index ed2a3977c6e7..e8882023576b 100644
--- a/drivers/net/netconsole.c
+++ b/drivers/net/netconsole.c
@@ -307,6 +307,11 @@ static ssize_t store_enabled(struct netconsole_target *nt,
return err;
if (enabled < 0 || enabled > 1)
return -EINVAL;
+ if (enabled == nt->enabled) {
+ printk(KERN_INFO "netconsole: network logging has already %s\n",
+ nt->enabled ? "started" : "stopped");
+ return -EINVAL;
+ }
if (enabled) { /* 1 */