aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/host/isp116x-hcd.c (unfollow)
AgeCommit message (Collapse)AuthorFilesLines
2006-01-04[PATCH] USB: Cleanups for usb gadget mass-storagePavel Machek1-2/+2
Remove useless initalizers. Signed-off-by: Pavel Machek <pavel@suse.cz> Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
2006-01-04[PATCH] USB: Store port number in usb_deviceAlan Stern3-61/+20
This patch (as610) adds a field to struct usb_device to store the device's port number. This allows us to remove several loops in the hub driver (searching for a particular device among all the entries in the parent's array of children). Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: Consider power budget when choosing configurationAlan Stern5-81/+164
This patch (as609) changes the way we keep track of power budgeting for USB hubs and devices, and it updates the choose_configuration routine to take this information into account. (This is something we should have been doing all along.) A new field in struct usb_device holds the amount of bus current available from the upstream port, and the usb_hub structure keeps track of the current available for each downstream port. Two new rules for configuration selection are added: Don't select a self-powered configuration when only bus power is available. Don't select a configuration requiring more bus power than is available. However the first rule is #if-ed out, because I found that the internal hub in my HP USB keyboard claims that its only configuration is self-powered. The rule would prevent the configuration from being chosen, leaving the hub & keyboard unconfigured. Since similar descriptor errors may turn out to be fairly common, it seemed wise not to include a rule that would break automatic configuration unnecessarily for such devices. The second rule may also trigger unnecessarily, although this should be less common. More likely it will annoy people by sometimes failing to accept configurations that should never have been chosen in the first place. The patch also changes usbcore's reaction when no configuration is suitable. Instead of raising an error and rejecting the device, now the core will simply leave the device unconfigured. People can always work around such problems by installing configurations manually through sysfs. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: One potential problem in gadget/serial.cFengwei Yin1-0/+2
It looks like that the gs_serial module maybe sleep with spinlock in gs_close. Sometimes, system hang when I remove the gs_serial module. From: Fengwei Yin <xaityyy@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: small cleanupsAdrian Bunk2-3/+3
This patch contains the following cleanups: - make needlessly global functions static - every file should #include the headers containing the prototypes for it's global functions Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: Fix locking for USB suspend/resumeAlan Stern1-15/+39
The earlier USB locking updates didn't touch the suspend/resume routines. They need updating as well, since now the caller holds the device semaphore. This patch (as608) makes the necessary changes. It also adds a line to store the correct power state when a device is resumed, something which was unaccountably missing. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: Disconnect children during hub unbindAlan Stern1-63/+31
This patch (as606b) is an updated version of my earlier patch to disconnect children from a hub device when the hub driver is unbound. Thanks to the changes in the driver core locking, we now know that the entire hub device (and not just the interface) is locked whenever the hub driver's disconnect method runs. Hence it is safe to disconnect the child device structures immediately instead of deferring the job. The earlier version of the patch neglected to disable the hub's ports. We don't want to forget that; otherwise we'd end up with live devices using addresses that have been recycled. This update adds the necessary code. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: Remove USB private semaphoreAlan Stern9-154/+37
This patch (as605) removes the private udev->serialize semaphore, relying instead on the locking provided by the embedded struct device's semaphore. The changes are confined to the core, except that the usb_trylock_device routine now uses the return convention of down_trylock rather than down_read_trylock (they return opposite values for no good reason). A couple of other associated changes are included as well: Now that we aren't concerned about HCDs that avoid using the hcd glue layer, usb_disconnect no longer needs to acquire the usb_bus_lock -- that can be done by usb_remove_hcd where it belongs. Devices aren't locked over the same scope of code in usb_new_device and hub_port_connect_change as they used to be. This shouldn't cause any trouble. Along with the preceding driver core patch, this needs a lot of testing. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: remove .owner field from struct usb_driverGreg Kroah-Hartman125-128/+0
It is no longer needed, so let's remove it, saving a bit of memory. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: make registering a usb driver automatically set the module ownerGreg Kroah-Hartman2-5/+10
This fixes the driver that forgot to set the module owner up. Now we can remove the unneeded pointer from the usb driver structure. The idea for how to do this was from Al Viro, who did this for the PCI drivers. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: allow usb drivers to disable dynamic idsGreg Kroah-Hartman32-0/+52
This lets drivers, like the usb-serial ones, disable the ability to add ids from sysfs. The usb-serial drivers are "odd" in that they are really usb-serial bus drivers, not usb bus drivers, so the dynamic id logic will have to go into the usb-serial bus core for those drivers to get that ability. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: add dynamic id functionality to USB coreGreg Kroah-Hartman2-50/+176
Echo the usb vendor and product id to the "new_id" file in the driver's sysfs directory, and then that driver will be able to bind to a device with those ids if it is present. Example: echo 0557 2008 > /sys/bus/usb/drivers/foo_driver/new_id adds the hex values 0557 and 2008 to the device id table for the foo_driver. Note, usb-serial drivers do not currently work with this capability yet. usb-storage also might have some oddities. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: reorg some functions out of the main usb.c fileGreg Kroah-Hartman5-312/+343
This will make the dynamic-id stuff easier to do, as it will be self-contained. No logic was changed at all. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: make bias writeable in libusualPete Zaitcev1-26/+27
Make the bias parameter writeable. Writing the parameter does not trigger a rebind of currently attached storage devices. Signed-off-by: Pete Zaitcev <zaitcev@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: drivers/usb/storage/libusualPete Zaitcev12-167/+486
This patch adds a shim driver libusual, which routes devices between usb-storage and ub according to the common table, based on unusual_devs.h. The help and example syntax is in Kconfig. Signed-off-by: Pete Zaitcev <zaitcev@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: central handling for host controllers that were reset during suspend/resumeAlan Stern6-15/+42
This patch (as515b) adds a routine to usbcore to simplify handling of host controllers that lost power or were reset during suspend/resume. The new core routine marks all the child devices of the root hub as NOTATTACHED and tells khubd to disconnect the device structures as soon as possible. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: dummy_hcd: rename variablesAlan Stern1-25/+25
The recent platform_device update has reintroduced into dummy_hcd.c the dreaded dev->dev syndrome. This harkens back to when an earlier version of that driver included the unforgettable line: dev->dev.dev.driver_data = dev; This patch (as602) renames the platform_device variables to "pdev", in the hope of reducing confusion. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: usb-net: new device ID passed through module parameterA.YOSHIYAMA1-0/+38
adds new module parameter "devid" that points to a string with format "device_name:vendor_id:device_id:flags". if provided at module load time, this string is being parsed and a new entry is created in usb_dev_id[] and pegasus_ids[] so the new device can later be recognized by the probe routine. this might be helpful for someone who don't know/wish to build new module/kernel, but want to use his new usb-to-eth device that is not yet listed in pegasus.h Signed-off-by: Petko Manolov <petkan@nucleusys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: usb-net: removes redundant returnPetko Manolov1-55/+51
removes all redundant collecting of the return value from get/set_registers() and suchlike. can't remember who put all of those some time ago, but they doesn't make any sense to me. where needed only a few references remained; Signed-off-by: Petko Manolov <petkan@nucleusys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: file-storage gadget: Add reference count for childrenAlan Stern1-13/+17
This patch (as601) adds a proper reference count to the file-storage gadget's main data structure, to keep track of references held by child devices (LUNs in this case). Before this, the driver would wait for each child to be released before unbinding. While there's nothing really wrong with that (you can't create a hang by doing "rmmod g_file_storage </sys/.../lun0/ro" since the open file will prevent rmmod from running), the code might as well follow the standard procedures. Besides, this shrinks the size of the structure by a few words... :-) Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: hcd uses EXTRA_CFLAGS for -DDEBUGDavid Brownell7-34/+7
This modifies the HCD builds to automatically "-DDEBUG" if CONFIG_USB_DEBUG is selected. It's just a minor source code cleanup, guaranteeing consistency. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: wakeup flag updates (3/3) isp116x-hcdDavid Brownell1-2/+3
This makes the ISP116x HCD use the driver model wakeup flags for its controller, not the flags in the HCD glue (which will be removed). Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: wakeup flag updates (2/3) uhci-hcdDavid Brownell1-2/+0
This makes UHCI stop using the HCD glue wakeup flags to report whether the controller can wake the system. The existing code was wrong anyway; having a PCI PM capability doesn't imply it reports PME# is supported. I skimmed Intel's ICH7 datasheet and that basically says the wakeup signaling gets routed only through ACPI registers. (On the other hand, many VIA chips provide the PCI PM capabilities...) I think that doing this correctly with UHCI is going to require the ACPI folk to associate the /proc/acpi/wakeup identifiers (and wakeup enable/disable flags) with the relevant /sys/devices/pci*/... devices. From: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: wakeup flag updates (1/3) sl811-hcdDavid Brownell1-2/+4
This makes the SL811 HCD use the driver model wakeup flags for its controller, not the flags in the HCD glue (which will be removed). From: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> drivers/usb/host/sl811-hcd.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
2006-01-04[PATCH] USB: ehci fix driver model wakeup flagsDavid Brownell1-1/+1
On some systems, EHCI seems to be getting IRQs too early during driver setup ... before the root hub is allocated, in particular, making trouble for any code chasing down root hub pointers! In this case, it seems to be safe to just ignore the root hub setting. Thanks to Rafael J. Wysocki for getting this properly tested. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: EHCI updates (4/4) driver model wakeup flagsDavid Brownell3-4/+13
This teaches the EHCI driver to use the new driver model wakeup flags, replacing the similar ones in the HCD glue. It also adds a workaround for the current glitch whereby PCI init doesn't init the wakeup flags from the PCI PM capabilities. (EHCI controllers don't worry about legacy mode; the PCI PM capability would always do the job.) Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: Eagle and ADI 930 usb adsl modem driver fixmatthieu castet1-10/+18
More care on loading firmware, take into account fw->size can't be zero. Signed-off-by: Matthieu CASTET <castet.matthieu@free.fr> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: Eagle and ADI 930 usb adsl modem drivermatthieu castet3-0/+1827
A driver for USB ADSL modems based on the ADI eagle chipset using the usb_atm infrastructure. The managing part was taken from bsd ueagle driver, other parts were written from scratch. The driver uses the in-kernel firmware loader : - to load a first usb firmware when the modem is in pre-firmware state - to load the dsp firmware that are swapped in host memory. - to load CMV (configuration and management variables) when the modem boot. (We can't use options or sysfs for this as there many possible values. See https://mail.gna.org/public/eagleusb-dev/2005-04/msg00031.html for a description of some) - to load fpga code for 930 chipset. The device had 4 endpoints : * 2 for data (use by usbatm). The incoming endpoint could be iso or bulk. The modem seems buggy and produce lot's of atm errors when using it in bulk mode for speed > 3Mbps, so iso endpoint is need for speed > 3Mbps. At the moment iso endpoint need a patched usbatm library and for this reason is not included in this patch. * One bulk endpoint for uploading dsp firmware * One irq endpoint that notices the driver - if we need to upload a page of the dsp firmware - an ack for read or write CMV and the value (for the read case). If order to make the driver cleaner, we design synchronous (read|write)_cmv : -send a synchronous control message to the modem -wait for an ack or a timeout -return the value if needed. In order to run these synchronous usb messages we need a kernel thread. The driver has been tested with sagem fast 800 modems with different eagle chipset revision and with ADI 930 since April 2005. Signed-off-by: Matthieu CASTET <castet.matthieu@free.fr> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: EHCI: fix conflation of buf == 0 with len == 0Alan Stern1-7/+7
When the ehci-hcd driver prepares a control URB, it tests for a zero-length data stage by looking at the transfer_dma value instead of the transfer_buffer_length. (In fact it does this even for non-control URBs, which is an additional aspect of the same bug.) However, under certain circumstances it's possible for transfer_dma to be 0 while transfer_buffer_length is non-zero. This can happen when a freshly allocated page (mapped to address 0 and marked Copy-On-Write, but never written to) is used as the source buffer for an OUT transfer. This patch (as598) fixes the problem. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: isp116x-hcd: cleanupOlav Kongas3-288/+230
The attached patch makes a cleanup of isp116x-hcd. Most of the volume of the patch comes from 2 sources: moving the code around to get rid of a few function prototypes and reworking register dumping functions/macros. Among other things, switched over from using procfs to debugfs. Cleanup. The following changes were made: - Rework register dumping code so it can be used for dumping to both syslog and debugfs. - Switch from procfs to debugfs.. - Die gracefully on Unrecoverable Error interrupt. - Fix memory leak in isp116x_urb_enqueue(), if HC happens to die in a narrow time window. - Fix a 'sparce' warning (unnecessary cast). - Report Devices Removable for root hub ports by default (was Devices Permanently Attached). - Move bus suspend/resume functions down in code to get rid of a few function prototypes. - A number of one-line cleanups. - Add an entry to MAINTAINERS. Signed-off-by: Olav Kongas <ok@artecdesign.ee> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> MAINTAINERS | 6 drivers/usb/host/isp116x-hcd.c | 429 ++++++++++++++++------------------------- drivers/usb/host/isp116x.h | 83 +++++-- 3 files changed, 230 insertions(+), 288 deletions(-)
2006-01-04[PATCH] USB: isp116x-hcd: support reiniting HC on resumeOlav Kongas1-8/+18
Until now the isp116x-hcd had no support to reinitialize the HC on resume, if the controller lost its state during suspend. This patch, generated against your Oct 26 git tree, adds that support. The patch is basically the same as the one tested by Ivan Kalatchev, who reported the problem, on 2.6.13. Please apply, Support reinitializing the isp116x host controller from scratch on resume, if the controller has lost its state. Signed-off-by: Olav Kongas <ok@artecdesign.ee> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: Converting cdc acm to a ring queueDavid Kubicek2-76/+184
this patch by David converts the sending queue of the CDC ACM driver to a queue of URBs. This is needed for quicker devices. Please apply. Signed-Off-By: Oliver Neukum <oliver@neukum.name> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> drivers/usb/class/cdc-acm.c | 229 ++++++++++++++++++++++++++++++-------------- drivers/usb/class/cdc-acm.h | 33 +++++- 2 files changed, 185 insertions(+), 77 deletions(-)
2006-01-04[PATCH] USB: Add pxa27x OHCI PM functionsRichard Purdie1-6/+27
Add power management functions for the pxa27x USB OHCI host controller. This is a totally rewritten version of the patch by Nicolas Pitre and Todd Poynor which accounts for recent USB changes. Signed-off-by: Richard Purdie <rpurdie@rpsys.net> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[PATCH] USB: pxa27x OHCI - Separate platform code from main driverRichard Purdie4-42/+88
To allow multiple platforms to use the PXA27x OHCI driver, the platform code needs to be moved into the board specific files in arch/arm/mach-pxa. This patch does this for mainstone and adds preliminary hooks to allow other boards to use the driver. This has been compile tested for mainstone and successfully run on Spitz (Sharp Zaurus SL-C3000) with the addition of an appropriate board support file. Signed-off-by: Richard Purdie <rpurdie@rpsys.net> Signed-off-by: Nicolas Pitre <nico@cam.org> Acked-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[IPVS]: Add missing include <linux/net.h>Arnaldo Carvalho de Melo1-0/+1
CC [M] net/ipv4/ipvs/ip_vs_conn.o /pub/scm/linux/kernel/git/acme/net-2.6/net/ipv4/ipvs/ip_vs_conn.c: In function 'ip_vs_conn_new': /pub/scm/linux/kernel/git/acme/net-2.6/net/ipv4/ipvs/ip_vs_conn.c:606: warning: implicit declaration of function 'net_ratelimit' /pub/scm/linux/kernel/git/acme/net-2.6/net/ipv4/ipvs/ip_vs_conn.c: In function 'ip_vs_random_dropentry': /pub/scm/linux/kernel/git/acme/net-2.6/net/ipv4/ipvs/ip_vs_conn.c:810: warning: implicit declaration of function 'net_random' Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
2006-01-04[TCP]: syn_flood_warning is only needed if CONFIG_SYN_COOKIES is selectedArnaldo Carvalho de Melo1-0/+2
CC net/ipv4/tcp_ipv4.o /pub/scm/linux/kernel/git/acme/net-2.6/net/ipv4/tcp_ipv4.c:665: warning: 'syn_flood_warning' defined but not used Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
2006-01-04[DCCP] ackvec: use u8 for the buf offsetsArnaldo Carvalho de Melo2-16/+23
Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
2006-01-04[DCCP] ackvec: Fix spelling of "throw"Andrea Bittau1-3/+3
Signed-off-by: Andrea Bittau <a.bittau@cs.ucl.ac.uk> Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
2006-01-03[TCP]: less inline'sStephen Hemminger5-201/+198
TCP inline usage cleanup: * get rid of inline in several places * replace __inline__ with inline where possible * move functions used in one file out of tcp.h * let compiler decide on used once cases On x86_64: text data bss dec hex filename 3594701 648348 567400 4810449 4966d1 vmlinux.orig 3593133 648580 567400 4809113 496199 vmlinux On sparc64: text data bss dec hex filename 2538278 406152 530392 3474822 350586 vmlinux.ORIG 2536382 406384 530392 3473158 34ff06 vmlinux Signed-off-by: Stephen Hemminger <shemminger@osdl.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-01-03[IEEE80211] ipw2200: Simplify multicast checks.Stephen Hemminger2-13/+7
From: Stephen Hemminger <shemminger@osdl.org> is_multicast_ether_addr() accepts broadcast too, so the is_broadcast_ether_addr() calls are redundant. Signed-off-by: David S. Miller <davem@davemloft.net>
2006-01-03[NET]: Don't exclude broadcast addresses from is_multicast_ether_addr()Stephen Hemminger1-1/+2
The check for multicast shouldn't exclude broadcast type addresses. This reverts the incorrect change done in 2.6.13. The broadcast address is a multicast address and should be excluded from being a valid_ether_address for use in bridging or device address. Signed-off-by: Stephen Hemminger <shemminger@osdl.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-01-03[IPV4] fib_trie: build fixStephen Hemminger1-0/+1
Need this to fix build of fib_trie in net-2.6.16 (rebased) tree. The code needs the new inet_make_mask inline. Signed-off-by: Stephen Hemminger <shemminger@osdl.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-01-03[BRIDGE]: Fix faulty check in br_stp_recalculate_bridge_id()Stephen Hemminger1-1/+1
One of the conversions from memcmp to compare_ether_addr is incorrect. We need to do relative comparison to determine min MAC address to use in bridge id. Signed-off-by: Stephen Hemminger <shemminger@osdl.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-01-03[DCCP]: Notify CCID only after ACK vectors have been processed.Andrea Bittau1-3/+3
The CCID should be notified of packet reception only when a packet is valid. Therefore, the ACK vector needs to be processed before notifying the CCID. Also, the CCID might need information provided by the ACK vector. Signed-off-by: Andrea Bittau <a.bittau@cs.ucl.ac.uk> Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-01-03[DCCP]: Send an ACK vector when ACKing a response packetAndrea Bittau1-0/+6
If ACK vectors are used, each packet with an ACK should contain an ACK vector. The only exception currently is response packets. It probably is not a good idea to store ACK vector state before the connection is completed (to help protect from syn floods). Signed-off-by: Andrea Bittau <a.bittau@cs.ucl.ac.uk> Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-01-03[DCCP]: Do not process a packet twice when it's not in state DCCP_OPEN.Andrea Bittau1-22/+34
When packets are received, the connection is either in DCCP_OPEN [fast-path] or it isn't. If it's not [e.g. DCCP_PARTOPEN] upper layers will perform sanity checks and parse options. If it is in DCCP_OPEN, dccp_rcv_established() will do it. It is important not to re-parse options in dccp_rcv_established() when it is not called from the fast-path. Else, fore example, the ack vector will be added twice and the CCID will see the packet twice. The solution is to always enfore sanity checks from the upper layers. When packets arrive in the fast-path, sanity checks will be performed before calling dccp_rcv_established(). Note(acme): I rewrote the patch to achieve the same result but keeping dccp_rcv_established with the previous semantics and having it split into __dccp_rcv_established, that doesn't does do any sanity check, code in state != DCCP_OPEN use this lighter version as they already do the sanity checks. Signed-off-by: Andrea Bittau <a.bittau@cs.ucl.ac.uk> Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-01-03[DECNET]: Only use local routersPatrick Caulfield1-5/+8
The attached patch makes DECnet routing only use routers from the same area - rather than the highest rated router seen. In theory there should not be an out-of-area router on a local network but some networks are bridged rather than properly routed. VMS seems to behave similarly: if I bring up a VMS node with no router then it can't see anything else on the global network. Signed-off-by: Patrick Caulfield <patrick@tykepenguin.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-01-03[IPVS]: Cleanup IP_VS_DBG statements.Roberto Nibali4-14/+17
From: Roberto Nibali <ratz@drugphish.ch> The attached patch (against current -GIT) is a cleanup patch which does following: o lookup debug messages shifted back to 9 o added more informational value to flags and refcnt since those entries can be in multiple referenced structures o cleanup 80 char violation It's the prepatch to the session pool implementation and helps very much to debug and monitor important variables and structures regarding the threshold limitation and persistency without the thousands of lookup messages which noone is interested in. Signed-off-by: Horms <horms@verge.net.au> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-01-03[TG3]: fixup tot_len calculationAlexey Dobriyan1-1/+1
Turning struct iphdr::tot_len into __be16 added sparse warning. Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-01-03[NET]: Add a dev_ioctl() fallback to sock_ioctl()Christoph Hellwig17-40/+27
Currently all network protocols need to call dev_ioctl as the default fallback in their ioctl implementations. This patch adds a fallback to dev_ioctl to sock_ioctl if the protocol returned -ENOIOCTLCMD. This way all the procotol ioctl handlers can be simplified and we don't need to export dev_ioctl. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: David S. Miller <davem@davemloft.net>