All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net] Revert "net: core: maybe return -EEXIST in __dev_alloc_name"
@ 2017-12-02  7:41 Johannes Berg
  2017-12-05 16:27 ` David Miller
  2017-12-19 12:28 ` [net] " Michael Ellerman
  0 siblings, 2 replies; 11+ messages in thread
From: Johannes Berg @ 2017-12-02  7:41 UTC (permalink / raw)
  To: netdev; +Cc: Jouni Malinen, Rasmus Villemoes, Johannes Berg

From: Johannes Berg <johannes.berg@intel.com>

This reverts commit d6f295e9def0; some userspace (in the case
we noticed it's wpa_supplicant), is relying on the current
error code to determine that a fixed name interface already
exists.

Reported-by: Jouni Malinen <j@w1.fi>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
---
 net/core/dev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/core/dev.c b/net/core/dev.c
index 07ed21d64f92..f47e96b62308 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -1106,7 +1106,7 @@ static int __dev_alloc_name(struct net *net, const char *name, char *buf)
 	 * when the name is long and there isn't enough space left
 	 * for the digits, or if all bits are used.
 	 */
-	return p ? -ENFILE : -EEXIST;
+	return -ENFILE;
 }
 
 static int dev_alloc_name_ns(struct net *net,
-- 
2.14.2

^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2018-01-08 17:36 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-12-02  7:41 [PATCH net] Revert "net: core: maybe return -EEXIST in __dev_alloc_name" Johannes Berg
2017-12-05 16:27 ` David Miller
2017-12-19 12:28 ` [net] " Michael Ellerman
2017-12-19 16:15   ` Johannes Berg
2017-12-19 16:15     ` Johannes Berg
2017-12-20 23:37   ` Rasmus Villemoes
2017-12-22  4:22     ` Michael Ellerman
2018-01-02 16:50       ` David Miller
2018-01-02 16:52         ` Johannes Berg
2018-01-08  3:26         ` Michael Ellerman
2018-01-08 17:36           ` David Miller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.