summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* cisco/enic: use eth_hw_addr_random() instead of random_ether_addr()Danny Kukawka2012-02-181-1/+2
| | | | | | | | | | | | | | Use dev_hw_addr_random() instead of calling random_ether_addr() to set addr_assign_type correctly to NET_ADDR_RANDOM. Reset the state to NET_ADDR_PERM as soon as the MAC get changed via .ndo_set_mac_address. v3: adapt to net-next v2: use bitops, adapt to eth_hw_addr_random(), add a comment Signed-off-by: Danny Kukawka <danny.kukawka@bisect.de> Signed-off-by: David S. Miller <davem@davemloft.net>
* net: ethernet: xilinx: Convert xilinx_axienet to module_platform_driverTobias Klauser2012-02-171-12/+1
| | | | | | | | | Follow commit db62f684. Convert the driver to use the module_platform_driver() macro which makes the code a bit smaller and simpler. Signed-off-by: Tobias Klauser <tklauser@distanz.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
* UML net: set addr_assign_type if random_ether_addr() usedDanny Kukawka2012-02-171-3/+8
| | | | | | | | | | | Set addr_assign_type correctly to NET_ADDR_RANDOM in case a random MAC address was generated and assigned to the netdevice. Return state from setup_etheraddr() about returning a random MAC address or not and check this state in eth_configure(). Signed-off-by: Danny Kukawka <danny.kukawka@bisect.de> Signed-off-by: David S. Miller <davem@davemloft.net>
* atheros eth: set addr_assign_type if random_ether_addr() usedDanny Kukawka2012-02-174-9/+15
| | | | | | | | | | | | | | | | | | Set addr_assign_type correctly to NET_ADDR_RANDOM in case a random MAC address was generated and assigned to the netdevice. Fix error handling in atl1c_probe(). If atl1c_read_mac_addr() couldn't get the hw mac address, and a random mac address get set return the error code. Don't go to err_eeprom in atl1c_probe(), use the generated MAC address in this case. Reset the state to NET_ADDR_PERM as soon as the MAC get changed via .ndo_set_mac_address. v2: use bitops Signed-off-by: Danny Kukawka <danny.kukawka@bisect.de> Signed-off-by: David S. Miller <davem@davemloft.net>
* ethoc: set addr_assign_type if random_ether_addr() usedDanny Kukawka2012-02-171-2/+18
| | | | | | | | | | | | | | | | | | Set addr_assign_type correctly to NET_ADDR_RANDOM in case a random MAC address was generated and assigned to the netdevice. Fixed ethoc_set_mac_address() to check if the given mac address is valid and set also dev_addr of the net_device. Check also the return value of ethoc_set_mac_address() in ethoc_probe(). Reset the state to NET_ADDR_PERM as soon as the MAC get changed via .ndo_set_mac_address. v2: set net_device->dev_addr in ethoc_set_mac_address(), check if given address is valid Signed-off-by: Danny Kukawka <danny.kukawka@bisect.de>
* batman-adv: use eth_hw_addr_random() instead of random_ether_addr()Danny Kukawka2012-02-171-3/+2
| | | | | | | | | | | | | | | Use eth_hw_addr_random() instead of calling random_ether_addr() to set addr_assign_type correctly to NET_ADDR_RANDOM. Remove dev_addr in interface_setup(), it's not needed anymore. Reset the state to NET_ADDR_PERM as soon as the MAC get changed via .ndo_set_mac_address. v2: use bitops, adapt to eth_hw_addr_random() Signed-off-by: Danny Kukawka <danny.kukawka@bisect.de> Signed-off-by: David S. Miller <davem@davemloft.net>
* igbvf: reset netdevice addr_assign_type if changedDanny Kukawka2012-02-171-0/+1
| | | | | | | | | | Reset the state of addr_assign_type to NET_ADDR_PERM as soon as the MAC get changed via .ndo_set_mac_address. v2: use bitops to reset addr_assign_type Signed-off-by: Danny Kukawka <danny.kukawka@bisect.de> Signed-off-by: David S. Miller <davem@davemloft.net>
* xilinx ll_temac: use eth_hw_addr_random() instead of random_ether_addr()Danny Kukawka2012-02-171-1/+3
| | | | | | | | | | | | | Use eth_hw_addr_random() instead of calling random_ether_addr() to set addr_assign_type correctly to NET_ADDR_RANDOM. Reset the state to NET_ADDR_PERM as soon as the MAC get changed via .ndo_set_mac_address. v2: reworked to prevent using an extra variable Signed-off-by: Danny Kukawka <danny.kukawka@bisect.de> Signed-off-by: David S. Miller <davem@davemloft.net>
* davinci_emac: use eth_hw_addr_random() instead of random_ether_addr()Danny Kukawka2012-02-171-2/+3
| | | | | | | | | | | | | | | | Use eth_hw_addr_random() instead of calling random_ether_addr() to set addr_assign_type correctly to NET_ADDR_RANDOM. Reset the state to NET_ADDR_PERM as soon as the MAC get changed via .ndo_set_mac_address. Remove one memcpy from emac_dev_setmac_addr() since this is a duplicate: it's already done some lines above. v2: use bitops, adapt to eth_hw_addr_random, remove a memcpy Signed-off-by: Danny Kukawka <danny.kukawka@bisect.de> Signed-off-by: David S. Miller <davem@davemloft.net>
* lantiq_etop: set addr_assign_type if random_ether_addr() usedDanny Kukawka2012-02-171-0/+7
| | | | | | | | | | Set addr_assign_type correctly to NET_ADDR_RANDOM in case a random MAC address was generated and assigned to the netdevice. v2: added comment, renamed bool variable to random_mac Signed-off-by: Danny Kukawka <danny.kukawka@bisect.de> Signed-off-by: David S. Miller <davem@davemloft.net>
* au1000_eth: use eth_hw_addr_random() instead of random_ether_addr()Danny Kukawka2012-02-171-4/+5
| | | | | | | | | | Use eth_hw_addr_random() instead of calling random_ether_addr() to set addr_assign_type correctly to NET_ADDR_RANDOM. v2: adapt to eth_hw_addr_random() Signed-off-by: Danny Kukawka <danny.kukawka@bisect.de> Signed-off-by: David S. Miller <davem@davemloft.net>
* Merge tag 'batman-adv-for-davem' of git://git.open-mesh.org/linux-mergeDavid S. Miller2012-02-1718-235/+426
|\
| * batman-adv: export used routing algorithm via sysfsMarek Lindner2012-02-172-0/+16
| | | | | | | | Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
| * batman-adv: allowing changing the routing algorithm via module parameterMarek Lindner2012-02-171-0/+24
| | | | | | | | Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
| * batman-adv: convert batman iv algorithm to use dynamic infrastructureMarek Lindner2012-02-177-129/+129
| | | | | | | | Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
| * batman-adv: add infrastructure to change routing algorithm at runtimeMarek Lindner2012-02-177-0/+145
| | | | | | | | Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
| * batman-adv: warn if added interface is part of a bridgeMarek Lindner2012-02-171-0/+8
| | | | | | | | Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
| * batman-adv: Move is_out_of_time() to main.h for general useMartin Hundebøll2012-02-172-20/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | Both translation tables and network coding use timeouts to do house keeping, so we might as well share the function used to compare a timestamp+timeout with current time. For readability and simplicity, the function is renamed to has_timed_out() and uses time_is_before_jiffies() instead of time_after(). Signed-off-by: Martin Hundebøll <martin@hundeboll.net> Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
| * batman-adv: Rm empty line from is_my_mac() in main.cMartin Hundebøll2012-02-171-1/+0
| | | | | | | | | | Signed-off-by: Martin Hundebøll <martin@hundeboll.net> Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
| * batman-adv: simplify bat_ogm_receive API callMarek Lindner2012-02-173-9/+9
| | | | | | | | | | | | | | | | Most of the values in that call are derived from the skb, so we can hand over the skb instead. Reported-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de> Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
| * batman-adv: Explicitly mark the common header structureSven Eckelmann2012-02-1710-98/+87
| | | | | | | | | | | | | | | | | | | | | | | | | | | | All batman-adv packets have a common 3 byte header. It can be used to share some code between different code paths, but it was never explicit stated that this header has to be always the same for all packets. Therefore, new code changes always have the problem that they may accidently introduce regressions by moving some elements around. A new structure is introduced that contains the common header and makes it easier visible that these 3 bytes have to be the same for all on-wire packets. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
| * batman-adv: add tt_initialised flag to the orig_node structAntonio Quartulli2012-02-173-3/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | (ttvn == 0) is currently used as initial condition. However this is not a good idea because ttvn gets the vale zero each time after reaching the maximum value (wrap around). For this reason a new flag is added in order to define whether a node has an initialised table or not. Moreover, after invoking tt_global_del_orig(), tt_initialised has to be set to false Reported-by: Alexey Fisher <bug-track@fisher-privat.net> Signed-off-by: Antonio Quartulli <ordex@autistici.org> Signed-off-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de> Tested-by: Alexey Fisher <bug-track@fisher-privat.net> Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
* | net: sh_eth: add support for VLAN tag filteringYoshihiro Shimoda2012-02-162-0/+64
| | | | | | | | | | | | | | | | | | | | Some controllers have TSU. It can register one VLAN tag, and it can filter other VLAN tag by hardware. If vlan_rx_add_vid() is called twice or more, the driver will disable the filtering. Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | net: sh_eth: add support for multicast filteringYoshihiro Shimoda2012-02-162-5/+286
| | | | | | | | | | | | | | | | Some controllers have TSU. It can filter multicast by hardware. This patch supports it. Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | net: sh_eth: modify a condition of ioremap for TSUYoshihiro Shimoda2012-02-161-11/+14
| | | | | | | | | | | | | | | | If the controller has TSU, the each channel needs TSU registers. This patch also fixes the iounmap condition in the sh_eth_drv_remove(). Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | net: sh_eth: change the condition of initializationYoshihiro Shimoda2012-02-162-2/+3
| | | | | | | | | | | | | | | | | | | | The SH7757 has 2 Fast Ethernet and 2 Gigabit Ethernet, and the first Gigabit channel needs the initialization. So, this patch adds the parameter of "needs_init", and if the sh_eth_plat_data is set it to 1, the driver will initialize the channel. Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | net: sh_eth: add the value of tsu to the SH7757's GETHERYoshihiro Shimoda2012-02-161-0/+1
| | | | | | | | | | | | | | | | The SH7757's GETHER has TSU registers. So, this patch adds the value of ".tsu = 1" in the sh_eth_cpu_data. Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | Merge git://git.kernel.org/pub/scm/linux/kernel/git/bwh/sfc-nextDavid S. Miller2012-02-1621-604/+3170
|\ \
| * | sfc: Add SR-IOV back-end support for SFC9000 familyBen Hutchings2012-02-1613-26/+2192
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On the SFC9000 family, each port has 1024 Virtual Interfaces (VIs), each with an RX queue, a TX queue, an event queue and a mailbox register. These may be assigned to up to 127 SR-IOV virtual functions per port, with up to 64 VIs per VF. We allocate an extra channel (IRQ and event queue only) to receive requests from VF drivers. There is a per-port limit of 4 concurrent RX queue flushes, and queue flushes may be initiated by the MC in response to a Function Level Reset (FLR) of a VF. Therefore, when SR-IOV is in use, we submit all flush requests via the MC. The RSS indirection table is shared with VFs, so the number of RX queues used in the PF is limited to the number of VIs per VF. This is almost entirely the work of Steve Hodgson, formerly shodgson@solarflare.com. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Allocate SRAM between buffer table and descriptor caches at init timeBen Hutchings2012-02-166-14/+50
| | | | | | | | | | | | | | | | | | | | | | | | | | | Each port has a block of 64-bit SRAM that is divided between buffer table and descriptor cache regions at initialisation time. Currently we use a fixed allocation, but it needs to be changed to support larger numbers of queues. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Pass NIC structure into efx_wanted_parallelism()Ben Hutchings2012-02-161-4/+4
| | | | | | | | | | | | | | | | | | | | | This lets us identify the NIC affected in case of failure, and will be necessary to adjust for SR-IOV constraints. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Add support for 'extra' channel typesBen Hutchings2012-02-163-108/+239
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Abstract some of the channel operations to allow for 'extra' channels that do not have RX or TX queues. - Try to assign a channel to each extra channel type that is enabled for the NIC, but gracefully degrade if we can't allocate sufficient MSI-X vectors - Allow each extra channel type to generate its own channel name - Allow channel types to disable reallocation and reinitialisation of their channels Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Make all CPU/IRQ/channel/queue counts unsignedBen Hutchings2012-02-162-9/+11
| | | | | | | | | | | | Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Make buffer table indices and counts consistently unsignedBen Hutchings2012-02-162-3/+3
| | | | | | | | | | | | Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Disable flow control during flushesSteve Hodgson2012-02-163-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The TX DMA engine issues upstream read requests when there is room in the TX FIFO for the completion. However, the fetches for the rest of the packet might be delayed by any back pressure. Since a flush must wait for an EOP, the entire flush may be delayed by back pressure. Mitigate this by disabling flow control before the flushes are started. Since PF and VF flushes run in parallel introduce fc_disable, a reference count of the number of flushes outstanding. The same principle could be applied to Falcon, but that would bring with it its own testing. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Generalise event generation to cover VF-owned event queuesBen Hutchings2012-02-162-6/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For SR-IOV we will need to send events to event queues that belong to VFs serviced by other drivers. Change the parameters of efx_generate_event() to allow this and declare it extern. While we're at it, remove the existing declaration under the wrong name efx_nic_generate_event(). Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Use proper function to test for RX channel in efx_poll()Ben Hutchings2012-02-161-1/+1
| | | | | | | | | | | | Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Leave interrupts and event queues enabled whenever we canBen Hutchings2012-02-164-318/+308
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When SR-IOV is enabled we may receive FLR (Function-Level Reset) events, associated queue flush events and requests from VF drivers at any time. Therefore we need to keep event queues and interrupts enabled whenever possible. Currently we stop interrupt-driven event processing before flushing RX and TX queues; efx_nic_flush_queues() then polls event queues for flush events and discards any others it finds. Change it to work with the regular event handling functions. Currently efx_start_channel() fills RX queues synchronously when a device is brought up. This could now race with NAPI, so change it to send fill events. This was almost entirely written by Steve Hodgson, formerly shodgson@solarflare.com. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Generate RX fill events based on RX queues, not channelsBen Hutchings2012-02-163-9/+13
| | | | | | | | | | | | | | | | | | | | | This makes it harder to accidentally send such events to TX-only channels. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Generalise driver event generationBen Hutchings2012-02-161-24/+27
| | | | | | | | | | | | Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Correct MAC filter bitfield definitionsBen Hutchings2012-02-161-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The RMFT_DEST_MAC and TMFT_SRC_MAC register fields were previously documented as 44 bits wide, whereas a MAC address has 48 bits. Thankfully the hardware uses the correct width and the driver has used separate definitions that divide each of these into 32-bit and 16-bit fields. Fix the initial definitions for these fields and rewrite the latter definitions to use them. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Add support for TX MAC filtersBen Hutchings2012-02-162-5/+72
| | | | | | | | | | | | | | | | | | | | | | | | | | | On Siena each TX queue can be configured to send only packets for which there is a TX MAC filter that matches the source MAC address, queue ID, and optionally VID. This will be used to implement the 'spoofchk' feature for SR-IOV virtual functions. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Add support for configuring RX unicast/multicast default filtersBen Hutchings2012-02-163-47/+214
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On Siena all received packets that don't match a more specific filter will match the unicast or multicast default filter. Currently we leave these set to the default values (RSS with base queue number of 0). Allow them to be reconfigured to select a single RX queue. These default filters are programmed through the FILTER_CTL register, but we represent them internally as an additional table of size 2. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Warn if unable to create MTDsBen Hutchings2012-02-132-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | Log an explicit warning if we are unable to create MTDs for a net device. Also correct the comment about why mtd_device_register() may fail; there is no longer an MTD table to fill up. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Replace some literal constants with EFX_PAGE_SIZE/EFX_BUF_SIZEBen Hutchings2012-02-133-5/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The 'page size' for PCIe DMA, i.e. the alignment of boundaries at which DMA must be broken, is 4KB. Name this value as EFX_PAGE_SIZE and use it in efx_max_tx_len(). Redefine EFX_BUF_SIZE as EFX_PAGE_SIZE since its value is also a result of that requirement, and use it in efx_init_special_buffer(). Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Do not retry hardware probe if it schedules a resetBen Hutchings2012-02-131-34/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | If efx_pci_probe_main() schedules an INVISIBLE or ALL reset (but nothing more drastic), we retry it up to 5 times. So far as I'm aware, this was a workaround for bugs in Falcon A0 which were fixed in production silicon. Remove the retry. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
| * | sfc: Skip RX end-of-batch work on channels without an RX queueBen Hutchings2012-02-131-10/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The code in efx_process_channel() to update the RX queue after each batch of RX completions works out as a no-op on a TX-only channel where the RX queue structure is set to all-zeroes, but (1) efx_channel_get_rx_queue() will BUG() if DEBUG is defined, and (2) it's a waste of time. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
* | | ipv4: Eliminate spurious argument to __ipv4_neigh_lookupDavid S. Miller2012-02-152-3/+3
| | | | | | | | | | | | | | | | | | 'tbl' is always arp_tbl, so specifying it is pointless. Signed-off-by: David S. Miller <davem@davemloft.net>
* | | decnet: net/dn.h needs net/flow.hDavid S. Miller2012-02-151-0/+1
| | | | | | | | | | | | | | | Reported-by: Randy Dunlap <rdunlap@xenotime.net> Signed-off-by: David S. Miller <davem@davemloft.net>
* | | cxgb3: update firmware versionDivy Le Ray2012-02-151-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Hi Dave, This patch is sent in conjunction with the cxgb3 firmware update submission on linux-firmware. (https://lkml.org/lkml/2012/2/13/27) Cheers, Divy From: Divy Le Ray <divy@chelsio.com> This patch updates the firmware version cxgb3 is requesting to 7.12.0. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
OpenPOWER on IntegriCloud