···1Linux* Base Driver for the Intel(R) PRO/1000 Family of Adapters2===============================================================34-September 26, 20065-67Contents8========910-- In This Release11- Identifying Your Adapter12-- Building and Installation13- Command Line Parameters14- Speed and Duplex Configuration15- Additional Configurations16-- Known Issues17- Support18-19-20-In This Release21-===============22-23-This file describes the Linux* Base Driver for the Intel(R) PRO/1000 Family24-of Adapters. This driver includes support for Itanium(R)2-based systems.25-26-For questions related to hardware requirements, refer to the documentation27-supplied with your Intel PRO/1000 adapter. All hardware requirements listed28-apply to use with Linux.29-30-The following features are now available in supported kernels:31- - Native VLANs32- - Channel Bonding (teaming)33- - SNMP34-35-Channel Bonding documentation can be found in the Linux kernel source:36-/Documentation/networking/bonding.txt37-38-The driver information previously displayed in the /proc filesystem is not39-supported in this release. Alternatively, you can use ethtool (version 1.640-or later), lspci, and ifconfig to obtain the same information.41-42-Instructions on updating ethtool can be found in the section "Additional43-Configurations" later in this document.44-45-NOTE: The Intel(R) 82562v 10/100 Network Connection only provides 10/10046-support.47-4849Identifying Your Adapter50========================···19For more information on how to identify your adapter, go to the Adapter &20Driver ID Guide at:2122- http://support.intel.com/support/network/adapter/pro100/21397.htm2324For the latest Intel network drivers for Linux, refer to the following25website. In the search field, enter your adapter name or type, or use the26networking link on the left to search for your adapter:2728- http://downloadfinder.intel.com/scripts-df/support_intel.asp29-3031Command Line Parameters32=======================33-34-If the driver is built as a module, the following optional parameters35-are used by entering them on the command line with the modprobe command36-using this syntax:37-38- modprobe e1000 [<option>=<VAL1>,<VAL2>,...]39-40-For example, with two PRO/1000 PCI adapters, entering:41-42- modprobe e1000 TxDescriptors=80,12843-44-loads the e1000 driver with 80 TX descriptors for the first adapter and45-128 TX descriptors for the second adapter.4647The default value for each parameter is generally the recommended setting,48unless otherwise noted.···41 RxIntDelay, TxIntDelay, RxAbsIntDelay, and TxAbsIntDelay42 parameters, see the application note at:43 http://www.intel.com/design/network/applnots/ap450.htm44-45- A descriptor describes a data buffer and attributes related to46- the data buffer. This information is accessed by the hardware.47-4849AutoNeg50-------···55NOTE: Refer to the Speed and Duplex section of this readme for more56 information on the AutoNeg parameter.5758-59Duplex60------61(Supported only on adapters with copper connections)···67link partner is forced (either full or half), Duplex defaults to half-68duplex.6970-71FlowControl72-----------73Valid Range: 0-3 (0=none, 1=Rx only, 2=Tx only, 3=Rx&Tx)···75This parameter controls the automatic generation(Tx) and response(Rx)76to Ethernet PAUSE frames.7778-79InterruptThrottleRate80---------------------81(not supported on Intel(R) 82542, 82543 or 82544-based adapters)82-Valid Range: 0,1,3,100-100000 (0=off, 1=dynamic, 3=dynamic conservative)083Default Value: 38485The driver can limit the amount of interrupts per second that the adapter86-will generate for incoming packets. It does this by writing a value to the 87-adapter that is based on the maximum amount of interrupts that the adapter 88will generate per second.8990Setting InterruptThrottleRate to a value greater or equal to 100···93load on the system and can lower CPU utilization under heavy load,94but will increase latency as packets are not processed as quickly.9596-The default behaviour of the driver previously assumed a static 97-InterruptThrottleRate value of 8000, providing a good fallback value for 98-all traffic types,but lacking in small packet performance and latency. 99-The hardware can handle many more small packets per second however, and 100for this reason an adaptive interrupt moderation algorithm was implemented.101102Since 7.3.x, the driver has two adaptive modes (setting 1 or 3) in which103-it dynamically adjusts the InterruptThrottleRate value based on the traffic 104that it receives. After determining the type of incoming traffic in the last105-timeframe, it will adjust the InterruptThrottleRate to an appropriate value 106for that traffic.107108The algorithm classifies the incoming traffic every interval into109-classes. Once the class is determined, the InterruptThrottleRate value is 110-adjusted to suit that traffic type the best. There are three classes defined: 111"Bulk traffic", for large amounts of packets of normal size; "Low latency",112for small amounts of traffic and/or a significant percentage of small113-packets; and "Lowest latency", for almost completely small packets or 114minimal traffic.115116-In dynamic conservative mode, the InterruptThrottleRate value is set to 4000 117-for traffic that falls in class "Bulk traffic". If traffic falls in the "Low 118-latency" or "Lowest latency" class, the InterruptThrottleRate is increased 119stepwise to 20000. This default mode is suitable for most applications.120121For situations where low latency is vital such as cluster or122grid computing, the algorithm can reduce latency even more when123InterruptThrottleRate is set to mode 1. In this mode, which operates124-the same as mode 3, the InterruptThrottleRate will be increased stepwise to 12570000 for traffic in class "Lowest latency".000000126127Setting InterruptThrottleRate to 0 turns off any interrupt moderation128and may improve small packet latency, but is generally not suitable···165 be platform-specific. If CPU utilization is not a concern, use166 RX_POLLING (NAPI) and default driver settings.167168-169-170RxDescriptors171-------------172Valid Range: 80-256 for 82542 and 82543-based adapters···176incoming packets, at the expense of increased system memory utilization.177178Each descriptor is 16 bytes. A receive buffer is also allocated for each179-descriptor and can be either 2048, 4096, 8192, or 16384 bytes, depending 180on the MTU setting. The maximum MTU size is 16110.181182-NOTE: MTU designates the frame size. It only needs to be set for Jumbo 183- Frames. Depending on the available system resources, the request 184- for a higher number of receive descriptors may be denied. In this 185 case, use a lower number.186-187188RxIntDelay189----------···204 restoring the network connection. To eliminate the potential205 for the hang ensure that RxIntDelay is set to 0.206207-208RxAbsIntDelay209-------------210(This parameter is supported only on 82540, 82545 and later adapters.)···217along with RxIntDelay, may improve traffic throughput in specific network218conditions.219220-221Speed222-----223(This parameter is supported only on adapters with copper connections.)···227(Mbps). If this parameter is not specified or is set to 0 and the link228partner is set to auto-negotiate, the board will auto-detect the correct229speed. Duplex should also be set when Speed is set to either 10 or 100.230-231232TxDescriptors233-------------···242 higher number of transmit descriptors may be denied. In this case,243 use a lower number.244000000000000000000000000000000245246TxIntDelay247----------···283efficiency if properly tuned for specific network traffic. If the284system is reporting dropped transmits, this value may be set too high285causing the driver to run out of available transmit descriptors.286-287288TxAbsIntDelay289-------------···306A value of '1' indicates that the driver should enable IP checksum307offload for received packets (both UDP and TCP) to the adapter hardware.30800000000000000000000000000000309310Speed and Duplex Configuration311==============================···390parameter should not be used. Instead, use the Speed and Duplex parameters391previously mentioned to force the adapter to the same speed and duplex.392393-394Additional Configurations395=========================396-397- Configuring the Driver on Different Distributions398- -------------------------------------------------399- Configuring a network driver to load properly when the system is started400- is distribution dependent. Typically, the configuration process involves401- adding an alias line to /etc/modules.conf or /etc/modprobe.conf as well402- as editing other system startup scripts and/or configuration files. Many403- popular Linux distributions ship with tools to make these changes for you.404- To learn the proper way to configure a network device for your system,405- refer to your distribution documentation. If during this process you are406- asked for the driver or module name, the name for the Linux Base Driver407- for the Intel(R) PRO/1000 Family of Adapters is e1000.408-409- As an example, if you install the e1000 driver for two PRO/1000 adapters410- (eth0 and eth1) and set the speed and duplex to 10full and 100half, add411- the following to modules.conf or or modprobe.conf:412-413- alias eth0 e1000414- alias eth1 e1000415- options e1000 Speed=10,100 Duplex=2,1416-417- Viewing Link Messages418- ---------------------419- Link messages will not be displayed to the console if the distribution is420- restricting system messages. In order to see network driver link messages421- on your console, set dmesg to eight by entering the following:422-423- dmesg -n 8424-425- NOTE: This setting is not saved across reboots.426427 Jumbo Frames428 ------------···411 setting in a different location.412413 Notes:414-415- - To enable Jumbo Frames, increase the MTU size on the interface beyond416- 1500.00417418 - The maximum MTU setting for Jumbo Frames is 16110. This value coincides419 with the maximum Jumbo Frames size of 16128.···423 - Using Jumbo Frames at 10 or 100 Mbps may result in poor performance or424 loss of link.425426- - Some Intel gigabit adapters that support Jumbo Frames have a frame size427- limit of 9238 bytes, with a corresponding MTU size limit of 9216 bytes.428- The adapters with this limitation are based on the Intel(R) 82571EB,429- 82572EI, 82573L and 80003ES2LAN controller. These correspond to the430- following product names:431- Intel(R) PRO/1000 PT Server Adapter432- Intel(R) PRO/1000 PT Desktop Adapter433- Intel(R) PRO/1000 PT Network Connection434- Intel(R) PRO/1000 PT Dual Port Server Adapter435- Intel(R) PRO/1000 PT Dual Port Network Connection436- Intel(R) PRO/1000 PF Server Adapter437- Intel(R) PRO/1000 PF Network Connection438- Intel(R) PRO/1000 PF Dual Port Server Adapter439- Intel(R) PRO/1000 PB Server Connection440- Intel(R) PRO/1000 PL Network Connection441- Intel(R) PRO/1000 EB Network Connection with I/O Acceleration442- Intel(R) PRO/1000 EB Backplane Connection with I/O Acceleration443- Intel(R) PRO/1000 PT Quad Port Server Adapter444-445 - Adapters based on the Intel(R) 82542 and 82573V/E controller do not446 support Jumbo Frames. These correspond to the following product names:447 Intel(R) PRO/1000 Gigabit Server Adapter448 Intel(R) PRO/1000 PM Network Connection449-450- - The following adapters do not support Jumbo Frames:451- Intel(R) 82562V 10/100 Network Connection452- Intel(R) 82566DM Gigabit Network Connection453- Intel(R) 82566DC Gigabit Network Connection454- Intel(R) 82566MM Gigabit Network Connection455- Intel(R) 82566MC Gigabit Network Connection456- Intel(R) 82562GT 10/100 Network Connection457- Intel(R) 82562G 10/100 Network Connection458-459460 Ethtool461 -------···437 The latest release of ethtool can be found from438 http://sourceforge.net/projects/gkernel.439440- NOTE: Ethtool 1.6 only supports a limited set of ethtool options. Support441- for a more complete ethtool feature set can be enabled by upgrading442- ethtool to ethtool-1.8.1.443-444 Enabling Wake on LAN* (WoL)445 ---------------------------446- WoL is configured through the Ethtool* utility. Ethtool is included with447- all versions of Red Hat after Red Hat 7.2. For other Linux distributions,448- download and install Ethtool from the following website:449- http://sourceforge.net/projects/gkernel.450-451- For instructions on enabling WoL with Ethtool, refer to the website listed452- above.453454 WoL will be enabled on the system during the next shut down or reboot.455 For this driver version, in order to enable WoL, the e1000 driver must be456 loaded when shutting down or rebooting the system.457-458- Wake On LAN is only supported on port A for the following devices:459- Intel(R) PRO/1000 PT Dual Port Network Connection460- Intel(R) PRO/1000 PT Dual Port Server Connection461- Intel(R) PRO/1000 PT Dual Port Server Adapter462- Intel(R) PRO/1000 PF Dual Port Server Adapter463- Intel(R) PRO/1000 PT Quad Port Server Adapter464-465- NAPI466- ----467- NAPI (Rx polling mode) is enabled in the e1000 driver.468-469- See www.cyberus.ca/~hadi/usenix-paper.tgz for more information on NAPI.470-471-472-Known Issues473-============474-475-Dropped Receive Packets on Half-duplex 10/100 Networks476-------------------------------------------------------477-If you have an Intel PCI Express adapter running at 10mbps or 100mbps, half-478-duplex, you may observe occasional dropped receive packets. There are no479-workarounds for this problem in this network configuration. The network must480-be updated to operate in full-duplex, and/or 1000mbps only.481-482-Jumbo Frames System Requirement483--------------------------------484-Memory allocation failures have been observed on Linux systems with 64 MB485-of RAM or less that are running Jumbo Frames. If you are using Jumbo486-Frames, your system may require more than the advertised minimum487-requirement of 64 MB of system memory.488-489-Performance Degradation with Jumbo Frames490------------------------------------------491-Degradation in throughput performance may be observed in some Jumbo frames492-environments. If this is observed, increasing the application's socket493-buffer size and/or increasing the /proc/sys/net/ipv4/tcp_*mem entry values494-may help. See the specific application manual and495-/usr/src/linux*/Documentation/496-networking/ip-sysctl.txt for more details.497-498-Jumbo Frames on Foundry BigIron 8000 switch499--------------------------------------------500-There is a known issue using Jumbo frames when connected to a Foundry501-BigIron 8000 switch. This is a 3rd party limitation. If you experience502-loss of packets, lower the MTU size.503-504-Allocating Rx Buffers when Using Jumbo Frames 505----------------------------------------------506-Allocating Rx buffers when using Jumbo Frames on 2.6.x kernels may fail if 507-the available memory is heavily fragmented. This issue may be seen with PCI-X 508-adapters or with packet split disabled. This can be reduced or eliminated 509-by changing the amount of available memory for receive buffer allocation, by510-increasing /proc/sys/vm/min_free_kbytes. 511-512-Multiple Interfaces on Same Ethernet Broadcast Network513-------------------------------------------------------514-Due to the default ARP behavior on Linux, it is not possible to have515-one system on two IP networks in the same Ethernet broadcast domain516-(non-partitioned switch) behave as expected. All Ethernet interfaces517-will respond to IP traffic for any IP address assigned to the system.518-This results in unbalanced receive traffic.519-520-If you have multiple interfaces in a server, either turn on ARP521-filtering by entering:522-523- echo 1 > /proc/sys/net/ipv4/conf/all/arp_filter524-(this only works if your kernel's version is higher than 2.4.5),525-526-NOTE: This setting is not saved across reboots. The configuration527-change can be made permanent by adding the line:528- net.ipv4.conf.all.arp_filter = 1529-to the file /etc/sysctl.conf530-531- or,532-533-install the interfaces in separate broadcast domains (either in534-different switches or in a switch partitioned to VLANs).535-536-82541/82547 can't link or are slow to link with some link partners537------------------------------------------------------------------538-There is a known compatibility issue with 82541/82547 and some539-low-end switches where the link will not be established, or will540-be slow to establish. In particular, these switches are known to541-be incompatible with 82541/82547:542-543- Planex FXG-08TE544- I-O Data ETG-SH8545-546-To workaround this issue, the driver can be compiled with an override547-of the PHY's master/slave setting. Forcing master or forcing slave548-mode will improve time-to-link.549-550- # make CFLAGS_EXTRA=-DE1000_MASTER_SLAVE=<n>551-552-Where <n> is:553-554- 0 = Hardware default555- 1 = Master mode556- 2 = Slave mode557- 3 = Auto master/slave558-559-Disable rx flow control with ethtool560-------------------------------------561-In order to disable receive flow control using ethtool, you must turn562-off auto-negotiation on the same command line.563-564-For example:565-566- ethtool -A eth? autoneg off rx off567-568-Unplugging network cable while ethtool -p is running569-----------------------------------------------------570-In kernel versions 2.5.50 and later (including 2.6 kernel), unplugging571-the network cable while ethtool -p is running will cause the system to572-become unresponsive to keyboard commands, except for control-alt-delete.573-Restarting the system appears to be the only remedy.574-575576Support577=======
···1Linux* Base Driver for the Intel(R) PRO/1000 Family of Adapters2===============================================================34+Intel Gigabit Linux driver.5+Copyright(c) 1999 - 2010 Intel Corporation.67Contents8========9010- Identifying Your Adapter011- Command Line Parameters12- Speed and Duplex Configuration13- Additional Configurations014- Support0000000000000000000000000000001516Identifying Your Adapter17========================···52For more information on how to identify your adapter, go to the Adapter &53Driver ID Guide at:5455+ http://support.intel.com/support/go/network/adapter/idguide.htm5657For the latest Intel network drivers for Linux, refer to the following58website. In the search field, enter your adapter name or type, or use the59networking link on the left to search for your adapter:6061+ http://support.intel.com/support/go/network/adapter/home.htm06263Command Line Parameters64=======================00000000000006566The default value for each parameter is generally the recommended setting,67unless otherwise noted.···88 RxIntDelay, TxIntDelay, RxAbsIntDelay, and TxAbsIntDelay89 parameters, see the application note at:90 http://www.intel.com/design/network/applnots/ap450.htm00009192AutoNeg93-------···106NOTE: Refer to the Speed and Duplex section of this readme for more107 information on the AutoNeg parameter.1080109Duplex110------111(Supported only on adapters with copper connections)···119link partner is forced (either full or half), Duplex defaults to half-120duplex.1210122FlowControl123-----------124Valid Range: 0-3 (0=none, 1=Rx only, 2=Tx only, 3=Rx&Tx)···128This parameter controls the automatic generation(Tx) and response(Rx)129to Ethernet PAUSE frames.1300131InterruptThrottleRate132---------------------133(not supported on Intel(R) 82542, 82543 or 82544-based adapters)134+Valid Range: 0,1,3,4,100-100000 (0=off, 1=dynamic, 3=dynamic conservative,135+ 4=simplified balancing)136Default Value: 3137138The driver can limit the amount of interrupts per second that the adapter139+will generate for incoming packets. It does this by writing a value to the140+adapter that is based on the maximum amount of interrupts that the adapter141will generate per second.142143Setting InterruptThrottleRate to a value greater or equal to 100···146load on the system and can lower CPU utilization under heavy load,147but will increase latency as packets are not processed as quickly.148149+The default behaviour of the driver previously assumed a static150+InterruptThrottleRate value of 8000, providing a good fallback value for151+all traffic types,but lacking in small packet performance and latency.152+The hardware can handle many more small packets per second however, and153for this reason an adaptive interrupt moderation algorithm was implemented.154155Since 7.3.x, the driver has two adaptive modes (setting 1 or 3) in which156+it dynamically adjusts the InterruptThrottleRate value based on the traffic157that it receives. After determining the type of incoming traffic in the last158+timeframe, it will adjust the InterruptThrottleRate to an appropriate value159for that traffic.160161The algorithm classifies the incoming traffic every interval into162+classes. Once the class is determined, the InterruptThrottleRate value is163+adjusted to suit that traffic type the best. There are three classes defined:164"Bulk traffic", for large amounts of packets of normal size; "Low latency",165for small amounts of traffic and/or a significant percentage of small166+packets; and "Lowest latency", for almost completely small packets or167minimal traffic.168169+In dynamic conservative mode, the InterruptThrottleRate value is set to 4000170+for traffic that falls in class "Bulk traffic". If traffic falls in the "Low171+latency" or "Lowest latency" class, the InterruptThrottleRate is increased172stepwise to 20000. This default mode is suitable for most applications.173174For situations where low latency is vital such as cluster or175grid computing, the algorithm can reduce latency even more when176InterruptThrottleRate is set to mode 1. In this mode, which operates177+the same as mode 3, the InterruptThrottleRate will be increased stepwise to17870000 for traffic in class "Lowest latency".179+180+In simplified mode the interrupt rate is based on the ratio of Tx and181+Rx traffic. If the bytes per second rate is approximately equal, the182+interrupt rate will drop as low as 2000 interrupts per second. If the183+traffic is mostly transmit or mostly receive, the interrupt rate could184+be as high as 8000.185186Setting InterruptThrottleRate to 0 turns off any interrupt moderation187and may improve small packet latency, but is generally not suitable···212 be platform-specific. If CPU utilization is not a concern, use213 RX_POLLING (NAPI) and default driver settings.21400215RxDescriptors216-------------217Valid Range: 80-256 for 82542 and 82543-based adapters···225incoming packets, at the expense of increased system memory utilization.226227Each descriptor is 16 bytes. A receive buffer is also allocated for each228+descriptor and can be either 2048, 4096, 8192, or 16384 bytes, depending229on the MTU setting. The maximum MTU size is 16110.230231+NOTE: MTU designates the frame size. It only needs to be set for Jumbo232+ Frames. Depending on the available system resources, the request233+ for a higher number of receive descriptors may be denied. In this234 case, use a lower number.0235236RxIntDelay237----------···254 restoring the network connection. To eliminate the potential255 for the hang ensure that RxIntDelay is set to 0.2560257RxAbsIntDelay258-------------259(This parameter is supported only on 82540, 82545 and later adapters.)···268along with RxIntDelay, may improve traffic throughput in specific network269conditions.2700271Speed272-----273(This parameter is supported only on adapters with copper connections.)···279(Mbps). If this parameter is not specified or is set to 0 and the link280partner is set to auto-negotiate, the board will auto-detect the correct281speed. Duplex should also be set when Speed is set to either 10 or 100.0282283TxDescriptors284-------------···295 higher number of transmit descriptors may be denied. In this case,296 use a lower number.297298+TxDescriptorStep299+----------------300+Valid Range: 1 (use every Tx Descriptor)301+ 4 (use every 4th Tx Descriptor)302+303+Default Value: 1 (use every Tx Descriptor)304+305+On certain non-Intel architectures, it has been observed that intense TX306+traffic bursts of short packets may result in an improper descriptor307+writeback. If this occurs, the driver will report a "TX Timeout" and reset308+the adapter, after which the transmit flow will restart, though data may309+have stalled for as much as 10 seconds before it resumes.310+311+The improper writeback does not occur on the first descriptor in a system312+memory cache-line, which is typically 32 bytes, or 4 descriptors long.313+314+Setting TxDescriptorStep to a value of 4 will ensure that all TX descriptors315+are aligned to the start of a system memory cache line, and so this problem316+will not occur.317+318+NOTES: Setting TxDescriptorStep to 4 effectively reduces the number of319+ TxDescriptors available for transmits to 1/4 of the normal allocation.320+ This has a possible negative performance impact, which may be321+ compensated for by allocating more descriptors using the TxDescriptors322+ module parameter.323+324+ There are other conditions which may result in "TX Timeout", which will325+ not be resolved by the use of the TxDescriptorStep parameter. As the326+ issue addressed by this parameter has never been observed on Intel327+ Architecture platforms, it should not be used on Intel platforms.328329TxIntDelay330----------···306efficiency if properly tuned for specific network traffic. If the307system is reporting dropped transmits, this value may be set too high308causing the driver to run out of available transmit descriptors.0309310TxAbsIntDelay311-------------···330A value of '1' indicates that the driver should enable IP checksum331offload for received packets (both UDP and TCP) to the adapter hardware.332333+Copybreak334+---------335+Valid Range: 0-xxxxxxx (0=off)336+Default Value: 256337+Usage: insmod e1000.ko copybreak=128338+339+Driver copies all packets below or equaling this size to a fresh Rx340+buffer before handing it up the stack.341+342+This parameter is different than other parameters, in that it is a343+single (not 1,1,1 etc.) parameter applied to all driver instances and344+it is also available during runtime at345+/sys/module/e1000/parameters/copybreak346+347+SmartPowerDownEnable348+--------------------349+Valid Range: 0-1350+Default Value: 0 (disabled)351+352+Allows PHY to turn off in lower power states. The user can turn off353+this parameter in supported chipsets.354+355+KumeranLockLoss356+---------------357+Valid Range: 0-1358+Default Value: 1 (enabled)359+360+This workaround skips resetting the PHY at shutdown for the initial361+silicon releases of ICH8 systems.362363Speed and Duplex Configuration364==============================···385parameter should not be used. Instead, use the Speed and Duplex parameters386previously mentioned to force the adapter to the same speed and duplex.3870388Additional Configurations389=========================000000000000000000000000000000390391 Jumbo Frames392 ------------···437 setting in a different location.438439 Notes:440+ Degradation in throughput performance may be observed in some Jumbo frames441+ environments. If this is observed, increasing the application's socket buffer442+ size and/or increasing the /proc/sys/net/ipv4/tcp_*mem entry values may help.443+ See the specific application manual and /usr/src/linux*/Documentation/444+ networking/ip-sysctl.txt for more details.445446 - The maximum MTU setting for Jumbo Frames is 16110. This value coincides447 with the maximum Jumbo Frames size of 16128.···447 - Using Jumbo Frames at 10 or 100 Mbps may result in poor performance or448 loss of link.4490000000000000000000450 - Adapters based on the Intel(R) 82542 and 82573V/E controller do not451 support Jumbo Frames. These correspond to the following product names:452 Intel(R) PRO/1000 Gigabit Server Adapter453 Intel(R) PRO/1000 PM Network Connection0000000000454455 Ethtool456 -------···490 The latest release of ethtool can be found from491 http://sourceforge.net/projects/gkernel.4920000493 Enabling Wake on LAN* (WoL)494 ---------------------------495+ WoL is configured through the Ethtool* utility.000000496497 WoL will be enabled on the system during the next shut down or reboot.498 For this driver version, in order to enable WoL, the e1000 driver must be499 loaded when shutting down or rebooting the system.0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000500501Support502=======
···1+Linux* Driver for Intel(R) Network Connection2+===============================================================3+4+Intel Gigabit Linux driver.5+Copyright(c) 1999 - 2010 Intel Corporation.6+7+Contents8+========9+10+- Identifying Your Adapter11+- Command Line Parameters12+- Additional Configurations13+- Support14+15+Identifying Your Adapter16+========================17+18+The e1000e driver supports all PCI Express Intel(R) Gigabit Network19+Connections, except those that are 82575, 82576 and 82580-based*.20+21+* NOTE: The Intel(R) PRO/1000 P Dual Port Server Adapter is supported by22+ the e1000 driver, not the e1000e driver due to the 82546 part being used23+ behind a PCI Express bridge.24+25+For more information on how to identify your adapter, go to the Adapter &26+Driver ID Guide at:27+28+ http://support.intel.com/support/go/network/adapter/idguide.htm29+30+For the latest Intel network drivers for Linux, refer to the following31+website. In the search field, enter your adapter name or type, or use the32+networking link on the left to search for your adapter:33+34+ http://support.intel.com/support/go/network/adapter/home.htm35+36+Command Line Parameters37+=======================38+39+The default value for each parameter is generally the recommended setting,40+unless otherwise noted.41+42+NOTES: For more information about the InterruptThrottleRate,43+ RxIntDelay, TxIntDelay, RxAbsIntDelay, and TxAbsIntDelay44+ parameters, see the application note at:45+ http://www.intel.com/design/network/applnots/ap450.htm46+47+InterruptThrottleRate48+---------------------49+Valid Range: 0,1,3,4,100-100000 (0=off, 1=dynamic, 3=dynamic conservative,50+ 4=simplified balancing)51+Default Value: 352+53+The driver can limit the amount of interrupts per second that the adapter54+will generate for incoming packets. It does this by writing a value to the55+adapter that is based on the maximum amount of interrupts that the adapter56+will generate per second.57+58+Setting InterruptThrottleRate to a value greater or equal to 10059+will program the adapter to send out a maximum of that many interrupts60+per second, even if more packets have come in. This reduces interrupt61+load on the system and can lower CPU utilization under heavy load,62+but will increase latency as packets are not processed as quickly.63+64+The driver has two adaptive modes (setting 1 or 3) in which65+it dynamically adjusts the InterruptThrottleRate value based on the traffic66+that it receives. After determining the type of incoming traffic in the last67+timeframe, it will adjust the InterruptThrottleRate to an appropriate value68+for that traffic.69+70+The algorithm classifies the incoming traffic every interval into71+classes. Once the class is determined, the InterruptThrottleRate value is72+adjusted to suit that traffic type the best. There are three classes defined:73+"Bulk traffic", for large amounts of packets of normal size; "Low latency",74+for small amounts of traffic and/or a significant percentage of small75+packets; and "Lowest latency", for almost completely small packets or76+minimal traffic.77+78+In dynamic conservative mode, the InterruptThrottleRate value is set to 400079+for traffic that falls in class "Bulk traffic". If traffic falls in the "Low80+latency" or "Lowest latency" class, the InterruptThrottleRate is increased81+stepwise to 20000. This default mode is suitable for most applications.82+83+For situations where low latency is vital such as cluster or84+grid computing, the algorithm can reduce latency even more when85+InterruptThrottleRate is set to mode 1. In this mode, which operates86+the same as mode 3, the InterruptThrottleRate will be increased stepwise to87+70000 for traffic in class "Lowest latency".88+89+In simplified mode the interrupt rate is based on the ratio of Tx and90+Rx traffic. If the bytes per second rate is approximately equal the91+interrupt rate will drop as low as 2000 interrupts per second. If the92+traffic is mostly transmit or mostly receive, the interrupt rate could93+be as high as 8000.94+95+Setting InterruptThrottleRate to 0 turns off any interrupt moderation96+and may improve small packet latency, but is generally not suitable97+for bulk throughput traffic.98+99+NOTE: InterruptThrottleRate takes precedence over the TxAbsIntDelay and100+ RxAbsIntDelay parameters. In other words, minimizing the receive101+ and/or transmit absolute delays does not force the controller to102+ generate more interrupts than what the Interrupt Throttle Rate103+ allows.104+105+NOTE: When e1000e is loaded with default settings and multiple adapters106+ are in use simultaneously, the CPU utilization may increase non-107+ linearly. In order to limit the CPU utilization without impacting108+ the overall throughput, we recommend that you load the driver as109+ follows:110+111+ modprobe e1000e InterruptThrottleRate=3000,3000,3000112+113+ This sets the InterruptThrottleRate to 3000 interrupts/sec for114+ the first, second, and third instances of the driver. The range115+ of 2000 to 3000 interrupts per second works on a majority of116+ systems and is a good starting point, but the optimal value will117+ be platform-specific. If CPU utilization is not a concern, use118+ RX_POLLING (NAPI) and default driver settings.119+120+RxIntDelay121+----------122+Valid Range: 0-65535 (0=off)123+Default Value: 0124+125+This value delays the generation of receive interrupts in units of 1.024126+microseconds. Receive interrupt reduction can improve CPU efficiency if127+properly tuned for specific network traffic. Increasing this value adds128+extra latency to frame reception and can end up decreasing the throughput129+of TCP traffic. If the system is reporting dropped receives, this value130+may be set too high, causing the driver to run out of available receive131+descriptors.132+133+CAUTION: When setting RxIntDelay to a value other than 0, adapters may134+ hang (stop transmitting) under certain network conditions. If135+ this occurs a NETDEV WATCHDOG message is logged in the system136+ event log. In addition, the controller is automatically reset,137+ restoring the network connection. To eliminate the potential138+ for the hang ensure that RxIntDelay is set to 0.139+140+RxAbsIntDelay141+-------------142+Valid Range: 0-65535 (0=off)143+Default Value: 8144+145+This value, in units of 1.024 microseconds, limits the delay in which a146+receive interrupt is generated. Useful only if RxIntDelay is non-zero,147+this value ensures that an interrupt is generated after the initial148+packet is received within the set amount of time. Proper tuning,149+along with RxIntDelay, may improve traffic throughput in specific network150+conditions.151+152+TxIntDelay153+----------154+Valid Range: 0-65535 (0=off)155+Default Value: 8156+157+This value delays the generation of transmit interrupts in units of158+1.024 microseconds. Transmit interrupt reduction can improve CPU159+efficiency if properly tuned for specific network traffic. If the160+system is reporting dropped transmits, this value may be set too high161+causing the driver to run out of available transmit descriptors.162+163+TxAbsIntDelay164+-------------165+Valid Range: 0-65535 (0=off)166+Default Value: 32167+168+This value, in units of 1.024 microseconds, limits the delay in which a169+transmit interrupt is generated. Useful only if TxIntDelay is non-zero,170+this value ensures that an interrupt is generated after the initial171+packet is sent on the wire within the set amount of time. Proper tuning,172+along with TxIntDelay, may improve traffic throughput in specific173+network conditions.174+175+Copybreak176+---------177+Valid Range: 0-xxxxxxx (0=off)178+Default Value: 256179+180+Driver copies all packets below or equaling this size to a fresh Rx181+buffer before handing it up the stack.182+183+This parameter is different than other parameters, in that it is a184+single (not 1,1,1 etc.) parameter applied to all driver instances and185+it is also available during runtime at186+/sys/module/e1000e/parameters/copybreak187+188+SmartPowerDownEnable189+--------------------190+Valid Range: 0-1191+Default Value: 0 (disabled)192+193+Allows PHY to turn off in lower power states. The user can set this parameter194+in supported chipsets.195+196+KumeranLockLoss197+---------------198+Valid Range: 0-1199+Default Value: 1 (enabled)200+201+This workaround skips resetting the PHY at shutdown for the initial202+silicon releases of ICH8 systems.203+204+IntMode205+-------206+Valid Range: 0-2 (0=legacy, 1=MSI, 2=MSI-X)207+Default Value: 2208+209+Allows changing the interrupt mode at module load time, without requiring a210+recompile. If the driver load fails to enable a specific interrupt mode, the211+driver will try other interrupt modes, from least to most compatible. The212+interrupt order is MSI-X, MSI, Legacy. If specifying MSI (IntMode=1)213+interrupts, only MSI and Legacy will be attempted.214+215+CrcStripping216+------------217+Valid Range: 0-1218+Default Value: 1 (enabled)219+220+Strip the CRC from received packets before sending up the network stack. If221+you have a machine with a BMC enabled but cannot receive IPMI traffic after222+loading or enabling the driver, try disabling this feature.223+224+WriteProtectNVM225+---------------226+Valid Range: 0-1227+Default Value: 1 (enabled)228+229+Set the hardware to ignore all write/erase cycles to the GbE region in the230+ICHx NVM (non-volatile memory). This feature can be disabled by the231+WriteProtectNVM module parameter (enabled by default) only after a hardware232+reset, but the machine must be power cycled before trying to enable writes.233+234+Note: the kernel boot option iomem=relaxed may need to be set if the kernel235+config option CONFIG_STRICT_DEVMEM=y, if the root user wants to write the236+NVM from user space via ethtool.237+238+Additional Configurations239+=========================240+241+ Jumbo Frames242+ ------------243+ Jumbo Frames support is enabled by changing the MTU to a value larger than244+ the default of 1500. Use the ifconfig command to increase the MTU size.245+ For example:246+247+ ifconfig eth<x> mtu 9000 up248+249+ This setting is not saved across reboots.250+251+ Notes:252+253+ - The maximum MTU setting for Jumbo Frames is 9216. This value coincides254+ with the maximum Jumbo Frames size of 9234 bytes.255+256+ - Using Jumbo Frames at 10 or 100 Mbps is not supported and may result in257+ poor performance or loss of link.258+259+ - Some adapters limit Jumbo Frames sized packets to a maximum of260+ 4096 bytes and some adapters do not support Jumbo Frames.261+262+263+ Ethtool264+ -------265+ The driver utilizes the ethtool interface for driver configuration and266+ diagnostics, as well as displaying statistical information. We267+ strongly recommend downloading the latest version of Ethtool at:268+269+ http://sourceforge.net/projects/gkernel.270+271+ Speed and Duplex272+ ----------------273+ Speed and Duplex are configured through the Ethtool* utility. For274+ instructions, refer to the Ethtool man page.275+276+ Enabling Wake on LAN* (WoL)277+ ---------------------------278+ WoL is configured through the Ethtool* utility. For instructions on279+ enabling WoL with Ethtool, refer to the Ethtool man page.280+281+ WoL will be enabled on the system during the next shut down or reboot.282+ For this driver version, in order to enable WoL, the e1000e driver must be283+ loaded when shutting down or rebooting the system.284+285+ In most cases Wake On LAN is only supported on port A for multiple port286+ adapters. To verify if a port supports Wake on LAN run ethtool eth<X>.287+288+289+Support290+=======291+292+For general information, go to the Intel support website at:293+294+ www.intel.com/support/295+296+or the Intel Wired Networking project hosted by Sourceforge at:297+298+ http://sourceforge.net/projects/e1000299+300+If an issue is identified with the released source code on the supported301+kernel with a supported adapter, email the specific information related302+to the issue to e1000-devel@lists.sf.net
+3-37
Documentation/networking/ixgbevf.txt
···1Linux* Base Driver for Intel(R) Network Connection2==================================================34-November 24, 2009056Contents7========89-- In This Release10- Identifying Your Adapter11- Known Issues/Troubleshooting12- Support13-14-In This Release15-===============1617This file describes the ixgbevf Linux* Base Driver for Intel Network18Connection.···30For more information on how to identify your adapter, go to the Adapter &31Driver ID Guide at:3233- http://support.intel.com/support/network/sb/CS-008441.htm3435Known Issues/Troubleshooting36============================···54If an issue is identified with the released source code on the supported55kernel with a supported adapter, email the specific information related56to the issue to e1000-devel@lists.sf.net57-58-License59-=======60-61-Intel 10 Gigabit Linux driver.62-Copyright(c) 1999 - 2009 Intel Corporation.63-64-This program is free software; you can redistribute it and/or modify it65-under the terms and conditions of the GNU General Public License,66-version 2, as published by the Free Software Foundation.67-68-This program is distributed in the hope it will be useful, but WITHOUT69-ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or70-FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for71-more details.72-73-You should have received a copy of the GNU General Public License along with74-this program; if not, write to the Free Software Foundation, Inc.,75-51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA.76-77-The full GNU General Public License is included in this distribution in78-the file called "COPYING".79-80-Trademarks81-==========82-83-Intel, Itanium, and Pentium are trademarks or registered trademarks of84-Intel Corporation or its subsidiaries in the United States and other85-countries.86-87-* Other names and brands may be claimed as the property of others.
···1Linux* Base Driver for Intel(R) Network Connection2==================================================34+Intel Gigabit Linux driver.5+Copyright(c) 1999 - 2010 Intel Corporation.67Contents8========9010- Identifying Your Adapter11- Known Issues/Troubleshooting12- Support0001314This file describes the ixgbevf Linux* Base Driver for Intel Network15Connection.···33For more information on how to identify your adapter, go to the Adapter &34Driver ID Guide at:3536+ http://support.intel.com/support/go/network/adapter/idguide.htm3738Known Issues/Troubleshooting39============================···57If an issue is identified with the released source code on the supported58kernel with a supported adapter, email the specific information related59to the issue to e1000-devel@lists.sf.net0000000000000000000000000000000
···969S: Maintained970F: arch/arm/mach-s5p*/9710000000000972ARM/SHMOBILE ARM ARCHITECTURE973M: Paul Mundt <lethal@linux-sh.org>974M: Magnus Damm <magnus.damm@gmail.com>···2545F: drivers/scsi/gdt*25462547GENERIC GPIO I2C DRIVER2548-M: Haavard Skinnemoen <hskinnemoen@atmel.com>2549S: Supported2550F: drivers/i2c/busses/i2c-gpio.c2551F: include/linux/i2c-gpio.h···3073S: Maintained3074F: drivers/net/ixp2000/30753076-INTEL ETHERNET DRIVERS (e100/e1000/e1000e/igb/igbvf/ixgb/ixgbe)3077M: Jeff Kirsher <jeffrey.t.kirsher@intel.com>3078M: Jesse Brandeburg <jesse.brandeburg@intel.com>3079M: Bruce Allan <bruce.w.allan@intel.com>3080-M: Alex Duyck <alexander.h.duyck@intel.com>003081M: PJ Waskiewicz <peter.p.waskiewicz.jr@intel.com>03082M: John Ronciak <john.ronciak@intel.com>3083L: e1000-devel@lists.sourceforge.net3084W: http://e1000.sourceforge.net/3085S: Supported000000003086F: drivers/net/e100.c3087F: drivers/net/e1000/3088F: drivers/net/e1000e/···3101F: drivers/net/igbvf/3102F: drivers/net/ixgb/3103F: drivers/net/ixgbe/031043105INTEL PRO/WIRELESS 2100 NETWORK CONNECTION SUPPORT3106L: linux-wireless@vger.kernel.org···5030F: drivers/media/video/*7146*5031F: include/media/*7146*50320000005033TLG2300 VIDEO4LINUX-2 DRIVER5034M: Huang Shijie <shijie8@gmail.com>5035M: Kang Yong <kangyong@telegent.com>···6478WOLFSON MICROELECTRONICS DRIVERS6479M: Mark Brown <broonie@opensource.wolfsonmicro.com>6480M: Ian Lartey <ian@opensource.wolfsonmicro.com>006481T: git git://opensource.wolfsonmicro.com/linux-2.6-audioplus6482-W: http://opensource.wolfsonmicro.com/node/86483S: Supported6484F: Documentation/hwmon/wm83??6485F: drivers/leds/leds-wm83*.c
···969S: Maintained970F: arch/arm/mach-s5p*/971972+ARM/SAMSUNG S5P SERIES FIMC SUPPORT973+M: Kyungmin Park <kyungmin.park@samsung.com>974+M: Sylwester Nawrocki <s.nawrocki@samsung.com>975+L: linux-arm-kernel@lists.infradead.org976+L: linux-media@vger.kernel.org977+S: Maintained978+F: arch/arm/plat-s5p/dev-fimc*979+F: arch/arm/plat-samsung/include/plat/*fimc*980+F: drivers/media/video/s5p-fimc/981+982ARM/SHMOBILE ARM ARCHITECTURE983M: Paul Mundt <lethal@linux-sh.org>984M: Magnus Damm <magnus.damm@gmail.com>···2535F: drivers/scsi/gdt*25362537GENERIC GPIO I2C DRIVER2538+M: Haavard Skinnemoen <hskinnemoen@gmail.com>2539S: Supported2540F: drivers/i2c/busses/i2c-gpio.c2541F: include/linux/i2c-gpio.h···3063S: Maintained3064F: drivers/net/ixp2000/30653066+INTEL ETHERNET DRIVERS (e100/e1000/e1000e/igb/igbvf/ixgb/ixgbe/ixgbevf)3067M: Jeff Kirsher <jeffrey.t.kirsher@intel.com>3068M: Jesse Brandeburg <jesse.brandeburg@intel.com>3069M: Bruce Allan <bruce.w.allan@intel.com>3070+M: Carolyn Wyborny <carolyn.wyborny@intel.com>3071+M: Don Skidmore <donald.c.skidmore@intel.com>3072+M: Greg Rose <gregory.v.rose@intel.com>3073M: PJ Waskiewicz <peter.p.waskiewicz.jr@intel.com>3074+M: Alex Duyck <alexander.h.duyck@intel.com>3075M: John Ronciak <john.ronciak@intel.com>3076L: e1000-devel@lists.sourceforge.net3077W: http://e1000.sourceforge.net/3078S: Supported3079+F: Documentation/networking/e100.txt3080+F: Documentation/networking/e1000.txt3081+F: Documentation/networking/e1000e.txt3082+F: Documentation/networking/igb.txt3083+F: Documentation/networking/igbvf.txt3084+F: Documentation/networking/ixgb.txt3085+F: Documentation/networking/ixgbe.txt3086+F: Documentation/networking/ixgbevf.txt3087F: drivers/net/e100.c3088F: drivers/net/e1000/3089F: drivers/net/e1000e/···3080F: drivers/net/igbvf/3081F: drivers/net/ixgb/3082F: drivers/net/ixgbe/3083+F: drivers/net/ixgbevf/30843085INTEL PRO/WIRELESS 2100 NETWORK CONNECTION SUPPORT3086L: linux-wireless@vger.kernel.org···5008F: drivers/media/video/*7146*5009F: include/media/*7146*50105011+SAMSUNG AUDIO (ASoC) DRIVERS5012+M: Jassi Brar <jassi.brar@samsung.com>5013+L: alsa-devel@alsa-project.org (moderated for non-subscribers)5014+S: Supported5015+F: sound/soc/s3c24xx5016+5017TLG2300 VIDEO4LINUX-2 DRIVER5018M: Huang Shijie <shijie8@gmail.com>5019M: Kang Yong <kangyong@telegent.com>···6450WOLFSON MICROELECTRONICS DRIVERS6451M: Mark Brown <broonie@opensource.wolfsonmicro.com>6452M: Ian Lartey <ian@opensource.wolfsonmicro.com>6453+M: Dimitris Papastamos <dp@opensource.wolfsonmicro.com>6454+T: git git://opensource.wolfsonmicro.com/linux-2.6-asoc6455T: git git://opensource.wolfsonmicro.com/linux-2.6-audioplus6456+W: http://opensource.wolfsonmicro.com/content/linux-drivers-wolfson-devices6457S: Supported6458F: Documentation/hwmon/wm83??6459F: drivers/leds/leds-wm83*.c
+2-2
Makefile
···1VERSION = 22PATCHLEVEL = 63SUBLEVEL = 364-EXTRAVERSION = -rc75-NAME = Sheep on Meth67# *DOCUMENTATION*8# To see a list of typical targets execute "make help"
···1VERSION = 22PATCHLEVEL = 63SUBLEVEL = 364+EXTRAVERSION = -rc85+NAME = Flesh-Eating Bats with Fangs67# *DOCUMENTATION*8# To see a list of typical targets execute "make help"
+14
arch/arm/Kconfig
···1101 invalidated are not, resulting in an incoherency in the system page1102 tables. The workaround changes the TLB flushing routines to invalidate1103 entries regardless of the ASID.000000000000001104endmenu11051106source "arch/arm/common/Kconfig"
···1101 invalidated are not, resulting in an incoherency in the system page1102 tables. The workaround changes the TLB flushing routines to invalidate1103 entries regardless of the ASID.1104+1105+config ARM_ERRATA_7436221106+ bool "ARM errata: Faulty hazard checking in the Store Buffer may lead to data corruption"1107+ depends on CPU_V71108+ help1109+ This option enables the workaround for the 743622 Cortex-A91110+ (r2p0..r2p2) erratum. Under very rare conditions, a faulty1111+ optimisation in the Cortex-A9 Store Buffer may lead to data1112+ corruption. This workaround sets a specific bit in the diagnostic1113+ register of the Cortex-A9 which disables the Store Buffer1114+ optimisation, preventing the defect from occurring. This has no1115+ visible impact on the overall performance or power consumption of the1116+ processor.1117+1118endmenu11191120source "arch/arm/common/Kconfig"
···2829static inline void arch_idle(void)30{31-#ifndef CONFIG_DEBUG_KERNEL32 /*33 * Disable the processor clock. The processor will be automatically34 * re-enabled by an interrupt or by a reset.35 */36 at91_sys_write(AT91_PMC_SCDR, AT91_PMC_PCK);37-#else38 /*39 * Set the processor (CP15) into 'Wait for Interrupt' mode.40- * Unlike disabling the processor clock via the PMC (above)41- * this allows the processor to be woken via JTAG.42 */43 cpu_do_idle();44#endif
···2829static inline void arch_idle(void)30{031 /*32 * Disable the processor clock. The processor will be automatically33 * re-enabled by an interrupt or by a reset.34 */35 at91_sys_write(AT91_PMC_SCDR, AT91_PMC_PCK);36+#ifndef CONFIG_CPU_ARM920T37 /*38 * Set the processor (CP15) into 'Wait for Interrupt' mode.39+ * Post-RM9200 processors need this in conjunction with the above40+ * to save power when idle.41 */42 cpu_do_idle();43#endif
+1-1
arch/arm/mach-ep93xx/dma-m2p.c
···276 v &= ~(M2P_CONTROL_STALL_IRQ_EN | M2P_CONTROL_NFB_IRQ_EN);277 m2p_set_control(ch, v);278279- while (m2p_channel_state(ch) == STATE_ON)280 cpu_relax();281282 m2p_set_control(ch, 0x0);
···276 v &= ~(M2P_CONTROL_STALL_IRQ_EN | M2P_CONTROL_NFB_IRQ_EN);277 m2p_set_control(ch, v);278279+ while (m2p_channel_state(ch) >= STATE_ON)280 cpu_relax();281282 m2p_set_control(ch, 0x0);
+1
arch/arm/mach-imx/Kconfig
···122 select IMX_HAVE_PLATFORM_IMX_I2C123 select IMX_HAVE_PLATFORM_IMX_UART124 select IMX_HAVE_PLATFORM_MXC_NAND0125 help126 Include support for Eukrea CPUIMX27 platform. This includes127 specific configurations for the module and its peripherals.
···122 select IMX_HAVE_PLATFORM_IMX_I2C123 select IMX_HAVE_PLATFORM_IMX_UART124 select IMX_HAVE_PLATFORM_MXC_NAND125+ select MXC_ULPI if USB_ULPI126 help127 Include support for Eukrea CPUIMX27 platform. This includes128 specific configurations for the module and its peripherals.
···204 /*205 * Don't allow RAM to be mapped - this causes problems with ARMv6+206 */207- if (WARN_ON(pfn_valid(pfn)))208- return NULL;0000209210 type = get_mem_type(mtype);211 if (!type)
···204 /*205 * Don't allow RAM to be mapped - this causes problems with ARMv6+206 */207+ if (pfn_valid(pfn)) {208+ printk(KERN_WARNING "BUG: Your driver calls ioremap() on system memory. This leads\n"209+ KERN_WARNING "to architecturally unpredictable behaviour on ARMv6+, and ioremap()\n"210+ KERN_WARNING "will fail in the next kernel release. Please fix your driver.\n");211+ WARN_ON(1);212+ }213214 type = get_mem_type(mtype);215 if (!type)
···48#include <plat/clock.h>49#include <plat/cpu.h>5051+#include <linux/serial_core.h>52+#include <plat/regs-serial.h> /* for s3c24xx_uart_devs */53+54/* clock information */5556static LIST_HEAD(clocks);···65 return 0;66}6768+static int dev_is_s3c_uart(struct device *dev)69+{70+ struct platform_device **pdev = s3c24xx_uart_devs;71+ int i;72+ for (i = 0; i < ARRAY_SIZE(s3c24xx_uart_devs); i++, pdev++)73+ if (*pdev && dev == &(*pdev)->dev)74+ return 1;75+ return 0;76+}77+78+/*79+ * Serial drivers call get_clock() very early, before platform bus80+ * has been set up, this requires a special check to let them get81+ * a proper clock82+ */83+84+static int dev_is_platform_device(struct device *dev)85+{86+ return dev->bus == &platform_bus_type ||87+ (dev->bus == NULL && dev_is_s3c_uart(dev));88+}89+90/* Clock API calls */9192struct clk *clk_get(struct device *dev, const char *id)···73 struct clk *clk = ERR_PTR(-ENOENT);74 int idno;7576+ if (dev == NULL || !dev_is_platform_device(dev))77 idno = -1;78 else79 idno = to_platform_device(dev)->id;
···1112#define MIN_SPI_BAUD_VAL 21300000000000014#define BIT_CTL_ENABLE 0x400015#define BIT_CTL_OPENDRAIN 0x200016#define BIT_CTL_MASTER 0x100017+#define BIT_CTL_CPOL 0x080018+#define BIT_CTL_CPHA 0x040019+#define BIT_CTL_LSBF 0x020020#define BIT_CTL_WORDSIZE 0x010021+#define BIT_CTL_EMISO 0x002022+#define BIT_CTL_PSSE 0x001023+#define BIT_CTL_GM 0x000824+#define BIT_CTL_SZ 0x000425#define BIT_CTL_RXMOD 0x000026#define BIT_CTL_TXMOD 0x000127#define BIT_CTL_TIMOD_DMA_TX 0x0003···50#define BIT_STU_SENDOVER 0x000151#define BIT_STU_RECVFULL 0x00205253+#define MAX_CTRL_CS 8 /* cs in spi controller */0000000000000000000000000000000000000000000000000000005455/* device.platform_data for SSP controller devices */56struct bfin5xx_spi_master {···120 u16 ctl_reg;121 u8 enable_dma;122 u8 bits_per_word;0123 u16 cs_chg_udelay; /* Some devices require 16-bit delays */0124 /* Value to send if no TX value is supplied, usually 0x0 or 0xFFFF */125 u16 idle_tx_val;126 u8 pio_interrupt; /* Enable spi data irq */
+2-2
arch/m32r/include/asm/elf.h
···82 * These are used to set parameters in the core dumps.83 */84#define ELF_CLASS ELFCLASS3285-#if defined(__LITTLE_ENDIAN)86#define ELF_DATA ELFDATA2LSB87-#elif defined(__BIG_ENDIAN)88#define ELF_DATA ELFDATA2MSB89#else90#error no endian defined
···82 * These are used to set parameters in the core dumps.83 */84#define ELF_CLASS ELFCLASS3285+#if defined(__LITTLE_ENDIAN__)86#define ELF_DATA ELFDATA2LSB87+#elif defined(__BIG_ENDIAN__)88#define ELF_DATA ELFDATA2MSB89#else90#error no endian defined
···2829#define DEBUG_SIG 0300031asmlinkage int32sys_sigaltstack(const stack_t __user *uss, stack_t __user *uoss,33 unsigned long r2, unsigned long r3, unsigned long r4,···256static int prev_insn(struct pt_regs *regs)257{258 u16 inst;259- if (get_user(&inst, (u16 __user *)(regs->bpc - 2)))260 return -EFAULT;261 if ((inst & 0xfff0) == 0x10f0) /* trap ? */262 regs->bpc -= 2;
···2829#define DEBUG_SIG 03031+#define _BLOCKABLE (~(sigmask(SIGKILL) | sigmask(SIGSTOP)))32+33asmlinkage int34sys_sigaltstack(const stack_t __user *uss, stack_t __user *uoss,35 unsigned long r2, unsigned long r3, unsigned long r4,···254static int prev_insn(struct pt_regs *regs)255{256 u16 inst;257+ if (get_user(inst, (u16 __user *)(regs->bpc - 2)))258 return -EFAULT;259 if ((inst & 0xfff0) == 0x10f0) /* trap ? */260 regs->bpc -= 2;
+1
arch/mips/include/asm/siginfo.h
···88#ifdef __ARCH_SI_TRAPNO89 int _trapno; /* TRAP # which caused the signal */90#endif091 } _sigfault;9293 /* SIGPOLL, SIGXFSZ (To do ...) */
···88#ifdef __ARCH_SI_TRAPNO89 int _trapno; /* TRAP # which caused the signal */90#endif91+ short _addr_lsb;92 } _sigfault;9394 /* SIGPOLL, SIGXFSZ (To do ...) */
+5-9
arch/um/drivers/hostaudio_kern.c
···40" This is used to specify the host mixer device to the hostaudio driver.\n"\41" The default is \"" HOSTAUDIO_DEV_MIXER "\".\n\n"420000043#ifndef MODULE44static int set_dsp(char *name, int *add)45{···61}6263__uml_setup("mixer=", set_mixer, "mixer=<mixer device>\n" MIXER_HELP);64-65-#else /*MODULE*/66-67-module_param(dsp, charp, 0644);68-MODULE_PARM_DESC(dsp, DSP_HELP);69-70-module_param(mixer, charp, 0644);71-MODULE_PARM_DESC(mixer, MIXER_HELP);72-73#endif7475/* /dev/dsp file operations */
···40" This is used to specify the host mixer device to the hostaudio driver.\n"\41" The default is \"" HOSTAUDIO_DEV_MIXER "\".\n\n"4243+module_param(dsp, charp, 0644);44+MODULE_PARM_DESC(dsp, DSP_HELP);45+module_param(mixer, charp, 0644);46+MODULE_PARM_DESC(mixer, MIXER_HELP);47+48#ifndef MODULE49static int set_dsp(char *name, int *add)50{···56}5758__uml_setup("mixer=", set_mixer, "mixer=<mixer device>\n" MIXER_HELP);00000000059#endif6061/* /dev/dsp file operations */
···420 return -1;421 }422423- for_each_node_mask(i, nodes_parsed)424- e820_register_active_regions(i, nodes[i].start >> PAGE_SHIFT,425- nodes[i].end >> PAGE_SHIFT);00426 /* for out of order entries in SRAT */427 sort_node_map();428 if (!nodes_cover_memory(nodes)) {
···420 return -1;421 }422423+ for (i = 0; i < num_node_memblks; i++)424+ e820_register_active_regions(memblk_nodeid[i],425+ node_memblk_range[i].start >> PAGE_SHIFT,426+ node_memblk_range[i].end >> PAGE_SHIFT);427+428 /* for out of order entries in SRAT */429 sort_node_map();430 if (!nodes_cover_memory(nodes)) {
+8-4
block/elevator.c
···938 }939 }940 kobject_uevent(&e->kobj, KOBJ_ADD);0941 }942 return error;943}···948{949 kobject_uevent(&e->kobj, KOBJ_REMOVE);950 kobject_del(&e->kobj);0951}952953void elv_unregister_queue(struct request_queue *q)···10441045 spin_unlock_irq(q->queue_lock);10461047- __elv_unregister_queue(old_elevator);010481049- err = elv_register_queue(q);1050- if (err)1051- goto fail_register;010521053 /*1054 * finally exit old elevator and turn off BYPASS.
···938 }939 }940 kobject_uevent(&e->kobj, KOBJ_ADD);941+ e->registered = 1;942 }943 return error;944}···947{948 kobject_uevent(&e->kobj, KOBJ_REMOVE);949 kobject_del(&e->kobj);950+ e->registered = 0;951}952953void elv_unregister_queue(struct request_queue *q)···10421043 spin_unlock_irq(q->queue_lock);10441045+ if (old_elevator->registered) {1046+ __elv_unregister_queue(old_elevator);10471048+ err = elv_register_queue(q);1049+ if (err)1050+ goto fail_register;1051+ }10521053 /*1054 * finally exit old elevator and turn off BYPASS.
···204 },205 },206 {207+ /*208+ * There have a NVIF method in MSI GX723 DSDT need call by Nvidia209+ * driver (e.g. nouveau) when user press brightness hotkey.210+ * Currently, nouveau driver didn't do the job and it causes there211+ * have a infinite while loop in DSDT when user press hotkey.212+ * We add MSI GX723's dmi information to this table for workaround213+ * this issue.214+ * Will remove MSI GX723 from the table after nouveau grows support.215+ */216+ .callback = dmi_disable_osi_vista,217+ .ident = "MSI GX723",218+ .matches = {219+ DMI_MATCH(DMI_SYS_VENDOR, "Micro-Star International"),220+ DMI_MATCH(DMI_PRODUCT_NAME, "GX723"),221+ },222+ },223+ {224 .callback = dmi_disable_osi_vista,225 .ident = "Sony VGN-NS10J_S",226 .matches = {
···1030 return r;1031 }1032 rdev->cp.ready = true;01033 return 0;1034}1035···1048void r100_cp_disable(struct radeon_device *rdev)1049{1050 /* Disable ring */01051 rdev->cp.ready = false;1052 WREG32(RADEON_CP_CSQ_MODE, 0);1053 WREG32(RADEON_CP_CSQ_CNTL, 0);···2297 /* FIXME we don't use the second aperture yet when we could use it */2298 if (rdev->mc.visible_vram_size > rdev->mc.aper_size)2299 rdev->mc.visible_vram_size = rdev->mc.aper_size;02300 config_aper_size = RREG32(RADEON_CONFIG_APER_SIZE);2301 if (rdev->flags & RADEON_IS_IGP) {2302 uint32_t tom;
···1030 return r;1031 }1032 rdev->cp.ready = true;1033+ rdev->mc.active_vram_size = rdev->mc.real_vram_size;1034 return 0;1035}1036···1047void r100_cp_disable(struct radeon_device *rdev)1048{1049 /* Disable ring */1050+ rdev->mc.active_vram_size = rdev->mc.visible_vram_size;1051 rdev->cp.ready = false;1052 WREG32(RADEON_CP_CSQ_MODE, 0);1053 WREG32(RADEON_CP_CSQ_CNTL, 0);···2295 /* FIXME we don't use the second aperture yet when we could use it */2296 if (rdev->mc.visible_vram_size > rdev->mc.aper_size)2297 rdev->mc.visible_vram_size = rdev->mc.aper_size;2298+ rdev->mc.active_vram_size = rdev->mc.visible_vram_size;2299 config_aper_size = RREG32(RADEON_CONFIG_APER_SIZE);2300 if (rdev->flags & RADEON_IS_IGP) {2301 uint32_t tom;
···532 memcpy(ptr + rdev->r600_blit.ps_offset, r6xx_ps, r6xx_ps_size * 4);533 radeon_bo_kunmap(rdev->r600_blit.shader_obj);534 radeon_bo_unreserve(rdev->r600_blit.shader_obj);0535 return 0;536}537···540{541 int r;5420543 if (rdev->r600_blit.shader_obj == NULL)544 return;545 /* If we can't reserve the bo, unref should be enough to destroy
···532 memcpy(ptr + rdev->r600_blit.ps_offset, r6xx_ps, r6xx_ps_size * 4);533 radeon_bo_kunmap(rdev->r600_blit.shader_obj);534 radeon_bo_unreserve(rdev->r600_blit.shader_obj);535+ rdev->mc.active_vram_size = rdev->mc.real_vram_size;536 return 0;537}538···539{540 int r;541542+ rdev->mc.active_vram_size = rdev->mc.visible_vram_size;543 if (rdev->r600_blit.shader_obj == NULL)544 return;545 /* If we can't reserve the bo, unref should be enough to destroy
+1
drivers/gpu/drm/radeon/radeon.h
···344 * about vram size near mc fb location */345 u64 mc_vram_size;346 u64 visible_vram_size;0347 u64 gtt_size;348 u64 gtt_start;349 u64 gtt_end;
···344 * about vram size near mc fb location */345 u64 mc_vram_size;346 u64 visible_vram_size;347+ u64 active_vram_size;348 u64 gtt_size;349 u64 gtt_start;350 u64 gtt_end;
+9-9
drivers/gpu/drm/radeon/radeon_atombios.c
···1558 switch (tv_info->ucTV_BootUpDefaultStandard) {1559 case ATOM_TV_NTSC:1560 tv_std = TV_STD_NTSC;1561- DRM_INFO("Default TV standard: NTSC\n");1562 break;1563 case ATOM_TV_NTSCJ:1564 tv_std = TV_STD_NTSC_J;1565- DRM_INFO("Default TV standard: NTSC-J\n");1566 break;1567 case ATOM_TV_PAL:1568 tv_std = TV_STD_PAL;1569- DRM_INFO("Default TV standard: PAL\n");1570 break;1571 case ATOM_TV_PALM:1572 tv_std = TV_STD_PAL_M;1573- DRM_INFO("Default TV standard: PAL-M\n");1574 break;1575 case ATOM_TV_PALN:1576 tv_std = TV_STD_PAL_N;1577- DRM_INFO("Default TV standard: PAL-N\n");1578 break;1579 case ATOM_TV_PALCN:1580 tv_std = TV_STD_PAL_CN;1581- DRM_INFO("Default TV standard: PAL-CN\n");1582 break;1583 case ATOM_TV_PAL60:1584 tv_std = TV_STD_PAL_60;1585- DRM_INFO("Default TV standard: PAL-60\n");1586 break;1587 case ATOM_TV_SECAM:1588 tv_std = TV_STD_SECAM;1589- DRM_INFO("Default TV standard: SECAM\n");1590 break;1591 default:1592 tv_std = TV_STD_NTSC;1593- DRM_INFO("Unknown TV standard; defaulting to NTSC\n");1594 break;1595 }1596 }
···1558 switch (tv_info->ucTV_BootUpDefaultStandard) {1559 case ATOM_TV_NTSC:1560 tv_std = TV_STD_NTSC;1561+ DRM_DEBUG_KMS("Default TV standard: NTSC\n");1562 break;1563 case ATOM_TV_NTSCJ:1564 tv_std = TV_STD_NTSC_J;1565+ DRM_DEBUG_KMS("Default TV standard: NTSC-J\n");1566 break;1567 case ATOM_TV_PAL:1568 tv_std = TV_STD_PAL;1569+ DRM_DEBUG_KMS("Default TV standard: PAL\n");1570 break;1571 case ATOM_TV_PALM:1572 tv_std = TV_STD_PAL_M;1573+ DRM_DEBUG_KMS("Default TV standard: PAL-M\n");1574 break;1575 case ATOM_TV_PALN:1576 tv_std = TV_STD_PAL_N;1577+ DRM_DEBUG_KMS("Default TV standard: PAL-N\n");1578 break;1579 case ATOM_TV_PALCN:1580 tv_std = TV_STD_PAL_CN;1581+ DRM_DEBUG_KMS("Default TV standard: PAL-CN\n");1582 break;1583 case ATOM_TV_PAL60:1584 tv_std = TV_STD_PAL_60;1585+ DRM_DEBUG_KMS("Default TV standard: PAL-60\n");1586 break;1587 case ATOM_TV_SECAM:1588 tv_std = TV_STD_SECAM;1589+ DRM_DEBUG_KMS("Default TV standard: SECAM\n");1590 break;1591 default:1592 tv_std = TV_STD_NTSC;1593+ DRM_DEBUG_KMS("Unknown TV standard; defaulting to NTSC\n");1594 break;1595 }1596 }
+13-13
drivers/gpu/drm/radeon/radeon_combios.c
···913 switch (RBIOS8(tv_info + 7) & 0xf) {914 case 1:915 tv_std = TV_STD_NTSC;916- DRM_INFO("Default TV standard: NTSC\n");917 break;918 case 2:919 tv_std = TV_STD_PAL;920- DRM_INFO("Default TV standard: PAL\n");921 break;922 case 3:923 tv_std = TV_STD_PAL_M;924- DRM_INFO("Default TV standard: PAL-M\n");925 break;926 case 4:927 tv_std = TV_STD_PAL_60;928- DRM_INFO("Default TV standard: PAL-60\n");929 break;930 case 5:931 tv_std = TV_STD_NTSC_J;932- DRM_INFO("Default TV standard: NTSC-J\n");933 break;934 case 6:935 tv_std = TV_STD_SCART_PAL;936- DRM_INFO("Default TV standard: SCART-PAL\n");937 break;938 default:939 tv_std = TV_STD_NTSC;940- DRM_INFO941 ("Unknown TV standard; defaulting to NTSC\n");942 break;943 }944945 switch ((RBIOS8(tv_info + 9) >> 2) & 0x3) {946 case 0:947- DRM_INFO("29.498928713 MHz TV ref clk\n");948 break;949 case 1:950- DRM_INFO("28.636360000 MHz TV ref clk\n");951 break;952 case 2:953- DRM_INFO("14.318180000 MHz TV ref clk\n");954 break;955 case 3:956- DRM_INFO("27.000000000 MHz TV ref clk\n");957 break;958 default:959 break;···13241325 if (tmds_info) {1326 ver = RBIOS8(tmds_info);1327- DRM_INFO("DFP table revision: %d\n", ver);1328 if (ver == 3) {1329 n = RBIOS8(tmds_info + 5) + 1;1330 if (n > 4)···1408 offset = combios_get_table_offset(dev, COMBIOS_EXT_TMDS_INFO_TABLE);1409 if (offset) {1410 ver = RBIOS8(offset);1411- DRM_INFO("External TMDS Table revision: %d\n", ver);1412 tmds->slave_addr = RBIOS8(offset + 4 + 2);1413 tmds->slave_addr >>= 1; /* 7 bit addressing */1414 gpio = RBIOS8(offset + 4 + 3);
···913 switch (RBIOS8(tv_info + 7) & 0xf) {914 case 1:915 tv_std = TV_STD_NTSC;916+ DRM_DEBUG_KMS("Default TV standard: NTSC\n");917 break;918 case 2:919 tv_std = TV_STD_PAL;920+ DRM_DEBUG_KMS("Default TV standard: PAL\n");921 break;922 case 3:923 tv_std = TV_STD_PAL_M;924+ DRM_DEBUG_KMS("Default TV standard: PAL-M\n");925 break;926 case 4:927 tv_std = TV_STD_PAL_60;928+ DRM_DEBUG_KMS("Default TV standard: PAL-60\n");929 break;930 case 5:931 tv_std = TV_STD_NTSC_J;932+ DRM_DEBUG_KMS("Default TV standard: NTSC-J\n");933 break;934 case 6:935 tv_std = TV_STD_SCART_PAL;936+ DRM_DEBUG_KMS("Default TV standard: SCART-PAL\n");937 break;938 default:939 tv_std = TV_STD_NTSC;940+ DRM_DEBUG_KMS941 ("Unknown TV standard; defaulting to NTSC\n");942 break;943 }944945 switch ((RBIOS8(tv_info + 9) >> 2) & 0x3) {946 case 0:947+ DRM_DEBUG_KMS("29.498928713 MHz TV ref clk\n");948 break;949 case 1:950+ DRM_DEBUG_KMS("28.636360000 MHz TV ref clk\n");951 break;952 case 2:953+ DRM_DEBUG_KMS("14.318180000 MHz TV ref clk\n");954 break;955 case 3:956+ DRM_DEBUG_KMS("27.000000000 MHz TV ref clk\n");957 break;958 default:959 break;···13241325 if (tmds_info) {1326 ver = RBIOS8(tmds_info);1327+ DRM_DEBUG_KMS("DFP table revision: %d\n", ver);1328 if (ver == 3) {1329 n = RBIOS8(tmds_info + 5) + 1;1330 if (n > 4)···1408 offset = combios_get_table_offset(dev, COMBIOS_EXT_TMDS_INFO_TABLE);1409 if (offset) {1410 ver = RBIOS8(offset);1411+ DRM_DEBUG_KMS("External TMDS Table revision: %d\n", ver);1412 tmds->slave_addr = RBIOS8(offset + 4 + 2);1413 tmds->slave_addr >>= 1; /* 7 bit addressing */1414 gpio = RBIOS8(offset + 4 + 3);
···442}443444/**0000000000000000000000000000000000000445 * If bo idle, remove from delayed- and lru lists, and unref.446 * If not idle, and already on delayed list, do nothing.447 * If not idle, and not on delayed list, put on delayed list,···493 int ret;494495 spin_lock(&bo->lock);0496 (void) ttm_bo_wait(bo, false, false, !remove_all);497498 if (!bo->sync_obj) {···502 spin_unlock(&bo->lock);503504 spin_lock(&glob->lru_lock);505- put_count = ttm_bo_del_from_lru(bo);506507- ret = ttm_bo_reserve_locked(bo, false, false, false, 0);508- BUG_ON(ret);509- if (bo->ttm)510- ttm_tt_unbind(bo->ttm);00000000000000000000000000511512 if (!list_empty(&bo->ddestroy)) {513 list_del_init(&bo->ddestroy);514 ++put_count;515 }516- if (bo->mem.mm_node) {517- drm_mm_put_block(bo->mem.mm_node);518- bo->mem.mm_node = NULL;519- }520- spin_unlock(&glob->lru_lock);521522- atomic_set(&bo->reserved, 0);523524 while (put_count--)525 kref_put(&bo->list_kref, ttm_bo_ref_bug);526527 return 0;528 }529-530 spin_lock(&glob->lru_lock);531 if (list_empty(&bo->ddestroy)) {532 void *sync_obj = bo->sync_obj;
···442}443444/**445+ * Call bo::reserved and with the lru lock held.446+ * Will release GPU memory type usage on destruction.447+ * This is the place to put in driver specific hooks.448+ * Will release the bo::reserved lock and the449+ * lru lock on exit.450+ */451+452+static void ttm_bo_cleanup_memtype_use(struct ttm_buffer_object *bo)453+{454+ struct ttm_bo_global *glob = bo->glob;455+456+ if (bo->ttm) {457+458+ /**459+ * Release the lru_lock, since we don't want to have460+ * an atomic requirement on ttm_tt[unbind|destroy].461+ */462+463+ spin_unlock(&glob->lru_lock);464+ ttm_tt_unbind(bo->ttm);465+ ttm_tt_destroy(bo->ttm);466+ bo->ttm = NULL;467+ spin_lock(&glob->lru_lock);468+ }469+470+ if (bo->mem.mm_node) {471+ drm_mm_put_block(bo->mem.mm_node);472+ bo->mem.mm_node = NULL;473+ }474+475+ atomic_set(&bo->reserved, 0);476+ wake_up_all(&bo->event_queue);477+ spin_unlock(&glob->lru_lock);478+}479+480+481+/**482 * If bo idle, remove from delayed- and lru lists, and unref.483 * If not idle, and already on delayed list, do nothing.484 * If not idle, and not on delayed list, put on delayed list,···456 int ret;457458 spin_lock(&bo->lock);459+retry:460 (void) ttm_bo_wait(bo, false, false, !remove_all);461462 if (!bo->sync_obj) {···464 spin_unlock(&bo->lock);465466 spin_lock(&glob->lru_lock);467+ ret = ttm_bo_reserve_locked(bo, false, !remove_all, false, 0);468469+ /**470+ * Someone else has the object reserved. Bail and retry.471+ */472+473+ if (unlikely(ret == -EBUSY)) {474+ spin_unlock(&glob->lru_lock);475+ spin_lock(&bo->lock);476+ goto requeue;477+ }478+479+ /**480+ * We can re-check for sync object without taking481+ * the bo::lock since setting the sync object requires482+ * also bo::reserved. A busy object at this point may483+ * be caused by another thread starting an accelerated484+ * eviction.485+ */486+487+ if (unlikely(bo->sync_obj)) {488+ atomic_set(&bo->reserved, 0);489+ wake_up_all(&bo->event_queue);490+ spin_unlock(&glob->lru_lock);491+ spin_lock(&bo->lock);492+ if (remove_all)493+ goto retry;494+ else495+ goto requeue;496+ }497+498+ put_count = ttm_bo_del_from_lru(bo);499500 if (!list_empty(&bo->ddestroy)) {501 list_del_init(&bo->ddestroy);502 ++put_count;503 }00000504505+ ttm_bo_cleanup_memtype_use(bo);506507 while (put_count--)508 kref_put(&bo->list_kref, ttm_bo_ref_bug);509510 return 0;511 }512+requeue:513 spin_lock(&glob->lru_lock);514 if (list_empty(&bo->ddestroy)) {515 void *sync_obj = bo->sync_obj;
···109 int ret = 0;110111 mutex_lock(&minors_lock);000000112 dev = hidraw_table[minor]->hid;113114 if (!dev->hid_output_raw_report) {···250251 mutex_lock(&minors_lock);252 dev = hidraw_table[minor];0000253254 switch (cmd) {255 case HIDIOCGRDESCSIZE:···327328 ret = -ENOTTY;329 }0330 mutex_unlock(&minors_lock);331 return ret;332}
···109 int ret = 0;110111 mutex_lock(&minors_lock);112+113+ if (!hidraw_table[minor]) {114+ ret = -ENODEV;115+ goto out;116+ }117+118 dev = hidraw_table[minor]->hid;119120 if (!dev->hid_output_raw_report) {···244245 mutex_lock(&minors_lock);246 dev = hidraw_table[minor];247+ if (!dev) {248+ ret = -ENODEV;249+ goto out;250+ }251252 switch (cmd) {253 case HIDIOCGRDESCSIZE:···317318 ret = -ENOTTY;319 }320+out:321 mutex_unlock(&minors_lock);322 return ret;323}
···7172static int pca_isa_waitforcompletion(void *pd)73{74- long ret = ~0;75 unsigned long timeout;07677 if (irq > -1) {78 ret = wait_event_timeout(pca_wait,···81 } else {82 /* Do polling */83 timeout = jiffies + pca_isa_ops.timeout;84- while (((pca_isa_readbyte(pd, I2C_PCA_CON)85- & I2C_PCA_CON_SI) == 0)86- && (ret = time_before(jiffies, timeout)))0087 udelay(100);088 }089 return ret > 0;90}91
···7172static int pca_isa_waitforcompletion(void *pd)73{074 unsigned long timeout;75+ long ret;7677 if (irq > -1) {78 ret = wait_event_timeout(pca_wait,···81 } else {82 /* Do polling */83 timeout = jiffies + pca_isa_ops.timeout;84+ do {85+ ret = time_before(jiffies, timeout);86+ if (pca_isa_readbyte(pd, I2C_PCA_CON)87+ & I2C_PCA_CON_SI)88+ break;89 udelay(100);90+ } while (ret);91 }92+93 return ret > 0;94}95
+7-4
drivers/i2c/busses/i2c-pca-platform.c
···80static int i2c_pca_pf_waitforcompletion(void *pd)81{82 struct i2c_pca_pf_data *i2c = pd;83- long ret = ~0;84 unsigned long timeout;08586 if (i2c->irq) {87 ret = wait_event_timeout(i2c->wait,···90 } else {91 /* Do polling */92 timeout = jiffies + i2c->adap.timeout;93- while (((i2c->algo_data.read_byte(i2c, I2C_PCA_CON)94- & I2C_PCA_CON_SI) == 0)95- && (ret = time_before(jiffies, timeout)))0096 udelay(100);097 }9899 return ret > 0;
···80static int i2c_pca_pf_waitforcompletion(void *pd)81{82 struct i2c_pca_pf_data *i2c = pd;083 unsigned long timeout;84+ long ret;8586 if (i2c->irq) {87 ret = wait_event_timeout(i2c->wait,···90 } else {91 /* Do polling */92 timeout = jiffies + i2c->adap.timeout;93+ do {94+ ret = time_before(jiffies, timeout);95+ if (i2c->algo_data.read_byte(i2c, I2C_PCA_CON)96+ & I2C_PCA_CON_SI)97+ break;98 udelay(100);99+ } while (ret);100 }101102 return ret > 0;
···319 * a keyup event might follow immediately after the keydown.320 */321 spin_lock_irqsave(&ir->keylock, flags);322- if (time_is_after_eq_jiffies(ir->keyup_jiffies))323 ir_keyup(ir);324 spin_unlock_irqrestore(&ir->keylock, flags);325}···509 driver_name, rc_tab->name,510 (ir_dev->props && ir_dev->props->driver_type == RC_DRIVER_IR_RAW) ?511 " in raw mode" : "");0000000512513 return 0;514
···319 * a keyup event might follow immediately after the keydown.320 */321 spin_lock_irqsave(&ir->keylock, flags);322+ if (time_is_before_eq_jiffies(ir->keyup_jiffies))323 ir_keyup(ir);324 spin_unlock_irqrestore(&ir->keylock, flags);325}···509 driver_name, rc_tab->name,510 (ir_dev->props && ir_dev->props->driver_type == RC_DRIVER_IR_RAW) ?511 " in raw mode" : "");512+513+ /*514+ * Default delay of 250ms is too short for some protocols, expecially515+ * since the timeout is currently set to 250ms. Increase it to 500ms,516+ * to avoid wrong repetition of the keycodes.517+ */518+ input_dev->rep[REP_DELAY] = 500;519520 return 0;521
+1-1
drivers/media/IR/ir-lirc-codec.c
···267 features |= LIRC_CAN_SET_SEND_CARRIER;268269 if (ir_dev->props->s_tx_duty_cycle)270- features |= LIRC_CAN_SET_REC_DUTY_CYCLE;271 }272273 if (ir_dev->props->s_rx_carrier_range)
···267 features |= LIRC_CAN_SET_SEND_CARRIER;268269 if (ir_dev->props->s_tx_duty_cycle)270+ features |= LIRC_CAN_SET_SEND_DUTY_CYCLE;271 }272273 if (ir_dev->props->s_rx_carrier_range)
···1098 *1099 * @return pointer to descriptor on success, NULL on error.1100 */1101-struct smscore_buffer_t *smscore_getbuffer(struct smscore_device_t *coredev)01102{1103 struct smscore_buffer_t *cb = NULL;1104 unsigned long flags;11051106- DEFINE_WAIT(wait);1107-1108 spin_lock_irqsave(&coredev->bufferslock, flags);1109-1110- /* This function must return a valid buffer, since the buffer list is1111- * finite, we check that there is an available buffer, if not, we wait1112- * until such buffer become available.1113- */1114-1115- prepare_to_wait(&coredev->buffer_mng_waitq, &wait, TASK_INTERRUPTIBLE);1116- if (list_empty(&coredev->buffers)) {1117- spin_unlock_irqrestore(&coredev->bufferslock, flags);1118- schedule();1119- spin_lock_irqsave(&coredev->bufferslock, flags);1120 }1121-1122- finish_wait(&coredev->buffer_mng_waitq, &wait);1123-1124- cb = (struct smscore_buffer_t *) coredev->buffers.next;1125- list_del(&cb->entry);1126-1127 spin_unlock_irqrestore(&coredev->bufferslock, flags);0000000011281129 return cb;1130}
···32#include <media/v4l2-chip-ident.h>3334#include <media/cx25840.h>035#include "xc5000.h"3637#include "cx231xx.h"···176 .driver_info = CX231XX_BOARD_CNXT_RDE_250},177 {USB_DEVICE(0x0572, 0x58A1),178 .driver_info = CX231XX_BOARD_CNXT_RDU_250},00179 {},180};181···229 dev->board.name, dev->model);230231 /* set the direction for GPIO pins */232- cx231xx_set_gpio_direction(dev, dev->board.tuner_gpio->bit, 1);233- cx231xx_set_gpio_value(dev, dev->board.tuner_gpio->bit, 1);234- cx231xx_set_gpio_direction(dev, dev->board.tuner_sif_gpio, 1);0235236- /* request some modules if any required */237238- /* reset the Tuner */239- cx231xx_gpio_set(dev, dev->board.tuner_gpio);0240241 /* set the mode to Analog mode initially */242 cx231xx_set_mode(dev, CX231XX_ANALOG_MODE);
···32#include <media/v4l2-chip-ident.h>3334#include <media/cx25840.h>35+#include "dvb-usb-ids.h"36#include "xc5000.h"3738#include "cx231xx.h"···175 .driver_info = CX231XX_BOARD_CNXT_RDE_250},176 {USB_DEVICE(0x0572, 0x58A1),177 .driver_info = CX231XX_BOARD_CNXT_RDU_250},178+ {USB_DEVICE_VER(USB_VID_PIXELVIEW, USB_PID_PIXELVIEW_SBTVD, 0x4000,0x4fff),179+ .driver_info = CX231XX_BOARD_UNKNOWN},180 {},181};182···226 dev->board.name, dev->model);227228 /* set the direction for GPIO pins */229+ if (dev->board.tuner_gpio) {230+ cx231xx_set_gpio_direction(dev, dev->board.tuner_gpio->bit, 1);231+ cx231xx_set_gpio_value(dev, dev->board.tuner_gpio->bit, 1);232+ cx231xx_set_gpio_direction(dev, dev->board.tuner_sif_gpio, 1);233234+ /* request some modules if any required */235236+ /* reset the Tuner */237+ cx231xx_gpio_set(dev, dev->board.tuner_gpio);238+ }239240 /* set the mode to Analog mode initially */241 cx231xx_set_mode(dev, CX231XX_ANALOG_MODE);
···1718config VIDEO_CX88_ALSA19 tristate "Conexant 2388x DMA audio support"20- depends on VIDEO_CX88 && SND && EXPERIMENTAL21 select SND_PCM22 ---help---23 This is a video4linux driver for direct (DMA) audio on
···1718config VIDEO_CX88_ALSA19 tristate "Conexant 2388x DMA audio support"20+ depends on VIDEO_CX88 && SND21 select SND_PCM22 ---help---23 This is a video4linux driver for direct (DMA) audio on
···402 if (mt9v022->model != V4L2_IDENT_MT9V022IX7ATC)403 return -EINVAL;404 break;405- case 0:406- /* No format change, only geometry */407- break;408 default:409 return -EINVAL;410 }
···1631 if (host->bus_ops && !host->bus_dead) {1632 if (host->bus_ops->suspend)1633 err = host->bus_ops->suspend(host);00000000000001634 }1635 mmc_bus_put(host);1636
···1631 if (host->bus_ops && !host->bus_dead) {1632 if (host->bus_ops->suspend)1633 err = host->bus_ops->suspend(host);1634+ if (err == -ENOSYS || !host->bus_ops->resume) {1635+ /*1636+ * We simply "remove" the card in this case.1637+ * It will be redetected on resume.1638+ */1639+ if (host->bus_ops->remove)1640+ host->bus_ops->remove(host);1641+ mmc_claim_host(host);1642+ mmc_detach_bus(host);1643+ mmc_release_host(host);1644+ host->pm_flags = 0;1645+ err = 0;1646+ }1647 }1648 mmc_bus_put(host);1649
+2-2
drivers/net/Kconfig
···24282429config MV643XX_ETH2430 tristate "Marvell Discovery (643XX) and Orion ethernet support"2431- depends on MV64X60 || PPC32 || PLAT_ORION2432 select INET_LRO2433 select PHYLIB2434 help···28032804config PASEMI_MAC2805 tristate "PA Semi 1/10Gbit MAC"2806- depends on PPC_PASEMI && PCI2807 select PHYLIB2808 select INET_LRO2809 help
···5164 res = dev_alloc_name(bond_dev, "bond%d");5165 if (res < 0)5166 goto out;0000000005167 }51685169 res = register_netdevice(bond_dev);
···5164 res = dev_alloc_name(bond_dev, "bond%d");5165 if (res < 0)5166 goto out;5167+ } else {5168+ /*5169+ * If we're given a name to register5170+ * we need to ensure that its not already5171+ * registered5172+ */5173+ res = -EEXIST;5174+ if (__dev_get_by_name(net, name) != NULL)5175+ goto out;5176 }51775178 res = register_netdevice(bond_dev);
···533 int length = cqe->num_bytes_transfered - 4; /*remove CRC */534535 skb_put(skb, length);0536 skb->protocol = eth_type_trans(skb, dev);537+538+ /* The packet was not an IPV4 packet so a complemented checksum was539+ calculated. The value is found in the Internet Checksum field. */540+ if (cqe->status & EHEA_CQE_BLIND_CKSUM) {541+ skb->ip_summed = CHECKSUM_COMPLETE;542+ skb->csum = csum_unfold(~cqe->inet_checksum_value);543+ } else544+ skb->ip_summed = CHECKSUM_UNNECESSARY;545}546547static inline struct sk_buff *get_skb_by_index(struct sk_buff **skb_array,
···678{679 struct fec_enet_private *fep = netdev_priv(dev);680 struct phy_device *phy_dev = NULL;681- int ret;00682683 fep->phy_dev = NULL;684685- /* find the first phy */686- phy_dev = phy_find_first(fep->mii_bus);687- if (!phy_dev) {688- printk(KERN_ERR "%s: no PHY found\n", dev->name);689- return -ENODEV;00000690 }691692- /* attach the mac to the phy */693- ret = phy_connect_direct(dev, phy_dev,694- &fec_enet_adjust_link, 0,695- PHY_INTERFACE_MODE_MII);696- if (ret) {697- printk(KERN_ERR "%s: Could not attach to PHY\n", dev->name);698- return ret;000000699 }700701 /* mask with MAC supported features */···751 fep->mii_bus->read = fec_enet_mdio_read;752 fep->mii_bus->write = fec_enet_mdio_write;753 fep->mii_bus->reset = fec_enet_mdio_reset;754- snprintf(fep->mii_bus->id, MII_BUS_ID_SIZE, "%x", pdev->id);755 fep->mii_bus->priv = fep;756 fep->mii_bus->parent = &pdev->dev;757···1323 ret = fec_enet_mii_init(pdev);1324 if (ret)1325 goto failed_mii_init;00013261327 ret = register_netdev(ndev);1328 if (ret)
···678{679 struct fec_enet_private *fep = netdev_priv(dev);680 struct phy_device *phy_dev = NULL;681+ char mdio_bus_id[MII_BUS_ID_SIZE];682+ char phy_name[MII_BUS_ID_SIZE + 3];683+ int phy_id;684685 fep->phy_dev = NULL;686687+ /* check for attached phy */688+ for (phy_id = 0; (phy_id < PHY_MAX_ADDR); phy_id++) {689+ if ((fep->mii_bus->phy_mask & (1 << phy_id)))690+ continue;691+ if (fep->mii_bus->phy_map[phy_id] == NULL)692+ continue;693+ if (fep->mii_bus->phy_map[phy_id]->phy_id == 0)694+ continue;695+ strncpy(mdio_bus_id, fep->mii_bus->id, MII_BUS_ID_SIZE);696+ break;697 }698699+ if (phy_id >= PHY_MAX_ADDR) {700+ printk(KERN_INFO "%s: no PHY, assuming direct connection "701+ "to switch\n", dev->name);702+ strncpy(mdio_bus_id, "0", MII_BUS_ID_SIZE);703+ phy_id = 0;704+ }705+706+ snprintf(phy_name, MII_BUS_ID_SIZE, PHY_ID_FMT, mdio_bus_id, phy_id);707+ phy_dev = phy_connect(dev, phy_name, &fec_enet_adjust_link, 0,708+ PHY_INTERFACE_MODE_MII);709+ if (IS_ERR(phy_dev)) {710+ printk(KERN_ERR "%s: could not attach to PHY\n", dev->name);711+ return PTR_ERR(phy_dev);712 }713714 /* mask with MAC supported features */···738 fep->mii_bus->read = fec_enet_mdio_read;739 fep->mii_bus->write = fec_enet_mdio_write;740 fep->mii_bus->reset = fec_enet_mdio_reset;741+ snprintf(fep->mii_bus->id, MII_BUS_ID_SIZE, "%x", pdev->id + 1);742 fep->mii_bus->priv = fep;743 fep->mii_bus->parent = &pdev->dev;744···1310 ret = fec_enet_mii_init(pdev);1311 if (ret)1312 goto failed_mii_init;1313+1314+ /* Carrier starts down, phylib will bring it up */1315+ netif_carrier_off(ndev);13161317 ret = register_netdev(ndev);1318 if (ret)
···191 struct isl_pmic *pmic = i2c_get_clientdata(i2c);192 int i;193194- i2c_set_clientdata(i2c, NULL);195-196 for (i = 0; i < 3; i++)197 regulator_unregister(pmic->rdev[i]);198
···191 struct isl_pmic *pmic = i2c_get_clientdata(i2c);192 int i;19300194 for (i = 0; i < 3; i++)195 regulator_unregister(pmic->rdev[i]);196
···134 if (!dump_write(file, dump_start, dump_size))135 goto end_coredump;136 }137-/* Finally dump the task struct. Not be used by gdb, but could be useful */138- set_fs(KERNEL_DS);139- if (!dump_write(file, current, sizeof(*current)))140- goto end_coredump;141end_coredump:142 set_fs(fs);143 return has_dumped;
···2283{2284 struct ceph_inode_info *ci = ceph_inode(inode);2285 int mds = session->s_mds;2286- int seq = le32_to_cpu(grant->seq);02287 int newcaps = le32_to_cpu(grant->caps);2288 int issued, implemented, used, wanted, dirty;2289 u64 size = le64_to_cpu(grant->size);···2296 int revoked_rdcache = 0;2297 int queue_invalidate = 0;22982299- dout("handle_cap_grant inode %p cap %p mds%d seq %d %s\n",2300- inode, cap, mds, seq, ceph_cap_string(newcaps));2301 dout(" size %llu max_size %llu, i_size %llu\n", size, max_size,2302 inode->i_size);2303···2393 }23942395 cap->seq = seq;023962397 /* file layout may have changed */2398 ci->i_layout = grant->layout;···2776 if (op == CEPH_CAP_OP_IMPORT)2777 __queue_cap_release(session, vino.ino, cap_id,2778 mseq, seq);2779-2780- /*2781- * send any full release message to try to move things2782- * along for the mds (who clearly thinks we still have this2783- * cap).2784- */2785- ceph_add_cap_releases(mdsc, session);2786- ceph_send_cap_releases(mdsc, session);2787- goto done;2788 }27892790 /* these will work even if we don't have a cap yet */···2804 dout(" no cap on %p ino %llx.%llx from mds%d\n",2805 inode, ceph_ino(inode), ceph_snap(inode), mds);2806 spin_unlock(&inode->i_lock);2807- goto done;2808 }28092810 /* note that each of these drops i_lock for us */···2827 pr_err("ceph_handle_caps: unknown cap op %d %s\n", op,2828 ceph_cap_op_name(op));2829 }0000000000028302831done:2832 mutex_unlock(&session->s_mutex);
···2283{2284 struct ceph_inode_info *ci = ceph_inode(inode);2285 int mds = session->s_mds;2286+ unsigned seq = le32_to_cpu(grant->seq);2287+ unsigned issue_seq = le32_to_cpu(grant->issue_seq);2288 int newcaps = le32_to_cpu(grant->caps);2289 int issued, implemented, used, wanted, dirty;2290 u64 size = le64_to_cpu(grant->size);···2295 int revoked_rdcache = 0;2296 int queue_invalidate = 0;22972298+ dout("handle_cap_grant inode %p cap %p mds%d seq %u/%u %s\n",2299+ inode, cap, mds, seq, issue_seq, ceph_cap_string(newcaps));2300 dout(" size %llu max_size %llu, i_size %llu\n", size, max_size,2301 inode->i_size);2302···2392 }23932394 cap->seq = seq;2395+ cap->issue_seq = issue_seq;23962397 /* file layout may have changed */2398 ci->i_layout = grant->layout;···2774 if (op == CEPH_CAP_OP_IMPORT)2775 __queue_cap_release(session, vino.ino, cap_id,2776 mseq, seq);2777+ goto flush_cap_releases;000000002778 }27792780 /* these will work even if we don't have a cap yet */···2810 dout(" no cap on %p ino %llx.%llx from mds%d\n",2811 inode, ceph_ino(inode), ceph_snap(inode), mds);2812 spin_unlock(&inode->i_lock);2813+ goto flush_cap_releases;2814 }28152816 /* note that each of these drops i_lock for us */···2833 pr_err("ceph_handle_caps: unknown cap op %d %s\n", op,2834 ceph_cap_op_name(op));2835 }2836+2837+ goto done;2838+2839+flush_cap_releases:2840+ /*2841+ * send any full release message to try to move things2842+ * along for the mds (who clearly thinks we still have this2843+ * cap).2844+ */2845+ ceph_add_cap_releases(mdsc, session);2846+ ceph_send_cap_releases(mdsc, session);28472848done:2849 mutex_unlock(&session->s_mutex);
···42static int ceph_encode_fh(struct dentry *dentry, u32 *rawfh, int *max_len,43 int connectable)44{45+ int type;46 struct ceph_nfs_fh *fh = (void *)rawfh;47 struct ceph_nfs_confh *cfh = (void *)rawfh;48 struct dentry *parent = dentry->d_parent;49 struct inode *inode = dentry->d_inode;50+ int connected_handle_length = sizeof(*cfh)/4;51+ int handle_length = sizeof(*fh)/4;5253 /* don't re-export snaps */54 if (ceph_snap(inode) != CEPH_NOSNAP)55 return -EINVAL;5657+ if (*max_len >= connected_handle_length) {58 dout("encode_fh %p connectable\n", dentry);59 cfh->ino = ceph_ino(dentry->d_inode);60 cfh->parent_ino = ceph_ino(parent->d_inode);61 cfh->parent_name_hash = parent->d_name.hash;62+ *max_len = connected_handle_length;63 type = 2;64+ } else if (*max_len >= handle_length) {65+ if (connectable) {66+ *max_len = connected_handle_length;67+ return 255;68+ }69 dout("encode_fh %p\n", dentry);70 fh->ino = ceph_ino(dentry->d_inode);71+ *max_len = handle_length;72 type = 1;73 } else {74+ *max_len = handle_length;75+ return 255;76 }77 return type;78}
+1-1
fs/ceph/file.c
···697 * start_request so that a tid has been assigned.698 */699 spin_lock(&ci->i_unsafe_lock);700- list_add(&ci->i_unsafe_writes, &req->r_unsafe_item);701 spin_unlock(&ci->i_unsafe_lock);702 ceph_get_cap_refs(ci, CEPH_CAP_FILE_WR);703 }
···697 * start_request so that a tid has been assigned.698 */699 spin_lock(&ci->i_unsafe_lock);700+ list_add(&req->r_unsafe_item, &ci->i_unsafe_writes);701 spin_unlock(&ci->i_unsafe_lock);702 ceph_get_cap_refs(ci, CEPH_CAP_FILE_WR);703 }
···2014fail:2015 return;2016}2017+2018+/*2019+ * Core dumping helper functions. These are the only things you should2020+ * do on a core-file: use only these functions to write out all the2021+ * necessary info.2022+ */2023+int dump_write(struct file *file, const void *addr, int nr)2024+{2025+ return access_ok(VERIFY_READ, addr, nr) && file->f_op->write(file, addr, nr, &file->f_pos) == nr;2026+}2027+EXPORT_SYMBOL(dump_write);2028+2029+int dump_seek(struct file *file, loff_t off)2030+{2031+ int ret = 1;2032+2033+ if (file->f_op->llseek && file->f_op->llseek != no_llseek) {2034+ if (file->f_op->llseek(file, off, SEEK_CUR) < 0)2035+ return 0;2036+ } else {2037+ char *buf = (char *)get_zeroed_page(GFP_KERNEL);2038+2039+ if (!buf)2040+ return 0;2041+ while (off > 0) {2042+ unsigned long n = off;2043+2044+ if (n > PAGE_SIZE)2045+ n = PAGE_SIZE;2046+ if (!dump_write(file, buf, n)) {2047+ ret = 0;2048+ break;2049+ }2050+ off -= n;2051+ }2052+ free_page((unsigned long)buf);2053+ }2054+ return ret;2055+}2056+EXPORT_SYMBOL(dump_seek);
+7-1
fs/exofs/inode.c
···54 unsigned nr_pages;55 unsigned long length;56 loff_t pg_first; /* keep 64bit also in 32-arches */00057};5859static void _pcol_init(struct page_collect *pcol, unsigned expected_pages,···74 pcol->nr_pages = 0;75 pcol->length = 0;76 pcol->pg_first = -1;077}7879static void _pcol_reset(struct page_collect *pcol)···351 if (PageError(page))352 ClearPageError(page);353354- unlock_page(page);0355 EXOFS_DBGMSG("readpage_strip(0x%lx, 0x%lx) empty page,"356 " splitting\n", inode->i_ino, page->index);357···433 /* readpage_strip might call read_exec(,is_sync==false) at several434 * places but not if we have a single page.435 */0436 ret = readpage_strip(&pcol, page);437 if (ret) {438 EXOFS_ERR("_readpage => %d\n", ret);
···54 unsigned nr_pages;55 unsigned long length;56 loff_t pg_first; /* keep 64bit also in 32-arches */57+ bool read_4_write; /* This means two things: that the read is sync58+ * And the pages should not be unlocked.59+ */60};6162static void _pcol_init(struct page_collect *pcol, unsigned expected_pages,···71 pcol->nr_pages = 0;72 pcol->length = 0;73 pcol->pg_first = -1;74+ pcol->read_4_write = false;75}7677static void _pcol_reset(struct page_collect *pcol)···347 if (PageError(page))348 ClearPageError(page);349350+ if (!pcol->read_4_write)351+ unlock_page(page);352 EXOFS_DBGMSG("readpage_strip(0x%lx, 0x%lx) empty page,"353 " splitting\n", inode->i_ino, page->index);354···428 /* readpage_strip might call read_exec(,is_sync==false) at several429 * places but not if we have a single page.430 */431+ pcol.read_4_write = is_sync;432 ret = readpage_strip(&pcol, page);433 if (ret) {434 EXOFS_ERR("_readpage => %d\n", ret);
···668 xfs_perag_put(pag);669}670671-void672-__xfs_inode_clear_reclaim_tag(673- xfs_mount_t *mp,674 xfs_perag_t *pag,675 xfs_inode_t *ip)676{677- radix_tree_tag_clear(&pag->pag_ici_root,678- XFS_INO_TO_AGINO(mp, ip->i_ino), XFS_ICI_RECLAIM_TAG);679 pag->pag_ici_reclaimable--;680 if (!pag->pag_ici_reclaimable) {681 /* clear the reclaim tag from the perag radix tree */···684 trace_xfs_perag_clear_reclaim(ip->i_mount, pag->pag_agno,685 -1, _RET_IP_);686 }00000000000687}688689/*···846 if (!radix_tree_delete(&pag->pag_ici_root,847 XFS_INO_TO_AGINO(ip->i_mount, ip->i_ino)))848 ASSERT(0);0849 write_unlock(&pag->pag_ici_lock);850851 /*
···668 xfs_perag_put(pag);669}670671+STATIC void672+__xfs_inode_clear_reclaim(0673 xfs_perag_t *pag,674 xfs_inode_t *ip)675{00676 pag->pag_ici_reclaimable--;677 if (!pag->pag_ici_reclaimable) {678 /* clear the reclaim tag from the perag radix tree */···687 trace_xfs_perag_clear_reclaim(ip->i_mount, pag->pag_agno,688 -1, _RET_IP_);689 }690+}691+692+void693+__xfs_inode_clear_reclaim_tag(694+ xfs_mount_t *mp,695+ xfs_perag_t *pag,696+ xfs_inode_t *ip)697+{698+ radix_tree_tag_clear(&pag->pag_ici_root,699+ XFS_INO_TO_AGINO(mp, ip->i_ino), XFS_ICI_RECLAIM_TAG);700+ __xfs_inode_clear_reclaim(pag, ip);701}702703/*···838 if (!radix_tree_delete(&pag->pag_ici_root,839 XFS_INO_TO_AGINO(ip->i_mount, ip->i_ino)))840 ASSERT(0);841+ __xfs_inode_clear_reclaim(pag, ip);842 write_unlock(&pag->pag_ici_lock);843844 /*
+3-1
include/drm/ttm/ttm_bo_api.h
···246247 atomic_t reserved;248249-250 /**251 * Members protected by the bo::lock000252 */253254 void *sync_obj_arg;
···246247 atomic_t reserved;2480249 /**250 * Members protected by the bo::lock251+ * In addition, setting sync_obj to anything else252+ * than NULL requires bo::reserved to be held. This allows for253+ * checking NULL while reserved but not holding bo::lock.254 */255256 void *sync_obj_arg;
···9 * These are the only things you should do on a core-file: use only these10 * functions to write out all the necessary info.11 */12-static inline int dump_write(struct file *file, const void *addr, int nr)13-{14- return file->f_op->write(file, addr, nr, &file->f_pos) == nr;15-}16-17-static inline int dump_seek(struct file *file, loff_t off)18-{19- int ret = 1;20-21- if (file->f_op->llseek && file->f_op->llseek != no_llseek) {22- if (file->f_op->llseek(file, off, SEEK_CUR) < 0)23- return 0;24- } else {25- char *buf = (char *)get_zeroed_page(GFP_KERNEL);26-27- if (!buf)28- return 0;29- while (off > 0) {30- unsigned long n = off;31-32- if (n > PAGE_SIZE)33- n = PAGE_SIZE;34- if (!dump_write(file, buf, n)) {35- ret = 0;36- break;37- }38- off -= n;39- }40- free_page((unsigned long)buf);41- }42- return ret;43-}4445#endif /* _LINUX_COREDUMP_H */
···9 * These are the only things you should do on a core-file: use only these10 * functions to write out all the necessary info.11 */12+extern int dump_write(struct file *file, const void *addr, int nr);13+extern int dump_seek(struct file *file, loff_t off);0000000000000000000000000000001415#endif /* _LINUX_COREDUMP_H */
···121typedef __s64 int64_t;122#endif123124-/* this is a special 64bit data type that is 8-byte aligned */00000000125#define aligned_u64 __u64 __attribute__((aligned(8)))126#define aligned_be64 __be64 __attribute__((aligned(8)))127#define aligned_le64 __le64 __attribute__((aligned(8)))···185186typedef __u16 __bitwise __sum16;187typedef __u32 __bitwise __wsum;00000188189#ifdef __KERNEL__190typedef unsigned __bitwise__ gfp_t;
···121typedef __s64 int64_t;122#endif123124+/*125+ * aligned_u64 should be used in defining kernel<->userspace ABIs to avoid126+ * common 32/64-bit compat problems.127+ * 64-bit values align to 4-byte boundaries on x86_32 (and possibly other128+ * architectures) and to 8-byte boundaries on 64-bit architetures. The new129+ * aligned_64 type enforces 8-byte alignment so that structs containing130+ * aligned_64 values have the same alignment on 32-bit and 64-bit architectures.131+ * No conversions are necessary between 32-bit user-space and a 64-bit kernel.132+ */133#define aligned_u64 __u64 __attribute__((aligned(8)))134#define aligned_be64 __be64 __attribute__((aligned(8)))135#define aligned_le64 __le64 __attribute__((aligned(8)))···177178typedef __u16 __bitwise __sum16;179typedef __u32 __bitwise __wsum;180+181+/* this is a special 64bit data type that is 8-byte aligned */182+#define __aligned_u64 __u64 __attribute__((aligned(8)))183+#define __aligned_be64 __be64 __attribute__((aligned(8)))184+#define __aligned_le64 __le64 __attribute__((aligned(8)))185186#ifdef __KERNEL__187typedef unsigned __bitwise__ gfp_t;
+1
include/media/videobuf-dma-sg.h
···4849 /* for userland buffer */50 int offset;051 struct page **pages;5253 /* for kernel buffers */
···4849 /* for userland buffer */50 int offset;51+ size_t size;52 struct page **pages;5354 /* for kernel buffers */
···2215#ifdef __ARCH_SI_TRAPNO2216 err |= __put_user(from->si_trapno, &to->si_trapno);2217#endif2218+#ifdef BUS_MCEERR_AO2219+ /* 2220+ * Other callers might not initialize the si_lsb field,2221+ * so check explicitely for the right codes here.2222+ */2223+ if (from->si_code == BUS_MCEERR_AR || from->si_code == BUS_MCEERR_AO)2224+ err |= __put_user(from->si_addr_lsb, &to->si_addr_lsb);2225+#endif2226 break;2227 case __SI_CHLD:2228 err |= __put_user(from->si_pid, &to->si_pid);
+1-1
kernel/sysctl.c
···2485 kbuf[left] = 0;2486 }24872488- for (; left && vleft--; i++, min++, max++, first=0) {2489 unsigned long val;24902491 if (write) {
···2485 kbuf[left] = 0;2486 }24872488+ for (; left && vleft--; i++, first = 0) {2489 unsigned long val;24902491 if (write) {
-9
kernel/sysctl_check.c
···143 if (!table->maxlen)144 set_fail(&fail, table, "No maxlen");145 }146- if ((table->proc_handler == proc_doulongvec_minmax) ||147- (table->proc_handler == proc_doulongvec_ms_jiffies_minmax)) {148- if (table->maxlen > sizeof (unsigned long)) {149- if (!table->extra1)150- set_fail(&fail, table, "No min");151- if (!table->extra2)152- set_fail(&fail, table, "No max");153- }154- }155#ifdef CONFIG_PROC_SYSCTL156 if (table->procname && !table->proc_handler)157 set_fail(&fail, table, "No proc_handler");
···143 if (!table->maxlen)144 set_fail(&fail, table, "No maxlen");145 }000000000146#ifdef CONFIG_PROC_SYSCTL147 if (table->procname && !table->proc_handler)148 set_fail(&fail, table, "No proc_handler");
+1-1
kernel/trace/ring_buffer.c
···405#define BUF_MAX_DATA_SIZE (BUF_PAGE_SIZE - (sizeof(u32) * 2))406407/* Max number of timestamps that can fit on a page */408-#define RB_TIMESTAMPS_PER_PAGE (BUF_PAGE_SIZE / RB_LEN_TIME_STAMP)409410int ring_buffer_print_page_header(struct trace_seq *s)411{
···405#define BUF_MAX_DATA_SIZE (BUF_PAGE_SIZE - (sizeof(u32) * 2))406407/* Max number of timestamps that can fit on a page */408+#define RB_TIMESTAMPS_PER_PAGE (BUF_PAGE_SIZE / RB_LEN_TIME_EXTEND)409410int ring_buffer_print_page_header(struct trace_seq *s)411{
+7-3
mm/memcontrol.c
···35873588static void mem_cgroup_threshold(struct mem_cgroup *memcg)3589{3590- __mem_cgroup_threshold(memcg, false);3591- if (do_swap_account)3592- __mem_cgroup_threshold(memcg, true);00003593}35943595static int compare_thresholds(const void *a, const void *b)
···35873588static void mem_cgroup_threshold(struct mem_cgroup *memcg)3589{3590+ while (memcg) {3591+ __mem_cgroup_threshold(memcg, false);3592+ if (do_swap_account)3593+ __mem_cgroup_threshold(memcg, true);3594+3595+ memcg = parent_mem_cgroup(memcg);3596+ }3597}35983599static int compare_thresholds(const void *a, const void *b)
+6-6
mm/memory-failure.c
···183 * signal.184 */185static int kill_proc_ao(struct task_struct *t, unsigned long addr, int trapno,186- unsigned long pfn)187{188 struct siginfo si;189 int ret;···198#ifdef __ARCH_SI_TRAPNO199 si.si_trapno = trapno;200#endif201- si.si_addr_lsb = PAGE_SHIFT;202 /*203 * Don't use force here, it's convenient if the signal204 * can be temporarily blocked.···235 int nr;236 do {237 nr = shrink_slab(1000, GFP_KERNEL, 1000);238- if (page_count(p) == 0)239 break;240 } while (nr > 10);241 }···327 * wrong earlier.328 */329static void kill_procs_ao(struct list_head *to_kill, int doit, int trapno,330- int fail, unsigned long pfn)331{332 struct to_kill *tk, *next;333···352 * process anyways.353 */354 else if (kill_proc_ao(tk->tsk, tk->addr, trapno,355- pfn) < 0)356 printk(KERN_ERR357 "MCE %#lx: Cannot send advisory machine check signal to %s:%d\n",358 pfn, tk->tsk->comm, tk->tsk->pid);···928 * any accesses to the poisoned memory.929 */930 kill_procs_ao(&tokill, !!PageDirty(hpage), trapno,931- ret != SWAP_SUCCESS, pfn);932933 return ret;934}
···183 * signal.184 */185static int kill_proc_ao(struct task_struct *t, unsigned long addr, int trapno,186+ unsigned long pfn, struct page *page)187{188 struct siginfo si;189 int ret;···198#ifdef __ARCH_SI_TRAPNO199 si.si_trapno = trapno;200#endif201+ si.si_addr_lsb = compound_order(compound_head(page)) + PAGE_SHIFT;202 /*203 * Don't use force here, it's convenient if the signal204 * can be temporarily blocked.···235 int nr;236 do {237 nr = shrink_slab(1000, GFP_KERNEL, 1000);238+ if (page_count(p) == 1)239 break;240 } while (nr > 10);241 }···327 * wrong earlier.328 */329static void kill_procs_ao(struct list_head *to_kill, int doit, int trapno,330+ int fail, struct page *page, unsigned long pfn)331{332 struct to_kill *tk, *next;333···352 * process anyways.353 */354 else if (kill_proc_ao(tk->tsk, tk->addr, trapno,355+ pfn, page) < 0)356 printk(KERN_ERR357 "MCE %#lx: Cannot send advisory machine check signal to %s:%d\n",358 pfn, tk->tsk->comm, tk->tsk->pid);···928 * any accesses to the poisoned memory.929 */930 kill_procs_ao(&tokill, !!PageDirty(hpage), trapno,931+ ret != SWAP_SUCCESS, p, pfn);932933 return ret;934}
···14411442static void l2cap_streaming_send(struct sock *sk)1443{1444+ struct sk_buff *skb;1445 struct l2cap_pinfo *pi = l2cap_pi(sk);1446 u16 control, fcs;14471448+ while ((skb = skb_dequeue(TX_QUEUE(sk)))) {1449+ control = get_unaligned_le16(skb->data + L2CAP_HDR_SIZE);001450 control |= pi->next_tx_seq << L2CAP_CTRL_TXSEQ_SHIFT;1451+ put_unaligned_le16(control, skb->data + L2CAP_HDR_SIZE);14521453 if (pi->fcs == L2CAP_FCS_CRC16) {1454+ fcs = crc16(0, (u8 *)skb->data, skb->len - 2);1455+ put_unaligned_le16(fcs, skb->data + skb->len - 2);1456 }14571458+ l2cap_do_send(sk, skb);14591460 pi->next_tx_seq = (pi->next_tx_seq + 1) % 64;000000001461 }1462}1463···19601961 switch (optname) {1962 case L2CAP_OPTIONS:1963+ if (sk->sk_state == BT_CONNECTED) {1964+ err = -EINVAL;1965+ break;1966+ }1967+1968 opts.imtu = l2cap_pi(sk)->imtu;1969 opts.omtu = l2cap_pi(sk)->omtu;1970 opts.flush_to = l2cap_pi(sk)->flush_to;···2771 case L2CAP_CONF_MTU:2772 if (val < L2CAP_DEFAULT_MIN_MTU) {2773 *result = L2CAP_CONF_UNACCEPT;2774+ pi->imtu = L2CAP_DEFAULT_MIN_MTU;2775 } else2776+ pi->imtu = val;2777+ l2cap_add_conf_opt(&ptr, L2CAP_CONF_MTU, 2, pi->imtu);2778 break;27792780 case L2CAP_CONF_FLUSH_TO:···3071 return 0;3072}30733074+static inline void set_default_fcs(struct l2cap_pinfo *pi)3075+{3076+ /* FCS is enabled only in ERTM or streaming mode, if one or both3077+ * sides request it.3078+ */3079+ if (pi->mode != L2CAP_MODE_ERTM && pi->mode != L2CAP_MODE_STREAMING)3080+ pi->fcs = L2CAP_FCS_NONE;3081+ else if (!(pi->conf_state & L2CAP_CONF_NO_FCS_RECV))3082+ pi->fcs = L2CAP_FCS_CRC16;3083+}3084+3085static inline int l2cap_config_req(struct l2cap_conn *conn, struct l2cap_cmd_hdr *cmd, u16 cmd_len, u8 *data)3086{3087 struct l2cap_conf_req *req = (struct l2cap_conf_req *) data;···3088 if (!sk)3089 return -ENOENT;30903091+ if (sk->sk_state == BT_DISCONN)000003092 goto unlock;030933094 /* Reject if config buffer is too small. */3095 len = cmd_len - sizeof(*req);···3135 goto unlock;31363137 if (l2cap_pi(sk)->conf_state & L2CAP_CONF_INPUT_DONE) {3138+ set_default_fcs(l2cap_pi(sk));0031393140 sk->sk_state = BT_CONNECTED;3141···3225 l2cap_pi(sk)->conf_state |= L2CAP_CONF_INPUT_DONE;32263227 if (l2cap_pi(sk)->conf_state & L2CAP_CONF_OUTPUT_DONE) {3228+ set_default_fcs(l2cap_pi(sk));0032293230 sk->sk_state = BT_CONNECTED;3231 l2cap_pi(sk)->next_tx_seq = 0;
+4
net/bluetooth/rfcomm/sock.c
···82static void rfcomm_sk_state_change(struct rfcomm_dlc *d, int err)83{84 struct sock *sk = d->owner, *parent;0085 if (!sk)86 return;8788 BT_DBG("dlc %p state %ld err %d", d, d->state, err);89090 bh_lock_sock(sk);9192 if (err)···111 }112113 bh_unlock_sock(sk);0114115 if (parent && sock_flag(sk, SOCK_ZAPPED)) {116 /* We have to drop DLC lock here, otherwise
···82static void rfcomm_sk_state_change(struct rfcomm_dlc *d, int err)83{84 struct sock *sk = d->owner, *parent;85+ unsigned long flags;86+87 if (!sk)88 return;8990 BT_DBG("dlc %p state %ld err %d", d, d->state, err);9192+ local_irq_save(flags);93 bh_lock_sock(sk);9495 if (err)···108 }109110 bh_unlock_sock(sk);111+ local_irq_restore(flags);112113 if (parent && sock_flag(sk, SOCK_ZAPPED)) {114 /* We have to drop DLC lock here, otherwise
+15-6
net/caif/caif_socket.c
···827 long timeo;828 int err;829 int ifindex, headroom, tailroom;0830 struct net_device *dev;831832 lock_sock(sk);···897 cf_sk->sk.sk_state = CAIF_DISCONNECTED;898 goto out;899 }900- dev = dev_get_by_index(sock_net(sk), ifindex);0000000901 cf_sk->headroom = LL_RESERVED_SPACE_EXTRA(dev, headroom);000902 cf_sk->tailroom = tailroom;903- cf_sk->maxframe = dev->mtu - (headroom + tailroom);904- dev_put(dev);905 if (cf_sk->maxframe < 1) {906- pr_warning("CAIF: %s(): CAIF Interface MTU too small (%d)\n",907- __func__, dev->mtu);908- err = -ENODEV;909 goto out;910 }911
···827 long timeo;828 int err;829 int ifindex, headroom, tailroom;830+ unsigned int mtu;831 struct net_device *dev;832833 lock_sock(sk);···896 cf_sk->sk.sk_state = CAIF_DISCONNECTED;897 goto out;898 }899+900+ err = -ENODEV;901+ rcu_read_lock();902+ dev = dev_get_by_index_rcu(sock_net(sk), ifindex);903+ if (!dev) {904+ rcu_read_unlock();905+ goto out;906+ }907 cf_sk->headroom = LL_RESERVED_SPACE_EXTRA(dev, headroom);908+ mtu = dev->mtu;909+ rcu_read_unlock();910+911 cf_sk->tailroom = tailroom;912+ cf_sk->maxframe = mtu - (headroom + tailroom);0913 if (cf_sk->maxframe < 1) {914+ pr_warning("CAIF: %s(): CAIF Interface MTU too small (%u)\n",915+ __func__, mtu);0916 goto out;917 }918
+4-4
net/core/ethtool.c
···348 if (info.cmd == ETHTOOL_GRXCLSRLALL) {349 if (info.rule_cnt > 0) {350 if (info.rule_cnt <= KMALLOC_MAX_SIZE / sizeof(u32))351- rule_buf = kmalloc(info.rule_cnt * sizeof(u32),352 GFP_USER);353 if (!rule_buf)354 return -ENOMEM;···397 (KMALLOC_MAX_SIZE - sizeof(*indir)) / sizeof(*indir->ring_index))398 return -ENOMEM;399 full_size = sizeof(*indir) + sizeof(*indir->ring_index) * table_size;400- indir = kmalloc(full_size, GFP_USER);401 if (!indir)402 return -ENOMEM;403···538539 gstrings.len = ret;540541- data = kmalloc(gstrings.len * ETH_GSTRING_LEN, GFP_USER);542 if (!data)543 return -ENOMEM;544···775 if (regs.len > reglen)776 regs.len = reglen;777778- regbuf = kmalloc(reglen, GFP_USER);779 if (!regbuf)780 return -ENOMEM;781
···348 if (info.cmd == ETHTOOL_GRXCLSRLALL) {349 if (info.rule_cnt > 0) {350 if (info.rule_cnt <= KMALLOC_MAX_SIZE / sizeof(u32))351+ rule_buf = kzalloc(info.rule_cnt * sizeof(u32),352 GFP_USER);353 if (!rule_buf)354 return -ENOMEM;···397 (KMALLOC_MAX_SIZE - sizeof(*indir)) / sizeof(*indir->ring_index))398 return -ENOMEM;399 full_size = sizeof(*indir) + sizeof(*indir->ring_index) * table_size;400+ indir = kzalloc(full_size, GFP_USER);401 if (!indir)402 return -ENOMEM;403···538539 gstrings.len = ret;540541+ data = kzalloc(gstrings.len * ETH_GSTRING_LEN, GFP_USER);542 if (!data)543 return -ENOMEM;544···775 if (regs.len > reglen)776 regs.len = reglen;777778+ regbuf = kzalloc(reglen, GFP_USER);779 if (!regbuf)780 return -ENOMEM;781
···413 If unsure, say Y.414415config INET_LRO416- bool "Large Receive Offload (ipv4/tcp)"417 default y418 ---help---419 Support for Large Receive Offload (ipv4/tcp).
···413 If unsure, say Y.414415config INET_LRO416+ tristate "Large Receive Offload (ipv4/tcp)"417 default y418 ---help---419 Support for Large Receive Offload (ipv4/tcp).
+13-1
net/ipv4/igmp.c
···834 int mark = 0;835836837- if (len == 8 || IGMP_V2_SEEN(in_dev)) {838 if (ih->code == 0) {839 /* Alas, old v1 router presents here. */840···856 igmpv3_clear_delrec(in_dev);857 } else if (len < 12) {858 return; /* ignore bogus packet; freed by caller */000000000000859 } else { /* v3 */860 if (!pskb_may_pull(skb, sizeof(struct igmpv3_query)))861 return;
···834 int mark = 0;835836837+ if (len == 8) {838 if (ih->code == 0) {839 /* Alas, old v1 router presents here. */840···856 igmpv3_clear_delrec(in_dev);857 } else if (len < 12) {858 return; /* ignore bogus packet; freed by caller */859+ } else if (IGMP_V1_SEEN(in_dev)) {860+ /* This is a v3 query with v1 queriers present */861+ max_delay = IGMP_Query_Response_Interval;862+ group = 0;863+ } else if (IGMP_V2_SEEN(in_dev)) {864+ /* this is a v3 query with v2 queriers present;865+ * Interpretation of the max_delay code is problematic here.866+ * A real v2 host would use ih_code directly, while v3 has a867+ * different encoding. We use the v3 encoding as more likely868+ * to be intended in a v3 query.869+ */870+ max_delay = IGMPV3_MRC(ih3->code)*(HZ/IGMP_TIMER_SCALE);871 } else { /* v3 */872 if (!pskb_may_pull(skb, sizeof(struct igmpv3_query)))873 return;
+24-4
net/ipv6/route.c
···1556 * i.e. Path MTU discovery1557 */15581559-void rt6_pmtu_discovery(struct in6_addr *daddr, struct in6_addr *saddr,1560- struct net_device *dev, u32 pmtu)1561{1562 struct rt6_info *rt, *nrt;1563- struct net *net = dev_net(dev);1564 int allfrag = 0;15651566- rt = rt6_lookup(net, daddr, saddr, dev->ifindex, 0);1567 if (rt == NULL)1568 return;1569···1628 }1629out:1630 dst_release(&rt->dst);0000000000000000000001631}16321633/*
···1556 * i.e. Path MTU discovery1557 */15581559+static void rt6_do_pmtu_disc(struct in6_addr *daddr, struct in6_addr *saddr,1560+ struct net *net, u32 pmtu, int ifindex)1561{1562 struct rt6_info *rt, *nrt;01563 int allfrag = 0;15641565+ rt = rt6_lookup(net, daddr, saddr, ifindex, 0);1566 if (rt == NULL)1567 return;1568···1629 }1630out:1631 dst_release(&rt->dst);1632+}1633+1634+void rt6_pmtu_discovery(struct in6_addr *daddr, struct in6_addr *saddr,1635+ struct net_device *dev, u32 pmtu)1636+{1637+ struct net *net = dev_net(dev);1638+1639+ /*1640+ * RFC 1981 states that a node "MUST reduce the size of the packets it1641+ * is sending along the path" that caused the Packet Too Big message.1642+ * Since it's not possible in the general case to determine which1643+ * interface was used to send the original packet, we update the MTU1644+ * on the interface that will be used to send future packets. We also1645+ * update the MTU on the interface that received the Packet Too Big in1646+ * case the original packet was forced out that interface with1647+ * SO_BINDTODEVICE or similar. This is the next best thing to the1648+ * correct behaviour, which would be to update the MTU on all1649+ * interfaces.1650+ */1651+ rt6_do_pmtu_disc(daddr, saddr, net, pmtu, 0);1652+ rt6_do_pmtu_disc(daddr, saddr, net, pmtu, dev->ifindex);1653}16541655/*
+2
net/mac80211/agg-tx.c
···175176 set_bit(HT_AGG_STATE_STOPPING, &tid_tx->state);17700178 /*179 * After this packets are no longer handed right through180 * to the driver but are put onto tid_tx->pending instead,
···175176 set_bit(HT_AGG_STATE_STOPPING, &tid_tx->state);177178+ del_timer_sync(&tid_tx->addba_resp_timer);179+180 /*181 * After this packets are no longer handed right through182 * to the driver but are put onto tid_tx->pending instead,
···137 int toff = off + key->off + (off2 & key->offmask);138 __be32 *data, _data;139140- if (skb_headroom(skb) + toff < 0)141 goto out;142143 data = skb_header_pointer(skb, toff, 4, &_data);
···137 int toff = off + key->off + (off2 & key->offmask);138 __be32 *data, _data;139140+ if (skb_headroom(skb) + toff > INT_MAX)141 goto out;142143 data = skb_header_pointer(skb, toff, 4, &_data);
+6-2
net/sctp/auth.c
···543 id = ntohs(hmacs->hmac_ids[i]);544545 /* Check the id is in the supported range */546- if (id > SCTP_AUTH_HMAC_ID_MAX)0547 continue;0548549 /* See is we support the id. Supported IDs have name and550 * length fields set, so that we can allocated and use551 * them. We can safely just check for name, for without the552 * name, we can't allocate the TFM.553 */554- if (!sctp_hmac_list[id].hmac_name)0555 continue;0556557 break;558 }
···543 id = ntohs(hmacs->hmac_ids[i]);544545 /* Check the id is in the supported range */546+ if (id > SCTP_AUTH_HMAC_ID_MAX) {547+ id = 0;548 continue;549+ }550551 /* See is we support the id. Supported IDs have name and552 * length fields set, so that we can allocated and use553 * them. We can safely just check for name, for without the554 * name, we can't allocate the TFM.555 */556+ if (!sctp_hmac_list[id].hmac_name) {557+ id = 0;558 continue;559+ }560561 break;562 }
+12-1
net/sctp/socket.c
···916 /* Walk through the addrs buffer and count the number of addresses. */917 addr_buf = kaddrs;918 while (walk_size < addrs_size) {00000919 sa_addr = (struct sockaddr *)addr_buf;920 af = sctp_get_af_specific(sa_addr->sa_family);921···1007 /* Walk through the addrs buffer and count the number of addresses. */1008 addr_buf = kaddrs;1009 while (walk_size < addrs_size) {000001010 sa_addr = (union sctp_addr *)addr_buf;1011 af = sctp_get_af_specific(sa_addr->sa.sa_family);1012- port = ntohs(sa_addr->v4.sin_port);10131014 /* If the address family is not supported or if this address1015 * causes the address buffer to overflow return EINVAL.···1022 err = -EINVAL;1023 goto out_free;1024 }0010251026 /* Save current address so we can work with it */1027 memcpy(&to, sa_addr, af->sockaddr_len);
···916 /* Walk through the addrs buffer and count the number of addresses. */917 addr_buf = kaddrs;918 while (walk_size < addrs_size) {919+ if (walk_size + sizeof(sa_family_t) > addrs_size) {920+ kfree(kaddrs);921+ return -EINVAL;922+ }923+924 sa_addr = (struct sockaddr *)addr_buf;925 af = sctp_get_af_specific(sa_addr->sa_family);926···1002 /* Walk through the addrs buffer and count the number of addresses. */1003 addr_buf = kaddrs;1004 while (walk_size < addrs_size) {1005+ if (walk_size + sizeof(sa_family_t) > addrs_size) {1006+ err = -EINVAL;1007+ goto out_free;1008+ }1009+1010 sa_addr = (union sctp_addr *)addr_buf;1011 af = sctp_get_af_specific(sa_addr->sa.sa_family);010121013 /* If the address family is not supported or if this address1014 * causes the address buffer to overflow return EINVAL.···1013 err = -EINVAL;1014 goto out_free;1015 }1016+1017+ port = ntohs(sa_addr->v4.sin_port);10181019 /* Save current address so we can work with it */1020 memcpy(&to, sa_addr, af->sockaddr_len);
+1-1
scripts/kconfig/conf.c
···427 if (sym->name && !sym_is_choice_value(sym)) {428 printf("CONFIG_%s\n", sym->name);429 }430- } else {431 if (!conf_cnt++)432 printf(_("*\n* Restart config...\n*\n"));433 rootEntry = menu_get_parent_menu(menu);
···427 if (sym->name && !sym_is_choice_value(sym)) {428 printf("CONFIG_%s\n", sym->name);429 }430+ } else if (input_mode != oldnoconfig) {431 if (!conf_cnt++)432 printf(_("*\n* Restart config...\n*\n"));433 rootEntry = menu_get_parent_menu(menu);
···391 case SND_DEV_DSP:392 case SND_DEV_DSP16:393 case SND_DEV_AUDIO:394- return audio_ioctl(dev, file, cmd, p);395 break;396397 case SND_DEV_MIDIN:398- return MIDIbuf_ioctl(dev, file, cmd, p);399 break;400401 }
···391 case SND_DEV_DSP:392 case SND_DEV_DSP16:393 case SND_DEV_AUDIO:394+ ret = audio_ioctl(dev, file, cmd, p);395 break;396397 case SND_DEV_MIDIN:398+ ret = MIDIbuf_ioctl(dev, file, cmd, p);399 break;400401 }