Skip to contentSkip to conversation

pull request: WAN

PATCH In review Krzysztof Halasa 2 participants 7 messages Jul 19, 2008 – Aug 8, 2008

Subsystems (8)
lore
Share & tools
lore

Krzysztof Halasa

author maintainer
#0 lore raw

PATCH 1/1 pull request: WAN

Hi Jeff,

Please pull from:
git://git.kernel.org/pub/scm/linux/kernel/git/chris/linux-2.6.git hdlc

This is based on pure v2.6.26 and includes various WAN cleanups as well as LMC, Zilog (hostess_sv11 + sealevel = z85230) and Cosa drivers ported from syncppp to generic HDLC. I have no hardware for that so - untested.

This makes hdlc-ppp the only user of syncppp.

My plan is to replace hdlc-ppp and syncppp with the new hdlc-ppp, hope that's now ok with syncppp going.

The long-term plan is to also add generic PPP interface so users can do PPP auth, compression and what not. 2.6.30+ maybe.

I have tried to test-merge your upstream-next branch and it causes conflicts in drivers/net/wan/pc300_drv.c (a trivial one) and net/netfilter/nf_conntrack_proto_tcp.c (some pre-2.6.26 thing I guess).

The first commits in my tree (after v2.6.26) are already in your tree, you've got them by mail. It seems that git knows that.

Thanks.

 Documentation/DocBook/z8530book.tmpl |   38 ++-
 drivers/char/pcmcia/synclink_cs.c    |   32 +-
 drivers/char/synclink.c              |   37 ++-
 drivers/char/synclink_gt.c           |   33 +-
 drivers/char/synclinkmp.c            |   35 +-
 drivers/net/wan/Kconfig              |   13 +-
 drivers/net/wan/Makefile             |   11 +-
 drivers/net/wan/c101.c               |    6 +-
 drivers/net/wan/cosa.c               |  293 +++++++++-------
 drivers/net/wan/dscc4.c              |   23 +-
 drivers/net/wan/farsync.c            |   75 +++--
 drivers/net/wan/farsync.h            |    6 +
 drivers/net/wan/hd6457x.c            |   33 +-
 drivers/net/wan/hdlc.c               |   27 +-
 drivers/net/wan/hdlc_cisco.c         |   33 +-
 drivers/net/wan/hdlc_fr.c            |   73 +++--
 drivers/net/wan/hdlc_ppp.c           |   15 +-
 drivers/net/wan/hdlc_raw.c           |   15 +-
 drivers/net/wan/hdlc_raw_eth.c       |   19 +-
 drivers/net/wan/hdlc_x25.c           |   23 +-
 drivers/net/wan/hostess_sv11.c       |  382 ++++++++++++--------
 drivers/net/wan/lmc/lmc.h            |   11 +-
 drivers/net/wan/lmc/lmc_debug.c      |    7 +-
 drivers/net/wan/lmc/lmc_debug.h      |    6 +-
 drivers/net/wan/lmc/lmc_ioctl.h      |    2 +-
 drivers/net/wan/lmc/lmc_main.c       |  672 +++++++++++++++++++---------------
 drivers/net/wan/lmc/lmc_media.c      |   66 ++--
 drivers/net/wan/lmc/lmc_proto.c      |  146 ++++++--
 drivers/net/wan/lmc/lmc_proto.h      |   14 +-
 drivers/net/wan/lmc/lmc_var.h        |  360 ++++++++++++-------
 drivers/net/wan/pc300.h              |  228 +++++++-----
 drivers/net/wan/pc300_drv.c          |  217 +++++++-----
 drivers/net/wan/pc300_tty.c          |    6 +-
 drivers/net/wan/sealevel.c           |  361 +++++++++++-------
 drivers/net/wan/syncppp.c            |    9 +
 drivers/net/wan/wanxl.c              |   26 +-
 drivers/net/wan/z85230.c             |  193 ++++++----
 drivers/net/wan/z85230.h             |   10 +-
 include/linux/hdlc.h                 |    7 +
 include/net/syncppp.h                |    2 +
 net/wanrouter/wanmain.c              |   27 ++
Signature · 1 line
Krzysztof Halasa
#1 lore raw
Quoted 18 lines · Krzysztof Halasa

Hi Jeff,

Please pull from:
git://git.kernel.org/pub/scm/linux/kernel/git/chris/linux-2.6.git hdlc

This is based on pure v2.6.26 and includes various WAN cleanups as well as LMC, Zilog (hostess_sv11 + sealevel = z85230) and Cosa drivers ported from syncppp to generic HDLC. I have no hardware for that so - untested.

This makes hdlc-ppp the only user of syncppp.

My plan is to replace hdlc-ppp and syncppp with the new hdlc-ppp, hope that's now ok with syncppp going.

The long-term plan is to also add generic PPP interface so users can do PPP auth, compression and what not. 2.6.30+ maybe.

Quoted 7 lines

I have tried to test-merge your upstream-next branch and it causes conflicts in drivers/net/wan/pc300_drv.c (a trivial one) and net/netfilter/nf_conntrack_proto_tcp.c (some pre-2.6.26 thing I guess).

The first commits in my tree (after v2.6.26) are already in your tree, you've got them by mail. It seems that git knows that.

Anything in upstream-next went upstream, and so we need to apply this on top of the current Linus upstream (torvalds/linux-2.6.git) at the very least.

Would you mind doing that, please?

Also, git pulls are great, but it would be helpful if you supply a git-shortlog summary of the changes, and the patch (>400k will only go to me, list will ignore).

Jeff

author maintainer
#2 lore raw
Quoted 5 lines · Jeff Garzik

Anything in upstream-next went upstream, and so we need to apply this on top of the current Linus upstream (torvalds/linux-2.6.git) at the very least.

Would you mind doing that, please?

No problem, though I guess David would hate us both if I do that, so I actually rebased on top of your "upstream" instead, is it ok?

It's now at:

git://git.kernel.org/pub/scm/linux/kernel/git/chris/linux-2.6.git for-jeff

Quoted 3 lines

Also, git pulls are great, but it would be helpful if you supply a git-shortlog summary of the changes, and the patch (>400k will only go to me, list will ignore).

Sure,

Krzysztof Hałasa (15):
WAN: cosmetic changes to generic HDLC
Remove bogus dosyncppp variable from synclink drivers. Remove bogus variables from syncppp.[ch]
Remove dead code from wanmain.c, CONFIG_WANPIPE_MULTPPP doesn't exist wanmain.c doesn't need syncppp.h
WAN: Remove unneeded "#include <net/syncppp.h>"
WAN: Remove dead code from PC300 driver, part #1
WAN: Remove dead code from PC300 driver, part #2
WAN: Convert PC300 driver to use normal u8/u16/u32 types
WAN: farsync driver no longer uses syncppp.c directly
WAN: Port COSA driver to generic HDLC.
WAN: Convert Zilog-based drivers to generic HDLC
WAN: Port LMC driver to generic HDLC
WAN: don't mention syncppp in z8530 DocBook.
WAN: Use u32 type instead of u_int32_t in LMC driver.

The combined patch follows.

Signature · 1 line
Krzysztof Halasa
author maintainer
#3 lore raw

git://git.kernel.org/pub/scm/linux/kernel/git/chris/linux-2.6.git for-jeff vs your "upstream" branch:

 Documentation/DocBook/z8530book.tmpl |   38 +--
 drivers/char/pcmcia/synclink_cs.c    |    4 -
 drivers/char/synclink.c              |    4 -
 drivers/char/synclink_gt.c           |    5 -
 drivers/char/synclinkmp.c            |    4 -
 drivers/net/wan/Kconfig              |   13 +-
 drivers/net/wan/Makefile             |   11 +-
 drivers/net/wan/cosa.c               |  293 +++++++---------
 drivers/net/wan/dscc4.c              |    1 -
 drivers/net/wan/farsync.c            |    5 +-
 drivers/net/wan/farsync.h            |    6 -
 drivers/net/wan/hdlc.c               |   25 +-
 drivers/net/wan/hdlc_cisco.c         |   29 +-
 drivers/net/wan/hdlc_fr.c            |   19 +-
 drivers/net/wan/hdlc_ppp.c           |   15 +-
 drivers/net/wan/hdlc_raw.c           |   15 +-
 drivers/net/wan/hdlc_raw_eth.c       |   17 +-
 drivers/net/wan/hdlc_x25.c           |   17 +-
 drivers/net/wan/hostess_sv11.c       |  382 ++++++++------------
 drivers/net/wan/lmc/lmc.h            |   11 +-
 drivers/net/wan/lmc/lmc_debug.c      |    7 +-
 drivers/net/wan/lmc/lmc_debug.h      |    6 +-
 drivers/net/wan/lmc/lmc_ioctl.h      |    2 +-
 drivers/net/wan/lmc/lmc_main.c       |  672 +++++++++++++++-------------------
 drivers/net/wan/lmc/lmc_media.c      |   66 ++--
 drivers/net/wan/lmc/lmc_proto.c      |  146 ++------
 drivers/net/wan/lmc/lmc_proto.h      |   14 +-
 drivers/net/wan/lmc/lmc_var.h        |  360 +++++++------------
 drivers/net/wan/pc300.h              |  228 +++++-------
 drivers/net/wan/pc300_drv.c          |  146 ++++----
 drivers/net/wan/sealevel.c           |  361 +++++++-----------
 drivers/net/wan/syncppp.c            |    9 -
 drivers/net/wan/z85230.c             |  193 ++++------
 drivers/net/wan/z85230.h             |   10 +-
 include/net/syncppp.h                |    2 -
 net/wanrouter/wanmain.c              |   27 --
 36 files changed, 1245 insertions(+), 1918 deletions(-)
Documentation/DocBook/z8530book.tmpl +12 -26
index 42c75ba..a42a8a4 100644
@@ -69,12 +69,6 @@
 	device to be used as both a tty interface and as a synchronous 
 	controller is a project for Linux post the 2.4 release
   </para>
-  <para>
-	The support code handles most common card configurations and
-	supports running both Cisco HDLC and Synchronous PPP. With extra
-	glue the frame relay and X.25 protocols can also be used with this
-	driver.
-  </para>
   </chapter>
   
   <chapter id="Driver_Modes">
@@ -179,35 +173,27 @@
   <para>
 	If you wish to use the network interface facilities of the driver,
 	then you need to attach a network device to each channel that is
-	present and in use. In addition to use the SyncPPP and Cisco HDLC
+	present and in use. In addition to use the generic HDLC
 	you need to follow some additional plumbing rules. They may seem 
 	complex but a look at the example hostess_sv11 driver should
 	reassure you.
   </para>
   <para>
 	The network device used for each channel should be pointed to by
-	the netdevice field of each channel. The dev-&gt; priv field of the
+	the netdevice field of each channel. The hdlc-&gt; priv field of the
 	network device points to your private data - you will need to be
-	able to find your ppp device from this. In addition to use the
-	sync ppp layer the private data must start with a void * pointer
-	to the syncppp structures.
+	able to find your private data from this.
   </para>
   <para>
 	The way most drivers approach this particular problem is to
 	create a structure holding the Z8530 device definition and
-	put that and the syncppp pointer into the private field of
-	the network device. The network device fields of the channels
-	then point back to the network devices. The ppp_device can also
-	be put in the private structure conveniently.
+	put that into the private field of the network device. The
+	network device fields of the channels then point back to the
+	network devices.
   </para>
   <para>
-	If you wish to use the synchronous ppp then you need to attach
-	the syncppp layer to the network device. You should do this before
-	you register the network device. The
-	<function>sppp_attach</function> requires that the first void *
-	pointer in your private data is pointing to an empty struct
-	ppp_device. The function fills in the initial data for the
-	ppp/hdlc layer.
+	If you wish to use the generic HDLC then you need to register
+	the HDLC device.
   </para>
   <para>
 	Before you register your network device you will also need to
@@ -314,10 +300,10 @@
 	buffer in sk_buff format and queues it for transmission. The
 	caller must provide the entire packet with the exception of the
 	bitstuffing and CRC. This is normally done by the caller via
-	the syncppp interface layer. It returns 0 if the buffer has been 
-        queued and non zero values  for queue full. If the function accepts 
-	the buffer it becomes property of the Z8530 layer and the caller 
-	should not free it. 
+	the generic HDLC interface layer. It returns 0 if the buffer has been
+	queued and non zero values for queue full. If the function accepts
+	the buffer it becomes property of the Z8530 layer and the caller
+	should not free it.
   </para>
   <para>
 	The function <function>z8530_get_stats</function> returns a pointer
drivers/char/pcmcia/synclink_cs.c +0 -4
index b694d43..36a0afa 100644
@@ -232,7 +232,6 @@ typedef struct _mgslpc_info {
 
 	/* SPPP/Cisco HDLC device parts */
 	int netcount;
-	int dosyncppp;
 	spinlock_t netlock;
 
 #if SYNCLINK_GENERIC_HDLC
@@ -459,13 +458,11 @@ static int ttymajor=0;
 
 static int debug_level = 0;
 static int maxframe[MAX_DEVICE_COUNT] = {0,};
-static int dosyncppp[MAX_DEVICE_COUNT] = {1,1,1,1};
 
 module_param(break_on_load, bool, 0);
 module_param(ttymajor, int, 0);
 module_param(debug_level, int, 0);
 module_param_array(maxframe, int, NULL, 0);
-module_param_array(dosyncppp, int, NULL, 0);
 
 MODULE_LICENSE("GPL");
 
@@ -2914,7 +2911,6 @@ static void mgslpc_add_device(MGSLPC_INFO *info)
 	if (info->line < MAX_DEVICE_COUNT) {
 		if (maxframe[info->line])
 			info->max_frame_size = maxframe[info->line];
-		info->dosyncppp = dosyncppp[info->line];
 	}
 
 	mgslpc_device_count++;
drivers/char/synclink.c +0 -4
index 527d220..2b9e930 100644
@@ -304,7 +304,6 @@ struct mgsl_struct {
 
 	/* generic HDLC device parts */
 	int netcount;
-	int dosyncppp;
 	spinlock_t netlock;
 
 #if SYNCLINK_GENERIC_HDLC
@@ -868,7 +867,6 @@ static int irq[MAX_ISA_DEVICES];
 static int dma[MAX_ISA_DEVICES];
 static int debug_level;
 static int maxframe[MAX_TOTAL_DEVICES];
-static int dosyncppp[MAX_TOTAL_DEVICES];
 static int txdmabufs[MAX_TOTAL_DEVICES];
 static int txholdbufs[MAX_TOTAL_DEVICES];
 	
@@ -879,7 +877,6 @@ module_param_array(irq, int, NULL, 0);
 module_param_array(dma, int, NULL, 0);
 module_param(debug_level, int, 0);
 module_param_array(maxframe, int, NULL, 0);
-module_param_array(dosyncppp, int, NULL, 0);
 module_param_array(txdmabufs, int, NULL, 0);
 module_param_array(txholdbufs, int, NULL, 0);
 
@@ -4257,7 +4254,6 @@ static void mgsl_add_device( struct mgsl_struct *info )
 	if (info->line < MAX_TOTAL_DEVICES) {
 		if (maxframe[info->line])
 			info->max_frame_size = maxframe[info->line];
-		info->dosyncppp = dosyncppp[info->line];
 
 		if (txdmabufs[info->line]) {
 			info->num_tx_dma_buffers = txdmabufs[info->line];
drivers/char/synclink_gt.c +0 -5
index 2c3e43b..88083b0 100644
@@ -128,17 +128,14 @@ static int slgt_device_count;
 static int ttymajor;
 static int debug_level;
 static int maxframe[MAX_DEVICES];
-static int dosyncppp[MAX_DEVICES];
 
 module_param(ttymajor, int, 0);
 module_param(debug_level, int, 0);
 module_param_array(maxframe, int, NULL, 0);
-module_param_array(dosyncppp, int, NULL, 0);
 
 MODULE_PARM_DESC(ttymajor, "TTY major device number override: 0=auto assigned");
 MODULE_PARM_DESC(debug_level, "Debug syslog output: 0=disabled, 1 to 5=increasing detail");
 MODULE_PARM_DESC(maxframe, "Maximum frame size used by device (4096 to 65535)");
-MODULE_PARM_DESC(dosyncppp, "Enable synchronous net device, 0=disable 1=enable");
 
 /*
  * tty support and callbacks
@@ -348,7 +345,6 @@ struct slgt_info {
 	/* SPPP/Cisco HDLC device parts */
 
 	int netcount;
-	int dosyncppp;
 	spinlock_t netlock;
 #if SYNCLINK_GENERIC_HDLC
 	struct net_device *netdev;
@@ -3385,7 +3381,6 @@ static void add_device(struct slgt_info *info)
 	if (info->line < MAX_DEVICES) {
 		if (maxframe[info->line])
 			info->max_frame_size = maxframe[info->line];
-		info->dosyncppp = dosyncppp[info->line];
 	}
 
 	slgt_device_count++;
drivers/char/synclinkmp.c +0 -4
index 5768c41..f2edfad 100644
@@ -270,7 +270,6 @@ typedef struct _synclinkmp_info {
 
 	/* SPPP/Cisco HDLC device parts */
 	int netcount;
-	int dosyncppp;
 	spinlock_t netlock;
 
 #if SYNCLINK_GENERIC_HDLC
@@ -469,13 +468,11 @@ static int ttymajor = 0;
  */
 static int debug_level = 0;
 static int maxframe[MAX_DEVICES] = {0,};
-static int dosyncppp[MAX_DEVICES] = {0,};
 
 module_param(break_on_load, bool, 0);
 module_param(ttymajor, int, 0);
 module_param(debug_level, int, 0);
 module_param_array(maxframe, int, NULL, 0);
-module_param_array(dosyncppp, int, NULL, 0);
 
 static char *driver_name = "SyncLink MultiPort driver";
 static char *driver_version = "$Revision: 4.38 $";
@@ -3751,7 +3748,6 @@ static void add_device(SLMP_INFO *info)
 	if (info->line < MAX_DEVICES) {
 		if (maxframe[info->line])
 			info->max_frame_size = maxframe[info->line];
-		info->dosyncppp = dosyncppp[info->line];
 	}
 
 	synclinkmp_device_count++;
drivers/net/wan/Kconfig +6 -7
index 846be60..766b8bf 100644
@@ -25,7 +25,7 @@ if WAN
 # There is no way to detect a comtrol sv11 - force it modular for now.
 config HOSTESS_SV11
 	tristate "Comtrol Hostess SV-11 support"
-	depends on ISA && m && ISA_DMA_API && INET
+	depends on ISA && m && ISA_DMA_API && INET && HDLC
 	help
 	  Driver for Comtrol Hostess SV-11 network card which
 	  operates on low speed synchronous serial links at up to
@@ -37,7 +37,7 @@ config HOSTESS_SV11
 # The COSA/SRP driver has not been tested as non-modular yet.
 config COSA
 	tristate "COSA/SRP sync serial boards support"
-	depends on ISA && m && ISA_DMA_API
+	depends on ISA && m && ISA_DMA_API && HDLC
 	---help---
 	  Driver for COSA and SRP synchronous serial boards.
 
@@ -61,7 +61,7 @@ config COSA
 #
 config LANMEDIA
 	tristate "LanMedia Corp. SSI/V.35, T1/E1, HSSI, T3 boards"
-	depends on PCI && VIRT_TO_BUS
+	depends on PCI && VIRT_TO_BUS && HDLC
 	---help---
 	  Driver for the following Lan Media family of serial boards:
 
@@ -78,9 +78,8 @@ config LANMEDIA
 	  - LMC 5245 board connects directly to a T3 circuit saving the
 	  additional external hardware.
 
-	  To change setting such as syncPPP vs Cisco HDLC or clock source you
-	  will need lmcctl.  It is available at <ftp://ftp.lanmedia.com/>
-	  (broken link).
+	  To change setting such as clock source you will need lmcctl.
+	  It is available at <ftp://ftp.lanmedia.com/> (broken link).
 
 	  To compile this driver as a module, choose M here: the
 	  module will be called lmc.
@@ -88,7 +87,7 @@ config LANMEDIA
 # There is no way to detect a Sealevel board. Force it modular
 config SEALEVEL_4021
 	tristate "Sealevel Systems 4021 support"
-	depends on ISA && m && ISA_DMA_API && INET
+	depends on ISA && m && ISA_DMA_API && INET && HDLC
 	help
 	  This is a driver for the Sealevel Systems ACB 56 serial I/O adapter.
 
drivers/net/wan/Makefile +5 -6
index d61fef3..1025496 100644
@@ -21,12 +21,11 @@ pc300-y				:= pc300_drv.o
 pc300-$(CONFIG_PC300_MLPPP)	+= pc300_tty.o
 pc300-objs			:= $(pc300-y)
 
-obj-$(CONFIG_HOSTESS_SV11)	+= z85230.o	syncppp.o	hostess_sv11.o
-obj-$(CONFIG_SEALEVEL_4021)	+= z85230.o	syncppp.o	sealevel.o
-obj-$(CONFIG_COSA)		+=		syncppp.o	cosa.o
-obj-$(CONFIG_FARSYNC)		+=		syncppp.o	farsync.o
-obj-$(CONFIG_DSCC4)             +=				dscc4.o
-obj-$(CONFIG_LANMEDIA)		+=		syncppp.o
+obj-$(CONFIG_HOSTESS_SV11)	+= z85230.o	hostess_sv11.o
+obj-$(CONFIG_SEALEVEL_4021)	+= z85230.o	sealevel.o
+obj-$(CONFIG_COSA)		+= cosa.o
+obj-$(CONFIG_FARSYNC)		+= farsync.o
+obj-$(CONFIG_DSCC4)             += dscc4.o
 obj-$(CONFIG_X25_ASY)		+= x25_asy.o
 
 obj-$(CONFIG_LANMEDIA)		+= lmc/
drivers/net/wan/cosa.c +128 -165

518 lines not on this page · raw message

drivers/net/wan/dscc4.c +0 -1
index 50ef5b4..f5d55ad 100644
@@ -103,7 +103,6 @@
 #include <linux/netdevice.h>
 #include <linux/skbuff.h>
 #include <linux/delay.h>
-#include <net/syncppp.h>
 #include <linux/hdlc.h>
 #include <linux/mutex.h>
 
drivers/net/wan/farsync.c +1 -4
index 754f008..9557ad0 100644
@@ -47,10 +47,7 @@ MODULE_LICENSE("GPL");
 /*      Default parameters for the link
  */
 #define FST_TX_QUEUE_LEN        100	/* At 8Mbps a longer queue length is
-					 * useful, the syncppp module forces
-					 * this down assuming a slower line I
-					 * guess.
-					 */
+					 * useful */
 #define FST_TXQ_DEPTH           16	/* This one is for the buffering
 					 * of frames on the way down to the card
 					 * so that we can keep the card busy
drivers/net/wan/farsync.h +0 -6
index d871daf..6b27e7c 100644
@@ -54,9 +54,6 @@
 
 
 /*      Ioctl call command values
- *
- *      The first three private ioctls are used by the sync-PPP module,
- *      allowing a little room for expansion we start our numbering at 10.
  */
 #define FSTWRITE        (SIOCDEVPRIVATE+10)
 #define FSTCPURESET     (SIOCDEVPRIVATE+11)
@@ -202,9 +199,6 @@ struct fstioc_info {
 #define J1              7
 
 /* "proto" */
-#define FST_HDLC        1               /* Cisco compatible HDLC */
-#define FST_PPP         2               /* Sync PPP */
-#define FST_MONITOR     3               /* Monitor only (raw packet reception) */
 #define FST_RAW         4               /* Two way raw packets */
 #define FST_GEN_HDLC    5               /* Using "Generic HDLC" module */
 
drivers/net/wan/hdlc.c +12 -13
index e3a5364..1f2a140 100644
@@ -22,20 +22,19 @@
  * - proto->start() and stop() are called with spin_lock_irq held.
  */
 
-#include <linux/module.h>
-#include <linux/kernel.h>
-#include <linux/slab.h>
-#include <linux/poll.h>
 #include <linux/errno.h>
+#include <linux/hdlc.h>
 #include <linux/if_arp.h>
+#include <linux/inetdevice.h>
 #include <linux/init.h>
-#include <linux/skbuff.h>
+#include <linux/kernel.h>
+#include <linux/module.h>
+#include <linux/notifier.h>
 #include <linux/pkt_sched.h>
-#include <linux/inetdevice.h>
-#include <linux/lapb.h>
+#include <linux/poll.h>
 #include <linux/rtnetlink.h>
-#include <linux/notifier.h>
-#include <linux/hdlc.h>
+#include <linux/skbuff.h>
+#include <linux/slab.h>
 #include <net/net_namespace.h>
 
 
@@ -109,7 +108,7 @@ static int hdlc_device_event(struct notifier_block *this, unsigned long event,
 
 	if (dev->get_stats != hdlc_get_stats)
 		return NOTIFY_DONE; /* not an HDLC device */
- 
+
 	if (event != NETDEV_CHANGE)
 		return NOTIFY_DONE; /* Only interrested in carrier changes */
 
@@ -357,7 +356,7 @@ static struct packet_type hdlc_packet_type = {
 
 
 static struct notifier_block hdlc_notifier = {
-        .notifier_call = hdlc_device_event,
+	.notifier_call = hdlc_device_event,
 };
 
 
@@ -367,8 +366,8 @@ static int __init hdlc_module_init(void)
 
 	printk(KERN_INFO "%s\n", version);
 	if ((result = register_netdevice_notifier(&hdlc_notifier)) != 0)
-                return result;
-        dev_add_pack(&hdlc_packet_type);
+		return result;
+	dev_add_pack(&hdlc_packet_type);
 	return 0;
 }
 
drivers/net/wan/hdlc_cisco.c +14 -15
index 849819c..44e64b1 100644
@@ -9,19 +9,18 @@
  * as published by the Free Software Foundation.
  */
 
-#include <linux/module.h>
-#include <linux/kernel.h>
-#include <linux/slab.h>
-#include <linux/poll.h>
 #include <linux/errno.h>
+#include <linux/hdlc.h>
 #include <linux/if_arp.h>
+#include <linux/inetdevice.h>
 #include <linux/init.h>
-#include <linux/skbuff.h>
+#include <linux/kernel.h>
+#include <linux/module.h>
 #include <linux/pkt_sched.h>
-#include <linux/inetdevice.h>
-#include <linux/lapb.h>
+#include <linux/poll.h>
 #include <linux/rtnetlink.h>
-#include <linux/hdlc.h>
+#include <linux/skbuff.h>
+#include <linux/slab.h>
 
 #undef DEBUG_HARD_HEADER
 
@@ -68,9 +67,9 @@ struct cisco_state {
 static int cisco_ioctl(struct net_device *dev, struct ifreq *ifr);
 
 
-static inline struct cisco_state * state(hdlc_device *hdlc)
+static inline struct cisco_state* state(hdlc_device *hdlc)
 {
-	return(struct cisco_state *)(hdlc->state);
+	return (struct cisco_state *)hdlc->state;
 }
 
 
@@ -172,7 +171,7 @@ static int cisco_rx(struct sk_buff *skb)
 	    data->address != CISCO_UNICAST)
 		goto rx_error;
 
-	switch(ntohs(data->protocol)) {
+	switch (ntohs(data->protocol)) {
 	case CISCO_SYS_INFO:
 		/* Packet is not needed, drop it. */
 		dev_kfree_skb_any(skb);
@@ -336,7 +335,7 @@ static struct hdlc_proto proto = {
 static const struct header_ops cisco_header_ops = {
 	.create = cisco_hard_header,
 };
- 
+
 static int cisco_ioctl(struct net_device *dev, struct ifreq *ifr)
 {
 	cisco_proto __user *cisco_s = ifr->ifr_settings.ifs_ifsu.cisco;
@@ -359,10 +358,10 @@ static int cisco_ioctl(struct net_device *dev, struct ifreq *ifr)
 		return 0;
 
 	case IF_PROTO_CISCO:
-		if(!capable(CAP_NET_ADMIN))
+		if (!capable(CAP_NET_ADMIN))
 			return -EPERM;
 
-		if(dev->flags & IFF_UP)
+		if (dev->flags & IFF_UP)
 			return -EBUSY;
 
 		if (copy_from_user(&new_settings, cisco_s, size))
@@ -372,7 +371,7 @@ static int cisco_ioctl(struct net_device *dev, struct ifreq *ifr)
 		    new_settings.timeout < 2)
 			return -EINVAL;
 
-		result=hdlc->attach(dev, ENCODING_NRZ,PARITY_CRC16_PR1_CCITT);
+		result = hdlc->attach(dev, ENCODING_NRZ,PARITY_CRC16_PR1_CCITT);
 		if (result)
 			return result;
 
drivers/net/wan/hdlc_fr.c +9 -10
index 62e93da..d3d5055 100644
@@ -33,20 +33,19 @@
 
 */
 
-#include <linux/module.h>
-#include <linux/kernel.h>
-#include <linux/slab.h>
-#include <linux/poll.h>
 #include <linux/errno.h>
+#include <linux/etherdevice.h>
+#include <linux/hdlc.h>
 #include <linux/if_arp.h>
+#include <linux/inetdevice.h>
 #include <linux/init.h>
-#include <linux/skbuff.h>
+#include <linux/kernel.h>
+#include <linux/module.h>
 #include <linux/pkt_sched.h>
-#include <linux/inetdevice.h>
-#include <linux/lapb.h>
+#include <linux/poll.h>
 #include <linux/rtnetlink.h>
-#include <linux/etherdevice.h>
-#include <linux/hdlc.h>
+#include <linux/skbuff.h>
+#include <linux/slab.h>
 
 #undef DEBUG_PKT
 #undef DEBUG_ECN
@@ -96,7 +95,7 @@ typedef struct {
 	unsigned ea1:	1;
 	unsigned cr:	1;
 	unsigned dlcih:	6;
-  
+
 	unsigned ea2:	1;
 	unsigned de:	1;
 	unsigned becn:	1;
drivers/net/wan/hdlc_ppp.c +7 -8
index 0030833..4efe9e6 100644
@@ -9,19 +9,18 @@
  * as published by the Free Software Foundation.
  */
 
-#include <linux/module.h>
-#include <linux/kernel.h>
-#include <linux/slab.h>
-#include <linux/poll.h>
 #include <linux/errno.h>
+#include <linux/hdlc.h>
 #include <linux/if_arp.h>
+#include <linux/inetdevice.h>
 #include <linux/init.h>
-#include <linux/skbuff.h>
+#include <linux/kernel.h>
+#include <linux/module.h>
 #include <linux/pkt_sched.h>
-#include <linux/inetdevice.h>
-#include <linux/lapb.h>
+#include <linux/poll.h>
 #include <linux/rtnetlink.h>
-#include <linux/hdlc.h>
+#include <linux/skbuff.h>
+#include <linux/slab.h>
 #include <net/syncppp.h>
 
 struct ppp_state {
drivers/net/wan/hdlc_raw.c +7 -8
index bbbb819..8612311 100644
@@ -9,19 +9,18 @@
  * as published by the Free Software Foundation.
  */
 
-#include <linux/module.h>
-#include <linux/kernel.h>
-#include <linux/slab.h>
-#include <linux/poll.h>
 #include <linux/errno.h>
+#include <linux/hdlc.h>
 #include <linux/if_arp.h>
+#include <linux/inetdevice.h>
 #include <linux/init.h>
-#include <linux/skbuff.h>
+#include <linux/kernel.h>
+#include <linux/module.h>
 #include <linux/pkt_sched.h>
-#include <linux/inetdevice.h>
-#include <linux/lapb.h>
+#include <linux/poll.h>
 #include <linux/rtnetlink.h>
-#include <linux/hdlc.h>
+#include <linux/skbuff.h>
+#include <linux/slab.h>
 
 
 static int raw_ioctl(struct net_device *dev, struct ifreq *ifr);
drivers/net/wan/hdlc_raw_eth.c +8 -9
index 26dee60..a13fc32 100644
@@ -9,20 +9,19 @@
  * as published by the Free Software Foundation.
  */
 
-#include <linux/module.h>
-#include <linux/kernel.h>
-#include <linux/slab.h>
-#include <linux/poll.h>
 #include <linux/errno.h>
+#include <linux/etherdevice.h>
+#include <linux/hdlc.h>
 #include <linux/if_arp.h>
+#include <linux/inetdevice.h>
 #include <linux/init.h>
-#include <linux/skbuff.h>
+#include <linux/kernel.h>
+#include <linux/module.h>
 #include <linux/pkt_sched.h>
-#include <linux/inetdevice.h>
-#include <linux/lapb.h>
+#include <linux/poll.h>
 #include <linux/rtnetlink.h>
-#include <linux/etherdevice.h>
-#include <linux/hdlc.h>
+#include <linux/skbuff.h>
+#include <linux/slab.h>
 
 static int raw_eth_ioctl(struct net_device *dev, struct ifreq *ifr);
 
drivers/net/wan/hdlc_x25.c +8 -9
index e808720..8b7e5d2 100644
@@ -9,20 +9,19 @@
  * as published by the Free Software Foundation.
  */
 
-#include <linux/module.h>
-#include <linux/kernel.h>
-#include <linux/slab.h>
-#include <linux/poll.h>
 #include <linux/errno.h>
+#include <linux/hdlc.h>
 #include <linux/if_arp.h>
-#include <linux/init.h>
-#include <linux/skbuff.h>
-#include <linux/pkt_sched.h>
 #include <linux/inetdevice.h>
+#include <linux/init.h>
+#include <linux/kernel.h>
 #include <linux/lapb.h>
+#include <linux/module.h>
+#include <linux/pkt_sched.h>
+#include <linux/poll.h>
 #include <linux/rtnetlink.h>
-#include <linux/hdlc.h>
-
+#include <linux/skbuff.h>
+#include <linux/slab.h>
 #include <net/x25device.h>
 
 static int x25_ioctl(struct net_device *dev, struct ifreq *ifr);
drivers/net/wan/hostess_sv11.c +154 -228

540 lines not on this page · raw message

drivers/net/wan/lmc/lmc.h +5 -6
index 882e58c..4ced7ac 100644
@@ -11,12 +11,12 @@ unsigned lmc_mii_readreg(lmc_softc_t * const sc, unsigned
       			  devaddr, unsigned regno);
 void lmc_mii_writereg(lmc_softc_t * const sc, unsigned devaddr,
 			       unsigned regno, unsigned data);
-void lmc_led_on(lmc_softc_t * const, u_int32_t);
-void lmc_led_off(lmc_softc_t * const, u_int32_t);
+void lmc_led_on(lmc_softc_t * const, u32);
+void lmc_led_off(lmc_softc_t * const, u32);
 unsigned lmc_mii_readreg(lmc_softc_t * const, unsigned, unsigned);
 void lmc_mii_writereg(lmc_softc_t * const, unsigned, unsigned, unsigned);
-void lmc_gpio_mkinput(lmc_softc_t * const sc, u_int32_t bits);
-void lmc_gpio_mkoutput(lmc_softc_t * const sc, u_int32_t bits);
+void lmc_gpio_mkinput(lmc_softc_t * const sc, u32 bits);
+void lmc_gpio_mkoutput(lmc_softc_t * const sc, u32 bits);
 
 int lmc_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd);
 
@@ -26,8 +26,7 @@ extern lmc_media_t lmc_t1_media;
 extern lmc_media_t lmc_hssi_media;
 
 #ifdef _DBG_EVENTLOG
-static void lmcEventLog( u_int32_t EventNum, u_int32_t arg2, u_int32_t arg3 );
+static void lmcEventLog(u32 EventNum, u32 arg2, u32 arg3);
 #endif
 
 #endif
-
drivers/net/wan/lmc/lmc_debug.c +3 -4
index 3b94352..15049d7 100644
@@ -1,4 +1,3 @@
-
 #include <linux/types.h>
 #include <linux/netdevice.h>
 #include <linux/interrupt.h>
@@ -48,10 +47,10 @@ void lmcConsoleLog(char *type, unsigned char *ucData, int iLen)
 #endif
 
 #ifdef DEBUG
-u_int32_t lmcEventLogIndex = 0;
-u_int32_t lmcEventLogBuf[LMC_EVENTLOGSIZE * LMC_EVENTLOGARGS];
+u32 lmcEventLogIndex;
+u32 lmcEventLogBuf[LMC_EVENTLOGSIZE * LMC_EVENTLOGARGS];
 
-void lmcEventLog (u_int32_t EventNum, u_int32_t arg2, u_int32_t arg3)
+void lmcEventLog(u32 EventNum, u32 arg2, u32 arg3)
 {
   lmcEventLogBuf[lmcEventLogIndex++] = EventNum;
   lmcEventLogBuf[lmcEventLogIndex++] = arg2;
drivers/net/wan/lmc/lmc_debug.h +3 -3
index cf35638..2d46f12 100644
@@ -38,15 +38,15 @@
 
 
 #ifdef DEBUG
-extern u_int32_t lmcEventLogIndex;
-extern u_int32_t lmcEventLogBuf[LMC_EVENTLOGSIZE * LMC_EVENTLOGARGS];
+extern u32 lmcEventLogIndex;
+extern u32 lmcEventLogBuf[LMC_EVENTLOGSIZE * LMC_EVENTLOGARGS];
 #define LMC_EVENT_LOG(x, y, z) lmcEventLog((x), (y), (z))
 #else
 #define LMC_EVENT_LOG(x,y,z)
 #endif /* end ifdef _DBG_EVENTLOG */
 
 void lmcConsoleLog(char *type, unsigned char *ucData, int iLen);
-void lmcEventLog (u_int32_t EventNum, u_int32_t arg2, u_int32_t arg3);
+void lmcEventLog(u32 EventNum, u32 arg2, u32 arg3);
 void lmc_trace(struct net_device *dev, char *msg);
 
 #endif
drivers/net/wan/lmc/lmc_ioctl.h +1 -1
index 57dd861..72fb113 100644
@@ -61,7 +61,7 @@
 /*
  * IFTYPE defines
  */
-#define LMC_PPP         1               /* use sppp interface */
+#define LMC_PPP         1               /* use generic HDLC interface */
 #define LMC_NET         2               /* use direct net interface */
 #define LMC_RAW         3               /* use direct net interface */
 
drivers/net/wan/lmc/lmc_main.c +294 -378

1,144 lines not on this page · raw message

drivers/net/wan/lmc/lmc_media.c +27 -39

146 lines not on this page · raw message

drivers/net/wan/lmc/lmc_proto.c +25 -121

35 lines not on this page · raw message

drivers/net/wan/lmc/lmc_proto.h +8 -6
index ccaa69e..662148c 100644

Lines of this file are not shown. View the raw message.

drivers/net/wan/lmc/lmc_var.h +130 -230

360 lines not on this page · raw message

drivers/net/wan/pc300.h +91 -137

228 lines not on this page · raw message

drivers/net/wan/pc300_drv.c +64 -82

146 lines not on this page · raw message

drivers/net/wan/sealevel.c +142 -219

361 lines not on this page · raw message

drivers/net/wan/syncppp.c +0 -9
index 29b4b94..327d585 100644

Lines of this file are not shown. View the raw message.

drivers/net/wan/z85230.c +77 -116

193 lines not on this page · raw message

drivers/net/wan/z85230.h +4 -6
index 158aea7..4f37239 100644

Lines of this file are not shown. View the raw message.

include/net/syncppp.h +0 -2
index e43f407..9e306f7 100644

Lines of this file are not shown. View the raw message.

net/wanrouter/wanmain.c +0 -27
index b210a88..7f07152 100644

Lines of this file are not shown. View the raw message.

The rest of this diff is not shown. View the raw message.

Signature · 1 line
Krzysztof Halasa

Part of the diff is not shown here. View the raw message.

author maintainer
#4 lore raw
In reply to Krzysztof Halasa

Hi Jeff,

Quoted 6 lines · I wrote:

No problem, though I guess David would hate us both if I do that, so I actually rebased on top of your "upstream" instead, is it ok?

It's now at:

git://git.kernel.org/pub/scm/linux/kernel/git/chris/linux-2.6.git for-jeff

How about the above? Is the tree ok?

Signature · 1 line
Krzysztof Halasa
#5 lore raw
In reply to Krzysztof Halasa
Quoted 21 lines · Krzysztof Halasa
Quoted 5 lines · Jeff Garzik

Anything in upstream-next went upstream, and so we need to apply this on top of the current Linus upstream (torvalds/linux-2.6.git) at the very least.

Would you mind doing that, please?

No problem, though I guess David would hate us both if I do that, so I actually rebased on top of your "upstream" instead, is it ok?

It's now at:

git://git.kernel.org/pub/scm/linux/kernel/git/chris/linux-2.6.git for-jeff

Quoted 3 lines

Also, git pulls are great, but it would be helpful if you supply a git-shortlog summary of the changes, and the patch (>400k will only go to me, list will ignore).

Sure,

Quoted 16 lines

Krzysztof Hałasa (15):
WAN: cosmetic changes to generic HDLC
Remove bogus dosyncppp variable from synclink drivers. Remove bogus variables from syncppp.[ch]
Remove dead code from wanmain.c, CONFIG_WANPIPE_MULTPPP doesn't exist wanmain.c doesn't need syncppp.h
WAN: Remove unneeded "#include <net/syncppp.h>"
WAN: Remove dead code from PC300 driver, part #1
WAN: Remove dead code from PC300 driver, part #2
WAN: Convert PC300 driver to use normal u8/u16/u32 types
WAN: farsync driver no longer uses syncppp.c directly
WAN: Port COSA driver to generic HDLC.
WAN: Convert Zilog-based drivers to generic HDLC
WAN: Port LMC driver to generic HDLC
WAN: don't mention syncppp in z8530 DocBook.
WAN: Use u32 type instead of u_int32_t in LMC driver.

pulled

author maintainer
#6 lore raw
Quoted 3 lines · Jeff Garzik

applied

pulled

Thanks.

Signature · 1 line
Krzysztof Halasa