ƒ¿F229337 91 1074 1074 257 414 257 257 494 860 2095 180 180 229 229 1335 1335 1335 194 3038 3038 3038 135 157 157 458 458 458 357 163 397 293 225 779 142 483 229 228 180 180 298 127 202 199 135 327 450 397 178 151 308 270 628 285 628 232 419 404 154 154 350 154 238 238 238 380 322 321 529 570 570 570 235 184 301 106 119 116 203 398 328 256 3912 3912 3908 859 1285 1285 294 1285 347 170 575 K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-02T23:38:03.433675Z K 7 svn:log V 977 MFC r226701: Add support for ALi/ULi, now NVIDIA, M5261/M5263 PCI FastEthernet controller which is found on ULi M1563 South Bridge & M1689 Bridge. These controllers look like a tulip clone. M5263 controller does not support MII bitbang so use DC_ROM register to access MII registers. Like other tulip variants, ULi controller uses a setup frame to configure RX filter and uses new setup frame format. It's not clear to me whether the controller supports a hash based multicast filtering so this patch uses 14 perfect multicast filter to filter multicast frames. If number of multicast addresses is greater than 14, controller is put into a mode that receives all multicast frames. Due to lack of access to M5261, this change was not tested with M5261 but it probably works. Many thanks to Marco who provided remote access to M5263. Tested by: Marco Steinbach executive-computing dot de>, Martin MATO orange dot fr> END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-02T23:40:09.772814Z K 7 svn:log V 977 MFC r226701: Add support for ALi/ULi, now NVIDIA, M5261/M5263 PCI FastEthernet controller which is found on ULi M1563 South Bridge & M1689 Bridge. These controllers look like a tulip clone. M5263 controller does not support MII bitbang so use DC_ROM register to access MII registers. Like other tulip variants, ULi controller uses a setup frame to configure RX filter and uses new setup frame format. It's not clear to me whether the controller supports a hash based multicast filtering so this patch uses 14 perfect multicast filter to filter multicast frames. If number of multicast addresses is greater than 14, controller is put into a mode that receives all multicast frames. Due to lack of access to M5261, this change was not tested with M5261 but it probably works. Many thanks to Marco who provided remote access to M5263. Tested by: Marco Steinbach executive-computing dot de>, Martin MATO orange dot fr> END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-02T23:43:08.624376Z K 7 svn:log V 160 MFC 226703-226704: r226703: Add ALi/ULi M5261/M5263 to supported hardware chipets. r226704: All dc(4) controllers support VLAN over-sized frame. Xr vlan END K 10 svn:author V 3 gjb K 8 svn:date V 27 2012-01-02T23:43:16.958037Z K 7 svn:log V 321 MFC r228356: r228356: - Update du(1): - Sort arguments alphabetically where appropriate - '-B blocksize' is not mutually exclusive of '-h|-k|-m' - Mention '-t' in synopsis - Other wording improvements - Update usage() output to reflect the new synopsis - Other miscellaneous improvements PR: 162438 END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-02T23:43:26.287138Z K 7 svn:log V 160 MFC 226703-226704: r226703: Add ALi/ULi M5261/M5263 to supported hardware chipets. r226704: All dc(4) controllers support VLAN over-sized frame. Xr vlan END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-02T23:43:45.006055Z K 7 svn:log V 160 MFC 226703-226704: r226703: Add ALi/ULi M5261/M5263 to supported hardware chipets. r226704: All dc(4) controllers support VLAN over-sized frame. Xr vlan END K 10 svn:author V 3 gjb K 8 svn:date V 27 2012-01-02T23:44:07.552503Z K 7 svn:log V 401 MFC r210993, r228356: r210933 (joel): - Fix typos and spelling mistakes r228356: [3] - Update du(1): - Sort arguments alphabetically where appropriate - '-B blocksize' is not mutually exclusive of '-h|-k|-m' - Mention '-t' in synopsis - Other wording improvements - Update usage() output to reflect the new synopsis - Other miscellaneous improvements PR: 162438 [3] END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-02T23:47:51.197607Z K 7 svn:log V 763 MFC r226709: This change makes it possible to define driver specific attach handler such that driver can announce interface capabilities and can do its own MII attach. Currently all USB ethernet controllers have no way to establish a link with pause capabilities. Lack of checksum offloading support also was one of reason to bring this change in. This change adds a couple of wrappers to USB ethernet drivers (uether_ifmedia_upd, uether_init and uether_start). All exported functions in uether has prefix uether_ so I think it's more consistent to have wrappers that follow the convention. This change preserves ABI/KPI so it should be safe to merge this change to stable/8. While I'm here add missing __FBSDID and clean up headers. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-02T23:50:32.880714Z K 7 svn:log V 1997 MFC r226743: Implement TX/RX checksum offloading support for ASIX AX88772B controller. AX88772B data sheet does not show detailed information about checksum offloading related things. It seems the controller has lots of options to support checksum offloading but I failed to understand why this feature requires so much complex controller configuration and status bits. One of major difference between AX88772B and its predecessor is AX88772B uses a new RX header format when RX checksum offloading is enabled. It also requires the received length of a frame should be multiple of 4. Controller will pad necessary bytes to make the length of received frame to be multiple of 4. It is driver's responsibility to offset this pad bytes. Note, AX88772B could be configured to get partial checksum value in in RX header. This mode uses different RX header format and currently we don't use that fature. This change makes axe(4) use driver specific MII attach handler to override uether(9)'s default MII attach and announce flow-control capability for AX88178/AX88772A/AX88772B to PHY drivers. It seems original AX88772 also supports flow-control but I didn't enable it due to lack of test/access to the controller. The flow-control threshold parameter is loaded from EEPROM and there is no way to override this value without reprogramming EEPROM. For AX88772B, TX/RX IP/TCP/UDP checksum offloading is announced to network stack. IPv6 and PPPoE checksum offloading is also supported by controller but we have no way to take advantage of these features. Driver already knows PHY address so make PHY driver know that information and remove unnecessary PHY address check used in miibus_readreg/miibus_writereg callbacks. Also announce AX88178, AX88772A and AX88772B support VLAN over-sized frame. While I'm here clean up headers and remove axe_start() in axe_init() because the link wouldn't be available right after media change. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-02T23:52:20.362840Z K 7 svn:log V 84 MFC r226744: AX88178/AX88772A/AX88772B supports VLAN over-sized frame. Xr vlan. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-02T23:52:32.943727Z K 7 svn:log V 84 MFC r226744: AX88178/AX88772A/AX88772B supports VLAN over-sized frame. Xr vlan. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-02T23:53:26.176756Z K 7 svn:log V 132 MFC r226745: axe(4) got VLAN over-sized frame support. Add axe(4) to the list of interfaces that support VLAN over-sized frame. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-02T23:53:36.428289Z K 7 svn:log V 132 MFC r226745: axe(4) got VLAN over-sized frame support. Add axe(4) to the list of interfaces that support VLAN over-sized frame. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T00:07:49.055226Z K 7 svn:log V 1237 MFC r226749,226770,226804-226807: r226749: Whitespace nits. r226770: Fix long standing bge_sysctl_debug_info() issues. o Protect bge(4) status block access and register dump with driver lock. o Add missing bus_dmamap_sync() before dumping status block. o Use minimum status block size, 32 bytes, for status block dump on most controllers except BCM5700 AX/BX. While I'm here, make the handler show 5717 Plus in hardware flags. r226804: Make CPMU handle GPHY power down control on controllers that have CPMU capability. r226805: It is known that all Broadcom controllers have 4GB boundary DMA bug. Apply workaround to all controllers. r226806: Broadcom says BCM5755 or higher and BCM5906 have short DMA bug. Apply workaround to these controllers. r226807: BCM5719 cannot handle DMA requests for DMA segments that have larger than 4KB in size. However the maximum DMA segment size created in DMA tag is 4KB, so we wouldn't encounter the issue here. Just record this issue such that let developers not to create a DMA segment that is larger than 4KB for BCM5719. It's possible to split a DMA segment into multiple smaller ones in run time but I believe it's not worth to implement that. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T00:10:30.536371Z K 7 svn:log V 1237 MFC r226749,226770,226804-226807: r226749: Whitespace nits. r226770: Fix long standing bge_sysctl_debug_info() issues. o Protect bge(4) status block access and register dump with driver lock. o Add missing bus_dmamap_sync() before dumping status block. o Use minimum status block size, 32 bytes, for status block dump on most controllers except BCM5700 AX/BX. While I'm here, make the handler show 5717 Plus in hardware flags. r226804: Make CPMU handle GPHY power down control on controllers that have CPMU capability. r226805: It is known that all Broadcom controllers have 4GB boundary DMA bug. Apply workaround to all controllers. r226806: Broadcom says BCM5755 or higher and BCM5906 have short DMA bug. Apply workaround to these controllers. r226807: BCM5719 cannot handle DMA requests for DMA segments that have larger than 4KB in size. However the maximum DMA segment size created in DMA tag is 4KB, so we wouldn't encounter the issue here. Just record this issue such that let developers not to create a DMA segment that is larger than 4KB for BCM5719. It's possible to split a DMA segment into multiple smaller ones in run time but I believe it's not worth to implement that. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T00:12:06.221669Z K 7 svn:log V 1237 MFC r226749,226770,226804-226807: r226749: Whitespace nits. r226770: Fix long standing bge_sysctl_debug_info() issues. o Protect bge(4) status block access and register dump with driver lock. o Add missing bus_dmamap_sync() before dumping status block. o Use minimum status block size, 32 bytes, for status block dump on most controllers except BCM5700 AX/BX. While I'm here, make the handler show 5717 Plus in hardware flags. r226804: Make CPMU handle GPHY power down control on controllers that have CPMU capability. r226805: It is known that all Broadcom controllers have 4GB boundary DMA bug. Apply workaround to all controllers. r226806: Broadcom says BCM5755 or higher and BCM5906 have short DMA bug. Apply workaround to these controllers. r226807: BCM5719 cannot handle DMA requests for DMA segments that have larger than 4KB in size. However the maximum DMA segment size created in DMA tag is 4KB, so we wouldn't encounter the issue here. Just record this issue such that let developers not to create a DMA segment that is larger than 4KB for BCM5719. It's possible to split a DMA segment into multiple smaller ones in run time but I believe it's not worth to implement that. END K 10 svn:author V 3 gjb K 8 svn:date V 27 2012-01-03T00:22:08.668721Z K 7 svn:log V 101 Trivial standardization to a few comments in kern.pre.mk. Submitted by: arundel MFC after: 3 days END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T00:22:57.918819Z K 7 svn:log V 2940 MFC r226814-226815,226820-226821,226864,226866-226867: r226814: Rename definition of BGE_SOFTWARE_GENCOMM_* to more readable ones. The origin of GENCOMM seems to come from Alteon Tigon Host/NIC interface definition where it defines general communications region which is active when firmware is loaded and running. This region was used in communication between the host and processor internal to the Tigon chip. Broadcom data sheet also defines the region as 'Software Gencomm' in NetXtreme memory map but lacks detailed description of its interface so it was hard to know which ones are used for which interface. This change shall slightly enhance readability. No functional changes. r226815: Define MAC address mail box and use it instead of using hard-coded value. r226820: Offset 0x6810 is RX-RISC event register. Rename BGE_CPU_EVENT with BGE_RX_CPU_EVENT for readability. Additionally define BGE_TX_CPU_EVENT for TX-RSIC event register(BCM570[0-4] only). r226821: SRAM offset 0x0C04 is used by driver to inform the IPMI/ASF firmware about the various driver events like load, unload, reset, suspend, restart, and ioctl operations. Define driver's event rather than using hard-coded values. We don't still send suspend/resume event to firmware. Previously bge(4) used BGE_SDI_STATUS to send events. Because driver has to access firmware mail box to inform current state, using BGE_SDI_STATUS register was wrong. The end result was the same as BGE_SDI_STATUS is 0x0C04. No functional changes. r226864: Rename BGE_FW_DRV_ALIVE/BGE_FW_PAUSE to BGE_FW_CMD_DRV_ALIVE/BGE_FW_CMD_PAUSE. Also add more firmware commands(not used yet). No functional changes. r226866: Rename hard-coded value 1 << 14 with BGE_RX_CPU_DRV_EVENT. This bit(SW event 7 in publicly available data sheet) is used to make RX CPU handle a firmware command and the bit is automatically cleared after RX CPU completed the command. Generally firmware command takes the following steps. 1. Write BGE_SRAM_FW_CMD_MB with a command. 2. Write BGE_SRAM_FW_CMD_LEN_MB with the length of the command in bytes. 3. Write BGE_SRAM_FW_CMD_DATA_MB with actual command data. 4. Generate BGE_RX_CPU_EVENT and let firmware handle the command. 5. Wait for the ACK of the firmware command. No functional changes. r226867: Define BGE_FW_HB_TIMEOUT_SEC and remove one more magic value. bge(4) sends BGE_FW_CMD_DRV_ALIVE command to firmware every 2 seconds. BGE_FW_CMD_DRV_ALIVE command requires 4 bytes data. This data contains timeout value in seconds until the next BGE_FW_CMD_DRV_ALIVE command. Broadcom recommends driver set the value 3 times longer than the interval that it sends BGE_FW_CMD_DRV_ALIVE. Currently bge(4) uses 3 seconds so probably we have to increase it in future and use different ALIVE command(e.g. BGE_FW_CMD_DRV_ALIVE3). No functional changes. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T00:24:44.353728Z K 7 svn:log V 2940 MFC r226814-226815,226820-226821,226864,226866-226867: r226814: Rename definition of BGE_SOFTWARE_GENCOMM_* to more readable ones. The origin of GENCOMM seems to come from Alteon Tigon Host/NIC interface definition where it defines general communications region which is active when firmware is loaded and running. This region was used in communication between the host and processor internal to the Tigon chip. Broadcom data sheet also defines the region as 'Software Gencomm' in NetXtreme memory map but lacks detailed description of its interface so it was hard to know which ones are used for which interface. This change shall slightly enhance readability. No functional changes. r226815: Define MAC address mail box and use it instead of using hard-coded value. r226820: Offset 0x6810 is RX-RISC event register. Rename BGE_CPU_EVENT with BGE_RX_CPU_EVENT for readability. Additionally define BGE_TX_CPU_EVENT for TX-RSIC event register(BCM570[0-4] only). r226821: SRAM offset 0x0C04 is used by driver to inform the IPMI/ASF firmware about the various driver events like load, unload, reset, suspend, restart, and ioctl operations. Define driver's event rather than using hard-coded values. We don't still send suspend/resume event to firmware. Previously bge(4) used BGE_SDI_STATUS to send events. Because driver has to access firmware mail box to inform current state, using BGE_SDI_STATUS register was wrong. The end result was the same as BGE_SDI_STATUS is 0x0C04. No functional changes. r226864: Rename BGE_FW_DRV_ALIVE/BGE_FW_PAUSE to BGE_FW_CMD_DRV_ALIVE/BGE_FW_CMD_PAUSE. Also add more firmware commands(not used yet). No functional changes. r226866: Rename hard-coded value 1 << 14 with BGE_RX_CPU_DRV_EVENT. This bit(SW event 7 in publicly available data sheet) is used to make RX CPU handle a firmware command and the bit is automatically cleared after RX CPU completed the command. Generally firmware command takes the following steps. 1. Write BGE_SRAM_FW_CMD_MB with a command. 2. Write BGE_SRAM_FW_CMD_LEN_MB with the length of the command in bytes. 3. Write BGE_SRAM_FW_CMD_DATA_MB with actual command data. 4. Generate BGE_RX_CPU_EVENT and let firmware handle the command. 5. Wait for the ACK of the firmware command. No functional changes. r226867: Define BGE_FW_HB_TIMEOUT_SEC and remove one more magic value. bge(4) sends BGE_FW_CMD_DRV_ALIVE command to firmware every 2 seconds. BGE_FW_CMD_DRV_ALIVE command requires 4 bytes data. This data contains timeout value in seconds until the next BGE_FW_CMD_DRV_ALIVE command. Broadcom recommends driver set the value 3 times longer than the interval that it sends BGE_FW_CMD_DRV_ALIVE. Currently bge(4) uses 3 seconds so probably we have to increase it in future and use different ALIVE command(e.g. BGE_FW_CMD_DRV_ALIVE3). No functional changes. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T00:26:11.652082Z K 7 svn:log V 2940 MFC r226814-226815,226820-226821,226864,226866-226867: r226814: Rename definition of BGE_SOFTWARE_GENCOMM_* to more readable ones. The origin of GENCOMM seems to come from Alteon Tigon Host/NIC interface definition where it defines general communications region which is active when firmware is loaded and running. This region was used in communication between the host and processor internal to the Tigon chip. Broadcom data sheet also defines the region as 'Software Gencomm' in NetXtreme memory map but lacks detailed description of its interface so it was hard to know which ones are used for which interface. This change shall slightly enhance readability. No functional changes. r226815: Define MAC address mail box and use it instead of using hard-coded value. r226820: Offset 0x6810 is RX-RISC event register. Rename BGE_CPU_EVENT with BGE_RX_CPU_EVENT for readability. Additionally define BGE_TX_CPU_EVENT for TX-RSIC event register(BCM570[0-4] only). r226821: SRAM offset 0x0C04 is used by driver to inform the IPMI/ASF firmware about the various driver events like load, unload, reset, suspend, restart, and ioctl operations. Define driver's event rather than using hard-coded values. We don't still send suspend/resume event to firmware. Previously bge(4) used BGE_SDI_STATUS to send events. Because driver has to access firmware mail box to inform current state, using BGE_SDI_STATUS register was wrong. The end result was the same as BGE_SDI_STATUS is 0x0C04. No functional changes. r226864: Rename BGE_FW_DRV_ALIVE/BGE_FW_PAUSE to BGE_FW_CMD_DRV_ALIVE/BGE_FW_CMD_PAUSE. Also add more firmware commands(not used yet). No functional changes. r226866: Rename hard-coded value 1 << 14 with BGE_RX_CPU_DRV_EVENT. This bit(SW event 7 in publicly available data sheet) is used to make RX CPU handle a firmware command and the bit is automatically cleared after RX CPU completed the command. Generally firmware command takes the following steps. 1. Write BGE_SRAM_FW_CMD_MB with a command. 2. Write BGE_SRAM_FW_CMD_LEN_MB with the length of the command in bytes. 3. Write BGE_SRAM_FW_CMD_DATA_MB with actual command data. 4. Generate BGE_RX_CPU_EVENT and let firmware handle the command. 5. Wait for the ACK of the firmware command. No functional changes. r226867: Define BGE_FW_HB_TIMEOUT_SEC and remove one more magic value. bge(4) sends BGE_FW_CMD_DRV_ALIVE command to firmware every 2 seconds. BGE_FW_CMD_DRV_ALIVE command requires 4 bytes data. This data contains timeout value in seconds until the next BGE_FW_CMD_DRV_ALIVE command. Broadcom recommends driver set the value 3 times longer than the interval that it sends BGE_FW_CMD_DRV_ALIVE. Currently bge(4) uses 3 seconds so probably we have to increase it in future and use different ALIVE command(e.g. BGE_FW_CMD_DRV_ALIVE3). No functional changes. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T00:45:14.118261Z K 7 svn:log V 39 MFC r226870: Recognize BCM5720C PHY. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T00:47:54.147411Z K 7 svn:log V 61 Recognize BCM5720C PHY. This is a direct commit to stable/8. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T00:49:12.342753Z K 7 svn:log V 61 Recognize BCM5720C PHY. This is a direct commit to stable/7. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T00:56:05.994251Z K 7 svn:log V 361 MFC r226871-226872: r226871: Add initial BCM5720 support. Many thanks to Broadcom for continuing support of FreeBSD. Submitted by: Geans Pin at Broadcom (initial version) H/W donated by: Broadcom r226872: Disable updating InputDiscards counter for BCM5717, BCM5718, BCM5719 A0 and BCM5720 A0 and add comment why driver does not try to read it. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T01:02:26.304670Z K 7 svn:log V 361 MFC r226871-226872: r226871: Add initial BCM5720 support. Many thanks to Broadcom for continuing support of FreeBSD. Submitted by: Geans Pin at Broadcom (initial version) H/W donated by: Broadcom r226872: Disable updating InputDiscards counter for BCM5717, BCM5718, BCM5719 A0 and BCM5720 A0 and add comment why driver does not try to read it. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T01:07:02.078700Z K 7 svn:log V 361 MFC r226871-226872: r226871: Add initial BCM5720 support. Many thanks to Broadcom for continuing support of FreeBSD. Submitted by: Geans Pin at Broadcom (initial version) H/W donated by: Broadcom r226872: Disable updating InputDiscards counter for BCM5717, BCM5718, BCM5719 A0 and BCM5720 A0 and add comment why driver does not try to read it. END K 10 svn:author V 3 alc K 8 svn:date V 27 2012-01-03T03:29:01.345150Z K 7 svn:log V 264 Don't pass VM_ALLOC_ZERO to vm_page_grab() in tmpfs_mappedwrite() and tmpfs_nocacheread(). It is both unnecessary and a pessimization. It results in either the page being zeroed twice or zeroed first and then overwritten by an I/O operation. MFC after: 3 weeks END K 10 svn:author V 6 eadler K 8 svn:date V 27 2012-01-03T03:38:50.842819Z K 7 svn:log V 68 MFC r228795: - document the -l option to usermod Approved by: gjb END K 10 svn:author V 8 rmacklem K 8 svn:date V 27 2012-01-03T04:12:40.810800Z K 7 svn:log V 299 MFC: r227543 Modify the new NFS client so that nfs_fsync() only calls ncl_flush() for regular files. Since other file types don't write into the buffer cache, calling ncl_flush() is almost a no-op. However, it does clear the NMODIFIED flag and this shouldn't be done by nfs_fsync() for directories. END K 10 svn:author V 2 ed K 8 svn:date V 27 2012-01-03T07:05:30.910776Z K 7 svn:log V 201 Implement extensions on top of standards instead of the other way around. Now that index() and rindex() have become unused, simply turn them into wrappers around strchr() and strrchr(), respectively. END K 10 svn:author V 2 ed K 8 svn:date V 27 2012-01-03T07:06:35.180632Z K 7 svn:log V 133 Add support for strong aliasing of symbols in i386 assembly. This macro is a literal copy from the MIPS version of . END K 10 svn:author V 2 ed K 8 svn:date V 27 2012-01-03T07:14:01.800175Z K 7 svn:log V 687 Merge index() and strchr() together. As I looked through the C library, I noticed the FreeBSD MIPS port has a hand-written version of index(). This is nice, if it weren't for the fact that most applications call strchr() instead. Also, on the other architectures index() and strchr() are identical, meaning we have two identical pieces of code in the C library and statically linked applications. Solve this by naming the actual file strchr.[cS] and let it use __strong_reference()/STRONG_ALIAS() to provide the index() routine. Do the same for rindex()/strrchr(). This seems to make the C libraries and static binaries slightly smaller, but this reduction in size seems negligible. END K 10 svn:author V 8 hselasky K 8 svn:date V 27 2012-01-03T08:31:47.341118Z K 7 svn:log V 45 MFC r229317: Fix for USB suspend and resume. END K 10 svn:author V 8 hselasky K 8 svn:date V 27 2012-01-03T09:15:54.297728Z K 7 svn:log V 385 MFC r228483, r228640, r228709, r228711, r228723 and r229086: - Implement better support for USB controller suspend and resume. - Add code to wait for USB shutdown to be executed at system shutdown. - Add sysctl which can be used to skip this waiting. NOTE: All USB controller drivers needs to be re-compiled after this change due to changes in some USB controller only structures. END K 10 svn:author V 8 hselasky K 8 svn:date V 27 2012-01-03T09:17:50.494568Z K 7 svn:log V 131 MFC r228758: - Fix for race against user-space applications trying to change the configuration on USB HUBs. PR: kern/163091 END K 10 svn:author V 3 kib K 8 svn:date V 27 2012-01-03T09:27:23.030985Z K 7 svn:log V 135 MFC r229104: Make the comment in i386/include/ucontext.h identical to the one in amd64/include/ucontext.h. The later is better worded. END K 10 svn:author V 3 kib K 8 svn:date V 27 2012-01-03T09:40:31.373182Z K 7 svn:log V 88 MFC rr225973: Convert ARM to the syscallenter/syscallret system call sequence handlers. END K 10 svn:author V 3 kib K 8 svn:date V 27 2012-01-03T09:42:08.478269Z K 7 svn:log V 88 MFC r226065: Convert MIPS to the syscallenter/syscallret system call sequence handlers. END K 10 svn:author V 8 bschmidt K 8 svn:date V 27 2012-01-03T09:42:31.700452Z K 7 svn:log V 200 Don't rely on MCS7 being at index 7 while determining the amount of antennas to use. Not all APs enable all MCS rates. Poked by: Lucius Windschuh MFC after: 1 week END K 10 svn:author V 3 kib K 8 svn:date V 27 2012-01-03T09:43:26.614541Z K 7 svn:log V 35 MFC r226112: Remove unused define. END K 10 svn:author V 3 kib K 8 svn:date V 27 2012-01-03T09:46:51.649835Z K 7 svn:log V 109 MFC r225974: Remove no longer valid statement about ARM. MFC r226066: Remove no longer needed BUGS section. END K 10 svn:author V 3 kib K 8 svn:date V 27 2012-01-03T09:51:34.407693Z K 7 svn:log V 106 MFC r228261: Use explicit information from the kernel to detect the traps due to syscall entry and leave. END K 10 svn:author V 5 kevlo K 8 svn:date V 27 2012-01-03T10:01:12.385362Z K 7 svn:log V 41 Add support for Intel EG20T serial ports END K 10 svn:author V 3 kib K 8 svn:date V 27 2012-01-03T10:02:44.828436Z K 7 svn:log V 234 MFC r228307: Force linker error when created shared library contains a relocation against text. Provide the override switch to turn off the strict behaviour. Apparently, openssl libcrypto needs it due to assembler code not being PIC. END K 10 svn:author V 7 delphij K 8 svn:date V 27 2012-01-03T10:22:09.913243Z K 7 svn:log V 353 MFC r226471 (se): Add missing default values for daily/800.scrub-zfs for documentation purposes. No functional change, since all parameters are set to their default values. MFC r226865 (delphij): Increase default scrub threshold from 30 days to 5 weeks. Using whole weeks makes it easier to predicate when the scrub would happen. Requested by: gjb END K 10 svn:author V 3 kib K 8 svn:date V 27 2012-01-03T10:30:27.273191Z K 7 svn:log V 304 MFC r227102: Provide typedefs for the type of bit mask for the page bits. Use the defined types instead of int when manipulating masks. Supposedly, it could fix support for 32KB page size in the machine-independend VM layer. MFC r227103: Remove redundand definitions. The chunk was missed from r227102. END K 10 svn:author V 3 kib K 8 svn:date V 27 2012-01-03T10:36:38.424637Z K 7 svn:log V 86 MFC r227530: Update the device pager interface. Sponsored by: The FreeBSD Foundation END K 10 svn:author V 2 ed K 8 svn:date V 27 2012-01-03T11:08:58.796924Z K 7 svn:log V 60 Simply use getprogname() to obtain the name of the process. END K 10 svn:author V 2 ed K 8 svn:date V 27 2012-01-03T11:10:15.156786Z K 7 svn:log V 216 Fix subtle typo: compare against idx -- not index. In this contest, index refers to the index(3) function. In this case it doesn't really harm, as this function is never called with idx == NULL. MFC after: 2 weeks END K 10 svn:author V 2 ed K 8 svn:date V 27 2012-01-03T11:13:07.712448Z K 7 svn:log V 178 Remove hand-written version of strcspn(). The code searches for the first occurence of @, : or !. Upon failure, it returns the index of \0. This is exactly what strcspn() does. END K 10 svn:author V 3 mav K 8 svn:date V 27 2012-01-03T12:47:55.037201Z K 7 svn:log V 535 MFC r225839: Import the rest of HID improvements from the branch: - improve report descriptor parser in libusbhid to handle several kinds of reports same time; - add to the libusbhid API two functions wrapping respective kernel IOCTLs for reading and writing reports; - tune uhid IOCTL interface to allow reading and writing arbitrary report, when multiple supported by the device; - teach usbhidctl to set output and feature reports; - make usbhidaction support all the same item names as bhidctl. Sponsored by: iXsystems, inc. END K 10 svn:author V 3 mav K 8 svn:date V 27 2012-01-03T13:13:31.786380Z K 7 svn:log V 192 MFC r213920 (by hselasky): - Add support for libusbhid in 32-bit compatibility mode. - Add missing check for ugd_actlen being too small. - Add missing inclusion guard to usbvar.h header file. END K 10 svn:author V 3 mav K 8 svn:date V 27 2012-01-03T13:16:47.066159Z K 7 svn:log V 535 MFC r225839: Import the rest of HID improvements from the branch: - improve report descriptor parser in libusbhid to handle several kinds of reports same time; - add to the libusbhid API two functions wrapping respective kernel IOCTLs for reading and writing reports; - tune uhid IOCTL interface to allow reading and writing arbitrary report, when multiple supported by the device; - teach usbhidctl to set output and feature reports; - make usbhidaction support all the same item names as bhidctl. Sponsored by: iXsystems, inc. END K 10 svn:author V 3 jhb K 8 svn:date V 27 2012-01-03T16:22:29.150532Z K 7 svn:log V 139 Use TAILQ_FOREACH() instead of TAILQ_FOREACH_SAFE() for some loops that do not modify the queues they iterate over. Submitted by: glebius END K 10 svn:author V 8 rmacklem K 8 svn:date V 27 2012-01-03T16:32:33.529619Z K 7 svn:log V 321 MFC: r227690 The old NFS client will crash due to the reply being m_freem()'d twice if the server bogusly returns an error with the NFSERR_RETERR bit (bit 31) set. No actual NFS error has this bit set, but it seems that amd will sometimes do this. This patch makes sure the NFSERR_RETERR bit is cleared to avoid a crash. END K 10 svn:author V 7 fabient K 8 svn:date V 27 2012-01-03T16:35:00.079959Z K 7 svn:log V 307 MFC r226514,r226526,r226986: Add a flush of the current PMC log buffer before displaying the next top. As the underlying block is 4KB if the PMC throughput is low the measurement will be reported on the next tick. pmcstat(8) use the modified flush API to reclaim current buffer before displaying next top. END K 10 svn:author V 7 fabient K 8 svn:date V 27 2012-01-03T16:41:38.204779Z K 7 svn:log V 58 MFC r228198: Update Westmere uncore event exception list. END K 10 svn:author V 7 fabient K 8 svn:date V 27 2012-01-03T16:54:47.891324Z K 7 svn:log V 58 MFC r228198: Update Westmere uncore event exception list. END K 10 svn:author V 3 mav K 8 svn:date V 27 2012-01-03T17:04:09.671865Z K 7 svn:log V 257 Add support for CDRIOCGETBLOCKSIZE and CDRIOCSETBLOCKSIZE IOCTLs to control sector size same as acd driver does. Together with r228808 and r228847 this allows existing multimedia/vlc to play Audio CDs via CAM cd driver. PR: ports/162190 MFC after: 1 week END K 10 svn:author V 7 fabient K 8 svn:date V 27 2012-01-03T17:07:11.222611Z K 7 svn:log V 58 MFC r228198: Update Westmere uncore event exception list. END K 10 svn:author V 7 fabient K 8 svn:date V 27 2012-01-03T17:15:27.046828Z K 7 svn:log V 141 MFC r228438: There's a small set of events on Nehalem, that are not supported in processors with CPUID signature 06_1AH, 06_1EH, and 06_1FH. END K 10 svn:author V 7 fabient K 8 svn:date V 27 2012-01-03T17:17:30.892340Z K 7 svn:log V 141 MFC r228438: There's a small set of events on Nehalem, that are not supported in processors with CPUID signature 06_1AH, 06_1EH, and 06_1FH. END K 10 svn:author V 7 fabient K 8 svn:date V 27 2012-01-03T17:19:57.244315Z K 7 svn:log V 141 MFC r228438: There's a small set of events on Nehalem, that are not supported in processors with CPUID signature 06_1AH, 06_1EH, and 06_1FH. END K 10 svn:author V 3 jhb K 8 svn:date V 27 2012-01-03T17:31:27.108911Z K 7 svn:log V 287 Improve the cscope target's handling of MD directories. Automatically include the MACHINE_CPUARCH directory if it differents from MACHINE when building an index for a single machine. Also, include the 'x86' directory when building an index for i386, pc98, or amd64. MFC after: 1 week END K 10 svn:author V 3 dim K 8 svn:date V 27 2012-01-03T18:40:41.421550Z K 7 svn:log V 229 In sys/dev/if_ndis/if_ndis_pccard.c, fix a bug where a garbage rid was passed to resource_list_add(). The rid that was just returned by bus_alloc_resource_any() should have been used instead. Reviewed by: jhb MFC after: 1 week END K 10 svn:author V 3 dim K 8 svn:date V 27 2012-01-03T18:49:39.159162Z K 7 svn:log V 228 In sys/compat/linux/linux_ioctl.c, work around a warning when a pointer is compared to an integer, by casting the pointer to l_uintptr_t. No functional difference on both i386 and amd64. Reviewed by: ed, jhb MFC after: 1 week END K 10 svn:author V 2 ed K 8 svn:date V 27 2012-01-03T18:51:58.693805Z K 7 svn:log V 437 Replace index() and rindex() calls with strchr() and strrchr(). The index() and rindex() functions were marked LEGACY in the 2001 revision of POSIX and were subsequently removed from the 2008 revision. The strchr() and strrchr() functions are part of the C standard. This makes the source code a lot more consistent, as most of these C files also call into other str*() routines. In fact, about a dozen already perform strchr() calls. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T18:58:20.256778Z K 7 svn:log V 473 MFC r227086-227089: r227086: Use ANSI function definations. r227087: No functional changes. r227088: Make ti(4) build with 'options TI_PRIVATE_JUMBOS'. This was broken in r175872. We have a UMA backed jumbo allocator and that is much better implementation than having a local jumbo buffer allocator in driver. This local allocator would be removed in near future but fixing build before removal wouldn't be a bad idea. r227089: s/u_intXX_t/uintXX_t/g END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T19:00:29.461182Z K 7 svn:log V 473 MFC r227086-227089: r227086: Use ANSI function definations. r227087: No functional changes. r227088: Make ti(4) build with 'options TI_PRIVATE_JUMBOS'. This was broken in r175872. We have a UMA backed jumbo allocator and that is much better implementation than having a local jumbo buffer allocator in driver. This local allocator would be removed in near future but fixing build before removal wouldn't be a bad idea. r227089: s/u_intXX_t/uintXX_t/g END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T19:01:54.932850Z K 7 svn:log V 473 MFC r227086-227089: r227086: Use ANSI function definations. r227087: No functional changes. r227088: Make ti(4) build with 'options TI_PRIVATE_JUMBOS'. This was broken in r175872. We have a UMA backed jumbo allocator and that is much better implementation than having a local jumbo buffer allocator in driver. This local allocator would be removed in near future but fixing build before removal wouldn't be a bad idea. r227089: s/u_intXX_t/uintXX_t/g END K 10 svn:author V 3 pfg K 8 svn:date V 27 2012-01-03T19:09:01.983864Z K 7 svn:log V 142 Minor cleanups to ntfs code bzero -> memset rename variables to avoid shadowing. PR: 142401 Obtained from: NetBSD Approved by jhb (mentor) END K 10 svn:author V 5 gonzo K 8 svn:date V 27 2012-01-03T19:10:37.023636Z K 7 svn:log V 90 - Octeon-SDK strictly requires multi_count to be zero for full and low speed devices. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T19:22:28.867510Z K 7 svn:log V 204 MFC r219547: - Allocate the DMA memory shared between the host and the controller as coherent. - Constify the ti_devs table. - Don't bother to set if_mtu to ETHERMTU, ether_ifattach() does that. END K 10 svn:author V 6 mjacob K 8 svn:date V 27 2012-01-03T19:24:33.360718Z K 7 svn:log V 11 IFC@229408 END K 10 svn:author V 2 ed K 8 svn:date V 27 2012-01-03T19:38:56.753546Z K 7 svn:log V 28 Import compiler-rt r147467. END K 10 svn:author V 2 ed K 8 svn:date V 27 2012-01-03T19:39:27.490311Z K 7 svn:log V 25 Tag compiler-rt r147467. END K 10 svn:author V 2 ed K 8 svn:date V 27 2012-01-03T19:41:36.784707Z K 7 svn:log V 111 Import compiler-rt r147467. The compiler-rt shipped with FreeBSD is now based on unmodified upstream sources. END K 10 svn:author V 3 jhb K 8 svn:date V 27 2012-01-03T19:44:36.494542Z K 7 svn:log V 305 Grab a reference on the matching interface address (ifa) in the handling of the SIOC[DG]LIFADDR icotls before dropping the IF_ADDR_LOCK() and release the reference after using it. This prevents the address from being potentially freed out from under the ioctl handler. Reviewed by: bz MFC after: 1 week END K 10 svn:author V 3 pfg K 8 svn:date V 27 2012-01-03T19:47:32.988341Z K 7 svn:log V 235 Integrate the line drawing algorithm from the book "Graphic Gems 1". http://www.graphicsgems.org/ At the time it claimed to be 3-4 times faster than the traditional algorithm. PR: 18769 Approved by: jhb (mentor) MFC after: 2 weeks END K 10 svn:author V 7 delphij K 8 svn:date V 27 2012-01-03T20:17:35.668159Z K 7 svn:log V 159 Don't forget to release queue lock when allocation of memory failed. Submitted by: Sascha Wildner Obtained from: DragonFly MFC after: 2 weeks END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T20:24:56.953361Z K 7 svn:log V 3814 MFC r227091-227095,227098-227099: r227091: Make sure to unload loaded DMA area(descriptor, command, event ring). r227092: Announce IFCAP_LINKSTATE capability and let network stack know link state changes. Hide superfluous link up/down message under bootverbose since if_link_state_change(9) shows that information. While I'm here, change baudrate with the resolved speed of the established link instead of blindly setting it 1G. Unfortunately, it seems there is no way to differentiate 10/100Mbps from non-gigabit link so just assume we established a 100Mbps link if current link is not a gigabit link. r227093: Introduce ti_ifmedia_upd_locked() to use in driver initialization and add missing driver lock for both ti_ifmedia_upd() and ti_ifmedia_sts(). r227094: Don't clear upper 4bits from VLAN tag information. It's responsibility of vlan(4) to extract VLAN id from the tag information and vlan(4) correctly handles it. r227095: Don't abuse if_hwassist and make sure enabling corresponding TX/RX checksum offloading and VLAN hardware tag insertion/stripping from the currently enabled hardware offloading capabilities. Previously if_hwassist, which was initialized to TX/RX checksum offloading, was blindly used to enable both TX and RX checksum offloading such that disabling either TX or RX checksum offloading was not possible. ti(4) controllers support TX/RX checksum offloading with VLAN tagging so announce TX/RX checksum offloading capability over VLAN to vlan(4). Make VLAN hardware tag insertion/stripping honors currently enabled interface capability instead of blindly enabling VLAN hardware tagging. This change allows disabling hardware support of VLAN tag. Because ti(4) supports VLAN oversized frames, make network stack know the capability by setting if_hdrlen. While I'm here, rewrite SIOCSIFCAP handler and make sure to reinitialize controller whenever TX/RX checksum offloading and VLAN hardware tagging option is changed. The requirement of controller reinitialization comes from the limitation of Tigon I/II firmware. Tigon I/II firmware requires all related RCBs should be reinitialized whenever any of its hardware offloading capabilities change. vlan(4) is also notified whenever the parent interface's capability changes such that it can correctly handle TX/RX checksum offloading based on parent interface's enabled offloading capabilities. RX checksum offloading handler was changed to make upper stack use controller computed partial checksum value. Previously, ti(4) just set the computed value for any frames(IPv4, IPv6) and the value was not used in upper stack because driver didn't set CSUM_DATA_VALID such that upper network stack had to recompute checksum of TCP/UDP packets. I have no idea how this was not noticed for a long time. With this change, upper network stack does not have to fully recompute the checksum such that calculating pseudo checksum based on partial checksum is sufficient to know whether received packet's checksum is correct or not. However, I don't know why ti(4) does not have controller compute pseudo checksum as controller has ability to do it. I'm just guessing enabling that feature could trigger a firmware bug or could be slower than computing it on host side so just leave it as it was. In order not to produce false positives, ti(4) now checks whether controller actually computed IP or TCP/UDP checksum by checking ti_flags field. r227098: Because ti(4) drops a driver lock in RX handler, check whether driver is still running before re-enabling interrupts. r227099: Implement altq(4) support. While I'm here fix a logic error in r227098 where it didn't re-enable interrupts when TX queue is empty. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T20:26:28.233299Z K 7 svn:log V 3814 MFC r227091-227095,227098-227099: r227091: Make sure to unload loaded DMA area(descriptor, command, event ring). r227092: Announce IFCAP_LINKSTATE capability and let network stack know link state changes. Hide superfluous link up/down message under bootverbose since if_link_state_change(9) shows that information. While I'm here, change baudrate with the resolved speed of the established link instead of blindly setting it 1G. Unfortunately, it seems there is no way to differentiate 10/100Mbps from non-gigabit link so just assume we established a 100Mbps link if current link is not a gigabit link. r227093: Introduce ti_ifmedia_upd_locked() to use in driver initialization and add missing driver lock for both ti_ifmedia_upd() and ti_ifmedia_sts(). r227094: Don't clear upper 4bits from VLAN tag information. It's responsibility of vlan(4) to extract VLAN id from the tag information and vlan(4) correctly handles it. r227095: Don't abuse if_hwassist and make sure enabling corresponding TX/RX checksum offloading and VLAN hardware tag insertion/stripping from the currently enabled hardware offloading capabilities. Previously if_hwassist, which was initialized to TX/RX checksum offloading, was blindly used to enable both TX and RX checksum offloading such that disabling either TX or RX checksum offloading was not possible. ti(4) controllers support TX/RX checksum offloading with VLAN tagging so announce TX/RX checksum offloading capability over VLAN to vlan(4). Make VLAN hardware tag insertion/stripping honors currently enabled interface capability instead of blindly enabling VLAN hardware tagging. This change allows disabling hardware support of VLAN tag. Because ti(4) supports VLAN oversized frames, make network stack know the capability by setting if_hdrlen. While I'm here, rewrite SIOCSIFCAP handler and make sure to reinitialize controller whenever TX/RX checksum offloading and VLAN hardware tagging option is changed. The requirement of controller reinitialization comes from the limitation of Tigon I/II firmware. Tigon I/II firmware requires all related RCBs should be reinitialized whenever any of its hardware offloading capabilities change. vlan(4) is also notified whenever the parent interface's capability changes such that it can correctly handle TX/RX checksum offloading based on parent interface's enabled offloading capabilities. RX checksum offloading handler was changed to make upper stack use controller computed partial checksum value. Previously, ti(4) just set the computed value for any frames(IPv4, IPv6) and the value was not used in upper stack because driver didn't set CSUM_DATA_VALID such that upper network stack had to recompute checksum of TCP/UDP packets. I have no idea how this was not noticed for a long time. With this change, upper network stack does not have to fully recompute the checksum such that calculating pseudo checksum based on partial checksum is sufficient to know whether received packet's checksum is correct or not. However, I don't know why ti(4) does not have controller compute pseudo checksum as controller has ability to do it. I'm just guessing enabling that feature could trigger a firmware bug or could be slower than computing it on host side so just leave it as it was. In order not to produce false positives, ti(4) now checks whether controller actually computed IP or TCP/UDP checksum by checking ti_flags field. r227098: Because ti(4) drops a driver lock in RX handler, check whether driver is still running before re-enabling interrupts. r227099: Implement altq(4) support. While I'm here fix a logic error in r227098 where it didn't re-enable interrupts when TX queue is empty. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T20:28:17.002315Z K 7 svn:log V 3810 MFC r227091-227095,227098-227099: r227091: Make sure to unload loaded DMA area(descriptor, command, event ring). r227092: Paritial merge since IFCAP_LINKSTATE capability is not available on stable/7. Hide superfluous link up/down message under bootverbose since if_link_state_change(9) shows that information. While I'm here, change baudrate with the resolved speed of the established link instead of blindly setting it 1G. Unfortunately, it seems there is no way to differentiate 10/100Mbps from non-gigabit link so just assume we established a 100Mbps link if current link is not a gigabit link. r227093: Introduce ti_ifmedia_upd_locked() to use in driver initialization and add missing driver lock for both ti_ifmedia_upd() and ti_ifmedia_sts(). r227094: Don't clear upper 4bits from VLAN tag information. It's responsibility of vlan(4) to extract VLAN id from the tag information and vlan(4) correctly handles it. r227095: Don't abuse if_hwassist and make sure enabling corresponding TX/RX checksum offloading and VLAN hardware tag insertion/stripping from the currently enabled hardware offloading capabilities. Previously if_hwassist, which was initialized to TX/RX checksum offloading, was blindly used to enable both TX and RX checksum offloading such that disabling either TX or RX checksum offloading was not possible. ti(4) controllers support TX/RX checksum offloading with VLAN tagging so announce TX/RX checksum offloading capability over VLAN to vlan(4). Make VLAN hardware tag insertion/stripping honors currently enabled interface capability instead of blindly enabling VLAN hardware tagging. This change allows disabling hardware support of VLAN tag. Because ti(4) supports VLAN oversized frames, make network stack know the capability by setting if_hdrlen. While I'm here, rewrite SIOCSIFCAP handler and make sure to reinitialize controller whenever TX/RX checksum offloading and VLAN hardware tagging option is changed. The requirement of controller reinitialization comes from the limitation of Tigon I/II firmware. Tigon I/II firmware requires all related RCBs should be reinitialized whenever any of its hardware offloading capabilities change. vlan(4) is also notified whenever the parent interface's capability changes such that it can correctly handle TX/RX checksum offloading based on parent interface's enabled offloading capabilities. RX checksum offloading handler was changed to make upper stack use controller computed partial checksum value. Previously, ti(4) just set the computed value for any frames(IPv4, IPv6) and the value was not used in upper stack because driver didn't set CSUM_DATA_VALID such that upper network stack had to recompute checksum of TCP/UDP packets. I have no idea how this was not noticed for a long time. With this change, upper network stack does not have to fully recompute the checksum such that calculating pseudo checksum based on partial checksum is sufficient to know whether received packet's checksum is correct or not. However, I don't know why ti(4) does not have controller compute pseudo checksum as controller has ability to do it. I'm just guessing enabling that feature could trigger a firmware bug or could be slower than computing it on host side so just leave it as it was. In order not to produce false positives, ti(4) now checks whether controller actually computed IP or TCP/UDP checksum by checking ti_flags field. r227098: Because ti(4) drops a driver lock in RX handler, check whether driver is still running before re-enabling interrupts. r227099: Implement altq(4) support. While I'm here fix a logic error in r227098 where it didn't re-enable interrupts when TX queue is empty. END K 10 svn:author V 3 jhb K 8 svn:date V 27 2012-01-03T20:34:52.844303Z K 7 svn:log V 766 When cancelling multicast timers on an interface, don't release the reference on a group in the leaving state while iterating over the loop. Instead, use the same approach used in igmp_ifdetach() and mld_ifdetach() of placing the groups to free on pending release list and then releasing the references after dropping the IF_ADDR_LOCK. This closes an ugly race where the code was dropping the lock in the middle of iterating over the list. It also fixes some additional potential use-after-free bugs since the cancellation routine also applied other changes to the group after dropping the reference. Now those changes are performed before the reference is dropped and the group is potentially freed. Prodded to fix by: glebius Reviewed by: bz MFC after: 1 week END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T20:48:28.120332Z K 7 svn:log V 1187 MFC r227311-227312,227318-227319,227322-227324: r227311: Remove ti_unit member variable in softc. While I'm here use PCIR_BAR macro. r227312: o Remove unnecessary controller reinitialization. o Do not blindly UP controller when MTU is changed. Reinitialize controller only if driver is running. o Remove useless ti_stop() in ti_watchdog() since ti_init_locked() always invokes ti_stop(). r227318: Track which ring was updated in RX handler and update only modified ring. This should reduce unnecessary register accesses. r227319: Mini ring is not available on Tigon 1 so do not create DMA maps for mini ring on Tigon 1 to save resources. r227322: Show RX buffer allocation failure and do not blindly send alive message to firmware. Probably the correct way for this error is to send a TI_CMD_CODE_STACK_DOWN message to firmware and let firmware handle the rest. r227323: If ti_chipinit() fails in ti_stop(), ignore the error and release all allocated TX/RX buffer resources. If the interface is brought to up again after the error, we will leak allocated TX/RX buffers. r227324: Do not allow changing MTU to be less than the minimum. END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T20:50:48.394851Z K 7 svn:log V 1187 MFC r227311-227312,227318-227319,227322-227324: r227311: Remove ti_unit member variable in softc. While I'm here use PCIR_BAR macro. r227312: o Remove unnecessary controller reinitialization. o Do not blindly UP controller when MTU is changed. Reinitialize controller only if driver is running. o Remove useless ti_stop() in ti_watchdog() since ti_init_locked() always invokes ti_stop(). r227318: Track which ring was updated in RX handler and update only modified ring. This should reduce unnecessary register accesses. r227319: Mini ring is not available on Tigon 1 so do not create DMA maps for mini ring on Tigon 1 to save resources. r227322: Show RX buffer allocation failure and do not blindly send alive message to firmware. Probably the correct way for this error is to send a TI_CMD_CODE_STACK_DOWN message to firmware and let firmware handle the rest. r227323: If ti_chipinit() fails in ti_stop(), ignore the error and release all allocated TX/RX buffer resources. If the interface is brought to up again after the error, we will leak allocated TX/RX buffers. r227324: Do not allow changing MTU to be less than the minimum. END K 10 svn:author V 3 dim K 8 svn:date V 27 2012-01-03T20:51:26.238804Z K 7 svn:log V 201 In sys/dev/qlxgb/qla_misc.c, fix a copy/paste issue. Clang complained the variable 'val' was uninitialized when used. Instead, 'sig' should have been printed. Reviewed by: davidcs MFC after: 1 week END K 10 svn:author V 7 yongari K 8 svn:date V 27 2012-01-03T20:52:05.901041Z K 7 svn:log V 1187 MFC r227311-227312,227318-227319,227322-227324: r227311: Remove ti_unit member variable in softc. While I'm here use PCIR_BAR macro. r227312: o Remove unnecessary controller reinitialization. o Do not blindly UP controller when MTU is changed. Reinitialize controller only if driver is running. o Remove useless ti_stop() in ti_watchdog() since ti_init_locked() always invokes ti_stop(). r227318: Track which ring was updated in RX handler and update only modified ring. This should reduce unnecessary register accesses. r227319: Mini ring is not available on Tigon 1 so do not create DMA maps for mini ring on Tigon 1 to save resources. r227322: Show RX buffer allocation failure and do not blindly send alive message to firmware. Probably the correct way for this error is to send a TI_CMD_CODE_STACK_DOWN message to firmware and let firmware handle the rest. r227323: If ti_chipinit() fails in ti_stop(), ignore the error and release all allocated TX/RX buffer resources. If the interface is brought to up again after the error, we will leak allocated TX/RX buffers. r227324: Do not allow changing MTU to be less than the minimum. END K 10 svn:author V 3 dim K 8 svn:date V 27 2012-01-03T20:53:07.267211Z K 7 svn:log V 254 In sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c, check the the number of links against LINK_MAX (which is INT16_MAX), not against UINT32_MAX. Otherwise, the constant would implicitly be converted to -1. Reviewed by: pjd MFC after: 1 week END K 10 svn:author V 7 trociny K 8 svn:date V 27 2012-01-03T20:53:16.261214Z K 7 svn:log V 74 MFC r228411: Include sys/queue.h: snmpmod.h uses TAILQ. PR: bin/153153 END K 10 svn:author V 3 jhb K 8 svn:date V 27 2012-01-03T20:53:58.684233Z K 7 svn:log V 482 Fix a few bugs in the SRAT parsing code: - Actually increment ndomain when building our list of known domains so that we can properly renumber them to be 0-based and dense. - If the number of domains exceeds the configured maximum (VM_NDOMAIN), bail out of processing the SRAT and disable NUMA rather than hitting an obscure panic later. - Don't bother parsing the SRAT at all if VM_NDOMAIN is set to 1 to disable NUMA (the default). Reported by: phk (2) MFC after: 1 week END