aboutsummaryrefslogtreecommitdiffstats
path: root/drivers (follow)
AgeCommit message (Collapse)AuthorFilesLines
2015-01-30net: davinci_emac: Get device dm816x MAC address using the cpsw codeTony Lindgren1-1/+22
At least on dm81xx, we can get the davinci_emac MAC address the same way as on am33xx cpsw. Let's also use ether_addr_copy() for davinci_emac while at it. Cc: Brian Hutchinson <b.hutchman@gmail.com> Cc: Felipe Balbi <balbi@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-30net: cpsw: Add a minimal cpsw-common module for shared codeTony Lindgren4-33/+60
Looks like davinci_emac and cpsw can share some code although the device registers have a different layout. At least the code for getting the MAC address using syscon can be shared by passing the register offset. Let's start with that and set up a minimal shared cpsw-shared.c. Cc: Brian Hutchinson <b.hutchman@gmail.com> Cc: Felipe Balbi <balbi@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-29Merge tag 'linux-can-next-for-3.20-20150128' of git://git.kernel.org/pub/scm/linux/kernel/git/mkl/linux-can-nextDavid S. Miller10-226/+1981
Marc Kleine-Budde says: ==================== pull-request: can-next 2015-28-01 this is a pull request of 12 patches for net-next/master. There are 3 patches by Ahmed S. Darwish, which update the kvaser_usb driver and add support for the USBcan-II based adapters. Stéphane Grosjean contributes 7 patches for the peak_usb driver, which add support for the CANFD USB adapters. I contribute 2 patches which clean up the peak_usb driver structure a bit. ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-29net: gianfar: remove the unneeded check of disabled deviceKevin Hao1-1/+1
Since commit cd1e65044d44 ("of/device: Don't register disabled devices"), the disabled device will not be registered at all. So we don't need to do the check again in the platform device driver. Signed-off-by: Kevin Hao <haokexin@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-28hisilicon: add some missing curly bracesDan Carpenter1-1/+2
The if block was supposed to have curly braces. In the current code we complain about dropped rx packets when we shouldn't. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-28Merge tag 'nfc-next-3.20-1' of git://git.kernel.org/pub/scm/linux/kernel/git/sameo/nfc-nextDavid S. Miller11-79/+767
NFC: 3.20 first pull request This is the first NFC pull request for 3.20. With this one we have: - Secure element support for the ST Micro st21nfca driver. This depends on a few HCI internal changes in order for example to support more than one secure element per controller. - ACPI support for NXP's pn544 HCI driver. This controller is found on many x86 SoCs and is typically enumerated on the ACPI bus there. - A few st21nfca and st21nfcb fixes. Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-28can: peak_usb: add support for PEAK new CANFD USB adaptersStephane Grosjean6-4/+1337
Add support for the following new PEAK-System technik CANFD USB adapters: PCAN-USB FD single CANFD channel USB adapter PCAN-USB Pro FD dual CANFD channels USB adapter Signed-off-by: Stephane Grosjean <s.grosjean@peak-system.com> Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net> Acked-by: Andri Yngvason <andri.yngvason@marel.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2015-01-28can: peak_usb: add peak_usb_netif_rx() new functionStephane Grosjean2-1/+18
Add a common function that pushes the skb in the network queue with adding timestamps information, converted from time values read from the PEAK USB adapters. Signed-off-by: Stephane Grosjean <s.grosjean@peak-system.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2015-01-28can: peak_usb: export pcan_usb_pro functionsStephane Grosjean2-12/+17
Add support for the following new PEAK-System technik CANFD USB adapters: PCAN-USB FD single CANFD channel USB adapter PCAN-USB Pro FD dual CANFD channels USB adapter The communication protocol has been developed using some mechanisms that did exist in the PCAN-USB Pro, thus, this patch also changes some previously static functions and data into global ones. Signed-off-by: Stephane Grosjean <s.grosjean@peak-system.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2015-01-28can: peak_usb: upgrade core to new struct canfd_frameStephane Grosjean2-4/+6
Upgrade PEAK-System USB adapters core to the new data structures (names) and callbacks added for the support of the CANFD extension. This specific patch includes changes that deal with the new struct canfd_frame. Signed-off-by: Stephane Grosjean <s.grosjean@peak-system.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2015-01-28can: peak_usb: upgrade core to data bittiming specsStephane Grosjean2-5/+34
Upgrade PEAK-System USB adapters core to the new data structures (names) and callbacks added for the support of the CANFD extension. This specific patch does the mandatory changes to support new data bittiming specs. Signed-off-by: Stephane Grosjean <s.grosjean@peak-system.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2015-01-28can: peak_usb: add adapter BEC callback definitionStephane Grosjean2-0/+3
Add the definition of a new callback that enable any PEAK-System CAN USB adapter to grant read access to its Bus Error Counters value. This ability is not supported by all the PEAK-System adapters, thus, for those, the callback pointer will be initiaized to NULL, which is correct regarding the linux-can device driver specs. Signed-off-by: Stephane Grosjean <s.grosjean@peak-system.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2015-01-28can: peak_usb: export ctrlmode_supported to adapter specific definitionStephane Grosjean4-2/+4
Export the ctrlmode_supported value from the core file to each adapter specific file. This has been mandatory for supporting the new CANFD extension. Signed-off-by: Stephane Grosjean <s.grosjean@peak-system.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2015-01-28can: peak_usb: constify struct peak_usb_adapterMarc Kleine-Budde4-11/+11
A "struct peak_usb_adapter" describes a certain USB adapter, as this doesn't change during runtime, this patch marks all USB adapter definitions as const. Acked-by: Stephane Grosjean <s.grosjean@peak-system.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2015-01-28can: peak_usb: use ARRAY_SIZE instead of NULL termination for peak_usb_adapters_listMarc Kleine-Budde1-5/+5
This patch converts the list "static struct peak_usb_adapter *peak_usb_adapters_list[]" to be used with ARRAY_SIZE not with a NULL termination, as the size is known during compile time. Acked-by: Stephane Grosjean <s.grosjean@peak-system.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2015-01-28can: kvaser_usb: Add support for the USBcan-II familyAhmed S. Darwish2-124/+474
CAN to USB interfaces sold by the Swedish manufacturer Kvaser are divided into two major families: 'Leaf', and 'USBcanII'. From an Operating System perspective, the firmware of both families behave in a not too drastically different fashion. This patch adds support for the USBcanII family of devices to the current Kvaser Leaf-only driver. CAN frames sending, receiving, and error handling paths has been tested using the dual-channel "Kvaser USBcan II HS/LS" dongle. It should also work nicely with other products in the same category. List of new devices supported by this driver update: - Kvaser USBcan II HS/HS - Kvaser USBcan II HS/LS - Kvaser USBcan Rugged ("USBcan Rev B") - Kvaser Memorator HS/HS - Kvaser Memorator HS/LS - Scania VCI2 (if you have the Kvaser logo on top) Signed-off-by: Ahmed S. Darwish <ahmed.darwish@valeo.com> Acked-by: Andri Yngvason <andri.yngvason@marel.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2015-01-28can: kvaser_usb: Consolidate and unify state change handlingAhmed S. Darwish1-64/+49
Replace most of the can interface's state and error counters handling with the new can-dev can_change_state() mechanism. Suggested-by: Andri Yngvason <andri.yngvason@marel.com> Signed-off-by: Ahmed S. Darwish <ahmed.darwish@valeo.com> Acked-by: Andri Yngvason <andri.yngvason@marel.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2015-01-28can: kvaser_usb: Update interface state before exiting on OOMAhmed S. Darwish1-76/+105
Update all of the can interface's state and error counters before trying any skb allocation that can actually fail with -ENOMEM. Suggested-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: Ahmed S. Darwish <ahmed.darwish@valeo.com> Acked-by: Andri Yngvason <andri.yngvason@marel.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2015-01-27stmmac: pci: add MSI support for Intel Quark X1000Kweh, Hock Leong1-0/+2
In Intel Quark SoC X1000, both of the Ethernet controllers support MSI interrupt handling. This patch enables them to use MSI interrupt servicing in stmmac_pci for Intel Quark X1000. Signed-off-by: Kweh, Hock Leong <hock.leong.kweh@intel.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27stmmac: pci: introduce Intel Quark X1000 runtime detectionAndy Shevchenko1-1/+61
This patch introduces run-time board detection through DMI and MAC-PHY configuration function used by quark_default_data() during initialization. It fills up the phy_addr for Galileo and Galileo Gen2 boards to indicate that the Ethernet MAC controller is or is not connected to any PHY. The implementation takes into consideration for future expansion in Quark series boards that may have different PHY address that is linked to its MAC controllers. This piece of work is derived from Bryan O'Donoghue's initial work for Quark X1000 enabling. Signed-off-by: Kweh, Hock Leong <hock.leong.kweh@intel.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27stmmac: pci: add support for Intel Quark X1000Kweh, Hock Leong1-1/+50
The Intel Quark SoC X1000 provides two 10/100 Mbps Ethernet MAC controllers which may or may not be connected to PHY on board. This MAC controller only supports RMII PHY. This patch add Quark PCI ID as well as Quark default platform data info to this driver. Signed-off-by: Kweh, Hock Leong <hock.leong.kweh@intel.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27net: netcp: remove unused kconfig option and codeKaricheri, Muralidharan2-2/+1
Currently CPTS is built into the netcp driver even though there is no call out to the CPTS driver. This patch removes the dependency in Kconfig and remove cpts.o from the Makefile for NetCP. Signed-off-by: Murali Karicheri <m-karicheri2@ti.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27cxgb4: Move firmware version MACRO to t4fw_version.hHariprasad Shenai3-10/+49
Move firmware version MACRO to a new t4fw_version.h file so that csiostor driver can also use it. Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27csiostor:T5 Firmware fix and cleanup.Praveen Madhavan3-256/+127
This patch fix is to use default firmware configuration files present in the adapter incase if not available in standard /lib/firmware/* dir. Additional cleanup is done to reuse flash related defines from cxgb4 header file. Please apply over net-next since it depends on previous commit. Signed-off-by: Praveen Madhavan <praveenm@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27net/mlx4_core: Update the HCA core clock frequency after INIT_PORTMajd Dibbiny1-0/+33
The firmware might change the hca core clock frequency after the driver issues the INIT_PORT command. Therefore we need to query the new value again and save in to the cached dev caps. Fixes: ddd8a6c1 ('net/mlx4_core: Read HCA frequency and map internal clock') Signed-off-by: Majd Dibbiny <majd@mellanox.com> Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com> Signed-off-by: Amir Vadai <amirv@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27net/mlx4_core: Fix device capabilities dumpingOr Gerlitz1-6/+2
We are dumping device capabilities which are supported both by the firmware and the driver. Align the array that holds the capability strings with this practice. Reported-by: Yuval Shaia <yuval.shaia@oracle.com> Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com> Signed-off-by: Amir Vadai <amirv@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27net/mlx4: Fix memory corruption in mlx4_MAD_IFC_wrapperMatan Barak1-1/+3
Fix a memory corruption at mlx4_MAD_IFC_wrapper. A table of size dev->caps.pkey_table_len[port]*sizeof(*table) was allocated, but get_full_pkey_table() assumes that the number of entries in the table is a multiplication of 32 (which isn't always correct). Fixes: 0a9a018 ('mlx4: MAD_IFC paravirtualization') Signed-off-by: Matan Barak <matanb@mellanox.com> Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com> Signed-off-by: Amir Vadai <amirv@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27net/mlx4_en: Use ethtool cmd->autoneg as a hint for ethtool set settingsSaeed Mahameed1-10/+8
Use cmd->autoneg as a user hint to decide what to set in ethtool set settings callback. When cmd->autoneg == AUTONEG_ENABLE set according to ethtool->advertise otherwise, set according to ethtool->speed. Usage: - ethtool -s eth<x> speed 56000 autoneg off - ethtool -s eth<x> advertise 0x800000 autoneg on While we're here: - Move proto_admin masking outcome check to be adjacent to the operation. - Move en_warn("port reset..") print to "port reset" block. Fixes: 312df74 ("net/mlx4_en: mlx4_en_set_settings() always fails when autoneg is set") Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: Amir Vadai <amirv@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27net/mlx4_core: Remove duplicate code line from procedure mlx4_bf_allocJack Morgenstein1-1/+0
mlx4_bf_alloc had an unnecessary/duplicate code line. Did no harm, but not good practice. Reported by the Mellanox Beijing team. Signed-off-by: Jack Morgenstein <jackm@dev.mellanox.co.il> Signed-off-by: Amir Vadai <amirv@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27net/mlx4_core: Fix struct mlx4_vhcr_cmd to make implicit padding explicitJack Morgenstein1-0/+1
Struct mlx4_vhcr was implicitly padded by the gcc compiler on 64-bit architectures. This commit makes that padding explicit, to prevent issues with changing compilers and with incompatibilities between 32-bit architecture implicit padding and 64-bit architecture implicit padding. This structure is used in virtualization for communication between the Host and its Guests. The explicit padding allows 64-bit Hosts (old and new) to continue to interoperate with 64-bit Guests (old and new). However, without this fix, 64-bit Hosts could not interoperate with 32-bit Guests (since these did not insert the padding dword). With this fix, 32-bit Guests will be able to interoperate with 64-bit Hosts (since the structure offsets will be identical on both). Reported-by: Alexander Schmidt <alexs@linux.vnet.ibm.com> Signed-off-by: Jack Morgenstein <jackm@dev.mellanox.co.il> Signed-off-by: Amir Vadai <amirv@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27net/mlx4_core: Fix HW2SW_EQ to conform to the firmware specJack Morgenstein3-35/+9
The driver incorrectly assigned an out-mailbox to this command, and used an opcode modifier = 0, which is a reserved value (it should use opcode modifier = 1). Signed-off-by: Jack Morgenstein <jackm@dev.mellanox.co.il> Signed-off-by: Amir Vadai <amirv@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27net/mlx4_core: Adjust command timeouts to conform to the firmware specJack Morgenstein2-11/+12
The firmware spec states that the timeout for all commands should be 60 seconds. In the past, the spec indicated that there were several classes of timeout (short, medium, and long). The driver has these different timeout classes. We leave the class differentiation in the driver as-is (to protect against any future spec changes), but set the timeout for all classes to be 60 seconds. In addition, we fix a few commands which had hard-coded numeric timeouts specified. Signed-off-by: Jack Morgenstein <jackm@dev.mellanox.co.il> Signed-off-by: Amir Vadai <amirv@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27net/mlx4_core: Fix mem leak in SRIOV mlx4_init_one error flowJack Morgenstein1-1/+3
Structs allocated for the resource tracker must be freed in the error flow. Signed-off-by: Jack Morgenstein <jackm@dev.mellanox.co.il> Signed-off-by: Amir Vadai <amirv@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27net/mlx4_core: Add reserved lkey for VFs to QUERY_FUNC_CAPJack Morgenstein3-2/+19
The reserved lKey is different for each VF. A base lkey value is returned in QUERY_DEV_CAP at offset 0x98. The reserved L_key value for a VF is: VF_lkey = base_lkey + (VF_number << 8). This VF L_key value should be returned in QUERY_FUNC_CAP (opcode-modifier = 0) at offset 0x48. To indicate that the lkey value at offset 0x48 is valid, the Hypervisor sets a flag bit in dword 0x0, offset 27 in the QUERY_FUNC_CAP wrapper function. When the VF calls QUERY_FUNC_CAP, it should check if this flag bit is set. If it is set, the VF should take the reserved lkey value at offset 0x48. If the bit is not set, the VF should not use a reserved lkey (i.e., should set its reserved lkey value to 0). Signed-off-by: Jack Morgenstein <jackm@dev.mellanox.co.il> Signed-off-by: Amir Vadai <amirv@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27net/mlx4_core: Add bad-cable event supportJack Morgenstein2-1/+30
If the firmware can detect a bad cable, allow it to generate an event, and print the problem in the log. Signed-off-by: Jack Morgenstein <jackm@dev.mellanox.co.il> Signed-off-by: Amir Vadai <amirv@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27vxlan: advertise link netns in fdb messagesNicolas Dichtel1-2/+3
Previous commit is based on a wrong assumption, fdb messages are always sent into the netns where the interface stands (see vxlan_fdb_notify()). These fdb messages doesn't embed the rtnl attribute IFLA_LINK_NETNSID, thus we need to add it (useful to interpret NDA_IFINDEX or NDA_DST for example). Note also that vxlan_nlmsg_size() was not updated. Fixes: 193523bf9373 ("vxlan: advertise netns of vxlan dev in fdb msg") Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27bonding: cleanup and remove dead codeJonathan Toppins1-1/+1
fix sparse warning about non-static function drivers/net/bonding/bond_main.c:3737:5: warning: symbol 'bond_3ad_xor_xmit' was not declared. Should it be static? Reviewed-by: Nikolay Aleksandrov <nikolay@redhat.com> Signed-off-by: Jonathan Toppins <jtoppins@cumulusnetworks.com> Signed-off-by: Jay Vosburgh <jay.vosburgh@canonical.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27bonding: fix LACP PDU not sent on slave port sometimesSatish Ashok1-3/+8
When a slave is added to a bond and it is not in full duplex mode, AD_PORT_LACP_ENABLED flag is cleared, due to this LACP PDU is not sent on slave. When the duplex is changed to full, the flag needs to be set to send LACP PDU. Cc: Andy Gospodarek <gospo@cumulusnetworks.com> Reviewed-by: Nikolay Aleksandrov <nikolay@redhat.com> Signed-off-by: Satish Ashok <sashok@cumulusnetworks.com> Signed-off-by: Jonathan Toppins <jtoppins@cumulusnetworks.com> Signed-off-by: Jay Vosburgh <jay.vosburgh@canonical.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27bonding: fix incorrect lacp mux state when agg not activeWilson Kok1-10/+34
This patch attempts to fix the following problems when an actor or partner's aggregator is not active: 1. a slave's lacp port state is marked as AD_STATE_SYNCHRONIZATION even if it is attached to an inactive aggregator. LACP advertises this state to the partner, making the partner think he can move into COLLECTING_DISTRIBUTING state even though this link will not pass traffic on the local side 2. a slave goes into COLLECTING_DISTRIBUTING state without checking if the aggregator is actually active 3. when in COLLECTING_DISTRIBUTING state, the partner parameters may change, e.g. the partner_oper_port_state.SYNCHRONIZATION. The local mux machine is not reacting to the change and continue to keep the slave and bond up 4. When bond slave leaves an inactive aggregator and joins an active aggregator, the actor oper port state need to update to SYNC state. v2: * fix style issues in bond_3ad.c Cc: Andy Gospodarek <gospo@cumulusnetworks.com> Reviewed-by: Nikolay Aleksandrov <nikolay@redhat.com> Signed-off-by: Wilson Kok <wkok@cumulusnetworks.com> Signed-off-by: Jonathan Toppins <jtoppins@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27bonding: fix bond_open() don't always set slave active flagWilson Kok1-1/+1
Mode 802.3ad, fix incorrect bond slave active state when slave is not in active aggregator. During bond_open(), the bonding driver always sets the slave active flag to true if the bond is not in active-backup, alb, or tlb modes. Bonding should let the aggregator selection logic set the active flag when in 802.3ad mode. Cc: Andy Gospodarek <gospo@cumulusnetworks.com> Reviewed-by: Nikolay Aleksandrov <nikolay@redhat.com> Signed-off-by: Wilson Kok <wkok@cumulusnetworks.com> Signed-off-by: Jonathan Toppins <jtoppins@cumulusnetworks.com> Signed-off-by: Jay Vosburgh <jay.vosburgh@canonical.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27bonding: update bond carrier state when min_links option changesJonathan Toppins2-1/+2
Cc: Andy Gospodarek <gospo@cumulusnetworks.com> Signed-off-by: Jonathan Toppins <jtoppins@cumulusnetworks.com> Signed-off-by: Jay Vosburgh <jay.vosburgh@canonical.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27hyperv: match wait_for_completion_timeout return typeNicholas Mc Guire1-7/+12
return type of wait_for_completion_timeout is unsigned long not int, this patch just fixes up the declarations. Signed-off-by: Nicholas Mc Guire <der.herr@hofr.at> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27hyperv: netvsc.c: match wait_for_completion_timeout return typeNicholas Mc Guire1-2/+3
Signed-off-by: Nicholas Mc Guire <der.herr@hofr.at> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-27Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netDavid S. Miller209-2197/+2618
Conflicts: arch/arm/boot/dts/imx6sx-sdb.dts net/sched/cls_bpf.c Two simple sets of overlapping changes. Signed-off-by: David S. Miller <davem@davemloft.net>
2015-01-28NFC: Add ACPI support for NXP PN544Robert Dolca1-2/+109
Currently there is no support for ACPI. This patch uses the following configuration: - Device id: NXP5440 - Pin mapping: - 0 IRQ pin - 1 enable pin - 2 firmware pin Signed-off-by: Robert Dolca <robert.dolca@intel.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-01-28NFC: PN544: GPIO access that may sleepRobert Dolca1-10/+12
gpio_set_value was replaced with gpio_set_value_cansleep in order to allow GPIO access that may sleep. This is particularelly useful when GPIO is accessed using busses like I2C, SPI, USB Signed-off-by: Robert Dolca <robert.dolca@intel.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-01-28NFC: st21nfca: Adding support for secure elementChristophe Ricard6-21/+606
st21nfca has 1 physical SWP line and can support up to 2 secure elements (UICC & eSE) thanks to an external switch managed with a gpio. The platform integrator needs to specify thanks to 2 initialization properties, uicc-present and ese-present, if it is suppose to have uicc and/or ese. Of course if the platform does not have an external switch, only one kind of secure element can be supported. Those parameters are under platform integrator responsibilities. During initialization, the white_list will be set according to those parameters. The discovery_se function will assume a secure element is physically present according to uicc-present and ese-present values and will add it to the secure element list. On ese activation, the atr is retrieved to calculate a command exchange timeout based on the first atr(TB) value. The se_io will allow to transfer data over SWP. 2 kind of events may appear after a data is sent over: - ST21NFCA_EVT_TRANSMIT_DATA when receiving an apdu answer - ST21NFCA_EVT_WTX_REQUEST when the secure element needs more time than expected to compute a command. If this timeout expired, a first recovery tentative consist to send a simple software reset proprietary command. If this tentative still fail, a second recovery tentative consist to send a hardware reset proprietary command. This function is only relevant for eSE like secure element. This patch also change the way a pipe is referenced. There can be different pipe connected to the same gate with different host destination (ex: CONNECTIVITY). In order to keep host information every pipe are reference with a tuple (gate, host). In order to reduce changes, we are keeping unchanged the way a gate is addressed on the Terminal Host. However, this is working because we consider the apdu reader gate is only present on the eSE slot also the connectivity gate cannot give a reliable value; it will give the latest stored pipe value. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-01-28NFC: microread: Change event_received gate parameter to pipeChristophe Ricard1-1/+2
The below event_received hci handler has change the gate parameter to pipe. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com>
2015-01-28NFC: pn544: Change event_received gate parameter to pipeChristophe Ricard1-1/+2
The below event_received hci handler has change the gate parameter to pipe. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com>
2015-01-27Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netLinus Torvalds22-256/+541
Pull networking fixes from David Miller: 1) Don't OOPS on socket AIO, from Christoph Hellwig. 2) Scheduled scans should be aborted upon RFKILL, from Emmanuel Grumbach. 3) Fix sleep in atomic context in kvaser_usb, from Ahmed S Darwish. 4) Fix RCU locking across copy_to_user() in bpf code, from Alexei Starovoitov. 5) Lots of crash, memory leak, short TX packet et al bug fixes in sh_eth from Ben Hutchings. 6) Fix memory corruption in SCTP wrt. INIT collitions, from Daniel Borkmann. 7) Fix return value logic for poll handlers in netxen, enic, and bnx2x. From Eric Dumazet and Govindarajulu Varadarajan. 8) Header length calculation fix in mac80211 from Fred Chou. 9) mv643xx_eth doesn't handle highmem correctly in non-TSO code paths. From Ezequiel Garcia. 10) udp_diag has bogus logic in it's hash chain skipping, copy same fix tcp diag used. From Herbert Xu. 11) amd-xgbe programs wrong rx flow control register, from Thomas Lendacky. 12) Fix race leading to use after free in ping receive path, from Subash Abhinov Kasiviswanathan. 13) Cache redirect routes otherwise we can get a heavy backlog of rcu jobs liberating DST_NOCACHE entries. From Hannes Frederic Sowa. * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (48 commits) net: don't OOPS on socket aio stmmac: prevent probe drivers to crash kernel bnx2x: fix napi poll return value for repoll ipv6: replacing a rt6_info needs to purge possible propagated rt6_infos too sh_eth: Fix DMA-API usage for RX buffers sh_eth: Check for DMA mapping errors on transmit sh_eth: Ensure DMA engines are stopped before freeing buffers sh_eth: Remove RX overflow log messages ping: Fix race in free in receive path udp_diag: Fix socket skipping within chain can: kvaser_usb: Fix state handling upon BUS_ERROR events can: kvaser_usb: Retry the first bulk transfer on -ETIMEDOUT can: kvaser_usb: Send correct context to URB completion can: kvaser_usb: Do not sleep in atomic context ipv4: try to cache dst_entries which would cause a redirect samples: bpf: relax test_maps check bpf: rcu lock must not be held when calling copy_to_user() net: sctp: fix slab corruption from use after free on INIT collisions net: mv643xx_eth: Fix highmem support in non-TSO egress path sh_eth: Fix serialisation of interrupt disable with interrupt & NAPI handlers ...