]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
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

17 years agoFix packing on the country band descriptor. No real change since this
imp [Fri, 1 Dec 2006 18:40:51 +0000 (18:40 +0000)]
Fix packing on the country band descriptor.  No real change since this
is unused.

Reviewed by: sam

17 years agoMake sure that carp_header is 36 bytes long
imp [Fri, 1 Dec 2006 18:37:41 +0000 (18:37 +0000)]
Make sure that carp_header is 36 bytes long

17 years agofix typo in last commit
imp [Fri, 1 Dec 2006 18:25:18 +0000 (18:25 +0000)]
fix typo in last commit

17 years agoUse FreeBDS standard __packed as opposed to the gcc centric
imp [Fri, 1 Dec 2006 18:18:35 +0000 (18:18 +0000)]
Use FreeBDS standard __packed as opposed to the gcc centric
__attribute__(__packed__).

17 years agoback out use of LLC_SNAPFRAMELEN now that sizeof(struct llc) isn't
sam [Fri, 1 Dec 2006 17:58:33 +0000 (17:58 +0000)]
back out use of LLC_SNAPFRAMELEN now that sizeof(struct llc) isn't
padded on arm

17 years agoMove the __packed declarations. This makes sizeof(struct llc) 8 again
imp [Fri, 1 Dec 2006 17:50:11 +0000 (17:50 +0000)]
Move the __packed declarations.  This makes sizeof(struct llc) 8 again
on the arm.  Add an assert to ensure that the size is 8 to prefent others
from falling into this trap (we should have more of these).

Why the construct:

struct foo {
union bar {
struct {
...
} __packed fred;
...
} __packed wilma;
} __packed;

has a different packing than:

struct foo {
union bar {
struct {
...
} fred __packed;
...
} wilma __packed;
} __packed;

is beyond my ability to ferret out of the gcc documentation.  Most
likely some subtle binding issue (eg before it says the struct itself
is packed, while after it means that the whole struct is packed into
the thing it is in).  Pointers to relevant documentation would be
appreciated.

17 years agoGive up on waiting for a repo-copy (no answer in 20 days), and
ru [Fri, 1 Dec 2006 17:46:25 +0000 (17:46 +0000)]
Give up on waiting for a repo-copy (no answer in 20 days), and
commit my markup fixes.

OK'ed by: kmacy

17 years agoMake libalias.conf parsing a bit smarter.
piso [Fri, 1 Dec 2006 16:34:53 +0000 (16:34 +0000)]
Make libalias.conf parsing a bit smarter.
This closes PR kern/106112.

While here, add mbuf's #includes i forgot in the previous commit.

Approved by: gleb

17 years agoRemove m_megapullup from ng_nat and put it under libalias.
piso [Fri, 1 Dec 2006 16:27:11 +0000 (16:27 +0000)]
Remove m_megapullup from ng_nat and put it under libalias.

Approved by: gleb

17 years agoDelete old (and now unused) alias_*.so.4 files.
piso [Fri, 1 Dec 2006 16:23:25 +0000 (16:23 +0000)]
Delete old (and now unused) alias_*.so.4 files.

Approved by: gleb

17 years agoclarify shortcut return
sam [Fri, 1 Dec 2006 16:03:39 +0000 (16:03 +0000)]
clarify shortcut return

Submitted by: cognet, kevlo
MFC after: 1 week

17 years agoGrammar nit.
ru [Fri, 1 Dec 2006 13:07:52 +0000 (13:07 +0000)]
Grammar nit.

17 years agoWe can have no PV entry here if the previous mapping was unmanaged, and the new
cognet [Fri, 1 Dec 2006 12:29:55 +0000 (12:29 +0000)]
We can have no PV entry here if the previous mapping was unmanaged, and the new
one is unmanaged too, so update the KASSERT to reflect this.

17 years agoAdd missing `;;' in the example shell code snippet.
ru [Fri, 1 Dec 2006 09:00:38 +0000 (09:00 +0000)]
Add missing `;;' in the example shell code snippet.

PR: i386/106113
Submitted by: Richard Arends
MFC after: 3 days

17 years agoUse CTASSERT to make sure:
imp [Fri, 1 Dec 2006 07:06:35 +0000 (07:06 +0000)]
Use CTASSERT to make sure:
sizeof ether_header is 2 * ETHER_ADDR_LEN + 2 (14) bytes long
sizeof ether_addr is ETHER_ADDR_LEN bytes long

On arm, this shows that struct ether_addr needs to be __packed.

The first condition muts be true for the bridging code to not dump core.
The second one appears to be implicitly relied upon by wi (but many
of the rids it sends down likely need __packed too to be safe) and
maybe others.  It appears to not hurt anything.

17 years agoThe sigconv.awk script generates a sigdesc.h header file, which
keramida [Fri, 1 Dec 2006 07:01:19 +0000 (07:01 +0000)]
The sigconv.awk script generates a sigdesc.h header file, which
contains a sigdec[] vector of structures, but the generated output is
missing braces around the initializer of each struct, which
triggers warnings in WARNS=3:

src/usr.bin/top/sigdesc.h:10: warning: missing braces around initializer
src/usr.bin/top/sigdesc.h:10: warning: (near initialization for `sigdesc[0]')

  * Fix the sigconv.awk script to generate a header with initializers
    which look better.

  * Add rules to usr.bin/top/Makefile that rebuilds a new sigconv.h
    header which matches the correct signal set from the build-time
    version of `${DESTDIR}/usr/include/signal.h' (so sigconv.h doesn't
    get stale once changes are made to the header).

  * Remove the old sigconv.h header, now that it is autoupdated at
    build time.

  * Various Makefile style fixes (the committed Makefile was kindly
    submitted by Ruslan):

    - Reorder .PATH, PROG, SRCS and CFLAGS to match style.Makefile(5)
    - Split off the generated sources (sigdesc.h top.local.h) in an
      SRCS+= line of their own.
    - Add entries to CLEANFILES near the rules that generate the
      respective files.
    - Move the explicit rule which builds top.1 after the implicit
      rules which generate its dependencies.

Reviewed by: ru, bde
Submitted by: ru (Makefile)
MFC after: 2 weeks

17 years agoAdd inverted amplifier sense quirk for HP Compaq nx4300.
ariff [Fri, 1 Dec 2006 06:53:13 +0000 (06:53 +0000)]
Add inverted amplifier sense quirk for HP Compaq nx4300.

PR: kern/106104
Submitted by: Shun-ichi Kobayashi <koba@mbox.kudpc.kyoto-u.ac.jp>
MFC after: 3 days

17 years agosizeof(struct llc) includes padding on arm; use LLC_SNAPFRAMELEN for now
sam [Fri, 1 Dec 2006 05:48:35 +0000 (05:48 +0000)]
sizeof(struct llc) includes padding on arm; use LLC_SNAPFRAMELEN for now

Submitted by: jhay
MFC after: 2 weeks

17 years agoFix white spaces.
jkim [Fri, 1 Dec 2006 01:37:45 +0000 (01:37 +0000)]
Fix white spaces.

17 years agoSimplify statistics updates, remove redundant register reads, and add
jkim [Fri, 1 Dec 2006 01:08:52 +0000 (01:08 +0000)]
Simplify statistics updates, remove redundant register reads, and add
discarded RX packets to input error for BCM5705 or newer chipset as the others.
Unfortunately we cannot do the same for output errors because ifOutDiscards
equivalent register does not exist.  While I am here, replace misleading and
wrong BGE_RX_STATS/BGE_TX_STATS with BGE_MAC_STATS.  They were reversed but
worked accidently.

17 years agoIn pmap_ts_referenced(), don't attempt to do anything if the page is
cognet [Thu, 30 Nov 2006 23:35:34 +0000 (23:35 +0000)]
In pmap_ts_referenced(), don't attempt to do anything if the page is
fictitious, and just return 0.

17 years agoFirst bits of Xscale core 3 support (the VM bits are far from being optimal
cognet [Thu, 30 Nov 2006 23:34:07 +0000 (23:34 +0000)]
First bits of Xscale core 3 support (the VM bits are far from being optimal
yet).

17 years agoIntroduce CPU_XSCALE_CORE3, as XScale Core 3 is significally different than
cognet [Thu, 30 Nov 2006 23:30:40 +0000 (23:30 +0000)]
Introduce CPU_XSCALE_CORE3, as XScale Core 3 is significally different than
regular Xscale (it has no mini data cache, has armv6-style 16MB
supersections, and can address 36bits).
Define it for i81342.

17 years agoFix the hardware VLAN tagging. TX was broken on little-endian
ru [Thu, 30 Nov 2006 21:01:59 +0000 (21:01 +0000)]
Fix the hardware VLAN tagging.  TX was broken on little-endian
machines and both TX and RX were broken on big-endian machines.

The chip design is crazy -- on RX, it puts the 16-bit VLAN tag
in network byte order (big-endian) in the 32-bit little-endian
register!

Thanks to John Baldwin for helping me document this change! ;-)

Tested by: sat (amd64), test program (sparc64)
PR: kern/105054
MFC after: 3 days

17 years agoFrom OpenBSD, rev. 1.91:
mlaier [Thu, 30 Nov 2006 18:55:36 +0000 (18:55 +0000)]
From OpenBSD, rev. 1.91:
  fix servicecurve check; no point in checking the same sc three times, it
  was obviously intended to check all three. has been wrong since the
  beginning, 4 years... noticed by Earl Lapus <earl.lapus@gmail.com>, Vasil
  Dimov <vd@FreeBSD.org> mailed me then, ok mcbride

MFC after: 3 days

17 years agoBump .Dd for revision 1.8.
ceri [Thu, 30 Nov 2006 18:06:57 +0000 (18:06 +0000)]
Bump .Dd for revision 1.8.

17 years agoo ciss.ko depends on cam and pci.
maxim [Thu, 30 Nov 2006 15:14:17 +0000 (15:14 +0000)]
o ciss.ko depends on cam and pci.

PR: kern/105989
Submitted by: nork
MFC after: 1 month

17 years agoThe recent issues with em(4) interface has shown that the old 4.4BSD
glebius [Thu, 30 Nov 2006 15:02:01 +0000 (15:02 +0000)]
The recent issues with em(4) interface has shown that the old 4.4BSD
if_watchdog/if_timer interface doesn't fit modern SMP network
stack design.

Device drivers that need watchdog to monitor their hardware should
implement it theirselves.

Eventually the if_watchdog/if_timer API will be removed. For now,
warn that driver uses it.

Reviewed by: scottl

17 years ago- Instead of if_watchdog/if_timer interface use our own timer
glebius [Thu, 30 Nov 2006 14:58:01 +0000 (14:58 +0000)]
- Instead of if_watchdog/if_timer interface use our own timer
  that piggybacks on fxp_tick() callout.

17 years agoBump __FreeBSD_version after UQ_KBD_IGNORE was set for Wi-Spy devices.
flz [Thu, 30 Nov 2006 14:29:47 +0000 (14:29 +0000)]
Bump __FreeBSD_version after UQ_KBD_IGNORE was set for Wi-Spy devices.

17 years ago- Instead of if_watchdog/if_timer interface use our own timer
glebius [Thu, 30 Nov 2006 13:40:39 +0000 (13:40 +0000)]
- Instead of if_watchdog/if_timer interface use our own timer
  that piggybacks on bge_tick() callout.
- Lock bge_tick() using callout_init_mtx().

17 years agoConsistently use #ifdef INET6 rather than mixing and matching with
rwatson [Thu, 30 Nov 2006 10:54:54 +0000 (10:54 +0000)]
Consistently use #ifdef INET6 rather than mixing and matching with
#if defined(INET6).

Don't comment the end of short #ifdef blocks.

Comment cleanup.

Line wrap.

17 years agoLinker set support depends on the magic __start_<section> and
kib [Thu, 30 Nov 2006 10:50:29 +0000 (10:50 +0000)]
Linker set support depends on the magic __start_<section> and
__stop_<section> symbols generated by the static linker for elf
sections. This is done only for the final link, and not for ld -r.
Augment elf_obj in-kernel linker by recognizing such special symbols,
and resolving them to the start and end of the section automatically.

As result, linker sets on amd64 could be used in the same way as on
other architectures, without explicit calls to linker_file_lookup_set().

Requested by: rdivacky
No objections from: peter, jhb

17 years agoOnly grab the sched_lock if we actually need to modify the thread priority.
phk [Thu, 30 Nov 2006 08:27:38 +0000 (08:27 +0000)]
Only grab the sched_lock if we actually need to modify the thread priority.

During a buildworld only 2/3 of the calls to msleep actually changed
the priority.

17 years agoDon't use vm_page_flag_set() if installing bootstrap page-table entries
grehan [Thu, 30 Nov 2006 08:13:06 +0000 (08:13 +0000)]
Don't use vm_page_flag_set() if installing bootstrap page-table entries
since the vm page mutex's aren't yet initialized. Fixes boot-time panic.

Reported by: Dario Freni  saturnero at freesbie dot org

17 years agoFlushing the buffer is conditional on actually using the buffer. Oops.
jb [Thu, 30 Nov 2006 07:25:52 +0000 (07:25 +0000)]
Flushing the buffer is conditional on actually using the buffer. Oops.