about summary refs log tree commit diff
path: root/debian
diff options
context:
space:
mode:
Diffstat (limited to 'debian')
-rw-r--r--debian/changelog6
-rw-r--r--debian/patches/Revert-ppp-manager-don-t-use-kernel-pppoe-rh-1034860-rh-1.patch131
-rw-r--r--debian/patches/series1
-rwxr-xr-xdebian/rules1
4 files changed, 138 insertions, 1 deletions
diff --git a/debian/changelog b/debian/changelog
index 2f8cb5f0..729f16e2 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,12 @@ network-manager (1.0.10-2) UNRELEASED; urgency=medium
 
   * Fix failure to configure routes due to wrong device-route for IPv4
     peer-addresses. Patch cherry-picked from upstream Git. (Closes: #809195)
+  * Switch from user-mode PPPoE client back to kernel-mode PPPoE.
+    We switched to rp-pppoe some time ago to workaround a bug in detecting
+    disconnects which has seen been fixed in the kernel and could be worked
+    around fairly simply with the right configuration.
+    In addition, the kernel mode PPPoE implementation is faster and provides
+    more features. (Closes: #783525)
 
  -- Michael Biebl <biebl@debian.org>  Wed, 20 Jan 2016 14:58:30 +0100
 
diff --git a/debian/patches/Revert-ppp-manager-don-t-use-kernel-pppoe-rh-1034860-rh-1.patch b/debian/patches/Revert-ppp-manager-don-t-use-kernel-pppoe-rh-1034860-rh-1.patch
new file mode 100644
index 00000000..5dc1833c
--- /dev/null
+++ b/debian/patches/Revert-ppp-manager-don-t-use-kernel-pppoe-rh-1034860-rh-1.patch
@@ -0,0 +1,131 @@
+From: Dan Williams <dcbw@redhat.com>
+Date: Wed, 18 Feb 2015 10:45:07 -0600
+Subject: Revert "ppp-manager: don't use kernel pppoe (rh #1034860,
+ rh #1061641)"
+
+We switched to user-mode PPPoE client to work around a bug in kernel
+PPPoE code that caused pppd not to be notified when the connection was
+terminated with a PADT before the LCP Termination Request.
+
+The kernel bug has now been fixed upstream with commit 287f3a943fef
+"pppoe: Use workqueue to die properly when a PADT is received", queued
+for v4.1.
+
+Since the issue affected only very particular scenarios and could
+somehow be solved with the right configuration (see bugzilla entry),
+we can safely revert the patch and restore the use of kernel mode
+PPPoE.
+
+This reverts commit 7955806a02db64b20079267743056d7d9d45af3b.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=742939
+---
+ configure.ac                     |  9 --------
+ src/ppp-manager/nm-ppp-manager.c | 46 +++++++++++-----------------------------
+ 2 files changed, 12 insertions(+), 43 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 8ca1278..86a427d 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -629,15 +629,6 @@ fi
+ AC_DEFINE_UNQUOTED(PPPD_PATH, "$PPPD_PATH", [Define to path of pppd binary])
+ AC_SUBST(PPPD_PATH)
+ 
+-AC_ARG_WITH(pppoe, AS_HELP_STRING([--with-pppoe=/path/to/pppoe], [path to pppoe binary]))
+-if test "x${with_pppoe}" = x; then
+-  AC_PATH_PROG(PPPOE_PATH, pppoe, [], $PATH:/sbin:/usr/sbin)
+-else
+-  PPPOE_PATH="$with_pppoe"
+-fi
+-AC_DEFINE_UNQUOTED(PPPOE_PATH, "$PPPOE_PATH", [Define to path of pppoe binary])
+-AC_SUBST(PPPOE_PATH)
+-
+ # ModemManager1 with libmm-glib
+ AC_ARG_WITH(modem-manager-1, AS_HELP_STRING([--with-modem-manager-1], [Enable new ModemManager1 interface support]),,[with_modem_manager_1=auto])
+ if (test "${with_modem_manager_1}" != "no"); then
+diff --git a/src/ppp-manager/nm-ppp-manager.c b/src/ppp-manager/nm-ppp-manager.c
+index d27b262..6742104 100644
+--- a/src/ppp-manager/nm-ppp-manager.c
++++ b/src/ppp-manager/nm-ppp-manager.c
+@@ -854,7 +854,7 @@ create_pppd_cmd_line (NMPPPManager *self,
+                       GError **err)
+ {
+ 	NMPPPManagerPrivate *priv = NM_PPP_MANAGER_GET_PRIVATE (self);
+-	const char *pppd_binary = NULL, *pppoe_binary = NULL;
++	const char *pppd_binary = NULL;
+ 	NMCmdLine *cmd;
+ 	gboolean ppp_debug;
+ 
+@@ -864,14 +864,6 @@ create_pppd_cmd_line (NMPPPManager *self,
+ 	if (!pppd_binary)
+ 		return NULL;
+ 
+-	if (   pppoe
+-	    || (   adsl
+-	        && !strcmp (nm_setting_adsl_get_protocol (adsl), NM_SETTING_ADSL_PROTOCOL_PPPOE))) {
+-		pppoe_binary = nm_utils_find_helper ("pppoe", NULL, err);
+-		if (!pppoe_binary)
+-			return NULL;
+-	}
+-
+ 	/* Create pppd command line */
+ 	cmd = nm_cmd_line_new ();
+ 	nm_cmd_line_add_string (cmd, pppd_binary);
+@@ -899,30 +891,21 @@ create_pppd_cmd_line (NMPPPManager *self,
+ 	}
+ 
+ 	if (pppoe) {
+-		GString *pppoe_arg;
++		char *dev_str;
+ 		const char *pppoe_service;
+-		char *quoted;
+ 
+-		g_assert (pppoe_binary != NULL);
+-		pppoe_arg = g_string_new (pppoe_binary);
++		nm_cmd_line_add_string (cmd, "plugin");
++		nm_cmd_line_add_string (cmd, "rp-pppoe.so");
+ 
+-		g_string_append (pppoe_arg, " -I ");
+-		quoted = g_shell_quote (priv->parent_iface);
+-		g_string_append (pppoe_arg, quoted);
+-		g_free (quoted);
++		dev_str = g_strdup_printf ("nic-%s", priv->parent_iface);
++		nm_cmd_line_add_string (cmd, dev_str);
++		g_free (dev_str);
+ 
+ 		pppoe_service = nm_setting_pppoe_get_service (pppoe);
+ 		if (pppoe_service) {
+-			g_string_append (pppoe_arg, " -S ");
+-			quoted = g_shell_quote (pppoe_service);
+-			g_string_append (pppoe_arg, quoted);
+-			g_free (quoted);
++			nm_cmd_line_add_string (cmd, "rp_pppoe_service");
++			nm_cmd_line_add_string (cmd, pppoe_service);
+ 		}
+-
+-		nm_cmd_line_add_string (cmd, "pty");
+-		nm_cmd_line_add_string (cmd, pppoe_arg->str);
+-
+-		g_string_free (pppoe_arg, TRUE);
+ 	} else if (adsl) {
+ 		const gchar *protocol = nm_setting_adsl_get_protocol (adsl);
+ 
+@@ -945,14 +928,9 @@ create_pppd_cmd_line (NMPPPManager *self,
+ 				nm_cmd_line_add_string (cmd, "vc-encaps");
+ 
+ 		} else if (!strcmp (protocol, NM_SETTING_ADSL_PROTOCOL_PPPOE)) {
+-			char *pppoe_arg;
+-
+-			g_assert (pppoe_binary != NULL);
+-
+-			pppoe_arg = g_strdup_printf ("%s -I %s", pppoe_binary, priv->parent_iface);
+-			nm_cmd_line_add_string (cmd, "pty");
+-			nm_cmd_line_add_string (cmd, pppoe_arg);
+-			g_free (pppoe_arg);
++			nm_cmd_line_add_string (cmd, "plugin");
++			nm_cmd_line_add_string (cmd, "rp-pppoe.so");
++			nm_cmd_line_add_string (cmd, priv->parent_iface);
+ 		}
+ 
+ 		nm_cmd_line_add_string (cmd, "noipdefault");
diff --git a/debian/patches/series b/debian/patches/series
index 7deb8a91..f3e09620 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -11,3 +11,4 @@ Don-t-block-network.target-on-NetworkManager-wait-on.patch
 Fix-iscsiadm-path.patch
 crypto-only-use-gnutls-crypto-API-remove-libgcrypt-d.patch
 core-fix-failure-to-configure-routes-due-to-wrong-device-.patch
+Revert-ppp-manager-don-t-use-kernel-pppoe-rh-1034860-rh-1.patch
diff --git a/debian/rules b/debian/rules
index 5a493f38..694cf907 100755
--- a/debian/rules
+++ b/debian/rules
@@ -20,7 +20,6 @@ override_dh_auto_configure:
 		--libexecdir=/usr/lib/NetworkManager \
 		--with-pppd-plugin-dir=$(PPPD_PLUGIN_DIR) \
 		--with-pppd=/usr/sbin/pppd \
-		--with-pppoe=/usr/sbin/pppoe \
 		--with-resolvconf=/sbin/resolvconf \
 		--with-dhclient=/sbin/dhclient \
 		--with-iptables=/sbin/iptables \