293896 |
14-Jan-2016 |
glebius |
o Fix invalid TCP checksums with pf(4). [EN-16:02.pf] o Fix YP/NIS client library critical bug. [EN-16:03.yplib] o Fix SCTP ICMPv6 error message vulnerability. [SA-16:01.sctp] o Fix ntp panic threshold bypass vulnerability. [SA-16:02.ntp] o Fix Linux compatibility layer incorrect futex handling. [SA-16:03.linux] o Fix Linux compatibility layer setgroups(2) system call. [SA-16:04.linux] o Fix TCP MD5 signature denial of service. [SA-16:05.tcp] o Fix insecure default bsnmpd.conf permissions. [SA-16:06.bsnmpd]
Errata: FreeBSD-EN-16:02.pf Errata: FreeBSD-EN-16:03.yplib Security: FreeBSD-SA-16:01.sctp, CVE-2016-1879 Security: FreeBSD-SA-16:02.ntp, CVE-2015-5300 Security: FreeBSD-SA-16:03.linux, CVE-2016-1880 Security: FreeBSD-SA-16:04.linux, CVE-2016-1881 Security: FreeBSD-SA-16:05.tcp, CVE-2016-1882 Security: FreeBSD-SA-16:06.bsnmpd, CVE-2015-5677 Approved by: so |
267655 |
20-Jun-2014 |
gjb |
Remove svn:mergeinfo carried over from stable/9.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation |
267654 |
20-Jun-2014 |
gjb |
Copy stable/9 to releng/9.3 as part of the 9.3-RELEASE cycle.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation
|
266398 |
18-May-2014 |
jhb |
MFC 260377: When pf_get_translation() fails, it should leave *sn pointer pristine, otherwise we will panic in pf_test_rule().
PR: amd64/189741 Tested by: Nick Rogers <ncrogers@gmail.com>
|
263170 |
14-Mar-2014 |
dumbbell |
MFC Radeon KMS driver
FreeBSD 9 already had modern Intel GPUs support, now this is the case for Radeon GPUs too. This will ease the work on ports, where there won't be a need to distinguish between FreeBSD 9/10 and different hardware vendors.
Help from: jhb@, jkim@, kan@, kib@, J.R. Oldroyd <fbsd@opal.com> (previous version of the patch)
The following revisions were merged in this single commit:
r254885: drm/radeon: Import the Radeon KMS driver
This driver is based on Linux 3.8 and a previous effort by kan@.
More informations about this project can be found on the FreeBSD wiki: https://wiki.freebsd.org/AMD_GPU
The driver is split into:
sys/dev/drm2: The driver sources.
sys/modules/drm2/radeonkmw: The driver main kernel module's Makefile.
sys/modules/drm2/radeonkmsfw: All firmware kernel module Makefiles. There's one directory and one Makefile for each firmware.
sys/contrib/dev/drm2/radeonkmsfw: All firmware binary sources.
tools/tools/drm/radeon Tools to update firmwares or regenerate some headers.
Merging the driver to FreeBSD 9.x may be possible but not a priority for now.
Help from: kib@, kan@ Tested by: avg@, kwm@, ray@, Alexander Yerenkow <yerenkow@gmail.com>, Anders Bolt-Evensen <andersbo87@me.com>, Denis Djubajlo <stdedjub@googlemail.com>, J.R. Oldroyd <fbsd@opal.com>, Mikaël Urankar <mikael.urankar@gmail.com>, Pierre-Emmanuel Pédron <pepcitron@gmail.com>, Sam Fourman Jr. <sfourman@gmail.com>, Wade <wade-is-great@live.com>, (probably other I forgot...) HW donations: kyzh, Yakaz
r254894: drm/radeon: Rename the (S)DEBUG macros in atom.c to avoid conflicts
For instance, DEBUG is already defined in the LINT kernel configuration. This fixes the build of LINT.
r254899: drm/radeon: Disable build on i386/pc98
r255572: drm/radeon: Fix usage of vga_pci_map_bios()
vga_pci_(un)map_bios() takes a vgapci device as argument, not a drmn one. This fixes a bug where the BIOS couldn't be mapped if the device wasn't the boot display.
Approved by: re (kib; blanket for following drm2/radeon commits)
r255573: drm/radeon: Fix usage of pci_save_state() and pci_restore_state()
Calling those functions with the drmn device as argument causes a panic, because it's not a direct child of pci$N. They must be called with the vgapci device instead.
This fix is not enough to make suspend/resume work reliably.
Approved by: re (blanket)
r255587: drm/radeon: Add missing "return false" after unmapping invalid BIOS
Without that, we would try to copy the unmapped BIOS.
Submitted by: Christoph Mallon <christoph.mallon@gmx.de> Approved by: re (blanket)
r256771: drm/radeon: radeonkms depends on firmware(9)
Submitted by: tijl@
r257869: drm: Initialize "handle" to 0 before calling drm_gem_handle_create()
This is variable is being checked in drm_gem_name_create() before being set.
r257870: drm/radeon: Wake up userland after page flip
For instance, this caused issues in KDE, such as stuttered animations (with desktop effects enabled).
r259003: Initialize modesetting sysctls in radeonkms.
This is intended for MFC if re@ permits.
Reviewed by: kib, dumbbell Tested by: Steven Chamberlain <steven@pyro.eu.org> MFC after: 3 days
r259101: drm/radeon: agp_info->ai_aperture_size is in bytes, not Mbytes
This fixes radeon_agp_init() and gtt_size is now correct. However, this is not enough to make Radeon AGP cards work: ttm_agp_backend.c isn't implemented yet.
Submitted by: tijl@
r259104: drm/radeon: radeon_dp_i2c_aux_ch() must return 0 on FreeBSD
The code was unmodified compared to Linux and returned the amount of received bytes from the i2c bus. This led to non-working i2c bus and failure to eg. read monitor's EDID, if connected to DisplayPort.
MFC after: 3 days Tested by: Mikaël Urankar <mikael.urankar@gmail.com>
r259684: drm/ttm, drm/radeon: Replace EINTR/ERESTART by ERESTARTSYS...
... for msleep/cv_*wait() return values, where wait_event*() is used on Linux. ERESTARTSYS is the return code expected by callers when the operation was interrupted.
For instance, this is the case of radeon_cs_ioctl() (radeon_cs.c): if an error occurs, and the code isn't ERESTARTSYS (eg. EINTR), it logs an error.
Note that ERESTARTSYS is defined as ERESTART, but this keeps callers' code close to Linux.
Submitted by: avg@ (previous version)
r261497: Abort when firmware isn't present in R600+ models.
More details at: http://anonscm.debian.org/viewvc/kernel/dists/trunk/linux/debian/patches/bugfix/all/radeon-firmware-is-required-for-drm-and-kms-on-r600-onward.patch?revision=20909&view=co
Reviewed by: dumbbell MFC after: 1 week
|
260119 |
31-Dec-2013 |
kevlo |
MFC r256717:
Update firmware for run(4) to version 0.33.
|
259485 |
16-Dec-2013 |
andreast |
Fix the outstanding mergeinfo part of r249374.
|
256882 |
22-Oct-2013 |
glebius |
Merge r255143 from head: Merge 1.12 of pf_lb.c from OpenBSD, with some changes. Original commit:
date: 2010/02/04 14:10:12; author: sthen; state: Exp; lines: +24 -19; pf_get_sport() picks a random port from the port range specified in a nat rule. It should check to see if it's in-use (i.e. matches an existing PF state), if it is, it cycles sequentially through other ports until it finds a free one. However the check was being done with the state keys the wrong way round so it was never actually finding the state to be in-use.
- switch the keys to correct this, avoiding random state collisions with nat. Fixes PR 6300 and problems reported by robert@ and viq.
- check pf_get_sport() return code in pf_test(); if port allocation fails the packet should be dropped rather than sent out untranslated.
Help/ok claudio@.
Some additional changes to 1.12:
- We also need to bzero() the key to zero padding, otherwise key won't match. - Collapse two if blocks into one with ||, since both conditions lead to the same processing. - Only naddr changes in the cycle, so move initialization of other fields above the cycle. - s/u_intXX_t/uintXX_t/g
PR: kern/181690 Submitted by: Olivier Cochard-Labbé <olivier cochard.me> Sponsored by: Nginx, Inc.
|
252778 |
05-Jul-2013 |
achim |
MFC r250963, r251013, r251056: Driver 'aacraid' added to support Adaptec by PMC RAID controller families Series 6, 7, 8 and upcoming products.
Approved by: emaste (co-mentor)
|
252555 |
03-Jul-2013 |
np |
MFC/backport core kernel and userspace parts of r237263 (TCP_OFFLOAD rework). MFC r237563, r239511, r243603, r245915, r245916, r245919, r245921, r245922, r245924, r245925, r245932, r245934 too.
Build tested with make universe.
r237263: - Updated TOE support in the kernel. ...
r237563: Fix clang warning when compiling iw_cxgb.
r239511: Correctly handle the case where an inp has already been dropped by the time the TOE driver reports that an active open failed. toe_connect_failed is supposed to handle this but it should be provided the inpcb instead of the tcpcb which may no longer be around.
r243603: Make sure that tcp_timer_activate() correctly sees TCP_OFFLOAD (or not).
r245915: Heed SO_NO_OFFLOAD.
r245916: Teach toe_4tuple_check() to deal with IPv6 4-tuples too.
r245919: Add TCP_OFFLOAD hook in syncache_respond for IPv6 too, just like the one that exists for IPv4.
r245921: There is no need to call into the TOE driver twice in pru_rcvd (tod_rcvd and then tod_output right after that).
r245922: Avoid NULL dereference in nd6_storelladdr when no mbuf is provided. It is called this way from a couple of places in the OFED code. (toecore calls it too but that's going to change shortly).
r245924: Move lle_event to if_llatbl.h
lle_event replaced arp_update_event after the ARP rewrite and ended up in if_ether.h simply because arp_update_event used to be there too. IPv6 neighbor discovery is going to grow lle_event support and this is a good time to move it to if_llatbl.h.
The two in-tree consumers of this event - OFED and toecore - are not affected.
r245925: Generate lle_event in the IPv6 neighbor discovery code too.
r245932: Teach toe_l2_resolve to resolve IPv6 destinations too.
r245934: Add checks for SO_NO_OFFLOAD in a couple of places that I missed earlier in r245915.
|
250248 |
04-May-2013 |
mdf |
MFC r248933:
Use a shared lock for VOP_GETEXTATTR, as it is a read-like operation.
|
250111 |
30-Apr-2013 |
gnn |
Improve error handling when unwrapping received data.
Submitted by: Rick Macklem
|
248665 |
23-Mar-2013 |
mckusick |
MFC of 246876 and 246877
MFC: 246876:
Add barrier write capability to the VFS buffer interface. A barrier write is a disk write request that tells the disk that the buffer being written must be committed to the media along with any writes that preceeded it before any future blocks may be written to the drive.
Barrier writes are provided by adding the functions bbarrierwrite (bwrite with barrier) and babarrierwrite (bawrite with barrier).
Following a bbarrierwrite the client knows that the requested buffer is on the media. It does not ensure that buffers written before that buffer are on the media. It only ensure that buffers written before that buffer will get to the media before any buffers written after that buffer. A flush command must be sent to the disk to ensure that all earlier written buffers are on the media.
Reviewed by: kib Tested by: Peter Holm
MFC 246877:
The UFS2 filesystem allocates new blocks of inodes as they are needed. When a cylinder group runs short of inodes, a new block for inodes is allocated, zero'ed, and written to the disk. The zero'ed inodes must be on the disk before the cylinder group can be updated to claim them. If the cylinder group claiming the new inodes were written before the zero'ed block of inodes, the system could crash with the filesystem in an unrecoverable state.
Rather than adding a soft updates dependency to ensure that the new inode block is written before it is claimed by the cylinder group map, we just do a barrier write of the zero'ed inode block to ensure that it will get written before the updated cylinder group map can be written. This change should only slow down bulk loading of newly created filesystems since that is the primary time that new inode blocks need to be created.
Reported by: Robert Watson Reviewed by: kib Tested by: Peter Holm
|
248626 |
22-Mar-2013 |
mckusick |
MFS of 246289:
For UFS2 i_blocks is unsigned. The current "sanity" check that it has gone below zero after the blocks in its inode are freed is a no-op which the compiler fails to warn about because of the use of the DIP macro. Change the sanity check to compare the number of blocks being freed against the value i_blocks. If the number of blocks being freed exceeds i_blocks, just set i_blocks to zero.
Reported by: Pedro Giffuni (pfg@)
|
247111 |
21-Feb-2013 |
mav |
MFC r230590 (by ken) except parts changing ABI: Add CAM infrastructure to allow reporting when a drive's long read capacity data changes.
|
245258 |
10-Jan-2013 |
ae |
MFC r244750: Add net.link.stf.permit_rfc1918 sysctl variable. It can be used to allow the use of private IPv4 addresses with stf(4).
MFC r244752: Add an ability to set net.link.stf.permit_rfc1918 from the loader.
|
244999 |
03-Jan-2013 |
gnn |
MFC: 234930
Fix so that ,usr and ,os work correctly with fixed function (IAF) counters.
|
243989 |
07-Dec-2012 |
gnn |
MFC: 238366, 240924
Initial commit of an I/O provider for DTrace on FreeBSD.
These probes are most useful when looking into the structures they provide, which are listed in io.d. For example:
dtrace -n 'io:kernel::start { printf("%d\n", args[0]->bio_bcount); }'
Note that the I/O systems in FreeBSD and Solaris/Illumos are sufficiently different that there is not a 1:1 mapping from scripts that work with one to the other.
This commit includes the fix so that our probes use "kernel" instead of the Solaris specific "genunix"
|
243401 |
22-Nov-2012 |
glebius |
Partially merge r240494, which moved netinet/ipfw to netpfil/ipfw, to make it easier to merge ipfw commits back to stable/9.
|
242838 |
09-Nov-2012 |
dim |
MFC r242623:
In sys/contrib/ngatm/netnatm/msg/uni_ie.c, fix a few warnings from newer versions of clang 3.2, about comparing enum uni_cause values against integer constants which fall outside the enum range. No functional change.
|
241681 |
18-Oct-2012 |
marius |
MFC: r239864
- Unlike cache invalidation and TLB demapping IPIs, reading registers from other CPUs doesn't require locking so get rid of it. As the latter is used for the timecounter on certain machine models, using a spin lock in this case can lead to a deadlock with the upcoming callout(9) rework. - Merge r134227/r167250 from x86: Avoid cross-IPI SMP deadlock by using the smp_ipi_mtx spin lock not only for smp_rendezvous_cpus() but also for the MD cache invalidation and TLB demapping IPIs. - Mark some unused function arguments as such.
|
241222 |
05-Oct-2012 |
jh |
MFC r239257:
Reserve room for the terminating NUL when setting or getting kernel environment variables. KENV_MNAMELEN and KENV_MVALLEN doesn't include space for the terminating NUL.
|
241194 |
04-Oct-2012 |
rmacklem |
MFC: r240720 Modify the NFSv4 client so that it can handle owner and owner_group strings that consist entirely of digits, interpreting them as the uid/gid number. This change was needed since new (>= 3.3) Linux servers reply with these strings by default. This change is mandated by the rfc3530bis draft. Reported on freebsd-stable@ under the Subject heading "Problem with Linux >= 3.3 as NFSv4 server" by Norbert Aschendorff on Aug. 20, 2012.
|
241192 |
04-Oct-2012 |
fjoe |
MFC: r241002
Fix pseudo checksum calculation.
This fixes ipfilter w/ network controllers that implement only partial rx csum offloading.
PR: 106438 Obtained from: upstream
|
241112 |
01-Oct-2012 |
jhb |
MFC 239779: Shorten the name of the fast SWI taskqueue to "fast taskq" so that it fits.
|
241110 |
01-Oct-2012 |
jhb |
MFC 239008,239020: Improve the handling of static DMA buffers that use non-default memory attributes (currently just BUS_DMA_NOCACHE): - Don't call pmap_change_attr() on the returned address, instead use kmem_alloc_contig() to ask the VM system for memory with the requested attribute. - As a result, always use kmem_alloc_contig() for non-default memory attributes, even for sub-page allocations. This requires adjusting bus_dmamem_free()'s logic for determining which free routine to use. - For x86, add a new dummy bus_dmamap that is used for static DMA buffers allocated via kmem_alloc_contig(). bus_dmamem_free() can then use the map pointer to determine which free routine to use. - For powerpc, add a new flag to the allocated map (bus_dmamem_alloc() always creates a real map on powerpc) to indicate which free routine should be used.
Note that the BUS_DMA_NOCACHE handling in powerpc is currently #ifdef'd out. I have left it disabled but updated it to match x86.
|
241109 |
01-Oct-2012 |
jhb |
MFC 239771: Fix misspelled "Infiniband".
|
240977 |
26-Sep-2012 |
rmacklem |
MFC: r240289 Add a simple printf() based debug facility to the new nfs client. Use it for a printf() that can be harmlessly generated for mmap()'d files. It will be used extensively for the NFSv4.1 client. Debugging printf()s are enabled by setting vfs.nfs.debuglevel to a non-zero value. The higher the value, the more debugging printf()s.
|
240217 |
07-Sep-2012 |
thomas |
Merge rev. 239673 from head to stable/9: (g_multipath_rotate): Fix algorithm so that it does rotate over all good providers, not just the last two.
|
240159 |
06-Sep-2012 |
thomas |
MFC: merge rev. 239012 from head to stable/9 New command "gmultipath prefer" to force selection of a specified provider in an Active/Passive configuration.
|
239920 |
30-Aug-2012 |
jhb |
MFC 239128: Don't try to stop the IPMI watchdog timer if it is not running. Starting or stopping the IPMI watchdog is rather expensive with the current implementation as all IPMI requests are bounced via thread. This is not viable during shutdown or dumps, and this avoids headache in the common case that the watchdog is not enabled. The IPMI watchdog should probably be reworked to not use a separate thread to fix this in the case when the watchdog timer is enabled.
|
239917 |
30-Aug-2012 |
jhb |
MFC 239103: Explicitly enable busmastering on PCI-PCI bridges. Transactions initiated on the secondary side of a bridge will not be propagated to the primary bus unless this is enabled. Busmastering is not enabled by default (we have relied on firmware to set this bit to date). The OS needs to set it for any bridges not configured by system firmware.
|
239915 |
30-Aug-2012 |
jhb |
MFC 238424: Make the interval timings for EVFILT_TIMER more accurate. tvtohz() always adds an extra tick to account for the current partial clock tick. However, that is not appropriate for a repeating timer when the exact tvtohz() value should be used for subsequent intervals. Fix repeating callouts for EVFILT_TIMER by subtracting 1 tick from the tvtohz() result similar to the fix used in realitexpire() for interval timers.
While here, update a few comments to note that if the EVFILT_TIMER code were to move out of kern_event.c, it should move to kern_time.c (where the interval timer code it mimics lives) rather than kern_timeout.c.
|
239914 |
30-Aug-2012 |
jhb |
MFC 238311: Add a clts() wrapper around the 'clts' instruction to <machine/cpufunc.h> on x86 and use that to implement stop_emulating() in the fpu/npx code. Reimplement start_emulating() in the non-XEN case by using load_cr0() and rcr0() instead of the 'lmsw' and 'smsw' instructions. Intel explicitly discourages the use of 'lmsw' and 'smsw' on 80386 and later processors in the description of these instructions in Volume 2 of the ADM.
|
239882 |
29-Aug-2012 |
jhb |
MFC 238142,238179: Now that our assembler supports the xsave family of instructions, use them natively rather than hand-assembled versions. For xgetbv/xsetbv, add a wrapper API to deal with xcr* registers: rxcr() and load_xcr().
|
239880 |
29-Aug-2012 |
jhb |
MFC 238310: Partially revert r217515 so that the mem_range_softc variable is always present on x86 kernels. This fixes the build of kernels that include 'device acpi' but do not include 'device mem'.
|
239879 |
29-Aug-2012 |
jhb |
MFC 238109,238166: Several fixes to the amd64 disassembler: - Decode the 'xsave', 'xrstor', 'xsaveopt', 'xgetbv', 'xsetbv', and 'rdtscp' instructions. - Add generic support for opcodes that are escape bytes used for multi-byte opcodes (such as the 0x0f prefix). Use this to replace the hard-coded 0x0f special case and add support for three-byte opcodes that use the 0x0f38 prefix. - Decode all Intel VMX instructions. invept and invvpid in particular are three-byte opcodes that use the 0x0f38 escape prefix. - Rework how the special 'SDEP' size flag works such that the default instruction name (i_name) is the instruction when the data size prefix (0x66) is not specified, and the alternate name in i_extra is used when the prefix is included. - Add a new 'ADEP' size flag similar to 'SDEP' except that it chooses between i_name and i_extra based on the address size prefix (0x67). Use this to fix the decoding for jrcxz vs jecxz which is determined by the address size prefix, not the operand size prefix. Also, jcxz is not possible in 64-bit mode, but jrcxz is the default instruction for that opcode. - Add support for handling instructions that have a mandatory 'rep' prefix (this means not outputting the 'repe ' prefix until determining if it is used as part of an opcode). Make 'pause' less of a special case this way. - Decode 'cmpxchg16b' and 'cdqe' which are variants of other instructions but with a REX.W prefix.
|
239874 |
29-Aug-2012 |
jhb |
MFC 238000,239584: Honor db_pager_quit in 'show malloc', 'show uma', and 'show witness'.
|
239866 |
29-Aug-2012 |
jhb |
MFC 238077: Fix panics triggered by older mfiutil binaries run on the new mfi(4) driver. The new driver changed the size of the mfi_dcmd_frame structure in such a way that a MFI_IOC_PASSTHRU ioctl from an old amd64 binary is treated as an MFI_IOC_PASSTHRU32 ioctl in the new driver. As a result, the user pointer is treated as the buffer length. mfi_user_command() doesn't have a bounds check on the buffer length, so it passes a really big value to malloc() which panics when it tries to exhaust the kmem_map. Fix this two ways: - Only honor MFI_IOC_PASSTHRU32 if the binary has the SV_ILP32 flag set, otherwise treat it as an unknown ioctl. - Add a bounds check on the buffer length passed by the user. For now it fails any user attempts to use a buffer larger than 1MB.
While here, fix a few other nits: - Remove an unnecessary check for a NULL return from malloc(M_WAITOK). - Use the ENOTTY errno for invalid ioctl commands instead of ENOENT.
|
239821 |
29-Aug-2012 |
jhb |
MFC 237338: Don't return an error if a kld does not contain any modules (e.g. a kld that only contained a sysctl). The kernel linker allows such modules, so the boot loader should not reject them.
|
239787 |
28-Aug-2012 |
jhb |
MFC 230782,237274: Refine the implementation of POSIX_FADV_NOREUSE to perform POSIX_FADV_DONTNEED requests on the currently accessed portion of the file on each read(2) or write(2) rather than using direct I/O. This gives much better performance including read-ahead and write clustering similar to normal read(2) and write(2) calls.
If subsequent read(2) and write(2) calls are sequential, then the POSIX_FADV_DONTNEED requests will cover the entire sequentially-accessed range.
|
239748 |
27-Aug-2012 |
jhb |
MFC 233040,233198,233870,234183: Add OFED and the associated options and drivers to x86 LINT builds: - Fix build with INET6 disabled. - Fix build of OFED bits with debugging options enabled. - Fix build on i386. - Mark 'sdp' as requiring 'inet'. - Always include "opt_inet.h" and "opt_inet6.h" and modify the IB driver Makefiles to honor WITH/WITHOUT_INET/INET6/_SUPPORT options to determine what should be enabled during a module build. - Fix the mlxen(4) driver and the core IB code to compile without if INET is disabled (including when both INET and INET6 are disabled).
|
239662 |
24-Aug-2012 |
jhb |
MFC 233872: Add descriptions after the 'device' line for several NICs to match the existing style.
|
239565 |
22-Aug-2012 |
mdf |
MFC r238502:
Fix a bug with memguard(9) on 32-bit architectures without a VM_KMEM_MAX_SIZE.
The code was not taking into account the size of the kernel_map, which the kmem_map is allocated from, so it could produce a sub-map size too large to fit. The simplest solution is to ignore VM_KMEM_MAX entirely and base the memguard map's size off the kernel_map's size, since this is always relevant and always smaller.
Found by: Justin Hibbits
|
239483 |
21-Aug-2012 |
marius |
MFC: r239079
Merge r236494 from x86:
Isolate the global TTE list lock from data and other locks to prevent false sharing within the cache.
|
238916 |
30-Jul-2012 |
jhb |
MFC 238164: Add another PS/2 keyboard PNP ID. This ID is listed as "Reserved by Microsoft" in the standard PNP ID table, but has been seen in the wild on at least one laptop.
Approved by: re (kib)
|
238904 |
30-Jul-2012 |
marius |
Pull the tier-2 card and change the sparc64 ZFS loader to no longer probe all diskN aliases for providers (which more or less corresponds to how the x86 version behaves) but instead probe only those listed in the boot-device OFW environment variable. This has the following advantages: - avoids otherwise unavoidable OFW warnings about failures to open disks for which aliases exist but no actual hardware is connected - avoids issues due to different diskN naming schemes - aligns us with Solaris
Approved by: re (kib)
|
238689 |
22-Jul-2012 |
marius |
MFC: r238621
Revert the use of BUS_DMA_ALLOCNOW when creating the DMA tag for user data introduced in r236061 (MFC'ed to stable/9 in r237186). Using that flag doesn't make that much sense on this case as the DMA maps using it are also created during sym_pci_attach(). Moreover, due to the maxsegsz parameter used, doing so may exhaust the bounce pages pool on architectures requiring bounce pages. [1] While at it, use a slightly more appropriate maxsegsz parameter.
PR: 169526 Submitted by: Mike Watters [1] Approved by: re (kib)
|
238600 |
18-Jul-2012 |
glebius |
Merge r230119, r238498 from head:
------------------------------------------------------------------------ r230119 | csjp | 2012-01-15 02:51:34 +0400 (вс, 15 янв 2012) | 9 lines
Revert to the old behavior of allocating table/table entries using M_NOWAIT. Currently, the code allows for sleeping in the ioctl path to guarantee allocation. However code also handles ENOMEM gracefully, so propagate this error back to user-space, rather than sleeping while holding the global pf mutex.
Reviewed by: glebius Discussed with: bz
------------------------------------------------------------------------ r238498 | glebius | 2012-07-15 23:10:00 +0400 (вс, 15 июл 2012) | 2 lines
Use M_NOWAIT while holding the pf giant lock.
Approved by: re (kib)
|
238047 |
03-Jul-2012 |
thompsa |
MFC r237852
Add the same check as vlan(4) where we ignore the ifnet departure event if the interface is just being renamed.
PR: kern/169557
|
238017 |
02-Jul-2012 |
marius |
MFC: r237547
Fix size of the bcopy when extracting ethernet address
Obtained from: DragonFly
|
238013 |
02-Jul-2012 |
marius |
MFC: r237546
Correct sizeof usage
Obtained from: DragonFly
|
238012 |
02-Jul-2012 |
marius |
MFC: r237842
Switch back to the 4BSD scheduler for now. There is some more or less recent regression with ULE, causing processes to get stuck in getblk as well as interrupt handler execution delays to rise above the command timeout of mpt(4).
|
237995 |
02-Jul-2012 |
bms |
Merge r237736 from HEAD: Kick the current-state report timer when a V1 group report would be triggered.
Submitted by: rpaulo@
|
237992 |
02-Jul-2012 |
bms |
Merge r237735 from HEAD: Fix a typo in MLD query exponent processing.
Submitted by: rpaulo@
|
237990 |
02-Jul-2012 |
bms |
Merge r237734 from HEAD: In MLDv2 general query processing, do not enforce the strict check on query origins.
Submitted by: Gu Yong
|
237839 |
30-Jun-2012 |
avg |
MFC r236503: free wdog_kern_pat calls in post-panic paths from under SW_WATCHDOG
|
237822 |
29-Jun-2012 |
jhb |
MFC 235024,235029,235556,235834,235845: Use MADT to match ACPI Processor objects to CPUs. MADT and DSDT/SSDTs may list CPUs in different orders, especially for disabled logical cores. Now we match ACPI IDs from the MADT with Processor objects, strictly order CPUs accordingly, and ignore disabled cores. This prevents us from executing methods for other CPUs, e. g., _PSS for disabled logical core, which may not exist. Unfortunately, it is known that there are a few systems with buggy BIOSes that do not have unique ACPI IDs for MADT and Processor objects. To work around these problems, 'debug.acpi.cpu_unordered' tunable is added. Set this to a non-zero value to restore the old behavior.
|
237815 |
29-Jun-2012 |
marius |
MFC: r236581
The loaddev environment variable is not modifiable once set, so it is not update for ZFS. It seems that this does not really affect anything except the help command. Nevertheless, rearrange things so loaddev is set only once in all cases in order to get it right. Pointed out by: avg
|
237805 |
29-Jun-2012 |
jhb |
MFC 233191: Fix madvise(MADV_WILLNEED) to properly handle individual mappings larger than 4GB. Specifically, the inlined version of 'ptoa' of the the 'int' count of pages overflowed on 64-bit platforms. While here, change vm_object_madvise() to accept two vm_pindex_t parameters (start and end) rather than a (start, count) tuple to match other VM APIs as suggested by alc@.
|
237803 |
29-Jun-2012 |
jhb |
MFC 237334: Move the per-thread deferred user map entries list into a private list in vm_map_process_deferred() which is then iterated to release map entries. This avoids having a nested vm map unlock operation called from the loop body attempt to recuse into vm_map_process_deferred(). This can happen if the vm_map_remove() triggers the OOM killer.
|
237797 |
29-Jun-2012 |
jhb |
MFC 237008,237271,237272,237673: - Fix a couple of bugs that prevented windows in PCI-PCI bridges from growing "downward" (moving the start address down). First, an off by one error caused the end address to be moved down an extra alignment chunk unnecessarily. Second, when aligning the new candidate starting address, the wrong bits were masked off. - Add a 'wmask' variable to hold the expression '(1ul << w->step) - 1' in pcib_grow_window(). - For subtractively decoding bridges, don't try to grow windows but pass the request up the tree in order to be on the safe side. Growing windows in this case would mean to switch resources to positive decoding and it's unclear how to correctly handle this. At least with ALi/ULi M5249 PCI-PCI bridges, this also just doesn't work out of the box.
|
237776 |
29-Jun-2012 |
glebius |
Merge r236364 from head by eri@: Correct table counter functionality to not panic. This was caused by not proper initialization of necessary parameters.
PR: 168200 Reviewed by: bz@, glebius@ MFC after: 1 week
|
237771 |
29-Jun-2012 |
avg |
MFC r235390: zfs boot code: mark spa_t arguments as const where they are used as such
|
237770 |
29-Jun-2012 |
avg |
MFC r235392,235394,235395: fixes and cleanups for zfs boot MFC
|
237767 |
29-Jun-2012 |
avg |
MFC r235330: zfs boot: try to set vfs.root.mountfrom from currdev as a fallback
|
237766 |
29-Jun-2012 |
avg |
MFC r235329,235343,235361,235364: zfsboot/zfsloader: support accessing filesystems within a pool
|
237763 |
29-Jun-2012 |
avg |
MFC r235264: MFi386: improve argument passing via btxldr
|
237761 |
29-Jun-2012 |
avg |
MFC r235219: cdboot, pxeldr: make use of bootargs.h instead of redefining flag constants
|
237760 |
29-Jun-2012 |
avg |
MFC r235156: i386 zfsloader: rename LIBZFS to LIBZFSBOOT
|
237758 |
29-Jun-2012 |
avg |
MFC r235155: i386 boot: consolidate MAXBDDEV definition
|
237752 |
29-Jun-2012 |
avg |
MFC r235153: sys/boot: add common CTASSERT definition
|
237731 |
28-Jun-2012 |
jhb |
MFC 228161,230774,230822,236415: Add a new -e flag to pciconf(8)'s list mode to display PCI error details. Currently this dumps the status of any error bits in the PCI status register and PCI-express device status register. It also lists any errors indicated by version 1 of PCI-express Advanced Error Reporting (AER).
|
237727 |
28-Jun-2012 |
jhb |
MFC 236405: Remove unnecessary initializations. The BSS of boot2 is in fact zero'd when boot2 begins execution by the _start() routine in btxcsu.S.
|
237725 |
28-Jun-2012 |
jhb |
MFC 236404: Extend VERBOSE_SYSINIT to also print out the name of variables passed to SYSINIT routines if they can be resolved via symbol look up in DDB. To avoid false positives, only honor a name if the symbol resolves exactly to the pointer value (no offset).
|
237719 |
28-Jun-2012 |
jhb |
MFC 234494: Include the associated wait channel message for context switch ktrace records. kdump supports both the old and new messages.
|
237670 |
27-Jun-2012 |
thompsa |
MFC r236178
if_lagg: allow to invoke SIOCSLAGGPORT multiple times in a row
|
237669 |
27-Jun-2012 |
thompsa |
MFC r236062
Turn LACP debugging from a compile time option to a sysctl, it is very handy to be able to turn it on when negotiation to a switch misbehaves.
|
237663 |
27-Jun-2012 |
jhb |
MFC 233925,236357: Add new ktrace records for the start and end of VM faults. This gives a pair of records similar to syscall entry and return that a user can use to determine how long page faults take. The new ktrace records are enabled via the 'p' trace type, but are not enabled in the default set of trace points.
|
237543 |
25-Jun-2012 |
rmacklem |
MFC: r237244 Fix the NFSv4 client for the case where mmap'd files are written, but not msync'd by a process. A VOP_PUTPAGES() called when VOP_RECLAIM() happens will usually fail, since the NFSv4 Open has already been closed by VOP_INACTIVE(). Add a vm_object_page_clean() call to the NFSv4 client's VOP_INACTIVE(), so that the write happens before the NFSv4 Open is closed. kib@ suggested using vgone() instead and I will explore this, but this patch fixes things in the meantime. For some reason, the VOP_PUTPAGES() is still attaempted in VOP_RECLAIM(), but having this fail doesn't cause any problems except a "stateid0 in write" being logged.
|
237534 |
24-Jun-2012 |
rmacklem |
MFC: r237200 Move the nfsrpc_close() call in ncl_reclaim() for the NFSv4 client to below the vnode_destroy_vobject() call, since that is where writes are flushed.
|
237491 |
23-Jun-2012 |
marius |
MFC: r231616, r232497, r234337
Add __aeabi_read_tp function required for thread-local storage.
|
237444 |
22-Jun-2012 |
gnn |
MFC 230063 Clean up a switch statement for uncore events on Westmere processors.
Submitted by: Davide Italiano Reviewed by: gnn
|
237388 |
21-Jun-2012 |
marius |
MFC: r231617
Add ARM relocations types used for thread-local storage
Reviewed by: cognet
|
237386 |
21-Jun-2012 |
marius |
MFC: r235348, r236191, r236497
Add glue/support for the SAM9XE512-based Ethernut 5 boards. Currently, all integrated and on-board peripherals except NAND Flash (missing NAND framework/integration) are working.
|
237384 |
21-Jun-2012 |
marius |
MFC: r236496
- Loop up to 3 seconds when waiting for a device to get ready. [1] - Make the device description match the driver name. - Identify the chip variant based on the JEDEC and use that information to use the proper values for page count, offset and size instead of hardcoding a AT45DB642x with 2^N byte page support disabled. - Take advantage of bioq_takefirst(). - Given that CONTINUOUS_ARRAY_READ_HF (0x0b) command isn't even mentioned in Atmel's DataFlash Application Note, as suggested by the previous comment may not work on all all devices and actually doesn't properly on at least AT45DB321D (JEDEC 0x1f2701), rewrite at45d_task() to use CONTINUOUS_ARRAY_READ (0xe8) for reading instead. This rewrite is laid out in a way allowing to easily add support for BIO_DELETE later on. - Add support for reads and writes not starting on a page boundary. - Verify the flash content after writing. - Let at45d_task() gracefully handle errors on SPI transfers and the device not becoming ready afterwards again. [1] - Use DEVMETHOD_END. [1] - Use NULL instead of 0 for pointers. [1]
Additional testing by: Ian Lepore
Submitted by: Ian Lepore [1]
|
237382 |
21-Jun-2012 |
marius |
MFC: r237239
Revert the part of r236495 (MFC'ed to stable/9 in r237095) that introduced checking of SPI_SR_TXEMPTY for TX transfer completion as for reasons unknown this occasionally causes SPI_SR_RXBUFF and SPI_SR_ENDRX to not rise. In any case, once the RX part of the transfer is done it's obvious that the preceding TX part had finished and checking of SPI_SR_TXEMPTY was introduced to rule out a possible cause for the data corruption mentioned in r236495 but which didn't turn out to be the problem anyway.
|
237380 |
21-Jun-2012 |
marius |
MFC: r230242, r237102, r237236
- Add support for the FT2232 based egnite Turtelizer 2 JTAG/RS232 Adapter. This includes adding support for skipping FTDI interfaces used for JTAG leaving them for userland and just attaching to the RS232 half, similarly to how the corresponding Linux drivers handles these kind of adapters. While at it, sort uftdi_devs and return BUS_PROBE_SPECIFIC (because uftdi_probe() alters the instance variables for better or worse as do other probe routines of USB drivers) instead of 0. - Remove duplicated entries for BeagleBone. - Use DEVMETHOD_END. - Use NULL instead of 0 for pointers. - Remove some stray lines.
|
237352 |
21-Jun-2012 |
mckusick |
MFC of 236937
In softdep_setup_inomapdep() we may have to allocate both inodedep and bmsafemap dependency structures in inodedep_lookup() and bmsafemap_lookup() respectively. The setup of these structures must be done while holding the soft-dependency mutex. If the inodedep is allocated first, it may be freed in the I/O completion callback when the mutex is released to allocate the bmsafemap. If the bmsafemap is allocated first, it may be freed in the I/O completion callback when the mutex is released to allocate the inodedep.
To resolve this problem, bmsafemap_lookup has had a parameter added that allows a pre-malloc'ed bmsafemap to be passed in so that it does not need to release the mutex to create a new bmsafemap. The softdep_setup_inomapdep() routine pre-malloc's a bmsafemap dependency before acquiring the mutex and starting to build the inodedep with a call to inodedep_lookup(). The subsequent call to bmsafemap_lookup() is passed this pre-allocated bmsafemap entry so that it need not release the mutex if it needs to create a new one.
Reported by: Peter Holm Tested by: Peter Holm
|
237351 |
21-Jun-2012 |
mckusick |
MFC of 236825
When synchronously syncing a device (MNT_WAIT), wait for buffers to become available. Otherwise we may excessively spin and fail with ``fsync: giving up on dirty''.
Reviewed by: kib Tested by: Peter Holm
|
237343 |
20-Jun-2012 |
rnoland |
MFC r236246
Add device ids for the Winbond 83627DHG-P chip and set the registers to trigger the keyboard reset line on timeout.
|
237342 |
20-Jun-2012 |
rnoland |
MFC r236245
Fix a typo in wbwd so that CRF5 is actually written to the data register rather than the index register.
|
237191 |
17-Jun-2012 |
marius |
MFC: r237107
- As a baind-aid, disable ATAPI DMA when using ATA_CAM for these controllers as well as it causes the kernel to hang during boot. Reported and tested by: Kevin Oberman - Use NULL instead of 0 for a pointer.
|
237188 |
17-Jun-2012 |
marius |
MFC: r230179
BeagleBone uses an FTDI chip with an altered Product ID.
|
237186 |
17-Jun-2012 |
marius |
MFC: r237101
Fix a braino in r236469 (MFC'ed to stable/9 in r236468); the number of DMA tags required for handling MAXPHYS should be based on PAGE_SIZE rather than SYM_CONF_DMA_BOUNDARY. While at it, reuse the SYM_CONF_MAX_SG macro for specifying the maximum number of DMA tags so sym(4) itself doesn't size memory beyond what's required for handling MAXPHYS.
PR: 168928
|
237103 |
14-Jun-2012 |
thompsa |
MFC r236916
Fix a panic I introduced in r234487, the bridge softc pointer is set to null early in the detach so rearrange things not to explode.
Reported by: David Roffiaen, Gustau Perez Querol
|
237095 |
14-Jun-2012 |
marius |
MFC: r236495
- Prepend the device description with "AT91" to reflect its nature. [1] - Move DMA tag and map creature to at91_spi_activate() where the other resource allocation also lives. [1] - Flesh out at91_spi_deactivate(). [1] - Work around the "Software Reset must be Written Twice" erratum. - For now, run the bus at the slowest speed possible in order to work around data corruption on transit even seen with 9 MHz on ETHERNUT5 (15 MHz maximum) and AT45DB321D (20 MHz maximum). This also serves as a poor man's work-around for the "NPCSx rises if no data data is to be transmitted" erratum of RM9200. Being able to use the appropriate bus speed would require: 1) Adding a proper work-around for the RM9200 bug consisting of taking the chip select control away from the SPI peripheral and managing it directly as a GPIO line. 2) Taking the maximum frequencies supported by the actual board and the slave devices into account and basing the whole thing on the master clock instead of hardcoding a divisor as previously done. 3) Fixing the above mentioned data corruption. - KASSERT that TX/RX command and data sizes match on transfers. - Introduce a mutex ensuring that only one child device is running a SPI transfer at a time. [1] - Add preliminary, #ifdef'ed out support for setting the chip select. [1] - Use the RX instead of the TX commando size when setting up the RX side of a transfer. - For controllers having SPI_SR_TXEMPTY, i.e. !RM9200, also wait for the completion of the TX part of transfers before stopping the whole thing again. - Use DEVMETHOD_END. [1] - Use NULL instead of 0 for pointers. [1, partially]
Additional testing by: Ian Lepore
Submitted by: Ian Lepore [1]
|
237093 |
14-Jun-2012 |
marius |
MFC: r225882
Remove pointless semicolons after label
|
237091 |
14-Jun-2012 |
marius |
MFC: r236579
The workaround added in r151650 for handling firmwares that don't allow a single device to be opened multiple times concurrently unfortunately isn't sufficient with ZFS. This is due to the fact, that ZFS may open different partitions of a single device simultaneously. So the best we can do in this case is to cache the lastly used device path and close and open devices in ofwd_strategy() as needed.
PR: 165025 Submitted by: Gavin Mu
|
237053 |
14-Jun-2012 |
glebius |
Merge r236671 from head: Merge revision 1.715 from OpenBSD:
date: 2010/12/24 20:12:56; author: henning; state: Exp; lines: +3 -3 in pf_src_connlimit, the indices to sk->addr were swapped. tracked down and diff sent by Robert B Mills <rbmills at sdf.lonestar.org> thanks, very good work! ok claudio
Impact is that the "flush" keyword didn't work.
Obtained from: OpenBSD
|
236887 |
11-Jun-2012 |
rmacklem |
MFC: r235381 Fix two cases in the new NFS server where a tsleep() is used, when the code should actually protect the tested variable with a mutex. Since the tsleep()s had a 10sec timeout, the race would have only delayed the allocation of a new clientid for a client. The sleeps will also rarely occur, since having a callback in progress when a client acquires a new clientid, is unlikely. in practice, since having a callback in progress when a fresh clientid is being acquired by a client is unlikely.
|
236702 |
07-Jun-2012 |
yongari |
MFC r236371: Remove unnecessary device_printfs.
|
236698 |
06-Jun-2012 |
jhb |
MFC 233760: Export some more useful info about shared memory objects to userland via procstat(1) and fstat(1): - Change shm file descriptors to track the pathname they are associated with and add a shm_path() method to copy the path out to a caller-supplied buffer. - Use the fo_stat() method of shared memory objects and shm_path() to export the path, mode, and size of a shared memory object via struct kinfo_file. - Add a struct shmstat to the libprocstat(3) interface along with a procstat_get_shm_info() to export the mode and size of a shared memory object. - Change procstat to always print out the path for a given object if it is valid. - Teach fstat about shared memory objects and to display their path, mode, and size.
|
236683 |
06-Jun-2012 |
jhb |
MFC 228509,228620,228533: Add a helper API to allow in-kernel code to map portions of shared memory objects created by shm_open(2) into the kernel's address space. This provides a convenient way for creating shared memory buffers between userland and the kernel without requiring custom character devices.
|
236642 |
05-Jun-2012 |
marius |
MFC: r236491
Add missing prototypes. While at it, sort them alphabetically.
|
236641 |
05-Jun-2012 |
marius |
MFC: r236488
Take advantage of nitems().
|
236631 |
05-Jun-2012 |
marius |
MFC: r236486
Add nitems(), a macro for determining the number of elements in a statically-allocated array.
Obtained from: OpenBSD (in principle)
MFC: r236489
|
236518 |
03-Jun-2012 |
marius |
MFC: r233666
Fix build after changes to trap headers.
|
236511 |
03-Jun-2012 |
marius |
MFC: r233635
Allow multiple inclusion of trap.h. This has always been broken, but until recently never caused problems.
|
236484 |
02-Jun-2012 |
marius |
MFC: r236328
Try to finally get the point in time at which bge_add_sysctls() is called right; it needs to be called before bge_can_use_msi() but in turn requires bge_flags to be properly set.
Submitted by: yongari
|
236481 |
02-Jun-2012 |
avg |
MFC r235829: vm_pager_object_lookup: small performance optimization
|
236479 |
02-Jun-2012 |
marius |
MFC: r236156
- Fix some typos in mmc_acquire_bus() and mmc_send_csd(). - Fix some math errors in mmc_decode_csd_sd(). - Fix incorrect arguments to mmc_send_app_op_cond() in mmc_go_discovery(). - Add reporting of CSD for debug purposes. - Add detection (and skipping) of password-locked cards. - Add setting of block length on card if necessary.
Submitted by: Patrick Kelsey
|
236477 |
02-Jun-2012 |
marius |
MFC: r236070
Consistently use USB_PAGE_SIZE. Currently, this is cosmetic.
|
236475 |
02-Jun-2012 |
marius |
MFC: r236069, r236073
Make the VIA workaround actually do its intended job.
|
236473 |
02-Jun-2012 |
marius |
MFC: r236063
Remove extraneous empty lines.
|
236472 |
02-Jun-2012 |
marius |
Revert changes accidentally committed as part of r236468.
|
236468 |
02-Jun-2012 |
marius |
MFC: r236061
- When creating the DMA tag for user data, don't ask for more segments than required for handling MAXPHYS and report the resulting maximum I/O size to CAM instead of implicitly limiting it to DFLTPHYS. - Move the variables of sym_action2() out of nested scope as required by style(9) and remove extraneous curly braces. - Replace a magic value for PCIR_COMMAND with the appropriate macro. - Use DEVMETHOD_END. - Use NULL instead of 0 for pointers.
Tested with a HBA donated by wilko.
|
236464 |
02-Jun-2012 |
avg |
MFC r235391: i386 bootinfo: re-arrange EFI fields for natural alignment and packing
|
236413 |
01-Jun-2012 |
gallatin |
MFC 236212:
Update mxge(4) firmware to the latest version available from Myricom (1.4.55).
Sponored by: Myricom, Inc.
|
236320 |
30-May-2012 |
jhb |
MFC 235833: Only check to see if a memory resource is a PCI ROM BAR when activating and deactivating PCI resources. Previously, if a device had more than 48 MSI interrupts, then activating message 48 (which has a rid == PCIR_BIOS) would incorrectly try to enable the PCI ROM BAR.
|
236318 |
30-May-2012 |
jhb |
MFC 234501: The amr(4) firmware contains a rather dubious "feature" where it assumes for small buffers (< 64k) that the OS driver is actually using a buffer rounded up to the next power of 2. It also assumes that the buffer is at least 4k in size. Furthermore, there is at least one known instance of megarc sending a request with a 12k buffer where the firmware writes out a 24k-ish reply.
To workaround the data corruption triggered by this "feature", ensure that buffers for user commands use a minimum size of 32k, and that buffers between 32k and 64k use a 64k buffer.
|
236316 |
30-May-2012 |
jhb |
MFC 234099: Properly parse 40G media types from newer Mellanox adapters that are 40G capable. For now, map all 40G links to 40GBase-CR4.
|
236218 |
29-May-2012 |
yongari |
MFC r235821: Don't force max payload size to 128. Root complex and Endpoint will negotiate with each other on the TLP payload size so blindly forcing the size to 128 can cause a completion error which in turn will stop device.
Reported by: Geans Pin < geanspin <> broadcom dot com >
|
236216 |
29-May-2012 |
yongari |
MFC r235816: Make IPMI work in the bce driver even when the interface is configured down. Formerly, IPMI communication was lost whenever the interface was not up. The reason was that the BCE_EMAC_MODE register was not configured with the correct media settings. There are two parts to the fix.
First, resetting the chip in bce_reset() causes the BCE_EMAC_MODE register to be initialized to a default value that does not necessarily correspond to the actual media settings. The fix implemented here is a bit of a hack. Ideally, at the end of bce_reset() we would poll the PHY to determine the negotiated media, and then we would set the BCE_EMAC_MODE register accordingly. That is difficult, since the PHY is abstracted behind the MII layer and is not supposed to be queried directly from the MAC driver. Instead, we read the BCE_EMAC_MODE register at the beginning of bce_reset() and then restore its media bits to their original values before returning. If IPMI is up and running, then the link is already established and the BCE_EMAC_MODE register is already set appropriately when bce_reset() is called. If IPMI is not running, no harm is done by preserving the BCE_EMAC_MODE settings. The driver will set the register properly once the interface is configured up and link is established.
Second, bce_miibus_statchg() is sometimes called when the link is down. In that case, the reported media settings are invalid. Formerly, the driver used them anyway to setup the BCE_EMAC_MODE register. We now avoid changing any MAC registers unless link is active and the reported media settings are valid.
Submitted by: jdp Tested by: jdp
|
236164 |
27-May-2012 |
mckusick |
MFC of 235610
Add missing `continue' statement at end of case.
Found by: Kevin Lo (kevlo@)
|
236134 |
27-May-2012 |
rmacklem |
MFC: r234740 Fix a leak of namei lookup path buffers that occurs when a ZFS volume is exported via the new NFS server. The leak occurred because the new NFS server code didn't handle the case where a file system sets the SAVENAME flag in its VOP_LOOKUP() and ZFS does this for the DELETE case.
|
236096 |
26-May-2012 |
rmacklem |
MFC: r235332 PR# 165923 reported intermittent write failures for dirty memory mapped pages being written back on an NFS mount. Since any thread can call VOP_PUTPAGES() to write back a dirty page, the credentials of that thread may not have write access to the file on an NFS server. (Often the uid is 0, which may be mapped to "nobody" in the NFS server.) Although there is no completely correct fix for this (NFS servers check access on every write RPC instead of at open/mmap time), this patch avoids the common cases by holding onto a credential that recently opened the file for writing and uses that credential for the write RPCs being done by VOP_PUTPAGES() for both NFS clients.
|
236089 |
26-May-2012 |
marius |
MFC: r234524
o Fixes: - When switching to 4-bit operation, send a SET_CLR_CARD_DETECT command to disconnect the card-detect pull-up resistor from the DAT3 line before sending the SET_BUS_WIDTH command. - Add the missing "reserved" zero entry to the mantissa table used to decode various CSD fields. This was causing SD cards to report that they could run at 30 MHz instead of the maximum 25 MHz mandated in the spec. o Enhancements: - At the MMC layer, format various info from the CID into a string that uniquely identifies the card instance (manufacturer number, serial number, product name and revision, etc). Export it as an instance variable. - At the MMCSD layer, display the formatted card ID string, and also report the clock speed of the hardware (not the card's max speed), and the number of bits and number of blocks per transfer. It comes out like this now: mmcsd0: 968MB <SD SD01G 8.0 SN 276886905 MFG 08/2008 by 3 SD> at mmc0 22.5MHz/4bit/128-block o Use DEVMETHOD_END. o Use NULL instead of 0 for pointers.
PR: 156496 Submitted by: Ian Lepore
|
236088 |
26-May-2012 |
marius |
MFC: r234901
- Add missing locking in at91_usart_getc(). - Align the RX buffers on the cache line size, otherwise the requirement of partial cache line flushes on every are pretty much guaranteed. [1] - Make the code setting the RX timeout match its comment (apparently, start and stop bits were missed in the previous calculation). [1] - Cover the busdma operations in at91_usart_bus_{ipend,transmit}() with the hardware mutex, too, so these don't race against each other. - In at91_usart_bus_ipend(), reduce duplication in the code dealing with TX interrupts. - In at91_usart_bus_ipend(), turn the code dealing with RX interrupts into an else-if cascade in order reduce its complexity and to improve its run-time behavior. - In at91_usart_bus_ipend(), add missing BUS_DMASYNC_PREREAD calls on the RX buffer map before handing things over to the hardware again. [1] - In at91_usart_bus_getsig(), used a variable of sufficient width for storing the contents of USART_CSR. - Use KOBJMETHOD_END. - Remove an unused header.
Submitted by: Ian Lepore [1] Reviewed by: Ian Lepore
|
236085 |
26-May-2012 |
marius |
MFC: r234561
Interrupts must be disabled while handling a partial cache line flush, as otherwise the interrupt handling code may modify data in the non-DMA part of the cache line while we have it stashed away in the temporary stack buffer, then we end up restoring a stale value.
PR: 160431 Submitted by: Ian Lepore
|
236084 |
26-May-2012 |
marius |
MFC: r234560
- Add support for MCI1 revision 2xx controllers and a work-around for their "Data Write Operation and number of bytes" erratum. - Use DEVMETHOD_END. - Use NULL instead of 0 for pointers.
|
236082 |
26-May-2012 |
marius |
MFC: r234293
Generate an obviously missing STOP when having finished transmitting data. This fixes communication with PCF8563.
|
236081 |
26-May-2012 |
marius |
MFC: r234291, r234292
Add support for the Atmel SAM9XE family of microcontrollers, which consist of a ARM926EJ-S processor core with up to 512 Kbytes of on-chip flash. Tested with SAM9XE512.
|
236080 |
26-May-2012 |
marius |
MFC: r234281
- Try to bring these files closer to style(9). - Use DEVMETHOD_END. - Use NULL instead of 0 for pointers.
|
236078 |
26-May-2012 |
marius |
MFC: r234248
Add a driver for the NXP (Philips) PCF8563 RTC.
Obtained from: NetBSD (pcf8563reg.h)
|
236076 |
26-May-2012 |
marius |
MFC: r234898, r235207
Add initial support for booting from ZFS on sparc64. At least on Sun Fire V100, the firmware is known to be broken and not allowing to simultaneously open disk devices, causing attempts to boot from a mirror or RAIDZ to cause a crash. This will be worked around later. The firmwares of newer sun4u models don't seem to exhibit this problem though.
PR: 165025 Submitted by: Gavin Mu
|
236074 |
26-May-2012 |
thompsa |
MFC r234936 (emaste)
Relax restriction on direct tx to child ports
Lagg(4) restricts the type of packet that may be sent directly to a child port, to avoid undesired output from accidental misconfiguration. Previously only ETHERTYPE_PAE was permitted.
BPF writes to a lagg(4) child port are presumably intentional, so just allow them, while still blocking other packets that should take the aggregation path.
PR: kern/138620
|
236071 |
26-May-2012 |
thompsa |
MFC r231130 (pjd)
Allow to set if_bridge(4) sysctls from /boot/loader.conf.
|
236054 |
26-May-2012 |
thompsa |
MFC r235147
Do not reinitialise the interface if it is already running, this prevents the bootp+nfs code from working as it calls init on each dhcp send and rx fails to start in time.
|
236053 |
26-May-2012 |
thompsa |
MFC r235144
The DEVICE_POLLING dereference of sc->tsec_ifp needs to be checked for null first or this will panic. Condense three blocks that check sc->tsec_ifp into one while I am here.
|
236052 |
26-May-2012 |
thompsa |
MFC r234488
Move the interface media check to a taskqueue, some interfaces (usb) sleep during SIOCGIFMEDIA and we were holding locks.
|
236051 |
26-May-2012 |
thompsa |
MFC r234487
Add linkstate to bridge(4), set the link to up when at least one underlying interface is up, otherwise the link is down.
This, among other things, allows carp to work on a bridge.
|
236050 |
26-May-2012 |
thompsa |
MFC r234163
Set the proto to LAGG_PROTO_NONE before calling the detach routine so packets are discarded, this is an issue because lacp drops the lock which may allow network threads to access freed memory. Expand the lock coverage so the detach/attach happen atomically.
Submitted by: Andrew Boyer (earlier version)
|
236049 |
26-May-2012 |
thompsa |
MFC r232629,r232640
Add the ability to set which packet layers are used for the load balance hash calculation.
|
236048 |
26-May-2012 |
thompsa |
MFC r232118
Only look for a usable MAC address for the bridge ID from ports within our bridge, this allows us to have more than one independent bridge in the same STP domain.
PR: kern/164369 Submitted by: Nikos Vassiliadis (earlier version)
|
236047 |
26-May-2012 |
thompsa |
MFC r232014,r232030,r232070
- bstp_input() always consumes the packet so remove the mbuf handling dance around it. - Now that network interfaces advertise if they support linkstate notifications we do not need to perform a media ioctl every 15 seconds. - Indicate this function decrements the timer as well as testing for expiry.
|
236021 |
25-May-2012 |
marius |
MFC: r235681
Rewrite nd6_sysctl_{d,p}rlist() to avoid misaligned accesses to char arrays casted to structs by getting rid of these buffers entirely. In r169832, it was tried to paper over this issue by 32-bit aligning the buffers. Depending on compiler optimizations that still was insufficient for 64-bit architectures with strong alignment requirements though. While at it, add comments regarding the total lack of locking in this area.
Tested by: bz Reviewed by: bz (slightly earlier version), yongari (earlier version)
|
236004 |
25-May-2012 |
bschmidt |
MFC r232946,232958,235233:
r232946: Update the rt2860's firmware and add a Makefile for the module. While here remove the ucode header file which was used to generate the fw files but by now is outdated.
r232958: Import the latest microcode.h which was used to generate the current firmware files and adjust the Makefile.
r235233: Add support for Ralink RT2800/RT3000 chipsets.
|
235997 |
25-May-2012 |
marius |
MFC: r234897
Add a command for showing the heap usage.
PR: 165025 Submitted by: Gavin Mu
|
235995 |
25-May-2012 |
marius |
MFC: r234789
Add multiple inclusion protection.
PR: 165025 Submitted by: Gavin Mu
|
235992 |
25-May-2012 |
marius |
MFC: r234348
Turn on PREEMPTION by default. After fixing several bugs over time, the last show-stopper keeping PREEMPTION from being usable on sparc64 should have been dealt with in r230662 (MFC'ed to stable/9 in r230662). At least on 2-way systems, PREEMPTION causes a little bit of a degradation in worldstone performance. However, FreeBSD seems to have started building up regressions in !PREEMPTION cases so sparc64 better should not be an oddball in this regard.
|
235906 |
24-May-2012 |
rmacklem |
MFC: r235568 A problem with the NFSv4 server was reported by Andrew Leonard to freebsd-fs@, where the setfacl of an NFSv4 acl would fail. This was caused by the VOP_ACLCHECK() call for ZFS replying EOPNOTSUPP. After discussion with rwatson@, it was determined that a call to VOP_ACLCHECK() before doing VOP_SETACL() is not required. This patch fixes the problem by deleting the VOP_ACLCHECK() call.
|
235818 |
23-May-2012 |
yongari |
MFC r235151: Implement basic remote PHY support. Remote PHY allows the controller to perform MDIO type accesses to a remote transceiver using message pages defined through MRBE(multirate backplane ethernet). It's used in blade systems(e.g Dell Blade m610) which are connected to pass-through blades rather than traditional switches. This change directly manipulates firmware's mailboxes to control remote PHY such that it does not use mii(4). Alternatively, as David said, it could be implemented in brgphy(4) by creating a fake PHY and let brgphy(4) do necessary mii accesses and bce(4) can implement mailbox accesses based on the type of brgphy(4)'s mii accesses. Personally, I think it would make brgphy(4) hard to maintain since it would have to access many bce(4) registers in brgphy(4). Given that there are users who are suffering from lack of remote PHY support, it would be better to get working system rather than waiting for complete/perfect implementation.
|
235764 |
22-May-2012 |
jhb |
MFC 234098: Add media types for 40G media that might be used with FreeBSD.
|
235763 |
22-May-2012 |
jhb |
Repair mergeinfo from merges done into a sparse checkout.
|
235743 |
21-May-2012 |
jhb |
Toss bogus mergeinfo.
|
235741 |
21-May-2012 |
jhb |
MFC 234190,234196,234280: - Extend the KDB interface to add a per-debugger callback to print a backtrace for an arbitrary thread (rather than the calling thread). A kdb_backtrace_thread() wrapper function uses the configured debugger if possible, otherwise it falls back to using stack(9) if that is available. - Replace a direct call to db_trace_thread() in propagate_priority() with a call to kdb_backtrace_thread() instead.
|
235738 |
21-May-2012 |
sbruno |
MFC r235634
Fix and update battery status bits according to linux driver
|
235627 |
18-May-2012 |
jhb |
Move mergeinfo from sys/kern/subr_witness.c up to sys/.
|
235626 |
18-May-2012 |
mckusick |
MFC of 234386, 234400, 234441, 234443, 234482, 234483, 235052, 235241, 235246, and 235619
MFC: 234386
Replace the MNT_VNODE_FOREACH interface with MNT_VNODE_FOREACH_ALL. The primary changes are that the user of the interface no longer needs to manage the mount-mutex locking and that the vnode that is returned has its mutex locked (thus avoiding the need to check to see if its is DOOMED or other possible end of life senarios).
To minimize compatibility issues for third-party developers, the old MNT_VNODE_FOREACH interface will remain available so that this change can be MFC'ed to 9. Following the MFC to 9, MNT_VNODE_FOREACH will be removed in head.
The reason for this update is to prepare for the addition of the MNT_VNODE_FOREACH_ACTIVE interface that will loop over just the active vnodes associated with a mount point (typically less than 1% of the vnodes associated with the mount point).
Reviewed by: kib Tested by: Peter Holm MFC after: 2 weeks
MFC: 234400
Drop export of vdestroy() function from kern/vfs_subr.c as it is used only as a helper function in that file. Replace sole call to vbusy() with inline code in vholdl(). Replace sole calls to vfree() and vdestroy() with inline code in vdropl().
The Clang compiler already inlines these functions, so they do not show up in a kernel backtrace which is confusing. Also you cannot set their frame in kgdb which means that it is impossible to view their local variables. So, while the produced code is unchanged, the debugging should be easier.
Discussed with: kib MFC after: 2 weeks
MFC: 234441
Fix a memory leak of M_VNODE_MARKER introduced in 234386.
Found by: Peter Holm
MFC: 234443
Delete a no longer useful VNASSERT missed during changes in 234400.
Suggested by: kib
MFC: 234482
This change creates a new list of active vnodes associated with a mount point. Active vnodes are those with a non-zero use or hold count, e.g., those vnodes that are not on the free list. Note that this list is in addition to the list of all the vnodes associated with a mount point.
To avoid adding another set of linkage pointers to the vnode structure, the active list uses the existing linkage pointers used by the free list (previously named v_freelist, now renamed v_actfreelist).
This update adds the MNT_VNODE_FOREACH_ACTIVE interface that loops over just the active vnodes associated with a mount point (typically less than 1% of the vnodes associated with the mount point).
Reviewed by: kib Tested by: Peter Holm MFC after: 2 weeks
MFC: 234483
This update uses the MNT_VNODE_FOREACH_ACTIVE interface that loops over just the active vnodes associated with a mount point to replace MNT_VNODE_FOREACH_ALL in the vfs_msync, ffs_sync_lazy, and qsync routines.
The vfs_msync routine is run every 30 seconds for every writably mounted filesystem. It ensures that any files mmap'ed from the filesystem with modified pages have those pages queued to be written back to the file from which they are mapped.
The ffs_lazy_sync and qsync routines are run every 30 seconds for every writably mounted UFS/FFS filesystem. The ffs_lazy_sync routine ensures that any files that have been accessed in the previous 30 seconds have had their access times queued for updating in the filesystem. The qsync routine ensures that any files with modified quotas have those quotas queued to be written back to their associated quota file.
In a system configured with 250,000 vnodes, less than 1000 are typically active at any point in time. Prior to this change all 250,000 vnodes would be locked and inspected twice every minute by the syncer. For UFS/FFS filesystems they would be locked and inspected six times every minute (twice by each of these three routines since each of these routines does its own pass over the vnodes associated with a mount point). With this change the syncer now locks and inspects only the tiny set of vnodes that are active.
Reviewed by: kib Tested by: Peter Holm MFC after: 2 weeks
MFC: 235052 (by pluknet)
Fix mount mutex handling missed in r234386.
MFC: 235241 (by pluknet)
Fix mount interlock oversights from the previous change in r234386.
Reported by: dougb Submitted by: Mateusz Guzik <mjguzik at gmail com> Reviewed by: Kirk McKusick Tested by: pho
MFC: 235246
Fix mount mutex handling missed in r234386.
MFC: 235619
Update comment to document that the vnode free-list mutex needs to be held when updating mnt_activevnodelist and mnt_activevnodelistsize.
|
235620 |
18-May-2012 |
jhb |
MFC 234186 If a linker file contains at least one module, but all of the modules fail to load (the MOD_LOAD event fails) during a kldload(2), unload the linker file and fail the kldload(2) with ENOEXEC.
|
235612 |
18-May-2012 |
jhb |
MFC 234182: Don't update if_obytes when transmitting packets. That is already done in IFQ_HANDOFF() when the packet is passed to the start routine, so doing it here resulted in double counting.
|
235564 |
17-May-2012 |
jhb |
MFC 235563: Don't expose i386-only ptrace constants on amd64. This broke gdb with libthread_db on amd64.
|
235522 |
16-May-2012 |
jhb |
MFC 234152: Allow device_busy() and device_unbusy() to be invoked while a device is being attached. This is implemented by adding a new DS_ATTACHING state while a device's DEVICE_ATTACH() method is being invoked. A driver is required to not fail an attach of a busy device. The device's state will be promoted to DS_BUSY rather than DS_ACTIVE() if the device was marked busy during DEVICE_ATTACH()
|
235515 |
16-May-2012 |
jhb |
MFC 233709,233781,233793: - Don't malloc() new MCA records for machine checks logged due to a CMCI or MC# exception. Instead, use a pre-allocated pool of records. When a CMCI or MC# exception fires, schedule a task to refill the pool. The pool is sized to hold at least one record per available machine bank, and one record per CPU. This should handle the case of all CPUs triggering a single bank at once as well as the case a single CPU triggering all of its banks. The periodic scans still use malloc() since they are run from a safe context. - Make machine check exception logging more readable. On newer Intel systems, an uncorrected ECC error tends to fire on all CPUs in a package simultaneously and the current printf hacks are not sufficient to make the messages legible. Instead, use the existing mca_lock spinlock to serialize calls to mca_log() and change the machine check code to panic directly when an unrecoverable error is encoutered rather than falling back to a trap_fatal() call in trap() (which adds nearly a screen-full of logging messages that aren't useful for machine checks).
|
235483 |
15-May-2012 |
jpaetzel |
MFC 229533:
Update contrib/xz-embedded to build with new GEOM_UNCOMPRESS module.
|
235482 |
15-May-2012 |
jpaetzel |
MFC 229211:
Initial copy of xz-embedded to sys/contrib/.
The upcoming geom_compress module (a read-only gzip/ulzma translation layer, similar to what geom_uzip does) will leverage parts of this.
|
235480 |
15-May-2012 |
avg |
MFC r230643: stop_scheduler -> td_stopsched
|
235449 |
14-May-2012 |
jh |
MFC r234489:
The value of flags matching VNOVAL can't be supported. Return EOPNOTSUPP from setfflags() in this case. This fixes the return value of chflags(path, -1).
|
235423 |
14-May-2012 |
yongari |
MFC r235119: Restore jumbo frame configuration which was broken in r218423.
Submitted by: Andrey Zonov <andrey <> zonov dot org > (initial version) Tested by: Andrey Zonov <andrey <> zonov dot org >
|
235422 |
14-May-2012 |
marius |
MFC: r235255
- Change the module order of these MAC drivers to be last so they are deterministically handled after the corresponding PHY drivers when loaded as modules. Otherwise, when these MAC/PHY driver pairs are compiled into a single module probing the PHY driver may fail. This makes r151438 and r226154 actually work. [1] Reported and tested by: yongari (fxp(4)) - Use DEVMETHOD_END. - Use NULL instead of 0 for pointers.
Submitted by: jhb [1]
|
235413 |
13-May-2012 |
avg |
MFC r229854: enable stop_scheduler_on_panic by default
|
235411 |
13-May-2012 |
avg |
MFC r228765: ukbd: adjust for SCHEDULER_STOPPED() and overhaul locking code
|
235410 |
13-May-2012 |
avg |
MFC r228760: adapt usb transfer code for SCHEDULER_STOPPED
|
235409 |
13-May-2012 |
avg |
MFC r228767: sc_cngrab: switch to console vty when possible
|
235408 |
13-May-2012 |
avg |
MFC r228644: syscons: provide a first iteration of cngrab/cnungrab implementation
|
235407 |
13-May-2012 |
avg |
MFC r228633,228634,228638,228642,228643: introduce cngets, a method for kernel to read a string from console
|
235406 |
13-May-2012 |
avg |
MFC r228632: introduce cngrab/cnungrab stub calls in some places where they make sense
|
235405 |
13-May-2012 |
avg |
MFC r228631: kern cons: introduce infrastructure for console grabbing by kernel
|
235404 |
13-May-2012 |
avg |
MFC r228424,228448: panic: add a switch and infrastructure for stopping other CPUs in SMP case
|
235397 |
13-May-2012 |
rmacklem |
MFC: r234742 It was reported via email that some non-FreeBSD NFS servers do not include file attributes in the reply to an NFS create RPC under certain circumstances. This resulted in a vnode of type VNON that was not usable. This patch adds an NFS getattr RPC to nfs_create() for this case, to fix the problem. It was tested by the person that reported the problem and confirmed to fix this case for their server.
|
235260 |
11-May-2012 |
attilio |
MFC r233961,234074,234105,234564,234723,234989,235231-235232: - Fix a bug in x86 and sparc64 where the intr cpu mask does only enables the BSP. - Remove the SMP constraints for intr_add_cpu
|
235131 |
07-May-2012 |
jh |
MFC r234104:
Apply changes from r233787 to ext2fs:
- Use more natural ip->i_flags instead of vap->va_flags in the final flags check. - Style improvements.
No functional change intended.
MFC r234139:
Restore the blank line incorrectly removed in r234104.
|
235010 |
04-May-2012 |
jh |
MFC r233875: Add a check for unsupported file flags to ufs_setattr().
|
234929 |
02-May-2012 |
jh |
MFC r233787:
- Use more natural ip->i_flags instead of vap->va_flags in the final flags check. - Add a comment for the immutable/append check done after handling of the flags. - Style improvements.
No functional change intended.
MFC r234421:
The part about exec atime no longer applies in the comment.
|
234771 |
28-Apr-2012 |
alc |
MFC r234038 If a page belonging a reservation is cached, then mark the reservation so that it will be freed to the cache pool rather than the default pool. Otherwise, the cached pages within the reservation may be recycled sooner than necessary.
|
234766 |
28-Apr-2012 |
alc |
MFC r234039 Fix mincore(2) so that it reports PG_CACHED pages as resident.
|
234765 |
28-Apr-2012 |
alc |
MFC r233097 With the changes over the past year to how accesses to the page's dirty field are synchronized, there is no need for pmap_protect() to acquire the page queues lock unless it is going to access the pv lists.
|
234764 |
28-Apr-2012 |
alc |
MFC r234554 Updates to the vm_page's flags no longer require the page queues lock.
|
234763 |
28-Apr-2012 |
alc |
MFC r232166 Simplify vm_mmap()'s control flow.
Add a comment describing what vm_mmap_to_errno() does.
|
234736 |
27-Apr-2012 |
dim |
MFC r234507:
Fix the following compilation warnings in sys/contrib/rdma/rdma_cma.c:
sys/contrib/rdma/rdma_cma.c:1259:8: error: case value not in enumerated type 'enum iw_cm_event_status' [-Werror,-Wswitch] case ECONNRESET: ^ @/sys/errno.h:118:20: note: expanded from macro 'ECONNRESET' #define ECONNRESET 54 /* Connection reset by peer */ ^ sys/contrib/rdma/rdma_cma.c:1263:8: error: case value not in enumerated type 'enum iw_cm_event_status' [-Werror,-Wswitch] case ETIMEDOUT: ^ @/sys/errno.h:124:19: note: expanded from macro 'ETIMEDOUT' #define ETIMEDOUT 60 /* Operation timed out */ ^ sys/contrib/rdma/rdma_cma.c:1260:8: error: case value not in enumerated type 'enum iw_cm_event_status' [-Werror,-Wswitch] case ECONNREFUSED: ^ @/sys/errno.h:125:22: note: expanded from macro 'ECONNREFUSED' #define ECONNREFUSED 61 /* Connection refused */ ^
This is because the switch uses iw_cm_event::status, which is an enum iw_cm_event_status, while ECONNRESET, ETIMEDOUT and ECONNREFUSED are just plain defines from errno.h.
It looks like there is only one use of any of the enumeration values of iw_cm_event_status, in:
sys/contrib/rdma/rdma_iwcm.c: if (iw_event->status == IW_CM_EVENT_STATUS_ACCEPTED) {
So messing around with the enum definitions to fix the warning seems too disruptive; the simplest fix is to cast the argument of the switch to int.
Reviewed by: kmacy
|
234679 |
25-Apr-2012 |
avg |
MFC r234339: zfsboot: honor -q if it's present in boot.config
|
234677 |
25-Apr-2012 |
avg |
MFC r234338: intpm: add ATI IXP400 pci id
PR: kern/136762
|
234673 |
25-Apr-2012 |
avg |
MFC r234208: add actual interrupt counters to back ipi_invlcache_counts
|
234671 |
25-Apr-2012 |
avg |
MFC r234207: bump INTRCNT_COUNT values to reflect actual numbers of IPI counters
|
234593 |
23-Apr-2012 |
yongari |
MFC r234121: Back out r228476. r228476 fixed superfluous link UP/DOWN messages but broke IPMI access during boot. It's not clear why r228476 breaks IPMI and should be revisited.
Reported by: Paul Guyot <paulguyot <> ieee dot org >
|
234559 |
21-Apr-2012 |
raj |
MFC r227730:
Initial version of cesa(4) driver for Marvell crypto engine and security accelerator.
The following algorithms and schemes are supported: - 3DES, AES, DES - MD5, SHA1
Obtained from: Semihalf Written by: Piotr Ziecik
|
234558 |
21-Apr-2012 |
raj |
MFC r233230, r233323:
Improve device tree blob (DTB) handling in loader(8).
Enable using the statically embedded blob from the kernel, if present. The KLD loaded DTB takes precedence, but they are both recognized and handled in the same way.
Improve FDT handling in loader(8) and make it more robust.
o Fix buffer overflows when using a long property body in node paths. o Fix loop end condition when iterating through the symbol table. o Better error handling during node modification, better problem reporting. o Eliminate build time warnings.
Submitted by: Lukasz Wojcik Obtained from: Semihalf
|
234511 |
20-Apr-2012 |
rmh |
MFC of r227310:
Don astbestos garment and remove the warning about TMPFS being experimental -- highly experimental even. So far the closest to a bug in TMPFS that people have gotten to relates to how ZFS can take away from the memory that TMPFS needs. One can argue that such is not a bug in TMPFS. Irrespective, even if there is a bug here and there in TMPFS, it's not in our own advantage to scare people away from using TMPFS. I for one have been using it, even with ZFS, very successfully.
Reviewed by: marcel
|
234490 |
20-Apr-2012 |
marius |
MFC: r234247
Merge from x86:
r233961:
Fix interrupt load balancing regression, introduced in revision 222813, that left all un-pinned interrupts assigned to CPU 0. In intr_shuffle_irqs(), remove CPU_SETOF() call that initialized the "intr_cpus" cpuset to only contain CPU0.
This initialization is too late and nullifies the results of calls to the intr_add_cpu() that occur much earlier in the boot process.
r234074 (partial):
The BSP is not added to the mask of valid target CPUs for interrupts. Fix this by adding the BSP as an interrupt target directly in
r234105:
Fix !SMP build after r234074.
|
234473 |
19-Apr-2012 |
mckusick |
MFC of 234158:
Export vinactive() from kern/vfs_subr.c (e.g., make it no longer static and declare its prototype in sys/vnode.h) so that it can be called from process_deferred_inactive() (in ufs/ffs/ffs_snapshot.c) instead of the body of vinactive() being cut and pasted into process_deferred_inactive().
Reviewed by: kib MFC after: 2 weeks
|
234471 |
19-Apr-2012 |
mckusick |
MFC of 234157:
Whitespace cleanup.
|
234470 |
19-Apr-2012 |
mckusick |
MFC of 233817:
A file cannot be deallocated until its last name has been removed and it is no longer referenced by a user process. The inode for a file whose name has been removed, but is still referenced at the time of a crash will still be allocated in the filesystem, but will have no references (e.g., they will have no names referencing them from any directory).
With traditional soft updates these unreferenced inodes will be found and reclaimed when the background fsck is run. When using journaled soft updates, the kernel must keep track of these inodes so that it can find and reclaim them during the cleanup process. Their existence cannot be stored in the journal as the journal only handles short-term events, and they may persist for days. So, they are tracked by keeping them in a linked list whose head pointer is stored in the superblock. The journal tracks them only until their linked list pointers have been commited to disk. Part of the cleanup process involves traversing the list of unreferenced inodes and reclaiming them.
This bug was triggered when confusion arose in the commit steps of keeping the unreferenced-inode linked list coherent on disk. Notably, a race between the link() system call adding a link-count to a file and the unlink() system call removing a link-count to the file. Here if the unlink() ran after link() had looked up the file but before link() had incremented the link-count of the file, the file's link-count would drop to zero before the link() incremented it back up to one. If the file was referenced by a user process, the first transition through zero made it appear that it should be added to the unreferenced-inode list when in fact it should not have been added. If the new name created by link() was deleted within a few seconds (with the file still referenced by a user process) it would legitimately be a candidate for addition to the unreferenced-inode list. The result was that there were two attempts to add the same inode to the unreferenced-inode list which scrambled the unreferenced-inode list's pointers leading to a panic. The fix is to detect and avoid the false attempt at adding it to the unreferenced-inode list by having the link() system call check to see if the link count is zero before it increments it. If it is, the link() fails with ENOENT (showing that it has failed the link()/unlink() race).
While tracking down this bug, we have added additional assertions to detect the problem sooner and also simplified some of the code.
Reported by: Kirk Russell Fix submitted by: Jeff Roberson Tested by: Peter Holm PR: kern/159971
|
234466 |
19-Apr-2012 |
mckusick |
MFC of 233627, 234024, 234025, and 234026
Restore per mount-point counts of synchronous and asynchronous reads and writes associated with UFS and MSDOS filesystems.
MFS 233627: Keep track of the mount point associated with a special device to enable the collection of counts of synchronous and asynchronous reads and writes for its associated filesystem. The counts are displayed using `mount -v'.
Ensure that buffers used for paging indicate the vnode from which they are operating so that counts of paging I/O operations from the filesystem are collected.
This checkin only adds the setting of the mount point for the UFS/FFS filesystem, but it would be trivial to add the setting and clearing of the mount point at filesystem mount/unmount time for other filesystems too.
Reviewed by: kib
MFC 234024: Drop an unnecessary setting of si_mountpt when updating a UFS mount point. Clearly it must have been set when the mount was done.
Reviewed by: kib
MFC 234025: Add I/O accounting to msdos filesystem.
Suggested and reviewed by: kib
MFC 234026: Expand locking around identification of filesystem mount point when accounting for I/O counts at completion of I/O operation. Also switch from using global devmtx to vnode mutex to reduce contention.
Suggested and reviewed by: kib
|
234391 |
17-Apr-2012 |
jhb |
MFC 234059: Recognize the RDRAND instruction feature.
|
234316 |
15-Apr-2012 |
netchild |
MFC r232799: - add comments to syscalls.master and linux(32)_dummy about which linux kernel version introduced the sysctl (based upon a linux man-page) - add comments to syscalls.master regarding some names of sysctls which are different than the linux-names (based upon the linux unistd.h) - add some dummy sysctls - name an unimplemented sysctl
|
234240 |
13-Apr-2012 |
marius |
MFC: r233888
- Const'ify the device lookup-table. - Use DEVMETHOD_END. - Use NULL instead of 0 for pointers. - Enable support for flow control. Tested by: yongari
|
234215 |
13-Apr-2012 |
avg |
MFC r234043: intpm: return only SMB bus error codes from SMB methods
|
234213 |
13-Apr-2012 |
avg |
MFC r234040: intpm: reflect the fact that SB800 and later AMD chipsets are not supported
|
234211 |
13-Apr-2012 |
avg |
MFC r233918: zfs_ioctl: no need for ddi_copyin/out here because sys_ioctl handles that
|
234209 |
13-Apr-2012 |
avg |
MFC r231558: newvers.sh: unbreak git/git-svn support
|
234181 |
12-Apr-2012 |
jhb |
MFC 233547: Use VM_MEMATTR_UNCACHEABLE instead of VM_MEMATTR_UNCACHED for UC mappings. VM_MEMATTR_UNCACHED is actually the x86-specific UC- mode (where a WC MTRR can override the PAT setting).
|
234179 |
12-Apr-2012 |
jhb |
MFC 233670,233671: - Use VM_MEMATTR_UNCACHEABLE for the constant for UC memory rather than VM_MEMATTR_UNCACHED on mips. - Rename VM_MEMATTR_UNCACHED to VM_MEMATTR_WEAK_UNCACHEABLE on x86 to be less ambiguous and more clearly identify what it means. An alias from VM_MEMATTR_WEAK_UNCACHEABLE to VM_MEMATTR_WEAK_UNCACHED remains on x86 to preserve the KPI. - Remove the VM_MEMATTR_UNCACHED alias from powerpc.
|
234150 |
11-Apr-2012 |
jhb |
MFC 233676: Use a more proper fix for enabling HT MSI mapping windows on Host-PCI bridges. Rather than blindly enabling the windows on all of them, only enable the window when an MSI interrupt is enabled for a device behind the bridge, similar to what already happens for HT PCI-PCI bridges.
|
234148 |
11-Apr-2012 |
jhb |
MFC 233893: Disable INET6 support in modules when building the LINT-NOINET6 kernel.
|
234147 |
11-Apr-2012 |
jhb |
MFC 233305,233623: - Mark the 'lapics' and 'ioapics' arrays here static since they are private to this file. The 'lapics' array was actually shadowing a completely different 'lapics' array that is private to local_apic.c. - Allocate the ioapics[] array dynamically since it is only needed for the duration of madt_setup_io(). This avoids having the array take up permanent space in the BSS.
|
234145 |
11-Apr-2012 |
jhb |
MFC 232228,233613: Move the DTrace return IDT vector back up from 0x20 to 0x92. The 0x20 vector is currently dedicated to servicing IRQ 0 from the 8259A's, so it shouldn't be overloaded for DTrace.
|
234144 |
11-Apr-2012 |
jhb |
MFC 232744,232747,233031: - Allow a native i386 kernel to be built with 'nodevice atpic'. Just as on amd64, if 'device isa' is present quiesce the 8259A's during boot and resume from suspend. - Move i386's intr_machdep.c to the x86 tree and share it with amd64. - Merge r232744 changes to pc98. (Allow a kernel to be built with 'nodevice atpic'.) - Move ICU related defines from x86/isa/atpic.c to x86/isa/icu.h and use them in x86/x86/intr_machdep.c.
Note, I normally would have merged 232747 separately, but 233031 assumed 232747 was already merged and 232744 needs to be merged with 233031.
|
234141 |
11-Apr-2012 |
jhb |
MFC 232742: MFamd64: - Return failure for a suspend attempt if we have no wake address. - Use intr_disable()/intr_restore() instead of ACPI_DISABLE_IRQS(). - Invoke intr_suspend() earlier and call intr_resume() if suspend fails. - Use pause in the loop waiting for CPU to suspend. - Restore PAT MSR, switchtime, switchticks, and MTRRs on resume.
|
234126 |
11-Apr-2012 |
yongari |
MFC r233688-233689: r233688: Remove task queue based link state change handler. Driver no longer needs to defer link state handling. While I'm here, mark IFF_DRV_RUNNING before changing media. If link is established without any delay, that link state change handling could be lost.
r233689: Do not report current link status if driver is not running. This change also workarounds dhclient's link state handling bug by not giving current link status.
Unlike other controllers, ale(4)'s PHY hibernation perfectly works such that driver does not see a valid link if the controller is not brought up. If dhclient(8) runs on ale(4) it will blindly waits until link UP and then gives up after 10 seconds. Because dhclient(8) still thinks interface got a valid link when IFM_AVALID is not set for selected media, this change makes dhclient initiate DHCP without waiting for link UP.
|
234123 |
11-Apr-2012 |
yongari |
MFC r233585-233587: r233585: Partially revert r223608 and selectively allow microcode loading for 82550C. For 82550 controllers this change restores CPUSaver microcode loading. Due to silicon bug on 82550 and 82550C with server extension, these controllers seem to require CPUSaver microcode to receive fragmented UDP datagrams. However the microcode shouldn't be used on client featured 82550C as it locks up the controller. In addition, client featured 82550C does not have the silicon bug. Also clear temporary memory used for microcode loading since the same memory area is used for other commands. While I'm here use 82550C in probe message instead of generic 82550.
Reported by: Andreas Longwitz <longwitz <> incore de> Tested by: Andreas Longwitz <longwitz <> incore de>
r233586: Load entire EEPROM contents in device attach time and verify whether the checksum of EEPROM is valid or not. Because driver heavily relies on EEPROM information when it selectively enables features/workarounds, it would be helpful to know whether driver sees valid EEPROM. While I'm here remove all other EEPROM accesses since the entire EEPROM is loaded at device attach time.
r233587: Remove unnecessary #if as the software workaround for PCI protocol violation should be activated unless the system is cold-booted after updating EEPROM. The PCI protocol violation happens only when established link is 10Mbps so the workaround should be updated whenever link state change is detected. Previously the workaround was activated only when user checks current media status with ifconfig(8).
|
234028 |
08-Apr-2012 |
bschmidt |
MFC r233284: Update the firmware to version 0.236
Submitted by: PseudoCylon
|
233995 |
07-Apr-2012 |
marius |
MFC: r233827
Fix probing of SAS1068E with a device ID of 0x0059 after r232411 (MFC'ed to stable/9 in r232562). Reported by: infofarmer
MFC: r233886
Refine r233827; as it turns out, controllers with a device ID of 0x0059 can be upgraded to MegaRAID mode, in which case mfi(4) should attach to these based on the sub-vendor and -device ID instead (not currently done). Therefore, let mpt_pci_probe() return BUS_PROBE_LOW_PRIORITY. While it, let mpt_pci_probe() return BUS_PROBE_DEFAULT instead of 0 in the default case.
|
233924 |
05-Apr-2012 |
jhb |
MFC 233675: Restore proper use of bounce buffers for ISA DMA. When locking was added, the call to pmap_kextract() was moved up, and as a result the code never updated the physical address to use for DMA if a bounce buffer was used. Restore the earlier location of pmap_kextract() so it takes bounce buffers into account.
|
233889 |
04-Apr-2012 |
marius |
MFC: r233747, r233748
- Fix panic on kernel traps having a mapping in trap_sig b0rked in r206086. Reported by: David E. Cross - Remove checks that are redundant due to tf_type being unsigned.
|
233816 |
02-Apr-2012 |
jhb |
MFC 233236: Add sys/ofed to the 'make cscope' target.
|
233814 |
02-Apr-2012 |
jhb |
MFC 232700: Add a new sched_clear_name() method to the scheduler interface to clear the cached name used for KTR_SCHED traces when a thread's name changes. This way KTR_SCHED traces (and thus schedgraph) will notice when a thread's name changes, most commonly via execve().
|
233811 |
02-Apr-2012 |
marius |
MFC: r233701
- Remove erroneous trailing semicolon. [1] - Correctly determine the maximum payload size for setting the TX link frequent NACK latency and replay timer thresholds.
Submitted by: stefanf [1]
|
233810 |
02-Apr-2012 |
gnn |
MFC: 232612
Properly mask off bits that are not supported in the IAP counters. This fixes a bug where users would see massively large counts, near to 2**64 -1, due to the bits not being cleared.
|
233750 |
31-Mar-2012 |
alc |
MFC r233256 Eliminate vm.pmap.shpgperproc and vm.pmap.pv_entry_max because they no longer serve any purpose.
|
233743 |
31-Mar-2012 |
marius |
MFC: r233427
Add cas(4), gem(4) and hme(4) to x86 GENERICs as suggested by netchild@ in <20120222095239.Horde.0hpYHJjmRSRPRKzXsoFRbYk@webmail.leidinger.net>. According to some private emails received, it apparently is not unpopular to use at least Quad GigaSwift cards driven by cas(4) in x86 machines.
|
233740 |
31-Mar-2012 |
marius |
MFC: r233425
Consistently update to the MPI header set version 01.05.20 after r224761. Requested by: mjacob
|
233725 |
31-Mar-2012 |
marius |
MFC: r233423
Initialize the mutexes used for the NVM and the swflag as MTX_DUPOK in order to avoid otherwise harmless witness warnings when these are acquired at the same time and due to both using MTX_NETWORK_LOCK as their type. The right fix actually would be to use different, descriptive types for these. However, the latter would require undesirable changes to the shared code base. Another approach would be to just supply NULL as the type, which was deemed as less desirable though as it would cause the unique but cryptic name also to be used for the type and to diverge from the type used by other network device drivers.
|
233723 |
31-Mar-2012 |
marius |
MFC: r233421
Given that this is a host-PCI-Express bridge driver, create the parent DMA tag with a 4 GB boundary as required by PCI-Express. With r232403 (MFC'ed to stable/9 in r233393) in place this actually is redundant. However, the host-PCI-Express bridge driver is the more appropriate place for implementing this restriction.
|
233721 |
31-Mar-2012 |
marius |
MFC: r233403, r233404
- Use the PCI ID macros from mpi_cnfg.h rather than duplicating them here. Note that this driver additionally probes some device IDs for the most part not know to other MPT drivers, if at all. So rename the macros not present in mpi_cnfg.h to match the naming scheme in the latter and but suffix them with a _FB in order to not cause conflicts. - Like mpt_set_config_regs(), comment out mpt_read_config_regs() as the content of the registers read isn't actually used and both functions aren't exactly up to date regarding the possible layouts of the BARs (these function might be helpful for debugging though, so don't remove them completely). - Use DEVMETHOD_END. - Use NULL rather than 0 for pointers. - Remove an unusual check for the softc being NULL. - Remove redundant zeroing of the softc. - Remove an overly banal and actually partly incorrect as well as partly outdated comment regarding the allocation of the memory resource.
|
233719 |
31-Mar-2012 |
marius |
MFC: r233287
Use the common/shared CRC-32 implementation instead of duplicating it.
|
233717 |
31-Mar-2012 |
marius |
MFC: r233282
- First pass at const'ifying ata(4) as appropriate. - Use DEVMETHOD_END. - Use NULL instead of 0 for pointers.
|
233715 |
30-Mar-2012 |
marius |
MFC: r233274
Remove remnants of ATA_LOCKING uses in the ATA_CAM case and wrap it along with functions, SYSCTLs and tunables that are not used with ATA_CAM in #ifndef ATA_CAM, similar to the existing #ifdef'ed ATA_CAM code for the other way around. This makes it easier to understand which parts of ata(4) actually are used in the new world order and to later on remove the !ATA_CAM bits. It also makes it obvious that there is something fishy with the C-bus front-end as well as in the ATP850 support, as these used ATA_LOCKING which is defunct in the ATA_CAM case. When fixing the former, ATA_LOCKING probably needs to be brought back in some form or other.
Reviewed by: mav
|
233712 |
30-Mar-2012 |
marius |
MFC: r233273
Exclude devices which are mutually exclusive with ATA_CAM. For better or worse, the former are still built as modules as part of the LINT builds.
Reviewed by: mav
|
233705 |
30-Mar-2012 |
jhb |
MFC 232669: Use bus_get_dma_tag() to inherit the 4G boundary restriction from the parent PCI bus and remove the home-grown version in this driver.
|
233659 |
29-Mar-2012 |
rmh |
MFC r233096:
Hide a few declarations from userland (including `struct inpcbgroup'). This removes the dependency on <machine/param.h> which was introduced with SVN rev 222748 (due to CACHE_LINE_SIZE).
Reviewed by: bde MFC after: 10 days
|
233647 |
29-Mar-2012 |
alc |
MFC r233291 Handle spurious page faults that may occur in no-fault sections of the kernel.
|
233630 |
28-Mar-2012 |
mckusick |
MFC of 232351, 233438, and 233629
MFC reviewed by: kib
MFC 232351:
This change avoids a kernel deadlock on "snaplk" when using snapshots on UFS filesystems running with journaled soft updates. This is the first of several bugs that need to be fixed before removing the restriction added in -r230250 to prevent the use of snapshots on filesystems running with journaled soft updates.
The deadlock occurs when holding the snapshot lock (snaplk) and then trying to flush an inode via ffs_update(). We become blocked by another process trying to flush a different inode contained in the same inode block that we need. It holds the inode block for which we are waiting locked. When it tries to write the inode block, it gets blocked waiting for the our snaplk when it calls ffs_copyonwrite() to see if the inode block needs to be copied in our snapshot.
The most obvious place that this deadlock arises is in the ffs_copyonwrite() routine when it updates critical metadata in a snapshot and tries to write it out before proceeding. The fix here is to write the data and indirect block pointer for the snapshot, but to skip the call to ffs_update() to write the snapshot inode. To ensure that we will never have to update a pointer in the inode itself, the ffs_snapshot() routine that creates the snapshot has to ensure that all the direct blocks are allocated as part of the creation of the snapshot.
A less obvious place that this deadlock occurs is when we hold the snaplk because we are deleting a snapshot. In the course of doing the deletion, we need to allocate various soft update dependency structures and allocate some journal space. If we hit a resource limit while doing this we decrease the resources in use by flushing out an existing dirty file to get it to give up the soft dependency resources that it holds. The flush can cause an ffs_update() to be done on the inode for the file that we have selected to flush resulting in the same deadlock as described above when the inode that we have chosen to flush resides in the same inode block as the snapshot inode that we hold. The fix is to defer cleaning up any time that the inode on which we are operating is a snapshot.
Help and review by: Jeff Roberson Tested by: Peter Holm
MFC 233438:
Add a third flags argument to ffs_syncvnode to avoid a possible conflict with MNT_WAIT flags that passed in its second argument.
Discussed with: kib
MFC 233629:
A refinement of change 232351 to avoid a race with a forcible unmount. While we have a snapshot vnode unlocked to avoid a deadlock with another inode in the same inode block being updated, the filesystem containing it may be forcibly unmounted. When that happens the snapshot vnode is revoked. We need to check for that condition and fail appropriately.
Spotted by: kib Reviewed by: kib
|
233604 |
28-Mar-2012 |
zec |
MFC r232517: Change SYSINIT priorities so that ip_mroute_modevent() is executed before vnet_mroute_init(), since vnet_mroute_init() depends on mfchashsize tunable to be set, and that is done in in ip_mroute_modevent(). Apparently I broke that ordering with r208744 almost 2 years ago...
PR: kern/162201 Submitted by: Stevan Markovic (mcafee.com) MFC after: 3 days
|
233602 |
28-Mar-2012 |
zec |
MFC: 232487 Properly restore curvnet context when returning early from ether_input_internal().
This change only affects options VIMAGE kernel builds.
PR: kern/165643 Submitted by: Vijay Singh MFC after: 3 days
|
233543 |
27-Mar-2012 |
jh |
MFC r233126:
Cast wallclock.tv_sec to uint64_t to avoid overflow in the calculation.
PR: kern/161552
|
233501 |
26-Mar-2012 |
yongari |
MFC r232951,232953,233158: r232951: fxp(4) does not handle deferred dma map loading. Tell bus_dmamap_load(9) that it should return immediately with error when there are insufficient mapping resources.
r232953: Fix white space nits.
r233158: Do not change current media when driver is already running. If driver is running driver would have already completed flow control configuration. This change removes unnecessary media changes in controller reconfiguration cases such that it does not trigger link reestablishment for configuration change requests like promiscuous mode change.
Reported by: Many Tested by: Mike Tancsa <mike <> sentex dot net>
|
233498 |
26-Mar-2012 |
yongari |
MFC r232849-232850: r232849: Show PCI bus speed and width as well as running mode of PCI-X device in device attach. This would help to narrow down issue to a specific controller and operating mode of the controller. While I'm here rename BGE_MISCCFG_BOARD_ID with BGE_MISCCFG_BOARD_ID_MASK.
r232850: Make if_ierrors updated whenever any of the following counters are updated. o Number of times NIC ran out of RX buffer descriptors o Number of inbound packet errors o Number of inbound packets that were chosen to be discarded Previously only the discarded packet counter was used to update if_ierrors. This change fixes wrong if_ierrors counter on BCM570[0-4] controllers. For BCM5705 and later controllers bge(4) already correctly counted it.
Reported by: Eugene Grosbein <egrosbein <> rdtc dot ru>
|
233495 |
26-Mar-2012 |
yongari |
MFC r232848: Add workaround for PCI-X BCM5704 controller that live behind AMD-8131 PCI-X bridge. The bridge seems to reorder write access to mailbox registers such that it caused watchdog timeouts by out-of-order TX completions.
Tested by: Michael L. Squires <mikes <> siralan dot org >
|
233492 |
26-Mar-2012 |
yongari |
MFC r232246: Prefer RL_GMEDIASTAT register to RGEPHY_MII_SSR register to extract a link status of PHY when parent driver is re(4). RGEPHY_MII_SSR register does not seem to report correct PHY status on some integrated PHYs used with re(4). Unfortunately, RealTek PHYs have no additional information to differentiate integrated PHYs from external ones so relying on PHY model number is not enough to know that. However, it seems RGEPHY_MII_SSR register exists for external RealTek PHYs so checking parent driver would be good indication to know which PHY was used. In other words, for non-re(4) controllers, the PHY is external one and its revision number is greater than or equal to 2. This change fixes intermittent link UP/DOWN messages reported on RTL8169 controller.
Also, mii_attach(9) is tried after setting interface name since rgephy(4) have to know parent driver name.
PR: kern/165509
|
233489 |
26-Mar-2012 |
yongari |
MFC r232145: Use correct Config registers for RTL8139 family. Unlike RTL8168 and RTL810x family , RTL8139 has different register map for Config registers.
While here, follow the lead of re(4) in WOL configuration. - Disable WOL_UCAST and WOL_MCAST capabilities by default. - Config5 register write does not need to unlock EEPROM access on RTL8139 family but unlocking EEPROM access does not affect its operation and make it consistent with re(4).
Reported by: Matt Renzelmann mjr <> cs dot wisc dot edu
|
233486 |
26-Mar-2012 |
yongari |
MFC r232019,232021,232025,232027,232029,232031,232040: r232019: Give hardware chance to drain active DMA cycles.
r232021: If there are not enough RX buffers, release partially allocated RX buffers.
r232025: Introduce sf_ifmedia_upd_locked() and have driver reset PHY before switching to selected media. While here, set if_drv_flags before switching to selected media.
r232027: No need to reprogram hardware RX filter when driver is not running.
r232029: Remove taskqueue based MII stat change handler. Driver does not need deferred link state change processing. While I'm here, do not report current link status if interface is not UP.
r232031: With r232015, sf(4) gets correct speed/duplex of established link. Add more strict speed check in sf_miibus_statchg() and do not touch MAC config registers when driver lost a link.
r232040: Add check for IFF_DRV_RUNNING flag after serving an interrupt and don't give RX path more priority than TX path. Also remove infinite loop in interrupt handler and limit number of iteration to 32. This change addresses system load fluctuations under high network load.
|
233485 |
26-Mar-2012 |
yongari |
MFC r232015-232016: r232015: Add Seeq Technology 80220 PHY support to smcphy(4). This PHY is found on Adaptec AIC-6915 Starfire ethernet controller. While here, use status register to know resolved speed/duplex. With this change, sf(4) correctly reports speed/duplex of established link.
r232016: Connect smcphy(4) to mii module build.
|
233468 |
25-Mar-2012 |
marius |
MFC: r233105
Declare some variables static in order to reduce the object size and redo r232822 (MFC'ed to stable/9 in r232962) in a less hackish way. The latter now no longer breaks compiling the x86 boot2 with clang.
|
233398 |
23-Mar-2012 |
jhb |
MFC 232470: Use pci_find_cap() instead of pci_find_extcap() to locate PCI find capabilities as the latter API is deprecated for this purpose.
|
233393 |
23-Mar-2012 |
jhb |
MFC 232403,232667: - Add a bus_dma tag to each PCI bus that is a child of a Host-PCI bridge. The tag enforces a single restriction that all DMA transactions must not cross a 4GB boundary. Note that while this restriction technically only applies to PCI-express, this change applies it to all PCI devices as it is simpler to implement that way and errs on the side of caution. - Add a softc structure for PCI bus devices to hold the bus_dma tag and a new pci_attach_common() routine that performs actions common to the attach phase of all PCI bus drivers. Right now this only consists of a bootverbose printf and the allocate of a bus_dma tag if necessary. - Adjust all PCI bus drivers to allocate a PCI bus softc and to call pci_attach_common() from their attach routines.
|
233385 |
23-Mar-2012 |
jhb |
MFC 232401: Similar to the fixes in 226967 and 226987, purge any name cache entries associated with the previous vnode (if any) associated with the target of a rename(). Otherwise, a lookup of the target pathname concurrent with a rename() could re-add a name cache entry after the namei(RENAME) lookup in kern_renameat() had purged the target pathname.
|
233383 |
23-Mar-2012 |
jhb |
MFC 232367: Properly handle failures in igb_setup_msix() by returning 0 if MSI or MSI-X allocation fails.
|
233379 |
23-Mar-2012 |
jhb |
MFC 232360: Add pci_save_state() and pci_restore_state() wrappers around pci_cfg_save() and pci_cfg_restore() for device drivers to use when saving and restoring state (e.g. to handle device-specific resets).
|
233376 |
23-Mar-2012 |
jhb |
Record mergeinfo for 233374.
|
233358 |
23-Mar-2012 |
jhb |
MFC 232218: Clear the a device's description string anytime it's driver changes. Descriptions are specific to drivers and we don't change drivers on attached devices. This fixes a few places where we were not clearing the description when detaching a driver (e.g. if device_attach() failed). While here, fix a few other nits: - Remove spurious call to remove a device's driver from devclass_driver_deleted(). device_detach() removes it already. - Fix a typo.
|
233355 |
23-Mar-2012 |
jhb |
MFC 232265: Properly clear a device's devclass if DEVICE_ATTACH() fails if the device does not have a fixed devclass.
|
233353 |
23-Mar-2012 |
kib |
MFC r231949: Fix found places where uio_resid is truncated to int.
Add the sysctl debug.iosize_max_clamp, enabled by default. Setting the sysctl to zero allows to perform the SSIZE_MAX-sized i/o requests from the usermode.
MFC r232493: Remove unneeded cast to u_int. The values as small enough to fit into int, beside the use of MIN macro which performs type promotions.
MFC r232494: Instead of incomplete handling of read(2)/write(2) return values that does not fit into registers, declare that we do not support this case using CTASSERT(), and remove endianess-unsafe code to split return value into td_retval.
While there, change the style of the sysctl debug.iosize_max_clamp definition.
MFC r232495: pipe_read(): change the type of size to int, and remove signed clamp. pipe_write(): change the type of desiredsize back to int, its value fits.
|
233326 |
22-Mar-2012 |
jhb |
MFC 230547: Add a timeout on positive name cache entries in the NFS client. That is, we will only trust a positive name cache entry for a specified amount of time before falling back to a LOOKUP RPC, even if the ctime for the file handle matches the cached copy in the name cache entry. The timeout is configured via a new 'nametimeo' mount option and defaults to 60 seconds. It may be set to zero to disable positive name caching entirely.
|
233324 |
22-Mar-2012 |
jhb |
MFC 232116: Adjust the nfs_skip_wcc_data_onerr setting so that it does not block post-op attributes for ENOENT errors now that the name caching logic depends on working post-op attributes.
|
233285 |
21-Mar-2012 |
jhb |
MFC 230394,230441,230489,230552,232420: Close a race in NFS lookup processing that could result in stale name cache entries on one client when a directory was renamed on another client. The root cause for the stale entry being trusted is that each per-vnode nfsnode structure has a single 'n_ctime' timestamp used to validate positive name cache entries. However, if there are multiple entries for a single vnode, they all share a single timestamp. To fix this, extend the name cache to allow filesystems to optionally store a timestamp value in each name cache entry. The NFS clients now fetch the timestamp associated with each name cache entry and use that to validate cache hits instead of the timestamps previously stored in the nfsnode. Another part of the fix is that the NFS clients now use timestamps from the post-op attributes of RPCs when adding name cache entries rather than pulling the timestamps out of the file's attribute cache. The latter is subject to races with other lookups updating the attribute cache concurrently.
|
233281 |
21-Mar-2012 |
jh |
MFC r232975: Add an assert for proctree_lock to proc_to_reap().
|
233275 |
21-Mar-2012 |
glebius |
Merge 232685 from head: Merge from OpenBSD:
revision 1.146 date: 2010/05/12 08:11:11; author: claudio; state: Exp; lines: +2 -3 bzero() the full compressed update struct before setting the values. This is needed because pf_state_peer_hton() skips some fields in certain situations which could result in garbage beeing sent to the other peer. This seems to fix the pfsync storms seen by stephan@ and so dlg owes me a whiskey.
I didn't see any storms, but this definitely fixes a useless memory allocation on the receiving side, due to non zero scrub_flags field in a pfsync_state_peer structure.
|
233266 |
21-Mar-2012 |
glebius |
Merge 228321 from head: Fix double free.
PR: kern/163089 Submitted by: Herbie Robinson <Herbie.Robinson stratus.com>
|
233265 |
21-Mar-2012 |
glebius |
Merge from head: r227785: - Reduce severity for all ARP events, that can be triggered from remote machine to LOG_NOTICE. Exception left to "using my IP address". - Fix multicast ARP warning: add newline and also log the bad MAC address.
Tested by: Alexander Wittig <wittigal msu.edu>
r227790: Be more informative for "unknown hardware address format" message.
Submitted by: Andrzej Tobola <ato iem.pw.edu.pl>
|
233261 |
21-Mar-2012 |
glebius |
Merge 227308 from head/: In icmp6_redirect_input:
- Assert that we got a valid mbuf with rcvif pointer. [1] - Use __func__ in logging.
Submitted by: prabhakar lakhera <prabhakar.lakhera gmail.com> [1] Submitted by: Kristof Provost <kristof sigsegv.be> [1]
|
233200 |
19-Mar-2012 |
jhb |
MFC 229621: Convert all users of IF_ADDR_LOCK to use new locking macros that specify either a read lock or write lock.
|
233084 |
17-Mar-2012 |
brueffer |
MFC: r232315
Use a more appropriate default for the maximum number of addresses in the bridge forwarding table.
|
233076 |
17-Mar-2012 |
marcel |
MFC r227430: On i386, fbt probes are implemented by writing an invalid opcode over certain instructions in a function prologue or epilogue. DTrace has a hook into the invalid opcode fault handler that checks whether the fault was due to an probe and if so, runs the DTrace magic.
Upon returning from an invalid opcode fault caused by a probe, DTrace must emulate the instruction that was replaced with the invalid opcode and then return control to the instruction following the invalid opcode.
There were a pair of related bugs in the emulation for the leave instruction. The leave instruction is used to pop off a stack frame prior to returning from a function. The emulation for this instruction must move the trap frame for the invalid opcode fault down the stack to the bottom of the stack frame that is being removed, and then execute an iret.
At two points in this process, the emulation code was storing values above the current value of the stack pointer. This opened up a window in which if we were two take an interrupt, the trap frame for the interrupt would overwrite the values stored on the stack, causing the system to panic later.
The first bug was that at one point the emulation code saves the new value for $esp above the current stack pointer value. The fix is to save this value instead inside of the original trap frame. At this point we do not need the original trap frame so this is safe.
The second bug is that when the emulate code loads $esp from the stack, it points part-way through the new trap frame instead of at its beginning. The emulation code adjusts the stack pointer to the correct value immediately afterwards, but this still leaves a one instruction window in which an interrupt would corrupt this trap frame. Fix this by adjusting the stack frame value before loading it into $esp.
This fixes panics in invop_leave on i386 when using fbt return probes.
Ok'd by: rstone
|
233046 |
16-Mar-2012 |
jhb |
MFC 226340,226340: Use queue(3) macros instead of home-rolled versions in several places in the INET6 code. This includes retiring the 'ndpr_next' and 'pfr_next' macros.
|
233015 |
15-Mar-2012 |
raj |
MFC r232518:
Respect phy-handle property in Ethernet nodes of the device tree.
This lets specify whereabouts of the parent PHY for a given MAC node (and get rid of ugly kludges in mge(4) and tsec(4)).
Obtained from: Semihalf
|
233014 |
15-Mar-2012 |
raj |
MFC r232512:
Remove unused #defines. All this is now retrieved from the device tree.
|
232962 |
14-Mar-2012 |
marius |
MFC: r232822
Fix a bug introduced in r223938; on big-endian machines coping a 32-bit quantum bytewise to the address of a 64-bit variable results in writing to the "wrong" 32-bit half so adjust the address accordingly. This fix is implemented in a hackish way for two reasons: o in order to be able to get it into 8.3 with zero impact on the little- endian architectures where this bug has no effect and o to avoid blowing the x86 boot2 out of the water again when compiling it with clang, which all sane versions of this fix tested do. This change fixes booting from UFS1 file systems on big-endian machines.
|
232945 |
13-Mar-2012 |
glebius |
Merge 231025 from head: Add new socket options: TCP_KEEPINIT, TCP_KEEPIDLE, TCP_KEEPINTVL and TCP_KEEPCNT, that allow to control initial timeout, idle time, idle re-send interval and idle send count on a per-socket basis.
Reviewed by: andre, bz, lstewart
|
232683 |
08-Mar-2012 |
rmacklem |
MFC: r2323467 The name caching changes of r230394 exposed an intermittent bug in the new NFS server for NFSv4, where it would report ENOENT when the file actually existed on the server. This turned out to be caused by not initializing ni_topdir before calling lookup() and there was a rare case where the value on the stack location assigned to ni_topdir happened to be a pointer to a ".." entry, such that "dp == ndp->ni_topdir" succeeded in lookup(). This patch initializes ni_topdir to fix the problem.
|
232682 |
08-Mar-2012 |
rmacklem |
MFC: r232327 Fix the NFS clients so that they use copyin() instead of bcopy(), when doing direct I/O. This direct I/O code is not enabled by default.
|
232511 |
04-Mar-2012 |
raj |
MFC r230865:
Adjust mvs(4) to handle interrupt cause reg depending on the actual number of channels available
- current code treats bits 4:7 in 'SATAHC interrupt mask' and 'SATAHC interrupt cause' as flags for SATA channels 2 and 3
- for embedded SATA controllers (SoC) these bits have been marked as reserved in datasheets so far, but for some new and upcoming chips they are used for purposes other than SATA
Submitted by: Lukasz Plachno Reviewed by: mav Obtained from: Semihalf
|
232508 |
04-Mar-2012 |
raj |
MFC r228504, r228530.
r228504: Make *intr{cnt,names} on ARM reside in data section, similar to other arches.
sintrnames and sintrcnt are initialized with non-zero values, which were discarded by the .bss directive, so consumers like "vmstat -i" were not getting correct data.
Submitted by: Lukasz Plachno Obtained from: Semihalf
r228530: ARM pmap fixes:
- Write Buffers have to be drained after write to Page Table even if caches are in write-through mode.
- Make sure to sync PTE in pmap_zero_page_generic().
Submitted by: Michal Mazur Reviewed by: cognet Obtained from: Semihalf
|
232292 |
29-Feb-2012 |
bz |
MFC r231852,232127:
Merge multi-FIB IPv6 support.
Extend the so far IPv4-only support for multiple routing tables (FIBs) introduced in r178888 to IPv6 providing feature parity.
This includes an extended rtalloc(9) KPI for IPv6, the necessary adjustments to the network stack, and user land support as in netstat.
Sponsored by: Cisco Systems, Inc.
|
232290 |
29-Feb-2012 |
davidxu |
MFC 230857:
If multiple threads call kevent() to get AIO events on same kqueue fd, it is possible that a single AIO event will be reported to multiple threads, it is not threading friendly, and the existing API can not control this behavior. Allocate a kevent flags field sigev_notify_kevent_flags for AIO event notification in sigevent, and allow user to pass EV_CLEAR, EV_DISPATCH or EV_ONESHOT to AIO kernel code, user can control whether the event should be cleared once it is retrieved by a thread. This change should be comptaible with existing application, because the field should have already been zero-filled, and no additional action will be taken by kernel.
PR: kern/156567
MFC 231006:
Add 32-bit compat code for AIO kevent flags introduced in revision 230857.
MFC 231724:
Add notes about sigev_notify_kevent_flags introduced in revision 230857 which enables thread-friendly polling on same fd for AIO events.
Reviewed by: delphij
MFC 231777:
Bump .Dd date for previous revision.
|
232279 |
29-Feb-2012 |
thompsa |
MFC r232008,232010,232080,232089
Using the flowid in the mbuf assumes the network card is giving a good hash for the traffic flow, this may not be the case giving poor traffic distribution. Add a sysctl which allows us to fall back to our own flow hash code.
PR: kern/164901
|
232259 |
28-Feb-2012 |
rmacklem |
MFC: r232050 hrs@ reported a panic to freebsd-stable@ under the subject line "panic in 8.3-PRERELEASE" on Feb. 22, 2012. This panic was caused by use of a mix of tsleep() and msleep() calls on the same event in the new NFS server DRC code. It did "mtx_unlock(); tsleep();" in two places, which kib@ noted introduced a slight risk that the wakeup() would occur before the tsleep(), resulting in a 10sec delay before waking up. This patch fixes the problem by replacing "mtx_unlock(); tsleep();" with mtx_sleep(..PDROP..). It also changes a nfsmsleep() call to mtx_sleep() so that the code uses mtx_sleep() consistently within the file.
|
232140 |
25-Feb-2012 |
marius |
MFC: r231985
Fix memset sizeof
|
232137 |
25-Feb-2012 |
marius |
MFC: r231914
Probe the National DP83849, which is a dual-port version of the PHYTER.
Obtained from: NetBSD
|
232134 |
25-Feb-2012 |
marius |
MFC: r231913
- Probe BCM57780. - In case the parent is bge(4), don't set the Jumbo frame settings unless the MAC actually is Jumbo capable as otherwise the PHY might not have the corresponding registers implemented. This is also in line with what the Linux tg3 driver does.
PR: 165032 Submitted by: Alexander Milanov Obtained from: OpenBSD
|
232117 |
24-Feb-2012 |
alc |
MFC r231904 Close a race due to dropping of the map lock between creating a map entry for a shared mapping and marking the entry for inheritance.
|
232092 |
24-Feb-2012 |
marius |
MFC: r231621
- As it turns out, MSI-X is broken for at least LSI SAS1068E when passed through by VMware so blacklist their PCI-PCI bridge for MSI/MSI-X here. Note that besides currently there not being a quirk type that disables MSI-X only and there's no evidence that MSI doesn't work with the VMware pass-through, it's really questionable whether MSI generally works in that setup as VMware only mention three know working devices [1, p. 4]. Also not that this quirk entry currently doesn't affect the devices emulated by VMware in any way as these don't claim support MSI/MSI-X to begin with. [2] While at it, make the PCI quirk table const and static. - Remove some duplicated empty lines. - Use DEVMETHOD_END.
PR: 163812, http://forums.freebsd.org/showthread.php?t=27899 [2] Reviewed by: jhb
[1]: http://www.vmware.com/pdf/vsp_4_vmdirectpath_host.pdf
|
232068 |
23-Feb-2012 |
cperciva |
MFC 230183: Make XENHVM work on i386 by fixing the definition of __ffs.
|
232067 |
23-Feb-2012 |
cperciva |
MFC 230184, 230185: Add XENHVM config file to i386.
|
232045 |
23-Feb-2012 |
yongari |
MFC r231622: For RTL8168/8111D controller, make sure to wake PHY from power down mode. Otherwise, PHY access times out under certain conditions.
|
232018 |
23-Feb-2012 |
rmacklem |
MFC: r231805 Delete a couple of out of date comments that are no longer true in the new NFS client.
|
231905 |
19-Feb-2012 |
rmh |
MFC r230972,r230980,r231559,r231565: Add MK_SOURCELESS build option, and associated fixes.
Approved by: kib (mentor)
|
231775 |
15-Feb-2012 |
alc |
MFC r229363 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.
|
231734 |
15-Feb-2012 |
yongari |
MFC r230286,230337-230338,231159: r230286: Introduce a tunable that disables use of MSI. Non-zero value will use INTx.
r230337-230338: Rename dev.bge.%d.msi_disable to dev.bge.%d.msi which matches enable/disable and default it to on.
r231159: Call bge_add_sysctls() early and especially before bge_can_use_msi() so r230337 actually has a chance of working and doesn't always unconditionally disable the use of MSIs.
|
231731 |
15-Feb-2012 |
yongari |
MFC r230336: Fix a logic error which resulted in putting PHY into sleep when WOL is active. If WOL is active driver should not put PHY into sleep. This change makes WOL work on RTL8168E.
|
231728 |
15-Feb-2012 |
yongari |
MFC r230575-230576: r230275: Use a RX DMA tag to free loaded RX DMA maps. Previously it used a TX DMA tag.
r230276: Free allocated jumbo buffers when controller is stopped.
|
231725 |
15-Feb-2012 |
yongari |
MFC r229940: style. No functional changes.
|
231636 |
14-Feb-2012 |
rmacklem |
MFC: r230803 When a "mount -u" switches an NFS mount point from TCP to UDP, any thread doing an I/O RPC with a transfer size greater than NFS_UDPMAXDATA will be hung indefinitely, retrying the RPC. After a discussion on freebsd-fs@, I decided to add a warning message for this case, as suggested by Jeremy Chadwick.
|
231633 |
14-Feb-2012 |
rmacklem |
MFC: r230801 jwd@ reported a problem via email to freebsd-fs@ on Aug 25, 2011 under the subject "F_RDLCK lock to FreeBSD NFS fails to R/O target file". This occurred because the server side NLM always checked for VWRITE access, irrespective of the type of lock request. This patch replaces VOP_ACCESS(..VWRITE..) with one appropriate to the lock operation. It allows unlock and lock cancellation to be done without a check of VOP_ACCESS(), so that files can't be left locked indefinitely after the file permissions have been changed.
|
231629 |
14-Feb-2012 |
marius |
MFC: r231228
Remove extra newlines from panic messages.
|
231623 |
14-Feb-2012 |
marius |
MFC: r231518
Remove extra newlines from panic messages.
|
231610 |
13-Feb-2012 |
jhb |
MFC 230340: Properly return success once a matching VPD entry is found in pci_get_vpd_readonly_method(). Previously the loop was always running to completion and falling through to failing with ENXIO.
|
231545 |
12-Feb-2012 |
rmacklem |
MFC: r231133 r228827 fixed a problem where copying of NFSv4 open credentials into a credential structure would corrupt it. This happened when the p argument was != NULL. However, I now realize that the copying of open credentials should only happen for p == NULL, since that indicates that it is a read-ahead or write-behind. This patch fixes this. After this commit, r228827 could be reverted, but I think the code is clearer and safer with the patch, so I am going to leave it in. Without this patch, it was possible that a NFSv4 VOP_SETATTR() could have changed the credentials of the caller. This would have happened if the process doing the VOP_SETATTR() did not have the file open, but some other process running as a different uid had the file open for writing at the same time.
|
231522 |
11-Feb-2012 |
avg |
MFC r230157: dadump: don't leak the periph lock on i/o error
|
231330 |
10-Feb-2012 |
rmacklem |
MFC: r230605 A problem with respect to data read through the buffer cache for both NFS clients was reported to freebsd-fs@ under the subject "NFS corruption in recent HEAD" on Nov. 26, 2011. This problem occurred when a TCP mounted root fs was changed to using UDP. I believe that this problem was caused by the change in mnt_stat.f_iosize that occurred because rsize was decreased to the maximum supported by UDP. This patch fixes the problem by using v_bufobj.bo_bsize instead of f_iosize, since the latter is set to f_iosize when the vnode is allocated, but does not change for a given vnode when f_iosize changes.
|
231178 |
08-Feb-2012 |
marcel |
MFC r231177: Rev. 228360 moved the call to cpu_set_upcall() to happen before td_proc gets initialized in td (=newtd). Use td0 instead.
|
231165 |
07-Feb-2012 |
jhb |
MFC 229465: Use correct locking when traversing interface address list.
|
231157 |
07-Feb-2012 |
jhb |
MFC 229614: Add new variants of the IF_ADDR_*LOCK*() macros used for protecting interface address lists that distinguish read locks from write locks. To preserve the KPI, the previous operations are mapped to the write lock macros. The lock is still kept as a mutex for now.
|
231156 |
07-Feb-2012 |
jhb |
MFC 229613: Update recently added drivers to use the if_*addr_r*lock() wrapper functions instead of using the IF_ADDR_LOCK directly. The wrapper functions are the supported interface for device drivers.
|
231153 |
07-Feb-2012 |
jhb |
MFC 229598: Remove use of explicit bus space tags and handles and use methods that operate on resource objects instead.
|
231152 |
07-Feb-2012 |
jhb |
Hoist mergeinfo for modules/sound/driver/* up to sys/.
|
231150 |
07-Feb-2012 |
jhb |
MFC 228962: Use curthread rather than PCPU_GET(curthread). 'curthread' uses special-case optimizations on several platforms and is preferred.
|
231145 |
07-Feb-2012 |
jhb |
MFC 228957: Implement linux_fadvise64() and linux_fadvise64_64() using kern_posix_fadvise().
|
231023 |
05-Feb-2012 |
nwhitehorn |
MFC r230247:
Revert r212360 now that PowerPC can handle large sparse arguments to pmap_remove() (changed in r228412).
|
231022 |
05-Feb-2012 |
nwhitehorn |
Pick a constant high IRQ value for the PS3 IPI, which lets PS3 devices be usefully loaded and unloaded as modules.
Submitted by: geoffrey dot levand at mail dot ru
|
231021 |
05-Feb-2012 |
nwhitehorn |
MFC r230398:
Prevent an error resulting from signed/unsigned comparison on systems that do not comply with the OF spec.
Submitted by: Anders Gavare
|
230966 |
03-Feb-2012 |
dim |
MFC r229753:
In sys/contrib/rdma/ib_addr.h, bump MAX_ADDR_LEN to 20 bytes (the same value used in sys/ofed/include/linux/netdevice.h), so there will be no buffer overruns in the rest of the inline functions in this file.
Reviewed by: kmacy
|
230928 |
03-Feb-2012 |
rmacklem |
MFC: r230345 Martin Cracauer reported a problem to freebsd-current@ under the subject "Data corruption over NFS in -current". During investigation of this, I came across an ugly bogusity in the new NFS client where it replaced the cr_uid with the one used for the mount. This was done so that "system operations" like the NFSv4 Renew would be performed as the user that did the mount. However, if any other thread shares the credential with the one doing this operation, it could do an RPC (or just about anything else) as the wrong cr_uid. This patch fixes the above, by using the mount credentials instead of the one provided as an argument for this case. It appears to have fixed Martin's problem. This patch is needed for NFSv4 mounts and NFSv3 mounts against some non-FreeBSD servers that do not put post operation attributes in the NFSv3 Statfs RPC reply.
Tested by: cracauer at cons.org, dim
|
230920 |
02-Feb-2012 |
ken |
MFC 230592:
Bring in the LSI-supported version of the mps(4) driver.
This involves significant changes to the mps(4) driver, but is not a complete rewrite.
Some of the changes in this version of the driver: - Integrated RAID (IR) support. - Support for WarpDrive controllers. - Support for SCSI protection information (EEDP). - Support for TLR (Transport Level Retries), needed for tape drives. - Improved error recovery code. - ioctl interface compatible with LSI utilities.
mps.4: Update the mps(4) driver man page somewhat for the driver changes. The list of supported hardware still needs to be updated to reflect the full list of supported cards.
conf/files: Add the new driver files.
mps/mpi/*: Updated version of the MPI header files, with a BSD style copyright.
mps/*: See above for a description of the new driver features.
modules/mps/Makefile: Add the new mps(4) driver files.
Submitted by: Kashyap Desai <Kashyap.Desai@lsi.com> Sponsored by: LSI, Spectra Logic Reviewed by: ken
|
230896 |
01-Feb-2012 |
marius |
MFC: r227980
Move to SCHED_ULE by default. Since r226057 SCHED_ULE and sparc64 are compatible with each other and since r227539 the last issue seen when using SCHED_ULE is fixed (MFC'ed to stable/9 in r230691 and r227714 respectively). At least on UP and 2-way machines SCHED_4BSD still performs better than SCHED_ULE, however, the optimizations done in r225889 (MFC'ed to stable/9 in r230673) pretty much compensate that so there's at least no net regression. Thanks go to Peter Jeremy for extensive testing.
|
230894 |
01-Feb-2012 |
marius |
MFC: r230664
As it turns out r227960 (MFC'ed to stable/9 in r228126) may still be insufficient with PREEMPTION so try harder to get the CDMA sync interrupt delivered and also in a more efficient way: - wrap the whole process of sending and receiving the CDMA sync interrupt in a critical section so we don't get preempted, - send the CDMA sync interrupt to the CPU that is actually waiting for it to happen so we don't take a detour via another CPU, - instead of waiting for up to 15 seconds for the interrupt to trigger try the whole process for up to 15 times using a one second timeout (the code was also changed to just ignore belated interrupts of a previous tries should they appear).
According to testing done by Peter Jeremy with the debugging also added as part of this commit the first two changes apparently are sufficient to now properly get the CDMA sync interrupts delivered at the first try though.
|
230892 |
01-Feb-2012 |
marius |
MFC: r230662
Fully disable interrupts while we fiddle with the FP context in the VIS-based block copy/zero implementations. While with 4BSD it's sufficient to just disable the tick interrupts, with ULE+PREEMPTION it's otherwise also possible that these are preempted via IPIs.
|
230890 |
01-Feb-2012 |
marius |
MFC: r230633, r230634
Now that we have a working OF_printf() since r230631 and a OF_panic() helper since r230632 (MFC'ed to stable/9 in r230884 and r230886 respectively), use these for output and panicing during the early cycles and move cninit() until after the static per-CPU data has been set up. This solves a couple of issue regarding the non- availability of the static per-CPU data: - panic() not working and only making things worse when called, - having to supply a special DELAY() implementation to the low-level console drivers, - curthread accesses of mutex(9) usage in low-level console drivers that aren't conditional due to compiler optimizations (basically, this is the problem described in r227537 but in this case for keyboards attached via uart(4)). [1]
PR: 164123 [1]
|
230888 |
01-Feb-2012 |
marius |
MFC: r230628
Mark cpu_{halt,reset}() as __dead2 as appropriate.
|
230886 |
01-Feb-2012 |
marius |
MFC: r230632
- Now that we have a working OF_printf() since r230631 (MFC'ed to stable/9 in r230884), use it for implementing a simple OF_panic() that may be used during the early cycles when panic() isn't available, yet. - Mark cpu_{exit,shutdown}() as __dead2 as appropriate.
|
230884 |
01-Feb-2012 |
marius |
MFC: r230631
Implement OF_printf() using kvprintf() directly, avoiding to use a buffer and allowing to handle newlines properly.
|
230882 |
01-Feb-2012 |
marius |
MFC: r230630
For machines where the kernel address space is unrestricted increase VM_KMEM_SIZE_SCALE to 2, awaiting more insight from alc@. As it turns out, the VM apparently has problems with machines that have large holes in the physical address space, causing the kmem_suballoc() call in kmeminit() to fail with a VM_KMEM_SIZE_SCALE of 1. Using a value of 2 allows these, namely Blade 1500 with 2GB of RAM, to boot.
PR: 164227
|
230880 |
01-Feb-2012 |
marius |
MFC: r230627
Using ATA_CAM along with ATAPI DMA causes data corruption with ALI_NEW and CMD controllers for reasons unknown so disable it.
PR: 164226
|
230872 |
01-Feb-2012 |
mav |
MFC r228820, r228851: Merge to da driver quirks hinting 4K physical sector sizes for SATA disks connected via SAS or USB. Unluckily I've found that SAS (mps) and USB-SATA I have translate models in different ways, requiring twice more quirks. Unluckily for Hitachi, their model names are trimmed on SAS, making impossible to identify 4K sector drives that way.
|
230868 |
01-Feb-2012 |
glebius |
Merge some cleanups and bugfixes to pfsync(4) and pf(4) from head. Merged revisions: r229773,229777,229849-229853,229857,229959,229961-229964,229976.
r229777: Merge from OpenBSD: revision 1.170 date: 2011/10/30 23:04:38; author: mikeb; state: Exp; lines: +6 -7 Allow setting big MTU values on the pfsync interface but not larger than the syncdev MTU. Prompted by the discussion with and tested by Maxim Bourmistrov; ok dlg, mpf
Consistently use sc_ifp->if_mtu in the MTU check throughout the module. This backs out r228813.
r229849: o Fix panic on module unload, that happened due to mutex being destroyed prior to pfsync_uninit(). To do this, move all the initialization to the module_t method, instead of SYSINIT(9). o Fix another panic after module unload, due to not clearing the m_addr_chg_pf_p pointer. o Refuse to unload module, unless being unloaded forcibly. o Revert the sub argument to MODULE_DECLARE, to the stable/8 value.
r229850: Bunch of fixes to pfsync(4) module load/unload:
o Make the pfsync.ko actually usable. Before this change loading it didn't register protosw, so was a nop. However, a module /boot/kernel did confused users. o Rewrite the way we are joining multicast group: - Move multicast initialization/destruction to separate functions. - Don't allocate memory if we aren't going to join a multicast group. - Use modern API for joining/leaving multicast group. - Now the utterly wrong pfsync_ifdetach() isn't needed. o Move module initialization from SYSINIT(9) to moduledata_t method. o Refuse to unload module, unless asked forcibly. o Improve a bit some FreeBSD porting code: - Use separate malloc type. - Simplify swi sheduling.
r229857: Can't pass MSIZE to m_cljget(), an mbuf can't be attached as external storage to another mbuf.
r229963: Add necessary locking in pfsync_in_ureq().
r229976: Redo r226660: - Define schednetisr() to swi_sched. - In the swi handler check if there is some data prepared, and if true, then call pfsync_sendout(), however tell it not to schedule swi again. - Since now we don't obtain the pfsync lock in the swi handler, don't use ifqueue mutex to synchronize queue access.
r229773, r229851, r229959, r229961, r229962, r229964 - minor cleanups.
|
230867 |
01-Feb-2012 |
pluknet |
MFC r230545: Clarify and improve the boot menu with some small changes.
PR: misc/160818 Submitted by: Warren Block <wblock wonkity com>
|
230849 |
31-Jan-2012 |
ken |
MFC: 230000, 230544
Fix a race condition in CAM peripheral free handling, locking in the CAM XPT bus traversal code, and a number of other periph level issues.
r230544 | ken | 2012-01-25 10:58:47 -0700 (Wed, 25 Jan 2012) | 9 lines
Fix a bug introduced in r230000. We were eliminating all LUNs on a target in response to CAM_DEV_NOT_THERE, instead of just the LUN in question.
This will now just eliminate the specified LUN in response to CAM_DEV_NOT_THERE.
Reported by: Richard Todd <rmtodd@servalan.servalan.com>
r230000 | ken | 2012-01-11 17:41:48 -0700 (Wed, 11 Jan 2012) | 72 lines
Fix a race condition in CAM peripheral free handling, locking in the CAM XPT bus traversal code, and a number of other periph level issues.
cam_periph.h, cam_periph.c: Modify cam_periph_acquire() to test the CAM_PERIPH_INVALID flag prior to allowing a reference count to be gained on a peripheral. Callers of this function will receive CAM_REQ_CMP_ERR status in the situation of attempting to reference an invalidated periph. This guarantees that a peripheral scheduled for a deferred free will not be accessed during its wait for destruction.
Panic during attempts to drop a reference count on a peripheral that already has a zero reference count.
In cam_periph_list(), use a local sbuf with SBUF_FIXEDLEN set so that mallocs do not occur while the xpt topology lock is held, regardless of the allocation policy of the passed in sbuf.
Add a new routine, cam_periph_release_locked_buses(), that can be called when the caller already holds the CAM topology lock.
Add some extra debugging for duplicate peripheral allocations in cam_periph_alloc().
Treat CAM_DEV_NOT_THERE much the same as a selection timeout (AC_LOST_DEVICE is emitted), but forgo retries.
cam_xpt.c: Revamp the way the EDT traversal code does locking and reference counting. This was broken, since it assumed that the EDT would not change during traversal, but that assumption is no longer valid.
So, to prevent devices from going away while we traverse the EDT, make sure we properly lock everything and hold references on devices that we are using.
The two peripheral driver traversal routines should be examined. xptpdperiphtraverse() holds the topology lock for the entire time it runs. xptperiphtraverse() is now locked properly, but only holds the topology lock while it is traversing the list, and not while the traversal function is running.
The bus locking code in xptbustraverse() should also be revisited at a later time, since it is complex and should probably be simplified.
scsi_da.c: Pay attention to the return value from cam_periph_acquire().
Return 0 always from daclose() even if the disk is now gone.
Add some rudimentary error injection support.
scsi_sg.c: Fix reference counting in the sg(4) driver.
The sg driver was calling cam_periph_release() on close, but never called cam_periph_acquire() (which increments the reference count) on open.
The periph code correctly complained that the sg(4) driver was trying to decrement the refcount when it was already 0.
Sponsored by: Spectra Logic
|
230799 |
31-Jan-2012 |
attilio |
MFC r227758,227759,227788: Introduce macro stubs in the mutex and sxlock implementation that will be always defined and will allow consumers, willing to provide options, file and line to locking requests, to not worry about options redefining the interfaces. This is typically useful when there is the need to build another locking interface on top of the mutex one.
Requested by: kib
|
230788 |
30-Jan-2012 |
jhibbits |
MFC r228270,228277:
Add a devd notification for closing/opening the lid on PowerBooks and iBooks.
Approved by: nwhitehorn (mentor)
|
230769 |
30-Jan-2012 |
pluknet |
MFC r230531: Remove unused variable.
|
230760 |
29-Jan-2012 |
mckusick |
MFC r230101:
Convert FFS mount error messages from kernel printf's to using the vfs_mount_error error message facility provided by the nmount interface.
Clean up formatting of mount warnings which still need to use kernel printf's since they do not return errors.
Requested by: Craig Rodrigues <rodrigc@crodrigues.org>
|
230751 |
29-Jan-2012 |
jhibbits |
MFC r226449:
Add support for special keys (volume/brightness/eject) on Apple laptops with ADB keyboards.
Approved by: nwhitehorn (mentor)
|
230746 |
29-Jan-2012 |
marius |
MFC: r228858
Update a comment to reflect reality and explain why we're using the medany code model.
|
230740 |
29-Jan-2012 |
marius |
MFC: r228211
It doesn't make much sense to check whether child is NULL after already having dereferenced it. We either should generally check the device_t's supplied to bus functions before using them (which we seem to virtually never do) or just assume that they are not NULL. While at it make this code fit 78 columns.
Found with: Coverity Prevent(tm) CID: 4230
|
230738 |
29-Jan-2012 |
marius |
MFC: r228209
- In device_probe_child(9) check the return value of device_set_driver(9) when actually setting a driver as especially ENOMEM is fatal in these cases. - Annotate other calls to device_set_devclass(9) and device_set_driver(9) without the return value being checked and that are okay to fail.
Reviewed by: yongari (slightly earlier version)
|
230736 |
29-Jan-2012 |
marius |
MFC: r228027
Move the scsi_da_bios_params() prototype from pc98_machdep.h to md_var.h where the prototype for pc98_ata_disk_firmware_geom_adjust() also lives in order to avoid an #ifdef'ed include in cam(4).
|
230734 |
29-Jan-2012 |
marius |
MFC: r228024
Update comment.
|
230733 |
29-Jan-2012 |
marius |
MFC: r228005
Change another instance of amd(4) to esp(4) missed in r227006 (MFC'ed to stable/9 in r227305).
Submitted by: Garrett Cooper
|
230725 |
29-Jan-2012 |
mckusick |
MFC r230249:
Make sure all intermediate variables holding mount flags (mnt_flag) and that all internal kernel calls passing mount flags are declared as uint64_t so that flags in the top 32-bits are not lost.
MFC r230250:
There are several bugs/hangs when trying to take a snapshot on a UFS/FFS filesystem running with journaled soft updates. Until these problems have been tracked down, return ENOTSUPP when an attempt is made to take a snapshot on a filesystem running with journaled soft updates.
|
230719 |
29-Jan-2012 |
marius |
MFC: r227912
- Just use cam_calc_geometry(9) on newer version of FreeBSD rather than duplicating it. - In hptmv(4) and hptrr(4) use __FBSDID and DEVMETHOD_END.
|
230717 |
29-Jan-2012 |
marius |
MFC: r227907, r22791 (for diff reduction)
Add BCM5785 but wrap it in #ifdef notyet for now. According to yongari@ there are issues probably needing workarounds in bge(4) when brgphy(4) handles this PHY. Letting ukphy(4) handle it instead results in a working configuration, although likely with performance penalties.
|
230716 |
29-Jan-2012 |
marius |
MFC: r227906
Sync with NetBSD rev. 1.104
Obtained from: NetBSD
|
230711 |
29-Jan-2012 |
marius |
MFC: r227688
There's no need export the device interface methods of miibus(4).
|
230709 |
29-Jan-2012 |
marius |
MFC: r227687, r228290
- Add a hint.miibus.X.phymask hint, allowing do individually exclude PHY addresses from being probed and attaching something including ukphy(4) to it. This is mainly necessarily for PHY switches that create duplicate or fake PHYs on the bus that can corrupt the PHY state when accessed or simply cause problems when ukphy(4) isolates the additional instances. - Change miibus(4) to be a hinted bus, allowing to add child devices via hints and to set their attach arguments (including for automatically probed PHYs). This is mainly needed for PHY switches that violate IEEE 802.3 and don't even implement the basic register set so we can't probe them automatically. However, the ability to alter the attach arguments for automatically probed PHYs is also useful as for example it allows to test (or tell a user to test) new variant of a PHY with a specific driver by letting an existing driver attach to it via manipulating the IDs without the need to touch the source code or to limit a Gigabit Ethernet PHY to only announce up to Fast Ethernet in order to save energy by limiting the capability mask. Generally, a driver has to be hinted via hint.phydrv.X.at="miibusY" and hint.phydrv.X.phyno="Z" (which already is sufficient to add phydrvX at miibusY at PHY address Z). Then optionally the following attach arguments additionally can be configured: hint.phydrv.X.id1 hint.phydrv.X.id2 hint.phydrv.X.capmask - Some minor cleanup.
Reviewed by: adrian, ray
|
230707 |
29-Jan-2012 |
marius |
MFC: r227686
There's no need to read DC_10BTSTAT twice in dcphy_status().
|
230705 |
29-Jan-2012 |
marius |
MFC: r227685
- There's no need to ignore the return value of mii_attach(9) when attaching dcphy(4) (CID 9283). - In dc_detach(), check whether ifp is NULL as dc_attach() may call the former without ifp being allocated (CID 4288).
Found with: Coverity Prevent(tm)
|
230703 |
29-Jan-2012 |
marius |
MFC: r227043
Sprinkle some const.
|
230701 |
29-Jan-2012 |
marius |
MFC: r226950
Add multiple inclusion protection.
|
230699 |
29-Jan-2012 |
marius |
MFC: r226948
Remove unnecessary DMA constraints.
|
230697 |
29-Jan-2012 |
marius |
MFC: r226270
- Remove unused remnants of MII bitbang'ing. - Sprinkle const.
|
230695 |
29-Jan-2012 |
marius |
MFC: r226175
In device_get_children() avoid malloc(0) in order to increase portability to other operating systems.
PR: 154287
|
230694 |
29-Jan-2012 |
marius |
MFC: r226171
Sprinkle const.
|
230691 |
29-Jan-2012 |
marius |
MFC: r226057
- Currently, sched_balance_pair() may cause a CPU to send an IPI_PREEMPT to itself, which sparc64 hardware doesn't support. One way to solve this would be to directly call sched_preempt() instead of issuing a self-IPI. However, quoting jhb@: "On the other hand, you can probably just skip the IPI entirely if we are going to send it to the current CPU. Presumably, once this routine finishes, the current CPU will exit softlock (or will do so "soon") and will then pick the next thread to run based on the adjustments made in this routine, so there's no need to IPI the CPU running this routine anyway. I think this is the better solution. Right now what is probably happening on other platforms is as soon as this routine finishes the CPU processes its self-IPI and causes mi_switch() which will just switch back to the softclock thread it is already running." - With r226054 (MFC'ed to stable/9 in r230690) and the the above change in place, sparc64 now no longer is incompatible with ULE and vice versa. However, powerpc/E500 still is.
Submitted by: jhb Reviewed by: jeff
|
230690 |
29-Jan-2012 |
marius |
MFC: r226054
- Use atomic operations rather than sched_lock for safely assigning pm_active and pc_pmap for SMP. This is key to allowing adding support for SCHED_ULE. Thanks go to Peter Jeremy for additional testing. - Add support for SCHED_ULE to cpu_switch().
|
230687 |
29-Jan-2012 |
marius |
MFC: r225931, r225932, r227000
Make sparc64 compatible with NEW_PCIB and enable it: - Implement bus_adjust_resource() methods as far as necessary and in non-PCI bridge drivers as far as feasible without rototilling them. - As NEW_PCIB does a layering violation by activating resources at layers above pci(4) without previously bubbling up their allocation there, move the assignment of bus tags and handles from the bus_alloc_resource() to the bus_activate_resource() methods like at least the other NEW_PCIB enabled architectures do. This is somewhat unfortunate as previously sparc64 (ab)used resource activation to indicate whether SYS_RES_MEMORY resources should be mapped into KVA, which is only necessary if their going to be accessed via the pointer returned from rman_get_virtual() but not for bus_space(9) as the later always uses physical access on sparc64. Besides wasting KVA if we always map in SYS_RES_MEMORY resources, a driver also may deliberately not map them in if the firmware already has done so, possibly in a special way. So in order to still allow a driver to decide whether a SYS_RES_MEMORY resource should be mapped into KVA we let it indicate that by calling bus_space_map(9) with BUS_SPACE_MAP_LINEAR as actually documented in the bus_space(9) page. This is implemented by allocating a separate bus tag per SYS_RES_MEMORY resource and passing the resource via the previously unused bus tag cookie so we later on can call rman_set_virtual() in sparc64_bus_mem_map(). As a side effect this now also allows to actually indicate that a SYS_RES_MEMORY resource should be mapped in as cacheable and/or read-only via BUS_SPACE_MAP_CACHEABLE and BUS_SPACE_MAP_READONLY respectively. - Do some minor cleanup like taking advantage of rman_init_from_resource(), factor out the common part of bus tag allocation into a newly added sparc64_alloc_bus_tag(), hook up some missing newbus methods and replace some homegrown versions with the generic counterparts etc. - While at it, let apb_attach() (which can't use the generic NEW_PCIB code as APB bridges just don't have the base and limit registers implemented) regarding the config space registers cached in pcib_softc and the SYSCTL reporting nodes set up.
|
230683 |
28-Jan-2012 |
marius |
MFC: r225901
Remove obsolete macros.
|
230682 |
28-Jan-2012 |
marius |
MFC: r225900
Nuke SUN4U #ifdef's which with the demise of sun4v no longer serve any purpose.
|
230680 |
28-Jan-2012 |
marius |
MFC: r225899
Also allocate space for the PIL counters. Given that no machine actually uses IV_MAX interrupt vectors this wasn't a problem in practice though.
|
230677 |
28-Jan-2012 |
marius |
MFC: r225891
Re-reading the Schizo errata suggests that it's actually tolerable to also use the streaming buffer of pre version 5/revision 2.3 hardware as long as we stay away from context flushes (which iommu(4) so far doesn't take advantage of). OpenSolaris does the same.
|
230675 |
28-Jan-2012 |
marius |
MFC: r225890
- Add protective parentheses to macros as far as possible. - Move {r,w,}mb() to the top of this file where they live on most of the other architectures.
|
230673 |
28-Jan-2012 |
marius |
MFC: r225889, r228222
In total store which we use for running the kernel and all of the userland atomic operations behave as if they were followed by a CPU memory barrier so there's no need to include ones in the acquire variants of atomic(9) and it's sufficient to just use include compiler memory barriers to satisfy the requirements of atomic(9). Removing the CPU memory barriers results in a small performance improvement, specifically this is sufficient to compensate the performance loss seen in the worldstone benchmark seen when using SCHED_ULE instead of SCHED_4BSD. This change is inspired by Linux even more radically doing the equivalent thing some time ago. Thanks go to Peter Jeremy for additional testing.
|
230671 |
28-Jan-2012 |
marius |
MFC: r225888
Add a comment about why contrary to what once would think running all of userland with total store order actually is appropriate.
|
230669 |
28-Jan-2012 |
marius |
MFC: r225887
Use the extended integer condition code when comparing 64-bit values. Given that ATOMIC_INC_LONG currently is unused this happened to not be fatal.
|
230667 |
28-Jan-2012 |
marius |
MFC: r225886
- Right-justify backslashes as suggested by style(9). - Rename ATOMIC_INC_ULONG to ATOMIC_INC_LONG in order to be consistent with the names of the other macros in this file an adjust accordingly.
|
230665 |
28-Jan-2012 |
marius |
MFC: r228022, r228026
For sparc64 also adjust the geometry of da(4) driven disks to not overflow the 16-bit cylinders field of the VTOC8 disk label (at around 502GB). The geometry chosen for disks above that limit allows to use disks up to 2TB, which is the limit of the extended VTOC8 format. The geometry used for disks smaller than the 16-bit cylinders limit stays the same as used by cam_calc_geometry(9) for extended translation. Thanks to Hans-Joerg Sirtl for providing hardware for testing this change.
|
230637 |
28-Jan-2012 |
rmacklem |
MFC: r230100 Tai Horgan reported via email that there were two places in the new NFSv4 server where the code follows the wrong list. Fortunately, for these fairly rare cases, the lc_stateid[] lists are normally empty. This patch fixes the code to follow the correct list.
|
230607 |
27-Jan-2012 |
pluknet |
MFC r230496: Remove the stale XXX rt_newaddrmsg comment.
|
230604 |
27-Jan-2012 |
qingli |
MFC 227460
A default route learned from the RAs could be deleted manually after its installation. This removal may be accidental and can prevent the default route from being installed in the future if the associated default router has the best preference. The cause is the lack of status update in the default router on the state of its route installation in the kernel FIB. This patch fixes the described problem.
Reviewed by: hrs, discussed with hrs
|
230518 |
25-Jan-2012 |
rmacklem |
MFC: r229956 jwd@ reported via email that the "CacheSize" field reported by "nfsstat -e -s" would go negative after using the "-z" option to zero out the stats. This patch fixes that by not zeroing out the srvcache_size field for "-z", since it is the size of the cache and not a counter
|
230497 |
24-Jan-2012 |
pluknet |
MFC r230256: Fix the "lock &zrl->zr_mtx already initialized" assertion by initializing the allocated memory before calling mtx_init(9) on mtx pointing to it. Otherwize, random contents of uninitialized memory might occasionally trigger the assertion.
Reported by: Pavel Polyakov <bsd kobyla org> Reviewed by: pjd
|
230485 |
23-Jan-2012 |
jh |
MFC r229694:
r222004 changed sbuf_finish() to not clear the buffer error status. As a consequence sbuf_len() will return -1 for buffers which had the error status set prior to sbuf_finish() call. This causes a problem in pfs_read() which purposely uses a fixed size sbuf to discard bytes which are not needed to fulfill the read request.
Work around the problem by using the full buffer length when sbuf_finish() indicates an overflow. An overflowed sbuf with fixed size is always full.
PR: kern/163076
|
230462 |
22-Jan-2012 |
jh |
MFC r229692:
Check the return value of sbuf_finish() in pfs_readlink() and return ENAMETOOLONG if the buffer overflowed.
|
230446 |
22-Jan-2012 |
rmacklem |
MFC: r229802 opt_inet6.h was missing from some files in the new NFS subsystem. The effect of this was, for clients mounted via inet6 addresses, that the DRC cache would never have a hit in the server. It also broke NFSv4 callbacks when an inet6 address was the only one available in the client. This patch fixes the above, plus deletes opt_inet6.h from a couple of files it is not needed for.
|
230435 |
21-Jan-2012 |
alc |
MFC r228923, r228935, and r229007 Eliminate many of the unnecessary differences between the native and paravirtualized pmap implementations for i386.
Fix a bug in the Xen pmap's implementation of pmap_extract_and_hold(): If the page lock acquisition is retried, then the underlying thread is not unpinned.
Wrap nearby lines that exceed 80 columns.
Merge r216333 and r216555 from the native pmap When r207410 eliminated the acquisition and release of the page queues lock from pmap_extract_and_hold(), it didn't take into account that pmap_pte_quick() sometimes requires the page queues lock to be held. This change reimplements pmap_extract_and_hold() such that it no longer uses pmap_pte_quick(), and thus never requires the page queues lock.
Merge r177525 from the native pmap Prevent the overflow in the calculation of the next page directory. The overflow causes the wraparound with consequent corruption of the (almost) whole address space mapping.
Strictly speaking, r177525 is not required by the Xen pmap because the hypervisor steals the uppermost region of the normal kernel address space. I am nonetheless merging it in order to reduce the number of unnecessary differences between the native and Xen pmap implementations.
|
230431 |
21-Jan-2012 |
alc |
MFC r228746 The Xen pmap doesn't support superpages. So, there is no point in it initializing structures, like the pv table, that are only used to implement superpages. In fact, some of the unnecessary code in pmap_init() was actually doing harm. It was preventing the kernel from booting on virtual machines with more than 768 MB of memory.
|
230425 |
21-Jan-2012 |
rmh |
MFC r227827 Define __FreeBSD_kernel__ macro in sys/param.h.
__FreeBSD_kernel__ indicates that this system uses the kernel of FreeBSD, which by definition is always true on FreeBSD. This macro is also defined on other systems that use the kernel of FreeBSD, such as GNU/kFreeBSD.
It is tempting to use this macro in userland code when we want to enable kernel-specific routines, and in fact it's fine to do this in code that is part of FreeBSD itself. However, be aware that as presence of this macro is still not widespread (e.g. older FreeBSD versions, 3rd party compilers, etc), it is STRONGLY DISCOURAGED to check for this macro in external applications without also checking for __FreeBSD__ as an alternative.
Approved by: kib (mentor)
|
230421 |
21-Jan-2012 |
alc |
MFC r228398 Avoid the possibility of integer overflow in the calculation of VM_KMEM_SIZE_MAX. Specifically, if the user/kernel address space split was changed such that the kernel address space was greater than or equal to 2 GB, then overflow would occur.
PR: 161721
|
230418 |
21-Jan-2012 |
alc |
MFC r226163, r228317, and r228324 Fix the handling of an empty kmem map by sysctl_kmem_map_free().
Eliminate the possibility of 32-bit arithmetic overflow in the calculation of vm_kmem_size that may occur if the system administrator has specified a vm.vm_kmem_size tunable value that exceeds the hard cap.
Eliminate stale numbers from a comment.
PR: 162741
|
230320 |
18-Jan-2012 |
gnn |
MFC: 229965
Fix for PR 138526.
Add the ability for /dev/null and /dev/zero to accept being set into non blocking mode via fcntl(). This brings the code into compliance with IEEE Std 1003.1-2001 as referenced in another PR, 94729.
Reviewed by: jhb
|
230305 |
18-Jan-2012 |
jhibbits |
MFC r228869,r228874:
Implement hwpmc counting PMC support for PowerPC G4+ (MPC745x/MPC744x). Sampling is in progress.
Approved by: nwhitehorn (mentor)
|
230302 |
18-Jan-2012 |
hselasky |
MFC r230032, r230050, r230090, r230091 and r228493. - Various XHCI and USB 3.0 related issues. - USB 3.0 HUBs should work after this change.
|
230290 |
17-Jan-2012 |
jhibbits |
MFC r230035:
Add PWM monitoring sysctl to G4 MDD (Windtunnel) fan driver. While there, clean up some style nits.
|
230266 |
17-Jan-2012 |
gavin |
Merge r229085 from head:
Default to not performing the early-boot memory tests when we detect we are booting inside a VM. There are three reasons to disable this:
o It causes the VM host to believe that all the tested pages or RAM are in use. This in turn may force the host to page out pages of RAM belonging to other VMs, or otherwise cause problems with fair resource sharing on the VM cluster. o It adds significant time to the boot process (around 1 second/Gig in testing) o It is unnecessary - the host should have already verified that the memory is functional etc.
Note that this simply changes the default when in a VM - it can still be overridden using the hw.memtest.tests tunable.
Early MFC requested by: bz
|
230219 |
16-Jan-2012 |
pluknet |
MFC r228985,229881:
Unset the environment variables associated with individual menu items before invoking the kernel.
Get rid of a spurious warning on the console when booting the kernel from the interactive loader(8) prompt and beastie_disable="YES" is set in loader.conf(5).
Submitted by: Devin Teske <devin dott teske fisglobal.com>
|
230175 |
15-Jan-2012 |
avg |
MFC r228265: critical_exit: ignore td_owepreempt if kdb_active is set
|
230173 |
15-Jan-2012 |
avg |
MFC r228718: ule: ensure that batch timeshare threads are scheduled fairly
|
230171 |
15-Jan-2012 |
avg |
MFC r228710: opensolaris compat: fix vcmn_err so that panic(9) produces a proper message
|
230169 |
15-Jan-2012 |
avg |
MFC r228426: syscons: make sc_puts static as it is used only privately
|
230167 |
15-Jan-2012 |
avg |
MFC r228430,228433: put sys/systm.h at its proper place or add it if missing
|
230165 |
15-Jan-2012 |
avg |
MFC r228267: zfsboot: print boot.config contents before parsing it
|
230163 |
15-Jan-2012 |
avg |
MFC r228266: zfs boot: allow file vdevs to be used in testing (e.g. with zfsboottest)
|
230086 |
13-Jan-2012 |
jhb |
MFC 229665,229672,229700: Remove the assertion from tcp_input() that rcv_nxt is always greater than or equal to rcv_adv and fix tcp_twstart() to handle this case by assuming the last window was zero rather than a negative value.
The code in tcp_input() already safely handled this case. It can happen due to delayed ACKs along with a remote sender that sends data beyond the window we previously advertised. If we have room in our socket buffer for the extra data beyond the advertised window, we will accept it. However, if the ACK for that segment is delayed, then we will not effectively fixup rcv_adv to account for that extra data until the next segment arrives and forces out an ACK. When that next segment arrives, rcv_nxt will be beyond rcv_adv.
|
230085 |
13-Jan-2012 |
jhb |
MFC 228961: Further relax the strictness of enforcing allocations to only come from decoded ranges. Pass any request for a specific range that fails because it is not in a decoded range for an ACPI Host-PCI bridge up to the parent to see if it can still be allocated. This is based on the assumption that many BIOSes are inconsistent/broken and that settings programmed into BARs or resources assigned to other built-in components are more trustworthy than the list of decoded resource ranges in _CRS. This effectively limits the decoded ranges to only being used for "wildcard" ranges when allocating fresh resources for a BAR, etc. At some point I would like to only be this permissive during an early scan of firmware-assigned resources during boot and to be strict about all later allocations, but that isn't viable currently.
|
230083 |
13-Jan-2012 |
jhb |
MFC 228960: Cap the priority calculated from the current thread's running tick count at SCHED_PRI_RANGE to prevent overflows in the priority value. This can happen due to irregularities with clock interrupts under certain virtualization environments.
|
230081 |
13-Jan-2012 |
jhb |
MFC 229519: Fix 'make clean' for this module so it cleans up the generated gssd.h.
|
230079 |
13-Jan-2012 |
jhb |
MFC 229429: Some small fixes to CPU accounting for threads: - Only initialize the per-cpu switchticks and switchtime in sched_throw() for the very first context switch on APs during boot. This avoids a small gap between the middle of thread_exit() and sched_throw() where time is not accounted to any thread. - In thread_exit(), update the timestamp bookkeeping to track the changes to mi_switch() introduced by td_rux so that the code once again matches the comment claiming it is mimicing mi_switch(). Specifically, only update the per-thread stats directly and depend on ruxagg() to update p_rux rather than adjusting p_rux directly. While here, move the timestamp bookkeeping as late in the function as possible.
|
230078 |
13-Jan-2012 |
jhb |
MFC 229427: 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).
|
230076 |
13-Jan-2012 |
jhb |
MFC 229390,229420,229479: Fix some races in the multicast code by removing places where we would drop the IF_ADDR_LOCK while walking an interface's multicast address list: - Use TAILQ_FOREACH() instead of TAILQ_FOREACH_SAFE() for some loops that do not modify the queues they iterate over. - 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 a pending release list and then releasing the references after dropping the IF_ADDR_LOCK. - Use the mli_relinmhead list normally used to defer calls to in6m_release_locked() to defer calls to mld_v1_transmit_report() until after the IF_ADDR_LOCK is dropped.
|
230074 |
13-Jan-2012 |
jhb |
MFC 229414,229476,229477: Various fixes to the SIOC[DG]LIFADDR ioctl handlers: - Grab a reference on any matching interface address (ifa) before dropping the IF_ADDR_LOCK() and release the reference after using it to prevent a potential use-after-free. - Fix the IPv4 ioctl handlers in in_lifaddr_ioctl() to work with IPv4 interface addresses rather than IPv6. - Add missing interface address list locking in the IPv4 handlers.
|
230072 |
13-Jan-2012 |
jhb |
MFC 229400: 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.
|
230071 |
13-Jan-2012 |
jhb |
MFC 229728: Add 5 spare VOPs as placeholders to avoid breaking the KBI in the future when new VOPs are MFC'd to a branch.
|
230069 |
13-Jan-2012 |
jhb |
MFC 229622: Fix a logic bug in change 228207 in the check for a thread's new user priority being a realtime priority.
|
230067 |
13-Jan-2012 |
jhb |
MFC 228849, 229727: Add post-VOP hooks for VOP_DELETEEXTATTR() and VOP_SETEXTATTR() and use these to trigger a NOTE_ATTRIB EVFILT_VNODE kevent when the extended attributes of a vnode are changed.
|
230065 |
13-Jan-2012 |
jhb |
MFC 228738: Allow boot0cfg to force a PXE boot via boot0 on the next boot. - Fix boot0 to check for PXE when using the pre-set setting for the preferred slice. - Update boot0cfg to use slice 6 to select PXE. Accept a 'pxe' argument instead of a number for the 's' option as a way to select PXE as well.
|
230019 |
12-Jan-2012 |
mav |
MFC r228461: Fix few bugs in isp(4) target mode support: - in destroy_lun_state() assert hold == 1 instead of 0, as it should receive hold taken by the create_lun_state() or get_lun_statep() before; - fix hold count leak inside rls_lun_statep() that also fired above assert; - in destroy_lun_state() use SIM bus number instead of SIM path id for ISP_GET_PC_ADDR(), as it was before r196008; - make isp_disable_lun() to set status in CCB; - make isp_target_mark_aborted() set status into the proper CCB.
Reviewed by: mjacob Sponsored by: iXsystems, inc.
|
230014 |
12-Jan-2012 |
mav |
MFC r228808, r228847, 229395:
r228808, r228847: Make cd driver to handle Audio CDs, reporting their 2352 bytes sectors to GEOM and using READ CD command for reading data, same as acd driver does. Audio CDs identified by checking respective bit of the control field of the first track in TOC.
229395: 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 Sponsored by: iXsystems, Inc.
|
230012 |
12-Jan-2012 |
jhb |
MFC 228715: Add a TASK_INITIALIZER() macro that can be used to statically initialize a task structure.
|
229973 |
11-Jan-2012 |
mav |
MFC r228726, r228727: Cast some vendor-specific spell on VIA VT1708S codecs to: - make analog input loopback work; - get access to the mics boost controls.
Sponsored by: iXsystems, Inc.
|
229953 |
11-Jan-2012 |
rmacklem |
MFC: r228827 During investigation of an NFSv4 client crash reported by glebius@, jhb@ spotted that nfscl_getstateid() might modify credentials when called from nfsrpc_read() for the case where p != NULL, whereas nfsrpc_read() only did a crdup() to get new credentials for p == NULL. This bug was introduced by r195510, since pre-r195510 nfscl_getstateid() only modified credentials for the p == NULL case. This patch modifies nfsrpc_read()/nfsrpc_write() so that they do crdup() for the p != NULL case. It is conceivable that this bug caused the crash reported by glebius@, but that will not be determined for some time, since the crash occurred after about 1month of operation.
|
229935 |
10-Jan-2012 |
jh |
MFC r228021:
Add LINT-NOINET LINT-NOINET6 and LINT-NOIP to the make clean target. This was missed in r221353.
|
229929 |
10-Jan-2012 |
pho |
MFC: r227550, r227576
Handle invalid large values for getdirentries(2) data buffer size. Fix build, use %d for int value formatting.
|
229902 |
10-Jan-2012 |
rmacklem |
MFC: r228757 jwd@ reported a problem via email where the old NFS client would get a reply of EEXIST from an NFS server when a Mkdir RPC was retried, for an NFS over UDP mount. Upon investigation, it was found that the client was retransmitting the Mkdir RPC request over UDP, but with a different xid. As such, the retransmitted message would miss the Duplicate Request Cache in the server, causing it to reply EEXIST. The kernel client side UDP rpc code has two timers. The first one causes a retransmit using the same xid and socket and was set to a fixed value of 3seconds. (The default can be overridden via CLSET_RETRY_TIMEOUT.) The second one creates a new socket and xid and should be larger than the first. However, both NFS clients were setting the second timer to nm_timeo ("timeout=<value>" mount argument), which defaulted to 1second, so the first timer would never time out. This patch fixes both NFS clients so that they set the first timer using nm_timeo and makes the second timer larger than the first one.
|
229885 |
09-Jan-2012 |
thompsa |
MFC r226324
Dont just set the pin high when turning on output, use the current value. Also let this value be set when in input mode.
|
229883 |
09-Jan-2012 |
thompsa |
MFC r226034
Add missing newbus glue, this has never attached properly to gpiobus.
|
229882 |
09-Jan-2012 |
thompsa |
MFC r225955
Allow ixp425 boot2 to compile after r219452
|
229874 |
09-Jan-2012 |
yongari |
MFC r228717: Increase wait time for OP_TCPSTART command processing. It seems 100us is not enough to ensure prefetch unit work.
|
229870 |
09-Jan-2012 |
yongari |
MFC r228716: TCP header size is represented by number of 32bits words. Fix the TCP header size calculation such that makes TSO engine cache all header(ethernet/IP/TCP) bytes to its internal buffer. While here, remove extra pull up for TCP payload. Unlike some em(4) controllers, fxp(4) does not require such work around for TSO. The two limitations are ethernet/IP/TCP header size should be less than or equal to the size of controller's internal buffer(80 bytes) and these header information should be found in the first fragment of a TSO frame.
|
229867 |
09-Jan-2012 |
yongari |
MFC r228479-228480: r228479: BCM5720 performance tweak from Broadcom. o Allow multiple outstanding read requests from non-LSO read DMA engine. o Allow 4KB burst length reads for non-LSO frames. o Enable 512B burst length reads for buffer descriptors.
r228480: Destroy DMA tag for jumbo RX buffer in device detach.
|
229864 |
09-Jan-2012 |
yongari |
MFC r228476: Rework link state tracking and remove superfluous link UP/DOWN messages. o Add check for actually resolved speed in miibus_statchg callback instead of blindly reprogramming BCE_EMAC_MODE register. The callback may be called multiple times(e.g. link UP, link transition, auto-negotiate complete etc) while auto-negotiation is in progress. All unresolved link state changes are ignored now and setting BCE_EMAC_MODE after link establishment is done once. o bce(4) is careful enough not to drive MII_TICK if driver got a valid link. To detect lost link, bce(4) relied on link state change interrupt and if driver see the interrupt, it forced to drive MII_TICK by calling bce_tick() in interrupt handler. Because bce(4) generates multiple link state change interrupts while auto-negotiation is in progress, bce_tick() would be called multiple times and this resulted in generating multiple link UP/DOWN messages. With this change, bce_tick() is not called in interrupt handler anymore such that miibus_statchg callback handles link state changes with consistent manner.
|
229858 |
09-Jan-2012 |
jh |
MFC r227823, r228163:
Append unit number to the WMI status device name to allow attaching multiple acpi_wmi(4) instances.
PR: kern/162491
|
229855 |
09-Jan-2012 |
ivoras |
MFC r227822: Avoid panics from recursive rename operations.
PR: kern/159418
|
229827 |
08-Jan-2012 |
rmacklem |
MFC: r228560 Patch the new NFS server in a manner analagous to r228520 for the old NFS server, so that it correctly handles a count == 0 argument for Commit.
|
229799 |
08-Jan-2012 |
rmacklem |
MFC: r228260 This patch adds a sysctl to the NFSv4 server which optionally disables the check for a UTF-8 compliant file name. Enabling this sysctl results in an NFSv4 server that is non-RFC3530 compliant, therefore it is not enabled by default. However, enabling this sysctl results in NFSv3 compatible behaviour and fixes the problem reported by "dan at sunsaturn.com" to freebsd-current@ on Nov. 14, 2011 under the subject "NFSV4 readlink_stat".
|
229770 |
07-Jan-2012 |
glebius |
Merge from head/ 228732,228811,228813-228816,228855:
r228732 | glebius | 2011-12-20 16:34:16 +0400 (вт, 20 дек 2011) | 3 lines
- Cover pfsync callouts deletion with PF_LOCK(). - Cover setting up interface between pf and pfsync with PF_LOCK().
r228811 | glebius | 2011-12-22 22:31:47 +0400 (чт, 22 дек 2011) | 3 lines
In FreeBSD we always have bpf(4) API, either real or stub. No need in detecting presense of 'device bpf'.
r228813 | glebius | 2011-12-22 22:51:35 +0400 (чт, 22 дек 2011) | 2 lines
We really mean MTU of the real interface here, not of our pseudo.
r228814 | glebius | 2011-12-22 22:56:27 +0400 (чт, 22 дек 2011) | 16 lines
Merge couple more fixes from OpenBSD to bulk processing:
revision 1.118 date: 2009/03/23 06:19:59; author: dlg; state: Exp; lines: +8 -6 wait an appropriate amount of time before giving up on a bulk update, rather than giving up after a hardcoded 5 seconds (which is generally much too short an interval for a bulk update). pointed out by david@, eyeballed by mcbride@
revision 1.171 date: 2011/10/31 22:02:52; author: mikeb; state: Exp; lines: +2 -1 Don't forget to cancel bulk update failure timeout when destroying an interface. Problem report and fix from Erik Lax, thanks!
Start a brief note of revisions merged from OpenBSD.
r228815 | glebius | 2011-12-22 23:05:58 +0400 (чт, 22 дек 2011) | 12 lines
Merge from OpenBSD: revision 1.120 date: 2009/04/04 13:09:29; author: dlg; state: Exp; lines: +5 -5 use time_uptime instead of time_second internally. time_uptime isnt affected by adjusting the clock.
revision 1.175 date: 2011/11/25 12:52:10; author: dlg; state: Exp; lines: +3 -3 use time_uptime to set state creation values as time_second can be skewed at runtime by things like date(1) and ntpd. time_uptime is monotonic and therefore more useful to compare against.
r228816 | glebius | 2011-12-22 23:09:55 +0400 (чт, 22 дек 2011) | 11 lines
Merge from OpenBSD: revision 1.122 date: 2009/05/13 01:01:34; author: dlg; state: Exp; lines: +6 -4 only keep track of the number of updates on tcp connections. state sync on all the other protocols is simply pushing the timeouts along which has a resolution of 1 second, so it isnt going to be hurt by pfsync taking up to a second to send it over.
keep track of updates on tcp still though, their windows need constant attention.
|
229752 |
07-Jan-2012 |
rmacklem |
MFC: r228217 Post r223774, the NFSv4 client no longer has multiple instances of the same lock_owner4 string. As such, the handling of cleanup of lock_owners could be simplified. This simplification permitted the client to do a ReleaseLockOwner operation when the process that the lock_owner4 string represents, has exited. This permits the server to release any storage related to the lock_owner4 string before the associated open is closed. Without this change, it is possible to exhaust a server's storage when a long running process opens a file and then many child processes do locking on the file, because the open doesn't get closed. A similar patch was applied to the Linux NFSv4 client recently so that it wouldn't exhaust a server's storage.
|
229736 |
06-Jan-2012 |
yongari |
MFC r228333,228335-228336,228362,228368-228369,228381: r228333: Protect SIOCSIFMTU ioctl handler with driver lock. Don't blindly re-initialize controller whenever MTU is changed. Now, reinitializing is done only when driver is running.
While here, remove unnecessary assignment of error value since it was already initialized to 0.
r228335: Consistently use a tab character instead of using either a space or tab after #define. While I'm here consistently use capital letters when it uses hexadecimal notation.
No functional changes.
r228336: Disable all clocks and put PHY into COMA before entering into suspend state. This will save more power. On resume, make sure to enable all clocks. While I'm here, if controller is not fast ethernet, enable gigabit PHY.
r228362: Do not disable interrupt without knowing whether the raised interrupt is ours. Note, interrupts are automatically ACKed when the status register is read. Add RX/TX DMA error to interrupt handler and do full controller reset if driver happen to encounter these errors. There is no way to recover from these DMA errors without controller reset. Rename local variable name intrs with status to enhance readability.
While I'm here, rename ET_INTR_TXEOF and ET_INTR_RXEOF to ET_INTR_TXDMA and ET_INTR_RXDMA respectively. These interrupts indicate that a frame is successfully DMAed to controller's internal FIFO and they have nothing to do with EOF(end of frame). Driver does not need to wait actual end of TX/RX of a frame(e.g. no need to wait the end signal of TX which is generated when a frame in TX FIFO is emptied by MAC). Previous names were somewhat confusing.
r228368: Remove unnecessary definition of ET_PCIR_BAR. Controller support I/O memory only. While here, use pci_set_max_read_req(9) rather than directly manipulating PCIe device control register.
r228369: Announce flow control ability to PHY driver and enable RX flow control. Controller does not automatically generate pause frames based on number of available RX buffers so it's very hard to know when driver should generate XON frame in time. The only mechanism driver can detect low number of RX buffer condition is ET_INTR_RXRING0_LOW or ET_INTR_RXRING1_LOW interrupt. This interrupt is generated whenever controller notices the number of available RX buffers are lower than pre-programmed value( ET_RX_RING0_MINCNT and ET_RX_RING1_MINCNT register). This scheme does not provide a way to detect when controller sees enough number of RX buffers again such that efficient generation of XON/XOFF frame is not easy.
While here, add more flow control related register definition.
r228381: FreeBSD driver does not require arpcom structure in softc.
|
229723 |
06-Jan-2012 |
jhb |
MFC 227070,227341,227502: Add the posix_fadvise(2) system call. It is somewhat similar to madvise(2) except that it operates on a file descriptor instead of a memory region. It is currently only supported on regular files.
Note that this adds a new VOP, so all filesystem modules must be recompiled.
Approved by: re (kib)
|
229720 |
06-Jan-2012 |
yongari |
MFC r228326-228327,228331-228332: r228326: Controller does not require TX start command for every frame. So send a single TX command after setting up all TX frames. This removes unnecessary register accesses and bus_dmamap_sync(9) calls. et(4) uses TX interrupt moderation so it's possible to have TX buffers that were already transmitted but waiting for TX completion interrupt. If the number of available TX descriptor is less then 1/3 of total TX descriptor, try reclaiming first to get enough free TX descriptors before setting up TX descriptors. After r228325, et_txeof() no longer tries to send frames after reclaiming TX buffers. That change was made to give more chance to transmit frames in main interrupt handler since we can still send frames in interrupt handler with RX interrupt. So right before exiting interrupt hander, after enabling interrupt, try to send more frames. This gives slightly better performance numbers.
While I'm here reduce number of spare TX descriptors from 8 to 4. Controller does not require reserved TX descriptors, it was just to reduce TX overhead. After r228325, driver has much lower TX overhead so it does not make sense to reserve 8 TX descriptors.
r228327: Remove et_enable_intrs(), et_disable_intrs() functions and manipulation of interrupt register access is done through CSR_WRITE_4 macro. Also add disabling interrupt into et_reset() because we want interrupt disabled state after controller reset. While I'm here slightly change interrupt handler to be more readable one.
r228331: Rework link state tracking and TX/RX MAC configuration. o Do not report link status if driver is not running. o TX/RX MAC configuration should be done with resolved speed, duplex and flow control after establishing a link so it can't be done in driver initialization routine. Move the configuration to miibus_statchg callback which will be called whenever any link state change is detected. At this moment, flow-control is not enabled yet mainly because I was not able to set correct flow control parameters to generate TX pause frames. o Now TX/RX MAC is enabled only when a valid link is detected. Rearragnge hardware initialization routine a bit to leave enabling MAC to miibus_statchg callback. In order to that, TX/RX DMA engine is enabled in et_init_locked(). o Introduce ET_FLAG_LINK flag to track current link state. o Introduce ET_FLAG_FASTETHER flag to mark whether controller is fast ethernet. This flag is checked in miibus_statchg callback to know whether PHY established a valid link. o In et_stop(), TX/RX MAC is explicitly disabled instead of relying on et_reset(). And move et_reset() from et_stop() to controller initialization. Controler reset is not required here and it would also clear critial registers(i.e station address, RX filter configuration, WOL etc) that are required to make WOL work. o Switching to current media is done in et_init_locked() after setting IFF_DRV_RUNNING flag. This should ensure reliable auto-negotiation/manual link establishment. o In et_start_locked(), check whether driver got a valid link before trying to send frames. o Remove checking a link in et_tick() as this is done by miibus_statchg callback.
r228332: Implement hardware MAC statistics counter. Counters could be queried with dev.et.%d.stats sysctl node where %d is an instance of device.
|
229717 |
06-Jan-2012 |
yongari |
MFC r228325: Overhaul bus_dma(9) usage in et(4) and clean up TX/RX path. This change should make et(4) work on any architectures. o Remove m_getl inline function and replace it with stanard mbuf interfaces. Previous code tried to minimize code duplication but this came from incorrect use of common DMA tag. Driver may be still use a common RX allocation handler with additional structure changes but I don't see much point to do that it would make it hard to understand the code. o Remove DragonflyBSD specific constant EVL_ENCAPLEN, use ETHER_VLAN_ENCAP_LEN instead. o Add bunch of new RX status definition. It seems controller supports RX checksum offloading but I was not able to make the feature work yet. Currently driver checks whether recevied frame is good one or not. o Avoid a typedef ending in '_t' as style(9) says. o Controller has no restriction on DMA address space, so there is no reason to limit the DMA address to 32bit. Descriptor rings, status blocks and TX/RX buffers now use full 64bit DMA addressing. o Allocate DMA memory shared between host and controller as coherent. o Create 3 separate DMA tags to be used as TX, mini RX ring and stanard RX ring. Previously it created a single DMA tag and it was used to all three rings. o et(4) does not support jumbo frame at this moment and I still don't quite understand how jumbo frame works on this controller so use two RX rings to handle small sized frame and normal sized frame respectively. The mini RX ring will be used to receive frames that are less than or equal to 127 bytes. The second RX ring is used to receive frames that are not handled by the first RX ring. If jumbo frame support is implemented, driver may have to choose better RX scheme by letting the second RX ring handle jumbo frames. This scheme will mimic Broadcom's efficient jumbo frame handling feature. However RAM buffer size(16KB) of the controller is too small to hold 2 jumbo frames, if 9KB jumbo frame is used, I'm not sure how good performance would it have. o In et_rxeof(), make sure to check whether controller received good frame or not. Passing corrupted frame to upper layer is bad idea. o If driver receives a bad frame or driver fails to allocate RX buffer due to resource shortage condition, reuse previously loaded DMA map for RX buffer instead of unloading/loading RX buffer again. o et_init_tx_ring() never fails so change return type to void. o In watchdog handler, show TX DMA write back status of errored frame which could be used as a clue to debug watchdog timeout. o Add missing bus_dmamap_sync() in various places such that et(4) should work with bounce buffers(e.g. PAE). o TX side bus_dmamap_load_mbuf_sg(9) support. o RX side bus_dmamap_load_mbuf_sg(9) support. o Controller has no DMA alignment limit in RX buffer so use m_adj(9) in RX buffer allocation to make IP header align on 2 bytes boundary. Otherwise it would trigger unaligned access error in upper layer on strict alignment architectures. One of down side of controller is it provides limited set of RX buffer length like most Intel controllers. This is not problem at this moment because driver does not support jumbo frame yet but it may require alignment fixup code to support jumbo frame on strict alignment architectures. o In et_txeof(), don't zero TX descriptors for transmitted frames. TX descriptors don't need write access after transmission. Driver sets IFF_DRV_OACTIVE when the number of available TX descriptors are less than or equal to ET_NSEG_SPARE. Make sure to clear IFF_DRV_OACTIVE only when the number of available TX descriptor is greater than ET_NSEG_SPARE.
|
229711 |
06-Jan-2012 |
yongari |
MFC r228291-228293,228297-228298: r228291: Remove NetBSD license. r199548 removed all bit macros that were derived from NetBSD.
r228292: Implement suspend/resume methods. Driver has no issue with suspend/resume.
r228293: Fix alt(4) support. Also add check for number of available TX descriptors before trying to send frames. If we're not able to send a frame, make sure to prepend it to if_snd queue such that alt(4) should work.
While I'm here prefer ETHER_BPF_MTAP to BPF_MTAP. ETHER_BPF_MTAP should be used for controllers that support VLAN hardware tag insertion. The controller supports VLAN tag insertion but lacks VLAN tag stripping in RX path though.
r228297: et(4) supports VLAN oversized frame so correctly set header length. While I'm here remove initializing if_mtu, it is set by ether_ifattach(9). Also move callout_init_mtx(9) to the right below driver lock initialization.
r228298: Make et_probe() return BUS_PROBE_DEFAULT such that allow other driver that has high precedence for the controller override et(4). Add missing callout_drain(9) in device detach and rework detach routine. While I'm here use rman_get_rid(9) instead of using cached resource id because bus methods are free to change the id.
|
229708 |
06-Jan-2012 |
jhb |
MFC 228967: Update if_obytes and if_omcast after successful transmit. While I'm here update if_oerrors if parent interface of vlan is not up and running. Previously it updated collision counter and it was confusing to interprete it.
|
229678 |
06-Jan-2012 |
rmacklem |
MFC: r227796 Clean up some cruft in the NFSv4 client left over from the OpenBSD port, so that it is more readable. No logic change is made by this commit.
|
229674 |
06-Jan-2012 |
rmacklem |
MFC: r227760 Add two arguments to the nfsrpc_rellockown() function in the NFSv4 client. This does not change the client's behaviour, but prepares the code so that nfsrpc_rellockown() can be called elsewhere in a future commit.
|
229661 |
05-Jan-2012 |
jhb |
MFC 227577: The sys/sysctl.h header is needed when MFI_DEBUG is defined.
|
229648 |
05-Jan-2012 |
yongari |
MFC r228286: Fix off by one error in mbuf access. Previously it caused panic. While I'm here use NULL to compare mbuf pointer and add additional check for zero length mbuf before accessing the mbuf.
PR: kern/162932
|
229641 |
05-Jan-2012 |
yongari |
MFC r228086: Announce flow control capability to PHY drivers and enable flow control for all vr(4) controllers that support it. It's known that old vr(4) controllers(Rhine II) does not support TX pause but Rhine III supports both TX and RX pause. Make TX pause really work on Rhine III by letting controller know available RX buffers. While here, adjust XON/XOFF parameters to get better performance with flow control.
|
229637 |
05-Jan-2012 |
jhb |
MFC 228866: Fix a bug where TAILQ_FIRST(&V_ifnet) was accessed without holding the proper lock.
|
229635 |
05-Jan-2012 |
jhb |
MFC 228593: Fire a kevent if necessary after seeking on a regular file. This fixes a case where a kevent would not fire on a regular file if an application read to EOF and then seeked backwards into the file.
|
229633 |
05-Jan-2012 |
jhb |
MFC 228089: Change the if_vlan driver to use if_transmit for forwarding packets to the parent interface. This avoids the overhead of queueing a packet to an IFQ only to immediately dequeue it again.
|
229627 |
05-Jan-2012 |
jhb |
MFC 228361: Explicitly use curthread while manipulating td_fpop during last close of a devfs file descriptor in devfs_close_f(). The passed in td argument may be NULL if the close was invoked by garbage collection of open file descriptors in pending control messages in the socket buffer of a UNIX domain socket after it was closed.
|
229625 |
05-Jan-2012 |
jhb |
MFC 228496: Implement BUS_ADD_CHILD() for the isab(4) driver. It already calls bus_generic_probe() and bus_generic_attach() to handle drivers that add new children via identify methods.
|
229619 |
05-Jan-2012 |
jhb |
MFC 228207: When changing the user priority of a thread, change the real priority in addition to the user priority for threads whose current real priority is equal to the previous user priority or if the new priority is a real-time priority. This allows priority changes of other threads to have an immediate effect.
|
229617 |
05-Jan-2012 |
jhb |
MFC 228185: Enhance the sequential access heuristic used to perform readahead in the NFS server and reuse it for writes as well to allow writes to the backing store to be clustered.
|
229611 |
05-Jan-2012 |
jhb |
MFC 227562: Add single-message MSI support to mfi(4). It is disabled by default but can be enabled via the hw.mfi.msi tunable. Many mfi(4) controllers also support MSI-X, but in testing it seems that many adapters do not work with MSI-X but do work with MSI.
|
229607 |
05-Jan-2012 |
yongari |
MFC r228084: Reuse flag variable to represent driver internal states rather than using member variables in softc. While I'm here change media after setting IFF_DRV_RUNNING. This will remove unnecessary link state handling in vr_tick() if controller established a link immediately.
|
229604 |
05-Jan-2012 |
jhb |
MFC 227507: Finish making 'wcommitsize' an NFS client mount option.
|
229599 |
05-Jan-2012 |
rmacklem |
MFC: r227744 Since the nfscl_cleanup() function isn't used by the FreeBSD NFSv4 client, delete the code and fix up the related comments. This should not have any functional effect on the client.
|
229548 |
05-Jan-2012 |
rmacklem |
MFC: r227743 Post r223774 the NFSv4 client never uses the linked list with the head nfsc_defunctlockowner. This patch simply removes the code that loops through this always empty list, since the code no longer does anything useful. It should not have any effect on the client's behaviour.
|
229543 |
05-Jan-2012 |
yongari |
MFC r227842: For IP1001 PHY, do not set multi-port device(MASTER). Ideally this bit should not affect link establishment process of auto-negotiation if manual configuration is not used, which is true in auto-negotiation. However it seems setting this bit interfere with IP1001 PHY's down-shifting feature such that establishing a 10/100Mbps link failed when 1000baseT link is not available during auto-negotiation process.
|
229540 |
05-Jan-2012 |
yongari |
MFC r227828,227835,227837: r227828: Always start MII auto polling before accessing any MII registers.
r227835: Rework link establishment and link state detection logic. - Remove MIIBUS statchg callback and program VGE_DIAGCTL before initiating link establishment. Previously driver used to program VGE_DIAGCTL after getting a link in statchg callback. It seems the VGE_DIAGCTL register works like a kind of MII register such that it requires setting a 'to be' mode in advance rather than relying on resolved speed/duplex of established link. This means the statchg callback is not needed in driver. In addition, if there was no link at the time of media change, this was not called at all. - Introduce vge_ifmedia_upd_locked() to change current media to configured one. Actual media change is performed only after PHY reset and VGE_DIAGCTL setup. - In WOL configuration, make sure to clear forced mode such that controller can rely on auto-negotiation. - Unlike most other drivers that use miibus(4), vge(4) used controller's auto-polling feature for link state tracking via interrupt. This came from controller's inefficient mechanism to access MII registers. On link state change interrupt, vge(4) used to get current link state with series of MII register accesses. Because vge(4) already enabled auto polling, read PHY status register to resolved speed/duplex/flow control parameters.
vge(4) still does not drive MII_TICK to reduce number of MII register accesses which in turn means the driver does not know the status of auto-negotiation. This was a one of long standing issue of vge(4). Probably driver may be able to implement a timer that keeps track of auto-negotiation state and restart auto-negotiation when driver couldn't establish a link within a specified period. However the controller does not provide a reliable way to detect auto-negotiation failure so I'm not sure whether it's worth to implement it in driver.
Alternatively driver can completely disable MII auto-polling and let miibus(4) poll link state by driving MII_TICK. This may reduce unnecessary overhead of stopping/restarting MII auto-polling of controller. Unfortunately it was known that some variants of controller does not work correctly if MII auto-polling is disabled.
r227837: Announce flow control capability to underlying PHY driver. Pause timer value is initialized to 0xFFFF. Controller allows just 4 different TX pause thresholds. The lowest possible threshold value looks too aggressive so use next available threshold value.
|
229534 |
04-Jan-2012 |
yongari |
MFC r227850-227851,227854,227914,227916: r227850: Writing access to RL_CFG5 register also requires EEPROM write access. While I'm here, enable WOL through magic packet but disable waking up system via unicast, multicast and broadcast frames. Otherwise, multicast or unicast frame(e.g. ICMP echo request) can wake up system which is not probably wanted behavior on most environments. This was not known as problem because RL_CFG5 register access had not effect until this change. The capability to wake up system with unicast/multicast frames are still set in driver, default off, so users who need that feature can still activate it with ifconfig(8).
r227851: Perform media change after setting IFF_DRV_RUNNING flag. Without it, driver would ignore the first link state update if controller already established a link such that it would have to take additional link state handling in re_tick().
r227854: Disable accepting frames in re_stop() to put RX MAC into idle state. Because there is no reliable way to know whether RX MAC is in stopped state, rejecting all frames would be the only way to minimize possible races. Otherwise it's possible to receive frames while stop command execution is in progress and controller can DMA the frame to freed RX buffer during that period. This was observed on recent PCIe controllers(i.e. RTL8111F).
While this change may not be required on old controllers it wouldn't make negative effects on old controllers. One side effect of this change is disabling receive so driver reprograms RL_RXCFG to receive WOL frames when it is put into suspend or shutdown.
This should address occasional 'memory modified free' errors seen on recent RealTek controllers.
r227914: Make sure to stop TX MAC before freeing queued TX frames. For RTL8111DP, check if the TX MAC is active by reading RL_GTXSTART register. For RTL8402/8168E-VL/8168F/8411, wait until TX queue is empty.
r227916: To save more power, switch to 10/100Mbps link when controller is put into suspend/shutdown. Old PCI controllers performed that operation in firmware but for RTL8111C or newer controllers, it's responsibility of driver. It's not clear whether the firmware of RTL8111B still downgrades its speed to 10/100Mbps so leave it as it was.
|
229529 |
04-Jan-2012 |
yongari |
MFC r227587,227590-227591,227593,227638-227639: r227587: Add preliminary support for RTL8402 PCIe FastEthernet with integrated card reader.
r227590: Add preliminary support for RTL8411 PCIe Gigabit ethernet with integrated card reader.
r227591: Add missing driver lock in SIOCSIFCAP handler.
r227593: Disable PCIe ASPM (Active State Power Management) for all controllers. More and more RealTek controllers started to implement EEE feature. Vendor driver seems to load a kind of firmware for EEE with additional PHY fixups. It is known that the EEE feature may need ASPM support. Unfortunately there is no documentation for EEE of the controller so enabling ASPM may cause more problems.
r227638: Add preliminary support for second generation RTL8105E PCIe FastEthernet.
r227639: Add preliminary support for RTL8168/8111F PCIe Gigabit ethernet.
|
229524 |
04-Jan-2012 |
yongari |
MFC r227582: Enable 64bit DMA addressing support for all msk(4) controllers. Unnecessarily complex LE format used on Marvell controller was main reason not to enable 64bit DMA addressing in driver. If high 32bit address of DMA address of TX/RX buffer is changed, driver has to generate a new LE. In TX path, driver will keep track of lastly used high 32bit address of DMA address and generate a new LE whenever it sees high address change in the DMA address. In RX path, driver will always use two LEs to specify 64bit DMA address of RX buffer. If the high 32bit address of DMA address of RX buffer is the same as previous DMA address of RX buffer, driver does not have to use two LEs but driver will use two LEs for simplicity in RX ring management.
One of draw back for switching to 64bit DMA addressing is that the large amount of LEs are used to specify 64bit DMA address such that number of available LEs for TX/RX buffers are considerably reduced. To mitigate the issue, increase number of available LEs from 256 to 384 for TX and from 256 to 512 for RX. For 32bit architectures, msk(4) does not use 64bit DMA addressing to save resources.
|
229520 |
04-Jan-2012 |
yongari |
MFC r227452: To send a frame, controller requires a prepended TX header and the length of frame should be treated as multiple of 4. Actual frame length is set in the TX header. The TX header position should be aligned on 4 byte boundary and actual frame start position should be aligned on 4 byte boundary as well. This means we need 4(TX header length) + 3(frame length fixup) additional free space in TX buffer in addition to actual frame length. Make sure TX handler check these additional bytes. ae_tx_avail_size() returns actual free space in TX buffer to ease the calculation of available TX buffer space in caller. While I'm here, replace magic number to appropriate sizeof operator to enhance readability.
This change should fix controller lockup issue happened under certain conditions but it still does not fix watchdog timeout. It seems the watchdog timeout is side-effect of TxS and TxD mismatches. The root cause of TxD/TxD mismatch is not known yet but it looks like silicon bug. I guess driver may have to reinitialize controller whenever it sees TxS and TxD mismatches but leave it as it was at this moment.
PR: kern/145918
|
229505 |
04-Jan-2012 |
jhb |
MFC 227069: Move the cleanup of f_cdevpriv when the reference count of a devfs file descriptor drops to zero out of _fdrop() and into devfs_close_f() as it is only relevant for devfs file descriptors.
|
229501 |
04-Jan-2012 |
jhb |
MFC 226746: Consolidate duplicate definitions of V86_CY() and V86_ZR() which check for the carry and zero flags being set, respectively, in <btxv86.h> and use them throughout the x86 boot code.
|
229500 |
04-Jan-2012 |
jhb |
MFC 226364: Use PAIR32TO64() for the offset and length parameters to freebsd32_posix_fallocate() to properly handle big-endian platforms.
|
229499 |
04-Jan-2012 |
jhb |
MFC 226039: Ignore SRAT memory entries if the memory range does not overlap with an existing phys_avail[] entry. If a hw.physmem setting causes a memory domain to not be present in phys_avail[], the SRAT table will now be ignored rather than triggering a panic when a CPU in the missing domain tries to allocate a page.
|
229492 |
04-Jan-2012 |
pluknet |
MFC r228916: Clean up from the 4.x era.
In an example of boot command: - rename wd(4) IDE disk drives name to ad(4) for the time being. - update the used kernel path "/kernel" to the current default.
Bump .Dd for this and previous changes.
|
229487 |
04-Jan-2012 |
pluknet |
MFC r227447:
struct timespec32: change types of tv_sec and tv_nsec fields to signed to match native struct timespec ABI on __LP32__.
|
229485 |
04-Jan-2012 |
pluknet |
MFC r226882: Fix arguments list for proc:::signal-discard DTrace probe.
Reported by: Anton Yuzhaninov <citrin citrin ru>
|
229482 |
04-Jan-2012 |
pluknet |
MFC r227055: Remove a couple of write-only variables.
|
229480 |
04-Jan-2012 |
pluknet |
Revert MFC r226833,227056. /stand exists in the MFS root used during a sysinstall-based install.
Reported by: jhb Pointy hat to: pluknet
|
229475 |
04-Jan-2012 |
pho |
MFC: r227527
Removed extra PRELE() call.
|
229473 |
04-Jan-2012 |
pluknet |
MFC r226833,r227056:
Remove the long reprecated ``/stand/sysinstall'' from the init_path.
|
229452 |
04-Jan-2012 |
yongari |
MFC r227675: Partially revert r218788. r218788 removed calling dc_setcfg() for !DC_IS_ADMTEK in dc_miibus_statchg(). This change broke link establishment of Intel 21143 with dcphy(4) where it stuck in "ability detect" state without completing auto-negotiation. Also nuke dc_if_media as it's not actually used.
|
229441 |
03-Jan-2012 |
yongari |
MFC r227512: Overhaul bus_dma(9) usage in driver: - Don't use a single big DMA block for all rings. Create separate DMA area for each ring instead. Currently the following DMA areas are created: Event ring, standard RX ring, jumbo RX ring, RX return ring, hardware MAC statistics and producer/consumer status area. For Tigon II, mini RX ring and TX ring are additionally created. - Added missing bus_dmamap_sync(9) in various TX/RX paths. - TX ring is no longer created for Tigon 1 such that it saves more resources on Tigon 1. - Data sheet is not clear about alignment requirement of each ring so use 32 bytes alignment for normal DMA area but use 64 bytes alignment for jumbo RX ring where the extended RX descriptor size is 64 bytes. - For each TX/RX buffers use separate DMA tag(e.g. the size of a DMA segment, total size of DMA segments etc). - Tigon allows separate DMA area for event producer, RX return producer and TX consumer which is really cool feature. This means TX and RX path could be independently run in parallel. However ti(4) uses a single driver lock so it's meaningless to have separate DMA area for these producer/consumer such that this change creates a single status DMA area. - It seems Tigon has no limits on DMA address space and I also don't see any problem with that but old comments in driver indicates there could be issues on descriptors being located in 64bit region. Introduce a tunable, dev.ti.%d.dac, to disable using 64bit DMA in driver. The default is 0 which means it would use full 64bit DMA. If there are DMA issues, users can disable it by setting the tunable to 0. - Do not increase watchdog timer in ti_txeof(). Previously driver increased the watchdog timer whenever there are queued TX frames. - When stat ticks is set to 0, skip processing ti_stats_update(), avoiding bus_dmamap_sync(9) and updating if_collisions counter. - MTU does not include FCS bytes, replace it with ETHER_VLAN_ENCAP_LEN.
With these changes, ti(4) should work on PAE environments. Many thanks to Jay Borkenhagen for remote hardware access.
|
229438 |
03-Jan-2012 |
yongari |
MFC r227431-227432,227505,227509: r227431: style. No functional changes.
r227432: Remove dead ifdef. Driver should always check raised interrupt is for the device.
r227505: It's bad idea to allocate large memory, 4KB, from stack. Pre-allocate the memory in device attach time. While I'm here remove unnecessary reassignment of error variable as it was already initialized. Also added a missing driver lock in TIIOCSETTRACE handler.
r227509: Export sysctl node for various interrupt moderation parameters and have administrators control them. ti(4) provides a character device to control various other features of driver via ioctls but users had to write their own code to manipulate these parameters. It seems some default values for these parameters are not optimal on today's system but leave it as it was and let administrators change them. The following parameters could be changed:
dev.ti.%d.rx_coal_ticks dev.ti.%d.rx_max_coal_bds dev.ti.%d.tx_coal_ticks dev.ti.%d.tx_max_coal_bds dev.ti.%d.tx_buf_ratio dev.ti.%d.stat_ticks
The interface has to be brought down and up again before a change takes effect.
ti(4) controller supports hardware MAC counters with additional DMA statistics. So it's doable to export these counters via sysctl interface. Unfortunately, these counters are cumulative such that driver have to either send an explicit clear command to controller after extracting them or have to maintain internal counters to get actual changes. Neither look good to me so counters were not exported via sysctl.
|
229432 |
03-Jan-2012 |
yongari |
MFC r227347,227367: r227347: Retire 'options TI_PRIVATE_JUMBOS' and replace local jumbo allocator with UMA backed jumbo allocator by default. Previously ti(4) used sf_buf(9) interface for jumbo buffers but it was broken at this moment such that enabling jumbo frame caused instant panic. Due to the nature of sf_buf(9) it heavily relies on VM changes but it seems ti(4) was not received much blessing from VM gurus. I don't understand VM magic and implications used in driver either. Switching to UMA backed jumbo allocator like other network drivers will make jumbo frame work on ti(4). While I'm here, fully allocate all RX buffers. This means ti(4) now uses 512 RX buffer and 1024 mini RX buffers.
To use sf_buf(9) interface for jumbo buffers, introduce a new 'options TI_SF_BUF_JUMBO'. If it is proven that sf_buf(9) is better for jumbo buffers, interesting developers can fix the issue in future.
ti(4) still needs more bus_dma(9) cleanups and should use separate DMA tag/map for each ring(standard, jumbo, mini, command, event etc) but it should work on all platforms except PAE.
Special thanks to Jay[1] who provided complete remote debugging access.
r227367: Comment out TI_JUMBO_HDRSPLIT. TI_JUMBO_HDRSPLIT requires TI_SF_BUF_JUMBO.
|
229421 |
03-Jan-2012 |
yongari |
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.
|
229417 |
03-Jan-2012 |
yongari |
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.
|
229404 |
03-Jan-2012 |
yongari |
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
|
229391 |
03-Jan-2012 |
rmacklem |
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.
|
229387 |
03-Jan-2012 |
mav |
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.
|
229369 |
03-Jan-2012 |
hselasky |
MFC r229317: Fix for USB suspend and resume.
|
229360 |
03-Jan-2012 |
yongari |
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.
|
229357 |
03-Jan-2012 |
yongari |
MFC r226870: Recognize BCM5720C PHY.
|
229354 |
03-Jan-2012 |
yongari |
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.
|
229350 |
03-Jan-2012 |
yongari |
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.
|
229336 |
02-Jan-2012 |
yongari |
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 <coco <> executive-computing dot de>, Martin MATO <martin.mato <> orange dot fr>
|
229333 |
02-Jan-2012 |
yongari |
MFC r226699: When driver is run for the first time there would be no established link such that calling dc_setcfg() right after media change would be meaningless unless controller in question is not Davicom DM9102. Ideally dc_setcfg() should be called when speed/duplex is resolved otherwise it would reprogram controller with wrong speed/duplex information. Because MII status change callback already calls dc_setcfg() I think calling dc_setcfg() in dc_init_locked() is wrong. For instance, it would take some time to establish a link after mii_mediachg(), so blindly calling dc_setcfg() right after mii_mediachg() will always yield wrong media configuration.
Extend dc_ifmedia_upd() to handle media change and still allow 21143 and Davidcom controllers program speed/duplex regardless of current resolved speed/duplex of link. In theory 21143 may not need to call dc_setcfg() right after media change, but leave it as it is because there are too many variants to test that change. Probably dc(4) shall need a PHY reset in dc_ifmedia_upd() but it's hard to verify correctness of the change.
This change reliably makes ULi M5263 establish a link.
While I'm here correctly report media change result. Previously it always reported a success.
|
229303 |
02-Jan-2012 |
mav |
MFC r227464, r227471 Major GEOM MULTIPATH class rewrite: - Improved locking and destruction process to fix crashes. - Improved "automatic" configuration method to make it consistent and safe by reading metadata back from all specified paths after writing to one. - Added provider size check to reduce chance of ordering conflict with other GEOM classes. - Added "manual" configuration method without using on-disk metadata. - Added "add" and "remove" commands to allow manage paths manually. - Failed paths are no longer dropped from geom, but only marked as FAIL and excluded from I/O operations. - Automatically restore failed paths when all others paths are marked as failed, for example, because of device-caused (not transport) errors. - Added "fail" and "restore" commands to manually control FAIL flag. - geom is now destroyed on last path disconnection. - Added optional Active/Active mode support. Unlike Active/Passive mode, load evenly distributed between all working paths. If supported by the device, it allows to significantly improve performance, utilizing bandwidth of all paths. It is controlled by -A option during creation. Disabled by default now. - Improved `status` and `list` commands output.
Sponsored by: iXsystems, inc.
|
229301 |
02-Jan-2012 |
mav |
MFC r226816: Clarify disks/volumes above 2TiB support in geom_raid: - add support for volumes above 2TiB with Promise metadata format; - enforse and document other limitations: - Intel and Promise metadata formats do not support disks above 2TiB; - NVIDIA metadata format does not support volumes above 2TiB.
Sponsored by: iXsystems, Inc.
|
229299 |
02-Jan-2012 |
mav |
MFC r228819: Update list of 4K physical sector hard drives.
|
229297 |
02-Jan-2012 |
mav |
MFC r227637: Introduce CAM_SIM_POLLED SIM flag, indicating that it works in polling mode. It blocks CAM SWI usage on requests completion, unneeded because of polling and denied during kernel dumping because of blocked scheduler.
Before r198899 there was periph flag CAM_PERIPH_POLLED, but that was wrong, because there is whole SIM is polled or handled by SWI, not a single periph.
|
229295 |
02-Jan-2012 |
mav |
MFC r228497: Add PCI IDs for the Intel ICH9M SATA controllers.
|
229293 |
02-Jan-2012 |
mav |
MFC r226680: Some dmesg cosmetics: - for the legacy PCI ATA channels move channel number out of the device description, same as it is for ahci(4), siis(4) and mvs(4); - add device description for the ISA ATA channels.
|
229291 |
02-Jan-2012 |
mav |
MFC r228200: Add hw.ahci.force tunable to control whether AHCI drivers should attach to known AHCI-capable chips (AMD/NVIDIA), configured for legacy emulation.
Enabled by default to get additional performance and functionality of AHCI when it can't be enabled by BIOS. Can be disabled to honor BIOS settings if needed for some reason.
|
229289 |
02-Jan-2012 |
mav |
MFC r227635: Change the way how "not implemented" AHCI channels handled. Instead of completely skipping them, create ahcich devices for them to allocate unit numbers, but mark them as disabled to prevent driver probe and attach.
Last time some BIOSes tend to report unused channels as "not implemented". This change makes ahcichX devices numbering consistent, independently of connected disks. It makes per-channel driver hints usable and CAM devices wiring possible on such systems.
|
229287 |
02-Jan-2012 |
rmacklem |
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.
|
229263 |
02-Jan-2012 |
rmacklem |
MFC: r227517 Move the setting of the default value for nm_wcommitsize to before the nfs_decode_args() call in the new NFS client, so that a specfied command line value won't be overwritten. Also, modify the calculation for small values of desiredvnodes to avoid an unusually large value or a divide by zero crash. It seems that the default value for nm_wcommitsize is very conservative and may need to change at some time.
|
229258 |
02-Jan-2012 |
rmacklem |
MFC: r227494 Since NFSv4 byte range locking only works for regular files, add a sanity check for the vnode type to the NFSv4 client.
|
229172 |
01-Jan-2012 |
rmacklem |
MFC: r227493 Move the assignment of default values for some mount options to before the nfs_decode_args() call in the new NFS client, so they don't overwrite the value specified on the command line.
|
229130 |
31-Dec-2011 |
pho |
MFC: r226987
Added missing cache purge of from argument for rename().
|
229121 |
31-Dec-2011 |
hselasky |
MFC r228195: Fix checks for error return from urtw_alloc_rx_data_list() and urtw_alloc_tx_data_list().
|
229120 |
31-Dec-2011 |
hselasky |
MFC r228232 and r228303: Fix clang compile warnings.
|
229119 |
31-Dec-2011 |
hselasky |
MFC r227706, r227748, r227749 and r228234: Simplify the usb_pause_mtx() function by factoring out the generic parts to the kernel's pause() function. The pause() function can now be used when cold != 0. Also assert that the timeout in system ticks must be greater or equal to zero.
|
229118 |
31-Dec-2011 |
hselasky |
MFC r227701, r227847 and r227849: Move the device_delete_all_children() function from usb_util.c to kern/subr_bus.c. Simplify this function so that it no longer depends on malloc() to execute. Rename device_delete_all_children() into device_delete_children(). Identify a few other places where it makes sense to use device_delete_children().
|
229117 |
31-Dec-2011 |
hselasky |
MFC r227610 and r228243: Add more quirks for USB mass storage devices.
|
229116 |
31-Dec-2011 |
hselasky |
MFC r228637: Add new USB ID.
|
229115 |
31-Dec-2011 |
hselasky |
MFC r227781: Add new USB IDs.
PR: usb/162712, usb/163732
|
229111 |
31-Dec-2011 |
hselasky |
MFC r226465 and r226467: Fix an issue with 11g beacon frames which looks to be a limitation on the largest multi-write size.
|
229108 |
31-Dec-2011 |
hselasky |
MFC r228494, r228508: Fix for random USB transfer time out.
|
229107 |
31-Dec-2011 |
hselasky |
MFC r227462: Enable power save mode for the USB storage device driver.
|
229106 |
31-Dec-2011 |
hselasky |
MFC r226743: Implement TX/RX checksum offloading support for ASIX AX88772B controller.
|
229105 |
31-Dec-2011 |
hselasky |
MFC r226709: Allow USB ethernet drivers to define a driver specific attach handler so that a USB ethernet driver can announce interface capabilities and do its own MII attach.
|
229103 |
31-Dec-2011 |
hselasky |
MFC 228304: Correct some bInterval USB template descriptor values.
|
229100 |
31-Dec-2011 |
hselasky |
MFC r228709, r228711 and r228723: - Add missing unlock of USB controller's lock, when doing shutdown, 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.
|
229099 |
31-Dec-2011 |
hselasky |
MFC r227285: Add support for new USB modem protocol.
PR: usb/159919
|
229098 |
31-Dec-2011 |
dim |
MFC r228554:
In sys/contrib/ngatm/netnatm/msg/uni_ie.c, use a more appropriate way to tell the compiler some parameters are purposefully unused.
|
229097 |
31-Dec-2011 |
hselasky |
MFC r228758: Fix for race against user-space applications trying to change the configuration on USB HUBs.
PR: kern/163091
|
229096 |
31-Dec-2011 |
hselasky |
MFC r229086, r228483 and r228640: Implement better support for USB controller suspend and resume. Fix some build issues in avr32dci.c
|
229093 |
31-Dec-2011 |
hselasky |
MFC r226173, r227843, r227848 and r227908: Use DEVMETHOD_END to mark end of device methods. Remove superfluous device methods. Add some missing __FBSBID() macros.
|
229084 |
31-Dec-2011 |
hselasky |
MFC r227396, r227401, r227541, r227654 and r228493: Relax XHCI timeouts which should fix enumeration issues. Fix definition of XHCI port power bit. Correct size of some USB 3.0 descriptor fields.
Reported by: Kohji Okuno, Jan Henrik Sylvester
|
229082 |
31-Dec-2011 |
hselasky |
MFC r227463, r227383 and r227108: Add support for modem control lines. Add support for GPIO pins.
PR: usb/162307 Submitted by: JD Louw
|
229080 |
31-Dec-2011 |
hselasky |
MFC r227461: Style change. Use memxxx() functions instead of bxxx() functions.
|
229061 |
31-Dec-2011 |
yongari |
MFC r226480-226481: r226480: Add missing driver lock in media status handler.
r226481: Make sure to report media change status to caller. Previously it always reported success.
|
229060 |
31-Dec-2011 |
yongari |
MFC r226479: Close a race where SIOCGIFMEDIA ioctl get inconsistent link status. Because driver is accessing a common MII structure in mii_pollstat(), updating user supplied structure should be done before dropping a driver lock.
Reported by: Karim (fodillemlinkarimi <> gmail dot com)
|
229057 |
31-Dec-2011 |
yongari |
MFC r226478: Close a race where SIOCGIFMEDIA ioctl get inconsistent link status. Because driver is accessing a common MII structure in mii_pollstat(), updating user supplied structure should be done before dropping a driver lock.
Reported by: Karim (fodillemlinkarimi <> gmail dot com)
|
229052 |
31-Dec-2011 |
yongari |
MFC r226123: BCE_MISC_ID register of BCM5716 returns the same id of BCM5709 so remove explicit checks for BCM5716. The BCM5709 and BCM5716 chips are virtually indistinguishable by software except for the PCI device ID. The two chips differ in that BCM5709 supports TCP/IP and iSCSI offload in Windows while the BCM5716 doesn't. While I'm here remove now unused definition of BCE_CHIP_NUM_5716 and BCE_CHIP_ID_5716_C0.
|
228244 |
03-Dec-2011 |
hrs |
MFC r226446: Fix a problem that an interface unexpectedly becomes IFF_UP by just doing "ifconfing inet6 -ifdisabled" when the interface has ND6_IFF_AUTO_LINKLOCAL flag and no link-local address.
Approved by: re (bz)
|
228187 |
01-Dec-2011 |
jhb |
MFC 227389: Remove some debugging printfs.
Approved by: re (bz)
|
228182 |
01-Dec-2011 |
glebius |
MFhead r228150:
Return value should be conditional on return value of pfsync_defer_ptr()
PR: kern/162947 Submitted by: Matthieu Kraus <matthieu.kraus s2008.tu-chemnitz.de>
Approved by: re (kib)
|
228126 |
29-Nov-2011 |
marius |
MFC: r227960
Increase the CDMA sync timeout for Schizo bridges to 15 seconds as used by OpenSolaris. One second turned out to be not enough for certain loads while 10 seconds were sufficient. Reported by: Peter Jeremy
Approved by: re (bz)
|
228041 |
27-Nov-2011 |
marcel |
MFC rev. 227629: Wire the kernel text RWX, rather than RX. We're not quite ready for having kernel text non-writable, because we still need to apply relocations. On top of that, the PBVM page table has all pages marked as RWX, so it's an inconsistency to begin with.
Approved by: re (kib)
|
228036 |
27-Nov-2011 |
tuexen |
MFC r228031:
Fix a warning reported by arundel@. Fix a bug where the parameter length of a supported address types parameter is set to a wrong value if the kernel is built with with either INET or INET6, but not both.
Approved by: re@
|
227976 |
25-Nov-2011 |
marius |
MFC: r227829, r227844
- Add a DEVMETHOD_END alias for KOBJMETHOD_END so that along with 'driver_t' and DEVMETHOD() we can fully hide the explicit mention of kobj(9) from device drivers. - Update the device driver examples to use DEVMETHOD_END.
Submitted by: jhb Approved by: re (kib)
|
227971 |
25-Nov-2011 |
rstone |
MFC r227342. Note that the original commit message, reproduced below, has error. The final sentence should read "*without* CTF data".
The in-kernel CTF parser caches the result of its first attempt to parse CTF data from a module. On subsequent attempts to retrieve CTF data for a module, return an error if there no CTF data.
This fixes a panic if you try to enable fbt probes on a module with CTF data twice.
Approved by: re (kib)
|
227948 |
24-Nov-2011 |
tuexen |
MFC r227930:
Move up the address to the top of the sctp_paddrthlds structure like in all other structures. This avoids alignment problems.
Approved by: re@
|
227945 |
24-Nov-2011 |
rstone |
MFC r227290 and r227291:
r227290: Fix the DTrace pid return trap interrupt vector. Previously we were using 31, but that vector is reserved.
Without this fix, running dtrace -p <pid> would either cause the target process to crash or the kernel to page fault
r227291: Replace fasttrap_copyout() with uwrite(). FreeBSD copyout() is not able to write to the .text section of a process.
Approved by: re (kib)
|
227942 |
24-Nov-2011 |
tuexen |
MFC r227540:
Set the MTU of an path to an approriate value if the interface MTU can't be determined.
Approved by: re@
|
227940 |
24-Nov-2011 |
tuexen |
MFC r227486:
Don't copy uninitialized memory. Also simplify the comparison of interface names.
Approved by: re@
|
227923 |
24-Nov-2011 |
pjd |
MFC r227110,r227111:
r227110:
In zvol_open() if the spa_namespace_lock is already held, it means that ZFS is trying to open and taste ZVOL as its VDEV. This is not supported, so return an error instead of panicing on spa_namespace_lock recursion.
Reported by: Robert Millan <rmh@debian.org> PR: kern/162008
r227111:
Correct typo in comment.
Reported by: Fabian Keil <fk@fabiankeil.de>
Approved by: re (kib)
|
227898 |
23-Nov-2011 |
bz |
MFC r226938 (by kevlo):
Add missing PF_UNLOCK in pf_test
Approved by: re (kib)
|
227894 |
23-Nov-2011 |
bz |
MFC r227061 (by mlaier):
Fix a use-after-free/redzone issue in the routing code.
Approved by: re (kib)
|
227890 |
23-Nov-2011 |
bz |
MFC r227547:
The maximum TSO frame size should be: maximum IP datagram size (65535 bytes) + Ethernet header size (14 bytes) + 2 * VLAN tag size (4 bytes) [1].
[1] We need to multiply by 2 to account for the double VLAN tag provision added in IEEE 802.1ad.
Submitted by: David Somayajulu (david.somayajulu qlogic.com)
Approved by: re (kib)
|
227888 |
23-Nov-2011 |
attilio |
MFC r227058: Disable interrupt and preemption for smp_rendezvous() also in the UP/!SMP case.
Sponsored by: Sandvine Incorporated Approved by: re (kib)
|
227885 |
23-Nov-2011 |
bz |
MFC r227481:
Return the correct value for the IPV6_MULTICAST_HOPS getsockopt() call.
Submitted by: rpaulo
Approved by: re (kib)
|
227718 |
19-Nov-2011 |
marius |
MFC: r227578
Fix compilation with DEBUG defined.
Approved by: re (kib)
|
227714 |
19-Nov-2011 |
marius |
MFC: r227539
Define curthread as an inline function that loads the thread pointer directly from g7, the pcpu pointer. This guarantees correct behavior when the thread migrates to a different CPU. Commit message stolen from r205431. Additional testing by Peter Jeremy.
Approved by: re (kib)
|
227711 |
19-Nov-2011 |
marius |
MFC: r227537
As it turns out, r186347 actually is insufficient to avoid the use of the curthread-accessing part of mtx_{,un}lock(9) when using a r210623-style curthread implementation on sparc64, crashing the kernel in its early cycles as PCPU isn't set up, yet (and can't be set up as OFW is one of the things we need for that, which leads to a chicken-and-egg problem). What happens is that due to the fact that the idea of r210623 actually is to allow the compiler to cache invocations of curthread, it factors out obtaining curthread needed for both mtx_lock(9) and mtx_unlock(9) to before the branch based on kobj_mutex_inited when compiling the kernel without the debugging options. So change kobj_class_compile_static(9) to just never acquire kobj_mtx, effectively restricting it to its documented use, and add a kobj_init_static(9) for initializing objects using a class compiled with the former and that also avoids using mutex(9) (and malloc(9)). Also assert in both of these functions that they are used in their intended way only. While at it, inline kobj_register_method() and kobj_unregister_method() as there wasn't much point for factoring them out in the first place and so that a reader of the code has to figure out the locking for fewer functions missing a KOBJ_ASSERT. Tested on powerpc{,64} by andreast.
Reviewed by: nwhitehorn (earlier version), jhb Approved by: re (kib)
|
227705 |
19-Nov-2011 |
pjd |
MFC r226549,r226550,r226551,r226552,r226553,r226554,r226568,r226569,r226611, r226612:
r226549:
Remove redundant size calculation.
r226550:
Initialize 'rc' properly before using it. This error could lead to infinite loop when data reconstruction was needed.
r226551:
Don't mark vdev as healthy too soon, so we won't try to use invalid vdevs.
r226552:
Never pass NULL block pointer when reading. This is neither expected nor handled by lower layers like vdev_raidz, which uses bp for checksum verification. This bug could lead to NULL pointer reference and resets during boot.
r226553:
Always pass data size for checksum verification function, as using physical block size declared in bp may not always be what we want. For example in case of gang block header physical block size declared in bp is much larger than SPA_GANGBLOCKSIZE (512 bytes) and checksum calculation failed. This bug could lead to accessing unallocated memory and resets/failures during boot.
r226554:
Fix missing return when LOADER_GPT_SUPPORT is defined, but LOADER_MBR_SUPPORT is not.
r226568:
- Correctly read gang header from raidz. - Decompress assembled gang block data if compressed. - Verify checksum of a gang header. - Verify checksum of assembled gang block data. - Verify checksum of uber block.
Submitted by: avg
r226569:
With LOADER_MBR_SUPPORT defined and LOADER_GPT_SUPPORT undefined we would never call disk_openmbr().
Submitted by: avg
r226611:
- Allow to specify multiple files to check, eg.
zfsboottest gpt/system0 gpt/system1 - /boot/kernel/kernel /boot/zfsloader
- Instead of printing file's content calculate MD5 hash of the file, so it can be easly compared to the hash calculated via file system. - Some other minor improvements.
r226612:
Because ZFS boot code was very fragile in the past and real PITA to debug, introduce zfsboottest.sh script that will verify if it will be possible to boot from the given pool.
# zfsboottest.sh system
Where "system" is pool name of the pool we want to boot from.
What is being verified by the script: - Does the pool exist? - Does it have bootfs property configured? - Is mountpoint property of the boot dataset set to 'legacy'?
Dataset configured in bootfs property has to be mounted to perform more checks: - Does the /boot directory in boot dataset exist? - Is this dataset configured as root file system in /etc/fstab or set in vfs.root.mountfrom variable in /boot/loader.conf?
By using zfsboottest tool the script will read all the files in /boot directory using ZFS boot code and calculate their checksums. Then, it will walk /boot directory using find(1) though regular file sytem and also read all the files in /boot directory and calculate their checksums. If any of the files cannot be looked up, read or checksum is invalid it will be reported and booting off of this pool is probably not possible.
Some additional checks may be interesting as well. For example if the disks contain proper pmbr and gptzfsboot code or if all expected files in /boot/ are present.
When upgrading FreeBSD, one should snapshot datasets that contain operating system, upgrade (install new world and kernel) and use zfsboottest.sh to verify if it will be possible to boot from new configuration. If all is good one should upgrade boot blocks, by eg.:
# gpart -b /boot/pmbr -p /boot/gptzfsboot -i 1 ada1
If something is wrong, one should rollback datasets and report the problems.
Approved by: re (kib)
|
227704 |
19-Nov-2011 |
pjd |
MFC r226617:
zfs vdev_file_io_start: validate vdev before using vdev_tsd
vdev_tsd can be NULL for certain vdev states. At least in userland testing with ztest.
Submitted by: avg Approved by: re (kib)
|
227702 |
19-Nov-2011 |
pjd |
MFC r226620:
Update per-thread I/O statistics collection in ZFS. This allows to see processes I/O activity in 'top -m io' output.
PR kern/156218 Reported by: Marcus Reid <marcus@blazingdot.com> Patch by: avg Approved by: re (kib)
|
227677 |
18-Nov-2011 |
dougb |
MFC r226863:
Fix svnversion for svn 1.7.x by not looking for .svn in ${SYSDIR} (since it no longer exists). Instead, run svnversion if we can find the binary and test that the output looks like a version string.
Approved by: re (kib)
|
227630 |
17-Nov-2011 |
rmacklem |
MFC: r227059 Both a crash reported on freebsd-current on Oct. 18 under the subject heading "mtx_lock() of destroyed mutex on NFS" and PR# 156168 appear to be caused by clnt_dg_destroy() closing down the socket prematurely. When to close down the socket is controlled by a reference count (cs_refs), but clnt_dg_create() checks for sb_upcall being non-NULL to decide if a new socket is needed. I believe the crashes were caused by the following race: clnt_dg_destroy() finds cs_refs == 0 and decides to delete socket clnt_dg_destroy() then loses race with clnt_dg_create() for acquisition of the SOCKBUF_LOCK() clnt_dg_create() finds sb_upcall != NULL and increments cs_refs to 1 clnt_dg_destroy() then acquires SOCKBUF_LOCK(), sets sb_upcall to NULL and destroys socket
This patch fixes the above race by changing clnt_dg_destroy() so that it acquires SOCKBUF_LOCK() before testing cs_refs.
Tested by: bz Reviewed by: dfr Approved by: re (kib)
|
227624 |
17-Nov-2011 |
eadler |
Record the merge of r227457, which was done as part of r227565 but not mentioned in the commit log
PR: kern/142999 PR: kern/151365 Submitted by: Takefu Kenji <takefu@airport.fm> Submitted by: Joerg Niendorf <f5d10a@internode.on.net> Approved by: re (kib)
|
227450 |
11-Nov-2011 |
trociny |
MFC r227449:
Fix false positive EADDRINUSE that could be returned by bind, due to the typo made in r227207.
Reported by: kib Tested by: kib
Approved by: re (kib)
|
227428 |
10-Nov-2011 |
trociny |
MFC r227204, 227206, 227207:
r227204:
Fix the typo made in r157474.
r227206:
Before dereferencing intotw() check for NULL, the same way as it is done for in_pcb (see r157474).
r227207:
Cache SO_REUSEPORT socket option in inpcb-layer in order to avoid inp_socket->so_options dereference when we may not acquire the lock on the inpcb.
This fixes the crash due to NULL pointer dereference in in_pcbbind_setup() when inp_socket->so_options in a pcb returned by in_pcblookup_local() was checked.
Reported by: dave jones <s.dave.jones@gmail.com>, Arnaud Lacombe <lacombar@gmail.com> Suggested by: rwatson Glanced by: rwatson Tested by: dave jones <s.dave.jones@gmail.com>
Approved by: re (kib)
|
227426 |
10-Nov-2011 |
tuexen |
MFC 227320: When loading addresses from INITs, always use the correct local address.
Approved by: re@
|
227424 |
10-Nov-2011 |
tuexen |
MFC 227266: Initialize all components of the sent COOKIE.
Approved by: re@
|
227423 |
10-Nov-2011 |
andre |
Back out r226299 (MFC of r226105) which caused a number of ports that depend on the incorrect IP length field. The fix stays in HEAD and ports should test for it.
Requested by: glebius Approved by: re (kib)
|
227420 |
10-Nov-2011 |
alc |
MFC r226740 Speed up vm_page_cache() and vm_page_remove() by checking for a few common cases that can be handled in constant time.
Approved by: re (kib)
|
227402 |
09-Nov-2011 |
pho |
MFC r226971 Added missing cache purge of from argument.
Approved by: re (kensmith)
|
227400 |
09-Nov-2011 |
jhb |
MFC 226748: - Add a new header for the x86 boot code that defines various structures and constants related to the BIOS Enhanced Disk Drive Specification. - Use this header instead of magic numbers and various duplicate structure definitions for doing I/O. - Use an actual structure for the request to fetch drive parameters in drvsize() rather than a gross hack of a char array with some magic size. While here, change drvsize() to only pass the 1.1 version of the structure and not request device path information. If we want device path information you have to set the length of the device path information as an input (along with probably checking the actual EDD version to see which size one should use as the device path information is variable-length). This fixes data smashing problems from passing an EDD 3 structure to BIOSes supporting EDD 4.
Approved by: re (kib)
|
227397 |
09-Nov-2011 |
jhb |
MFC 226302: If an allocation for a specific resource range fails because it is not in a decoded range for an ACPI Host-PCI bridge, try to allocate it from the ACPI system resource range. If that works, permit the resource allocation regardless.
Approved by: re (kib)
|
227305 |
07-Nov-2011 |
marius |
MFC: r227006, r227281, r227282
Add a PCI front-end to esp(4) allowing it to support AMD Am53C974 and replace amd(4) with the former in the amd64, i386 and pc98 GENERIC kernel configuration files. Besides duplicating functionality, amd(4), which previously also supported the AMD Am53C974, unlike esp(4) is no longer maintained and has accumulated enough bit rot over time to always cause a panic during boot as long as at least one target is attached to it (see PR 124667).
PR: 124667 Approved by: re (kib) Obtained from: NetBSD (based on)
|
227302 |
07-Nov-2011 |
marius |
MFC: r226947, r226949, r227284
- Use device_t rather than the NetBSDish struct device. - Move esp_devclass to ncr53c9x.c in order to allow different bus front-ends to use it. - Use KOBJMETHOD_END. - Remove the gl_clear_latched_intr hook as it's not needed for any of the chips nor the front-ends supported in FreeBSD and likely never will be. - Correct the DMA constraints and only limit the tag used for the transfer buffers to 32-bit DMA as that address is written into a 32-bit register. - The ESP200 also only supports up to 64k transfers. - Don't let the DMA and SBus front-end supply a maximum transfer size larger than MAXPHYS as that's the maximum the upper layers use and we otherwise just waste resources unnecessarily. - Initialize the ECB callout and don't zero the handle when returning ECBs to the free list so that ncr53c9x_callout() actually is called with the driver lock held. - On detach the driver lock should be held across cam_sim_free() according to isp(4) and a panic received. - Check the return value of NCRDMA_SETUP(), i.e. bus_dmamap_load(9), and try to handle failures gracefully. - In ncr53c9x_action() replace N calls to xpt_done() in a switch with just one at the end. - On XPT_PATH_INQ report "NCR" rather than "Sun" as the vendor as the former is somewhat more correct as well as the maximum supported transfer size via maxio in order to take advantage of controllers that that can handle more than DFLTPHYS. - Freeze the device queue if a request didn't complete without error and isn't already frozen. - Print the number of MESSAGE (EXTENDED) rejected. - Fix the path encoded in the multiple inclusion protection of ncr53c9xvar.h. - Correct the DMA constraints used in the LSI64854 core to not exceed the maximum supported transfer size and include the boundary so we don't need to check on every setup of a DMA transfer. - Let the bus DMA map callbacks do nothing in case of an error. - Correctly handle > 64k transfers for FAS366 in the LSI64854. A new feature flag NCR_F_LARGEXFER was introduced so we just need to check for this one and not for individual controllers supporting large transfers in several places. - Let the LSI64854 core load transfer buffers using BUS_DMA_NOWAIT as the NCR53C9x core can't handle EINPROGRESS. Due to lack of bounce buffers support, sparc64 doesn't actually use EINPROGRESS and likely never will, as an example for writing additional front-ends for the NCR53C9x core it makes sense to set BUS_DMA_NOWAIT anyway though. - Some minor cleanup.
Approved by: re (kib)
|
227277 |
06-Nov-2011 |
marius |
MFC: r226995, r227042
- Import the common MII bitbang'ing code from NetBSD and convert drivers to take advantage of it instead of duplicating it. This reduces the size of the i386 GENERIC kernel by about 8k. The only potential in-tree users left unconverted are ed(4) and xe(4). Xe(4) generally should be changed to use miibus(4) instead of implementing PHY handling on its own, as otherwise it makes not much sense to add a dependency on miibus(4)/mii_bitbang(4) to it just for the MII bitbang'ing code. Ed(4) has some chip specific things interwinded with the MII bitbang'ing code and it's unclear whether it can be converted to common code, at least not without thorough testing of all the various chips supported by ed(4). The common MII bitbang'ing code also is useful in the embedded space for using GPIO pins to implement MII access. - Based on lessons learnt with dc(4) (see r185750), add bus barriers to the MII bitbang read and write functions of the other drivers converted in order to ensure the intended ordering. Given that register access via an index register as well as register bank/window switching is subject to the same problem, also add bus barriers to the respective functions of smc(4), tl(4) and xl(4). - Sprinkle some const.
Thanks to the following testers: Andrew Bliznak (nge(4)), nwhitehorn@ (bm(4)), yongari@ (sis(4) and ste(4)) Thanks to Hans-Joerg Sirtl for supplying hardware to test stge(4).
Reviewed by: yongari (subset of drivers) Approved by: re (kib) Obtained from: NetBSD (partially)
|
227268 |
06-Nov-2011 |
bz |
MFC r227064:
Add QLogic 10 Gigabit Ethernet & CNA Adapter Driver version 1.30 for 3200 and 8200 series cards.
Submitted by: David C Somayajulu (david.somayajulu@qlogic.com), Qlogic Corporation
Approved by: re (kib)
|
227232 |
06-Nov-2011 |
bz |
MFC r227085:
Always use the opt_*.h options for ipfw.ko, not just when compiled into the kernel. Do not try to build the module in case of no INET support but keep #error calls for now in case we would compile it into the kernel.
This should fix an issue where the module would fail to enable IPv6 support from the rc framework, but also other INET and INET6 parts being silently compiled out without giving a warning in the module case.
While here garbage collect unneeded opt_*.h includes. opt_ipdn.h is not used anywhere but we need to leave the DUMMYNET entry in options for conditional inclusion in kernel so keep the file with the same name.
Reported by: pluknet Reviewed by: plunket, jhb
Approved by: re (kib)
|
227230 |
06-Nov-2011 |
marius |
MFC: r227001
Increase the IOC port initialization timeouts by ten times to what the corresponding Linux driver uses. This allows mpt(4) to still recognize all good SATA devices in presence of a defective one, which takes about 45 seconds. In the long term we probably should implement the logic used by mpt2sas(4) allowing IOC port initialization to complete at a later time.
Submitted by: Andrew Boyer Approved by: re (kib)
|
227229 |
06-Nov-2011 |
marius |
MFC: r226154, r226165
- Follow the lead of dcphy(4) and pnphy(4) and move the reminder of the PHY drivers that only ever attach to a particular MAC driver, i.e. inphy(4), ruephy(4) and xlphy(4), to the directory where the respective MAC driver lives and only compile it into the kernel when the latter is also there, also removing it from miibus.ko and moving it into the module of the respective MAC driver. - While at it, rename exphy.c, which comes from NetBSD where the MAC driver it corresponds to also is named ex(4) instead of xl(4) but that in FreeBSD actually identifies itself as xlphy(4), and its function names accordingly for consistency. - Additionally while at it, fix some minor style issues like whitespace in the register headers and add multi-inclusion protection to inphyreg.h.
Approved by: re (kib)
|
227226 |
06-Nov-2011 |
mav |
MFC r226985: Workaround the problem introduced by combination of r162200 and r215687. r162200 delays provider orphanization until all running requests complete, to workaround broken orphan() method implementation in some classes. r215687 removes persistent periodic (10Hz) event thread wake ups. Together these changes can indefinitely delay orphanization until some other event wake up the event thread. One consequence of this is inability of CAM to destroy device disconnected when busy and, as consequence, create new one after reconnection.
While the best solution would be to revert r162200, it is not easy, as some classes still broken in that way. Instead conditionally wake up event thread if there are some providers waiting for orphanization.
Approved by: re (kib)
|
227216 |
06-Nov-2011 |
hselasky |
MFC r227075: Fix for panic at USB controller attach failure during cold boot.
Approved by: re (kib)
|
227073 |
04-Nov-2011 |
ae |
MFC r226880: Our geom withering function could take some time before geom with its providers and consumers will be destroyed. Before take some actions with a geom, check that it is not destroyed at the moment.
Tested by: nwhitehorn
Approved by: re (kib)
|
227008 |
01-Nov-2011 |
qingli |
MFC 226710
The host-id/interface-id can have a specific value and is properly masked out when adding a prefix route through the "route" command. However, when deleting the route, simply changing the command keyword from "add" to "delete" does not work. The failoure is observed in both IPv4 and IPv6 route insertion. The patch makes the route command behavior consistent between the "add" and the "delete" operation.
Approved by: re (kib)
|
227007 |
01-Nov-2011 |
hselasky |
MFC r226903, r225777, r226221 and r226534: Add some new USB device IDs and some USB device quirks. Improve the USB mass storage auto quirk detection.
PR: usb/161798, usb/160911 Approved by: re (kib)
|
227005 |
01-Nov-2011 |
qingli |
MFC 226451
The IPv6 code was influx at the time of r196865 due to the L2/L3 separation rewrite changes. r196865 was committed to fix a scope violation problem in the following test scenario:
box-1# ifconfig em0 inet6 2001:db8:1:: prefixlen 64 anycast box-1# ifconfig em1 inet6 2001:db8:2::1 prefixlen 64
box-2# ifconfig re0 inet6 2001:db8:1::6 prefixlen 64
em0 and re0 are on the same link.
box-2# ping6 2001:db8:1:: PING6(56=40+8+8 bytes) 2001:db8:1::6 --> 2001:db8:1::
the ICMPv6 response should have a source address of em1, which is 2001:db8:2::1, not the link-local address of em0.
That code is no longer necessary and breaks the IPv6-Ready logo testing, so revert it now.
Reviewed by: hrs Approved by: re (kib)
|
227002 |
01-Nov-2011 |
qingli |
MFC 226713
Exclude host routes when checking for prefix coverage on multiple interfaces. A host route has a NULL mask so check for that condition. I have also been told by developers who customize the packet output path with direct manipulation of the route entry (or the outgoing interface to be specific). This patch checks for the route mask explicitly to make sure custom code will not panic.
PR: kern/161805 Approved by: re (kib)
|
226965 |
31-Oct-2011 |
tuexen |
MFC 226869: When adding a new remote address using sctp_add_remote_addr(), return the correct net if requested.
Approved by: re@
|
226963 |
31-Oct-2011 |
pho |
MFC r226681: Only unlock if the lock is exclusive.
Approved by: re (kib) PR: kern/161956
|
226960 |
31-Oct-2011 |
tuexen |
MFC 226868: Send out control chunks which have no specific destination.
Approved by: re@
|
226956 |
31-Oct-2011 |
marcel |
MFC r226647: Add support for Boot Camp. The support is defined as follows: o Detect when Boot Camp is enabled (i.e. the MBR mirrors the GPT). o When Boot Camp is enabled, update the MBR whenever we write the GPT. o Creation of a Boot Camp enabled GPT is not supported. o Automatically disable Boot Camp when the GPT has been changed so that there's either no EFI partition or no HFS+ partition. o The first 4 partitions (by index) get mirrored in the MBR.
Requested by, discussed with and tested by: kris@pcbsd.org Approved by: re (bz@, kib@)
|
226934 |
30-Oct-2011 |
marius |
MFC: r226522
Allow to dump on Solaris swap partitions.
PR: 161764 Submitted by: Peter Jeremy Approved by: re (kib)
|
226917 |
30-Oct-2011 |
marius |
MFC: r226381
Merge from NetBSD: - Remove clause 3 and 4 from TNF licenses. - Fix memset usage. - Various cleanup. - Kill caddr_t.
Approved by: re (kib)
|
226910 |
29-Oct-2011 |
marius |
Merge from r225950:
Set the sense residual properly.
Reviewed by: ken Approved by: re (kib)
|
226906 |
29-Oct-2011 |
marcel |
MFC r226673: Don't terminate the interactive root mount prompt on mount failure. This restores the previous behaviour. While here, match '?' and '.' inputs exactly and improve the error message.
Requested by: avg@ Derived from a patch by: Arnaud Lacombe <lacombar@gmail.com> Approved by: re (kib@)
|
226904 |
29-Oct-2011 |
hselasky |
MFC r226803: Fix suspend and resume of non-super-speed USB devices in the generic XHCI driver. There appears to be some minor logic missing for this feature to work.
Approved by: re (kib)
|
226894 |
29-Oct-2011 |
attilio |
Include a missing opt_vm.h which doesn't let VM_NRESERVLEVEL switching correct utilization.
Approved by: re (kib)
|
226822 |
27-Oct-2011 |
yongari |
MFC r226695-226696: r226695: Fix a regression introduced in r218832. For TX status check, driver should use a TX list DMA tag.
r226696: Add missing bus_dmamap_sync() in setup frame transmit.
Approved by: re (kensmith)
|
226809 |
26-Oct-2011 |
kensmith |
MFC r226510,r226547: Comment out sbp(4) because it appears to cause boot failure on some systems. Add comment explaining why sbp(4) is commented out.
It was a mistake on my part to omit powerpc's GENERIC for r226510. But when I noticed the mistake I checked with the powerpc maintainer to see if I should correct the mistake Marcel said he'd prefer it be left as-is.
Approved by: re (kib)
|
226801 |
26-Oct-2011 |
glebius |
Sync pf(4) and pfsync(4) with head, merging lots of important bugfixes required for normal operation of pfsync(4). Revisions merged:
r226531 | bz | 2011-10-19 13:34:40 +0400 (ср, 19 окт 2011) | 4 lines
Fix an obvious locking bug where we would lock again rather than unlock.
r226532 | bz | 2011-10-19 14:04:24 +0400 (ср, 19 окт 2011) | 12 lines
Pseudo interfaces should go at SI_SUB_PSEUDO. However at least pfsync also depends on pf to be initialized already so pf goes at FIRST and the interfaces go at ANY. Then the (VNET_)SYSINIT startups for pf stays at SI_SUB_PROTO_BEGIN and for pfsync we move to the later SI_SUB_PROTO_IF.
This is not ideal either but at least an order that should work for the moment and can be re-fined with the VIMAGE merge, once this will actually work with more than one network stack.
r226533 | bz | 2011-10-19 14:08:58 +0400 (ср, 19 окт 2011) | 4 lines
In the non-FreeBSD case we do not expect PF_LOCK and friends to do anything.
r226535 | bz | 2011-10-19 14:16:42 +0400 (ср, 19 окт 2011) | 5 lines
Adjust the PF_ASSERT() macro to what we usually use in the network stack: PF_LOCK_ASSERT() and PF_UNLOCK_ASSERT().
r226536 | bz | 2011-10-19 15:04:49 +0400 (ср, 19 окт 2011) | 8 lines
De-virtualize the pf_task_mtx lock. At the current state of pf locking and virtualization it is not helpful but complicates things.
Current state of art is to not virtualize these kinds of locks - inp_group/hash/info/.. are all not virtualized either.
r226544 | bz | 2011-10-19 17:13:56 +0400 (ср, 19 окт 2011) | 12 lines
Fix recursive pf locking leading to panics. Splatter PF_LOCK_ASSERT()s to document where we are expecting to be called with a lock held to more easily catch unnoticed code paths. This does not neccessarily improve locking in pfsync, it just tries to avoid the panics reported.
PR: kern/159390, kern/158873 Submitted by: pluknet (at least something that partly resembles my patch ignoring other cleanup, which I only saw too late on the 2nd PR)
r226609 | glebius | 2011-10-21 15:11:18 +0400 (пт, 21 окт 2011) | 4 lines
In FreeBSD ip_output() expects ip_len and ip_off in host byte order
PR: kern/159029
r226623 | glebius | 2011-10-22 02:28:15 +0400 (сб, 22 окт 2011) | 5 lines
Fix a race: we should update sc_len before dropping the pf lock, otherwise a number of packets can be queued on sc, while we are in ip_output(), and then we wipe the accumulated sc_len. On next pfsync_sendout() that would lead to writing beyond our mbuf cluster.
r226655 | glebius | 2011-10-23 14:05:25 +0400 (вс, 23 окт 2011) | 5 lines
Correct flag for uma_zalloc() is M_WAITOK. M_WAIT is an old and deprecated flag from historical mbuf(9) allocator.
This is style only change.
r226656 | glebius | 2011-10-23 14:13:20 +0400 (вс, 23 окт 2011) | 5 lines
Absense of M_WAITOK in malloc flags for UMA doesn't equals presense of M_NOWAIT. Specify M_NOWAIT explicitly.
This fixes sleeping with PF_LOCK().
r226660 | glebius | 2011-10-23 18:59:54 +0400 (вс, 23 окт 2011) | 22 lines
Fix from r226623 is not sufficient to close all races in pfsync(4).
The root of problem is re-locking at the end of pfsync_sendout(). Several functions are calling pfsync_sendout() holding pointers to pf data on stack, and these functions expect this data to be consistent.
To fix this, the following approach was taken:
- The pfsync_sendout() doesn't call ip_output() directly, but enqueues the mbuf on sc->sc_ifp's interfaces queue, that is currently unused. Then pfsync netisr is scheduled. PF_LOCK isn't dropped in pfsync_sendout(). - The netisr runs through queue and ip_output()s packets on it.
Apart from fixing race, this also decouples stack, fixing potential issues, that may happen, when sending pfsync(4) packets on input path.
Reviewed by: eri (a quick review)
r226661 | glebius | 2011-10-23 19:08:18 +0400 (вс, 23 окт 2011) | 13 lines
- Fix a bad typo (FreeBSD specific) in pfsync_bulk_update(). Instead of scheduling next run pfsync_bulk_update(), pfsync_bulk_fail() was scheduled. This lead to instant 100% state leak after first bulk update request. - After above fix, it appeared that pfsync_bulk_update() lacks locking. To fix this, sc_bulk_tmo callout was converted to an mtx one. Eventually, all pf/pfsync callouts should be converted to mtx version, since it isn't possible to stop or drain a non-mtx callout without risk of race. - Add comment that callout_stop() in pfsync_clone_destroy() lacks locking. Since pfsync0 can't be destroyed (yet), let it be here.
r226662 | glebius | 2011-10-23 19:10:15 +0400 (вс, 23 окт 2011) | 2 lines
Fix indentation, no code changed.
r226663 | glebius | 2011-10-23 19:15:17 +0400 (вс, 23 окт 2011) | 4 lines
Merge several fixes to bulk update processing from OpenBSD. Merged revisions: 1.148, 1.149, 1.150. This makes number of states on master/slave to be of a sane value.
Approved by: re (kib)
|
226796 |
26-Oct-2011 |
bz |
MFC r226527:
Fix indentation in a loop and a tiny maze of #ifdefs for just the __FreeBSD__ parts that had it wrong.
MFC r226530:
Fix a bug when NPFSYNC > 0 that on FreeBSD we would always return and never remove state.
This fixes the problem some people are seeing that state is removed when pf is loaded as a module but not in situations when compiled into the kernel.
Approved by: re (kib)
|
226670 |
23-Oct-2011 |
brueffer |
MFC: r226406
Properly free resources in case of an error.
Approved by: re (kib)
|
226667 |
23-Oct-2011 |
brueffer |
MFC: r226398, r226442
Move the allocation of usrbufs down a few lines to avoid leaking it in case of an error.
Approved by: re (kib)
|
226640 |
22-Oct-2011 |
brueffer |
MFC: r226247, r226253
Properly free linux_gidset in case of an error.
Approved by: re (kib)
|
226637 |
22-Oct-2011 |
brueffer |
MFC: r226185
Add missing break statement to make sure all 3DES etypes really are treated the same.
Approved by: re (kib)
|
226572 |
20-Oct-2011 |
glebius |
MFhead 226401,226402:
Remove last remnants of classful addressing:
- Remove ia_net, ia_netmask, ia_netbroadcast from struct in_ifaddr. - Remove net.inet.ip.subnetsarelocal, I bet no one need it in 2011. - fix bug when we were not forwarding to a host which matches classful net address. For example router having 192.168.x.y/16 network attached, would not forward traffic to 192.168.*.0, which are legal IPs in CIDR world. - For compatibility, leave autoguessing of mask based on class.
Reviewed by: andre, bz, rwatson
Add support for IPv4 /31 prefixes, as described in RFC3021.
To run a /31 network, participating hosts MUST drop support for directed broadcasts, and treat the first and last addresses on subnet as unicast. The broadcast address for the prefix should be the link local broadcast address, INADDR_BROADCAST.
Approved by: re (kib)
|
226571 |
20-Oct-2011 |
glebius |
MFhead r226367:
Never switch directly from INIT to MASTER, since this produces nasty status flaps.
PR: kern/161123 Submitted by: Damien Fleuriot <dam my.gd> OpenBSD: ip_carp.c, rev. 1.115
Approved by: re (kib)
|
226570 |
20-Oct-2011 |
glebius |
MFhead r226338:
Restore functions in6_ifaddloop() and in6_ifremloop() that were inlined by Qing Li in his big new-ARP commit. I am going to utilize them in my newcarp work, and also these functions left declared in in6_var.h for all the time they were absent.
Reviewed by: bz
Approved by: re (kib)
|
226567 |
20-Oct-2011 |
nwhitehorn |
MFC r226410: Enforce a memory barrier in stream operations, as is done on other bus_space calls. This makes ath(4) work correctly on PowerPC.
Submitted by: adrian Tested by: andreast Approved by: re (kib)
|
226455 |
17-Oct-2011 |
qingli |
MFC 226453
The code change made in r226040 was incomplete and resulted in routes such as fe80::1%lo0 no being installed. This patch completes the original intended fix.
Reviewed by: hrs. bz Approved by: re (ken)
|
226389 |
15-Oct-2011 |
brueffer |
MFC: r226149
Fix an infinite loop in siba_bwn_suspend().
Approved by: re (kib)
|
226387 |
15-Oct-2011 |
brueffer |
MFC: r226146
Remove dead code, "error" doesn't change between this check and the previous one.
Approved by: re (kib)
|
226386 |
15-Oct-2011 |
brueffer |
MFC: r226117
Add missing va_end() in an error case to clean up after va_start() (already done in the non-error case).
Approved by: re (kib)
|
226385 |
15-Oct-2011 |
brueffer |
MFC: r226116
Add missing va_end() to clean up after va_start().
Approved by: re (kib)
|
226384 |
15-Oct-2011 |
brueffer |
MFC: r226143
Remove two dublicated assignments.
Approved by: re (kib)
|
226368 |
14-Oct-2011 |
delphij |
MFC r226082:
Return proper errno when we hit error when doing sanity check. This fixes dtrace crashes when module is not compiled with CTF data.
Submitted by: Paul Ambrose ambrosehua at gmail.com Approved by: re (kib)
|
226337 |
13-Oct-2011 |
qingli |
MFC 226120
PR: kern/159602 Submitted by: pluknet Approved by: re (kib)
|
226333 |
13-Oct-2011 |
qingli |
MFC 226114
Remove the reference held on the loopback route when the interface address is being deleted. Only the last reference holder deletes the loopback route. All other delete operations just clear the IFA_RTSELF flag.
PR: kern/159601 Submitted by: pluknet Reviewed by: discussed on net@ Approved by: re (kib)
|
226332 |
13-Oct-2011 |
qingli |
MFC 226040
The IFA_RTSELF instead of the IFA_ROUTE flag should be checked to determine if a loopback route should be installed for an interface IPv6 address. Another condition is the address must not belong to a looopback interface.
Reviewed by: hrs Approved by: re (kib)
|
226331 |
13-Oct-2011 |
qingli |
MFC 226224
All indirect routes will fail the rtcheck, except for a special host route where the destination IP and the gateway IP is the same. This special case handling is only meant for backward compatibility reason. The last commit introduced a bug in the route check logic, where a valid special case is treated as an error. This patch fixes that bug along with some code cleanup.
Suggested by: glebius smirnoff Reviewed by: kmacy, discussed with glebius smirnoff Approved by: re (hrs)
|
226326 |
12-Oct-2011 |
qingli |
MFC 225947
A system may have multiple physical interfaces, all of which are on the same prefix. Since a single route entry is installed for the prefix (without RADIX_MPATH), incoming packets on the interfaces that are not associated with the prefix route may trigger an error message about unable to allocation LLE entry, and fails L2. This patch makes sure a valid route is present in the system, and allow the aforementioned condition to exist and treats as valid.
Reviewed by: bz Approved by: re (kib)
|
226319 |
12-Oct-2011 |
kib |
Handle page dirty mask with atomics.
MFC r225838: Use the explicitly-sized types for the dirty and valid masks.
MFC r225840: Use the trick of performing the atomic operation on the contained aligned word to handle the dirty mask updates in vm_page_clear_dirty_mask().
MFC 225841 Remove locking of the vm page queues from several pmaps.
MFC r225843: Fix grammar.
MFC r225856: Style nit.
Approved by: re (bz)
|
226315 |
12-Oct-2011 |
marius |
MFC: r226176
Recognize the Intel(R) Centrino(R) Wireless-N 130.
PR: 161162 Submitted by: Mikhail Tsatsenko Approved by: re (kib)
|
226306 |
12-Oct-2011 |
hselasky |
MFC r226219 Fix panic due to re-using in-use modem unit number.
Approved by: re (kib)
|
226304 |
12-Oct-2011 |
tuexen |
MFC 226252: Use the most significant 6 bits of the dscp instead of the least significant ones. This has changed in the latest version of the socket API ID and provides backwards compatibility and gets it in syn with the usage of the IP_TOS socket option.
Approved by: re@
|
226303 |
12-Oct-2011 |
marius |
MFC r226118:
Sync with ahc(4)/ahd(4)/sym(4) etc: Zero any sense not transferred by the device as the SCSI specification mandates that any untransferred data should be assumed to be zero.
Reviewed by: ken Approved by: re (kib)
|
226299 |
12-Oct-2011 |
andre |
MFC r226105: Add back the IP header length to the total packet length field on raw IP sockets. It was deducted in ip_input() in preparation for protocols interested only in the payload.
On raw sockets the IP header should be delivered as it at came in from the network except for the byte order swaps in some fields.
Approved by: re (kib)
|
226295 |
12-Oct-2011 |
ed |
MFC r226099:
Tab should not blank cells.
It seems I was under the impression that a tab differs from a single forward tabulation, namely that it blanks the underlying cells. This seems not to be the case. They are identical.
This should fix applications like jove(1) that use tabs instead of explicit cursor position setting.
Reported by: Brett Glass <brett lariat net>
MFC r226183:
Properly use the cursor to bound the position for CUP.
We must take the origin region into account when clamping the cursor position.
Approved by: re@ (kib)
|
226288 |
12-Oct-2011 |
marius |
MFC: r226095
Merge from r225950 (merged to stable/9 in r226067):
Set the sense residual properly.
Reviewed by: ken Approved by: re (kib)
|
226287 |
12-Oct-2011 |
qingli |
MFC 225946
This patch allows ARP to work properly in the presence of self-referencing routes. This patch is a rework of r223862.
Reviewed by: bz, zec Approved by: re (kib)
|
226278 |
12-Oct-2011 |
tuexen |
MFC 226222: Get struct sctp_net_route in tune with struct route. struct route was changed in http://svn.freebsd.org/changeset/base/225698 and since then SCTP support was broken.
Approved by: re@
|
226268 |
11-Oct-2011 |
tuexen |
MFC 226203
When moving an stcb to a new inp and we copy over the list of bound addresses, update the last used address pointer. If not, it might result in a crash if the old inp goes away.
Approved by: re@
|
226267 |
11-Oct-2011 |
tuexen |
MFC 226168 Update the inp stored in a HB-timer when moving an stcb to a new inp. Use only this stored inp when processing a HB timeout. This fixes a bug which results in a crash.
Approved by: re@
|
226254 |
11-Oct-2011 |
attilio |
MFC r226060: Skip TCP_SIGNATURE calculation for INP_TIMEWAIT case.
Sponsored by: Sandvine Incorporated Approved by: re (kib)
|
226251 |
11-Oct-2011 |
kib |
MFC r226022: Move parts of the commit log for r166167, where Tor explained the interaction between vnode locks and vfs_busy(), into comment.
Approved by: re (bz)
|
226248 |
11-Oct-2011 |
kib |
MFC r225791: Do not deliver SIGTRAP on exec as the normal signal, use ptracestop() on syscall exit path. Otherwise, if SIGTRAP is ignored, that tdsendsignal() do not want to deliver the signal, and debugger never get a notification of exec.
Approved by: re (bz)
|
226231 |
10-Oct-2011 |
jkim |
MFC: r226068, r226069, r226071, r226072, r226073, r226074, r226078, r226079
- Unroll inlined strnlen(9) and make it easier to read. - Inline do_sa_get() function and remove an unused return value. - Retern more appropriate errno when Linux path name is too long. - Restore the original socket address length if it was not really AF_INET6. - Make sure to ignore the leading NULL byte from Linux abstract namespace. - Use uint32_t instead of u_int32_t. Fix style(9) nits. - Remove a now-defunct variable. - Use the caculated length instead of maximum length.
Approved by: re (kib)
|
226229 |
10-Oct-2011 |
jkim |
MFC: r226029
Add strnlen() to libkern.
Approved by: re (kib)
|
226228 |
10-Oct-2011 |
andre |
MFC r226113: Prevent TCP sessions from stalling indefinitely in reassembly when reaching the zone limit of reassembly queue entries.
Approved by: re (kib)
|
226209 |
10-Oct-2011 |
rmacklem |
MFC: r226081, r226104 A crash reported on freebsd-fs@ on Sep. 23, 2011 under the subject heading "kernel panics with RPCSEC_GSS" appears to be caused by a corrupted tailq list for the client structure. Looking at the code, calls to the function svc_rpc_gss_forget_client() were done in an SMP unsafe manner, with the svc_rpc_gss_lock only being acquired in the function and not before it. As such, when multiple threads called svc_rpc_gss_forget_client() concurrently, it could try and remove the same client structure from the tailq lists multiple times. The patch fixes this by moving the critical code into a separate function called svc_rpc_gss_forget_client_locked(), which must be called with the lock held. For the one case where the caller would have no interest in the lock, svc_rpc_gss_forget_client() was retained, but a loop was added to check that the client structure is still in the tailq lists before removing it, to make it safe for multiple concurrent calls. Also, remove an extraneous "already" from a comment introduced by r226081.
Approved by: re (kib)
|
226204 |
10-Oct-2011 |
kib |
MFC r225943: Do not allow the kernel to access usermode pages without installed fault handler. Panic immediately in such situation, on i386 and amd64.
Approved by: re (bz)
|
226202 |
10-Oct-2011 |
kib |
MFC r225942: Assert that exiting process does not return to usermode.
Approved by: re (bz)
|
226199 |
10-Oct-2011 |
kib |
MFC r225894: The sigwait(3) function shall not return EINTR, according to the POSIX/SUSvN. The sigwait(2) syscall does return EINTR, and libc.so.7 contains the wrapper sigwait(3) which hides EINTR from callers. The EINTR return is used by libthr to handle required cancellation point in the sigwait(3).
To help the binaries linked against pre-libc.so.7, i.e. RELENG_6 and earlier, to have right ABI for sigwait(3), transform EINTR return from sigwait(2) into ERESTART.
Approved by: re (bz)
|
226115 |
07-Oct-2011 |
delphij |
MFC r226026:
Add the 9750 SATA+SAS 6Gb/s RAID controller card driver, tws(4). Many thanks for their contiued support to FreeBSD.
This is version 10.80.00.003 from codeset 10.2.1 [1]
Obtained from: LSI http://kb.lsi.com/Download16574.aspx [1] Approved by: re (kib)
|
226092 |
07-Oct-2011 |
trasz |
MFC r225938:
Fix bug introduced in r225641, which would cause panic if racct_proc_fork() returned error -- the racct_destroy_locked() would get called twice.
MFC r225940:
Fix another bug introduced in r225641, which caused rctl to access certain fields in 'struct proc' before they got initialized in do_fork().
MFC r225944:
Move some code inside the racct_proc_fork(); it spares a few lock operations and it's more logical this way.
MFC r225981:
Actually enforce limit for inheritable resources on fork.
Approved by: re (kib)
|
226067 |
06-Oct-2011 |
ken |
MFC r225950:
Add descriptor sense support to CAM, and honor sense residuals properly in CAM.
Desriptor sense is a new sense data format that originated in SPC-3. Among other things, it allows for an 8-byte info field, which is necessary to pass back block numbers larger than 4 bytes.
This change adds a number of new functions to scsi_all.c (and therefore libcam) that abstract out most access to sense data.
This includes a bump of CAM_VERSION, because the CCB ABI has changed. Userland programs that use the CAM pass(4) driver will need to be recompiled.
camcontrol.c: Change uses of scsi_extract_sense() to use scsi_extract_sense_len().
Use scsi_get_sks() instead of accessing sense key specific data directly.
scsi_modes: Update the control mode page to the latest version (SPC-4).
scsi_cmds.c, scsi_target.c: Change references to struct scsi_sense_data to struct scsi_sense_data_fixed. This should be changed to allow the user to specify fixed or descriptor sense, and then use scsi_set_sense_data() to build the sense data.
ps3cdrom.c: Use scsi_set_sense_data() instead of setting sense data manually.
cam_periph.c: Use scsi_extract_sense_len() instead of using scsi_extract_sense() or accessing sense data directly.
cam_ccb.h: Bump the CAM_VERSION from 0x15 to 0x16. The change of struct scsi_sense_data from 32 to 252 bytes changes the size of struct ccb_scsiio, but not the size of union ccb. So the version must be bumped to prevent structure mis-matches.
scsi_all.h: Lots of updated SCSI sense data and other structures.
Add function prototypes for the new sense data functions.
Take out the inline implementation of scsi_extract_sense(). It is now too large to put in a header file.
Add macros to calculate whether fields are present and filled in fixed and descriptor sense data
scsi_all.c: In scsi_op_desc(), allow the user to pass in NULL inquiry data, and we'll assume a direct access device in that case.
Changed the SCSI RESERVED sense key name and description to COMPLETED, as it is now defined in the spec.
Change the error recovery action for a number of read errors to prevent lots of retries when the drive has said that the block isn't accessible. This speeds up reconstruction of the block by any RAID software running on top of the drive (e.g. ZFS).
In scsi_sense_desc(), allow for invalid sense key numbers. This allows calling this routine without checking the input values first.
Change scsi_error_action() to use scsi_extract_sense_len(), and handle things when invalid asc/ascq values are encountered.
Add a new routine, scsi_desc_iterate(), that will call the supplied function for every descriptor in descriptor format sense data.
Add scsi_set_sense_data(), and scsi_set_sense_data_va(), which build descriptor and fixed format sense data. They currently default to fixed format sense data.
Add a number of scsi_get_*() functions, which get different types of sense data fields from either fixed or descriptor format sense data, if the data is present.
Add a number of scsi_*_sbuf() functions, which print formatted versions of various sense data fields. These functions work for either fixed or descriptor sense.
Add a number of scsi_sense_*_sbuf() functions, which have a standard calling interface and print the indicated field. These functions take descriptors only.
Add scsi_sense_desc_sbuf(), which will print a formatted version of the given sense descriptor.
Pull out a majority of the scsi_sense_sbuf() function and put it into scsi_sense_only_sbuf(). This allows callers that don't use struct ccb_scsiio to easily utilize the printing routines. Revamp that function to handle descriptor sense and use the new sense fetching and printing routines.
Move scsi_extract_sense() into scsi_all.c, and implement it in terms of the new function, scsi_extract_sense_len(). The _len() version takes a length (which should be the sense length - residual) and can indicate which fields are present and valid in the sense data.
Add a couple of new scsi_get_*() routines to get the sense key, asc, and ascq only.
mly.c: Rename struct scsi_sense_data to struct scsi_sense_data_fixed.
sbp_targ.c: Use the new sense fetching routines to get sense data instead of accessing it directly.
sbp.c: Change the firewire/SCSI sense data transformation code to use struct scsi_sense_data_fixed instead of struct scsi_sense_data. This should be changed later to use scsi_set_sense_data().
ciss.c: Calculate the sense residual properly. Use scsi_get_sense_key() to fetch the sense key.
mps_sas.c, mpt_cam.c: Set the sense residual properly.
iir.c: Use scsi_set_sense_data() instead of building sense data by hand.
iscsi_subr.c: Use scsi_extract_sense_len() instead of grabbing sense data directly.
umass.c: Use scsi_set_sense_data() to build sense data.
Grab the sense key using scsi_get_sense_key().
Calculate the sense residual properly.
isp_freebsd.h: Use scsi_get_*() routines to grab asc, ascq, and sense key values.
Calculate and set the sense residual.
Approved by: re (kib) Sponsored by: Spectra Logic Corporation
|
226061 |
06-Oct-2011 |
ae |
MFC r225878: Add Oxford Semiconductor OXPCIe952 (0x1c38) 1 port serial card.
PR: kern/160895 Submitted by: Konstantin V. Krotov
Approved by: re (kib)
|
225971 |
04-Oct-2011 |
bz |
MFC r225885:
Fix an obvious bug from r186196 shadowing a variable, not correctly appending the new mbuf to the chain reference but possibly causing an mbuf nextpkt loop leading to a memory used after handoff (or having been freed) and leaking an mbuf here.
Reviewed by: rwatson, brooks Approved by: re (kib)
|
225970 |
04-Oct-2011 |
bz |
MFC r225837:
Pass the fibnum where we need filtering of the message on the rtsock allowing routing daemons to filter routing updates on an rtsock per FIB.
Adjust raw_input() and split it into wrapper and a new function taking an optional callback argument even though we only have one consumer [1] to keep the hackish flags local to rtsock.c.
Submitted by: multiple (see PR) Suggested by: rwatson [1] Reviewed by: rwatson PR: kern/134931 Approved by: re (kib)
|
225965 |
04-Oct-2011 |
bz |
MFC r225793:
Unbreak no-ip and no-inet6 module builds with ipfw. For now continue to build the ip_fw_pfil.c hooks and ipfw even in case of no-ip under the assumption that the private L2 hook (which hopefully eventually will be a pfil hook as well) can still be useful.
Allow building the module without inet as well.
Approved by: re (kib)
|
225963 |
04-Oct-2011 |
mav |
MFC 225953: Revert r225875, r225877: It is reported that on some chips (e.g. the 970MP) behavior of POW bit set simultaneously with modifying other bits is undefined and may cause hangs. The race should be handled in some other way, but for now just get back.
Reported by: nwitehorn Approved by: re (kib)
|
225918 |
02-Oct-2011 |
mav |
MFC r225869: - Add special support for the MFI_CMD ioctl with MFI_CMD_STP command, used by present MegaCLI version. It has some special meaning for the first s/g list entry, while the main s/g list begins from the the second entry, and those lists should remain separate after loading to the busdma map. - Fix bug in 32bit ioctl compatibility shims when s/g list consists of more then on element.
Approved by: re (kib)
|
225917 |
02-Oct-2011 |
mav |
MFC r225875, r225877: Handle the race in cpu_idle() when due to the critical section CPU could get into sleep after receiving interrupt, delaying interrupt thread execution indefinitely until the next interrupt arrive.
Reviewed by: nwhitehorn Approved by: re (kib)
|
225873 |
29-Sep-2011 |
mav |
MFC r225789: Add one more ID for the Marvell 88SE9128 6Gbps SATA controller.
Approved by: re (kib)
|
225799 |
27-Sep-2011 |
mav |
MFC r225788: Fix interrupt counters dumping on SW_WATCHDOG fire.
Approved by: re (kib)
|
225797 |
27-Sep-2011 |
attilio |
Backout r225372. Eventhandler mutex cannot be acquired in kernel context.
Sponsored by: Sandvine Incorporated Approved by: re (kib)
|
225736 |
23-Sep-2011 |
kensmith |
Copy head to stable/9 as part of 9.0-RELEASE release cycle.
Approved by: re (implicit)
|
225171 |
25-Aug-2011 |
bz |
Use the correct byte order for the ip_divert(4) mbuf tag port meta information in pf(4).
Submitted by: Yaocl (chunlinyao gmail.com), forum post 145106 Approved by: re (kib)
|
224936 |
17-Aug-2011 |
pluknet |
Fix build failure without BPF.
Reported by: deeptech71 at gmail dot com Approved by: re (kib)
|
223758 |
04-Jul-2011 |
attilio |
With retirement of cpumask_t and usage of cpuset_t for representing a mask of CPUs, pc_other_cpus and pc_cpumask become highly inefficient.
Remove them and replace their usage with custom pc_cpuid magic (as, atm, pc_cpumask can be easilly represented by (1 << pc_cpuid) and pc_other_cpus by (all_cpus & ~(1 << pc_cpuid))).
This change is not targeted for MFC because of struct pcpu members removal and dependency by cpumask_t retirement.
MD review by: marcel, marius, alc Tested by: pluknet MD testing by: marcel, marius, gonzo, andreast
|
223637 |
28-Jun-2011 |
bz |
Update packet filter (pf) code to OpenBSD 4.5.
You need to update userland (world and ports) tools to be in sync with the kernel.
Submitted by: mlaier Submitted by: eri
|
222813 |
07-Jun-2011 |
attilio |
etire the cpumask_t type and replace it with cpuset_t usage.
This is intended to fix the bug where cpu mask objects are capped to 32. MAXCPU, then, can now arbitrarely bumped to whatever value. Anyway, as long as several structures in the kernel are statically allocated and sized as MAXCPU, it is suggested to keep it as low as possible for the time being.
Technical notes on this commit itself: - More functions to handle with cpuset_t objects are introduced. The most notable are cpusetobj_ffs() (which calculates a ffs(3) for a cpuset_t object), cpusetobj_strprint() (which prepares a string representing a cpuset_t object) and cpusetobj_strscan() (which creates a valid cpuset_t starting from a string representation). - pc_cpumask and pc_other_cpus are target to be removed soon. With the moving from cpumask_t to cpuset_t they are now inefficient and not really useful. Anyway, for the time being, please note that access to pcpu datas is protected by sched_pin() in order to avoid migrating the CPU while reading more than one (possible) word - Please note that size of cpuset_t objects may differ between kernel and userland. While this is not directly related to the patch itself, it is good to understand that concept and possibly use the patch as a reference on how to deal with cpuset_t objects in userland, when accessing kernland members. - KTR_CPUMASK is changed and now is represented through a string, to be set as the example reported in NOTES.
Please additively note that no MAXCPU is bumped in this patch, but private testing has been done until to MAXCPU=128 on a real 8x8x2(htt) machine (amd64).
Please note that the FreeBSD version is not yet bumped because of the upcoming pcpu changes. However, note that this patch is not targeted for MFC.
People to thank for the time spent on this patch: - sbruno, pluknet and Nicholas Esborn (nick AT desert DOT net) tested several revision of the patches and really helped in improving stability of this work. - marius fixed several bugs in the sparc64 implementation and reviewed patches related to ktr. - jeff and jhb discussed the basic approach followed. - kib and marcel made targeted review on some specific part of the patch. - marius, art, nwhitehorn and andreast reviewed MD specific part of the patch. - marius, andreast, gonzo, nwhitehorn and jceel tested MD specific implementations of the patch. - Other people have made contributions on other patches that have been already committed and have been listed separately.
Companies that should be mentioned for having participated at several degrees: - Yahoo! for having offered the machines used for testing on big count of CPUs. - The FreeBSD Foundation for having sponsored my devsummit attendance, which has been instrumental. - Sandvine for having offered offices and infrastructure during development.
(I really hope I didn't forget anyone, if it happened I apologize in advance).
|
222691 |
04-Jun-2011 |
rwatson |
Add _mbuf() variants of various inpcb-related interfaces, including lookup, hash install, etc. For now, these are arguments are unused, but as we add RSS support, we will want to use hashes extracted from mbufs, rather than manually calculated hashes of header fields, due to the expensive of the software version of Toeplitz (and similar hashes).
Add notes that it would be nice to be able to pass mbufs into lookup routines in pf(4), optimising firewall lookup in the same way, but the code structure there doesn't facilitate that currently.
(In principle there is no reason this couldn't be MFCed -- the change extends rather than modifies the KBI. However, it won't be useful without other previous possibly less MFCable changes.)
Reviewed by: bz Sponsored by: Juniper Networks, Inc.
|
222544 |
31-May-2011 |
jkim |
Merge ACPICA 20110527.
|
222529 |
31-May-2011 |
bz |
Remove some further INET related symbols from pf to allow the module to not only compile bu load as well for testing with IPv6-only kernels. For the moment we ignore the csum change in pf_ioctl.c given the pending update to pf45.
Reported by: dru Sponsored by: The FreeBSD Foundation Sponsored by: iXsystems MFC after: 20 days
|
222488 |
30-May-2011 |
rwatson |
Decompose the current single inpcbinfo lock into two locks:
- The existing ipi_lock continues to protect the global inpcb list and inpcb counter. This lock is now relegated to a small number of allocation and free operations, and occasional operations that walk all connections (including, awkwardly, certain UDP multicast receive operations -- something to revisit).
- A new ipi_hash_lock protects the two inpcbinfo hash tables for looking up connections and bound sockets, manipulated using new INP_HASH_*() macros. This lock, combined with inpcb locks, protects the 4-tuple address space.
Unlike the current ipi_lock, ipi_hash_lock follows the individual inpcb connection locks, so may be acquired while manipulating a connection on which a lock is already held, avoiding the need to acquire the inpcbinfo lock preemptively when a binding change might later be required. As a result, however, lookup operations necessarily go through a reference acquire while holding the lookup lock, later acquiring an inpcb lock -- if required.
A new function in_pcblookup() looks up connections, and accepts flags indicating how to return the inpcb. Due to lock order changes, callers no longer need acquire locks before performing a lookup: the lookup routine will acquire the ipi_hash_lock as needed. In the future, it will also be able to use alternative lookup and locking strategies transparently to callers, such as pcbgroup lookup. New lookup flags are, supplementing the existing INPLOOKUP_WILDCARD flag:
INPLOOKUP_RLOCKPCB - Acquire a read lock on the returned inpcb INPLOOKUP_WLOCKPCB - Acquire a write lock on the returned inpcb
Callers must pass exactly one of these flags (for the time being).
Some notes:
- All protocols are updated to work within the new regime; especially, TCP, UDPv4, and UDPv6. pcbinfo ipi_lock acquisitions are largely eliminated, and global hash lock hold times are dramatically reduced compared to previous locking. - The TCP syncache still relies on the pcbinfo lock, something that we may want to revisit. - Support for reverting to the FreeBSD 7.x locking strategy in TCP input is no longer available -- hash lookup locks are now held only very briefly during inpcb lookup, rather than for potentially extended periods. However, the pcbinfo ipi_lock will still be acquired if a connection state might change such that a connection is added or removed. - Raw IP sockets continue to use the pcbinfo ipi_lock for protection, due to maintaining their own hash tables. - The interface in6_pcblookup_hash_locked() is maintained, which allows callers to acquire hash locks and perform one or more lookups atomically with 4-tuple allocation: this is required only for TCPv6, as there is no in6_pcbconnect_setup(), which there should be. - UDPv6 locking remains significantly more conservative than UDPv4 locking, which relates to source address selection. This needs attention, as it likely significantly reduces parallelism in this code for multithreaded socket use (such as in BIND). - In the UDPv4 and UDPv6 multicast cases, we need to revisit locking somewhat, as they relied on ipi_lock to stablise 4-tuple matches, which is no longer sufficient. A second check once the inpcb lock is held should do the trick, keeping the general case from requiring the inpcb lock for every inpcb visited. - This work reminds us that we need to revisit locking of the v4/v6 flags, which may be accessed lock-free both before and after this change. - Right now, a single lock name is used for the pcbhash lock -- this is undesirable, and probably another argument is required to take care of this (or a char array name field in the pcbinfo?).
This is not an MFC candidate for 8.x due to its impact on lookup and locking semantics. It's possible some of these issues could be worked around with compatibility wrappers, if necessary.
Reviewed by: bz Sponsored by: Juniper Networks, Inc.
|
221132 |
27-Apr-2011 |
bz |
Make pf compile without INET support by adding #ifdef INETs and correcting few #includes.
Reviewed by: gnn Sponsored by: The FreeBSD Foundation Sponsored by: iXsystems MFC after: 4 days
|
220893 |
20-Apr-2011 |
bschmidt |
Add firmware images for the 6000 series g2a and g2b adapters.
|
220892 |
20-Apr-2011 |
bschmidt |
Update iwn(4) firmware blobs: - bump iwn1000fw to 39.31.5.1 - bump iwn5000fw to 8.83.5.1 - bump iwn6050fw to 41.28.5.1
|
220681 |
15-Apr-2011 |
jkim |
Re-merge with ACPICA vendor source.
|
220663 |
15-Apr-2011 |
jkim |
Merge ACPICA 20110413.
|
220433 |
07-Apr-2011 |
jkim |
Use atomic load & store for TSC frequency. It may be overkill for amd64 but safer for i386 because it can be easily over 4 GHz now. More worse, it can be easily changed by user with 'machdep.tsc_freq' tunable (directly) or cpufreq(4) (indirectly). Note it is intentionally not used in performance critical paths to avoid performance regression (but we should, in theory). Alternatively, we may add "virtual TSC" with lower frequency if maximum frequency overflows 32 bits (and ignore possible incoherency as we do now).
|
219707 |
17-Mar-2011 |
jkim |
Merge ACPICA 20110316.
|
219694 |
16-Mar-2011 |
jmallett |
o) Clean up FPA pools on module unload. o) Allocate output buffer pool based on available output queues.
Submitted by: Bhanu Prakash (with modifications)
|
219673 |
15-Mar-2011 |
jkim |
Deprecate tsc_present as the last of its real consumers finally disappeared.
|
219473 |
11-Mar-2011 |
jkim |
Add a tunable "machdep.disable_tsc" to turn off TSC. Specifically, it turns off boot-time CPU frequency calibration, DELAY(9) with TSC, and using TSC as a CPU ticker. Note tsc_present does not change by this tunable.
|
219461 |
10-Mar-2011 |
jkim |
Deprecate rarely used tsc_is_broken. Instead, we zero out tsc_freq because it is almost always used with tsc_freq any way.
|
219459 |
10-Mar-2011 |
jkim |
Remove alpha reminiscence from altq.
|
219458 |
10-Mar-2011 |
jkim |
Consistently add TSC support for amd64.
|
219457 |
10-Mar-2011 |
jkim |
Remove support for FreeBSD 4.x and below.
|
218590 |
12-Feb-2011 |
jkim |
Merge ACPICA 20110211.
|
217388 |
14-Jan-2011 |
csjp |
Correct bogus initialization. It should be noted that this change has been corrected in the vendor branch, but for now, silence clang warnings.
Found by: clang Discussed with: mlaier MFC after: 1 week
|
217365 |
13-Jan-2011 |
jkim |
Merge ACPICA 20110112. Switch to BSD/GPLv2 dual license[1].
Discussed with: core [1]
|
217214 |
10-Jan-2011 |
jmallett |
o) Expand the CIU driver to be aware of newly-allocated parts of the IRQ range. o) Add 'octm', a trivial driver for the 10/100 management ports found on some Octeon systems. o) Make the Simple Executive's management port helper routines compile on FreeBSD (namely by not doing math on void pointers.) o) Add a cvmx_mgmt_port_sendm routine to the Simple Executive to send an mbuf so there is only one copy in the transmit path, rather than having to first copy the mbuf to an intermediate buffer and then copy that to the Simple Executive's transmit ring. o) Properly work out MII addresses of management ports on the Lanner MR-730. XXX The MR-730 also needs some patches to the MII read/write routines, but this is sufficient for now. Media detection will be fixed in the future when I can spend more time reading the vendor-supplied patches.
|
216559 |
19-Dec-2010 |
bschmidt |
Update firmware for wpi(4) from version 2.14.4 to 15.32.2.9.
PR: kern/142907 Submitted by: Craig Butler <craig001 at lerwick.hopto.org> MFC after: 2 weeks
|
216476 |
16-Dec-2010 |
jmallett |
o) Add support for the Lanner MR-321X/MR-325, which is just a modified MR-320. o) On the Lanner MR-730, disable PCIe lane swap, per vendor.
|
216471 |
15-Dec-2010 |
jkim |
Merge ACPICA 20101209.
|
215990 |
28-Nov-2010 |
jmallett |
Merge Cavium Octeon SDK 2.0 Simple Executive; this brings some fixes and new facilities as well as support for the Octeon 2 family of SoCs.
XXX Note that with our antediluvian assembler, we can't support some Octeon 2 instructions and fall back to using the old ones instead.
|
215681 |
22-Nov-2010 |
jhb |
Remove some bogus, self-referential mergeinfo.
|
215014 |
08-Nov-2010 |
jmallett |
o) Recognize the Lanner MR-730. o) Fix enumeration of PHY addresses on the MR-955. o) Parse link state for the MR-730 using the Broadcom PHY support in the SDK. It's not clear that this is entirely-correct, but it seems to work. Since this board uses a BCM5482S, this may mean that we work correctly for copper but not SFI, which is untested.
|
213806 |
13-Oct-2010 |
jkim |
Merge ACPICA 20101013.
|
213792 |
13-Oct-2010 |
rpaulo |
Ignore the return value of ADDCARRY().
|
213789 |
13-Oct-2010 |
rpaulo |
Properly tell the compiler that we want to ignore the return value of certain macros.
|
213788 |
13-Oct-2010 |
rpaulo |
Fix several cases were a conditional operator was used instead of a bitwise operator.
Found with: clang
|
213782 |
13-Oct-2010 |
rpaulo |
Pass a format string to make_dev().
Found by: clang
|
213346 |
02-Oct-2010 |
jmallett |
o) Allow devices to override the MDIO read and write functions presented to the miibus attached to octe interfaces. o) Add an SMI/MDIO interface to the MV88E61XX and use it for the switch PHY on the Lanner MR-320. An actual driver for the switch PHY will come later. Note that for now it intercepts and fakes MII_BMSR reads to prevent the miibus from talking to anything but the switch itself.
|
212844 |
19-Sep-2010 |
jmallett |
Add preliminary support for the Lanner MR-955. It boots multi-user but there seem to be problems both with the on-board Ethernet interfaces and the em(4) interfaces on PCI under FreeBSD.
Thanks to Lanner for providing access to hardware.
|
212761 |
16-Sep-2010 |
jkim |
Merge ACPICA 20100915.
|
212403 |
10-Sep-2010 |
bz |
When using pf routing options, properly handle IP fragmentation for interfaces with TSO enabled, otherwise one would see an extra ICMP unreach, frag needed pre matching packet on lo0. This syncs pf code to ip_output.c r162084.
PR: kern/144311 Submitted by: yongari via mlaier Reviewed by: eri Tested by: kib MFC after: 8 days
|
210976 |
06-Aug-2010 |
jkim |
Merge ACPICA 20100806.
|
210311 |
20-Jul-2010 |
jmallett |
Update the port of FreeBSD to Cavium Octeon to use the Cavium Simple Executive library: o) Increase inline unit / large function growth limits for MIPS to accommodate the needs of the Simple Executive, which uses a shocking amount of inlining. o) Remove TARGET_OCTEON and use CPU_CNMIPS to do things required by cnMIPS and the Octeon SoC. o) Add OCTEON_VENDOR_LANNER to use Lanner's allocation of vendor-specific board numbers, specifically to support the MR320. o) Add OCTEON_BOARD_CAPK_0100ND to hard-wire configuration for the CAPK-0100nd, which improperly uses an evaluation board's board number and breaks board detection at runtime. This board is sold by Portwell as the CAM-0100. o) Add support for the RTC available on some Octeon boards. o) Add support for the Octeon PCI bus. Note that rman_[sg]et_virtual for IO ports can not work unless building for n64. o) Clean up the CompactFlash driver to use Simple Executive macros and structures where possible (it would be advisable to use the Simple Executive API to set the PIO mode, too, but that is not done presently.) Also use structures from FreeBSD's ATA layer rather than structures copied from Linux. o) Print available Octeon SoC features on boot. o) Add support for the Octeon timecounter. o) Use the Simple Executive's routines rather than local copies for doing reads and writes to 64-bit addresses and use its macros for various device addresses rather than using local copies. o) Rename octeon_board_real to octeon_is_simulation to reduce differences with Cavium-provided code originally written for Linux. Also make it use the same simplified test that the Simple Executive and Linux both use rather than our complex one. o) Add support for the Octeon CIU, which is the main interrupt unit, as a bus to use normal interrupt allocation and setup routines. o) Use the Simple Executive's bootmem facility to allocate physical memory for the kernel, rather than assuming we know which addresses we can steal. NB: This may reduce the amount of RAM the kernel reports you as having if you are leaving large temporary allocations made by U-Boot allocated when starting FreeBSD. o) Add a port of the Cavium-provided Ethernet driver for Linux. This changes Ethernet interface naming from rgmxN to octeN. The new driver has vast improvements over the old one, both in performance and functionality, but does still have some features which have not been ported entirely and there may be unimplemented code that can be hit in everyday use. I will make every effort to correct those as they are reported. o) Support loading the kernel on non-contiguous cores. o) Add very conservative support for harvesting randomness from the Octeon random number device. o) Turn SMP on by default. o) Clean up the style of the Octeon kernel configurations a little and make them compile with -march=octeon. o) Add support for the Lanner MR320 and the CAPK-0100nd to the Simple Executive. o) Modify the Simple Executive to build on FreeBSD and to build without executive-config.h or cvmx-config.h. In the future we may want to revert part of these changes and supply executive-config.h and cvmx-config.h and access to the options contained in those files via kernel configuration files. o) Modify the Simple Executive USB routines to support getting and setting of the USB PID.
|
210286 |
20-Jul-2010 |
jmallett |
Import the Cavium Simple Executive from the Cavium Octeon SDK. The Simple Executive is a library that can be used by standalone applications and kernels to abstract access to Octeon SoC and board-specific hardware and facilities. The FreeBSD port to Octeon will be updated to use this where possible.
|
210113 |
15-Jul-2010 |
bschmidt |
- Update 6000 firmware to 9.221.4.1 - Add 6050 firmware
MFC after: 2 weeks
|
209746 |
06-Jul-2010 |
jkim |
Merge ACPICA 20100702.
|
208750 |
02-Jun-2010 |
raj |
Provide kernel level headers for the libfdt code.
Reviewed by: imp Sponsored by: The FreeBSD Foundation
|
208019 |
13-May-2010 |
thompsa |
Sync run(4) driver from author's site.
Submitted by: Akinori Furukoshi Obtained from: git://gitorious.org/run/run.git
|
207736 |
07-May-2010 |
mckusick |
Merger of the quota64 project into head.
This joint work of Dag-Erling Smørgrav and myself updates the FFS quota system to support both traditional 32-bit and new 64-bit quotas (for those of you who want to put 2+Tb quotas on your users).
By default quotas are not compiled into the kernel. To include them in your kernel configuration you need to specify:
options QUOTA # Enable FFS quotas
If you are already running with the current 32-bit quotas, they should continue to work just as they have in the past. If you wish to convert to using 64-bit quotas, use `quotacheck -c 64'; if you wish to revert from 64-bit quotas back to 32-bit quotas, use `quotacheck -c 32'.
There is a new library of functions to simplify the use of the quota system, do `man quotafile' for details. If your application is currently using the quotactl(2), it is highly recommended that you convert your application to use the quotafile interface. Note that existing binaries will continue to work.
Special thanks to John Kozubik of rsync.net for getting me interested in pursuing 64-bit quota support and for funding part of my development time on this project.
|
207369 |
29-Apr-2010 |
bz |
MFP4: @176978-176982, 176984, 176990-176994, 177441
"Whitspace" churn after the VIMAGE/VNET whirls.
Remove the need for some "init" functions within the network stack, like pim6_init(), icmp_init() or significantly shorten others like ip6_init() and nd6_init(), using static initialization again where possible and formerly missed.
Move (most) variables back to the place they used to be before the container structs and VIMAGE_GLOABLS (before r185088) and try to reduce the diff to stable/7 and earlier as good as possible, to help out-of-tree consumers to update from 6.x or 7.x to 8 or 9.
This also removes some header file pollution for putatively static global variables.
Revert VIMAGE specific changes in ipfilter::ip_auth.c, that are no longer needed.
Reviewed by: jhb Discussed with: rwatson Sponsored by: The FreeBSD Foundation Sponsored by: CK Software GmbH MFC after: 6 days
|
207344 |
28-Apr-2010 |
jkim |
Merge ACPICA 20100428.
|
206627 |
14-Apr-2010 |
imp |
We don't need the definition for in_cksum repeated here since we get it from machine/in_cksum.h. This definition prevents us from using hand-tuned assembler versions of in_cksum.
# this fixes the modules build on arm for ipfilter.
|
206446 |
10-Apr-2010 |
bschmidt |
Update firmware for the 6000 series Intel cards to version 9.193.4.1.
Approved by: rpaulo (mentor) MFC after: 2 weeks
|
206117 |
02-Apr-2010 |
jkim |
Merge ACPICA 20100331 (and four additional upstream patches).
|
204934 |
09-Mar-2010 |
delphij |
Integrate OpenBSD rev 1.5 of x86emu.c.
|
204920 |
09-Mar-2010 |
jkim |
Since the interpreter slack mode is a tunable now, enable a local hack only when it is set. Note the default behaviour does not change by this change.
|
204773 |
05-Mar-2010 |
jkim |
Merge ACPICA 20100304.
|
204488 |
28-Feb-2010 |
raj |
Merge DTC-d75b33af.
This is a split merge because of non-uniform licensing of the DTC package contents and the way these components will be used in the FreeBSD environment.
The original DTC package is composed of the following two major pieces:
1. sys/contrib/libfdt (BSD [dual] license) 2. contrib/dtc (GPLv2)
The libfdt component is going to be shared in all aspects of the environment: - /boot/loader - kernel - dtc (the device tree compiler proper, userspace tool)
|
203148 |
29-Jan-2010 |
thompsa |
Uuencode the rt2870 firmware into ascii like the other firmware blobs.
|
203134 |
28-Jan-2010 |
thompsa |
Add run(4), a driver for Ralink RT2700U/RT2800U/RT3000U USB 802.11agn devices.
This driver was written for OpenBSD by Damien Bergamini and ported over by Akinori Furukoshi.
|
202773 |
21-Jan-2010 |
jkim |
Fix a new header inclusion.
|
202771 |
21-Jan-2010 |
jkim |
Merge ACPICA 20100121.
|
202607 |
19-Jan-2010 |
weongyo |
Fixes a firmware bug that in some devices (e.g. Netgear WG111T or TRENDnet TEW-504UB/EU) idProduct didn't be decreased after loading the firmware.
Pointed by: Steven Friedrich <freebsd at insightbb.com> Reviewed by: sam
|
201818 |
08-Jan-2010 |
trasz |
Fix array overflow.
Reviewed by: philip
|
201212 |
29-Dec-2009 |
rpaulo |
Delete old firmware.
|
201209 |
29-Dec-2009 |
rpaulo |
iwn(4) update. Notable changes: * new firmware * untested support for 1000 and 6000 series * bgscan support * remove unnecessary RXON changes * allow setting of country/regdomain by enforcing channel flags read from the EEPROM * suspend/resume fixes * RF kill switch fixes * LED adjustments * several bus_dma*() related fixes * addressed some LORs * many other bug fixes
Submitted by: Bernhard Schmidt <bschmidt at techwires.net> Obtained from: Brandon Gooch <jamesbrandongooch at gmail dot com> (LED related changes), Benjamin Kaduk <kaduk at mit dot edu> (LOR fixes), OpenBSD
|
200930 |
24-Dec-2009 |
delphij |
Adapt OpenBSD pf's "sloopy" TCP state machine which is useful for Direct Server Return mode, where not all packets would be visible to the load balancer or gateway.
This commit should be reverted when we merge future pf versions. The benefit it would provide is that this version does not break any existing public interface and thus won't be a problem if we want to MFC it to earlier FreeBSD releases.
Discussed with: mlaier Obtained from: OpenBSD Sponsored by: iXsystems, Inc. MFC after: 1 month
|
200553 |
14-Dec-2009 |
jkim |
Merge ACPICA 20091214.
|
199337 |
16-Nov-2009 |
jkim |
Merge ACPICA 20091112.
|
199223 |
12-Nov-2009 |
attilio |
Remove the explicit definition of inet_aton() as it was introduced as a general function in r199208.
Reported by: np Sponsored by: Sandvine Incorporated MFC: 1 week
|
198952 |
05-Nov-2009 |
brueffer |
Fix two memory leaks in error cases.
PR: 138378 Submitted by: Patroklos Argyroudis <argp@census-labs.com> Approved by: mlaier MFC after: 1 week
|
198429 |
23-Oct-2009 |
rpaulo |
Updated iwn(4) driver supporting the newer series, 5000, 5150 and 5300.
Submitted by: Bernhard Schmidt <bschmidt at techwires.net>
|
198251 |
19-Oct-2009 |
jkim |
Rewrite x86bios and update its dependent drivers.
- Do not map entire real mode memory (1MB). Instead, we map IVT/BDA and ROM area separately. Most notably, ROM area is mapped as device memory (uncacheable) as it should be. User memory is dynamically allocated and free'ed with contigmalloc(9) and contigfree(9). Remove now redundant and potentially dangerous x86bios_alloc.c. If this emulator ever grows to support non-PC hardware, we may implement it with rman(9) later. - Move all host-specific initializations from x86emu_util.c to x86bios.c and remove now unnecessary x86emu_util.c. Currently, non-PC hardware is not supported. We may use bus_space(9) later when the KPI is fixed. - Replace all bzero() calls for emulated registers with more obviously named x86bios_init_regs(). This function also initializes DS and SS properly. - Add x86bios_get_intr(). This function checks if the interrupt vector is available for the platform. It is not necessary for PC-compatible hardware but it may be needed later. ;-) - Do not try turning off monitor if DPMS does not support the state. - Allocate stable memory for VESA OEM strings instead of just holding pointers to them. They may or may not be accessible always. Fix a memory leak of video mode table while I am here. - Add (experimental) BIOS POST call for vesa(4). This function calls VGA BIOS POST code from the current VGA option ROM. Some video controllers cannot save and restore the state properly even if it is claimed to be supported. Usually the symptom is blank display after resuming from suspend state. If the video mode does not match the previous mode after restoring, we try BIOS POST and force the known good initial state. Some magic was taken from NetBSD (and it was taken from vbetool, I believe.) - Add a loader tunable for vgapci(4) to give a hint to dpms(4) and vesa(4) to identify who owns the VESA BIOS. This is very useful for multi-display adapter setup. By default, the POST video controller is automatically probed and the tunable "hw.pci.default_vgapci_unit" is set to corresponding vgapci unit number. You may override it from loader but it is very unlikely to be necessary. Unfortunately only AGP/PCI/PCI-E controllers can be matched because ISA controller does not have necessary device IDs. - Fix a long standing bug in state save/restore function. The state buffer pointer should be ES:BX, not ES:DI according to VBE 3.0. If it ever worked, that's because BX was always zero. :-) - Clean up register initializations more clearer per VBE 3.0. - Fix a lot of style issues with vesa(4).
|
198237 |
19-Oct-2009 |
jkim |
Merge ACPICA 20091013.
|
197386 |
21-Sep-2009 |
delphij |
Use __FBSDID to embed RCS ID.
|
197383 |
21-Sep-2009 |
delphij |
Collapase interrupt supporting functions to a new module, and switch from x86emu to this new module.
This changeset also brings a fix for bugs introduced with the initial x86emu commit, which prevents the user from using some display mode or cause instant reboots during mode switch.
Submitted by: paradox <ddkprog yahoo com>
|
197107 |
11-Sep-2009 |
jkim |
Canonify include paths for newly added files.
|
197104 |
11-Sep-2009 |
jkim |
MFV: r196804
Import ACPICA 20090903
|
197019 |
09-Sep-2009 |
delphij |
- Port x86emu to FreeBSD. - Connect x86emu to build.
Tested with: make universe Submitted by: swell.k at gmail com
|
197009 |
09-Sep-2009 |
delphij |
Import x86emu from OpenBSD as of OPENBSD_4_6.
|
196970 |
08-Sep-2009 |
phk |
Revert previous commit and add myself to the list of people who should know better than to commit with a cat in the area.
|
196969 |
08-Sep-2009 |
phk |
Add necessary include.
|
196551 |
25-Aug-2009 |
mlaier |
Fix argument ordering to memcpy as well as the size of the copy in the (theoretical) case that pfi_buffer_cnt should be greater than ~_max.
Submitted by: pjd Reviewed by: {krw,sthen,markus}@openbsd.org MFC after: 3 days
|
196481 |
23-Aug-2009 |
rwatson |
Rework global locks for interface list and index management, correcting several critical bugs, including race conditions and lock order issues:
Replace the single rwlock, ifnet_lock, with two locks, an rwlock and an sxlock. Either can be held to stablize the lists and indexes, but both are required to write. This allows the list to be held stable in both network interrupt contexts and sleepable user threads across sleeping memory allocations or device driver interactions. As before, writes to the interface list must occur from sleepable contexts.
Reviewed by: bz, julian MFC after: 3 days
|
196372 |
19-Aug-2009 |
mlaier |
If we cannot immediately get the pf_consistency_lock in the purge thread, restart the scan after acquiring the lock the hard way. Otherwise we might end up with a dead reference.
Reported by: pfsense Reviewed by: eri Initial patch by: eri Tested by: pfsense Approved by: re (kib)
|
196039 |
02-Aug-2009 |
rwatson |
Many network stack subsystems use a single global data structure to hold all pertinent statatistics for the subsystem. These structures are sometimes "borrowed" by kernel modules that require a place to store statistics for similar events.
Add KPI accessor functions for statistics structures referenced by kernel modules so that they no longer encode certain specifics of how the data structures are named and stored. This change is intended to make it easier to move to per-CPU network stats following 8.0-RELEASE.
The following modules are affected by this change:
if_bridge if_cxgb if_gif ip_mroute ipdivert pf
In practice, most of these statistics consumers should, in fact, maintain their own statistics data structures rather than borrowing structures from the base network stack. However, that change is too agressive for this point in the release cycle.
Reviewed by: bz Approved by: re (kib)
|
196019 |
01-Aug-2009 |
rwatson |
Merge the remainder of kern_vimage.c and vimage.h into vnet.c and vnet.h, we now use jails (rather than vimages) as the abstraction for virtualization management, and what remained was specific to virtual network stacks. Minor cleanups are done in the process, and comments updated to reflect these changes.
Reviewed by: bz Approved by: re (vimage blanket)
|
195699 |
14-Jul-2009 |
rwatson |
Build on Jeff Roberson's linker-set based dynamic per-CPU allocator (DPCPU), as suggested by Peter Wemm, and implement a new per-virtual network stack memory allocator. Modify vnet to use the allocator instead of monolithic global container structures (vinet, ...). This change solves many binary compatibility problems associated with VIMAGE, and restores ELF symbols for virtualized global variables.
Each virtualized global variable exists as a "reference copy", and also once per virtual network stack. Virtualized global variables are tagged at compile-time, placing the in a special linker set, which is loaded into a contiguous region of kernel memory. Virtualized global variables in the base kernel are linked as normal, but those in modules are copied and relocated to a reserved portion of the kernel's vnet region with the help of a the kernel linker.
Virtualized global variables exist in per-vnet memory set up when the network stack instance is created, and are initialized statically from the reference copy. Run-time access occurs via an accessor macro, which converts from the current vnet and requested symbol to a per-vnet address. When "options VIMAGE" is not compiled into the kernel, normal global ELF symbols will be used instead and indirection is avoided.
This change restores static initialization for network stack global variables, restores support for non-global symbols and types, eliminates the need for many subsystem constructors, eliminates large per-subsystem structures that caused many binary compatibility issues both for monitoring applications (netstat) and kernel modules, removes the per-function INIT_VNET_*() macros throughout the stack, eliminates the need for vnet_symmap ksym(2) munging, and eliminates duplicate definitions of virtualized globals under VIMAGE_GLOBALS.
Bump __FreeBSD_version and update UPDATING.
Portions submitted by: bz Reviewed by: bz, zec Discussed with: gnn, jamie, jeff, jhb, julian, sam Suggested by: peter Approved by: re (kensmith)
|
195626 |
11-Jul-2009 |
cperciva |
Remove build timestamps from the following files: /boot/kernel/hptrr.ko /etc/mail/*.cf /lib/libcrypto.so.5 /usr/bin/ntpq /usr/sbin/amd /usr/sbin/iasl /usr/sbin/ntpd /usr/sbin/ntpdate /usr/sbin/ntpdc
There does not appear to be any purpose to having these timestamps, and they have the irritating consequence that the aforementioned files will be different every time they are rebuilt.
After this commit, the only remaining build timestamps are in the kernel, the boot loaders, /usr/include/osreldate.h (the year in the copyright notice), and lib*.a (the timestamps on all of the included .o files).
Reviewed by: scottl (hptrr), gshapiro (sendmail), simon (openssl), roberto (ntp), jkim (acpica) Approved by: re (kib)
|
195171 |
29-Jun-2009 |
sam |
Update to 3.6.2.2 firmware (latest w/o host-based power save support): o new tx ack queue (not used right now) o proxy-sta related changes (no proxy sta in driver) o explicit dwds ena/dis (needed only with proxy sta) o cleanup BA policy handling o new ampdu aggressive mode support o CFEnd use now controllable
Approved by: re (kensmith)
|
194825 |
24-Jun-2009 |
rdivacky |
Use proper form of gnu designated initalizers. This lets clang compile this files.
Approved by: ed (mentor) Silence from: harti (maintainer?)
|
194760 |
23-Jun-2009 |
rwatson |
Modify most routines returning 'struct ifaddr *' to return references rather than pointers, requiring callers to properly dispose of those references. The following routines now return references:
ifaddr_byindex ifa_ifwithaddr ifa_ifwithbroadaddr ifa_ifwithdstaddr ifa_ifwithnet ifaof_ifpforaddr ifa_ifwithroute ifa_ifwithroute_fib rt_getifa rt_getifa_fib IFP_TO_IA ip_rtaddr in6_ifawithifp in6ifa_ifpforlinklocal in6ifa_ifpwithaddr in6_ifadd carp_iamatch6 ip6_getdstifaddr
Remove unused macro which didn't have required referencing:
IFP_TO_IA6
This closes many small races in which changes to interface or address lists while an ifaddr was in use could lead to use of freed memory (etc). In a few cases, add missing if_addr_list locking required to safely acquire references.
Because of a lack of deep copying support, we accept a race in which an in6_ifaddr pointed to by mbuf tags and extracted with ip6_getdstifaddr() doesn't hold a reference while in transmit. Once we have mbuf tag deep copy support, this can be fixed.
Reviewed by: bz Obtained from: Apple, Inc. (portions) MFC after: 6 weeks (portions)
|
194739 |
23-Jun-2009 |
bz |
After cleaning up rt_tables from vnet.h and cleaning up opt_route.h a lot of files no longer need route.h either. Garbage collect them. While here remove now unneeded vnet.h #includes as well.
|
193900 |
10-Jun-2009 |
bz |
All consumers of in_cksum.h have been properly #ifdefed already, so do not include the file either as it would give as an extra dependency on INET.
|
193750 |
08-Jun-2009 |
jkim |
Rewrite OsdSynch.c to reflect the latest ACPICA more closely:
- Implement ACPI semaphore (ACPI_SEMAPHORE) with condvar(9) and mutex(9). - Implement ACPI mutex (ACPI_MUTEX) with mutex(9). - Implement ACPI lock (ACPI_SPINLOCK) with spin mutex(9).
|
193744 |
08-Jun-2009 |
bz |
After r193232 rt_tables in vnet.h are no longer indirectly dependent on the ROUTETABLES kernel option thus there is no need to include opt_route.h anymore in all consumers of vnet.h and no longer depend on it for module builds.
Remove the hidden include in flowtable.h as well and leave the two explicit #includes in ip_input.c and ip_output.c.
|
193730 |
08-Jun-2009 |
jkim |
Clean up FreeBSD-specific header file:
- Define ACPI_USE_DO_WHILE_0 to add do while(0) around return_*() macros. - Define __cdecl only for user land. It will never be used in kernel. - Remove __cli() and __sti(). They were deprecated long ago.
|
193529 |
05-Jun-2009 |
jkim |
Import ACPICA 20090521.
|
193511 |
05-Jun-2009 |
rwatson |
Move "options MAC" from opt_mac.h to opt_global.h, as it's now in GENERIC and used in a large number of files, but also because an increasing number of incorrect uses of MAC calls were sneaking in due to copy-and-paste of MAC-aware code without the associated opt_mac.h include.
Discussed with: pjd
|
193274 |
01-Jun-2009 |
zec |
V_loif is not an array but a pure pointer, so treat it as such.
Reviewed by: bz Approved by: julian (mentor)
|
193240 |
01-Jun-2009 |
sam |
driver for Marvell 88W8363 Wireless LAN controller
|
192895 |
27-May-2009 |
jamie |
Add hierarchical jails. A jail may further virtualize its environment by creating a child jail, which is visible to that jail and to any parent jails. Child jails may be restricted more than their parents, but never less. Jail names reflect this hierarchy, being MIB-style dot-separated strings.
Every thread now points to a jail, the default being prison0, which contains information about the physical system. Prison0's root directory is the same as rootvnode; its hostname is the same as the global hostname, and its securelevel replaces the global securelevel. Note that the variable "securelevel" has actually gone away, which should not cause any problems for code that properly uses securelevel_gt() and securelevel_ge().
Some jail-related permissions that were kept in global variables and set via sysctls are now per-jail settings. The sysctls still exist for backward compatibility, used only by the now-deprecated jail(2) system call.
Approved by: bz (mentor)
|
192388 |
19-May-2009 |
avg |
bootstrap merge history for acpica contrib code
Approved by: rpaulo (mentor)
|
192278 |
18-May-2009 |
bz |
tbr_timeout() is a timer driven function[1]. While the previous commit made LINT happy this does the proper looping over all vnets as we are only called `globally' and not once per vnet instance.
Reported by: zec [1] Missed by: bz [1] in r192264 Reviewed by: zec
|
192264 |
17-May-2009 |
bz |
Add a missing INIT_VNET_NET() to get VIMAGE closer to full LINT again.
|
191945 |
09-May-2009 |
sam |
Makefile to record the technique by which the .uu files are generated from the Intel-distributed .fw files
|
191944 |
09-May-2009 |
sam |
update to v3.1
|
191548 |
26-Apr-2009 |
zec |
In preparation for turning on options VIMAGE in next commits, rearrange / replace / adjust several INIT_VNET_* initializer macros, all of which currently resolve to whitespace.
Reviewed by: bz (an older version of the patch) Approved by: julian (mentor)
|
191148 |
16-Apr-2009 |
kmacy |
Change if_output to take a struct route as its fourth argument in order to allow passing a cached struct llentry * down to L2
Reviewed by: rwatson
|
190964 |
12-Apr-2009 |
rwatson |
Update stats in struct icmpstat and icmp6stat using four new macros: ICMPSTAT_ADD(), ICMPSTAT_INC(), ICMP6STAT_ADD(), and ICMP6STAT_INC(), rather than directly manipulating the fields of these structures across the kernel. This will make it easier to change the implementation of these statistics, such as using per-CPU versions of the data structures.
In on case, icmp6stat members are manipulated indirectly, by icmp6_errcount(), and this will require further work to fix for per-CPU stats.
MFC after: 3 days
|
190962 |
12-Apr-2009 |
rwatson |
Update stats in struct udpstat using two new macros, UDPSTAT_ADD() and UDPSTAT_INC(), rather than directly manipulating the fields across the kernel. This will make it easier to change the implementation of these statistics, such as using per-CPU versions of the data structures.
MFC after: 3 days
|
190951 |
11-Apr-2009 |
rwatson |
Update stats in struct ipstat using four new macros, IPSTAT_ADD(), IPSTAT_INC(), IPSTAT_SUB(), and IPSTAT_DEC(), rather than directly manipulating the fields across the kernel. This will make it easier to change the implementation of these statistics, such as using per-CPU versions of the data structures.
MFC after: 3 days
|
190948 |
11-Apr-2009 |
rwatson |
Update stats in struct tcpstat using two new macros, TCPSTAT_ADD() and TCPSTAT_INC(), rather than directly manipulating the fields across the kernel. This will make it easier to change the implementation of these statistics, such as using per-CPU versions of the data structures.
MFC after: 3 days
|
190688 |
04-Apr-2009 |
weongyo |
Add uath(4) wireless USB driver for Atheros AR5005UG and AR5005UX chipsets.
Reviewed by: sam
|
190633 |
01-Apr-2009 |
piso |
Implement an ipfw action to reassemble ip packets: reass.
|
190581 |
30-Mar-2009 |
mav |
Integrate user/mav/ata branch:
Add ch_suspend/ch_resume methods for PCI controllers and implement them for AHCI. Refactor AHCI channel initialization according to it.
Fix Port Multipliers operation. It is far from perfect yet, but works now. Tested with JMicron JMB363 AHCI + SiI 3726 PMP pair. Previous version was also tested with SiI 4726 PMP.
Hardware sponsored by: Vitsch Electronics / VEHosting.nl
|
189699 |
11-Mar-2009 |
dfr |
Merge in support for Xen HVM on amd64 architecture.
|
189106 |
27-Feb-2009 |
bz |
For all files including net/vnet.h directly include opt_route.h and net/route.h.
Remove the hidden include of opt_route.h and net/route.h from net/vnet.h.
We need to make sure that both opt_route.h and net/route.h are included before net/vnet.h because of the way MRT figures out the number of FIBs from the kernel option. If we do not, we end up with the default number of 1 when including net/vnet.h and array sizes are wrong.
This does not change the list of files which depend on opt_route.h but we can identify them now more easily.
|
189105 |
27-Feb-2009 |
bz |
Move the include of vinet.h further up before the ipfilter includes.
|
189103 |
27-Feb-2009 |
bz |
Shuffle the vimage.h includes or add where missing.
|
189004 |
24-Feb-2009 |
rdivacky |
Change the functions to ANSI in those cases where it breaks promotion to int rule. See ISO C Standard: SS6.7.5.3:15.
Approved by: kib (mentor) Reviewed by: warner Tested by: silence on -current
|
187689 |
25-Jan-2009 |
ed |
Revert my previous two changes.
Even though the code seems to be FreeBSD kernel code, it isn't compiled on FreeBSD. I could have known this, because I was a little amazed that I couldn't find a prototype of pfopen()/pfclose() somewhere else, because it isn't marked as static.
Apart from that, removing these functions wouldn't have been harmful anyway, because there are some other strange things about them (the implementation isn't consistent with the prototype at the top). Still, it's better to leave it, because it makes merging code back to older branches a little harder.
Requested by: mlaier
|
187688 |
25-Jan-2009 |
ed |
Remove pfopen() and pfclose() entirely.
It turns out I was patching functions that weren't used by pf(4) anyway. They still seem to use `struct proc *' instead of `struct thread *'. They weren't listed in pf_cdevsw.
|
187687 |
25-Jan-2009 |
ed |
Remove unneeded checking for invalid minor numbers from pf(4).
Because it is not possible to access the pf(4) character device through any other device node as the one in devfs, there is no need to check for unknown device minor numbers.
Approved by: mlaier
|
187566 |
21-Jan-2009 |
jkim |
Change __FreeBSD_version to prepare for merging r184102.
|
187192 |
13-Jan-2009 |
thompsa |
Restore the if_*var.h and if_*reg.h to their original names, they dont need to be different.
|
186436 |
23-Dec-2008 |
bz |
Check for ipprotosw.h more precisely. It hasn't been needed for more than 5 years, since r120386.
MFC after: 4 weeks
|
186352 |
20-Dec-2008 |
sam |
Merge support for Gateworks Cambria boards: o add support for IXP435 cpu's (e.g. 64 irq's) o add support for Cambria-specific devices: npe, led's (front panel and octal latch), ehci, mcu, ide cf o redo memory mapping for xscale/ixp4xx boards: previously memory was assumed aliased to 0x10000000 but this appears to be true only for ixp425 systems and breaks operation on others; rework so memory is assumed to start at 0 o rework NPE configuration support to use NPE id's instead of port #'s; these changes also rename the associated MAC's to follow the NPE's they are attached to o update npe firmware to latest rev (same license) and update default fw imageid's to match; in particular this adds NPE-A and crypto support o re-style NPE fw handling code and add a console msg identifying the attributes of the loaded fw o fix numerous problems with handling failures during npe setup o fix npe rx q setup; need to spin waiting for mailbox responses during early boot stages as qmgr interrupts are not delivered; this fixes the problem where all 8 traffic classifications were not tied to the rx q (and eliminates the console msg "remember to fix rx q setup") o add DELAY to npe MII wait logic for IXP435 o strip down builtin phys->virt address translation table in resource handling to just those resources that require it and add a console msg to alert people when this (kludge) table needs to be extended o purge a bunch of dead netbsd-ism's o cleanup avila led driver o add Cambria support to boot2 and rework code for better multi-board support
Notes: 1. NPE-A doesn't work and causes NPE-C to stop working; it is disabled in the hints 2. USB isn't working yet; controller communicates ok but device discovery fails 3. Cambria support must be configured separately from IXP425 boards; multi-board support is TBD
Sponsored by: Hobnob, Gateworks (board donation) Reviewed by: imp
|
186119 |
15-Dec-2008 |
qingli |
This main goals of this project are: 1. separating L2 tables (ARP, NDP) from the L3 routing tables 2. removing as much locking dependencies among these layers as possible to allow for some parallelism in the search operations 3. simplify the logic in the routing code,
The most notable end result is the obsolescent of the route cloning (RTF_CLONING) concept, which translated into code reduction in both IPv4 ARP and IPv6 NDP related modules, and size reduction in struct rtentry{}. The change in design obsoletes the semantics of RTF_CLONING, RTF_WASCLONE and RTF_LLINFO routing flags. The userland applications such as "arp" and "ndp" have been modified to reflect those changes. The output from "netstat -r" shows only the routing entries.
Quite a few developers have contributed to this project in the past: Glebius Smirnoff, Luigi Rizzo, Alessandro Cerri, and Andre Oppermann. And most recently:
- Kip Macy revised the locking code completely, thus completing the last piece of the puzzle, Kip has also been conducting active functional testing - Sam Leffler has helped me improving/refactoring the code, and provided valuable reviews - Julian Elischer setup the perforce tree for me and has helped me maintaining that branch before the svn conversion
|
186058 |
13-Dec-2008 |
bz |
Like for tcp_subr.c in r186057 make the MD5 context a function local variable in this copy of the code[1].
While here prefix the variables with 'pf_' to avoid file static global variables with colliding names that are or will be virtualized.
Discussed with: rwatson, silby [1]
|
186048 |
13-Dec-2008 |
bz |
Second round of putting global variables, which were virtualized but formerly missed under VIMAGE_GLOBAL.
Put the extern declarations of the virtualized globals under VIMAGE_GLOBAL as the globals themsevles are already. This will help by the time when we are going to remove the globals entirely.
Sponsored by: The FreeBSD Foundation
|
185895 |
10-Dec-2008 |
zec |
Conditionally compile out V_ globals while instantiating the appropriate container structures, depending on VIMAGE_GLOBALS compile time option.
Make VIMAGE_GLOBALS a new compile-time option, which by default will not be defined, resulting in instatiations of global variables selected for V_irtualization (enclosed in #ifdef VIMAGE_GLOBALS blocks) to be effectively compiled out. Instantiate new global container structures to hold V_irtualized variables: vnet_net_0, vnet_inet_0, vnet_inet6_0, vnet_ipsec_0, vnet_netgraph_0, and vnet_gif_0.
Update the VSYM() macro so that depending on VIMAGE_GLOBALS the V_ macros resolve either to the original globals, or to fields inside container structures, i.e. effectively
#ifdef VIMAGE_GLOBALS #define V_rt_tables rt_tables #else #define V_rt_tables vnet_net_0._rt_tables #endif
Update SYSCTL_V_*() macros to operate either on globals or on fields inside container structs.
Extend the internal kldsym() lookups with the ability to resolve selected fields inside the virtualization container structs. This applies only to the fields which are explicitly registered for kldsym() visibility via VNET_MOD_DECLARE() and vnet_mod_register(), currently this is done only in sys/net/if.c.
Fix a few broken instances of MODULE_GLOBAL() macro use in SCTP code, and modify the MODULE_GLOBAL() macro to resolve to V_ macros, which in turn result in proper code being generated depending on VIMAGE_GLOBALS.
De-virtualize local static variables in sys/contrib/pf/net/pf_subr.c which were prematurely V_irtualized by automated V_ prepending scripts during earlier merging steps. PF virtualization will be done separately, most probably after next PF import.
Convert a few variable initializations at instantiation to initialization in init functions, most notably in ipfw. Also convert TUNABLE_INT() initializers for V_ variables to TUNABLE_FETCH_INT() in initializer functions.
Discussed at: devsummit Strassburg Reviewed by: bz, julian Approved by: julian (mentor) Obtained from: //depot/projects/vimage-commit2/... X-MFC after: never Sponsored by: NLnet Foundation, The FreeBSD Foundation
|
185747 |
07-Dec-2008 |
kmacy |
- convert radix node head lock from mutex to rwlock - make radix node head lock not recursive - fix LOR in rtexpunge - fix LOR in rtredirect
Reviewed by: sam
|
185571 |
02-Dec-2008 |
bz |
Rather than using hidden includes (with cicular dependencies), directly include only the header files needed. This reduces the unneeded spamming of various headers into lots of files.
For now, this leaves us with very few modules including vnet.h and thus needing to depend on opt_route.h.
Reviewed by: brooks, gnn, des, zec, imp Sponsored by: The FreeBSD Foundation
|
185548 |
02-Dec-2008 |
peter |
Merge user/peter/kinfo branch as of r185547 into head.
This changes struct kinfo_filedesc and kinfo_vmentry such that they are same on both 32 and 64 bit platforms like i386/amd64 and won't require sysctl wrapping.
Two new OIDs are assigned. The old ones are available under COMPAT_FREEBSD7 - but it isn't that simple. The superceded interface was never actually released on 7.x.
The other main change is to pack the data passed to userland via the sysctl. kf_structsize and kve_structsize are reduced for the copyout. If you have a process with 100,000+ sockets open, the unpacked records require a 132MB+ copyout. With packing, it is "only" ~35MB. (Still seriously unpleasant, but not quite as devastating). A similar problem exists for the vmentry structure - have lots and lots of shared libraries and small mmaps and its copyout gets expensive too.
My immediate problem is valgrind. It traditionally achieves this functionality by parsing procfs output, in a packed format. Secondly, when tracing 32 bit binaries on amd64 under valgrind, it uses a cross compiled 32 bit binary which ran directly into the differing data structures in 32 vs 64 bit mode. (valgrind uses this to track file descriptor operations and this therefore affected every single 32 bit binary)
I've added two utility functions to libutil to unpack the structures into a fixed record length and to make it a little more convenient to use.
|
185522 |
01-Dec-2008 |
sam |
Switch to ath hal source code. Note this removes the ath_hal module; the ath module now brings in the hal support. Kernel config files are almost backwards compatible; supplying
device ath_hal
gives you the same chip support that the binary hal did but you must also include
options AH_SUPPORT_AR5416
to enable the extended format descriptors used by 11n parts. It is now possible to control the chip support included in a build by specifying exactly which chips are to be supported in the config file; consult ath_hal(4) for information.
|
185419 |
28-Nov-2008 |
zec |
Unhide declarations of network stack virtualization structs from underneath #ifdef VIMAGE blocks.
This change introduces some churn in #include ordering and nesting throughout the network stack and drivers but is not expected to cause any additional issues.
In the next step this will allow us to instantiate the virtualization container structures and switch from using global variables to their "containerized" counterparts.
Reviewed by: bz, julian Approved by: julian (mentor) Obtained from: //depot/projects/vimage-commit2/... X-MFC after: never Sponsored by: NLnet Foundation, The FreeBSD Foundation
|
184214 |
23-Oct-2008 |
des |
Fix a number of style issues in the MALLOC / FREE commit. I've tried to be careful not to fix anything that was already broken; the NFSv4 code is particularly bad in this respect.
|
184205 |
23-Oct-2008 |
des |
Retire the MALLOC and FREE macros. They are an abomination unto style(9).
MFC after: 3 months
|
184102 |
21-Oct-2008 |
jkim |
Turn off CPU frequency change notifiers when the TSC is P-state invariant or it is forced by setting 'kern.timecounter.invariant_tsc' tunable to non-zero.
|
183606 |
04-Oct-2008 |
bz |
Cache so_cred as inp_cred in the inpcb. This means that inp_cred is always there, even after the socket has gone away. It also means that it is constant for the lifetime of the inp. Both facts lead to simpler code and possibly less locking.
Suggested by: rwatson Reviewed by: rwatson MFC after: 6 weeks X-MFC Note: use a inp_pspare for inp_cred
|
183550 |
02-Oct-2008 |
zec |
Step 1.5 of importing the network stack virtualization infrastructure from the vimage project, as per plan established at devsummit 08/08: http://wiki.freebsd.org/Image/Notes200808DevSummit
Introduce INIT_VNET_*() initializer macros, VNET_FOREACH() iterator macros, and CURVNET_SET() context setting macros, all currently resolving to NOPs.
Prepare for virtualization of selected SYSCTL objects by introducing a family of SYSCTL_V_*() macros, currently resolving to their global counterparts, i.e. SYSCTL_V_INT() == SYSCTL_INT().
Move selected #defines from sys/sys/vimage.h to newly introduced header files specific to virtualized subsystems (sys/net/vnet.h, sys/netinet/vinet.h etc.).
All the changes are verified to have zero functional impact at this point in time by doing MD5 comparision between pre- and post-change object files(*).
(*) netipsec/keysock.c did not validate depending on compile time options.
Implemented by: julian, bz, brooks, zec Reviewed by: julian, bz, brooks, kris, rwatson, ... Approved by: julian (mentor) Obtained from: //depot/projects/vimage-commit2/... X-MFC after: never Sponsored by: NLnet Foundation, The FreeBSD Foundation
|
183397 |
27-Sep-2008 |
ed |
Replace all calls to minor() with dev2unit().
After I removed all the unit2minor()/minor2unit() calls from the kernel yesterday, I realised calling minor() everywhere is quite confusing. Character devices now only have the ability to store a unit number, not a minor number. Remove the confusion by using dev2unit() everywhere.
This commit could also be considered as a bug fix. A lot of drivers call minor(), while they should actually be calling dev2unit(). In -CURRENT this isn't a problem, but it turns out we never had any problem reports related to that issue in the past. I suspect not many people connect more than 256 pieces of the same hardware.
Reviewed by: kib
|
182804 |
05-Sep-2008 |
rpaulo |
Merge ath again (addition of wisoc files).
|
182787 |
05-Sep-2008 |
rpaulo |
Merge fix for P4 expansion from vendor branch.
|
182312 |
28-Aug-2008 |
rpaulo |
Merge ath_hal 0.10.5.10 to head.
Approved by: sam
|
182306 |
27-Aug-2008 |
rpaulo |
Bootstrap svn:mergeinfo.
|
182152 |
25-Aug-2008 |
julian |
I think we can remove the conditionals for freebsd 2.0 now
|
181803 |
17-Aug-2008 |
bz |
Commit step 1 of the vimage project, (network stack) virtualization work done by Marko Zec (zec@).
This is the first in a series of commits over the course of the next few weeks.
Mark all uses of global variables to be virtualized with a V_ prefix. Use macros to map them back to their global names for now, so this is a NOP change only.
We hope to have caught at least 85-90% of what is needed so we do not invalidate a lot of outstanding patches again.
Obtained from: //depot/projects/vimage-commit2/... Reviewed by: brooks, des, ed, mav, julian, jamie, kris, rwatson, zec, ... (various people I forgot, different versions) md5 (with a bit of help) Sponsored by: NLnet Foundation, The FreeBSD Foundation X-MFC after: never V_Commit_Message_Reviewed_By: more people than the patch
|
181295 |
04-Aug-2008 |
mlaier |
Merge state reuse for tcp.
PR: kern/125261 Obtained from: OpenBSD MFC after: 1 week
|
181290 |
04-Aug-2008 |
mlaier |
Record initial merge histroy.
|
180832 |
26-Jul-2008 |
darrenr |
2020447 IPFilter's NAT can undo name server random port selection (fix output port range, was a random number in [0,max-min] (byteswapped on litle endian), instead of [min,max])
Submitted by: darrenr
|
180788 |
24-Jul-2008 |
julian |
Fix spelling error in comment
|
180778 |
24-Jul-2008 |
darrenr |
2020447 IPFilter's NAT can undo name server random port selection
Approved by: darrenr MFC after: 1 week Security: CERT VU#521769
|
180259 |
04-Jul-2008 |
jhb |
Remove the oltr(4) driver. No one responded to calls for testing on current@ and stable@ for the locking patches. The driver can always be revived if someone tests it.
This driver also sleeps in its if_init routine, so it likely doesn't really work at all anyway in modern releases.
|
180258 |
04-Jul-2008 |
jhb |
Make oltr(4) MPSAFE: - Add a mutex to the softc and use it to protect the softc and device hardware. - Setup interrupt handler after interface attach. - Retire 'unit' from softc and use if_printf() instead. - Don't frob IFF_UP in the driver. - Use callout_() rather than timeout() and untimeout().
|
179570 |
05-Jun-2008 |
mlaier |
Fix range check for rtable id.
|
178888 |
09-May-2008 |
julian |
Add code to allow the system to handle multiple routing tables. This particular implementation is designed to be fully backwards compatible and to be MFC-able to 7.x (and 6.x)
Currently the only protocol that can make use of the multiple tables is IPv4 Similar functionality exists in OpenBSD and Linux.
From my notes:
-----
One thing where FreeBSD has been falling behind, and which by chance I have some time to work on is "policy based routing", which allows different packet streams to be routed by more than just the destination address.
Constraints: ------------
I want to make some form of this available in the 6.x tree (and by extension 7.x) , but FreeBSD in general needs it so I might as well do it in -current and back port the portions I need.
One of the ways that this can be done is to have the ability to instantiate multiple kernel routing tables (which I will now refer to as "Forwarding Information Bases" or "FIBs" for political correctness reasons). Which FIB a particular packet uses to make the next hop decision can be decided by a number of mechanisms. The policies these mechanisms implement are the "Policies" referred to in "Policy based routing".
One of the constraints I have if I try to back port this work to 6.x is that it must be implemented as a EXTENSION to the existing ABIs in 6.x so that third party applications do not need to be recompiled in timespan of the branch.
This first version will not have some of the bells and whistles that will come with later versions. It will, for example, be limited to 16 tables in the first commit. Implementation method, Compatible version. (part 1) ------------------------------- For this reason I have implemented a "sufficient subset" of a multiple routing table solution in Perforce, and back-ported it to 6.x. (also in Perforce though not always caught up with what I have done in -current/P4). The subset allows a number of FIBs to be defined at compile time (8 is sufficient for my purposes in 6.x) and implements the changes needed to allow IPV4 to use them. I have not done the changes for ipv6 simply because I do not need it, and I do not have enough knowledge of ipv6 (e.g. neighbor discovery) needed to do it.
Other protocol families are left untouched and should there be users with proprietary protocol families, they should continue to work and be oblivious to the existence of the extra FIBs.
To understand how this is done, one must know that the current FIB code starts everything off with a single dimensional array of pointers to FIB head structures (One per protocol family), each of which in turn points to the trie of routes available to that family.
The basic change in the ABI compatible version of the change is to extent that array to be a 2 dimensional array, so that instead of protocol family X looking at rt_tables[X] for the table it needs, it looks at rt_tables[Y][X] when for all protocol families except ipv4 Y is always 0. Code that is unaware of the change always just sees the first row of the table, which of course looks just like the one dimensional array that existed before.
The entry points rtrequest(), rtalloc(), rtalloc1(), rtalloc_ign() are all maintained, but refer only to the first row of the array, so that existing callers in proprietary protocols can continue to do the "right thing". Some new entry points are added, for the exclusive use of ipv4 code called in_rtrequest(), in_rtalloc(), in_rtalloc1() and in_rtalloc_ign(), which have an extra argument which refers the code to the correct row.
In addition, there are some new entry points (currently called rtalloc_fib() and friends) that check the Address family being looked up and call either rtalloc() (and friends) if the protocol is not IPv4 forcing the action to row 0 or to the appropriate row if it IS IPv4 (and that info is available). These are for calling from code that is not specific to any particular protocol. The way these are implemented would change in the non ABI preserving code to be added later.
One feature of the first version of the code is that for ipv4, the interface routes show up automatically on all the FIBs, so that no matter what FIB you select you always have the basic direct attached hosts available to you. (rtinit() does this automatically).
You CAN delete an interface route from one FIB should you want to but by default it's there. ARP information is also available in each FIB. It's assumed that the same machine would have the same MAC address, regardless of which FIB you are using to get to it.
This brings us as to how the correct FIB is selected for an outgoing IPV4 packet.
Firstly, all packets have a FIB associated with them. if nothing has been done to change it, it will be FIB 0. The FIB is changed in the following ways.
Packets fall into one of a number of classes.
1/ locally generated packets, coming from a socket/PCB. Such packets select a FIB from a number associated with the socket/PCB. This in turn is inherited from the process, but can be changed by a socket option. The process in turn inherits it on fork. I have written a utility call setfib that acts a bit like nice..
setfib -3 ping target.example.com # will use fib 3 for ping.
It is an obvious extension to make it a property of a jail but I have not done so. It can be achieved by combining the setfib and jail commands.
2/ packets received on an interface for forwarding. By default these packets would use table 0, (or possibly a number settable in a sysctl(not yet)). but prior to routing the firewall can inspect them (see below). (possibly in the future you may be able to associate a FIB with packets received on an interface.. An ifconfig arg, but not yet.)
3/ packets inspected by a packet classifier, which can arbitrarily associate a fib with it on a packet by packet basis. A fib assigned to a packet by a packet classifier (such as ipfw) would over-ride a fib associated by a more default source. (such as cases 1 or 2).
4/ a tcp listen socket associated with a fib will generate accept sockets that are associated with that same fib.
5/ Packets generated in response to some other packet (e.g. reset or icmp packets). These should use the FIB associated with the packet being reponded to.
6/ Packets generated during encapsulation. gif, tun and other tunnel interfaces will encapsulate using the FIB that was in effect withthe proces that set up the tunnel. thus setfib 1 ifconfig gif0 [tunnel instructions] will set the fib for the tunnel to use to be fib 1.
Routing messages would be associated with their process, and thus select one FIB or another. messages from the kernel would be associated with the fib they refer to and would only be received by a routing socket associated with that fib. (not yet implemented)
In addition Netstat has been edited to be able to cope with the fact that the array is now 2 dimensional. (It looks in system memory using libkvm (!)). Old versions of netstat see only the first FIB.
In addition two sysctls are added to give: a) the number of FIBs compiled in (active) b) the default FIB of the calling process.
Early testing experience: -------------------------
Basically our (IronPort's) appliance does this functionality already using ipfw fwd but that method has some drawbacks.
For example, It can't fully simulate a routing table because it can't influence the socket's choice of local address when a connect() is done.
Testing during the generating of these changes has been remarkably smooth so far. Multiple tables have co-existed with no notable side effects, and packets have been routes accordingly.
ipfw has grown 2 new keywords:
setfib N ip from anay to any count ip from any to any fib N
In pf there seems to be a requirement to be able to give symbolic names to the fibs but I do not have that capacity. I am not sure if it is required.
SCTP has interestingly enough built in support for this, called VRFs in Cisco parlance. it will be interesting to see how that handles it when it suddenly actually does something.
Where to next: --------------------
After committing the ABI compatible version and MFCing it, I'd like to proceed in a forward direction in -current. this will result in some roto-tilling in the routing code.
Firstly: the current code's idea of having a separate tree per protocol family, all of the same format, and pointed to by the 1 dimensional array is a bit silly. Especially when one considers that there is code that makes assumptions about every protocol having the same internal structures there. Some protocols don't WANT that sort of structure. (for example the whole idea of a netmask is foreign to appletalk). This needs to be made opaque to the external code.
My suggested first change is to add routing method pointers to the 'domain' structure, along with information pointing the data. instead of having an array of pointers to uniform structures, there would be an array pointing to the 'domain' structures for each protocol address domain (protocol family), and the methods this reached would be called. The methods would have an argument that gives FIB number, but the protocol would be free to ignore it.
When the ABI can be changed it raises the possibilty of the addition of a fib entry into the "struct route". Currently, the structure contains the sockaddr of the desination, and the resulting fib entry. To make this work fully, one could add a fib number so that given an address and a fib, one can find the third element, the fib entry.
Interaction with the ARP layer/ LL layer would need to be revisited as well. Qing Li has been working on this already.
This work was sponsored by Ironport Systems/Cisco
Reviewed by: several including rwatson, bz and mlair (parts each) Obtained from: Ironport systems/Cisco
|
178812 |
06-May-2008 |
kmacy |
fix build
|
178791 |
05-May-2008 |
kmacy |
conditionally define PANIC_IF
|
178784 |
05-May-2008 |
kmacy |
Import basic common and iwarp kernel RDMA infrastructure.
Supported by: Chelsio Inc.
|
178676 |
29-Apr-2008 |
sam |
Intel 4965 wireless driver (derived from openbsd driver of the same name)
|
178354 |
20-Apr-2008 |
sam |
Multi-bss (aka vap) support for 802.11 devices.
Note this includes changes to all drivers and moves some device firmware loading to use firmware(9) and a separate module (e.g. ral). Also there no longer are separate wlan_scan* modules; this functionality is now bundled into the wlan module.
Supported by: Hobnob and Marvell Reviewed by: many Obtained from: Atheros (some bits)
|
178325 |
20-Apr-2008 |
rwatson |
Teach pf and ipfw to use read locks in inpcbs write than write locks when reading credential data from sockets.
Teach pf to unlock the pcbinfo more quickly once it has acquired an inpcb lock, as the inpcb lock is sufficient to protect the reference.
Assert locks, rather than read locks or write locks, on inpcbs in subroutines--this is necessary as the inpcb may be passed down with a write lock from the protocol, or may be passed down with a read lock from the firewall lookup routine, and either is sufficient.
MFC after: 3 months
|
178285 |
17-Apr-2008 |
rwatson |
Convert pcbinfo and inpcb mutexes to rwlocks, and modify macros to explicitly select write locking for all use of the inpcb mutex. Update some pcbinfo lock assertions to assert locked rather than write-locked, although in practice almost all uses of the pcbinfo rwlock main exclusive, and all instances of inpcb lock acquisition are exclusive.
This change should introduce (ideally) little functional change. However, it lays the groundwork for significantly increased parallelism in the TCP/IP code.
MFC after: 3 months Tested by: kris (superset of committered patch)
|
177700 |
29-Mar-2008 |
mlaier |
Make ALTQ cope with disappearing interfaces (particularly common with mpd and netgraph in gernal). This also allows to add queues for an interface that is not yet existing (you have to provide the bandwidth for the interface, however).
PR: kern/106400, kern/117827 MFC after: 2 weeks
|
177677 |
28-Mar-2008 |
jb |
Remove the last 3 files I missed. These have been repo copied to the new location under a cddl part of the tree following the core@ license review.
|
177675 |
28-Mar-2008 |
jb |
Remove files that have been repo copied to their new location in cddl-specific parts of the source tree.
|
177633 |
26-Mar-2008 |
dfr |
Add the new kernel-mode NFS Lock Manager. To use it instead of the user-mode lock manager, build a kernel with the NFSLOCKD option and add '-k' to 'rpc_lockd_flags' in rc.conf.
Highlights include:
* Thread-safe kernel RPC client - many threads can use the same RPC client handle safely with replies being de-multiplexed at the socket upcall (typically driven directly by the NIC interrupt) and handed off to whichever thread matches the reply. For UDP sockets, many RPC clients can share the same socket. This allows the use of a single privileged UDP port number to talk to an arbitrary number of remote hosts.
* Single-threaded kernel RPC server. Adding support for multi-threaded server would be relatively straightforward and would follow approximately the Solaris KPI. A single thread should be sufficient for the NLM since it should rarely block in normal operation.
* Kernel mode NLM server supporting cancel requests and granted callbacks. I've tested the NLM server reasonably extensively - it passes both my own tests and the NFS Connectathon locking tests running on Solaris, Mac OS X and Ubuntu Linux.
* Userland NLM client supported. While the NLM server doesn't have support for the local NFS client's locking needs, it does have to field async replies and granted callbacks from remote NLMs that the local client has contacted. We relay these replies to the userland rpc.lockd over a local domain RPC socket.
* Robust deadlock detection for the local lock manager. In particular it will detect deadlocks caused by a lock request that covers more than one blocking request. As required by the NLM protocol, all deadlock detection happens synchronously - a user is guaranteed that if a lock request isn't rejected immediately, the lock will eventually be granted. The old system allowed for a 'deferred deadlock' condition where a blocked lock request could wake up and find that some other deadlock-causing lock owner had beaten them to the lock.
* Since both local and remote locks are managed by the same kernel locking code, local and remote processes can safely use file locks for mutual exclusion. Local processes have no fairness advantage compared to remote processes when contending to lock a region that has just been unlocked - the local lock manager enforces a strict first-come first-served model for both local and remote lockers.
Sponsored by: Isilon Systems PR: 95247 107555 115524 116679 MFC after: 2 weeks
|
177253 |
16-Mar-2008 |
rwatson |
In keeping with style(9)'s recommendations on macros, use a ';' after each SYSINIT() macro invocation. This makes a number of lightweight C parsers much happier with the FreeBSD kernel source, including cflow's prcc and lxr.
MFC after: 1 month Discussed with: imp, rink
|
177230 |
15-Mar-2008 |
pjd |
Fix mmap(2) on ZFS after some changes in VM subsystem.
Submitted by: alc Reported by: kris (originally) and many others Tested with: fsx MFC after: 1 week
|
176559 |
25-Feb-2008 |
attilio |
Axe the 'thread' argument from VOP_ISLOCKED() and lockstatus() as it is always curthread.
As KPI gets broken by this patch, manpages and __FreeBSD_version will be updated by further commits.
Tested by: Andrea Barberio <insomniac at slackware dot it>
|
176519 |
24-Feb-2008 |
attilio |
Introduce some functions in the vnode locks namespace and in the ffs namespace in order to handle lockmgr fields in a controlled way instead than spreading all around bogus stubs: - VN_LOCK_AREC() allows lock recursion for a specified vnode - VN_LOCK_ASHARE() allows lock sharing for a specified vnode
In FFS land: - BUF_AREC() allows lock recursion for a specified buffer lock - BUF_NOREC() disallows recursion for a specified buffer lock
Side note: union_subr.c::unionfs_node_update() is the only other function directly handling lockmgr fields. As this is not simple to fix, it has been left behind as "sole" exception.
|
175633 |
24-Jan-2008 |
pjd |
- Reduce how much ZFS caches by default. This is another change to mitigate 'kmem_map too small panics'. - Print two warnings if there is not enough memory and not enough address space. - Improve comment.
|
175294 |
13-Jan-2008 |
attilio |
VOP_LOCK1() (and so VOP_LOCK()) and VOP_UNLOCK() are only used in conjuction with 'thread' argument passing which is always curthread. Remove the unuseful extra-argument and pass explicitly curthread to lower layer functions, when necessary.
KPI results broken by this change, which should affect several ports, so version bumping and manpage update will be further committed.
Tested by: kris, pho, Diego Sardina <siarodx at gmail dot com>
|
175257 |
12-Jan-2008 |
njl |
This commit was generated by cvs2svn to compensate for changes in r175256, which included commits to RCS files with non-trunk default branches.
|
175202 |
10-Jan-2008 |
attilio |
vn_lock() is currently only used with the 'curthread' passed as argument. Remove this argument and pass curthread directly to underlying VOP_LOCK1() VFS method. This modify makes the code cleaner and in particular remove an annoying dependence helping next lockmgr() cleanup. KPI results, obviously, changed.
Manpage and FreeBSD_version will be updated through further commits.
As a side note, would be valuable to say that next commits will address a similar cleanup about VFS methods, in particular vop_lock1 and vop_unlock.
Tested by: Diego Sardina <siarodx at gmail dot com>, Andrea Di Pasquale <whyx dot it at gmail dot com>
|
174049 |
28-Nov-2007 |
jb |
* Check endianness the FreeBSD way.
* Use LBOLT rather than lbolt to avoid a clash with a FreeBSD global variable.
|
174048 |
28-Nov-2007 |
jb |
Fix a prototype definition.
|
174047 |
28-Nov-2007 |
jb |
Check endianness the FreeBSD way.
|
174046 |
28-Nov-2007 |
jb |
Include an extra header to get this to compile cleanly.
|
173931 |
26-Nov-2007 |
darrenr |
Fix 3 issues relating to the use of "auth" rules in IPFilter, from sourceforge: 1837014 Kernel panics after authentication of an outgoing packet 1836992 Potential bugs in packet auth code (w/patches) 1836967 Kernel panic when using auth rule with keep state and another reported only to FreeBSD by Andiry (see PR)
PR: kern/118251 Submitted by: Andriy Syrovenko <andriys@gmail.com> Reviewed by: darrenr MFC after: 5 days
|
173825 |
21-Nov-2007 |
mlaier |
Bring back pf_if.c revs 1.8 and 1.6 also lost during last import: - Use correct time for tzero when compiled in - Don't use bogus interface addresses on ptp-interfaces with :0
MFC after: 3 days
|
173822 |
21-Nov-2007 |
mlaier |
Cleanup pf interface mangement - esp. remove EVENTHANDLER before unloading the coresponding code. This was lost during 4.1 import.
Reported by: ru MFC after: 3 days
|
173815 |
21-Nov-2007 |
mlaier |
Reloop OpenBSD rev. 1.563: In pf_test_fragment(), ignore protocol-specific criteria for packets of different protocols.
Reported by: des Obtained from: OpenBSD MFC after: 3 days
|
173419 |
07-Nov-2007 |
pjd |
Warn if kmem_map size is set to less than 512MB. Previous warning was a bit pointless, because default is set to something around 300MB and also insufficient.
MFC after: 3 days
|
173374 |
05-Nov-2007 |
pjd |
Remove unused header.
MFC after: 3 days
|
173373 |
05-Nov-2007 |
pjd |
If setting a state to anything but open state, close access to vdev. This fixes replacing drive in place, eg. zpool replace tank da1 da1. Before it complained that device is already open.
MFC after: 1 week
|
173362 |
05-Nov-2007 |
benjsc |
Initial Import of wpi driver based on p4 changeset 128641.
This import includes: o wpi Wireless driver for the Intel 3945 Wireless Lan Controller (802.11abg) (sys/dev/wpi) o Intel firmware revision 2.14.4 & associated LICENSE (sys/dev/contrib/wpi, sys/contrib/dev/wpi/LICENSE) o wpifw Firmware driver (sys/modules/wpifw)
Approved by: mlaier, sam (co-mentors)
|
173268 |
02-Nov-2007 |
lulf |
- Add sysctl for sizeof(znode_t), which will be used by fstat(1).
Approved by: pjd (mentor)
|
173250 |
01-Nov-2007 |
pjd |
Call zil_commit() (if ZIL is not disabled) after every non-read request (BIO_WRITE and BIO_FLUSH) as it is done is Solaris. The difference is that Solaris calls it only for sync requests, but we can't say in GEOM is the request is sync or async, so we do it for every request.
MFC after: 1 week
|
173181 |
30-Oct-2007 |
darrenr |
Apply a few changes from ipfilter-current: * Do not hold any locks over calls to copyin/copyout. * Clean up some #ifdefs * fix a possible mbuf leak when NAT fails on policy routed packets
PR: 117216
|
173102 |
28-Oct-2007 |
rwatson |
Continue to move from generic network entry points in the TrustedBSD MAC Framework by moving from mac_mbuf_create_netlayer() to more specific entry points for specific network services:
- mac_netinet_firewall_reply() to be used when replying to in-bound TCP segments in pf and ipfw (etc).
- Rename mac_netinet_icmp_reply() to mac_netinet_icmp_replyinplace() and add mac_netinet_icmp_reply(), reflecting that in some cases we overwrite a label in place, but in others we apply the label to a new mbuf.
Obtained from: TrustedBSD Project
|
173018 |
26-Oct-2007 |
rwatson |
Rename 'mac_mbuf_create_from_firewall' to 'mac_netinet_firewall_send' as we move towards netinet as a pseudo-object for the MAC Framework.
Rename 'mac_create_mbuf_linklayer' to 'mac_mbuf_create_linklayer' to reflect general object-first ordering preference.
Sponsored by: SPARTA (original patches against Mac OS X) Obtained from: TrustedBSD Project, Apple Computer
|
172933 |
24-Oct-2007 |
mlaier |
Properly drop the pf mutex around all copyout (consistency still protected by the sx) and avoid a WITNESS panic. Overlooked during last import.
Reported and tested by: Max N. Boyarov MFC after: 3 days
|
172930 |
24-Oct-2007 |
rwatson |
Merge first in a series of TrustedBSD MAC Framework KPI changes from Mac OS X Leopard--rationalize naming for entry points to the following general forms:
mac_<object>_<method/action> mac_<object>_check_<method/action>
The previous naming scheme was inconsistent and mostly reversed from the new scheme. Also, make object types more consistent and remove spaces from object types that contain multiple parts ("posix_sem" -> "posixsem") to make mechanical parsing easier. Introduce a new "netinet" object type for certain IPv4/IPv6-related methods. Also simplify, slightly, some entry point names.
All MAC policy modules will need to be recompiled, and modules not updates as part of this commit will need to be modified to conform to the new KPI.
Sponsored by: SPARTA (original patches against Mac OS X) Obtained from: TrustedBSD Project, Apple Computer
|
172836 |
20-Oct-2007 |
julian |
Rename the kthread_xxx (e.g. kthread_create()) calls to kproc_xxx as they actually make whole processes. Thos makes way for us to add REAL kthread_create() and friends that actually make theads. it turns out that most of these calls actually end up being moved back to the thread version when it's added. but we need to make this cosmetic change first.
I'd LOVE to do this rename in 7.0 so that we can eventually MFC the new kthread_xxx() calls.
|
172776 |
18-Oct-2007 |
darrenr |
Pullup IPFilter 4.1.28 from the vendor branch into HEAD.
MFC after: 7 days
|
172772 |
18-Oct-2007 |
darrenr |
This commit was generated by cvs2svn to compensate for changes in r172771, which included commits to RCS files with non-trunk default branches.
|
172645 |
14-Oct-2007 |
thompsa |
ZFS_LOG adds a newline by itself.
Pointed out by: pjd
|
172624 |
14-Oct-2007 |
thompsa |
Print the ZFS ereport to the console if vfs.zfs.debug is set to help diagnose problems with zfs-on-root since devd isnt running yet.
Reviewed by: pjd
|
172443 |
04-Oct-2007 |
pjd |
Fix lock leak leading to the 'System call <name> returning with 1 locks held' panic.
Reported by: kris Approved by: re (kensmith)
|
172358 |
27-Sep-2007 |
cognet |
Ok I hope I got it right this time. After discussion with Sam, switch back to use firmware(9) instead of having the firmware in hex format. Put the binary firmware uuencoded into sys/contrib/dev/npe, and slap a LICENSE file, as found on the Intel website.
Approved by: re (blanket), mux (mentor) MFC After: 1 week
|
172315 |
24-Sep-2007 |
jkim |
This commit was generated by cvs2svn to compensate for changes in r172314, which included commits to RCS files with non-trunk default branches.
|
172301 |
23-Sep-2007 |
pjd |
Now that we have CDDLed code in the tree, add CDDL license.
Discussed with: core Approved by: re (kensmith)
|
172135 |
10-Sep-2007 |
pjd |
Reduce the limit of vnodes on i386 when ZFS is loaded to 3/4 of the original value, so we don't run out of KVA. The default vnodes limit fits better for UFS, but ZFS allocated more file system specific memory for a vnode than UFS.
Don't touch vnodes limit if we detect it was tuned by system administrator and restore original value when ZFS is unloaded.
This isn't final fix, but before we implement something better, this will help to stabilize ZFS under heavy load on i386.
Approved by: re (bmah)
|
172130 |
10-Sep-2007 |
pjd |
After dfr@ vnode leak fix, we can allow ARC to consume more memory.
Tested by: kris Approved by: re (bmah)
|
172030 |
01-Sep-2007 |
pjd |
Use CTLFLAG_RDTUN for tunable sysctls.
Approved by: re (bmah)
|
171929 |
23-Aug-2007 |
dhartmei |
When checking the sequence number of a TCP header embedded in an ICMP error message, do not access th_flags. The field is beyond the first eight bytes of the header that are required to be present and were pulled up in the mbuf.
A random value of th_flags can have TH_SYN set, which made the sequence number comparison not apply the window scaling factor, which led to legitimate ICMP(v6) packets getting blocked with "BAD ICMP" debug log messages (if enabled with pfctl -xm), thus breaking PMTU discovery.
Triggering the bug requires TCP window scaling to be enabled (sysctl net.inet.tcp.rfc1323, enabled by default) on both end- points of the TCP connection. Large scaling factors increase the probability of triggering the bug.
PR: kern/115413: [ipv6] ipv6 pmtu not working Tested by: Jacek Zapala Reviewed by: mlaier Approved by: re (kensmith)
|
171637 |
28-Jul-2007 |
rwatson |
Replace references to NET_CALLOUT_MPSAFE with CALLOUT_MPSAFE, and remove definition of NET_CALLOUT_MPSAFE, which is no longer required now that debug.mpsafenet has been removed.
The once over: bz Approved by: re (kensmith)
|
171567 |
24-Jul-2007 |
pjd |
Update assertion after revision 1.23.
Reviewed by: dfr Approved by: re (rwatson)
|
171407 |
12-Jul-2007 |
njl |
Fix a bug where the callout might not be initialized before being used. Rev 1.9 introduced another path where machclk_freq would be initialized before the rest of setup was done (i.e. initializing the callout). Make the one-time initialization a separate function and make init_machclk() able to be called multiple times, any time. We depend on tsc_freq first being updated from the highest priority eventhandler, thus we run last and call init_machclk() to set machclk_freq. Also, don't initialize static variables to 0.
Tested by: Eygene Ryabinkin Approved by: re
|
171365 |
11-Jul-2007 |
harti |
This commit was generated by cvs2svn to compensate for changes in r171364, which included commits to RCS files with non-trunk default branches.
|
171316 |
09-Jul-2007 |
dfr |
Correct a reference-counting mistake in the ZFS code which led to abnormal memory usage and pessimal cache performance.
Reviewed by: pjd Approved by: re (rwatson)
|
171257 |
05-Jul-2007 |
mlaier |
Remove unused variable from pf_subr.c to make it -Werror buildable.
Approved by: re (kensmith)
|
171174 |
03-Jul-2007 |
mlaier |
Add two place holders in struct pf_rule for future netgraph integration.
Submitted by: Ermal Luçi Approved by: re (kensmith)
|
171173 |
03-Jul-2007 |
mlaier |
Link pf 4.1 to the build: - move ftp-proxy from libexec to usr.sbin - add tftp-proxy - new altq mtag link
Approved by: re (kensmith)
|
171168 |
03-Jul-2007 |
mlaier |
Commit resolved import of OpenBSD 4.1 pf from perforce.
Approved by: re (kensmith)
|
171165 |
03-Jul-2007 |
mlaier |
This commit was generated by cvs2svn to compensate for changes in r171164, which included commits to RCS files with non-trunk default branches.
|
171163 |
03-Jul-2007 |
mlaier |
Fix hardware checksum verification on fragments.
MFC after: 7 days Reported/tested by: Hugo Koji Kobayashi, Vadym Chepkov Reviewed/help by: yongari Approved by: re (kensmith)
|
171063 |
27-Jun-2007 |
dfr |
In zfs_vget, if we fail to translate an inode number to the corresponding vnode, make sure we return an error code to the caller.
Reviewed by: pjd Approved by: re
|
170459 |
09-Jun-2007 |
darrenr |
Pointer to an ICMP header was getting left behind after doing a pullup.
|
170437 |
08-Jun-2007 |
marcel |
Add my copyright.
Requested by: pjd@
|
170431 |
08-Jun-2007 |
pjd |
- Reduce number of atomic operations needed to be implemented in asm by implementing some of them using existing ones. - Allow to compile ZFS on all archs and use atomic operations surrounded by global mutex on archs we don't have or can't have all atomic operations needed by ZFS.
|
170430 |
08-Jun-2007 |
pjd |
Missing atomic operations for ZFS/ia64.
Submitted by: marcel
|
170281 |
04-Jun-2007 |
pjd |
Reimplement traverse() helper function: 1. Pass locking flags to VFS_ROOT(). 2. Check v_mountedhere while the vnode is locked. 3. Always return locked vnode on success.
Change 1 fixes problem reported by Stephen M. Rumble - after zfs_vfsops.c,1.9 change, zfs_root() no longer locks the vnode unconditionally and traverse() didn't pass right lock type to VFS_ROOT(). The result was that kernel paniced when .zfs/ directory was accessed via NFS.
|
170268 |
04-Jun-2007 |
darrenr |
Merge IPFilter 4.1.23 back to HEAD See src/contrib/ipfilter/HISTORY for details of changes since 4.1.13
|
170264 |
04-Jun-2007 |
darrenr |
This commit was generated by cvs2svn to compensate for changes in r170263, which included commits to RCS files with non-trunk default branches.
|
170044 |
28-May-2007 |
pjd |
Adjust va_mask for setattr. FreeBSD doesn't have va_mask, so we initialize it based on individual fields beeing set. This doesn't work for setattr replay, because va_type is set there, so we add AT_TYPE flag to va_mask, which won't be accepted by zfs_setattr().
Reported by: kris
|
170040 |
28-May-2007 |
pjd |
Because we allocate componentname structures on stack, bzero() them before use just in case.
|
169929 |
24-May-2007 |
pjd |
Initialize ZFS a bit earlier and block root mounting until initialization is complete. This fixes some root-on-ZFS configurations.
Reported by: Bruno Damour <freebsd.ruomad@free.fr> Tested by: Bruno Damour <freebsd.ruomad@free.fr>
|
169920 |
23-May-2007 |
pjd |
FreeBSD's namecache works quite well with ZFS, so remove DNLC.
|
169919 |
23-May-2007 |
pjd |
All objects we create using GFS are directories, so initialize d_type properly, but add XXX comment saying that it can eventually change in the future.
|
169884 |
22-May-2007 |
pjd |
Lock vnode on lookup. This fixes ZIL replay for rmdir/unlink/rename.
Reported by: des
|
169843 |
21-May-2007 |
dhartmei |
From OpenBSD, rev. 1.524, 1.528, 1.529 Deal with IPv6 routing headers (see FreeBSD-SA-07:03.ipv6 for background) Block IPv6 packets with routing headers by default, unless 'allow-opts' is specified. Block RH0 unconditionally. Deal with ip6_plen 0.
MFC after: 1 week Discussed with: mlaier
|
169430 |
09-May-2007 |
pjd |
Increase debug level - this message is not that important.
|
169325 |
06-May-2007 |
pjd |
- Add missing lock destruction and remove duplicate initializations. With this change it is possible to unload zfs.ko module from WITNESS-enabled kernel. - Remove bogus comment.
|
169303 |
06-May-2007 |
pjd |
Use provider's ident to handle situations when disks are moved around and show up with different names: first try to open provider using remembered name and compare its ident, if equal, this is our provider, if not equal or there is no provider with such name, find provider with remembered ident and don't care about the name.
|
169302 |
06-May-2007 |
pjd |
MFp4: We don't need to cover vnode_pager_setsize() with the z_map_lock.
|
169199 |
02-May-2007 |
pjd |
Share-lock a vnode where possible.
|
169198 |
02-May-2007 |
pjd |
When parent directory has to be unlocked, lock it back with the same lock type. Before this change, if directory was shared-locked, it was relocked exclusively.
|
169197 |
02-May-2007 |
pjd |
Lock vnode using cn_lkflags in case the caller wants the vnode to be shared-locked.
|
169196 |
02-May-2007 |
pjd |
The getnewvnode() function sets LK_NOSHARE by default, so if we want to support shared vnodes locking, we need to remove that flag. Also add LK_CANRECURSE flag as found in nfsclient.
|
169195 |
02-May-2007 |
pjd |
ZFS should update timestamps upon the creat() of an existing file.
Obtained from: OpenSolaris Bug: http://bugs.opensolaris.org/view_bug.do?bug_id=6465105
|
169194 |
02-May-2007 |
pjd |
- Lock vnode with flags passed in as argument in zfs_vget() and zfs_root().
Pointed out by: ups Also reported by: kris
- Add comments where I'm not sure if LK_RETRY should be used.
|
169172 |
01-May-2007 |
pjd |
MFp4: Remove LK_RETRY flag when locking vnode in zfs_lookup, we don't want dead vnodes here.
Suggested by: kib
|
169170 |
01-May-2007 |
pjd |
White space fixes.
|
169167 |
01-May-2007 |
pjd |
Add a comment explaining why we call dmu_write() unconditionally, even if uiomove() fails, especially that it is different from what OpenSolaris does (I'm not entirely sure they are right).
Suggested by: darrenr
|
169108 |
29-Apr-2007 |
pjd |
- Define d_type for ".", ".." and ".zfs" directories. - Add a TODO comment where d_type is still noe defined.
|
169107 |
29-Apr-2007 |
pjd |
Oops, correct important typo in last commit.
|
169106 |
29-Apr-2007 |
pjd |
Avoid freeing NULL pointer in case of an error.
|
169087 |
29-Apr-2007 |
pjd |
Fix two use-after-free cases.
|
169059 |
26-Apr-2007 |
pjd |
MFp4: Optimize mappedwrite() and mappedread() functions to write/read as much non-mapped data as possible at once and not page-by-page. Which this change we combain I/Os, but also saves many VM_OBJECT_UNLOCK()/VM_OBJECT_LOCK() operations.
Simple 'fsx -l 33554432 -o 524288 -N 10000 /tank/fsx' test shows ~23% performance increase.
|
169057 |
26-Apr-2007 |
pjd |
- Always try to write one whole page at a time. - vm_page_undirty() is enough (instead of vm_page_set_validclean()), but it has to be called before we write the data in case someone makes page dirty after our write, but before our vm_page_undirty() call. - Always dmu_write, not matter if uiomove() succeeded, because it could partially be ok and we would lose some changes.
All good ideas from: ups
|
169056 |
26-Apr-2007 |
pjd |
MFV: Free znodes immediatelly, allowing the ARC to hold onto less memory.
Full description at: http://bugs.opensolaris.org/view_bug.do?bug_id=6543706
|
169055 |
26-Apr-2007 |
pjd |
MFV: Functions name change.
|
169028 |
24-Apr-2007 |
pjd |
ZIL (ZFS Intent Log) can be safely turned on and off at run time, because it is only used when dataset is beeing mounted to decide if log should also be opened.
|
169027 |
24-Apr-2007 |
pjd |
MFp4: Now that ZFS can use FreeBSD's namecache, turn it off by default and turn off DNLC, but don't remove DNLC yet just in case.
|
169025 |
24-Apr-2007 |
pjd |
MFp4: Rearange the code so vobject is destroyed from reclaim() method like in all other file system on FreeBSD (instead from inactive() method).
A nice side-effect of this change, except that it speedups file system when mmaped file are often open/closed, is that it makes FreeBSD's namecache work:)
|
169024 |
24-Apr-2007 |
pjd |
MFp4: Once page is written successfully, we should clear the dirty bits. This fixes slow operations on mmaped files, because without this fix, pages were written to disk multiple times.
If one is looking for even greater speed up for such operation, he should disable ZIL (by setting vfs.zfs.zil_disable to 1 in /boot/loader.conf). Disabling ZIL makes fsx run ~9 times faster.
|
169023 |
24-Apr-2007 |
pjd |
MFp4: Reduce diff against vendor.
|
169022 |
24-Apr-2007 |
pjd |
MFp4: We have stronger 'lock already initialized' check now, so we can reduce diff against the vendor by removing bzero of this mutex.
|
168987 |
23-Apr-2007 |
bmah |
Mostly-cosmetic fixes in low-memory warning messages:
o Fix linewrap issues.
o Fix two typos (s/Recomended/Recommended/ and s/tunning/tuning/)
o Remove a couple of extra instances of the word "of".
o Update names of kmem_size variables.
Approved by: pjd
|
168978 |
23-Apr-2007 |
pjd |
Too much diff reduction. 'cmd' has to be u_long.
Reported by: delphij
|
168962 |
23-Apr-2007 |
pjd |
MFp4: Reduce diff against vendor code: - Move FreeBSD-specific code to zfs_freebsd_*() functions in zfs_vnops.c and keep original functions as similar to vendor's code as possible. - Add various includes back, now that we have them.
|
168959 |
22-Apr-2007 |
pjd |
Fix 'zpool status -v'. To get object number we should use ZFS_DIRENT_OBJ() macro, as za_first_integer field also contains type. This should be fixed in ZFS itself, but this bug is not visible on Solaris, because there, type is not stored in za_first_integer. On the other hand it will be visible on MacOS X.
Reported by: Barry Pederson <bp@barryp.org>
|
168958 |
22-Apr-2007 |
pjd |
Fix st_rdev handling (implement it, actually).
Reported by: gj
|
168926 |
21-Apr-2007 |
pjd |
MFp4:
@118370 Correct typo.
@118371 Integrate changes from vendor.
@118491 Show backtrace on unexpected code paths.
@118494 Integrate changes from vendor.
@118504 Fix sendfile(2). I had two ways of fixing it: 1. Fixing sendfile(2) itself to use VOP_GETPAGES() instead of hacking around with vn_rdwr(UIO_NOCOPY), which was suggested by ups. 2. Modify ZFS behaviour to handle this special case.
Although 1 is more correct, I've choosen 2, because hack from 1 have a side-effect of beeing faster - it reads ahead MAXBSIZE bytes instead of reading page by page. This is not easy to implement with VOP_GETPAGES(), at least not for me in this very moment.
Reported by: Andrey V. Elsukov <bu7cher@yandex.ru>
@118525 Reorganize the code to reduce diff.
@118526 This code path is expected. It is simply when file is opened with O_FSYNC flag.
Reported by: kris Reported by: Michal Suszko <dry@dry.pl>
|
168839 |
18-Apr-2007 |
pjd |
MFp4: We check for PRIV_VFS_MOUNT already in mount(2) syscall and we don't want to do the check when snapshot is automatically mounted by an unprivileged user doing lookup on a snapshot directory.
|
168826 |
17-Apr-2007 |
pjd |
Simplify.
|
168821 |
17-Apr-2007 |
pjd |
Ignore hostid check for root-on-ZFS configurations. Making hostid available before the root is mounted is tricky and having it in /boot/ is not really desire.
Reported by: Zephiris <zephiris@gmail.com>
|
168775 |
16-Apr-2007 |
pjd |
Uncomment forgotten check. Without this check in-place, ZFS will panic on unload instead of returning EBUSY. This check tells if there are mounted ZFS file systems or not. We can't unload if there are mounted file systems.
Reported by: Andrey V. Elsukov <bu7cher@yandex.ru>
|
168753 |
15-Apr-2007 |
pjd |
MFp4: Start DNLC after desiredvnodes variable is initialized. Before this change if zfs.ko was loaded by the loader, DNLC was automatically disabled.
Reported by: Zephiris <zephiris@gmail.com>
|
168738 |
14-Apr-2007 |
pjd |
Fix RAID-Z resilvering.
Obtained from: OpenSolaris
|
168724 |
14-Apr-2007 |
pjd |
MFp4: Hmm, it seems to work now.
|
168715 |
14-Apr-2007 |
pjd |
MFp4: Use max_ncpus, which is used in other places in the code.
|
168714 |
14-Apr-2007 |
pjd |
MFp4: Add more debug, so we can see if zpool.cache was loaded or why it wasn't loaded.
|
168713 |
14-Apr-2007 |
pjd |
MFp4: Allow to tune vfs.zfs.debug from loader.conf.
|
168712 |
14-Apr-2007 |
pjd |
MFp4: - Allow to tune number of spa_zio_* threads. - Reduce default number of spa_zio_* threads to N*spa_zio_issue plus N*spa_zio_intr threads per ZIO type, where N is the number of CPUs. - Put ZIO type number in thread's name.
|
168700 |
14-Apr-2007 |
bms |
In member interface detach event handler, do not attempt to free state which has already been freed by in_ifdetach(). With this cumulative change, the removal of a member interface will not cause a panic in pfsync(4).
Requested by: yar PR: 86848
|
168696 |
13-Apr-2007 |
pjd |
Fix overflow, which was causing endless loops when 32bit machine had more than 2GB of RAM. This was because our physmem is long and 'physmem*PAGESIZE' can be negative for more than 2GB of memory.
Reported by: Andrey V. Elsukov <bu7cher@yandex.ru>
It is not yet tested by Andrey, so there can be other problems, but this was definiately a bug, so I'm committing a fix now.
|
168683 |
13-Apr-2007 |
pjd |
Fix vnodes starvation caused by DNLC (ZFS name cache): - Tune number of namecache entires better (based on desiredvnodes). - Handle vfs_lowvnodes event by releasing requested number of name cache entries, but no less than 5%.
Reported by: simokawa
|
168676 |
12-Apr-2007 |
pjd |
MFp4: Synchronize with vendor (mostly 'zfs rename -r').
|
168675 |
12-Apr-2007 |
pjd |
MFp4: Bring back comments.
Requested by: jhb
|
168617 |
11-Apr-2007 |
ru |
This commit was generated by cvs2svn to compensate for changes in r168616, which included commits to RCS files with non-trunk default branches.
|
168610 |
11-Apr-2007 |
njl |
This commit was generated by cvs2svn to compensate for changes in r168609, which included commits to RCS files with non-trunk default branches.
|
168583 |
10-Apr-2007 |
pjd |
MFp4: Allow to set zfs_recover via vfs.zfs.recover from /boot/loader.conf.
|
168582 |
10-Apr-2007 |
pjd |
MFp4: Hide under '#ifdef _KERNEL' only what's really needed.
|
168566 |
10-Apr-2007 |
pjd |
Try to stabilize ZFS with regard to memory consumption: - Allow to shrink ARC down to 16MB (instead of 64MB). - Set arc_max to 1/2 of kmem_map by default. - Start freeing things earlier when low memory situation is detected. - Serialize execution of arc_lowmem().
I decided to setup minimum ZFS memory requirements to 512MB of RAM and 256MB of kmem_map size. If there is less RAM or kmem_map, a warning will be printed. World is cruel, be no better. In other words: modern file system requires modern hardware:)
From ZFS administration guide:
"Currently the minimum amount of memory recommended to install a Solaris system is 512 Mbytes. However, for good ZFS performance, at least one Gbyte or more of memory is recommended."
|
168565 |
10-Apr-2007 |
pjd |
Reduce diff against vendor - we have now stronger check for "mutex already initialized", so we can go back to kmem_alloc().
|
168559 |
09-Apr-2007 |
pjd |
Remove unused #define.
|
168511 |
09-Apr-2007 |
pjd |
We don't have to wait for the root file system to be mounted anymore, now that kobj KPI supports operating on files loaded by the loader.
|
168510 |
09-Apr-2007 |
pjd |
Drop the Giant lock before calling zfs_domount(), which is held when mounting root file system.
|
168509 |
08-Apr-2007 |
pjd |
Move zpool.cache from /etc/zfs/ to /boot/zfs/, so we can keep it on dedicated /boot/ file system and use ZFS for the root file system.
|
168498 |
08-Apr-2007 |
pjd |
MFp4: Synchronize with recent OpenSolaris changes.
|
168494 |
08-Apr-2007 |
pjd |
- Use 'name=value' so it can be properly recognized by devd(8). - Use only subclass as devd's type.
|
168488 |
08-Apr-2007 |
pjd |
Take vnode pointer and hold it under znode lock, so we won't race with zfs_reclaim(). This may or may not fix problem reported by kris, but it's definiatelly better that way.
|
168482 |
07-Apr-2007 |
pjd |
Move atomic.S files to directories that better fit OpenSolaris directory layout.
|
168481 |
07-Apr-2007 |
pjd |
Fix libzpool compilation.
Reported by: des
|
168478 |
07-Apr-2007 |
pjd |
Limit the number of system taskq threads to the number of CPUs. They are only used when there is a need for reducing namecache.
Observed by: kris, csjp
|
168474 |
07-Apr-2007 |
des |
Fix some type mismatches.
Reviewed by: pjd@
|
168473 |
07-Apr-2007 |
pjd |
Allow to tune maximum and minimum memory used by ARC.
|
168460 |
07-Apr-2007 |
pjd |
Add missing mutex_init() which was causing assertion panic when on clone destruction.
Reported by: kris
|
168404 |
06-Apr-2007 |
pjd |
Please welcome ZFS - The last word in file systems.
ZFS file system was ported from OpenSolaris operating system. The code in under CDDL license.
I'd like to thank all SUN developers that created this great piece of software.
Supported by: Wheel LTD (http://www.wheel.pl/) Supported by: The FreeBSD Foundation (http://www.freebsdfoundation.org/) Supported by: Sentex (http://www.sentex.net/)
|
167905 |
26-Mar-2007 |
njl |
Add an interface for drivers to be notified of changes to CPU frequency. cpufreq_pre_change is called before the change, giving each driver a chance to revoke the change. cpufreq_post_change provides the results of the change (success or failure). cpufreq_levels_changed gives the unit number of the cpufreq device whose number of available levels has changed. Hook in all the drivers I could find that needed it.
* TSC: update TSC frequency value. When the available levels change, take the highest possible level and notify the timecounter set_cputicker() of that freq. This gets rid of the "calcru: runtime went backwards" messages. * identcpu: updates the sysctl hw.clockrate value * Profiling: if profiling is active when the clock changes, let the user know the results may be inaccurate.
Reviewed by: bde, phk MFC after: 1 month
|
167819 |
22-Mar-2007 |
jkim |
Merge from vendor branch to fix tinderbox breakage.
|
167818 |
22-Mar-2007 |
jkim |
This commit was generated by cvs2svn to compensate for changes in r167817, which included commits to RCS files with non-trunk default branches.
|
167813 |
22-Mar-2007 |
jkim |
Update to reflect import of ACPI-CA 20070320.
|
167812 |
22-Mar-2007 |
jkim |
Resolve conflicts from import of Intel ACPI-CA 20070320.
|
167811 |
22-Mar-2007 |
jkim |
Resolve conflicts of unchanged files that are off the vendor branch.
|
167809 |
22-Mar-2007 |
jkim |
Remove files that removed on the vendor branch.
|
167808 |
22-Mar-2007 |
jkim |
This commit was generated by cvs2svn to compensate for changes in r167807, which included commits to RCS files with non-trunk default branches.
|
167806 |
22-Mar-2007 |
jkim |
This commit was generated by cvs2svn to compensate for changes in r167805, which included commits to RCS files with non-trunk default branches.
|
167803 |
22-Mar-2007 |
jkim |
This commit was generated by cvs2svn to compensate for changes in r167802, which included commits to RCS files with non-trunk default branches.
|
167710 |
19-Mar-2007 |
bms |
Teach pfsync(4) that its member interfaces may go away.
This change partially resolves the issue in the PR. Further architectural fixes, in the form of reference counting, are needed.
PR: 86848 Reviewed by: yar MFC after: 1 month
|
167165 |
02-Mar-2007 |
flz |
- Add Intel firmwares for Intel PRO/Wireless LAN 2100/2200/2915 cards in a uuencoded format along with their respective LICENSE files. - Add new share/doc/legal directory to BSD.usr.dist mtree file. This is the place we install LICENSE files for restricted firmwares. - Teach firmware(9) and kmod.mk about licensed firmwares. Restricted firmwares won't load properly unless legal.<name>.license_ack is set to 1, either via kenv(1) or /boot/loader.conf.
Reviewed by: mlaier, sam Permitted by: Intel (via Andrew Wilson) MFC after: 1 month
|
166901 |
23-Feb-2007 |
piso |
o break newbus api: add a new argument of type driver_filter_t to bus_setup_intr()
o add an int return code to all fast handlers
o retire INTR_FAST/IH_FAST
For more info: http://docs.freebsd.org/cgi/getmsg.cgi?fetch=465712+0+current/freebsd-current
Reviewed by: many Approved by: re@
|
165719 |
01-Jan-2007 |
mlaier |
Clean up pfr_kentry_pl2 as well. This fixes a kernel panic in the vm.zone sysctl after unloading pf.
Submitted by: Earl Lapus MFC after: 3 days
|
165632 |
29-Dec-2006 |
jhb |
Various bpf(4) related fixes to catch places up to the new bpf(4) semantics. - Stop testing bpf pointers for NULL. In some cases use bpf_peers_present() and then call the function directly inside the conditional block instead of the macro. - For places where the entire conditional block is the macro, remove the test and make the macro unconditional. - Use BPF_MTAP() in if_pfsync on FreeBSD instead of an expanded version of the old semantics.
Reviewed by: csjp (older version)
|
165631 |
29-Dec-2006 |
mlaier |
Work around a long standing LOR with user/group rules by doing the socket lookup early. This has some performance implications and should not be enabled by default, but might help greatly in certain setups. After some more testing this could be turned into a sysctl.
Tested by: avatar LOR ids: 17, 24, 32, 46, 191 (conceptual) MFC after: 6 weeks
|
165515 |
24-Dec-2006 |
darrenr |
TCP Window scaling was being recognised but the recorded settings were being clobbered and thus effectively disabled.
MFC after: 7 days
|
165183 |
13-Dec-2006 |
sam |
This commit was generated by cvs2svn to compensate for changes in r165182, which included commits to RCS files with non-trunk default branches.
|
164033 |
06-Nov-2006 |
rwatson |
Sweep kernel replacing suser(9) calls with priv(9) calls, assigning specific privilege names to a broad range of privileges. These may require some future tweaking.
Sponsored by: nCircle Network Security, Inc. Obtained from: TrustedBSD Project Discussed on: arch@ Reviewed (at least in part) by: mlaier, jmg, pjd, bde, ceri, Alex Lyashkov <umka at sevcity dot net>, Skip Ford <skip dot ford at verizon dot net>, Antoine Brodin <antoine dot brodin at laposte dot net>
|
163606 |
22-Oct-2006 |
rwatson |
Complete break-out of sys/sys/mac.h into sys/security/mac/mac_framework.h begun with a repo-copy of mac.h to mac_framework.h. sys/mac.h now contains the userspace and user<->kernel API and definitions, with all in-kernel interfaces moved to mac_framework.h, which is now included across most of the kernel instead.
This change is the first step in a larger cleanup and sweep of MAC Framework interfaces in the kernel, and will not be MFC'd.
Obtained from: TrustedBSD Project Sponsored by: SPARTA
|
163027 |
05-Oct-2006 |
oleg |
Workaround bad locking design: do not try to lock/unlock destroyed/non-existsing mutex.
PR: kern/103569 Reviewed by: guido Approved by: glebius (mentor) Silence from: darrenr MFC: 2 week
|
162416 |
18-Sep-2006 |
sam |
remove this from HEAD too since it got taken off the vendor branch
|
162414 |
18-Sep-2006 |
sam |
This commit was generated by cvs2svn to compensate for changes in r162413, which included commits to RCS files with non-trunk default branches.
|
162238 |
12-Sep-2006 |
csjp |
Introduce a new entry point, mac_create_mbuf_from_firewall. This entry point exists to allow the mandatory access control policy to properly initialize mbufs generated by the firewall. An example where this might happen is keep alive packets, or ICMP error packets in response to other packets.
This takes care of kernel panics associated with un-initialize mbuf labels when the firewall generates packets.
[1] I modified this patch from it's original version, the initial patch introduced a number of entry points which were programmatically equivalent. So I introduced only one. Instead, we should leverage mac_create_mbuf_netlayer() which is used for similar situations, an example being icmp_error()
This will minimize the impact associated with the MFC
Submitted by: mlaier [1] MFC after: 1 week
This is a RELENG_6 candidate
|
162069 |
06-Sep-2006 |
mlaier |
Fix stateful filtering of loopback IPv6 traffic to an address not configured on lo0. While here fix a comment.
PR: kern/102647 Reported by: Frank Steinborn Submitted by: suz (earlier version) MFC after: 3 days
|
161356 |
16-Aug-2006 |
guido |
Resolve conflicts
MFC after: 2 weeks
|
161352 |
16-Aug-2006 |
guido |
This commit was generated by cvs2svn to compensate for changes in r161351, which included commits to RCS files with non-trunk default branches.
|
161244 |
12-Aug-2006 |
pjd |
The strstr() function is in the libkern now.
|
160543 |
21-Jul-2006 |
mlaier |
Import from OpenBSD 1.168, dhartmei: fix a bug in the input sanity check of DIOCCHANGERULE (not used by pfctl, but third-party tools). a rule must have a non-empty replacement address list when it's a translation rule but not an anchor call (i.e. "nat ... ->" needs a replacement address, but "nat-anchor ..." doesn't). the check confused "rule is an anchor call" with "rule is defined within an anchor". report from Michal Mertl, Max Laier.
Obtained from: OpenBSD MFC after: 2 weeks
|
160195 |
09-Jul-2006 |
sam |
Revise network interface cloning to take an optional opaque parameter that can specify configuration parameters: o rev cloner api's to add optional parameter block o add SIOCCREATE2 that accepts parameter data o rev vlan support to use new api (maintain old code)
Reviewed by: arch@
|
160164 |
08-Jul-2006 |
mlaier |
Make in-kernel multicast protocols for pfsync and carp work after enabling dynamic resizing of multicast membership array.
Reported and testing by: Maxim Konovalov, Scott Ullrich Reminded by: thompsa MFC after: 2 weeks
|
160163 |
07-Jul-2006 |
marcel |
Apply local modifications to make Unwind Express BETA 10 buildable and usable in the FreeBSD kernel.
|
160161 |
07-Jul-2006 |
marcel |
This commit was generated by cvs2svn to compensate for changes in r160160, which included commits to RCS files with non-trunk default branches.
|
160158 |
07-Jul-2006 |
marcel |
This commit was generated by cvs2svn to compensate for changes in r160157, which included commits to RCS files with non-trunk default branches.
|
159656 |
16-Jun-2006 |
mlaier |
Fix pfsync w/o carp compilation.
Submitted by: yar
|
159603 |
14-Jun-2006 |
mlaier |
Fix byteorder of syncpeer and make it actually work.
Submitted by: glebius MFC after: 1 week
|
159380 |
07-Jun-2006 |
sam |
reposition defines so things build on architectures where AH_REGOPS_FUNC is defined
|
159288 |
05-Jun-2006 |
sam |
resolve merge conflicts
MFC after: 1 month
|
159286 |
05-Jun-2006 |
sam |
This commit was generated by cvs2svn to compensate for changes in r159285, which included commits to RCS files with non-trunk default branches.
|
158651 |
16-May-2006 |
phk |
Since DELAY() was moved, most <machine/clock.h> #includes have been unnecessary.
|
158486 |
12-May-2006 |
mlaier |
Put debugging messages related to inconsistent ticket numbers under misc and wrap it __FreeBSD__ specific as I couldn't figure out which version of OpenBSD I got it from.
Reported by: Scott Ullrich
|
157836 |
18-Apr-2006 |
darrenr |
fix "ipf -Z" reporting rubbish and possibly panic'ing box
MFC after: 4 days
|
157131 |
25-Mar-2006 |
mlaier |
Loopback pf_norm.c rev. 1.106 from OpenBSD: fixup IP checksum when modifying IP header fields
PR: kern/93849 Obtained from: OpenBSD MFC after: 3 days
|
156500 |
09-Mar-2006 |
yar |
Avoid pulling in the whole <net/pfvar.h> by opaquely declaring the structs pflog_packet() takes pointers to.
Approved by: mlaier MFC after: 3 days
|
156200 |
02-Mar-2006 |
thompsa |
Do not use the TSC where its known to be broken, this will cause the queue speeds to perform below the desired bitrate and throughput will be erratic.
This makes queueing work on the Geode SC1100, K5 model 0 and IDT WinChip C6 processors.
MFC after: 3 days
|
155514 |
10-Feb-2006 |
sam |
resolve merge conflicts
MFC after: 2 weeks
|
155512 |
10-Feb-2006 |
sam |
This commit was generated by cvs2svn to compensate for changes in r155511, which included commits to RCS files with non-trunk default branches.
|
155337 |
05-Feb-2006 |
mlaier |
Make pflog a seperate module. As a result pflog_packet() becomes a function pointer that is declared in pf_ioctl.c
Requested by: yar (as part of the module build reorg) MFC after: 1 week X-MFC with: yar's module reorg
|
154551 |
19-Jan-2006 |
dhartmei |
fix a bug in the fragment cache (used for 'scrub fragment crop/drop-ovl', but not 'fragment reassemble'), which can cause some fragments to get inserted into the cache twice, thereby violating an invariant, and panic- ing the system subsequently.
Reviewed by: mlaier MFC after: 1 day
|
154377 |
14-Jan-2006 |
mlaier |
Move m_adj after checking that m_dup succeeded.
Found with: Coverity Prevent(tm) MFC after: 3 days
|
153882 |
30-Dec-2005 |
guido |
Add mcopywrap prototype to ip_compat.h Remove h323 proxy from ip_proxy (copyright issue)
|
153876 |
30-Dec-2005 |
guido |
Resolve conflicts
|
153873 |
30-Dec-2005 |
guido |
This commit was generated by cvs2svn to compensate for changes in r153872, which included commits to RCS files with non-trunk default branches.
|
153725 |
25-Dec-2005 |
mlaier |
Only decrement the max-src-conn counter for tcp connections that reached "established" state.
Similar to OpenBSD's rev. 1.499 by joel but not breaking ABI.
Obtained from: OpenBSD (with changes) Reported by: Bruno Afonso MFC after: 3 days X-MFC: together with local_flags
|
153722 |
25-Dec-2005 |
mlaier |
Fix build after timeval.tv_sec changed from long to time_t.
|
153545 |
20-Dec-2005 |
mlaier |
Move PFSTATE_EXPIRING from sync_flags to a new local_flags. sync_flags has special handling when zero. This caused no PFSYNC_ACT_DEL message and thus disfunction of pfflowd and state synchronisation in general.
Discovered by: thompsa Good catch by: thompsa MFC after: 7 days
|
153201 |
07-Dec-2005 |
obrien |
This commit was generated by cvs2svn to compensate for changes in r153200, which included commits to RCS files with non-trunk default branches.
|
153110 |
05-Dec-2005 |
ru |
Fix -Wundef warnings found when compiling i386 LINT, GENERIC and custom kernels.
|
153084 |
04-Dec-2005 |
ru |
Fix -Wundef from compiling the amd64 LINT.
|
152315 |
11-Nov-2005 |
ru |
- Store pointer to the link-level address right in "struct ifnet" rather than in ifindex_table[]; all (except one) accesses are through ifp anyway. IF_LLADDR() works faster, and all (except one) ifaddr_byindex() users were converted to use ifp->if_addr.
- Stop storing a (pointer to) Ethernet address in "struct arpcom", and drop the IFP2ENADDR() macro; all users have been converted to use IF_LLADDR() instead.
|
152296 |
11-Nov-2005 |
ru |
- Make IFP2ENADDR() a pointer to IF_LLADDR() rather than another copy of Ethernet address.
- Change iso88025_ifattach() and fddi_ifattach() to accept MAC address as an argument, similar to ether_ifattach(), to make this work.
|
152209 |
08-Nov-2005 |
thompsa |
Move the cloned interface list management in to if_clone. For some drivers the softc lists and associated mutex are now unused so these have been removed.
Calling if_clone_detach() will now destroy all the cloned interfaces for the driver and in most cases is all thats needed to unload.
Idea by: brooks Reviewed by: brooks
|
152070 |
04-Nov-2005 |
jkim |
This commit was generated by cvs2svn to compensate for changes in r152069, which included commits to RCS files with non-trunk default branches.
|
152059 |
04-Nov-2005 |
njl |
This commit was generated by cvs2svn to compensate for changes in r152058, which included commits to RCS files with non-trunk default branches.
|
152020 |
03-Nov-2005 |
jkim |
Fix build breakage on tinderbox.
|
151946 |
01-Nov-2005 |
jkim |
Update to reflect import of ACPI-CA 20051021 with includes fixups
|
151945 |
01-Nov-2005 |
jkim |
Local change: remove unnecessary __cdecl
|
151944 |
01-Nov-2005 |
jkim |
Local change: remove compilation warnings
|
151943 |
01-Nov-2005 |
jkim |
Fix conflicts from import of Intel ACPI-CA 20051021
|
151942 |
01-Nov-2005 |
jkim |
Unchanged files that are off the vendor branch
|
151941 |
01-Nov-2005 |
jkim |
This commit was generated by cvs2svn to compensate for changes in r151940, which included commits to RCS files with non-trunk default branches.
|
151938 |
01-Nov-2005 |
jkim |
This commit was generated by cvs2svn to compensate for changes in r151937, which included commits to RCS files with non-trunk default branches.
|
151897 |
31-Oct-2005 |
rwatson |
Normalize a significant number of kernel malloc type names:
- Prefer '_' to ' ', as it results in more easily parsed results in memory monitoring tools such as vmstat.
- Remove punctuation that is incompatible with using memory type names as file names, such as '/' characters.
- Disambiguate some collisions by adding subsystem prefixes to some memory types.
- Generally prefer lower case to upper case.
- If the same type is defined in multiple architecture directories, attempt to use the same name in additional cases.
Not all instances were caught in this change, so more work is required to finish this conversion. Similar changes are required for UMA zone names.
|
151604 |
24-Oct-2005 |
obrien |
Add a commented out version of what was done for the r20041119sysinc import.
|
151603 |
24-Oct-2005 |
obrien |
Fix conflicts of import of Intel ACPI-CA 20041119 with system includes fixups.
|
151601 |
24-Oct-2005 |
obrien |
This commit was generated by cvs2svn to compensate for changes in r151600, which included commits to RCS files with non-trunk default branches.
|
151297 |
13-Oct-2005 |
ru |
In detach method, move if_free() after bus_teardown_intr().
|
151266 |
12-Oct-2005 |
thompsa |
Change the reference counting to count the number of cloned interfaces for each cloner. This ensures that ifc->ifc_units is not prematurely freed in if_clone_detach() before the clones are destroyed, resulting in memory modified after free. This could be triggered with if_vlan.
Assert that all cloners have been destroyed when freeing the memory.
Change all simple cloners to destroy their clones with ifc_simple_destroy() on module unload so the reference count is properly updated. This also cleans up the interface destroy routines and allows future optimisation.
Discussed with: brooks, pjd, -current Reviewed by: brooks
|
150220 |
16-Sep-2005 |
ru |
Fix "struct ifnet" leak if attach() fails in the middle.
|
150000 |
11-Sep-2005 |
obrien |
Per a request from Nick Triantos of nVidia, nVidia's legal department asked that we provide their license document beside their nForce MCP object code.
|
149982 |
11-Sep-2005 |
mlaier |
Stop leaking a lock. This used to cause a propagate_priority() page fault when setting syncdev and syncpeer.
Reported by: Dominic Marks
|
149893 |
08-Sep-2005 |
mlaier |
Unbreak the build. Committed from the wrong directory.
|
149884 |
08-Sep-2005 |
mlaier |
Commit imported changes to HEAD: pf_ioctl.c Revision 1.153 Sun Aug 7 11:37:33 2005 UTC by dhartmei | verify ticket in DIOCADDADDR, from Boris Polevoy, ok deraadt@
pf_ioctl.c Revision 1.158 Mon Sep 5 14:51:08 2005 UTC by dhartmei | in DIOCCHANGERULE, properly initialize table, if used in NAT rule. | from Boris Polevoy <vapcom at mail dot ru>, ok mcbride@
pf.c Revision 1.502 Mon Aug 22 11:54:25 2005 UTC by dhartmei | when nat'ing icmp 'connections', replace icmp id with proxy values | (similar to proxy ports for tcp/udp). not all clients use | per-invokation random ids, this allows multiple concurrent | connections from such clients. | thanks for testing to Rod Whitworth, "looks ok" markus@
pf.c Revision 1.501 Mon Aug 22 09:48:05 2005 UTC by dhartmei | fix rdr to bitmask replacement address pool. patch from Max Laier, | reported by Boris Polevoy, tested by Jean Debogue, ok henning@
Obtained from: OpenBSD MFC after: 3 days
|
148891 |
09-Aug-2005 |
mlaier |
Wrap the new world order in __FreeBSD__ to ease future imports.
|
148887 |
09-Aug-2005 |
rwatson |
Propagate rename of IFF_OACTIVE and IFF_RUNNING to IFF_DRV_OACTIVE and IFF_DRV_RUNNING, as well as the move from ifnet.if_flags to ifnet.if_drv_flags. Device drivers are now responsible for synchronizing access to these flags, as they are in if_drv_flags. This helps prevent races between the network stack and device driver in maintaining the interface flags field.
Many __FreeBSD__ and __FreeBSD_version checks maintained and continued; some less so.
Reviewed by: pjd, bz MFC after: 7 days
|
148196 |
20-Jul-2005 |
mlaier |
Prevent a race condition. As pf_send_tcp() - called for expired synproxy states - has to drop the lock when calling back to ip_output(), the state purge timeout might run and gc the state. This results in a rb-tree inconsistency. With this change we flag expiring states while holding the lock and back off if the flag is already set.
Reported by: glebius MFC after: 2 weeks
|
148176 |
20-Jul-2005 |
ume |
move RFC3542 related definitions into ip6.h.
Submitted by: Keiichi SHIMA <keiichi__at__iijlab.net> Reviewed by: mlaier Obtained from: KAME
|
148015 |
14-Jul-2005 |
mlaier |
Export pfsyncstats via sysctl "net.inet.pfsync" in order to print them with netstat (seperate commit).
Requested by: glebius MFC after: 1 week
|
147614 |
26-Jun-2005 |
mlaier |
Properly initialize ifq_maxlen for the defered send queue and make it actually work. Also use the right semantics for IF_HANDOFF to get correct stats.
Reported and tested by: Sascha Luck <sascha at c4inet dot net> Approved by: re (blanket)
|
147547 |
23-Jun-2005 |
darrenr |
Fix some minor problems before release: (1) "ipf -T" is broken for fetching single entries and (2) loading rules with numbered collections does not order insertion right. (3) stats aren't accumulated for hash table memory failures
Approved by: re (dwhite)
|
147367 |
14-Jun-2005 |
darrenr |
locking on exit of reading from ip_sync is not correct for all instances
Approved by: re (dwhite)
|
147321 |
12-Jun-2005 |
mlaier |
Mark pf callouts as NET_MPSAFE.
Requested by: yongari (serveral times) Approved by: re (blanket) MFC after: 1 week
|
147261 |
10-Jun-2005 |
mlaier |
Defer ip_output of pfsync updates to an independent callout thread instead of just dropping the lock around the ip_output call. This used to cause corrupted state tree walks for some call-paths.
In a second stage all callouts will be marked MPSAFE according to the setting of mpsafenet.
Reported and tested by: Matthew Grooms <mgrooms at seton dot org> MFC after: 3 days X-MFC after: Marking callouts MPSAFE + 1 week
|
147256 |
10-Jun-2005 |
brooks |
Stop embedding struct ifnet at the top of driver softcs. Instead the struct ifnet or the layer 2 common structure it was embedded in have been replaced with a struct ifnet pointer to be filled by a call to the new function, if_alloc(). The layer 2 common structure is also allocated via if_alloc() based on the interface type. It is hung off the new struct ifnet member, if_l2com.
This change removes the size of these structures from the kernel ABI and will allow us to better manage them as interfaces come and go.
Other changes of note: - Struct arpcom is no longer referenced in normal interface code. Instead the Ethernet address is accessed via the IFP2ENADDR() macro. To enforce this ac_enaddr has been renamed to _ac_enaddr. - The second argument to ether_ifattach is now always the mac address from driver private storage rather than sometimes being ac_enaddr.
Reviewed by: sobomax, sam
|
146540 |
23-May-2005 |
harti |
This commit was generated by cvs2svn to compensate for changes in r146539, which included commits to RCS files with non-trunk default branches.
|
146277 |
16-May-2005 |
darrenr |
Enable building /sbin/ipf (but not the rescue version) with the ability to parse bpf strings for filter rules in ipf.conf
|
146229 |
15-May-2005 |
darrenr |
Enable IPFilter to correctly determine if BPF has been optioned into the kernel it is being compiled against and subsequently enable using BPF for packet matching in ipf rules.
|
145886 |
04-May-2005 |
mlaier |
if_mtu not ifp_mtu.
|
145875 |
04-May-2005 |
mlaier |
Bring back fix from rev. 1.28 which was lost during the import.
|
145874 |
04-May-2005 |
mlaier |
Combine rev. 1.29 and 1.30 to something that will make sense for future imports.
|
145873 |
04-May-2005 |
mlaier |
Make LINT happy.
|
145863 |
04-May-2005 |
andre |
Pass icmp_error() the MTU argument directly instead of an interface pointer. This simplifies a couple of uses and removes some XXX workarounds.
|
145836 |
03-May-2005 |
mlaier |
Resolve conflicts created during the import of pf 3.7 Some features are missing and will be implemented in a second step. This is functional as is.
Tested by: freebsd-pf, pfsense.org Obtained from: OpenBSD X-MFC after: never (breaks API/ABI)
|
145660 |
29-Apr-2005 |
ru |
Fix the following warnings on amd64:
/usr/src/sbin/ipf/ipftest/../../../sys/contrib/ipfilter/netinet/ip_frag.c: In function `fr_ipid_newfrag': /usr/src/sbin/ipf/ipftest/../../../sys/contrib/ipfilter/netinet/ip_frag.c:397: warning: cast to pointer from integer of different size /usr/src/sbin/ipf/ipftest/../../../sys/contrib/ipfilter/netinet/ip_frag.c: In function `fr_ipid_knownfrag': /usr/src/sbin/ipf/ipftest/../../../sys/contrib/ipfilter/netinet/ip_frag.c:582: warning: cast from pointer to integer of different size
|
145640 |
28-Apr-2005 |
darrenr |
Don't use quad_t on FreeBSD (deprecated) so use "long long" instead. Someday this should be converted to uint64_t and printstate.c changed to use those horrid PRiud64 things.
|
145582 |
27-Apr-2005 |
darrenr |
The current H.323 proxy source has a license that isn't suitable for inclusion with FreeBSD so we shouldn't be trying to include it here.
|
145579 |
27-Apr-2005 |
darrenr |
- Comment out duplicate rcsid strings in *.c files - Move SIOCPROXY from ip_nat.h to ip_proxy.h and fix ip_proxy.h so that it can be easily compiled into kdump, et al.
|
145562 |
26-Apr-2005 |
darrenr |
Add an include for netinet/ip_compat.h directly so that we don't need to add another special file in the creation of ioctls.c for kdump.
|
145522 |
25-Apr-2005 |
darrenr |
Merge the changes from 3.4.35 to 4.1.8 into the kernel source tree
|
145517 |
25-Apr-2005 |
darrenr |
This commit was generated by cvs2svn to compensate for changes in r145516, which included commits to RCS files with non-trunk default branches.
|
145398 |
22-Apr-2005 |
glebius |
Fix error in synproxy connection completion. Source and destination windows were confused, one instead of other. This error was masked, because first segment of just established connection is usually smaller than initially announced window, and it was successfully passed. First window reannouncement corrected erroneous 'seqhi' value. The error showed up when client connected to synproxy with zero initial window, and reannounced it after session establishment.
In collaboration with: dhartmei [we came to same patch independtly] Reviewed by: mlaier Sponsored by: Rambler MFC after: 3 days
|
145142 |
16-Apr-2005 |
rwatson |
Modify the alq(9) alq_open() API to accept a file creation mode, rather than defaulting the cmode argument to vn_open() to 0. Supply a default argument of ALQ_DEFAULT_CMODE (0600) in current callers.
Discussed with/pointed out by: hmp Reveiwed by: jeff, hmp MFC after: 3 days
|
145030 |
13-Apr-2005 |
glebius |
Fix mss byte order, only affects synproxy code path.
Submitted by: John L. Scarfone via OpenBSD Reviewed by: mlaier Obtained from: OpenBSD, rev. 1.483 MFC after: 2 days
|
143440 |
12-Mar-2005 |
obrien |
This commit was generated by cvs2svn to compensate for changes in r143439, which included commits to RCS files with non-trunk default branches.
|
142988 |
02-Mar-2005 |
scottl |
Move all of the hptmv files to /sys/dev/hptmv so that they won't be mistaken for being on a CVS vendor branch. The files were moved via a repo-copy.
|
142731 |
28-Feb-2005 |
obrien |
Add FreeBSD ID.
|
142720 |
27-Feb-2005 |
phk |
Use dynamic major number allocation.
|
142409 |
25-Feb-2005 |
sam |
avoid sneaky double free
Noticed by: Coverity Prevent analysis tool Reviewed by: scottl
|
142201 |
22-Feb-2005 |
green |
Do not fail to initialize callouts (on SMP only) -- it leads to crashing.
|
142179 |
21-Feb-2005 |
mlaier |
Fix a terrible braino in pfi_maybe_destroy() and unbreak "$pfctl -Fall" with renamed interfaces.
PR: kern/77645 Reported by: Harald Schmalzbauer <harryNOschmalzbauerSPAMde> Reviewed by: yongari MFC after: 3 days
|
142178 |
21-Feb-2005 |
mlaier |
Don't use the static CALLOUT_INITIALIZER for __FreeBSD_version >= 600000. It was a bad idea, but since it is done like this in the vendor source we keep it around for older versions. As a safe guard against future misuse we don't even define CALLOUT_INITIALIZER anymore.
This fixes ALTQ after callout_init_mtx() and takes altq_var.h off the vendor branch.
Submitted by: Divacky Roman <xdivac02NOstud.fit.vutbrSPAMcz> (w/ changes)
|
142006 |
17-Feb-2005 |
yongari |
Fix inteface clear time. pf printed "Thu Jan 1 09:00:01 1970" in "pfctl -vvsI" output when pf was statically linked to kernel.
Discussed with: mlaier
|
141584 |
09-Feb-2005 |
mlaier |
Access softc embedded struct ifnet via function macro to make it easier to untangle struct ifnet and softc/arpcom in the future.
Requested by: brooks
|
141219 |
03-Feb-2005 |
mdodd |
- Split out PCI support. - Add previously removed ISA support.
Submitted by: David S. Madole <david AT madole.net>
|
140518 |
20-Jan-2005 |
dhartmei |
Use the packet's address family instead of the rule's when selecting a replacement address for an rdr rule. Some rdr rules have no address family (when the replacement is a table and no other criterion implies one AF). In this case, pf would fail to select a replacement address and drop the packet due to translation failure.
Found by: Gustavo A. Baratto
|
140494 |
19-Jan-2005 |
dhartmei |
Prohibit ruleset changes at securelevel > 2, not > 1. It's documented like this in init(8), but the code didn't match the documentation.
Submitted by: Juraj Lutter <otis at sk dot FreeBSD dot org> Agrees: mlaier
|
140217 |
14-Jan-2005 |
njl |
This commit was generated by cvs2svn to compensate for changes in r140216, which included commits to RCS files with non-trunk default branches.
|
140095 |
12-Jan-2005 |
njl |
This commit was generated by cvs2svn to compensate for changes in r140094, which included commits to RCS files with non-trunk default branches.
|
139894 |
08-Jan-2005 |
darrenr |
Elminate 1 LOR (actually a recursive mutex grab) involving ipfilter where we loop through all the list of NICs (struct ifnet), holding the lock on it and then do a name lookup with ifunit() whilst holding it.
|
139327 |
26-Dec-2004 |
darrenr |
* Remove some code that's in a #ifndef FreeBSD that's no longer used.
|
139326 |
26-Dec-2004 |
darrenr |
* The #ifdef's to cause mutex's for freebsd to be declared were meant to pick up on USE_MUTEX being defined, but this patch * Remove some code that's in a #ifndef FreeBSD that's no longer used.
|
139284 |
25-Dec-2004 |
scottl |
Darnit, through a maze of twisty passages, ipfilter needs to have PFIL_HOOKS defined. Revert part of the previous commit to fix this.
|
139282 |
25-Dec-2004 |
scottl |
Sprinkle in some __FreeBSD_version checks so that this compiles again. Don't define PFIL_HOOKS anymore.
Submitted by: keramida
|
139255 |
24-Dec-2004 |
darrenr |
Enable fine grained locking within IPFilter, using mtx(9) and sx(9) allowing the the "needs giant" flag to be removed from the driver.
|
139045 |
19-Dec-2004 |
dhartmei |
Initialise init_addr in pf_map_addr() in the PF_POOL_ROUNDROBIN, prevents a possible endless loop in pf_get_sport() with 'static-port'
ICMP state entries use the ICMP ID as port for the unique state key. When checking for a usable key, construct the key in the same way. Otherwise, a colliding key might be missed or a state insertion might be refused even though it could be inserted. The second case triggers the endless loop, possibly allowing a NATed LAN client to lock up the kernel.
PR: kern/74930 Reported and tested by: Hugo Silva, Srebrenko Sehic MFC after: 3 days
|
139005 |
18-Dec-2004 |
mlaier |
Make ip_nat compile again. Should read #if->n<-def LARGE_NAT as in ipf 4.x
|
138979 |
17-Dec-2004 |
darrenr |
Move two variables that are unused if LARGE_NAT is defined inside an #ifdef to keep them out of harms way when compiling.
PR: 72783
|
138947 |
17-Dec-2004 |
darrenr |
Allow ipnat redirect rules to work for non-TCP/UDP packets.
PR: 70038 Submitted by: fming@borderware.com Reviewed by: darrenr Obtained from: fming@borderware.com
|
138928 |
16-Dec-2004 |
darrenr |
Using just m_pullup to get all of the interesting bits in packet into one buffer doesn't work for ipv6 packets, so use m_defrag() here instead as an easy drop-in replacement.
PR: 70399
|
138666 |
10-Dec-2004 |
mlaier |
Compile pfsync w/o bpf.
Noticed by: "Jayel Villamin" <jarthel operamail com>
|
138589 |
08-Dec-2004 |
sam |
clear old files now in public
|
138587 |
08-Dec-2004 |
sam |
resolve merge conflict
|
138584 |
08-Dec-2004 |
sam |
This commit was generated by cvs2svn to compensate for changes in r138583, which included commits to RCS files with non-trunk default branches.
|
138387 |
05-Dec-2004 |
dhartmei |
IPv6 packets can contain headers (like options) before the TCP/UDP/ICMP6 header. pf finds the first TCP/UDP/ICMP6 header to filter by traversing the header chain. In the case where headers are skipped, the protocol checksum verification used the wrong length (included the skipped headers), leading to incorrectly mismatching checksums. Such IPv6 packets with headers were silently dropped.
Discovered by: Bernhard Schmidt MFC after: 1 week
|
138299 |
02-Dec-2004 |
marks |
This commit was generated by cvs2svn to compensate for changes in r138298, which included commits to RCS files with non-trunk default branches.
|
138297 |
02-Dec-2004 |
marks |
This commit was generated by cvs2svn to compensate for changes in r138296, which included commits to RCS files with non-trunk default branches.
|
138295 |
01-Dec-2004 |
marks |
Local change: Remove warnings from vendor files.
Approved by: njl MFC after: 1 week
|
138294 |
01-Dec-2004 |
marks |
Local change: In the resume path, give up after waiting for a while for WAK_STS to be set. Some BIOSs never set it.
Approved by: njl MFC after: 1 week
|
138293 |
01-Dec-2004 |
marks |
Local change: Put various debugging options under ACPI_DISASSEMBLER.
Approved by: njl MFC after: 1 week
|
138292 |
01-Dec-2004 |
marks |
Unchanged files that are off the vendor branch.
Approved by: njl MFC after: 1 week
|
138288 |
01-Dec-2004 |
marks |
This commit was generated by cvs2svn to compensate for changes in r138287, which included commits to RCS files with non-trunk default branches.
|
138041 |
24-Nov-2004 |
dhartmei |
fix a bug that leads to a crash when binat rules of the form 'binat from ... to ... -> (if)' are used, where the interface is dynamic.
Discovered by: kos(at)bastard(dot)net Analyzed by: Pyun YongHyeon Approved by: mlaier (mentor) MFC after: 1 week
|
137413 |
08-Nov-2004 |
ru |
Removed the remnants of gx(4).
|
137159 |
03-Nov-2004 |
mlaier |
Improved interface handling. This should fix the use of renamed interfaces (ifconfig xl0 name foo) as well as some special interfaces such as the 6to4 tunnel.
Reported by: Ed Schouten <ed (at) il ! fontys , nl> Tested by: freebsd-pf PR: kern/72444 MFC after: 3 weeks
|
136925 |
24-Oct-2004 |
mlaier |
Fix a panic discovered with some apache2 configure test (that seemed to trigger a socket creation race some some kind). Checking for non-NULL socket and credential is not a bad idea anyway. Unfortunatly too late for the release.
Reported & tested by: Gilbert Cao MFC after: 2 weeks
|
136862 |
24-Oct-2004 |
scottl |
Fix some warnings that only triggered in LINT.
|
136857 |
24-Oct-2004 |
scottl |
Embed the correct name.
|
136849 |
24-Oct-2004 |
scottl |
Import the HighPoint RocketRAID 182x driver. Thanks to HighPoint for providing the original driver, and thanks to IronSystems for providing hardware for testing.
|
135920 |
29-Sep-2004 |
mlaier |
Add an additional struct inpcb * argument to pfil(9) in order to enable passing along socket information. This is required to work around a LOR with the socket code which results in an easy reproducible hard lockup with debug.mpsafenet=1. This commit does *not* fix the LOR, but enables us to do so later. The missing piece is to turn the filter locking into a leaf lock and will follow in a seperate (later) commit.
This will hopefully be MT5'ed in order to fix the problem for RELENG_5 in forseeable future.
Suggested by: rwatson A lot of work by: csjp (he'd be even more helpful w/o mentor-reviews ;) Reviewed by: rwatson, csjp Tested by: -pf, -ipfw, LINT, csjp and myself MFC after: 3 days
LOR IDs: 14 - 17 (not fixed yet)
|
135615 |
23-Sep-2004 |
mlaier |
Protect sockaddr_union definitions with a protecting define. This allows to build kernels with FAST_IPSEC and PF. This is the least disruptive fix.
PR: kern/71836 Reviewed by: bms, various mailing lists MFC after: 3 days
|
135352 |
17-Sep-2004 |
mlaier |
Break out altq_enable/disable from DIOC{START,STOP}ALTQ into seprate functions that can be called from enable/disable pf as well. This improves switching from non-altq ruleset to altq ruleset (and the other way 'round) by a great deal and makes pfctl act like the user would except it to.
PR: kern/71746 Tested by: Aurilien "beorn" Rougemont (PR submitter) MFC after: 3 days
|
135215 |
14-Sep-2004 |
mlaier |
Reactivate skipping over bogus IPCP addresses on ppp interfaces. Be more careful with the skip condition this time. Addresses are only not taken into account if: - The interface is POINTTOPOINT - There is no route installed for the address - The user specified noalias (:0) and - We are looking at an IPv4 address.
This should be enough paranoia to not cause any false positives.
PR: misc/69954 Discussed with: yongari MFC after: 4 days
|
135196 |
14-Sep-2004 |
mlaier |
Move pf* init from SI_SUB_PSEUDO to SI_SUB_PROTO_IFATTACHDOMAIN where it is save to call if_attachdomain from if_attach() (as done for if_loop.c). We will now end up with a properly initialized if_afdata array and the nd6 callout will no longer try to deref a NULL pointer.
Still this is a temp workaround and the locking for if_afdata should be revisited at a later point.
Requested by: rwatson Discussed with and tested by: yongari (a while ago) PR: kern/70393 MFC after: 5 days
|
135078 |
11-Sep-2004 |
mlaier |
One more round on the H/W supported checksum code: Fix NICs that can't do the pseudo header. We really need the TCP packet length here. This happens to end up in ip->ip_len in tcp_input.c, but here we should get it from the len function variable instead.
Submitted by: yongari Tested by: Nicolas Linard, yongari (sparc64 + hme) MFC after: 5 days
|
134402 |
27-Aug-2004 |
andre |
From __FreeBSD_version 600001 on PFIL_HOOKS is permanently in the kernel and doesn't require to include opt_pfil_hooks.h.
|
134166 |
22-Aug-2004 |
mlaier |
Use securelevel_gt instead of reading global securelevel unprotected.
Submitted by: yongari MFC after: 3 days
|
133932 |
18-Aug-2004 |
njl |
This commit was generated by cvs2svn to compensate for changes in r133931, which included commits to RCS files with non-trunk default branches.
|
133872 |
16-Aug-2004 |
mlaier |
Comment out rev. 1.4 after problems w/ IPv6, a better solution must be found.
|
133720 |
14-Aug-2004 |
dwmalone |
Get rid of the RANDOM_IP_ID option and make it a sysctl. NetBSD have already done this, so I have styled the patch on their work:
1) introduce a ip_newid() static inline function that checks the sysctl and then decides if it should return a sequential or random IP ID.
2) named the sysctl net.inet.ip.random_id
3) IPv6 flow IDs and fragment IDs are now always random. Flow IDs and frag IDs are significantly less common in the IPv6 world (ie. rarely generated per-packet), so there should be smaller performance concerns.
The sysctl defaults to 0 (sequential IP IDs).
Reviewed by: andre, silby, mlaier, ume Based on: NetBSD MFC after: 2 months
|
133705 |
14-Aug-2004 |
rwatson |
Since if_oltr doesn't contain locking or run with INTR_MPSAFE, mark the interface as IFF_NEEDSGIANT so if_start is run holding Giant.
|
133577 |
12-Aug-2004 |
mlaier |
Loopback fix from Mathieu Sauve-Frankel: Add missing check for NULL in DIOCCHANGERULE. This prevents a crash in certain rare cases.
|
133574 |
12-Aug-2004 |
mlaier |
Loopback fix from Daniel Hartmeier: pf_cksum_fixup() was called without last argument from normalization, also fixup checksum when random-id modifies ip_id. This would previously lead to incorrect checksums for packets modified by scrub random-id.
(Originally) Submitted by: yongari
|
133573 |
12-Aug-2004 |
mlaier |
Loopback fix from Henning Brauer: skip over interface addresses without IFA_ROUTE, fixes some issue with pppd
PR: misc/69954
|
133495 |
11-Aug-2004 |
harti |
Exclusion list for easier import.
|
133493 |
11-Aug-2004 |
harti |
This commit was generated by cvs2svn to compensate for changes in r133492, which included commits to RCS files with non-trunk default branches.
|
133181 |
05-Aug-2004 |
mlaier |
Use in_cksum_skip() to calculate in4_cksum instead of doing handrolled magic (that does not compile with !gcc). Moreover we get the benefit for all archs that have a hand optimized in_cksum_skip().
Submitted by: yongari Tested by: me (i386, extensivly), pf4freebsd ML (various)
|
132767 |
28-Jul-2004 |
kan |
Initialize s variable early to shut up GCC warnings. Do not declare inline functions without body as this is useless in general and generates a warning with GCC 3.4.x.
Glanced over by: dhartmei
|
132567 |
23-Jul-2004 |
mlaier |
Fix the following LOR on pf module unload: 1st ifnet (ifnet) @/usr/src/sys/contrib/pf/net/pf_if.c:191 2nd pf task mtx (pf task mtx) @/usr/src/sys/contrib/pf/net/pf_if.c:197
Reported by: Pyun YongHyeon (a long time ago)
|
132566 |
23-Jul-2004 |
mlaier |
Refine pf_check_proto_cksum() a bit in order to avoid additional in_pseudo() calls further down the stack. If we find the cksum to be okay we pretend that the hardware did all the work and hence keep the upper layers from checking again.
Submitted by: Pyun YongHyeon
|
132350 |
18-Jul-2004 |
mlaier |
Fix a stupid attemp to apply host arithmetics to network byte ordered data. This fixes checksum for some drivers with partial H/W ckcsum offloads.
Reported by: Simon 'corecode' Schubert, Devon H. O'Dell, hmp Reviewed by: Pyun YongHyeon
|
132321 |
18-Jul-2004 |
mlaier |
m_tag_copy takes an additional "how" parameter in FreeBSD.
Submitted by: rwatson
|
132303 |
17-Jul-2004 |
mlaier |
Merge in a stable fix from OpenBSD: MFC: Fix by dhartmei@
change pf_route() loop detection: introduce a counter (number of times a packet is routed already) in the mbuf tag, allow at most four times. Fixes some legitimate cases broken by the previous change.
Reviewed by: dhartmei
|
132280 |
17-Jul-2004 |
mlaier |
Define semantic of M_SKIP_FIREWALL more precisely, i.e. also pass associated icmp_error() packets. While here retire PACKET_TAG_PF_GENERATED (which served the same purpose) and use M_SKIP_FIREWALL in pf as well. This should speed up things a bit as we get rid of the tag allocations.
Discussed with: juli
|
132113 |
13-Jul-2004 |
phk |
Send the fla driver in the Attic
|
131974 |
11-Jul-2004 |
darrenr |
Clean up a bunch of white-space difference with IPFilter source as well as remove some superfluous assignments for .d_version/.d_flags in a cdevsw structure initialisation that never sees the light of day in FreeBSD.
|
131827 |
08-Jul-2004 |
harti |
This commit was generated by cvs2svn to compensate for changes in r131826, which included commits to RCS files with non-trunk default branches.
|
131445 |
02-Jul-2004 |
marks |
Local change: Allow access to the field if it is within the region size rounded up to a multiple of the access byte width. This overcomes "off-by-one" programming errors in the AML often found in Toshiba laptops.
|
131444 |
02-Jul-2004 |
marks |
Local diff: allow use of the disassembler.
|
131443 |
02-Jul-2004 |
marks |
Unchanged files that are off the vendor branch.
|
131441 |
02-Jul-2004 |
marks |
This commit was generated by cvs2svn to compensate for changes in r131440, which included commits to RCS files with non-trunk default branches.
|
131262 |
29-Jun-2004 |
darrenr |
Mess from update & merge - don't release the ifnet lock twice, just once and after we're finished with it.
|
130933 |
22-Jun-2004 |
brooks |
Major overhaul of pseudo-interface cloning. Highlights include:
- Split the code out into if_clone.[ch]. - Locked struct if_clone. [1] - Add a per-cloner match function rather then simply matching names of the form <name><unit> and <name>. - Use the match function to allow creation of <interface>.<tag> vlan interfaces. The old way is preserved unchanged! - Also the match function to allow creation of stf(4) interfaces named stf0, stf, or 6to4. This is the only major user visible change in that "ifconfig stf" creates the interface stf rather then stf0 and does not print "stf0" to stdout. - Allow destroy functions to fail so they can refuse to delete interfaces. Currently, we forbid the deletion of interfaces which were created in the init function, particularly lo0, pflog0, and pfsync0. In the case of lo0 this was a panic implementation so it does not count as a user visiable change. :-) - Since most interfaces do not need the new functionality, an family of wrapper functions, ifc_simple_*(), were created to wrap old style cloner functions. - The IF_CLONE_INITIALIZER macro is replaced with a new incompatible IFC_CLONE_INITIALIZER and ifc_simple consumers use IFC_SIMPLE_DECLARE instead.
Submitted by: Maurycy Pawlowski-Wieronski <maurycy at fouk.org> [1] Reviewed by: andre, mlaier Discussed on: net
|
130911 |
22-Jun-2004 |
darrenr |
revert section of code that calls netisr_queue() to match v1.33 of this file
|
130910 |
22-Jun-2004 |
darrenr |
#ifdef's for FreeBSD are wrong, causing too many variable declaractions to disappear.
|
130898 |
22-Jun-2004 |
darrenr |
one too many #endif's from the update broke the build
|
130886 |
21-Jun-2004 |
darrenr |
Update ipfilter from 3.4.31 -> 3.4.35. Some important changes: * block packets that fail to create state table entries * only allow non-fragmented packets to influence whether or not a logged packet is the same as the one logged before. * correct the ICMP packet checksum fixing up when processing ICMP errors for NAT * implement a maximum for the number of entries in the NAT table (NAT_TABLE_MAX and ipf_nattable_max) * frsynclist() wasn't paying attention to all the places where interface names are, like it should. * fix comparing ICMP packets with established TCP state where only 8 bytes of header are returned in the ICMP error.
MFC after: 1 week
|
130680 |
18-Jun-2004 |
phk |
Add missing <sys/module.h> include.
Approved by: sam
|
130639 |
17-Jun-2004 |
mlaier |
Import two fixes from the OpenBSD stable branch: - prevent an endless loop with route-to lo0, fixes PR 3736 (dhartmei@) - The rule_number parameter for pf_get_pool() needs to be 32 bits, not 8 - this fixes corruption of the address pools with large rulesets. (mcbride@, pb@)
Reviewed-by: dhartmei
|
130613 |
16-Jun-2004 |
mlaier |
Commit pf version 3.5 and link additional files to the kernel build.
Version 3.5 brings: - Atomic commits of ruleset changes (reduce the chance of ending up in an inconsistent state). - A 30% reduction in the size of state table entries. - Source-tracking (limit number of clients and states per client). - Sticky-address (the flexibility of round-robin with the benefits of source-hash). - Significant improvements to interface handling. - and many more ...
|
130611 |
16-Jun-2004 |
mlaier |
This commit was generated by cvs2svn to compensate for changes in r130610, which included commits to RCS files with non-trunk default branches.
|
130585 |
16-Jun-2004 |
phk |
Do the dreaded s/dev_t/struct cdev */ Bump __FreeBSD_version accordingly.
|
130550 |
15-Jun-2004 |
mlaier |
Disable "bulk dequeue" when enabling ALTQ so it does not irritate the timing.
|
130508 |
15-Jun-2004 |
mlaier |
Transform tbr_dequeue into a function pointer in order to build drivers with ALTQ enabled versions of IFQ_* macros by default, as requested by serveral others. This is a follow-up to the quick fix I committed yesterday which turned off the ALTQ checks for non-ALTQ kernels.
|
130475 |
14-Jun-2004 |
mlaier |
Remove some more leftover from the old pfaltq_module hack to allow for kernels w/ pf, but w/o altq.
Reported-by: Xin LI
|
130440 |
13-Jun-2004 |
mlaier |
#if out an old leftover in the KAME code. opt_cpu.h is no longer useful here and breaks build on some arch.
Found-by: tinderbox
|
130397 |
13-Jun-2004 |
mlaier |
Prepare pf for building with ALTQ: - remove old pfaltq module linkage - move pfaltq_running to pf_ioctl.c It is protected by PF_LOCK()
|
130384 |
12-Jun-2004 |
mlaier |
Add an additional queue which will be "owned by the driver". This allows to rig a PREPEND macro for ALTQ as the POLL/DEQUEUE semantic is very bad in terms of locking. We make this a full functional queue to allow "bulk dequeue" which will further reduce the locking overhead (for non-altq enabled devices). Drivers will access this via the following macros, which will show up in <net/if_var.h> once we expose ALTQ to the build:
IFQ_DRV_DEQUEUE(ifq, m) - takes a mbuf off the queue (driver queue first) IFQ_DRV_PREPEND(ifq, m) - pushes a mbuf back to the driver queue IFQ_DRV_PURGE(ifq) - drops all packets in both queues IFQ_DRV_IS_EMPTY(ifq) - checks for pending mbufs in either queue
One has to make sure that the first three are protected by a driver mutex. At the moment most network drivers still require Giant, so this is not an issue. Even those that have thier own mutex usually hold it in if_start and the like, so this requirement is almost always satisfied.
This evolved from a discussion with Andrew Gallatin.
|
130368 |
12-Jun-2004 |
mlaier |
FreeBSD-ify ALTQ: - add locking - disable ALTQ3_COMPAT by default (do not remove the code to keep the diff towards KAME small) - put some more code under ALTQ3 conditional compilation as it should be - account for if_xname - some more minor compile fixes
As people started wondering: The strange path layout "altq/altq" is there to avoid "-Isys/contrib" and make it "-Isys/contrib/altq" instead, as we will need at least <altq/altq.h> and <altq/if_altq.h> for kernel compilation.
The "freebsd4_..." in the privious commit is just the best tag name in the KAME tree I could find to classify this in order to track its history. It does *not* mean that this will go to 4-STABLE or anything of that kind.
|
130366 |
12-Jun-2004 |
mlaier |
This commit was generated by cvs2svn to compensate for changes in r130365, which included commits to RCS files with non-trunk default branches.
|
130253 |
08-Jun-2004 |
darrenr |
Recognise NOINET6 as an indication to not build IPv6 enabled source even if FreeBSD header files, etc, support it.
Submitted by: Sergey Mokryshev <mokr@mokr.net>
|
129907 |
31-May-2004 |
mlaier |
"Get rid of the nested include of <sys/module.h> from <sys/kernel.h>" or better do no longer depend on it.
Requested-by: phk Approved-by: bms(mentor)
|
129882 |
30-May-2004 |
phk |
Add missing #include <sys/module.h>
|
129695 |
25-May-2004 |
njl |
This commit was generated by cvs2svn to compensate for changes in r129694, which included commits to RCS files with non-trunk default branches.
|
129691 |
25-May-2004 |
njl |
Local change: allow usermode to compile this header. Submitted to vendor.
|
129690 |
25-May-2004 |
njl |
Local change: don't hang forever if WAK_STS is never set.
|
129689 |
25-May-2004 |
njl |
Local change: remove warnings.
|
129688 |
25-May-2004 |
njl |
Local diff: allow use of the disassembler.
|
129687 |
25-May-2004 |
njl |
Unchanged files that are off the vendor branch.
|
129685 |
25-May-2004 |
njl |
This commit was generated by cvs2svn to compensate for changes in r129684, which included commits to RCS files with non-trunk default branches.
|
129060 |
09-May-2004 |
marcel |
This commit was generated by cvs2svn to compensate for changes in r129059, which included commits to RCS files with non-trunk default branches.
|
128978 |
05-May-2004 |
njl |
Add sys/types.h for both kernel and user compiles.
|
128846 |
02-May-2004 |
dhartmei |
Commit three imported bugfixes from OpenBSD 3.4-stable:
- change pf_get_pool() argument rule_number type from u_int32_t to u_int8_t, fixes corruption of address pools with large rulesets (mcbride@) - prevent endless loops with route-to (dhartmei@) - limit option length to 2 octets max (frantzen@)
Obtained from: OpenBSD Approved by: mlaier(mentor), bms(mentor)
|
128255 |
14-Apr-2004 |
njl |
Remove warnings from vendor files. This takes some files off the vendor branch but they have indicated they will not fix these warnings.
|
128246 |
14-Apr-2004 |
njl |
Even though the patch has been submitted to the vendor, this file is off the vendor branch. Once more, with feeling!
|
128218 |
14-Apr-2004 |
njl |
Check in files with local changes:
* In the resume path, give up after waiting for a while for WAK_STS to be set. Some BIOSs never set it.
* Allow access to the field if it is within the region size rounded up to a multiple of the access byte width. This overcomes "off-by-one" programming errors in the AML often found in Toshiba laptops.
|
128216 |
14-Apr-2004 |
njl |
Check in unmodified files off the vendor branch.
|
128213 |
14-Apr-2004 |
njl |
This commit was generated by cvs2svn to compensate for changes in r128212, which included commits to RCS files with non-trunk default branches.
|
128211 |
14-Apr-2004 |
njl |
Add another cleanfile for future imports.
|
128209 |
14-Apr-2004 |
brooks |
Staticize <if>_clone_{create,destroy} functions.
Reviewed by: mlaier
|
128129 |
11-Apr-2004 |
mlaier |
Commit import of OpenBSD-stable fix:
Fix by dhartmei@ and mcbride@ 1.433 Properly m_copyback() modified TCP sequence number after demodulation 1.432 Fix icmp checksum when sequence number modlation is being used. Also fix a daddr vs saddr cut-n-paste error in ICMP error handling.
Fixes PR 3724
Obtained from: OpenBSD Reviewed by: dhartmei Approved by: rwatson
|
128019 |
07-Apr-2004 |
imp |
Remove advertising clause from University of California Regent's license, per letter dated July 22, 1999 and email from Peter Wemm, Alan Cox and Robert Watson.
Approved by: core, peter, alc, rwatson
|
127900 |
05-Apr-2004 |
njl |
Unbreak the bootloader build by excluding ctype.h.
Submitted by: Stefan Farfeleder <stefan@fafoe.narf.at>
|
127874 |
05-Apr-2004 |
njl |
Add #include for ctype.h to cover strupr() in the !_KERNEL case.
Submitted by: Stefan Farfeleder <stefan@fafoe.narf.at>
|
127629 |
30-Mar-2004 |
mlaier |
Shut up a couple of annoying gcc warnings. Do not enclose the fixes with #ifdefs in order to loop it back to OpenBSD after the next import. There are a some implicit asserts involved which might be better spelled out explicitly (af == AF_INET ...)
Approved by: bms(mentor)
|
127585 |
29-Mar-2004 |
imp |
Eliminate support for FreeBSD 3.x and earlier now that we're in the glide path for the 5.x branch.
|
127531 |
28-Mar-2004 |
mlaier |
Commit two fixes from OpenBSD's stable branch: - Fix binat for incoming connections when a netblock (not just a single address) is used for source in the binat rule. closes PR 3535, reported by Karl O.Pinc. ok henning@, cedric@
- Fix a problem related to empty anchor rulesets, which could cause a kernel panic.
Approved by: bms(mentor)
|
127313 |
22-Mar-2004 |
njl |
Revert 1.22. Go back to "FreeBSD" as our _OS value. Since we now support _OSI, we can claim compatibility with MS products without claiming to BE one. :-)
|
127178 |
18-Mar-2004 |
njl |
Check in files off the vendor branch as well as files with local patches.
|
127176 |
18-Mar-2004 |
njl |
This commit was generated by cvs2svn to compensate for changes in r127175, which included commits to RCS files with non-trunk default branches.
|
127145 |
17-Mar-2004 |
mlaier |
Style(9) round for the pf kernel parts. Mostly #if defined() -> #ifdef
Also set HOOK_HACK to true (remove the related #ifdef's) as we have the hooks in the kernel this was missed during the merge from the port.
Noticed by: Amir S. (for the HOOK_HACK part) Approved by: bms(mentor)
|
127135 |
17-Mar-2004 |
njl |
Convert callers to the new bus_alloc_resource_any(9) API.
Submitted by: Mark Santcroos <marks@ripe.net> Reviewed by: imp, dfr, bde
|
126812 |
10-Mar-2004 |
mlaier |
Remove `$Name$' leftovers from the port version reporting.
Noticed by: Craig Rodrigues Approved by: bms(mentor)
|
126577 |
04-Mar-2004 |
njl |
Part 2 of Project Evil: Pretend to be Windows 2000 for buggy ASL that always expects to be running on some MS OS. A survey of ASL shows that this is the 2nd most common expected OS value. (1st is Win98 and we don't emulate its buggy ACPI support.) Our ACPI support is similar to Win2k, also. Put this behavior under ACPICA_PEDANTIC so we can get back to our previous behavior for OSV testing.
|
126521 |
03-Mar-2004 |
njl |
This commit was generated by cvs2svn to compensate for changes in r126520, which included commits to RCS files with non-trunk default branches.
|
126409 |
29-Feb-2004 |
mlaier |
Remove __inline keyword from functions that can't be inlined according to LINT. This fixes LINT compliation for now, but needs to be revised. Changes do not affect the objects.
Approved by: bms(mentor)
|
126382 |
28-Feb-2004 |
njl |
Strip out new, unused file acnetbsd.h
|
126381 |
28-Feb-2004 |
njl |
This commit was generated by cvs2svn to compensate for changes in r126380, which included commits to RCS files with non-trunk default branches.
|
126379 |
28-Feb-2004 |
njl |
Local change: emulate a ReturnOp if the AML expects one but it isn't present. Some buggy BIOSs do not have a ReturnOp even though it is required for a function to return a value.
|
126378 |
28-Feb-2004 |
njl |
Local change: In the resume path, give up after waiting for a while for WAK_STS to be set. Some BIOSs never set it.
|
126377 |
28-Feb-2004 |
njl |
Local change: Allow access to the field if it is within the region size rounded up to a multiple of the access byte width. This overcomes "off-by-one" programming errors in the AML often found in Toshiba laptops.
|
126376 |
28-Feb-2004 |
njl |
Local change: Put various debugging options under ACPI_DISASSEMBLER.
|
126375 |
28-Feb-2004 |
njl |
Unchanged files from ACPICA 20040220 that are off the vendor branch.
|
126373 |
28-Feb-2004 |
njl |
This commit was generated by cvs2svn to compensate for changes in r126372, which included commits to RCS files with non-trunk default branches.
|
126263 |
26-Feb-2004 |
mlaier |
Tweak existing header and other build infrastructure to be able to build pf/pflog/pfsync as modules. Do not list them in NOTES or modules/Makefile (i.e. do not connect it to any (automatic) builds - yet).
Approved by: bms(mentor)
|
126261 |
26-Feb-2004 |
mlaier |
Bring diff from the security/pf port. This has code been tested as a port for a long time and is run in production use. This is the code present in portversion 2.03 with some additional tweaks.
The rather extensive diff accounts for: - locking (to enable pf to work with a giant-free netstack) - byte order difference between OpenBSD and FreeBSD for ip_len/ip_off - conversion from pool(9) to zone(9) - api differences etc.
Approved by: bms(mentor) (in general)
|
126259 |
26-Feb-2004 |
mlaier |
This commit was generated by cvs2svn to compensate for changes in r126258, which included commits to RCS files with non-trunk default branches.
|
126080 |
21-Feb-2004 |
phk |
Device megapatch 4/6:
Introduce d_version field in struct cdevsw, this must always be initialized to D_VERSION.
Flip sense of D_NOGIANT flag to D_NEEDGIANT, this involves removing four D_NOGIANT flags and adding 145 D_NEEDGIANT flags.
|
125975 |
18-Feb-2004 |
phk |
Change the disk(9) API in order to make device removal more robust.
Previously the "struct disk" were owned by the device driver and this gave us problems when the device disappared and the users of that device were not immediately disappearing.
Now the struct disk is allocate with a new call, disk_alloc() and owned by geom_disk and just abandonned by the device driver when disk_create() is called.
Unfortunately, this results in a ton of "s/\./->/" changes to device drivers.
Since I'm doing the sweep anyway, a couple of other API improvements have been carried out at the same time:
The Giant awareness flag has been flipped from DISKFLAG_NOGIANT to DISKFLAG_NEEDSGIANT
A version number have been added to disk_create() so that we can detect, report and ignore binary drivers with old ABI in the future.
Manual page update to follow shortly.
|
124529 |
14-Jan-2004 |
njl |
This commit was generated by cvs2svn to compensate for changes in r124528, which included commits to RCS files with non-trunk default branches.
|
124121 |
04-Jan-2004 |
njl |
This commit was generated by cvs2svn to compensate for changes in r124120, which included commits to RCS files with non-trunk default branches.
|
123333 |
09-Dec-2003 |
njl |
Changes to the import script to handle the compiler/debugger import.
|
123332 |
09-Dec-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r123331, which included commits to RCS files with non-trunk default branches.
|
123330 |
09-Dec-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r123329, which included commits to RCS files with non-trunk default branches.
|
123328 |
09-Dec-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r123327, which included commits to RCS files with non-trunk default branches.
|
123324 |
09-Dec-2003 |
njl |
Unchanged files that are off the vendor branch.
|
123323 |
09-Dec-2003 |
njl |
Local change: In the resume path, give up after waiting for a while for WAK_STS to be set. Some BIOSs never set it.
|
123322 |
09-Dec-2003 |
njl |
Import for 20031203 file off vendor branch.
|
123321 |
09-Dec-2003 |
njl |
Local change: emulate a ReturnOp if the AML expects one but it isn't present. Some buggy BIOSs do not have a ReturnOp even though it is required for a function to return a value.
|
123320 |
09-Dec-2003 |
njl |
Local change: Allow access to the field if it is within the region size rounded up to a multiple of the access byte width. This overcomes "off-by-one" programming errors in the AML often found in Toshiba laptops.
|
123319 |
09-Dec-2003 |
njl |
Local change: Put various debugging options under ACPI_DISASSEMBLER.
|
123318 |
09-Dec-2003 |
njl |
Unchanged files that are off the vendor branch.
|
123316 |
09-Dec-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r123315, which included commits to RCS files with non-trunk default branches.
|
123203 |
07-Dec-2003 |
sam |
This commit was generated by cvs2svn to compensate for changes in r123202, which included commits to RCS files with non-trunk default branches.
|
123108 |
02-Dec-2003 |
brooks |
Use parens more reasionably so we match the vendor code. This is part of the if_xname change.
Submitted by: darrenr Approved by: re (scottl)
|
123042 |
29-Nov-2003 |
sam |
This commit was generated by cvs2svn to compensate for changes in r123041, which included commits to RCS files with non-trunk default branches.
|
122949 |
22-Nov-2003 |
njl |
Commit rev 1.1.1.20 to HEAD. This file was off the vendor branch and thus the changes need to be made to HEAD.
Approved by: re (previously)
|
122946 |
21-Nov-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r122945, which included commits to RCS files with non-trunk default branches.
|
122209 |
07-Nov-2003 |
harti |
This commit was generated by cvs2svn to compensate for changes in r122208, which included commits to RCS files with non-trunk default branches.
|
122207 |
07-Nov-2003 |
harti |
These two files are generated with the ../genfiles script and are not part of the imported distribution.
|
122206 |
07-Nov-2003 |
harti |
This commit was generated by cvs2svn to compensate for changes in r122205, which included commits to RCS files with non-trunk default branches.
|
122138 |
05-Nov-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r122137, which included commits to RCS files with non-trunk default branches.
|
121937 |
03-Nov-2003 |
harti |
Explain how to handle the generated files. Explain that the import must actually be done into the netnatm sub-directory.
|
121936 |
03-Nov-2003 |
harti |
These files are generated by the genfiles script. See FREEBSD-upgrade for instructions how to upgrade these.
|
121935 |
03-Nov-2003 |
harti |
This commit was generated by cvs2svn to compensate for changes in r121934, which included commits to RCS files with non-trunk default branches.
|
121838 |
01-Nov-2003 |
sam |
This commit was generated by cvs2svn to compensate for changes in r121837, which included commits to RCS files with non-trunk default branches.
|
121816 |
31-Oct-2003 |
brooks |
Replace the if_name and if_unit members of struct ifnet with new members if_xname, if_dname, and if_dunit. if_xname is the name of the interface and if_dname/unit are the driver name and instance.
This change paves the way for interface renaming and enhanced pseudo device creation and configuration symantics.
Approved By: re (in principle) Reviewed By: njl, imp Tested On: i386, amd64, sparc64 Obtained From: NetBSD (if_xname)
|
121643 |
29-Oct-2003 |
marcel |
This commit was generated by cvs2svn to compensate for changes in r121642, which included commits to RCS files with non-trunk default branches.
|
121376 |
22-Oct-2003 |
njl |
Allow access to the field if it is within the region size rounded up to a multiple of the access byte width. This overcomes errors in the AML often found in Toshiba laptops. These errors were allowed by the Microsoft ASL compiler and interpreter. This will NOT be imported by ACPI-CA so make the change on our local branch. File was already off the vendor branch.
Submitted by: blaz Original idea: Rick Richardson for Linux
|
121329 |
22-Oct-2003 |
harti |
Some upgrade instructions.
|
121327 |
22-Oct-2003 |
harti |
This commit was generated by cvs2svn to compensate for changes in r121326, which included commits to RCS files with non-trunk default branches.
|
121170 |
17-Oct-2003 |
ume |
use ND_IFINFO().
|
120926 |
09-Oct-2003 |
marcel |
This commit was generated by cvs2svn to compensate for changes in r120925, which included commits to RCS files with non-trunk default branches.
|
120399 |
24-Sep-2003 |
sam |
o remove extraneous include of <net/pfil.h> o guard wrapper code against user-mode compilation
Sponsored by: FreeBSD Foundation
|
120387 |
23-Sep-2003 |
sam |
update to reflect PFIL_HOOKS api changes
Supported by: FreeBSD Foundation
|
120240 |
19-Sep-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r120239, which included commits to RCS files with non-trunk default branches.
|
119305 |
22-Aug-2003 |
imp |
Prefer new location of pci include files (which have only been in the tree for two or more years now), except in a few places where there's code to be compatible with older versions of FreeBSD.
|
118813 |
12-Aug-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r118812, which included commits to RCS files with non-trunk default branches.
|
118766 |
11-Aug-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r118765, which included commits to RCS files with non-trunk default branches.
|
118625 |
07-Aug-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r118624, which included commits to RCS files with non-trunk default branches.
|
118618 |
07-Aug-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r118617, which included commits to RCS files with non-trunk default branches.
|
118614 |
07-Aug-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r118613, which included commits to RCS files with non-trunk default branches.
|
118612 |
07-Aug-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r118611, which included commits to RCS files with non-trunk default branches.
|
118610 |
07-Aug-2003 |
njl |
Remove the user include of ctype.h and instead include it for each utility that uses strupr().
|
118600 |
07-Aug-2003 |
njl |
Comment out ctype.h. It's not ok to always include in the !_KERNEL case since the bootblocks have their own local includes. Sorry for breaking world.
|
118577 |
07-Aug-2003 |
njl |
Add includes to fix user-compilation of acpica. Also clarify a comment about overriding the OS name.
|
118529 |
06-Aug-2003 |
bde |
Broke the warning that this driver uses pessimal (u_short) types for i/o ports by calling the implementation-detail level below inb() and outb() instead of inb() and outb(). Unpessimizing the types is too hard since they are mainly used in microcode.
|
118340 |
02-Aug-2003 |
sam |
This commit was generated by cvs2svn to compensate for changes in r118339, which included commits to RCS files with non-trunk default branches.
|
118119 |
28-Jul-2003 |
peter |
Make this compile on 64 bit systems again. You cannot just cast a 32 bit int to a 64 bit pointer. This file is already off the vendor branch.
|
117647 |
15-Jul-2003 |
njl |
Fix the ACPI_DEBUG build for the non-module case. Move the #define into acfreebsd.h and remove it from the Makefile. Now ACPI_DEBUG implies ACPI_DISASSEMBLER.
Noticed by: marcel
|
117536 |
14-Jul-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r117535, which included commits to RCS files with non-trunk default branches.
|
117528 |
13-Jul-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r117527, which included commits to RCS files with non-trunk default branches.
|
117526 |
13-Jul-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r117525, which included commits to RCS files with non-trunk default branches.
|
117524 |
13-Jul-2003 |
njl |
Commit local patches for files off the vendor branch.
|
117523 |
13-Jul-2003 |
njl |
Unmodified files from the vendor 0619 dist that should no longer be off the vendor branch.
|
117522 |
13-Jul-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r117521, which included commits to RCS files with non-trunk default branches.
|
117466 |
12-Jul-2003 |
marcel |
This commit was generated by cvs2svn to compensate for changes in r117465, which included commits to RCS files with non-trunk default branches.
|
117393 |
11-Jul-2003 |
marcel |
This commit was generated by cvs2svn to compensate for changes in r117392, which included commits to RCS files with non-trunk default branches.
|
116802 |
25-Jun-2003 |
sam |
This commit was generated by cvs2svn to compensate for changes in r116801, which included commits to RCS files with non-trunk default branches.
|
116749 |
23-Jun-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r116748, which included commits to RCS files with non-trunk default branches.
|
115368 |
28-May-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r115367, which included commits to RCS files with non-trunk default branches.
|
115352 |
27-May-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r115351, which included commits to RCS files with non-trunk default branches.
|
115014 |
15-May-2003 |
marcel |
This commit was generated by cvs2svn to compensate for changes in r115013, which included commits to RCS files with non-trunk default branches.
|
114585 |
03-May-2003 |
imp |
This commit was generated by cvs2svn to compensate for changes in r114584, which included commits to RCS files with non-trunk default branches.
|
114457 |
01-May-2003 |
jhb |
Restore local changes accidentally lost in the last import.
Reviewed by: njl
|
114247 |
29-Apr-2003 |
njl |
Resolve conflicts.
|
114244 |
29-Apr-2003 |
njl |
Updated import-preparation script. It now removes vendor paths from header info. With these changes, no manual prep of the dist was necessary.
|
114243 |
29-Apr-2003 |
njl |
Resolve conflicts
|
114240 |
29-Apr-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r114239, which included commits to RCS files with non-trunk default branches.
|
114238 |
29-Apr-2003 |
njl |
This commit was generated by cvs2svn to compensate for changes in r114237, which included commits to RCS files with non-trunk default branches.
|
113799 |
21-Apr-2003 |
obrien |
Explicitly declare 'int' parameters.
|
112946 |
01-Apr-2003 |
phk |
Use bioq_flush() to drain a bio queue with a specific error code. Retain the mistake of not updating the devstat API for now.
Spell bioq_disksort() consistently with the remaining bioq_*().
#include <geom/geom_disk.h> where this is more appropriate.
|
112367 |
18-Mar-2003 |
phk |
Including <sys/stdint.h> is (almost?) universally only to be able to use %j in printfs, so put a newsted include in <sys/systm.h> where the printf prototype lives and save everybody else the trouble.
|
112309 |
16-Mar-2003 |
mdodd |
Catch up with recent infrastructure changes.
|
112304 |
15-Mar-2003 |
mdodd |
Register module dependencies.
|
112302 |
15-Mar-2003 |
mdodd |
G/C unused varilable.
|
112301 |
15-Mar-2003 |
mdodd |
Catch up with recent changes.
|
111979 |
08-Mar-2003 |
phk |
Centralize the devstat handling for all GEOM disk device drivers in geom_disk.c.
As a side effect this makes a lot of #include <sys/devicestat.h> lines not needed and some biofinish() calls can be reduced to biodone() again.
|
111888 |
04-Mar-2003 |
jlemon |
Update netisr handling; Each SWI now registers its queue, and all queue drain routines are done by swi_net, which allows for better queue control at some future point. Packets may also be directly dispatched to a netisr instead of queued, this may be of interest at some installations, but currently defaults to off.
Reviewed by: hsu, silby, jayanth, sam Sponsored by: DARPA, NAI Labs
|
111815 |
03-Mar-2003 |
phk |
Gigacommit to improve device-driver source compatibility between branches:
Initialize struct cdevsw using C99 sparse initializtion and remove all initializations to default values.
This patch is automatically generated and has been tested by compiling LINT with all the fields in struct cdevsw in reverse order on alpha, sparc64 and i386.
Approved by: re(scottl)
|
111247 |
22-Feb-2003 |
phk |
NO_GEOM cleanup:
Move to "struct disk *" centric use of disk_* API.
Remove NOOP ioctl, spl*() and some debug printfs.
|
111119 |
19-Feb-2003 |
imp |
Back out M_* changes, per decision of the TRB.
Approved by: trb
|
110921 |
15-Feb-2003 |
darrenr |
fix bug in updating of interface pointers when resyncing state
|
110916 |
15-Feb-2003 |
darrenr |
Commit import changed from vendor branch of ipfilter to -current head
|
110915 |
15-Feb-2003 |
darrenr |
Commit import changed from vendor branch of ipfilter to -current head
|
110914 |
15-Feb-2003 |
darrenr |
sometimes i hate it when you leave temp files in a directory you import from
|
110912 |
15-Feb-2003 |
darrenr |
This commit was generated by cvs2svn to compensate for changes in r110911, which included commits to RCS files with non-trunk default branches.
|
110694 |
11-Feb-2003 |
phk |
Mark our struct disk with DISKFLAG_CANDELETE instead of the cdevsw with D_CANFREE.
|
110232 |
02-Feb-2003 |
alfred |
Consolidate MIN/MAX macros into one place (param.h).
Submitted by: Hiten Pandya <hiten@unixdaemons.com>
|
109623 |
21-Jan-2003 |
alfred |
Remove M_TRYWAIT/M_WAITOK/M_WAIT. Callers should use 0. Merge M_NOWAIT/M_DONTWAIT into a single flag M_NOWAIT.
|
108172 |
22-Dec-2002 |
hsu |
SMP locking for ifnet list.
|
107328 |
27-Nov-2002 |
iwasaki |
Resolve conflicts arising from the ACPI CA 20021118 import.
|
107326 |
27-Nov-2002 |
iwasaki |
This commit was generated by cvs2svn to compensate for changes in r107325, which included commits to RCS files with non-trunk default branches.
|
106939 |
15-Nov-2002 |
sam |
network interface and link layer changes:
o on input don't strip the Ethernet header from packets o input packet handling is now done with if_input o track changes to ether_ifattach/ether_ifdetach API o track changes to bpf tapping o call ether_ioctl for default handling of ioctl's o use constants from net/ethernet.h where possible
Reviewed by: many Approved by: re
|
105194 |
16-Oct-2002 |
sam |
Replace aux mbufs with packet tags:
o instead of a list of mbufs use a list of m_tag structures a la openbsd o for netgraph et. al. extend the stock openbsd m_tag to include a 32-bit ABI/module number cookie o for openbsd compatibility define a well-known cookie MTAG_ABI_COMPAT and use this in defining openbsd-compatible m_tag_find and m_tag_get routines o rewrite KAME use of aux mbufs in terms of packet tags o eliminate the most heavily used aux mbufs by adding an additional struct inpcb parameter to ip_output and ip6_output to allow the IPsec code to locate the security policy to apply to outbound packets o bump __FreeBSD_version so code can be conditionalized o fixup ipfilter's call to ip_output based on __FreeBSD_version
Reviewed by: julian, luigi (silent), -arch, -net, darren Approved by: julian, silence from everyone else Obtained from: openbsd (mostly) MFC after: 1 month
|
104473 |
04-Oct-2002 |
iwasaki |
Resolve conflicts arising from the ACPI CA 20021002 import.
|
104471 |
04-Oct-2002 |
iwasaki |
This commit was generated by cvs2svn to compensate for changes in r104470, which included commits to RCS files with non-trunk default branches.
|
103714 |
20-Sep-2002 |
phk |
(This commit touches about 15 disk device drivers in a very consistent and predictable way, and I apologize if I have gotten it wrong anywhere, getting prior review on a patch like this is not feasible, considering the number of people involved and hardware availability etc.)
If struct disklabel is the messenger: kill the messenger.
Inside struct disk we had a struct disklabel which disk drivers used to communicate certain metrics to the disklayer above (GEOM or the disk mini-layer). This commit changes this communication to use four explicit fields instead.
Amongst the benefits is that the fields do not get overwritten by wrong or bogus on-disk disklabels.
Once that is clear, <sys/disk.h> which is included in the drivers no longer need to pull <sys/disklabel.h> and <sys/diskslice.h> in, the few places that needs them, have gotten explicit #includes for them.
The disklabel inside struct disk is now only for internal use in the disk mini-layer, so instead of embedding it, we malloc it as we need it.
This concludes (modulus any mistakes) the series of disklabel related commits.
I belive it all amounts to a NOP for all the rest of you :-)
Sponsored by: DARPA & NAI Labs.
|
103688 |
20-Sep-2002 |
phk |
Don't call dkunit() to find our unit number, it is in our softc.
Sponsored by: DARPA & NAI Labs.
|
102564 |
29-Aug-2002 |
iwasaki |
Fix kernel build breakage when ACPI_DEBUG option is specified.
|
102553 |
29-Aug-2002 |
iwasaki |
Resolve conflicts arising from the ACPI CA 20020815 import.
|
102551 |
29-Aug-2002 |
iwasaki |
This commit was generated by cvs2svn to compensate for changes in r102550, which included commits to RCS files with non-trunk default branches.
|
102520 |
28-Aug-2002 |
darrenr |
Finally merge in the changes from ipfilter 3.4.29 to freebsd-current. Main changes here are related to the ftp proxy and making that work better.
|
102326 |
23-Aug-2002 |
archie |
Don't use "NULL" when "0" is really meant. But in this case, "-1" is really meant.
Reviewed by: darrenr
|
102270 |
22-Aug-2002 |
iwasaki |
Prepare for importing newer version of ACPI CA.
|
100969 |
30-Jul-2002 |
iwasaki |
Resolve conflicts arising from the ACPI CA 20020725 import.
|
100967 |
30-Jul-2002 |
iwasaki |
This commit was generated by cvs2svn to compensate for changes in r100966, which included commits to RCS files with non-trunk default branches.
|
99682 |
09-Jul-2002 |
iwasaki |
Resolve conflicts arising from the ACPI CA 20020611 import.
|
99680 |
09-Jul-2002 |
iwasaki |
This commit was generated by cvs2svn to compensate for changes in r99679, which included commits to RCS files with non-trunk default branches.
|
99149 |
30-Jun-2002 |
iwasaki |
Resolve conflicts arising from the ACPI CA 20020404 import.
|
99147 |
30-Jun-2002 |
iwasaki |
This commit was generated by cvs2svn to compensate for changes in r99146, which included commits to RCS files with non-trunk default branches.
|
98146 |
12-Jun-2002 |
iwasaki |
- Add sanity check for argument. - Add new entry to stripdirs. The `generate' directory appeared in acpica-unix-20020517.
|
98004 |
07-Jun-2002 |
darrenr |
Commit changes that happened in IPFilter versions 3.4.27 - 3.4.28
|
95563 |
27-Apr-2002 |
darrenr |
Merge updates from 3.4.26 - 3.4.27.
|
95418 |
25-Apr-2002 |
darrenr |
bring in changes from 3.4.26.
|
95416 |
25-Apr-2002 |
darrenr |
This commit was generated by cvs2svn to compensate for changes in r95415, which included commits to RCS files with non-trunk default branches.
|
93224 |
26-Mar-2002 |
ru |
We don't need ip_ipsec_pxy.c in userland.
|
92720 |
19-Mar-2002 |
alfred |
fix blockno printf formatting warnings.
|
92703 |
19-Mar-2002 |
darrenr |
do not include the missing ip_h323_pxy.c
|
92685 |
19-Mar-2002 |
darrenr |
fix conflicts (mostly damn rcs id's) generated by import
|
92684 |
19-Mar-2002 |
darrenr |
This file is being removed pending the all clear on its licence by someone else.
|
92681 |
19-Mar-2002 |
darrenr |
This commit was generated by cvs2svn to compensate for changes in r92680, which included commits to RCS files with non-trunk default branches.
|
92561 |
18-Mar-2002 |
dfr |
Remove a couple of stray linuxisms to make this work for FreeBSD/ia64.
|
92394 |
16-Mar-2002 |
msmith |
Merge local changes for the 20020308 ACPI CA update.
|
92389 |
16-Mar-2002 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r92388, which included commits to RCS files with non-trunk default branches.
|
92387 |
16-Mar-2002 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r92386, which included commits to RCS files with non-trunk default branches.
|
91478 |
28-Feb-2002 |
mike |
Change two occurrences of HTONS() to use htons().
|
91441 |
27-Feb-2002 |
peter |
Fix warning (unused variable)
Submitted by: LINT, -Werror
|
91192 |
24-Feb-2002 |
msmith |
Move some debugger-only symbols around; this patch didn't make it into the commit resolution for some reason. Fixes ACPI_DEBUG.
|
91119 |
23-Feb-2002 |
msmith |
Resolve conflicts arising from the ACPI CA 20020217 import.
|
91117 |
23-Feb-2002 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r91116, which included commits to RCS files with non-trunk default branches.
|
90380 |
08-Feb-2002 |
msmith |
Add a helper script used to take an Intel-supplied ACPI CA drop and make it ready for importing. This should save me from my own over-cleanliness.
|
89336 |
14-Jan-2002 |
alfred |
Backout inclusion of queue.h since rev 1.38 sys/file.h now has it included in the right order.
|
89316 |
13-Jan-2002 |
alfred |
Include sys/_lock.h and sys/_mutex.h to reduce namespace pollution.
Requested by: jhb
|
88876 |
04-Jan-2002 |
darrenr |
Import this patch to address user concerns.
PR: 27615 Submitted by: Andria Thomas <andria@tovaris.com> Approved by: Me. MFC after: 7 days
|
88420 |
22-Dec-2001 |
iwasaki |
Add OS layer ACPI mutex and threading support. - Temporary fix a bug of Intel ACPI CA core code. - Add OS layer ACPI mutex support. This can be disabled by specifying option ACPI_NO_SEMAPHORES. - Add ACPI threading support. Now that we have a dedicate taskqueue for ACPI tasks and more ACPI task threads can be created by specifying option ACPI_MAX_THREADS. - Change acpi_EvaluateIntoBuffer() behavior slightly to reuse given caller's buffer unless AE_BUFFER_OVERFLOW occurs. Also CM battery's evaluations were changed to use acpi_EvaluateIntoBuffer(). - Add new utility function acpi_ConvertBufferToInteger(). - Add simple locking for CM battery and temperature updating. - Fix a minor problem on EC locking. - Make the thermal zone polling rate to be changeable. - Change minor things on AcpiOsSignal(); in ACPI_SIGNAL_FATAL case, entering Debugger is easier to investigate the problem rather than panic.
|
87394 |
05-Dec-2001 |
guido |
Fix initialisation of struct nat entry, to solve a panic that occurs when reloading a nat table after reboot
Submitted by: Arjan de Vet <devet@devet.org> Reviewed by: IP Filter mailing list MFC after: 3 days
|
87035 |
28-Nov-2001 |
msmith |
Merge local changes.
Add a fix for a minor error in the PCI routing table creation handler where the correct size for the buffer is not returned.
|
87032 |
28-Nov-2001 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r87031, which included commits to RCS files with non-trunk default branches.
|
86632 |
19-Nov-2001 |
green |
Reference lomac in its new location.
|
86611 |
19-Nov-2001 |
green |
Use appropriaate include path for syscall_gate.h
|
86570 |
19-Nov-2001 |
green |
Fix a license and change $Id$s to $FreeBSD$s.
Obtained from: DARPA, NAI Labs (CBOSS project)
|
86568 |
19-Nov-2001 |
green |
This commit was generated by cvs2svn to compensate for changes in r86567, which included commits to RCS files with non-trunk default branches.
|
86261 |
11-Nov-2001 |
iwasaki |
Apply a local change to ACPICA. Some BIOSes don't set WAK_STS at all, give up waiting for wakeup if we time out.
|
86133 |
06-Nov-2001 |
iwasaki |
Add S4BIOS sleep (BIOS hibernation) and DSDT overriding support. - Add S4BIOS sleep implementation. This will works well if MIB hw.acpi.s4bios is set (and of course BIOS supports it and hibernation is enabled correctly). - Add DSDT overriding support which is submitted by takawata originally. If loader tunable acpi_dsdt_load="YES" and DSDT file is set to acpi_dsdt_name (default DSDT file name is /boot/acpi_dsdt.aml), ACPI CA core loads DSDT from given file rather than BIOS memory block. DSDT file can be generated by iasl in ports/devel/acpicatools/. - Add new files so that we can add our proposed additional code to Intel ACPI CA into these files temporary. They will be removed when similar code is added into ACPI CA officially.
|
85759 |
31-Oct-2001 |
msmith |
Merge local changes, add new files and remove obsoleted ones.
|
85757 |
31-Oct-2001 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r85756, which included commits to RCS files with non-trunk default branches.
|
85755 |
31-Oct-2001 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r85754, which included commits to RCS files with non-trunk default branches.
|
84497 |
04-Oct-2001 |
msmith |
Remove file obsoleted by the 20010920 snapshot.
|
84496 |
04-Oct-2001 |
msmith |
Merge our local patches into the 20010920 snapshot. Note that the "implicit return" hack in psparse.c was resubmitted by Iwasaki-san.
Submitted by: iwasaki
|
84494 |
04-Oct-2001 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r84493, which included commits to RCS files with non-trunk default branches.
|
84492 |
04-Oct-2001 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r84491, which included commits to RCS files with non-trunk default branches.
|
83380 |
12-Sep-2001 |
darrenr |
IPFilter munges multicast address packets on the loopback interface.
Submitted by: Frank Zolf Approved by: jkh MFC after: 0
|
83377 |
12-Sep-2001 |
darrenr |
Add IPFLITER.LICENCE to the kernel (requested by rwatson)
|
83366 |
12-Sep-2001 |
julian |
KSE Milestone 2 Note ALL MODULES MUST BE RECOMPILED make the kernel aware that there are smaller units of scheduling than the process. (but only allow one thread per process at this time). This is functionally equivalent to teh previousl -current except that there is a thread associated with each process.
Sorry john! (your next MFC will be a doosie!)
Reviewed by: peter@freebsd.org, dillon@freebsd.org
X-MFC after: ha ha ha ha
|
83178 |
07-Sep-2001 |
msmith |
Merge our local branch changes with the 20010831 snapshot.
|
83175 |
07-Sep-2001 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r83174, which included commits to RCS files with non-trunk default branches.
|
82371 |
26-Aug-2001 |
msmith |
Nuke the Windows platform defines; we don't need them.
|
82370 |
26-Aug-2001 |
msmith |
Merge local changes.
|
82368 |
26-Aug-2001 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r82367, which included commits to RCS files with non-trunk default branches.
|
80625 |
30-Jul-2001 |
darrenr |
fix import/merge related code problems
|
80482 |
28-Jul-2001 |
darrenr |
fix conflicts created by import
|
80358 |
25-Jul-2001 |
peter |
This commit was generated by cvs2svn to compensate for changes in r80357, which included commits to RCS files with non-trunk default branches.
|
80065 |
21-Jul-2001 |
msmith |
Merge local changes with the ACPI CA 20010717 import.
|
80063 |
21-Jul-2001 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r80062, which included commits to RCS files with non-trunk default branches.
|
80061 |
21-Jul-2001 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r80060, which included commits to RCS files with non-trunk default branches.
|
80031 |
20-Jul-2001 |
msmith |
We haven't had AcpiSetSystemSleepState for a while now, clean out the prototype.
|
78989 |
29-Jun-2001 |
msmith |
Merge FreeBSD-specific changes.
|
78987 |
29-Jun-2001 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r78986, which included commits to RCS files with non-trunk default branches.
|
78217 |
14-Jun-2001 |
joerg |
Do only call oltr_stop() if we are not already in OL_STOPPED state. This avoids a null pointer deref panic in TRlldClose() inside the vendor-supplied object code. It's now possible to unload the driver at all.
Implement deallocation of malloc()ed memory regions.
MFC after: 2 months
|
77433 |
29-May-2001 |
msmith |
Remove old ACPI CA code. These will be drained from the repo at some future date.
|
77429 |
29-May-2001 |
msmith |
- wbinvd isn't an inline on ia64. - includes are not in subdirectories.
|
77428 |
29-May-2001 |
msmith |
Merge FreeBSD-specific changes with the ACPI CA 20010518 release.
|
77425 |
29-May-2001 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r77424, which included commits to RCS files with non-trunk default branches.
|
77423 |
29-May-2001 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r77422, which included commits to RCS files with non-trunk default branches.
|
76322 |
06-May-2001 |
phk |
Actually biofinish(struct bio *, struct devstat *, int error) is more general than the bioerror().
Most of this patch is generated by scripts.
|
76311 |
06-May-2001 |
phk |
Update the DiskOnChip firmware to OSAK version 4.1.
Sponsored by: Redfern Broadband Networks (www.RedFernNetworks.com)
|
75262 |
06-Apr-2001 |
darrenr |
fix security hole created by fragment cache
|
74810 |
26-Mar-2001 |
phk |
Send the remains (such as I have located) of "block major numbers" to the bit-bucket.
|
73972 |
08-Mar-2001 |
mdodd |
Move configuration of work_memory to oltr_init() rather than oltr_pci_attach(). This only affects the OC-3139 and OC-3540.
MFC candidate.
PR: kern/24074
|
73564 |
05-Mar-2001 |
msmith |
Resolve merge conflicts.
|
73562 |
05-Mar-2001 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r73561, which included commits to RCS files with non-trunk default branches.
|
72010 |
04-Feb-2001 |
darrenr |
fix duplicate rcsid
|
72006 |
04-Feb-2001 |
darrenr |
fix conflicts
|
71923 |
02-Feb-2001 |
msmith |
Patch the reintroduced (~0 << 32) == 1 bug with a cryptic but functional version. This should fix the read-before-write problem again.
Obtained from: "Adam J. Richter" <adam@yggdrasil.com>
|
71877 |
31-Jan-2001 |
msmith |
Merge conflicts from the ACPI CA 20010125 import.
|
71870 |
31-Jan-2001 |
msmith |
Remove obsoleted files.
|
71868 |
31-Jan-2001 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r71867, which included commits to RCS files with non-trunk default branches.
|
70902 |
10-Jan-2001 |
iwasaki |
Disable strstr() if ACPICA is compiled in userland.
Reviewed by: msmith
|
70246 |
21-Dec-2000 |
msmith |
Resolve conflicts from the ACPI CA 20001215 vendor import.
|
70244 |
21-Dec-2000 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r70243, which included commits to RCS files with non-trunk default branches.
|
69781 |
08-Dec-2000 |
dwmalone |
Convert more malloc+bzero to malloc+M_ZERO.
Submitted by: josh@zipperup.org Submitted by: Robert Drehmel <robd@gmx.net>
|
69774 |
08-Dec-2000 |
phk |
Staticize some malloc M_ instances.
|
69749 |
08-Dec-2000 |
msmith |
Resolve conflicts from the 20001201 merge.
|
69747 |
08-Dec-2000 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r69746, which included commits to RCS files with non-trunk default branches.
|
69473 |
01-Dec-2000 |
msmith |
Remove duplicate definition.
|
69472 |
01-Dec-2000 |
msmith |
Update local changes for new hardware register interface.
|
69454 |
01-Dec-2000 |
msmith |
Resolve conflicts from the vendor update.
|
69451 |
01-Dec-2000 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r69450, which included commits to RCS files with non-trunk default branches.
|
69152 |
25-Nov-2000 |
jlemon |
Lock down the network interface queues. The queue mutex must be obtained before adding/removing packets from the queue. Also, the if_obytes and if_omcasts fields should only be manipulated under protection of the mutex.
IF_ENQUEUE, IF_PREPEND, and IF_DEQUEUE perform all necessary locking on the queue. An IF_LOCK macro is provided, as well as the old (mutex-less) versions of the macros in the form _IF_ENQUEUE, _IF_QFULL, for code which needs them, but their use is discouraged.
Two new macros are introduced: IF_DRAIN() to drain a queue, and IF_HANDOFF, which takes care of locking/enqueue, and also statistics updating/start if necessary.
|
68619 |
11-Nov-2000 |
bmilekic |
While I'm here, get rid of (now useless) MCLISREFERENCED and use MEXT_IS_REF instead. Also, fix a small set of "avail." If we're setting `avail,' we shouldn't be re-checking whether m_flags is M_EXT, because we know that it is, as if it wasn't, we would have already returned several lines above.
Reviewed by: jlemon
|
67853 |
29-Oct-2000 |
darrenr |
Fix conflicts creted by import.
|
67770 |
28-Oct-2000 |
msmith |
We should include <machine/stdarg.h> not <stdarg.h>
Submitted by: phk
|
67767 |
28-Oct-2000 |
msmith |
Some AML code assumes that a function without an explicit ReturnOp will return the last value returned by a nested method call. This violates the ACPI spec, but is implemented by the Microsoft interpreter, and thus vendors can (and do) get away with it.
Intel's stance is that this is illegal and should not be supported. As they put it, however, we have to live in the real world. So go ahead and implement it.
Submitted by: Mitsaru IWASAKI <iwasaki@jp.freebsd.org>
|
67766 |
28-Oct-2000 |
msmith |
FreeBSD-specific customisations:
- Set debugger options for kernel build - Define some missing functions - Bring in GCC defines - Disable the 'wbinvd' macro as it conflicts with our inline
|
67765 |
28-Oct-2000 |
msmith |
Add some extra fuctions:
- AcpiGetProcessorID (fetch the ACPI processor ID for a given ACPI_HANDLE) - AcpiSetSystemSleepState (set the Sx sleeping state, proposed by Intel but not actually implemented)
|
67755 |
28-Oct-2000 |
msmith |
This commit was generated by cvs2svn to compensate for changes in r67754, which included commits to RCS files with non-trunk default branches.
|
67711 |
27-Oct-2000 |
obrien |
Include sys/param.h for `__FreeBSD_version' rather than the non-existent osreldate.h.
Submitted by: dougb
|
67614 |
26-Oct-2000 |
darrenr |
fix conflicts from rcsids
|
67564 |
25-Oct-2000 |
ru |
We now keep the ip_id field in network byte order all the time, so there is no need to make the distinction between ip_output() and ip_input() cases.
Reviewed by: silence on freebsd-net
|
67287 |
18-Oct-2000 |
ru |
If we do not byte-swap the ip_id in the first place, don't do it in the second. NetBSD (from where I've taken this originally) needs to fix this too.
|
67164 |
15-Oct-2000 |
phk |
Remove unneeded #include <machine/clock.h>
|
66903 |
10-Oct-2000 |
lile |
o Change TX_BUFFER_LEN from 512 to 2048.
o Remove bogus "spurious interrupt" message.
o Ring buffer head and avail were incorrectly calculated.
o Fix fragment count.
o Fix ring entry for single station, default to 16Mbit.
o Don't complain about long frames.
|
66795 |
07-Oct-2000 |
phk |
remove unused #include.
|
65933 |
16-Sep-2000 |
phk |
Remove SMP hack.
|
65837 |
14-Sep-2000 |
ru |
Follow BSD/OS and NetBSD, keep the ip_id field in network order all the time.
Requested by: wollman
|
64674 |
15-Aug-2000 |
kris |
Install mode 644, not mode 664 during kernel compile. Yes, Peter, I am psycho :-)
|
64580 |
13-Aug-2000 |
darrenr |
resolve conflicts
|
64105 |
01-Aug-2000 |
roberto |
Change __FreeBSD_Version into the proper __FreeBSD_version.
Submitted by: Alain.Thivillon@hsc.fr (Alain Thivillon) (for ip_fil.c)
|
64078 |
01-Aug-2000 |
ache |
Add missing '0' to FreeBSD_version test: 50011 -> 500011
|
64060 |
31-Jul-2000 |
darrenr |
activate pfil_hooks and covert ipfilter to use it
|
63523 |
19-Jul-2000 |
darrenr |
fix conflicts
|
61977 |
23-Jun-2000 |
peter |
Remove these here, these were repocopied to src/sys/ufs/ffs.
|
61926 |
22-Jun-2000 |
mckusick |
Update to new copyright.
|
61813 |
18-Jun-2000 |
mckusick |
When running with quotas enabled on a filesystem using soft updates, the system would panic when a user's inode quota was exceeded (see PR 18959 for details). This fixes that problem.
PR: 18959 Submitted by: Jason Godsey <jason@unixguy.fidalgo.net>
|
61812 |
18-Jun-2000 |
mckusick |
Some additional performance improvements. When freeing an inode check to see if it has been committed to disk. If it has never been written, it can be freed immediately. For short lived files this change allows the same inode to be reused repeatedly. Similarly, when upgrading a fragment to a larger size, if it has never been claimed by an inode on disk, it too can be freed immediately making it available for reuse often in the next slowly growing block of the same file.
|
61729 |
16-Jun-2000 |
phk |
ARGH! I have too many source trees :-(
Fix prototype errors in last commit.
|
61724 |
16-Jun-2000 |
phk |
Virtualizes & untangles the bioops operations vector.
Ref: Message-ID: <18317.961014572@critter.freebsd.dk> To: current@
|
61483 |
10-Jun-2000 |
peter |
Unused include: #include "fla.h"
|
61044 |
28-May-2000 |
peter |
Fix a reference to an old FreeBSD 2.2 register name. s/PCI_COMMAND_STATUS_REG/PCIR_COMMAND/
|
60944 |
26-May-2000 |
darrenr |
define CSUM_DELAY_DATA to match merge
|
60938 |
26-May-2000 |
jake |
Back out the previous change to the queue(3) interface. It was not discussed and should probably not happen.
Requested by: msmith and others
|
60925 |
25-May-2000 |
darrenr |
fix up #ifdef jungle for FreeBSD
|
60923 |
25-May-2000 |
darrenr |
remove duplicate prototypes
|
60883 |
24-May-2000 |
darrenr |
fix duplicate rcsid's
|
60865 |
24-May-2000 |
peter |
It would have been nice if this actually compiled. Close the header comment */.
|
60857 |
24-May-2000 |
darrenr |
fix up conflicts
|
60855 |
24-May-2000 |
darrenr |
fix conflicts
|
60854 |
24-May-2000 |
darrenr |
fix conflicts
|
60853 |
24-May-2000 |
darrenr |
fix conflicts
|
60852 |
24-May-2000 |
darrenr |
fix conflicts
|
60851 |
24-May-2000 |
darrenr |
fix conflicts
|
60850 |
24-May-2000 |
darrenr |
fix conflicts
|
60833 |
23-May-2000 |
jake |
Change the way that the queue(3) structures are declared; don't assume that the type argument to *_HEAD and *_ENTRY is a struct.
Suggested by: phk Reviewed by: phk Approved by: mdodd
|
60765 |
21-May-2000 |
jlemon |
Compute the checksum before handing the packet off to IPFilter.
Tested by: Cy Schubert <Cy.Schubert@uumail.gov.bc.ca>
|
60295 |
09-May-2000 |
darrenr |
Fix bug in dealing with "hlen == 1 and opt > 1"
|
60265 |
09-May-2000 |
ps |
Add missing include machine/in_cksum.h.
Submitted by: n_hibma
|
60041 |
05-May-2000 |
phk |
Separate the struct bio related stuff out of <sys/buf.h> into <sys/bio.h>.
<sys/bio.h> is now a prerequisite for <sys/buf.h> but it shall not be made a nested include according to bdes teachings on the subject of nested includes.
Diskdrivers and similar stuff below specfs::strategy() should no longer need to include <sys/buf.> unless they need caching of data.
Still a few bogus uses of struct buf to track down.
Repocopy by: peter
|
59874 |
01-May-2000 |
peter |
Add $FreeBSD$
|
59532 |
23-Apr-2000 |
phk |
Enforce and respect the 8 unit limit.
|
59249 |
15-Apr-2000 |
phk |
Complete the bio/buf divorce for all code below devfs::strategy
Exceptions: Vinum untouched. This means that it cannot be compiled. Greg Lehey is on the case.
CCD not converted yet, casts to struct buf (still safe)
atapi-cd casts to struct buf to examine B_PHYS
|
59241 |
15-Apr-2000 |
rwatson |
Introduce extended attribute support for FFS, allowing arbitrary (name, value) pairs to be associated with inodes. This support is used for ACLs, MAC labels, and Capabilities in the TrustedBSD security extensions, which are currently under development.
In this implementation, attributes are backed to data vnodes in the style of the quota support in FFS. Support for FFS extended attributes may be enabled using the FFS_EXTATTR kernel option (disabled by default). Userland utilities and man pages will be committed in the next batch. VFS interfaces and man pages have been in the repo since 4.0-RELEASE and are unchanged.
o ufs/ufs/extattr.h: UFS-specific extattr defines o ufs/ufs/ufs_extattr.c: bulk of support routines o ufs/{ufs,ffs,mfs}/*.[ch]: hooks and extattr.h includes o contrib/softupdates/ffs_softdep.c: extattr.h includes o conf/options, conf/files, i386/conf/LINT: added FFS_EXTATTR
o coda/coda_vfsops.c: XXX required extattr.h due to ufsmount.h (This should not be the case, and will be fixed in a future commit)
Currently attributes are not supported in MFS. This will be fixed.
Reviewed by: adrian, bp, freebsd-fs, other unthanked souls Obtained from: TrustedBSD Project
|
58934 |
02-Apr-2000 |
phk |
Move B_ERROR flag to b_ioflags and call it BIO_ERROR.
(Much of this done by script)
Move B_ORDERED flag to b_ioflags and call it BIO_ORDERED.
Move b_pblkno and b_iodone_chain to struct bio while we transition, they will be obsoleted once bio structs chain/stack.
Add bio_queue field for struct bio aware disksort.
Address a lot of stylistic issues brought up by bde.
|
58641 |
26-Mar-2000 |
lile |
o Get basic if_media support working.
o Add more diagnostic and status messages.
o General clean up of old debug messages and small style fixes.
|
58349 |
20-Mar-2000 |
phk |
Rename the existing BUF_STRATEGY() to DEV_STRATEGY()
substitute BUF_WRITE(foo) for VOP_BWRITE(foo->b_vp, foo)
substitute BUF_STRATEGY(foo) for VOP_STRATEGY(foo->b_vp, foo)
This patch is machine generated except for the ccd.c and buf.h parts.
|
58345 |
20-Mar-2000 |
phk |
Remove B_READ, B_WRITE and B_FREEBUF and replace them with a new field in struct buf: b_iocmd. The b_iocmd is enforced to have exactly one bit set.
B_WRITE was bogusly defined as zero giving rise to obvious coding mistakes.
Also eliminate the redundant struct buf flag B_CALL, it can just as efficiently be done by comparing b_iodone to NULL.
Should you get a panic or drop into the debugger, complaining about "b_iocmd", don't continue. It is likely to write on your disk where it should have been reading.
This change is a step in the direction towards a stackable BIO capability.
A lot of this patch were machine generated (Thanks to style(9) compliance!)
Vinum users: Greg has not had time to test this yet, be careful.
|
58297 |
19-Mar-2000 |
lile |
o Fix typo in the RapidFire 3540 adapter name 4/16/100 -> 100/16/4 so that it matches all of the others.
o Since we went to all the trouble of getting the correct working memory size actually use it.
* Submitted by: Nikolai Saoukh <nms@otdel-1.org>
|
58267 |
18-Mar-2000 |
lile |
o Replace the old "oltr" driver with the completely re-written new-bus Olicom driver, previously known as "ol". The new driver unfortunately does not support ISA cards yet.
o Update the microcode files, interface library and include files to the latest PowerMACH works version. Force even byte alignment of adapter microcode.
o Roll in some of the patches from Nikolai Saoukh <nms@ethereal.ru>.
|
57126 |
10-Feb-2000 |
guido |
Re add rev 1.11 diffs to ip_fil.h Also discover that I did not undefine CVS_FUBAR (which no longer exists) and thus forgot to add $FreeBSD's. Add them.
Approved by: jkh (is part of ipfilter upgrade)
|
57096 |
09-Feb-2000 |
guido |
Bring over ipfilter v3_3_8 kernel sources, including merging the local modifications. Also fix initializing fr_running in KLD case. Rename ipl_inited to fr_runninhg in mlfk_ipl
Approved by: jkh
|
56908 |
30-Jan-2000 |
mckusick |
When writing out bitmap buffers, need to skip over ones that already have a write in progress. Otherwise one can get in an infinite loop trying to get them all flushed.
Submitted by: Matthew Dillon <dillon@apollo.backplane.com>
|
56873 |
29-Jan-2000 |
peter |
Remove a somewhat odd #if that is always true (NOLTR will be always 1 or more if this file is being compiled)
|
56209 |
18-Jan-2000 |
mckusick |
During fastpath processing for removal of a short-lived inode, the set of restrictions for cancelling an inode dependency (inodedep) is somewhat stronger than originally coded. Since this check appears in two places, we codify it into the function check_inode_unwritten which we then call from the two sites, one freeing blocks and the other freeing directory entries.
Submitted by: Steinar Haug via Matthew Dillon
|
56208 |
18-Jan-2000 |
mckusick |
Need to reorganize the flushing of directory entry (pagedep) dependencies so that they never try to lock an inode corresponding to ".." as this can lead to deadlock. We observe that any inode with an updated link count is always pushed into its buffer at the time of the link count change, so we do not need to do a VOP_UPDATE, but merely find its buffer and write it. The only time we need to get the inode itself is from the result of a mkdir whose name will never be ".." and hence locking such an inode will never request a lock above us in the filesystem tree. Thanks to Brian Fundakowski Feldman for providing the test program that tickled soft updates into hanging in "inode" sleep.
Submitted by: Brian Fundakowski Feldman <green@FreeBSD.org>
|
56150 |
17-Jan-2000 |
mckusick |
Better bounding on softdep_flushfiles; other minor tweeks to checks.
|
56149 |
17-Jan-2000 |
mckusick |
Must track multiple uncommitted renames until one ultimately gets committed to disk or is removed.
|
55990 |
14-Jan-2000 |
guido |
Apply patches in rev 1.2 and 1.9 that I forgot
Pointe out by: bde
|
55947 |
14-Jan-2000 |
dillon |
Non-operational change, fix compiler warning.
Reviewed by: mckusick
|
55931 |
13-Jan-2000 |
mckusick |
Confirming Peter's fix (locking 101: release the lock before you go to sleep). Locking 101, part 2: do not look at buffer contents after you have been asleep. There is no telling what wonderous changes may have occurred.
|
55929 |
13-Jan-2000 |
guido |
Bring over ipfilter kernel sources, including merging the local modifications.
|
55928 |
13-Jan-2000 |
peter |
Free the global softupdates lock prior to tsleep() in getdirtybuf(). This seems to be responsible for a bunch of panics where the process sleeps and something else finds softupdates "locked" when it shouldn't be. This commit is unreviewed, but has been a big help here. Previously my boxes would panic pretty much on the first fsync() that wrote something to disk.
|
55886 |
13-Jan-2000 |
mckusick |
Because cylinder group blocks are now written in background, it is no longer sufficient to get a lock on a buffer to know that its write has been completed. We have to first get the lock on the buffer, then check to see if it is doing a background write. If it is doing background write, we have to wait for the background write to finish, then check to see if that fullfilled our dependency, and if not to start another write. Luckily the explanation is longer than the fix.
|
55885 |
13-Jan-2000 |
mckusick |
A panic occurs during an fsync when a dirty block associated with a vnode has not been written (which would clear certain of its dependencies). The problems arises because fsync with MNT_NOWAIT no longer pushes all the dirty blocks associated with a vnode. It skips those that require rollbacks, since they will just get instantly dirty again. Such skipped blocks are marked so that they will not be skipped a second time (otherwise circular dependencies would never clear). So, we fsync twice to ensure that everything will be written at least once.
|
55794 |
11-Jan-2000 |
mckusick |
We cannot proceed to free the blocks of the file until the dependencies have been cleaned up by deallocte_dependencies(). Once that is done, it is safe to post the request to free the blocks. A similar change is also needed for the freefile case.
|
55756 |
10-Jan-2000 |
phk |
Give vn_isdisk() a second argument where it can return a suitable errno.
Suggested by: bde
|
55726 |
10-Jan-2000 |
mckusick |
Missing FREE_LOCK call before handle_workitem_freeblocks.
Submitted by: "Kenneth D. Merry" <ken@kdm.org>
|
55697 |
10-Jan-2000 |
mckusick |
Several performance improvements for soft updates have been added: 1) Fastpath deletions. When a file is being deleted, check to see if it was so recently created that its inode has not yet been written to disk. If so, the delete can proceed to immediately free the inode. 2) Background writes: No file or block allocations can be done while the bitmap is being written to disk. To avoid these stalls, the bitmap is copied to another buffer which is written thus leaving the original available for futher allocations. 3) Link count tracking. Constantly track the difference in i_effnlink and i_nlink so that inodes that have had no change other than i_effnlink need not be written. 4) Identify buffers with rollback dependencies so that the buffer flushing daemon can choose to skip over them.
|
55694 |
09-Jan-2000 |
mckusick |
Keep tighter control of removal dependencies by limiting the number of dirrem structure rather than the collaterally created freeblks and freefile structures. Limit the rate of buffer dirtying by the syncer process during periods of intense file removal.
|
55692 |
09-Jan-2000 |
mckusick |
Reorganize softdep_fsync so that it only does the inode-is-flushed check before the inode is unlocked while grabbing its parent directory. Once it is unlocked, other operations may slip in that could make the inode-is-flushed check fail. Allowing other writes to the inode before returning from fsync does not break the semantics of fsync since we have flushed everything that was dirty at the time of the fsync call.
|
55690 |
09-Jan-2000 |
mckusick |
Make static non-exported functions from soft updates.
|
55460 |
05-Jan-2000 |
eivind |
KERNEL -> _KERNEL
|
54935 |
21-Dec-1999 |
eivind |
Garbage collect oltr_pci_shutdown
|
54892 |
20-Dec-1999 |
peter |
The ipfilter module name wasn't exactly conventional..
|
54700 |
16-Dec-1999 |
mckusick |
The function request_cleanup() had a tsleep() with PCATCH. It is quite dangerous, since the process may hold locks at the point, and if it is stopped in that tsleep the machine may hang. Because the sleep is so short, the PCATCH is not required here, so it has been removed. For the future, the FreeBSD team needs to decide whether it is still reasonable to stop a process in tsleep, as that may affect any other code that uses PCATCH while holding kernel locks.
Submitted by: Dmitrij Tejblum <tejblum@arc.hq.cti.ru> Reviewed by: Kirk McKusick <mckusick@mckusick.com>
|
54444 |
11-Dec-1999 |
eivind |
Lock reporting and assertion changes. * lockstatus() and VOP_ISLOCKED() gets a new process argument and a new return value: LK_EXCLOTHER, when the lock is held exclusively by another process. * The ASSERT_VOP_(UN)LOCKED family is extended to use what this gives them * Extend the vnode_if.src format to allow more exact specification than locked/unlocked.
This commit should not do any semantic changes unless you are using DEBUG_VFS_LOCKS.
Discussed with: grog, mch, peter, phk Reviewed by: peter
|
54279 |
08-Dec-1999 |
ken |
Revamp the devstat priority system. All disks now have the same priority. The same goes for CD drivers and tape drivers. In systems with mixed IDE and SCSI, devices in the same priority class will be sorted in attach order.
Also, the 'CCD' priority is now the 'ARRAY' priority, and a number of drivers have been modified to use that priority.
This includes the necessary changes to all drivers, except the ATA drivers. Soren will modify those separately.
This does not include and does not require any change in the devstat version number, since no known userland applications use the priority enumerations.
Reviewed by: msmith, sos, phk, jlemon, mjacob, bde
|
54228 |
06-Dec-1999 |
guido |
Last minute patch that I forgot to apply: check return code of iplattach()
|
54221 |
06-Dec-1999 |
guido |
Revive mlfk_ipl here. This version is slightly changed from the old one: an unnecessary define (KLD_MODULE) has been deleted and the initialisation of the module is done after domaininit was called to be sure inet is running.
Some slight changed were made to ip_auth.c and ip_state.c in order to assure including of sys/systm.h in case we make a kld
Make sure ip_fil does nmot include osreldate in kernel mode
Remove mlfk_ipl.c from here: no sources allowed in these directories!
|
54048 |
03-Dec-1999 |
billf |
Fix typo, add $FreeBSD$
|
53885 |
29-Nov-1999 |
peter |
Fix a stray (ifdef'ed) reference to a non-existing file.
|
53645 |
23-Nov-1999 |
guido |
Get rid of useless osreldate include for KLD/LKM modules (sys/param.h already carries what is needed). This is needed for the KLD support.
|
53642 |
23-Nov-1999 |
guido |
Add kernel parts of revived ipfilter (3.3.3.)
|
53577 |
22-Nov-1999 |
phk |
Convert various pieces of code to use vn_isdisk() rather than checking for vp->v_type == VBLK.
In ccd: we don't need to call VOP_GETATTR to find the type of a vnode.
Reviewed by: sos
|
53452 |
20-Nov-1999 |
phk |
struct mountlist and struct mount.mnt_list have no business being a CIRCLEQ. Change them to TAILQ_HEAD and TAILQ_ENTRY respectively.
This removes ugly mp != (void*)&mountlist comparisons.
Requested by: phk Submitted by: Jake Burkholder jake@checker.org PR: 14967
|
53080 |
10-Nov-1999 |
phk |
Finding root devices is a much more sane thing now.
|
52174 |
12-Oct-1999 |
dfr |
* Add struct resource_list* argument to resource_list_alloc and resource_list_release. This removes the dependancy on the layout of ivars.
* Move set_resource, get_resource and delete_resource from isa_if.m to bus_if.m.
* Simplify driver code by providing wrappers to those methods:
bus_set_resource(dev, type, rid, start, count); bus_get_resource(dev, type, rid, startp, countp); bus_get_resource_start(dev, type, rid); bus_get_resource_count(dev, type, rid); bus_delete_resource(dev, type, rid);
* Delete isa_get_rsrc and use bus_get_resource_start instead.
* Fix a stupid typo in isa_alloc_resource reported by Takahashi Yoshihiro <nyan@FreeBSD.org>.
* Print a diagnostic message if we can't assign resources to a PnP device.
* Change device_print_prettyname() so that it doesn't print "(no driver assigned)-1" for anonymous devices.
|
52134 |
11-Oct-1999 |
phk |
remove unused #includes.
|
52089 |
10-Oct-1999 |
peter |
Nuke the old antique copy of ipfilter from the tree. This is old enough to be dangerous. It will better serve us as a port building a KLD, ala SKIP.
The hooks are staying although it would be better to port and use the NetBSD pfil interface rather than have custom hooks.
|
51658 |
25-Sep-1999 |
phk |
Remove five now unused fields from struct cdevsw. They should never have been there in the first place. A GENERIC kernel shrinks almost 1k.
Add a slightly different safetybelt under nostop for tty drivers.
Add some missing FreeBSD tags
|
51646 |
25-Sep-1999 |
phk |
Remove NBPF conditionality of bpf calls in most of our network drivers.
This means that we will not have to have a bpf and a non-bpf version of our driver modules.
This does not open any security hole, because the bpf core isn't loadable
The drivers left unchanged are the "cross platform" drivers where the respective maintainers are urged to DTRT, whatever that may be.
Add a couple of missing FreeBSD tags.
|
51376 |
18-Sep-1999 |
phk |
Use devstat_end_transaction_buf() rather than Use devstat_end_transaction()
|
51215 |
12-Sep-1999 |
phk |
Bite the bullet and allocate the devsw entry at compile time.
|
51198 |
12-Sep-1999 |
phk |
Use a different tactic when creating the devsw so that disk_create() doesn't need to malloc.
|
51087 |
08-Sep-1999 |
phk |
Update docs for 3.3-R
OK'ed by: jkh
|
50994 |
06-Sep-1999 |
peter |
Clean $Log$ debris.
|
50728 |
01-Sep-1999 |
phk |
Improve the micro "disk" layer after gaining more experience with it.
|
50570 |
29-Aug-1999 |
phk |
Remove unneeded slice element.
|
50566 |
29-Aug-1999 |
phk |
Convert to use the new "disk" layer. A few cleanups while here.
|
50511 |
28-Aug-1999 |
phk |
We don't need to pass the diskname argument all over the diskslice/label code, we can find the name from any convenient dev_t
|
50480 |
28-Aug-1999 |
peter |
$Id$ -> $FreeBSD$
|
50477 |
28-Aug-1999 |
peter |
$Id$ -> $FreeBSD$
|
49847 |
15-Aug-1999 |
phk |
SMP: Release the giant lock while we work the flash array Use splbio() rather than fiddling the hardware interrupts. Remove the compatibility stuff for older FreeBSD versions. Add devstat support.
|
49771 |
14-Aug-1999 |
phk |
Spring cleaning around strategy and disklabels/slices:
Introduce BUF_STRATEGY(struct buf *, int flag) macro, and use it throughout. please see comment in sys/conf.h about the flag argument.
Remove strategy argument from all the diskslice/label/bad144 implementations, it should be found from the dev_t.
Remove bogus and unused strategy1 routines.
Remove open/close arguments from dssize(). Pick them up from dev_t.
Remove unused and unfinished setgeom support from diskslice/label/bad144 code.
|
49535 |
08-Aug-1999 |
phk |
Decommision miscfs/specfs/specdev.h. Most of it goes into <sys/conf.h>, a few lines into <sys/vnode.h>.
Add a few fields to struct specinfo, paving the way for the fun part.
|
49500 |
07-Aug-1999 |
bde |
Fixed a bogus include pathname which broke compiling in an obj directory.
|
49499 |
07-Aug-1999 |
bde |
Fixed syntax errors. Code should be tested before committing it, or at least before enabling it in LINT and merging it into RELENG_3.
|
49470 |
06-Aug-1999 |
phk |
Better way to circumvent the boot problem on older versions.
Submitted by: Larry Baird <lab@gta.com>
|
49467 |
06-Aug-1999 |
phk |
Add driver support for M-systems DiskOnChip Products.
Sponsored by: M-systems Inc. http://www.m-sys.com
|
48645 |
06-Jul-1999 |
des |
Rename bpfilter to bpf.
|
48591 |
05-Jul-1999 |
lile |
Update to latest version of PowerMACH Works from Olicom.
|
48334 |
29-Jun-1999 |
mckusick |
No longer need to set B_ASYNC flag since BUF_KERNPROC now unconditionally sets the identity of the buffer.
|
48276 |
27-Jun-1999 |
peter |
Keep the inlines for <sys/buf.h> happy..
|
48225 |
26-Jun-1999 |
mckusick |
Convert buffer locking from using the B_BUSY and B_WANTED flags to using lockmgr locks. This commit should be functionally equivalent to the old semantics. That is, all buffer locking is done with LK_EXCLUSIVE requests. Changes to take advantage of LK_SHARED and LK_RECURSIVE will be done in future commits.
|
48015 |
19-Jun-1999 |
green |
Add RCS strings to kernel ipfilter files.
|
47964 |
16-Jun-1999 |
mckusick |
Add a vnode argument to VOP_BWRITE to get rid of the last vnode operator special case. Delete special case code from vnode_if.sh, vnode_if.src, umap_vnops.c, and null_vnops.c.
|
47940 |
15-Jun-1999 |
mckusick |
Get rid of the global variable rushjob and replace it with a function in kern/vfs_subr.c named speedup_syncer() which handles the speedup request. Change the various clients of rushjob to use the new function.
|
47381 |
22-May-1999 |
julian |
Cosmetic changes to make it compile without errors in gcc -Wall
|
47131 |
14-May-1999 |
mckusick |
Add a hook to ffs_fsync to allow soft updates to get first chance at doing a sync on the block device for the filesystem. That allows it to push the bitmap blocks before the inode blocks which greatly reduces the number of inode rollbacks that need to be done.
|
46827 |
09-May-1999 |
mckusick |
Put back changes that might be causing trouble on Alpha.
|
46813 |
09-May-1999 |
peter |
Simplify the COMPAT_PCI_DRIVER/DATA_SET hack. We can add: #define COMPAT_PCI_DRIVER(name,data) DATA_SET(pcidevice_set,data) .. to 2.2.x and 3.x if people think it's worth it. Driver writers can do this if it's not defined. (The reason for this is that I'm trying to progressively eliminate use of linker_sets where it hurts modularity and runtime load capability, and these DATA_SET's keep getting in the way.)
|
46618 |
07-May-1999 |
mckusick |
Whitespace cleanup.
|
46616 |
07-May-1999 |
mckusick |
Get rid of random debugging cruft; sync up with latest version.
|
46609 |
07-May-1999 |
mckusick |
Severe slowdowns have been reported when creating or removing many files at once on a filesystem running soft updates. The root of the problem is that soft updates limits the amount of memory that may be allocated to dependency structures so as to avoid hogging kernel memory. The original algorithm just waited for the disk I/O to catch up and reduce the number of dependencies. This new code takes a much more aggressive approach. Basically there are two resources that routinely hit the limit. Inode dependencies during periods with a high file creation rate and file and block removal dependencies during periods with a high file removal rate. I have attacked these problems from two fronts. When the inode dependency limits are reached, I pick a random inode dependency, UFS_UPDATE it together with all the other dirty inodes contained within its disk block and then write that disk block. This trick usually clears 5-50 inode dependencies in a single disk I/O. For block and file removal dependencies, I pick a random directory page that has at least one remove pending and VOP_FSYNC its directory. That releases all its removal dependencies to the work queue. To further hasten things along, I also immediately start the work queue process rather than waiting for its next one second scheduled run.
|
46026 |
24-Apr-1999 |
peter |
Use COMPAT_PCI_DRIVER() for registration if it exists. This shouldn't hurt the driver portability to 3.x too much for where drivers are shared.
|
45895 |
21-Apr-1999 |
peter |
As I understand it, these register_intr()'s shouldn't be here. The isa driver attaches the interupt itself.
|
44643 |
10-Mar-1999 |
julian |
Need to include /contrib/dev/oltr/... not dev/oltr/...
|
44627 |
10-Mar-1999 |
julian |
Submitted by: Larry Lile Move the Olicom token ring driver to the officially sanctionned location of /sys/contrib. Also fix some brokenness in the generic token ring support.
Be warned that if_dl.h has been changed and SOME programs might like recompilation.
|
44398 |
02-Mar-1999 |
mckusick |
Reorganize locking to avoid holding the lock during calls to bdwrite and brelse (which may sleep in some systems).
Obtained from: Matthew Dillon <dillon@apollo.backplane.com>
|
44383 |
02-Mar-1999 |
mckusick |
Ensure that softdep_sync_metadata can handle bmsafemap and mkdir entries if they ever arise (which should not happen as softdep_sync_metadata is currently used).
|
44102 |
17-Feb-1999 |
mckusick |
fix double LIST_REMOVE; other cosmetic changes to match version 9.32. Obtained from: Jeffrey Hsu <hsu@FreeBSD.ORG>
|
43305 |
27-Jan-1999 |
dillon |
Fix warnings in preparation for adding -Wall -Wcast-qual to the kernel compile
|
43044 |
22-Jan-1999 |
dg |
Gutted softdep_deallocate_dependencies and replaced it with a panic. It turns out to not be useful to unwind the dependencies and continue in the face of a fatal error. Also changed the log() to a printf() in softdep_error() so that it will be output in the case of a impending panic. Submitted by: Kirk McKusick <mckusick@mckusick.com>
|
42374 |
07-Jan-1999 |
bde |
Don't pass unused unused timestamp args to UFS_UPDATE() or waste time initializing them. This almost finishes centralizing (in-core) timestamp updates in ufs_itimes().
|
42354 |
06-Jan-1999 |
bde |
UFS_UPDATE() takes a boolean `waitfor' arg, so don't pass it the value MNT_WAIT when we mean boolean `true' or check for that value not being passed. There was no problem in practice because MNT_WAIT had the magic value of 1.
|
41659 |
10-Dec-1998 |
julian |
Remove some compiler warnings.
|
41591 |
07-Dec-1998 |
archie |
The "easy" fixes for compiling the kernel -Wunused: remove unreferenced static and local variables, goto labels, and functions declared but not defined.
|
41514 |
04-Dec-1998 |
archie |
Examine all occurrences of sprintf(), strcat(), and str[n]cpy() for possible buffer overflow problems. Replaced most sprintf()'s with snprintf(); for others cases, added terminating NUL bytes where appropriate, replaced constants like "16" with sizeof(), etc.
These changes include several bug fixes, but most changes are for maintainability's sake. Any instance where it wasn't "immediately obvious" that a buffer overflow could not occur was made safer.
Reviewed by: Bruce Evans <bde@zeta.org.au> Reviewed by: Matthew Dillon <dillon@apollo.backplane.com> Reviewed by: Mike Spengler <mks@networkcs.com>
|
41363 |
26-Nov-1998 |
eivind |
Staticize some more.
|
40791 |
31-Oct-1998 |
peter |
Change dirty block list handling to use TAILQ macros.
|
40692 |
28-Oct-1998 |
jkh |
Clarify a rather ambiguous debugging message.
|
39933 |
03-Oct-1998 |
nate |
Fix 'noatime' bug that was unrelated to use of noatime.
The problem is caused when a directory block is compacted. When this occurs, softdep_change_directoryentry_offset() is called to relocate each directory entry and adjust its matching diradd structure, if any, to match the new location of the entry. The bug is that while softdep_change_directoryentry_offset() correctly adjusts the offsets of the diradd structures on the pd_diraddhd[] lists (which are not yet ready to be committed to disk), it fails to adjust the offsets of the diradd structures on the pd_pendinghd list (which are ready to be committed to disk). This causes the dependency structures to be inconsistent with the buf contents. Now, if the compaction has moved a directory entry to the same offset as one of the diradd structures on the pd_pendinghd list *and* a syscall is done that tries to remove this directory entry before this directory block has been written to disk (which would empty pd_pendinghd), a sanity check in newdirrem() will call panic() when it notices that the inode number in the entry that it is to be removed doesn't match the inode number in the diradd structure with that offset of that entry.
Reviewed by: Kirk McKusick <mckusick@McKusick.COM> Submitted by: Don Lewis <Don.Lewis@tsc.tdk.com>
|
39623 |
24-Sep-1998 |
luoqi |
Eliminate a race in VOP_FSYNC() when softupdates is enabled. Submitted by: Kirk McKusick <mckusick@McKusick.COM> Two minor changes are also included, 1. Remove gratuitious checks for error return from vn_lock with LK_RETRY set, vn_lock should always succeed in these cases. 2. Back out change rev. 1.36->1.37, which unnecessarily makes async mount a little more unstable. It also keeps us in sync with other BSDs. Suggested by: Bruce Evans <bde@zeta.org.au>
|
38342 |
15-Aug-1998 |
bde |
Made some disgusting ifdefs even more disgusting to enable the support for `u_long cmd' ioctl args if __FreeBSD_version >= 300003. Some ioctls were broken on machines with 32-bit ints and 64-bit longs.
|
38291 |
12-Aug-1998 |
julian |
Handle the case of moving a directory onto the top of a sibling's child of the same name.
Submitted by: Kirk Mckusick with fixes from luoqi Chen Obtained from: Whistle test tree.
|
37077 |
20-Jun-1998 |
peter |
Merge ipfilter 3.2.3 -> 3.2.7 changes onto mainline.
|
37072 |
20-Jun-1998 |
peter |
This commit was generated by cvs2svn to compensate for changes in r37071, which included commits to RCS files with non-trunk default branches.
|
36936 |
12-Jun-1998 |
julian |
Note which version of Kirk's sources this corresponds to.
|
36935 |
12-Jun-1998 |
julian |
Fix the case when renaming to a file that you've just created and deleted, that had an inode that has not yet been written to disk, when the inode of the new file is also not yet written to disk, and your old directory entry is not yet on disk but you need to remove it and the new name exists in memory but has been deleted but the transaction to write the deleted name to disk exists and has not yet been cancelled by the request to delete the non existant name. I don't know how kirk could have missed such a glaring problem for so long. :-) Especially since the inconsitency survived on the disk for a whole 4 second on average before being fixed by other code. This was not a crashing bug but just led to filesystem inconsitencies if you crashed.
Submitted by: Kirk McKusick (mckusick@mckusick.com)
|
36900 |
11-Jun-1998 |
julian |
Add B_NOCACHE to several cases where BSD4.4 only required a B_INVAL. Change worked out by john and kirk in consort.
|
36871 |
10-Jun-1998 |
julian |
Fix for "live inode" panic. Submitted by: Kirk McKusick <mckusick@McKusick.COM> Reviewed by: yeah right...
|
36866 |
10-Jun-1998 |
julian |
Remove buggy debugging code.
|
36767 |
08-Jun-1998 |
bde |
Fixed pedantic semantics errors (bitfields not of type int, signed int or unsigned int (this doesn't change the struct layout, size or alignment in any of the files changed in this commit, at least for gcc on i386's. Using bitfields of type u_char may affect size and alignment but not packing)).
|
36752 |
08-Jun-1998 |
bde |
ip_fil.h has 9 separate declarations of iplioctl() in a disgusting ifdef tangle. The previous commit to ip_fil.h didn't change the one that actually applies to the current FreeBSD kernel, of course. Fixed.
Fixed style bugs in previous commit to ip_fil.h.
|
36735 |
07-Jun-1998 |
dfr |
This commit fixes various 64bit portability problems required for FreeBSD/alpha. The most significant item is to change the command argument to ioctl functions from int to u_long. This change brings us inline with various other BSD versions. Driver writers may like to use (__FreeBSD_version == 300003) to detect this change.
The prototype FreeBSD/alpha machdep will follow in a couple of days time.
|
36580 |
02-Jun-1998 |
julian |
Add a reference to the Ganger/Patt paper
|
36404 |
27-May-1998 |
julian |
A fix to a debug test from Kirk.
|
36234 |
19-May-1998 |
julian |
Bring up-to-date with Whistle's current version Includes some debugging code.
|
36232 |
19-May-1998 |
julian |
Merge with Kirk's version as of Feb 20
His version 9.23 == our version 1.5 of ffs_softdep.c His version 9.5 == our version 1.4 of softdep.c
|
36225 |
19-May-1998 |
julian |
Merge in Kirk's changes to stop softupdates from hogging all of memory.
|
36212 |
19-May-1998 |
julian |
Change to stop a silly panic. This should be understood better. Change a buffer swizzle trick to a bcopy. It would be nice if the efficient trick could be used in the future.
|
36210 |
19-May-1998 |
julian |
First published FreeBSD version of soft updates Feb 5.
|
36207 |
19-May-1998 |
julian |
This commit was generated by cvs2svn to compensate for changes in r36206, which included commits to RCS files with non-trunk default branches.
|
36202 |
19-May-1998 |
julian |
This commit was generated by cvs2svn to compensate for changes in r36201, which included commits to RCS files with non-trunk default branches.
|
35065 |
06-Apr-1998 |
phk |
Use read_random()
|
34915 |
27-Mar-1998 |
peter |
allow open on all minors
|
34756 |
21-Mar-1998 |
peter |
Make it compile.. missing "opt_ipfilter.h" and missing <sys/malloc.h>
|
34751 |
21-Mar-1998 |
peter |
Some patchups for when this code is compiled in userland (!).
|
34746 |
21-Mar-1998 |
peter |
Make this compile.. There are some unpleasing hacks in here. A major unifdef session is sorely tempting but would destroy any remaining chance of tracking the original sources.
|
34743 |
21-Mar-1998 |
peter |
This commit was generated by cvs2svn to compensate for changes in r34742, which included commits to RCS files with non-trunk default branches.
|
31188 |
16-Nov-1997 |
peter |
This commit was generated by cvs2svn to compensate for changes in r31187, which included commits to RCS files with non-trunk default branches.
|
26125 |
25-May-1997 |
darrenr |
This commit was generated by cvs2svn to compensate for changes in r26124, which included commits to RCS files with non-trunk default branches.
|
24587 |
03-Apr-1997 |
darrenr |
This commit was generated by cvs2svn to compensate for changes in r24586, which included commits to RCS files with non-trunk default branches.
|
23286 |
02-Mar-1997 |
peter |
This commit was generated by cvs2svn to compensate for changes in r23285, which included commits to RCS files with non-trunk default branches.
|
23283 |
02-Mar-1997 |
peter |
This commit was generated by cvs2svn to compensate for changes in r23282, which included commits to RCS files with non-trunk default branches.
|