Skip to content

Commit

Permalink
ipwireless: Increase PPP outgoing queue size
Browse files Browse the repository at this point in the history
ipwireless: Increase PPP outgoing queue size

Increase default size of PPP outgoing queue. Currently set to 1, which
means that a packet quickly following another pushed by PPP must wait
until hardware actually sends the previous and PPP has to be waken up
by ppp_wakeup(). This slows down upstream.

Now PPP can push more packets at once which get buffered inside driver
and pushed immediatelly to hardware when previous packet is out.

Experiments show that size = 10 is quite good for all connection types
(GPRS/EDGE/UMTS) and gains 4 KB/sec of upload for UMTS for batch uploads.
Need for higher queue size than 10 occures in only < 0.1 % of cases.

Signed-off-by: David Sterba <dsterba@suse.cz>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
David Sterba authored and Linus Torvalds committed Jul 28, 2008
1 parent 09e491e commit bee9c7c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions drivers/char/pcmcia/ipwireless/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,15 @@ static void ipwireless_detach(struct pcmcia_device *link);
/* Debug mode: more verbose, print sent/recv bytes */
int ipwireless_debug;
int ipwireless_loopback;
int ipwireless_out_queue = 1;
int ipwireless_out_queue = 10;

module_param_named(debug, ipwireless_debug, int, 0);
module_param_named(loopback, ipwireless_loopback, int, 0);
module_param_named(out_queue, ipwireless_out_queue, int, 0);
MODULE_PARM_DESC(debug, "switch on debug messages [0]");
MODULE_PARM_DESC(loopback,
"debug: enable ras_raw channel [0]");
MODULE_PARM_DESC(out_queue, "debug: set size of outgoing queue [1]");
MODULE_PARM_DESC(out_queue, "debug: set size of outgoing PPP queue [10]");

/* Executes in process context. */
static void signalled_reboot_work(struct work_struct *work_reboot)
Expand Down
4 changes: 3 additions & 1 deletion drivers/char/pcmcia/ipwireless/network.c
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ static void notify_packet_sent(void *callback_data, unsigned int packet_length)
spin_unlock_irqrestore(&network->lock, flags);
ppp_output_wakeup(network->ppp_channel);
if (ipwireless_debug)
printk(KERN_INFO IPWIRELESS_PCCARD_NAME
printk(KERN_DEBUG IPWIRELESS_PCCARD_NAME
": ppp unblocked\n");
} else
spin_unlock_irqrestore(&network->lock, flags);
Expand Down Expand Up @@ -144,6 +144,8 @@ static int ipwireless_ppp_start_xmit(struct ppp_channel *ppp_channel,
*/
network->ppp_blocked = 1;
spin_unlock_irqrestore(&network->lock, flags);
if (ipwireless_debug)
printk(KERN_DEBUG IPWIRELESS_PCCARD_NAME ": ppp blocked\n");
return 0;
}
}
Expand Down

0 comments on commit bee9c7c

Please sign in to comment.