>Make the exploring of all luns supported by an HBA more of a
>tunable (until we get REPORT LUNS in place).
>
>If we're probing luns, and each probe succeeds, we keep going past
>lun 7 if we're a SCSI3 or better device (until we fail to probe).
>
>If we're probing luns, and a probe fails, we only keep going if
>we're quirked *for* it (CAM_QUIRK_HILUNS), and if we're not quirked
>*against* it (CAM_QUIRK_NOHILUNS), or we're a SCSI3 or better device
>and the tunable (kern.cam.cam_srch_hi) is set non-zero.
Approved by: re (scottl)
Handle a race condition where NULLFS vnode can be cleaned while threads
can still be asleep waiting for lowervp lock.
Tested by: kkenn
Discussed with: ssouhlal, jeffr
(this is an early MFC for inclusion in the upcoming 6.0-BETA5)
Approved by: re (scottl)
Use vput() instead of vrele() in null_reclaim() since the lower vnode
is locked.
MFC 1.89 (by kan):
Handle a race condition where NULLFS vnode can be cleaned while threads
can still be asleep waiting for lowervp lock.
Tested by: kkenn
Discussed with: ssouhlal, jeffr
(rev. 1.89 is an early MFC for inclusion in the upcoming 6.0-BETA5)
Approved by: re (scottl)
Log:
Handle circular dependencies properly (via errx(3)) rather than dumping
core. This bug was made visible by a recent change to the audio/timidity++
port, which now has itself as a run dependency.
Approved by: re (scottl)
Stop leaking a lock. This used to cause a propagate_priority() page fault
when setting syncdev and syncpeer.
Reported by: Dominic Marks
Approved by: re (scottl)
- Determine where the runtime loader got mapped to when a dynamically
linked process was exec()'ed, and map samples in that address range
into the appropriate buckets in the runtime loader's profile.
- Fix a bug that caused generated gmon.out profiles to be out of
whack. Use saturating arithmetic when incrementing a bucket.
- Improve a few comments.
Approved by: re (scottl)
o New APIs to access CIS, attribute memory and pccard registers
o Lock ed driver
o Support more cards in ed, ep, sn, xe
o Use new APIs to get MAC address right more often.
Approved by: re (scottl)
Ignore mutex asserts when we're dumping as well. This allows me
to panic a system from DDB when INVARIANTS is compiled into the
kernel on a scsi system.
Approved by: re (scottl)
Remove a KASSERT in the sack path that fails because of a interaction
between sack and a bug in the "bad retransmit recovery" logic. This is
a workaround, the underlying bug will be fixed later.
Approved by: re (scottl)
For FreeBSD 4 binaries, when trying to read from a device that does
not exsist, do not have ioctl return an error, but instead set -1
in the data returned to the user. This allows the HP bios flash
utilities to work without requiring changes to their code.
Approved by: re (scottl)
Trim down now (believed to be) unused fifo_ioctl() and
fifo_kqfilter() VOP implementations, since they in theory are used
only on open file descriptors, in which case the ioctls are via
fifo_ioctl_f() and kqueue requests are via fifo_kqfilter_f().
Generate warnings if they are entered for now. These printf()
calls should become panic() calls.
Annotate and re-implement fifo_ioctl_f(): don't arbitrarily
forward ioctls to the socket layer, only forward the ones we
explicitly support for fifos. In the case of FIONREAD, don't
forward the request to the write socket on a read-write fifo, or
the read result is overwritten. Annotate a nasty case for the
undefined POSIX O_RDWR on fifos, in which failure of the second
ioctl will result in the socket pair being in an inconsistent
state.
Assert copyright as I find myself rewriting non-trivial parts of
fifofs.
Approved by: re (scottl)
Annotate two issues:
1) fifo_kqfilter() is not actually ever used, it likely should be GC'd.
2) fifo_kqfilter_f() doesn't implement EVFILT_VNODE, so detecting events
on the underlying vnode for a fifo no longer works (it did in 4.x).
Likely, fifo_kqfilter_f() should forward the request to the VFS using
fp->f_vnode, which would work once fifo_kqfilter() was detached from
the vnode operation vector (removing the fifo override).
Discussed with: phk
Approved by: re (scottl)
As a result of kqueue locking work, socket buffer locks will always
be held when entering a kqueue filter for fifos via a socket buffer
event: as such, assert the lock unconditionally rather than acquiring
it conditionally.
Approved by: re (scottl)
Introduce no-op nosup fifo kqueue filter and detach routine, which are
used when a read filter is requested on a write-only fifo descriptor, or
a write filter is requested on a read-only fifo descriptor. This
permits the filters to be registered, but never raises the event, which
causes kqueue behavior for fifos to more closely match similar semantics
for poll and select, which permit testing for the condition even though
the condition will never be raised, and is consistent with POSIX's notion
that a fifo has identical semantics to a one-way IPC channel created
using pipe() on most operating systems.
The fifo regression test suite can now run to completion on HEAD without
errors.
Approved by: re (kensmith)
In netkqfilter(), return EINVAL instead of 1 (EPERM) when a filter type
is requested on a network interface file descriptor that is
non-applicable.
Approved by: re (kensmith)
When a request is made to register a filter on a fifo that doesn't
apply to the fifo (i.e., not EVFILT_READ or EVFILT_WRITE), reject
it as EINVAL, not by returning 1 (EPERM).
Approved by: re (kensmith)
Remove DFLAG_SEEKABLE from fifo file descriptors: fifos are not seekable
according to POSIX, not to mention the fact that it doesn't make sense
(and hence isn't really implemented). This causes the fifo_misc
regression test to succeed.
Approved by: re (scottl)
Only poll the fifo for read events if the fifo is attached to a readable
file descriptor. Otherwise, the read end of a fifo might return that it
is writable (which it isn't).
Only poll the fifo for write events if the fifo attached to a writable
file descriptor. Otherwise, the write end of a fifo might return that
it is readable (which it isn't).
In the event that a file is FREAD|FWRITE (which is allowed by POSIX, but
has undefined behavior), we poll for both.
Approved by: re (kensmith)
After going to some trouble to identify only the write-related events
to poll the write socket for, the fifo polling code proceeded to poll
for the complete set of events. Use 'levents' instead of 'events' as
the argument to poll, and only poll the write socket if there is
interest in write events.
Approved by: re (kensmith)
Add an assertion that fifo_open() doesn't race against other threads
while sleeping to allocate fifo state: due to using the vnode lock to
serialize access to a fifo during open, it shouldn't happen (tm).
Approved by: re (kensmith)
Rather than reaching into the internals of the UNIX domain socket code
by calling uipc_connect2() to connect two socket endpoints to create a
fifo, call soconnect2().
Approved by: re (kensmith)
``Process one NMI interrupt per handler invocation as the processor
buffers pending NMIs from multiple interrupting PMCs and delivers
them serially.''
Approved by: re (kensmith)
Even if there are no valid keys in metadata, but provider is attached
we can still use setkey subcommand.
Found by: regression tests
Approved by: re (scottl)
When bge_stop() is called from bge_detach(), mii is already NULL, so check
before trying to use it.
This fix allows to 'kldunload if_bge' without panicing.
Reviewed by: bz
Approved by: re (scottl)
Add gem(4) to the list of devices supporting VLAN-sized frames natively
(since sys/dev/gem/if_gem.c rev. 1.34, MFC'ed in rev. 1.29.2.4).
Approved by: re (scottl)
- Allow for VLAN-sized frames and set IFCAP_VLAN_MTU.
- On resume all registers have to be initialized again like after
power-on so reset sc_inited in gem_suspend() in order get all of
the registers set next time gem_init_regs() is called.
- On at least some ERI and GEM revisions GEM_MAC_RX_OVERFLOW happen
often due to a silicon bug and re-initializing is all we can do
about these errors so make handling them non-verbose.
- Remove a superfluous memset(3) call in gem_meminit(), all elements
are initialized to 0 anyway.
Approved by: re (scottl)
When padding with zero, do pad after prefixes rather than padding
before prefixes.
Use cases:
printf("%05d", -42); --> "00-42" (should be "-0042")
printf("%#05x", 12); --> "000xc" (should be "0x00c")
Submitted by: Oliver Fromme
PR: kern/85520
Approved by: re (kensmith)
nd6.c, r1.55; nd6_nbr.c, r1.33
> Add support for multicast to the bridge and allow inet6 addresses to be
> assigned to the interface.
>
> IPv6 auto-configuration is disabled. An IPv6 link-local address has a
> link-local scope within one link, the spec is unclear for the bridge case and
> it may cause scope violation.
>
> An address can be assigned in the usual way;
> ifconfig bridge0 inet6 xxxx:...
>
> Tested by: bmah
> Reviewed by: ume (netinet6)
> Approved by: mlaier (mentor)
Approved by: re (kensmith), mlaier (mentor)
- Do not hold route entry lock, when calling arprequest(). One such
call was introduced by me in 1.139, the other one was present before.
- Do all manipulations with rtentry and la before dropping the lock.
- Copy interface address from route into local variable before dropping
the lock. Supply this copy as argument to arprequest().
(LOR Ids in original commit message.)
Approved by: re (scottl)