]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
17 years ago- Use our own callout (the dc_tick() callout uses varying periods
marius [Wed, 6 Dec 2006 01:56:38 +0000 (01:56 +0000)]
- Use our own callout (the dc_tick() callout uses varying periods
  depending on the NIC and isn't used at all with HomePNA links)
  instead of if_slowtimo() for driving dc_watchdog() in order to
  avoid races accessing if_timer.
- Use bus_get_dma_tag() so dc(4) works on platforms requiring it.
- Don't bother to set if_mtu to ETHERMTU, ether_ifattach() does that.
- Remove an alpha remnant in dc_softc.

17 years agotest cancel_pending to save a thr_wake call in some specical cases.
davidxu [Wed, 6 Dec 2006 00:15:35 +0000 (00:15 +0000)]
test cancel_pending to save a thr_wake call in some specical cases.

17 years agoinitialize mutex and cv.
davidxu [Wed, 6 Dec 2006 00:03:42 +0000 (00:03 +0000)]
initialize mutex and cv.

17 years ago_thr_ucond_wait drops lock, we should pick it up again.
davidxu [Tue, 5 Dec 2006 23:46:11 +0000 (23:46 +0000)]
_thr_ucond_wait drops lock, we should pick it up again.

17 years agoFlush my typo fix queue for this directory.
ceri [Tue, 5 Dec 2006 23:20:14 +0000 (23:20 +0000)]
Flush my typo fix queue for this directory.

17 years agoFix typos.
ceri [Tue, 5 Dec 2006 23:05:53 +0000 (23:05 +0000)]
Fix typos.

17 years ago- Add myself to calendar.freebsd
gabor [Tue, 5 Dec 2006 22:22:02 +0000 (22:22 +0000)]
- Add myself to calendar.freebsd

Approved by: erwin (mentor)
MFC after: 3 days

17 years agodocument that NCQ is not yet supported.
wilko [Tue, 5 Dec 2006 20:23:25 +0000 (20:23 +0000)]
document that NCQ is not yet supported.

PR: kern/106343

17 years agoPortability fix for non-POSIX operating systems: Open files in binary mode.
cperciva [Tue, 5 Dec 2006 20:22:14 +0000 (20:22 +0000)]
Portability fix for non-POSIX operating systems: Open files in binary mode.

PR: bin/106358
Submitted by: techtonik at php dot net

17 years agoUse callout mechanism instead of timeout()/untimeout().
ume [Tue, 5 Dec 2006 18:54:21 +0000 (18:54 +0000)]
Use callout mechanism instead of timeout()/untimeout().

MFC after: 1 week

17 years agoForced commit to note a repo-copy of this file from
bmah [Tue, 5 Dec 2006 18:30:05 +0000 (18:30 +0000)]
Forced commit to note a repo-copy of this file from
src/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml.

This operation is a part of a reorganization of the release notes,
which will (when completed) provide one version of the release notes
covering all architectures, rather than multiple versions (each
describing one architecture).

Discussed on: -doc@

17 years agoTeach mdoc(7) about FreeBSD/arm and FreeBSD 6.3; both needed by the
ru [Tue, 5 Dec 2006 17:01:23 +0000 (17:01 +0000)]
Teach mdoc(7) about FreeBSD/arm and FreeBSD 6.3; both needed by the
npe(4) manpage.

17 years agoMove npe.4 to a machine specific manpage subdirectory.
ru [Tue, 5 Dec 2006 16:57:10 +0000 (16:57 +0000)]
Move npe.4 to a machine specific manpage subdirectory.

17 years agoFix an off by one error in struct nve_tx_desc's frags[] array as a result
jhb [Tue, 5 Dec 2006 15:31:05 +0000 (15:31 +0000)]
Fix an off by one error in struct nve_tx_desc's frags[] array as a result
of the nvenet lib upgrade (the constant went from 63 (2^n - 1) to
32 (2^n)).  For reasons that are not obvious to me this fixes the driver
on at least some NICs.

MFC after: 3 days

17 years agoOnce upon a time, the hostname was being set in the /etc/netstart,
ru [Tue, 5 Dec 2006 12:09:50 +0000 (12:09 +0000)]
Once upon a time, the hostname was being set in the /etc/netstart,
which can be called a "network initialization script", now that it
is set in /etc/rc.d/hostname, "network" sounds confusing, so remove
it.

17 years agoUse a different bitmask for superpages' base address so that it
ru [Tue, 5 Dec 2006 11:31:33 +0000 (11:31 +0000)]
Use a different bitmask for superpages' base address so that it
doesn't conflict with the PG_PDE_PAT bit.  (We still don't mask
off all the reserved bits but that's okay for now.)

Reviewed by: alc

17 years agoAdd a "-D" flag to restore which puts it into "degraded" mode. This
dwmalone [Tue, 5 Dec 2006 11:18:51 +0000 (11:18 +0000)]
Add a "-D" flag to restore which puts it into "degraded" mode. This
makes restore less efficient, but it makes a bigger effore to read
corrupted dumps. Specifiacally, when in degreded mode:

1) Restore shifts the input by 1 byte if it sees a problem,
rather than one tape block.
2) It doesn't assume the inodes are stored in ascending order.
3) It turns some panics into warning printfs.

We also verify some fields more carefully than before.

There's probably more a degreded mode could do, but this seems to
help a lot.

Approved by: imp, iedowse, mckusick
MFC after: 3 weeks

17 years agoFix markup.
ru [Tue, 5 Dec 2006 08:07:21 +0000 (08:07 +0000)]
Fix markup.

17 years agoMake ISPCTL_PLOGX find a handle to log into the management server
mjacob [Tue, 5 Dec 2006 07:50:23 +0000 (07:50 +0000)]
Make ISPCTL_PLOGX find a handle to log into the management server
with- not hope for the best. Change some things which were gated
off of 24XX to be gated off of 2K login support. Convert some
isp_prt calls to xpt_print calls.

17 years agoAdd a chip timeout to ENABLE/MODIFY/DISABLE lun calls.
mjacob [Tue, 5 Dec 2006 07:49:15 +0000 (07:49 +0000)]
Add a chip timeout to ENABLE/MODIFY/DISABLE lun calls.

MFC after: 1 month

17 years agouse xpt_print function
mjacob [Tue, 5 Dec 2006 07:47:22 +0000 (07:47 +0000)]
use xpt_print function

17 years agoAdd an xpt_print function to reduce most of the xpt_print_path/printf
mjacob [Tue, 5 Dec 2006 07:45:28 +0000 (07:45 +0000)]
Add an xpt_print function to reduce most of the xpt_print_path/printf
pairs. Convert the core code to use it.

Reviewed by: scsi (various folks weighing in with good advice)
MFC after: 2 weeks

17 years agothe c_has_waiters is lazily updated, temporarily disable the false
davidxu [Tue, 5 Dec 2006 07:23:58 +0000 (07:23 +0000)]
the c_has_waiters is lazily updated, temporarily disable the false
alarm code.

17 years agoFix typo.
joel [Tue, 5 Dec 2006 06:56:09 +0000 (06:56 +0000)]
Fix typo.

17 years agoUse ucond to implement barrier.
davidxu [Tue, 5 Dec 2006 06:54:25 +0000 (06:54 +0000)]
Use ucond to implement barrier.

17 years agoAdd _thr_ucond_init().
davidxu [Tue, 5 Dec 2006 06:53:44 +0000 (06:53 +0000)]
Add _thr_ucond_init().

17 years agoconst poison
imp [Tue, 5 Dec 2006 06:19:36 +0000 (06:19 +0000)]
const poison

submitted by: john wehle

17 years agoMore properly cleanup the iicbus child when deleting it.
imp [Tue, 5 Dec 2006 06:11:10 +0000 (06:11 +0000)]
More properly cleanup the iicbus child when deleting it.

These are from patches by John Wehle, but the commentary has been
updated by me.

Obtained from: ports/multimedia/pvr250, indirectly

17 years agoFix spelling.
davidxu [Tue, 5 Dec 2006 05:31:49 +0000 (05:31 +0000)]
Fix spelling.

17 years agoAdd a test for pthread's cv and cancellation.
davidxu [Tue, 5 Dec 2006 05:14:56 +0000 (05:14 +0000)]
Add a test for pthread's cv and cancellation.

17 years agoReference Hauppage's cxm_iic bit-bang device here.
imp [Tue, 5 Dec 2006 05:06:59 +0000 (05:06 +0000)]
Reference Hauppage's cxm_iic bit-bang device here.
Add a note that suggests a cleanup.

Note: This patch was derived based on looking at the pvrxxx/pvr250
ports' Makefiles only, and may be incomplete.  It is not derived from
anything I saw from Hauppage.

17 years agoTweak _thr_cancel_leave_defer a bit to fix a possible race.
davidxu [Tue, 5 Dec 2006 05:01:57 +0000 (05:01 +0000)]
Tweak _thr_cancel_leave_defer a bit to fix a possible race.

17 years agoFix gdb issue where the i-cache was not being updated when a breakpoint
grehan [Tue, 5 Dec 2006 04:01:52 +0000 (04:01 +0000)]
Fix gdb issue where the i-cache was not being updated when a breakpoint
was written into a user's address space. The fix is to modify uiomove_fromphys
to sync the icache when an executable user-space page is written into.

Alan Cox suggested that there should probably be a higher-level interface
to this in the ptrace code, but agreed that this is an OK short-term solution.

Files changed:

pmap.h - declaration of pmap_page_executable()
pmap_dispatch.c - pass through the page_executable call to the mmu object
mmu_oea.c - implement the page_executable method by examining the PTE_EXEC
 field in the vm_page_t
uio_machdep.c - in uiomove_fromphys(), if the op was a UIO_WRITE to user-space,
 and if the page is executable, sync the icache since this is at the least
 a breakpoint-write from gdb.

Reported by: marcel
Tested by: marcel, grehan on g3+g4
Discussed with: alc
MFC after: 2 weeks

17 years agoInitial cut at Basic Domain Validation- just add some states to
mjacob [Mon, 4 Dec 2006 23:04:13 +0000 (23:04 +0000)]
Initial cut at Basic Domain Validation- just add some states to
traverse through during probing.

Reviewed by: scsi (scottl)

17 years agoMFP4: 109653
jkim [Mon, 4 Dec 2006 22:46:09 +0000 (22:46 +0000)]
MFP4: 109653

Linux mknod(2) can open any files, not just char/block or fifo files.
This fixes Linux Test Project test cases mknod01, mknod07 and mknod09.

17 years agohook npe.4 up to arm build
sam [Mon, 4 Dec 2006 22:42:27 +0000 (22:42 +0000)]
hook npe.4 up to arm build

MFC after: 1 month

17 years agostart 'o man page for xscale npe ethernet driver
sam [Mon, 4 Dec 2006 22:41:41 +0000 (22:41 +0000)]
start 'o man page for xscale npe ethernet driver

MFC after: 1 month

17 years agoMFP4: 109652
jkim [Mon, 4 Dec 2006 22:38:52 +0000 (22:38 +0000)]
MFP4: 109652

Fixes for 'blocking in fifoor state' problem of LTP tests.
linux_*stat*() functions were opening files with O_RDONLY to get
major/minor pair for char/block special files.  Unfortunately,
when these functions are used against fifo, it is blocked forever
because there is no writer.  Instead, we only open char/block special
files for major/minor conversion.  We have to get rid of kern_open()
entirely from translate_path_major_minor() but today is not the day.
While I am here, add checks for errors before calling
translate_path_major_minor().

17 years agoBug fix for obscenely large wait times on uncontested locks
kmacy [Mon, 4 Dec 2006 22:15:50 +0000 (22:15 +0000)]
Bug fix for obscenely large wait times on uncontested locks

if waittime was zero (the lock was uncontested) l->lpo_waittime
in the hash table would not get initialized.

Inspection prompted by questions from: Attilio Rao

17 years ago- Add BGE_FLAG_JUMBO flag which idicates jumbo frame capability. Some day we
jkim [Mon, 4 Dec 2006 22:12:21 +0000 (22:12 +0000)]
- Add BGE_FLAG_JUMBO flag which idicates jumbo frame capability.  Some day we
may be able to support jumbo frames for BCM5714 and BCM5780.
- Rename BGE_IS_5705_OR_BEYOND() to BGE_IS_5705_PLUS() for consistency.

17 years agoGrammar.
ru [Mon, 4 Dec 2006 20:34:25 +0000 (20:34 +0000)]
Grammar.

OK'ed by: sam

17 years agoUse bge_flags to save chipset family and remove dead code while I am here.
jkim [Mon, 4 Dec 2006 19:50:49 +0000 (19:50 +0000)]
Use bge_flags to save chipset family and remove dead code while I am here.

17 years ago- separate out rounding memory ranges to 4M boundaries from OFW memory allocation...
kmacy [Mon, 4 Dec 2006 19:35:40 +0000 (19:35 +0000)]
- separate out rounding memory ranges to 4M boundaries from OFW memory allocation bug workaround
- create real_phys_avail which includes all memory ranges to be added to the direct map
- merge in nucleus memory to real_phys_avail
- distinguish between tag VA and index VA in tsb_set_tte_real for cases where page_size != index_page_size
- clean up direct map loop

17 years agodocument recent change to return ECONNRESET for tcp sockets
sam [Mon, 4 Dec 2006 18:39:11 +0000 (18:39 +0000)]
document recent change to return ECONNRESET for tcp sockets

MFC after: 1 month

17 years agoUse _kevent() instead of kevent().
ume [Mon, 4 Dec 2006 17:08:43 +0000 (17:08 +0000)]
Use _kevent() instead of kevent().

Requested by: nork

17 years agoFix an edge case in rman_manage_region() where it didn't handle a resource
jhb [Mon, 4 Dec 2006 16:45:23 +0000 (16:45 +0000)]
Fix an edge case in rman_manage_region() where it didn't handle a resource
ending at ULONG_MAX properly.  While here, use TAILQ_FOREACH_SAFE().

Tested by: "Stephane E. Potvin" <sepotvin at videotron-ca>
MFC after: 1 week

17 years agoAdd two new flags to if_bridge(4) indicating whether the edge flag
syrinx [Mon, 4 Dec 2006 14:45:02 +0000 (14:45 +0000)]
Add two new flags to if_bridge(4) indicating whether the edge flag
of the bridge port and path cost have been administratively set or
calculated automatically by RSTP.

Make sure to transition from non-edge to edge when the port goes down
and the edge flag was manually set before.
This is needed to comply with the condition
((!portEnabled && AdminEdge) || ....)
in the Bridge Detection State Machine (IEE802.1D-2004, p. 171).

Reviewed by: thompsa
Approved by: bz (mentor)

17 years agoFix my error in rev. 1.152
glebius [Mon, 4 Dec 2006 14:35:17 +0000 (14:35 +0000)]
Fix my error in rev. 1.152

Submitted by: oleg

17 years agoFix typo, I was using a wrong header file, and the typo is not detected
davidxu [Mon, 4 Dec 2006 14:27:42 +0000 (14:27 +0000)]
Fix typo, I was using a wrong header file, and the typo is not detected
by compiler.

17 years agoUse kernel provided userspace condition variable to implement pthread
davidxu [Mon, 4 Dec 2006 14:20:41 +0000 (14:20 +0000)]
Use kernel provided userspace condition variable to implement pthread
condition variable.

17 years agoif a thread blocked on userland condition variable is
davidxu [Mon, 4 Dec 2006 14:15:12 +0000 (14:15 +0000)]
if a thread blocked on userland condition variable is
pthread_cancel()ed, it is expected that the thread will not
consume a pthread_cond_signal(), therefor, we use thr_wake()
to mark a flag, the flag tells a thread calling do_cv_wait()
in umtx code to not block on a condition variable.
Thread library is expected that once a thread detected itself
is in pthread_cond_wait, it will call the thr_wake() for itself
in its SIGCANCEL handler.

17 years agoo Correct a function prototype.
maxim [Mon, 4 Dec 2006 14:05:42 +0000 (14:05 +0000)]
o Correct a function prototype.

17 years agoDo not forget to call pmap_free_l2_bucket() in pmap_remove_pages().
cognet [Mon, 4 Dec 2006 12:55:00 +0000 (12:55 +0000)]
Do not forget to call pmap_free_l2_bucket() in pmap_remove_pages().
This can fix the pmap-related panics reported on arm.

MFC After: 3 days

17 years agoArgh. Restore a stat() call that was erroneously removed.
kientzle [Mon, 4 Dec 2006 08:01:53 +0000 (08:01 +0000)]
Argh.  Restore a stat() call that was erroneously removed.

Thanks to: WATANABE, Kazuo
Pointy hat: me, from the handy dispenser I keep nearby.

17 years agorecent changes have caused TRAP_TRACING to induce corruption
kmacy [Mon, 4 Dec 2006 05:06:47 +0000 (05:06 +0000)]
recent changes have caused TRAP_TRACING to induce corruption
disable until the issue has been tracked down

17 years agoRemove the HME_LOCK_ASSERT() in hme_mifinit(), which was added in the
marius [Mon, 4 Dec 2006 01:53:40 +0000 (01:53 +0000)]
Remove the HME_LOCK_ASSERT() in hme_mifinit(), which was added in the
previous revision; it's actually ok when invoking hme_mifinit() from
hme_config() without the lock held.

17 years ago- In hme_stop() mask all interrupts.
marius [Mon, 4 Dec 2006 00:51:08 +0000 (00:51 +0000)]
- In hme_stop() mask all interrupts.
- In hme_eint() print MIF register contents on MIF interrupts.
- In hme_mifinit() don't bother to preserve the previous MIF config.
  This was mainly done in order to preserve the PHY select bit (external
  or internal PHY) but which only needs to be set as appropriate when
  reading from or writing to the desired PHY in hme_mii_{read,write}reg().
  Similarly don't bother to set the PHY select bit in hme_mii_statchg().
- In hme_mii_{read,write}reg() ignore requests to PHYs other than the
  external and internal PHY one.
- Move enabling/disabling the MII drivers of the external transceiver
  from hme_init_locked() and based on the sheer presence of an external
  to hme_mifinit() and based on the currently selected media, defaulting
  to the internal transceiver when the media hasn't been set, yet.
  Invoke hme_mifinit() from the newly added hme_mediachange_locked() so
  the setting of the MII drivers is updated when changing media.
  These changes keep the MII bus from wedging (which manifests in the HME
  and the PHYs no longer being able to communicate with each other) when
  the PHY device drivers isolate the unused PHY in two-PHY configurations
  as present in f.e. Netra t1 100 while changing media, either from
  hme_init_locked() (see also below) or via ifconfig(8). They also allow
  for using both transceivers/PHYs.
- In the newly added hme_mediachange_locked() also reset the PHYs in two-
  PHY configurations before invoking mii_mediachg(). This is required
  for successfully unisolating the previously unused PHY when switching
  between PHYs.
- Now that changing media should no longer cause problems back out rev.
  1.27 and re-enable setting the current media in hme_init_locked() (see
  the commit message of rev. 1.23 for more info).

These changes are roughly a merge of NetBSD gem.c rev. 1.32 - 1.35 (1.30
was already fixed differently in our 1.36; 1.31 and 1.32 were wrong) with
some parts reworked and things that don't make sense like setting the MII
drivers and restoring the previous MIF and XIF settings in hme_mii_{read,
write}reg() omitted.

MFC after: 2 weeks

17 years agoImprove style(9) conformance of igmp.c.
rwatson [Mon, 4 Dec 2006 00:41:48 +0000 (00:41 +0000)]
Improve style(9) conformance of igmp.c.

17 years ago- put some common code in a function handle_remount();
luigi [Sun, 3 Dec 2006 23:50:29 +0000 (23:50 +0000)]
- put some common code in a function handle_remount();
- add better checks on non-existing directories to prevent error
  messages at run time;
- introduce a function log() to help debugging diskless booting
  when things don't work;
- modify the parsing of diskless_remount so you can add mount_nfs
  options after the pathname. You could use 'remount' to do something
  similar, but this way is more convenient because you don't have to
  hardwire the server name in the command.
- document the above.

I have been running the above in a diskless lab since february on RELENG_6.

MFC after: 1 week

17 years agoFix SIOCGDRVSPEC/BRDGGIFSSTP ioctl: make it copyin() the user
syrinx [Sun, 3 Dec 2006 21:50:57 +0000 (21:50 +0000)]
Fix SIOCGDRVSPEC/BRDGGIFSSTP ioctl: make it copyin() the user
provided buffer length before trying to use it.

Reviewed by: thompsa
Approved by: bz (mentor)
MFC after: 3 days

17 years agoMFP4 (110939):
netchild [Sun, 3 Dec 2006 21:06:07 +0000 (21:06 +0000)]
MFP4 (110939):

MFi386: return EOPNOTSUPP for unknown module events.

Submitted by: rdivacky

17 years agoSync with i386 (remove the LINUX stuff) now that the module is usable.
netchild [Sun, 3 Dec 2006 21:02:09 +0000 (21:02 +0000)]
Sync with i386 (remove the LINUX stuff) now that the module is usable.

17 years agoMFP4 (110957)
netchild [Sun, 3 Dec 2006 21:00:31 +0000 (21:00 +0000)]
MFP4 (110957)

Use TAILQ_FOREACH_SAFE instead of the unsafe one where an item is removed
from the queue.

This prevents a panic on kldunload.

Submitted by: rdivacky
Tested by: bsam

17 years agoMinor clarification.
dds [Sun, 3 Dec 2006 19:26:17 +0000 (19:26 +0000)]
Minor clarification.

17 years agoNew test cases demonstrating fixed bugs, and the reason why
dds [Sun, 3 Dec 2006 19:18:41 +0000 (19:18 +0000)]
New test cases demonstrating fixed bugs, and the reason why
fmtcheck can't be used.

17 years agoo Do not leave uninitialized birthtime: in MSDOSFSMNT_LONGNAME
maxim [Sun, 3 Dec 2006 19:04:26 +0000 (19:04 +0000)]
o Do not leave uninitialized birthtime: in MSDOSFSMNT_LONGNAME
set birthtime to FAT CTime (creation time) and in the other cases
set birthtime to -1.

o Set ctime to mtime instead of FAT CTime which has completely
different meaning.

PR: kern/106018
Submitted by: Oliver Fromme
MFC after: 1 month

17 years agoPrevent buffer overflow when forcibly terminating an escape character.
dds [Sun, 3 Dec 2006 17:50:21 +0000 (17:50 +0000)]
Prevent buffer overflow when forcibly terminating an escape character.

Obtained from: OpenBSD
Note: In the case of a full buffer the OpenBSD implementation will
leave in the format string an invalid escape sequence.  This appears
to be harmless with our C library, but according to C99 this can
cause undefined behavior.

MFC after:      2 weeks

17 years agoCorrect handling of format strings with escaped % specifications.
dds [Sun, 3 Dec 2006 17:05:04 +0000 (17:05 +0000)]
Correct handling of format strings with escaped % specifications.

Note: It would be nice to be able to implement getformat() using
fmtcheck(3), but fmtcheck does not distinguish between signed and
unsigned types, a facility jot needs to perform range checks on its
output.

Submitted by:   Per Kristian Hove
MFC after: 2 weeks

17 years agoo Fix typo: manger -> manager.
maxim [Sun, 3 Dec 2006 15:25:55 +0000 (15:25 +0000)]
o Fix typo: manger -> manager.

PR: misc/106253
Submitted by: Niclas Zeising
MFC after: 1 week

17 years agoo /stand/sysinstall -> /usr/sbin/sysinstall.
maxim [Sun, 3 Dec 2006 15:22:45 +0000 (15:22 +0000)]
o /stand/sysinstall -> /usr/sbin/sysinstall.

PR: conf/106254
Submitted by: Simon Olofsson
MFC after: 1 week

17 years agoo As POSIX requires confstr(3) returns zero on errors, not -1.
maxim [Sun, 3 Dec 2006 08:22:36 +0000 (08:22 +0000)]
o As POSIX requires confstr(3) returns zero on errors, not -1.

PR: misc/106234
Submitted by: Guy Harris
MFC after: 1 week

17 years agoFix a massive couple of botches here: the NVRAM settings
mjacob [Sun, 3 Dec 2006 07:59:12 +0000 (07:59 +0000)]
Fix a massive couple of botches here: the NVRAM settings
read wasn't flagging the SYNC mode was enabled. The temp
values for offset and sync period were uint8_t, but were
being assigned and shifted from a uint32_t value.

This didn't show up in testing because a random number
of 1030 cards set a bit that says "honor BIOS negotiation",
which means this whole code path was skipped.

This should clear up at least some of the negotation
issues that have been seen.

17 years agoFix XPT_GET_TRANSPORT_SETTINGS to zero validity and flags-
mjacob [Sun, 3 Dec 2006 07:22:15 +0000 (07:22 +0000)]
Fix XPT_GET_TRANSPORT_SETTINGS to zero validity and flags-
this was causing us to not negotiate sync at all, or at
random.

17 years agoRemove CTS_SPI_FLAGS_TAG_ENB. Nobody is using it and at least one
mjacob [Sun, 3 Dec 2006 07:19:28 +0000 (07:19 +0000)]
Remove CTS_SPI_FLAGS_TAG_ENB. Nobody is using it and at least one
author can't remember why it was there.

The CTS_SCSI_FLAGS_TAG_ENB remains in place, and makes sense, and is
checked all over the place.

The CTS_SPI_FLAGS_TAG_ENB was probably an attempt to distinguish
protocol and transport tag capabilities. At the very least this can
be confusing and prone to many bugs, so let's just assume that the
transport tag case just flows from the protocol (and vice versa)
for now.

17 years agoIt's confusing to say that "Command Queueing Supported" just based
mjacob [Sun, 3 Dec 2006 07:11:55 +0000 (07:11 +0000)]
It's confusing to say that "Command Queueing Supported" just based
upon the scsi flag validity field. Instead, just say "Command Queueing Enabled"
when it is- otherwise remain mute.

17 years agoOptimized RTC accesses by avoiding null writes to the index register
bde [Sun, 3 Dec 2006 03:49:28 +0000 (03:49 +0000)]
Optimized RTC accesses by avoiding null writes to the index register
and by only delaying when an RTC register is written to.  The delay
after writing to the data register is now not just a workaround.

This reduces the number of ISA accesses in the usual case from 4 to
1.  The usual case is 2 rtcin()'s for each RTC interrupt.  The index
register is almost always RTC_INTR for this.  The 3 extra ISA accesses
were 1 for writing the index and 2 for delays.  Some delays are needed
in theory, but in practice they now just slow down slow accesses some
more since almost eveyone including us does them wrong so modern systems
enforce sufficient delays in hardware.  I used to have the delays ifdefed
out, but with the index register optimization the delays are rarely
executed so the old magic ones can be kept or even implemented non-
magically without significant cost.

Optimizing RTC interrupt handling is more interesting than it used to
be because RTC interrupts are currently needed to fix the more efficient
apic timer interrupts on some systems.  apic_timer_hz is normally 2000
so the RTC interrupt rate needs to be 2048 to keep the apic timer
firing on such systems.  Without these changes, each RTC interrupt
normally took 10 ISA accesses (2 PIC accesses and 2 sets of 4 RTC
accesses).  Each ISA access takes 1-1.5uS so 10 of then at 2048 Hz
takes 2-3% of a CPU.  Now 4 of them take 0.8-1.2% of a CPU.

17 years agoIntroduce userspace condition variable, since we have already POSIX
davidxu [Sun, 3 Dec 2006 01:49:22 +0000 (01:49 +0000)]
Introduce userspace condition variable, since we have already POSIX
priority mutex implemented, it is the time to introduce this stuff,
now we can use umutex and ucond together to implement pthread's
condition wait/signal.

17 years agoForced commit: previous revision just correctly reflected that
mjacob [Sun, 3 Dec 2006 00:29:51 +0000 (00:29 +0000)]
Forced commit: previous revision just correctly reflected that
the number of attached devices is 16 bits wide, not 8 bits wide.

17 years agoFix a debug message which didn't quite get it right about data direction.
mjacob [Sun, 3 Dec 2006 00:28:11 +0000 (00:28 +0000)]
Fix a debug message which didn't quite get it right about data direction.

Fix things to use the LSI-Logic Fusion Library mask and shift names for
offset and sync, no matter how awkward they are, in preference to just
plain numbers.

17 years agoAdd missing includes for <sys/buf.h> and <sys/bio.h>.
rodrigc [Sat, 2 Dec 2006 22:30:30 +0000 (22:30 +0000)]
Add missing includes for <sys/buf.h> and <sys/bio.h>.

17 years ago- Probe Davicom DM9102 PHYs.
marius [Sat, 2 Dec 2006 21:21:16 +0000 (21:21 +0000)]
- Probe Davicom DM9102 PHYs.
- Don't set MIIF_NOISOLATE so amphy(4) can be used in configurations
  with multiple PHYs. There doesn't seem to be a problem with isolating
  AM79c873 and workalikes per se nor in combination with the NICs they're
  used with and amphy(4) was already adding IFM_NONE anyway.
- Use mii_phy_add_media() instead of mii_add_media() so the latter can
  be eventually retired.
- Take advantage of mii_phy_setmedia().
- Fix a whitespace nit.

Obtained from: NetBSD dmphy(4) (except for the last item)
MFC after: 2 weeks

17 years ago- In acphy_service() for the MII_TICK case don't bother to check whether
marius [Sat, 2 Dec 2006 21:19:54 +0000 (21:19 +0000)]
- In acphy_service() for the MII_TICK case don't bother to check whether
  the currently selected media is of type IFM_AUTO as auto-negotiation
  doesn't need to be kicked anyway.
- Fix a whitespace nit.
- Probe another Altima PHY, which is a AC101 workalike and integrated
  in at least ADMtek ADM8511 but apparently is not mentioned in any
  publically available data sheet so the actual identifier is unknown.
- Don't set MIIF_NOISOLATE so acphy(4) can be used in configurations
  with multiple PHYs. There doesn't seem to be a problem with isolating
  AC101 and workalikes per se nor in combination with the NICs they're
  used with.
- Use mii_phy_add_media() instead of mii_add_media() so the latter can
  be eventually retired.
- Take advantage of mii_phy_setmedia().

Obtained from: NetBSD (except for the first and second item)
MFC after: 2 weeks

17 years ago- Add another Altima PHY, which is a AC101 workalike and integrated
marius [Sat, 2 Dec 2006 21:18:56 +0000 (21:18 +0000)]
- Add another Altima PHY, which is a AC101 workalike and integrated
  in at least ADMtek ADM8511 but apparently is not mentioned in any
  publically available data sheet so the actual identifier is unknown.
- Add Davicom DM9102 PHY.
- Add DM9101 to the description of AMD 79C873 as at least some Davicom
  DM9101F identify identical to AMD 79C873.

Obtained from: NetBSD
MFC after: 2 weeks

17 years ago- Don't set MIIF_NOISOLATE so tdkphy(4) can be used in configurations
marius [Sat, 2 Dec 2006 20:16:45 +0000 (20:16 +0000)]
- Don't set MIIF_NOISOLATE so tdkphy(4) can be used in configurations
  with multiple PHYs. There doesn't seem to be a problem with isolating
  78Q2120 per se nor in combination with the NICs they're used with and
  tdkphy(4) was already adding IFM_NONE anyway.
- Set MIIF_NOLOOP as loopback doesn't work with this PHY. The MIIF_NOLOOP
  flag currently triggers nothing but hopefully will be respected by
  mii_phy_setmedia() later on.
- Use mii_phy_add_media() instead of mii_add_media() so the latter can
  be eventually retired.
- Take advantage of mii_phy_setmedia().

Thanks to Hans-Joerg Sirtl for lending me test hardware.

Obtained from: NetBSD tqphy(4)
MFC after: 2 weeks

17 years ago- Don't set MIIF_NOISOLATE so rgephy(4) can be used in configurations
marius [Sat, 2 Dec 2006 19:48:53 +0000 (19:48 +0000)]
- Don't set MIIF_NOISOLATE so rgephy(4) can be used in configurations
  with multiple PHYs and un-comment case IFM_NONE in case MII_MEDIACHG
  rgephy_service(). There doesn't seem to be a problem with isolating
  RTL8169S and their internal PHY.
- Take advantage of mii_phy_add_media(). [1]

Obtained from: NetBSD [1]
Tested by: yongari
MFC after: 2 weeks

17 years agoSome style changes to a couple of PHY drivers:
marius [Sat, 2 Dec 2006 19:36:25 +0000 (19:36 +0000)]
Some style changes to a couple of PHY drivers:
- Fix some whitespace nits.
- Fix some spelling in comments.
- Use MII_ANEGTICKS instead of 5.
- Don't define variables in nested scope.
- Remove superfluous returns at the end of void functions.
- Remove unused static global rgephy_mii_model.
- Remove dupe $Id$ in tdkphy(4).
- Sort brgphys table.

MFC after: 2 weeks

17 years agoMany, many thanks to Masanori OZAWA <ozawa@ongs.co.jp>
rodrigc [Sat, 2 Dec 2006 19:35:56 +0000 (19:35 +0000)]
Many, many thanks to Masanori OZAWA <ozawa@ongs.co.jp>
and Daichi GOTO <daichi@FreeBSD.org> for submitting this
major rewrite of unionfs.  This rewrite was done to
try to solve many of the longstanding crashing and locking
issues in the existing unionfs implementation.  This
implementation also adds a 'MASQUERADE mode', which allows
the user to set different user, group, and file permission
modes in the upper layer.

Submitted by: daichi, Masanori OZAWA
Reviewed by: rodrigc (modified for minor style issues)

17 years agoAdd support for Apple Intel/Mac.
ariff [Sat, 2 Dec 2006 17:12:24 +0000 (17:12 +0000)]
Add support for Apple Intel/Mac.

 - Playback and headphone/speaker automute works.
 - Recording untested due to me being deaf doing back-and-forth
   remote debugging.

Free Macbook donation is highly appreciated :)

Tested by: Dennis Pielken <mips128@gmx.net>

17 years agoAdd a helper function mii_phy_dev_probe(), which wraps around the
marius [Sat, 2 Dec 2006 15:32:34 +0000 (15:32 +0000)]
Add a helper function mii_phy_dev_probe(), which wraps around the
mii_phy_match() API and takes care of the PHY device probe based on
the struct mii_phydesc array and the match return value provided.
Convert PHY drivers to take advantage of mii_phy_dev_probe(),
converting drivers to provide a mii_phydesc table in the first
place where necessary.

Reviewed by: yongari
MFC after: 2 weeks

17 years agoMFP4 (108673, 110519, 110874):
netchild [Sat, 2 Dec 2006 14:56:25 +0000 (14:56 +0000)]
MFP4 (108673, 110519, 110874):
- Currently LINUX_MAX_COMM_LEN is smaller than MAXCOMLEN, but in case
  this will change we have a buffer overflow. Apply some defensive
  programming to DTRT when this should happen.
- Use copyinstr() instead of copyin where appropriate.
  * Fallback to copyin() in case of ENAMETOOLONG. [1]
  * Use the right source and destination (it was wrong before).
- Use strlcpy instead of strcpy.
- Properly lock the read case (PR_GET_NAME) like the write case.

Reviewed by: rwatson (except [1])
Suggested by: rwatson [1]

17 years agoAdd the linux module to the amd64 build, all symbols can now be resolved.
netchild [Sat, 2 Dec 2006 13:58:13 +0000 (13:58 +0000)]
Add the linux module to the amd64 build, all symbols can now be resolved.

17 years agoProvide stream operations.
cognet [Sat, 2 Dec 2006 13:37:29 +0000 (13:37 +0000)]
Provide stream operations.

17 years agoForced commit to use the correct PR syntax.
piso [Sat, 2 Dec 2006 10:30:23 +0000 (10:30 +0000)]
Forced commit to use the correct PR syntax.

PR:             kern/106112
Noted by:       ru

17 years agoAdd ftp.il.freebsd.org to the IPv6 server section.
erwin [Sat, 2 Dec 2006 09:58:01 +0000 (09:58 +0000)]
Add ftp.il.freebsd.org to the IPv6 server section.

Submitted by: Rostislav Krasny <rosti.bsd@gmail.com>
Reviewed by: simon (also previous commit)
MFC: 3 days

17 years agoSoftc may be NULL in g_journal_orphan(), so don't be surprised.
pjd [Sat, 2 Dec 2006 09:10:29 +0000 (09:10 +0000)]
Softc may be NULL in g_journal_orphan(), so don't be surprised.

17 years agobce(4) does not work correctly in polling(4) mode for now.
brueffer [Sat, 2 Dec 2006 09:03:06 +0000 (09:03 +0000)]
bce(4) does not work correctly in polling(4) mode for now.

17 years ago- Add israeli mirror [1]
erwin [Fri, 1 Dec 2006 22:49:51 +0000 (22:49 +0000)]
- Add israeli mirror [1]
- Add an IPv6 main site now both ISC and TDC have IPv6

Submitted by: Rostislav Krasny <rosti.bsd@gmail.com> [1]
MFC: 3 days

17 years agoRemove obfuscating OpenBSD/NetBSD/BSDI/FreeBSD 2.x/FreeBSD 5.x ifdefs
rwatson [Fri, 1 Dec 2006 22:45:43 +0000 (22:45 +0000)]
Remove obfuscating OpenBSD/NetBSD/BSDI/FreeBSD 2.x/FreeBSD 5.x ifdefs
from around printfs and address list iteration.

17 years agoif_watchdog -> rl_watchdog
ru [Fri, 1 Dec 2006 21:52:07 +0000 (21:52 +0000)]
if_watchdog -> rl_watchdog

17 years agoALTQify ep(4).
mlaier [Fri, 1 Dec 2006 20:29:55 +0000 (20:29 +0000)]
ALTQify ep(4).

Tested and Requested by: Andy Brook
MFC after: 3 days