summaryrefslogtreecommitdiff
path: root/drivers/net
AgeCommit message (Collapse)Author
2019-01-30apalis-tk1: can: mfd: k20: use level interrupts and prioritize txDominik Sliwa
Prioritize CAN TX trafic, and move from edge to level triggered interrupts. Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com>
2018-09-27net: igb: implement SIOCSMIIREG and allow SIOCGMIIREG to set pagesApalis-TK1_LXDE-Image_2.8b4.129-20181005Dominik Sliwa
Before SIOCGMIIREG was only able to access page 0 registers. Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2018-09-27apalis-tk1: can: k20: change tx complete signalingDominik Sliwa
In fw version 1.2 K20 CANINTF_TX now indicates TX in progress, not TX completed. Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2018-03-28can: mfd: apalis-tk1: v1.1 frequency adjustments and various fixesDominik Sliwa
Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2018-03-28mfd: apalis-tk1-k20: single transaction register readDominik Sliwa
This change also modifies SPI clock for ezPort mode. Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2018-03-28can: mfd: apalis-tk1-k20:increased clock speed, zero copyDominik Sliwa
Increased SPI speed for transfers and peripheral speed. Switch to cleaning IRQ flags on read, instead of separate write. Switched to zero-copy on SPI reads. Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2017-11-29mfd: apalis-tk1: 0.11 fw supportDominik Sliwa
Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2017-10-06mfd: apalis-tk1-k20: clean-up and fix support for 0.10 k20 fwApalis-TK1_LXDE-Image_2.7b4-20171007Dominik Sliwa
Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2017-10-05mfd: apalis-tk1-k20: support for 0.10 k20 fwDominik Sliwa
Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2017-06-30apalis-tk1-k20: can and spi improvementsDominik Sliwa
This patch includes CAN driver and improvements in SPI communications for Apalis TK1 k20 based MFD. Requires firmware version 0.9. Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2017-04-04igb: integrate igb driver 5.3.5.4Marcel Ziswiler
Integrate latest igb driver version 5.3.5.4 (igb-5.3.5.4.tar.gz from e1000.sf.net). While this fixes a build time warning using later gcc compilers it should not have any further impact. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Acked-by: Dominik Sliwa <dominik.sliwa@toradex.com>
2016-06-29apalis_t30/tk1: igb: no nvm and Ethernet MAC address handlingMarcel Ziswiler
Springville/i211 with a blank Flash/iNVM use different PCI IDs. Extend the driver to load despite i210/i211 data sheets claiming tools only, not for driver. Only warn rather than fail on NVM validation failures on Apalis T30. Revise Ethernet MAC address assignment: should now handle up to two instances of custom user MACs (2nd one with a 0x100000 offset). This way customer does not have to worry about NVM on a secondary Ethernet on the carrier board and still gets a valid official MAC address from us (e.g. analogous to how we did it on our Protea carrier board). Use the Toradex OUI as default MAC address if no valid one is encountered. Tested on samples of Apalis T30 2GB V1.0B, V1.0C, V1.1A, Apalis T30 1GB V1.0A, V1.1A and Apalis T30 1GB IT V1.1A both with blank NVMs as well as iNVMs programmed with Intel's defaults. Tested on samples of Apalis TK1 2GB V1.0A and V1.0B both with blank NVMs as well as iNVMs programmed with Intel's defaults. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Acked-by: Dominik Sliwa <dominik.sliwa@toradex.com> (cherry picked from commit c4c3c7449bdb15c53bfebb0a29c73b24ea810d23)
2016-06-29igb: integrate tools only device supportMarcel Ziswiler
Springville/i211 with a blank Flash/iNVM use a different PCI ID (tools only, not for driver) than properly programmed ones. While at it also fix ethtool time stamping as well as RX flow hash indirection functionality. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Acked-by: Dominik Sliwa <dominik.sliwa@toradex.com> (cherry picked from commit 2c7123458270c9b3ec9b5ed668f9d55a7f8dbad9)
2016-06-29igb: integrate igb driver 5.3.5.3Marcel Ziswiler
Integrate latest igb driver version 5.3.5.3 (igb-5.3.5.3.tar.gz from e1000.sf.net). Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Acked-by: Dominik Sliwa <dominik.sliwa@toradex.com>
2015-08-19ax88179_178a: Correct the RX error definition in RX headerFreddy Xin
Correct the definition of AX_RXHDR_CRC_ERR and AX_RXHDR_DROP_ERR. They are BIT29 and BIT31 in pkt_hdr seperately. bug 200009821 Change-Id: Ib55e13899a68a86a847708500dccd475e2f0712a Signed-off-by: Freddy Xin <freddy@asix.com.tw> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: wtsai <wtsai@nvidia.com> Reviewed-on: http://git-master/r/434739 Reviewed-on: http://git-master/r/450229 (cherry picked from commit 67e4ec14734d8343116fe7a486de6ec0ad3b9e73) Reviewed-on: http://git-master/r/784056 GVS: Gerrit_Virtual_Submit Reviewed-by: ChihMin Cheng <ccheng@nvidia.com> Reviewed-by: Ashutosh Jha <ajha@nvidia.com>
2014-07-01net: wireless: bcmdhd: Fix LP0 in case of wifi tetheringManikanta
PROPTX_STATUS periodically sends useful information (such as flow control info, RSSI etc) to the host, this prevents host from going into LP0 mode. Disable dhd_pm_callback pm notifier to fix this issue. bug 200016824 Change-Id: I50c0fa61e6a183d203f8ef49b1ed81a060e81351 Signed-off-by: Manikanta <mmaddireddy@nvidia.com> Reviewed-on: http://git-master/r/432654 Reviewed-by: Nagarjuna Kristam <nkristam@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
2014-06-25net: wireless: bcmdhd: correct sdio_idsNagarjuna Kristam
Usage of SDIO_DEVICE(SDIO_VENDOR_ID_BROADCOM, SDIO_ANY_ID) is causing device hang when BRCM chipsets BCM433341 are used. This is because SDIO_DEVICE MACRO uses, SDIO_ANY_ID for class. Use SDIO_CLASS_NONE instead resolves device hang issue. Bug 1527370 Change-Id: I9af6e7598893663afa7629e822a5934f12c128fa Signed-off-by: Nagarjuna Kristam <nkristam@nvidia.com> Reviewed-on: http://git-master/r/427780 (cherry picked from commit eab2794d3420cc31218709410afd0feab48ced6b) Reviewed-on: http://git-master/r/427779 Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
2014-06-20net: wireless: bcmdhd: correct sdio_idsNagarjuna Kristam
BCMDHD driver uses SDIO_DEVICE_CLASS(SDIO_CLASS_NONE) ID during sdio register process. This causes brcm driver execution, when other SDIO peripherals with class 0 are used. Replace SDIO_DEVICE_CLASS(SDIO_CLASS_NONE) usage by SDIO_DEVICE(SDIO_VENDOR_ID_BROADCOM, SDIO_ANY_ID), to ensure bcmdhd driver execution for Broadcom only hardware. Bug 200013331 Change-Id: Ia31be2940b7e523e30c0740155a567e324da6be1 Signed-off-by: Nagarjuna Kristam <nkristam@nvidia.com> Reviewed-on: http://git-master/r/424260 Reviewed-by: Seema Khowala <seemaj@nvidia.com> Tested-by: Seema Khowala <seemaj@nvidia.com> Reviewed-by: Mitch Luban <mluban@nvidia.com>
2014-06-11drivers: use request_firmware_nowait() instead of request_firmware()Manikanta
During boot request_firmware API call waits for the system partition to mount, whereas kernel gets stuck at request_firmware API call, stalling kernel boot for 60 seconds [Timeout for request firmware]. Use request_firmware_nowait API to avoid deadlock. bug 1520734 bug 200008011 Change-Id: I5a7fcb720c407236108bcac7f36c52b2cd47ee27 Signed-off-by: Manikanta <mmaddireddy@nvidia.com> Reviewed-on: http://git-master/r/420452 GVS: Gerrit_Virtual_Submit Reviewed-by: Nagarjuna Kristam <nkristam@nvidia.com> Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
2014-06-05Merge branch 'linux-3.10.40' into rel-21Ishan Mittal
Bug 200004122 Conflicts: drivers/cpufreq/cpufreq.c drivers/regulator/core.c sound/soc/codecs/max98090.c Change-Id: I9418a05ad5c56b2e902249218bac2fa594d99f56 Signed-off-by: Ishan Mittal <imittal@nvidia.com>
2014-05-30net: wireless: bcmdhd: optimize scan timeNarayan Reddy
modify DHD_SCAN_UNASSOC_ACTIVE_TIME and DHD_SCAN_ASSOC_ACTIVE_TIME to 65 and 35 msec to save 300 msec of active scan time in non associated state and 100 msec in case of associated state. Bug 1496192 Change-Id: I902400763d0e64ee020ff4650253e4934527c0e3 Signed-off-by: Narayan Reddy <narayanr@nvidia.com> Reviewed-on: http://git-master/r/407443 (cherry picked from commit aa34b71e8b235eb2d05e4d2b099bcae36c7d0a02) Signed-off-by: Manikanta <mmaddireddy@nvidia.com> Reviewed-on: http://git-master/r/408717 Reviewed-by: Nagarjuna Kristam <nkristam@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
2014-05-28net: wireless: bcmdhd: enable DHD flags for bcmdhd driverManikanta
enable DHD flags to optimize the bcmdhd driver wrt bcm43241 TOE - Enable TCP offload engine RXFRAME_THREAD - Create RX frame thread DHDTCPACKSUPRESS - Fake push BDC header for pkt in delayed q bug 200008015 Change-Id: I27134f136220e2bbfa8c4fcda83331ca5dbddf98 Signed-off-by: Manikanta <mmaddireddy@nvidia.com> Reviewed-on: http://git-master/r/415096 Reviewed-by: Narayan Reddy <narayanr@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
2014-05-27net: wireless: Disable chip retry logicNagarjuna Kristam
For tegra reference devices, WiFI pre-power is enabled, which performs chip identification during MMC driver intialization. Disable Chip retry logic, if CONFIG_TEGRA_PREPOWER_WIFI is enabled Bug 1438249 Bug 1467982 Change-Id: I08777052f7333915c06257671e72bf5899d98185 Signed-off-by: Nagarjuna Kristam <nkristam@nvidia.com> Reviewed-on: http://git-master/r/402352 (cherry picked from commit a098912da0ae29f22c30ffca31e9f97ccd84a5a7) Reviewed-on: http://git-master/r/408748 Reviewed-by: Manikanta Maddireddy <mmaddireddy@nvidia.com> Reviewed-by: Venu Byravarasu <vbyravarasu@nvidia.com> GVS: Gerrit_Virtual_Submit
2014-05-27net: wireless: sd8897: update Kconfig and MakefileNagarjuna Kristam
- Update Makefile to compile based on option in defconfig - Update default module params, for proper driver initialization when compiled part of kernel Bug 1438249 Bug 1467982 Change-Id: If79ed1ee36cd27ec9c47b244184c73e96bcf5eec Signed-off-by: Nagarjuna Kristam <nkristam@nvidia.com> Reviewed-on: http://git-master/r/355031 (cherry picked from commit 547efef53edc38a1972e127c59c363a77b716e12) Reviewed-on: http://git-master/r/408745 Reviewed-by: Manikanta Maddireddy <mmaddireddy@nvidia.com> Reviewed-by: Venu Byravarasu <vbyravarasu@nvidia.com> GVS: Gerrit_Virtual_Submit
2014-05-23net: wireless: bcmdhd: remove CUSTOM_GLOM_SETTINGManikanta
Remove CUSTOM_GLOM_SETTING from Makefile, this allows firmware to set default glomming algortihm. This improves tcp tx throughput. bug 200003229 Change-Id: Ib92e267fd10ce13af455b100c8cda4d2af8420d9 Signed-off-by: Manikanta <mmaddireddy@nvidia.com> Reviewed-on: http://git-master/r/408715 Reviewed-by: Riham Haidar <rhaidar@nvidia.com> Tested-by: Riham Haidar <rhaidar@nvidia.com>
2014-05-23net: wireless: use CONFIG_BCMDHD_HW_OOB to enable HW_OOB and OOB_INTR_ONLYSeshagir.H
Enable HW_OOB and OOB_INTR_ONLY when CONFIG_BCMDHD_HW_OOB is set, else enable SDIO_ISR_THREAD bug 200001046 Change-Id: Icd72c7ffe8bdcfe5b7b15139153ec117c86f2569 Signed-off-by: Seshagir.H <sholi@nvidia.com> Reviewed-on: http://git-master/r/403380 Reviewed-by: Venu Byravarasu <vbyravarasu@nvidia.com> (cherry picked from commit c8fd6f8c298dc8a2f6045df6220d0c0838b0a6b9) Reviewed-on: http://git-master/r/404240 Reviewed-by: Phoenix Jung <pjung@nvidia.com> Reviewed-by: Sandeep Trasi <strasi@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
2014-05-13rtlwifi: rtl8188ee: initialize packet_beaconColin Ian King
commit 328e203fc35f0b4f6df1c4943f74cf553bcc04f8 upstream. static code analysis from cppcheck reports: [drivers/net/wireless/rtlwifi/rtl8188ee/trx.c:322]: (error) Uninitialized variable: packet_beacon packet_beacon is not initialized and hence packet_beacon contains garbage from the stack, so set it to false. Signed-off-by: Colin Ian King <colin.king@canonical.com> Acked-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-13rtlwifi: rtl8192se: Fix regression due to commit 1bf4bbbLarry Finger
commit 5f9186990ec4579ee5b7a99b3254c29eda479f36 upstream. Beginning with kernel 3.13, this driver fails on some systems. The problem was bisected to: Commit 1bf4bbb4024dcdab5e57634dd8ae1072d42a53ac Author: Felix Fietkau <nbd@openwrt.org> Title: mac80211: send control port protocol frames to the VO queue There is noting wrong with the above commit. The regression occurs because V0 queue on RTL8192SE cards uses priority 6, not the usual 7. The fix is to modify the rtl8192se routine that sets the correct transmit queue. Bug: https://bugzilla.kernel.org/show_bug.cgi?id=74541 Reported-by: Alex Miller <almiller_1@yahoo.co.uk> Tested-by: Alex Miller <almiller_1@yahoo.co.uk> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-13rtlwifi: rtl8192se: Fix too long disable of IRQsLarry Finger
commit 2610decdd0b3808ba20471a999835cfee5275f98 upstream. In commit f78bccd79ba3cd9d9664981b501d57bdb81ab8a4 entitled "rtlwifi: rtl8192ce: Fix too long disable of IRQs", Olivier Langlois <olivier@trillion01.com> fixed a problem caused by an extra long disabling of interrupts. This patch makes the same fix for rtl8192se. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-13rtlwifi: rtl8192cu: Fix too long disable of IRQsLarry Finger
commit a53268be0cb9763f11da4f6fe3fb924cbe3a7d4a upstream. In commit f78bccd79ba3cd9d9664981b501d57bdb81ab8a4 entitled "rtlwifi: rtl8192ce: Fix too long disable of IRQs", Olivier Langlois <olivier@trillion01.com> fixed a problem caused by an extra long disabling of interrupts. This patch makes the same fix for rtl8192cu. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-13rtlwifi: rtl8188ee: Fix too long disable of IRQsLarry Finger
commit 6b6392715856d563719991e9ce95e773491a8983 upstream. In commit f78bccd79ba3cd9d9664981b501d57bdb81ab8a4 entitled "rtlwifi: rtl8192ce: Fix too long disable of IRQs", Olivier Langlois <olivier@trillion01.com> fixed a problem caused by an extra long disabling of interrupts. This patch makes the same fix for rtl8188ee. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-13rtlwifi: rtl8723ae: Fix too long disable of IRQsLarry Finger
commit bfc1010c418a22cbebd8b1bd1e75dad6a527a609 upstream. In commit f78bccd79ba3cd9d9664981b501d57bdb81ab8a4 entitled "rtlwifi: rtl8192ce: Fix too long disable of IRQs", Olivier Langlois <olivier@trillion01.com> fixed a problem caused by an extra long disabling of interrupts. This patch makes the same fix for rtl8723ae. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-13iwlwifi: dvm: take mutex when sending SYNC BT config commandEmmanuel Grumbach
commit 82e5a649453a3cf23516277abb84273768a1592b upstream. There is a flow in which we send the host command in SYNC mode, but we don't take priv->mutex. Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1046495 Reviewed-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-13b43: Fix machine check error due to improper access of B43_MMIO_PSM_PHY_HDRRafał Miłecki
commit 12cd43c6ed6da7bf7c5afbd74da6959cda6d056b upstream. Register B43_MMIO_PSM_PHY_HDR is 16 bit one, so accessing it with 32b functions isn't safe. On my machine it causes delayed (!) CPU exception: Disabling lock debugging due to kernel taint mce: [Hardware Error]: CPU 0: Machine Check Exception: 4 Bank 4: b200000000070f0f mce: [Hardware Error]: TSC 164083803dc mce: [Hardware Error]: PROCESSOR 2:20fc2 TIME 1396650505 SOCKET 0 APIC 0 microcode 0 mce: [Hardware Error]: Run the above through 'mcelog --ascii' mce: [Hardware Error]: Machine check: Processor context corrupt Kernel panic - not syncing: Fatal machine check on current CPU Kernel Offset: 0x0 from 0xffffffff81000000 (relocation range: 0xffffffff80000000-0xffffffff9fffffff) Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Acked-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-12net: wireless: bcmdhd: handle roam indicationNarayan Reddy
When user modifies any settings in AP, wlan driver does a reconnection on its own and after connection is re-established, reports it as ROAM_EVENT to cfg. Sometimes bss information of that particular bssid gets expired in the cfg80211 which is resulting in the WARN_ON in cfg80211_roamed function. So skip roaming indication to cfg80211 layer if it is connected to the same BSSID Bug 1500472 Change-Id: I67b9466840451d65a3d7558fc14294ecf1ccf865 Signed-off-by: Narayan Reddy <narayanr@nvidia.com> Reviewed-on: http://git-master/r/403994 (cherry picked from commit 56e52b147181ca3489e0090072d6d5fc42be0f1d) Signed-off-by: Manikanta <mmaddireddy@nvidia.com> Reviewed-on: http://git-master/r/408004 Reviewed-by: Nagarjuna Kristam <nkristam@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
2014-05-06net: wireless: bcmdhd: Fix card detection race conditionManikanta
On non built-in platform device cases mmc_rescan will initiated by mmc stack and android wifi device. So stop the card detection on mmc device probe, Since card detection is completed. So that we can avoid mmc_rescan initiation after power save done in sdio client driver probe. bug 1492308 bug 200000066 Change-Id: I26165399c463878f1f8acc76cb6174c83bf81b56 Signed-off-by: Manikanta <mmaddireddy@nvidia.com> Reviewed-on: http://git-master/r/404975 GVS: Gerrit_Virtual_Submit Reviewed-by: Mohan Thadikamalla <mohant@nvidia.com> Reviewed-by: Narayan Reddy <narayanr@nvidia.com> Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
2014-05-01net: wireless: bcmdhd: Set KSO enable sleep to 5msMohan T
The HW time requirements to wake up the BRCM chip is about 5ms. 3ms sleep time is too aggressive for wake up, due to which CMD CRC is observed. So change the sleep for KSO bit set from 3ms to 5ms. Bug 1456241 Bug 1500578 Change-Id: Ia20b173a7730cff2356e62eb57baddb09d24a784 Signed-off-by: Mohan T <mohant@nvidia.com> Reviewed-on: http://git-master/r/399663 Reviewed-on: http://git-master/r/403760 Reviewed-by: Narayan Reddy <narayanr@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com> GVS: Gerrit_Virtual_Submit
2014-04-23r8152: add IOCTLHayes Wang
Add IOCTL which could be used by PG tool. Change-Id: Iafbe78e42441afeda36f91e5c1f8c2ad91cbf9a4 Signed-off-by: Hayes Wang <hayeswang@realtek.com> Signed-off-by: Aly Hirani <ahirani@nvidia.com> Reviewed-on: http://git-master/r/390301 (cherry picked from commit 75054cd9e838444a3534827604f365b9ca826c5c) Reviewed-on: http://git-master/r/396904 Reviewed-by: Preetham Chandru <pchandru@nvidia.com> Tested-by: Preetham Chandru <pchandru@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
2014-04-23r8152: disable the ECM modehayeswang
There are known issues for switching the drivers between ECM mode and vendor mode. The interrup transfer may become abnormal. The hardware may have the opportunity to die if you change the configuration without unloading the current driver first, because all the control transfers of the current driver would fail after the command of switching the configuration. Although to use the ecm driver and vendor driver independently is fine, it may have problems to change the driver from one to the other by switching the configuration. Additionally, now the vendor mode driver is more powerful than the ECM driver. Thus, disable the ECM mode driver, and let r8152 to set the configuration to vendor mode and reset the device automatically. Change-Id: I2ba697b2afe83ca6e220007af0ceaa6b83e281f4 Signed-off-by: Hayes Wang <hayeswang@realtek.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Aly Hirani <ahirani@nvidia.com> Reviewed-on: http://git-master/r/390288 (cherry picked from commit f212e29aefa37cbad3e851733410cc8accb1f65c) Reviewed-on: http://git-master/r/396903 Reviewed-by: Preetham Chandru <pchandru@nvidia.com> Tested-by: Preetham Chandru <pchandru@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
2014-04-23r8152: support dumping the hw countershayeswang
Add dumping the tally counter by ethtool. Change-Id: I302202fe31e01b2857c76f98637e9ad5c1edb412 Signed-off-by: Hayes Wang <hayeswang@realtek.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Aly Hirani <ahirani@nvidia.com> Reviewed-on: http://git-master/r/390300 (cherry picked from commit 0816ece0a6581f465489ca5a01b2d95cef5f5af2) Reviewed-on: http://git-master/r/396902 Reviewed-by: Preetham Chandru <pchandru@nvidia.com> Tested-by: Preetham Chandru <pchandru@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
2014-04-23r8152: add skb_cow_headhayeswang
Call skb_cow_head() before editing the tx packet header. The header would be reallocated if it is shared. Change-Id: I6b3aef7acf215692eec02da679f356be614a9585 Signed-off-by: Hayes Wang <hayeswang@realtek.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Aly Hirani <ahirani@nvidia.com> Reviewed-on: http://git-master/r/390299 (cherry picked from commit a51ef337214b4d1a848d5c3279aec4718f1be36a) Reviewed-on: http://git-master/r/396901 Reviewed-by: Preetham Chandru <pchandru@nvidia.com> Tested-by: Preetham Chandru <pchandru@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
2014-04-23r8152: support IPv6hayeswang
Support hw IPv6 checksum for TCP and UDP packets. Note that the hw has the limitation of the range of the transport offset. Besides, the TCP Pseudo Header of the IPv6 TSO of the hw bases on the Microsoft document which excludes the packet length. Change-Id: I12aba3407f1894e2a161779fc19c075040ce5a6e Signed-off-by: Hayes Wang <hayeswang@realtek.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Aly Hirani <ahirani@nvidia.com> Reviewed-on: http://git-master/r/390298 (cherry picked from commit 4e218fd34b612339ad636db2182291fd347c146d) Reviewed-on: http://git-master/r/396900 Reviewed-by: Preetham Chandru <pchandru@nvidia.com> Tested-by: Preetham Chandru <pchandru@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
2014-04-23r8152: support TSOhayeswang
Support scatter gather and TSO. Adjust the tx checksum function and set the max gso size to fix the size of the tx aggregation buffer. Change-Id: Iff3dde25a2329fb47de6a5b6bfce92f260276992 Signed-off-by: Hayes Wang <hayeswang@realtek.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Aly Hirani <ahirani@nvidia.com> Reviewed-on: http://git-master/r/390297 (cherry picked from commit 5af199861e22e25c0454676b992298ddfe4d6111) Reviewed-on: http://git-master/r/396899 Reviewed-by: Preetham Chandru <pchandru@nvidia.com> Tested-by: Preetham Chandru <pchandru@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
2014-04-23r8152: support rx checksumhayeswang
Support hw rx checksum for TCP and UDP packets. Change-Id: I3bb3cefe4d9dbd98996fa975256545f35f393eae Signed-off-by: Hayes Wang <hayeswang@realtek.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Aly Hirani <ahirani@nvidia.com> Reviewed-on: http://git-master/r/390296 (cherry picked from commit 930a7af20283f78e3f5e5e4c70615c84c1ee29f6) Reviewed-on: http://git-master/r/396898 Reviewed-by: Preetham Chandru <pchandru@nvidia.com> Tested-by: Preetham Chandru <pchandru@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
2014-04-23r8152: calculate the dropped packets for rxhayeswang
Continue dealing with the remain rx packets, even though the allocation of the skb fail. This could calculate the correct dropped packets. Change-Id: Ic7fbe722e41b379f0bcf892356c9b00eacae82dc Signed-off-by: Hayes Wang <hayeswang@realtek.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Aly Hirani <ahirani@nvidia.com> Reviewed-on: http://git-master/r/390295 (cherry picked from commit 36eb4f48ca9366207524859b84e439c8fb0ed6f2) Reviewed-on: http://git-master/r/396897 Reviewed-by: Preetham Chandru <pchandru@nvidia.com> Tested-by: Preetham Chandru <pchandru@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
2014-04-23r8152: up the priority of the transmissionhayeswang
move the tx_bottom() from delayed_work to tasklet. It makes the rx and tx balanced. If the device is in runtime suspend when getting the tx packet, wakeup the device before trasmitting. Change-Id: Ib200ea8e98de1425d2e95185e75766b763619623 Signed-off-by: Hayes Wang <hayeswang@realtek.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Aly Hirani <ahirani@nvidia.com> Reviewed-on: http://git-master/r/390294 (cherry picked from commit 46737054c934399d0e7f1ea9723620e250f74e9a) Reviewed-on: http://git-master/r/396896 Reviewed-by: Preetham Chandru <pchandru@nvidia.com> Tested-by: Preetham Chandru <pchandru@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
2014-04-23r8152: check tx agg list before spin lockhayeswang
Check tx agg list before spin lock to avoid doing spin lock every times. Change-Id: I6f2533252659317642f49b2260af1e1b00c0081b Signed-off-by: Hayes Wang <hayeswang@realtek.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Aly Hirani <ahirani@nvidia.com> Reviewed-on: http://git-master/r/390293 (cherry picked from commit ff50c75cf61bd8ec3187a6e995e8b50ff032994c) Reviewed-on: http://git-master/r/396895 Reviewed-by: Preetham Chandru <pchandru@nvidia.com> Tested-by: Preetham Chandru <pchandru@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
2014-04-23r8152: replace spin_lock_irqsave and spin_unlock_irqrestorehayeswang
Use spin_lock and spin_unlock in interrupt context. The ndo_start_xmit would not be called in interrupt context, so replace the relative spin_lock_irqsave and spin_unlock_irqrestore with spin_lock_bh and spin_unlock_bh. Change-Id: I1a1764c0e3785efb6a72c14702763d9e516f794a Signed-off-by: Hayes Wang <hayeswang@realtek.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Aly Hirani <ahirani@nvidia.com> Reviewed-on: http://git-master/r/390292 (cherry picked from commit f6ef437cdfb0f7ea777242158d4bde29ac5ab8f0) Reviewed-on: http://git-master/r/396894 Reviewed-by: Preetham Chandru <pchandru@nvidia.com> Tested-by: Preetham Chandru <pchandru@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
2014-04-23r8152: remove rtl8152_get_statshayeswang
The rtl8152_get_stats() returns the point address of the struct net_device_stats. This could be got from struct net_device directly. Change-Id: Icfd675c4b637497a5f20700041a064a81a351a46 Signed-off-by: Hayes Wang <hayeswang@realtek.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Aly Hirani <ahirani@nvidia.com> Reviewed-on: http://git-master/r/390291 (cherry picked from commit 1e474e3346d583776f18abc9590d99ef55f1f84d) Reviewed-on: http://git-master/r/396893 Reviewed-by: Preetham Chandru <pchandru@nvidia.com> Tested-by: Preetham Chandru <pchandru@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
2014-04-23r8152: replace tp->netdev with netdevhayeswang
Replace some tp->netdev with netdev. Change-Id: Id349fa97584b7b340ee53f0d31279c657c06249c Signed-off-by: Hayes Wang <hayeswang@realtek.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Aly Hirani <ahirani@nvidia.com> Reviewed-on: http://git-master/r/390290 (cherry picked from commit fc179da3affa34c183403b1c70e7f5b95b619972) Reviewed-on: http://git-master/r/396892 Reviewed-by: Preetham Chandru <pchandru@nvidia.com> Tested-by: Preetham Chandru <pchandru@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>