]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
15 years agoAccept integer times. Previously, the field "time=1233294539" would be
Tim Kientzle [Fri, 30 Jan 2009 05:49:27 +0000 (05:49 +0000)]
Accept integer times.  Previously, the field "time=1233294539" would be
rejected as invalid.

15 years agoSpawn one fewer shells on startup. We don't use dhcp_interfaces at
Warner Losh [Fri, 30 Jan 2009 03:41:45 +0000 (03:41 +0000)]
Spawn one fewer shells on startup.  We don't use dhcp_interfaces at
all in this function, and grep shows no other instances of it
(besides, this is a function, and in a sub-shell, so all changes are
local).

15 years agoFor files not named on the command line, only the basename is compared
David E. O'Brien [Fri, 30 Jan 2009 00:22:08 +0000 (00:22 +0000)]
For files not named on the command line, only the basename is compared
to the exclude pattern.
Change this so that "grep --exclude='*/.svn/*' -[Rr] foo *" DWIM.

Obtained from: dave+news001@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx (Dave Gibson)
Obtained from: comp.unix.questions [Thu, 15 Mar 2007 18:54:38 +0000]
Obtained from: http://unix.derkeiler.com/Newsgroups/comp.unix.questions/2007-03/msg00046.html

15 years agotrack hal changes
Sam Leffler [Thu, 29 Jan 2009 23:29:07 +0000 (23:29 +0000)]
track hal changes

15 years agoupdate for hal changes
Sam Leffler [Thu, 29 Jan 2009 23:24:21 +0000 (23:24 +0000)]
update for hal changes

15 years agosetup default fixed rates for static turbo and 11n;
Sam Leffler [Thu, 29 Jan 2009 23:12:06 +0000 (23:12 +0000)]
setup default fixed rates for static turbo and 11n;
the 11n rates are pure guess

15 years agoset ni_txparms for static turbo mode
Sam Leffler [Thu, 29 Jan 2009 23:11:18 +0000 (23:11 +0000)]
set ni_txparms for static turbo mode

15 years agosetup default rate set for static turbo mode
Sam Leffler [Thu, 29 Jan 2009 23:09:12 +0000 (23:09 +0000)]
setup default rate set for static turbo mode

15 years agoDefine NULL to be __null in a case of gnu c++. This makes sentinel attribute
Roman Divacky [Thu, 29 Jan 2009 16:51:09 +0000 (16:51 +0000)]
Define NULL to be __null in a case of gnu c++. This makes sentinel attribute
work ok in C++. Note that we enable this only for gcc 4.x for any value
of x. The __null was introduced in gcc 4.1 (in fact it was commited
12 days after release of gcc 4.0) and as we have never released any version
of FreeBSD with gcc 4.0 nor ports support gcc 4.0.x this is a safe check.

Using __GNUC_PREREQ__ would require us to include cdefs.h in params.h so
we just check __GNUC__.

Approved by: kib (mentor)
Tested by: exp build of ports (done by pav)
Tested by: make universe (done by me)

15 years agoMake sure the cdev doesn't go away while the filesystem is still mounted.
Edward Tomasz Napierala [Thu, 29 Jan 2009 16:47:15 +0000 (16:47 +0000)]
Make sure the cdev doesn't go away while the filesystem is still mounted.
Otherwise dev2udev() could return garbage.

Reviewed by: kib
Approved by: rwatson (mentor)
Sponsored by: FreeBSD Foundation

15 years agoUse si_drv1 to hold the softc for the adb_mouse character device instead of
John Baldwin [Thu, 29 Jan 2009 16:18:49 +0000 (16:18 +0000)]
Use si_drv1 to hold the softc for the adb_mouse character device instead of
using devclass_get_softc().

Tested by: nwhitehorn

15 years agoIf a process is a zombie and we couldn't identify another useful state,
Robert Watson [Thu, 29 Jan 2009 09:32:56 +0000 (09:32 +0000)]
If a process is a zombie and we couldn't identify another useful state,
print out the state as "zombine" in preference to "unknown" when ^T is
pressed.

MFC after: 3 days
Sponsored by: Google, Inc.

15 years ago - Allocate apic vectors on a per-cpu basis. This allows us to allocate
Jeff Roberson [Thu, 29 Jan 2009 09:22:56 +0000 (09:22 +0000)]
 - Allocate apic vectors on a per-cpu basis.  This allows us to allocate
   more irqs as we have more cpus.  This is principally useful on systems
   with msi devices which may want many irqs per-cpu.

Discussed with: jhb
Sponsored by: Nokia

15 years agoBackout change 187782. It inhibits ntpd from starting at all
Giorgos Keramidas [Thu, 29 Jan 2009 06:43:29 +0000 (06:43 +0000)]
Backout change 187782.  It inhibits ntpd from starting at all
when ntpd_sync_on_start is set.

Noticed by: rafan

15 years agoMake adb_mouse use dev2unit() instead of minor().
Ed Schouten [Thu, 29 Jan 2009 05:59:42 +0000 (05:59 +0000)]
Make adb_mouse use dev2unit() instead of minor().

A real fix would be to migrate it to si_drv0 to store the softc
directly, but this is the quickest way to fix it right now.

15 years agoAdd one more debug level.
Alexander Motin [Wed, 28 Jan 2009 23:18:21 +0000 (23:18 +0000)]
Add one more debug level.

15 years agoAdd hw.sdhci.debug sysctl to control debug level.
Alexander Motin [Wed, 28 Jan 2009 22:53:41 +0000 (22:53 +0000)]
Add hw.sdhci.debug sysctl to control debug level.

15 years agoImprove mmc driver verbose logging.
Alexander Motin [Wed, 28 Jan 2009 22:09:00 +0000 (22:09 +0000)]
Improve mmc driver verbose logging.
Make requests logging controllable by hw.mmc.debug sysctl.

15 years agoUse a different value for the initial control word for the FPU state for
John Baldwin [Wed, 28 Jan 2009 20:35:16 +0000 (20:35 +0000)]
Use a different value for the initial control word for the FPU state for
32-bit processes.  The value matches the initial setting used by
FreeBSD/i386.  Otherwise, 32-bit binaries using floating point would use
a slightly different initial state when run on FreeBSD/amd64.

MFC after: 1 week

15 years agoUpdate ubtbcmfw2 (aka usb2_bluetooth_fw) driver
Maksim Yevmenkin [Wed, 28 Jan 2009 20:06:02 +0000 (20:06 +0000)]
Update ubtbcmfw2 (aka usb2_bluetooth_fw) driver

Reviewed by: HPS

15 years agoMake ng_ubt2 (aka usb2_bluetooth_ng) driver only attach as "generic" driver
Maksim Yevmenkin [Wed, 28 Jan 2009 20:04:39 +0000 (20:04 +0000)]
Make ng_ubt2 (aka usb2_bluetooth_ng) driver only attach as "generic" driver

Reviewed by: HPS

15 years agoMark most often used sysctl's as MPSAFE.
Ed Schouten [Wed, 28 Jan 2009 19:58:05 +0000 (19:58 +0000)]
Mark most often used sysctl's as MPSAFE.

After running a `make buildkernel', I noticed most of the Giant locks in
sysctl are only caused by a very small amount of sysctl's:

- sysctl.name2oid. This one is locked by SYSCTL_LOCK, just like
  sysctl.oidfmt.

- kern.ident, kern.osrelease, kern.version, etc. These are just constant
  strings.

- kern.arandom, used by the stack protector. It is already protected by
  arc4_mtx.

I also saw the following sysctl's show up. Not as often as the ones
above, but still quite often:

- security.jail.jailed. Also mark security.jail.list as MPSAFE. They
  don't need locking or already use allprison_lock.

- kern.devname, used by devname(3), ttyname(3), etc.

This seems to reduce Giant locking inside sysctl by ~75% in my primitive
test setup.

15 years agoRemove gsm hacks now that we can do this "right":
Sam Leffler [Wed, 28 Jan 2009 19:25:51 +0000 (19:25 +0000)]
Remove gsm hacks now that we can do this "right":
o no need for special country codes; it's sufficient to use the sku
o no need to specify bands w/ 2.4G frequencies, use the real values
o remove duplicate band specs

15 years agoinclude the channel list in list caps when -v is set; ieee channel
Sam Leffler [Wed, 28 Jan 2009 19:24:29 +0000 (19:24 +0000)]
include the channel list in list caps when -v is set; ieee channel
#'s are not available and we have to hack around the mapchan routine
but it lets us see the calibration table w/o forcing the debug regdomain

15 years agopritize the channel we display with list chans so that, among other
Sam Leffler [Wed, 28 Jan 2009 19:23:12 +0000 (19:23 +0000)]
pritize the channel we display with list chans so that, among other
things, 1/2 and 1/4 width channels are hidden behind the full width
channel; this is needed because they are ordered such that they
appear after in the channel table

15 years agosimplify display of 1/2 and 1/4 width channels
Sam Leffler [Wed, 28 Jan 2009 19:20:12 +0000 (19:20 +0000)]
simplify display of 1/2 and 1/4 width channels

15 years agoimprove debug msgs for regdomain operations; print channel flags
Sam Leffler [Wed, 28 Jan 2009 19:18:58 +0000 (19:18 +0000)]
improve debug msgs for regdomain operations; print channel flags
symbolically so it's easier to identify channels and why they
are added (or not)

15 years agoFix 1/2 and 1/4 width channel handling:
Sam Leffler [Wed, 28 Jan 2009 19:15:52 +0000 (19:15 +0000)]
Fix 1/2 and 1/4 width channel handling:
o only include 1/2 and 1/4 width channels when they are specified in the
  regulatory database description; previously we treated them as if they
  were part of the band and blindly added them for 11a/g
o check the channel list returned in the devcaps to identify whether a
  device supports 1/2 or 1/4 width channels on a band; this might be
  better brought out as a capability bit to avoid filling the channel
  list w/ 1/2 and 1/4 width channels but then cards that only support
  these channels in a range of frequencies could not be described (though
  right now we don't check frequency range only band)

15 years agoUse the correct field name for the size of the sierra_id. While this
Warner Losh [Wed, 28 Jan 2009 19:09:49 +0000 (19:09 +0000)]
Use the correct field name for the size of the sierra_id.  While this
is the same size as id, and is unlikely to change, it seems better to
use the correct field here.  There's no difference in the generated
code.

15 years agoConvert the global mutex protecting the directory lookup name cache from a
John Baldwin [Wed, 28 Jan 2009 19:05:18 +0000 (19:05 +0000)]
Convert the global mutex protecting the directory lookup name cache from a
mutex to a reader/writer lock.  Lookup operations first grab a read lock and
perform the lookup.  If the operation results in a need to modify the cache,
then it tries to do an upgrade.  If that fails, it drops the read lock,
obtains a write lock, and redoes the lookup.

15 years agoMark cd9660 MPSAFE and add support for using shared vnode locks during
John Baldwin [Wed, 28 Jan 2009 18:54:56 +0000 (18:54 +0000)]
Mark cd9660 MPSAFE and add support for using shared vnode locks during
pathname lookups.
- Remove 'i_offset' and 'i_ino' from the ISO node structure and replace
  them with local variables in the lookup routine instead.
- Cache a copy of 'i_diroff' for use during a lookup in a local variable.
- Save a copy of the found directory entry in a malloc'd buffer after a
  successfull lookup before getting the vnode.  This allows us to release
  the buffer holding the directory block before calling vget() which
  otherwise resulted in a LOR between "bufwait" and the vnode lock.
- Use an inlined version of vn_vget_ino() to handle races with ..
  lookups.  I had to inline the code here since cd9660 uses an internal
  vget routine to save a disk I/O that would otherwise re-read the
  directory block.
- Honor the requested locking flags during lookups to allow for shared
  locking.
- Honor the requested locking flags passed to VFS_ROOT() and VFS_VGET()
  similar to UFS.
- Don't make every ISO 9660 vnode hold a reference on the vnode of the
  underlying device vnode of the mountpoint.  The mountpoint already
  holds a suitable reference.

15 years agoSync with ufs_vnops.c:1.245 and remove support for accessing device nodes
John Baldwin [Wed, 28 Jan 2009 18:46:29 +0000 (18:46 +0000)]
Sync with ufs_vnops.c:1.245 and remove support for accessing device nodes
in ISO 9660 filesystems.

15 years agoadd an assert to verify the number of channels returned by ic_getradiocaps
Sam Leffler [Wed, 28 Jan 2009 18:39:23 +0000 (18:39 +0000)]
add an assert to verify the number of channels returned by ic_getradiocaps
correlates with the size of the channel array passed down

might want to promote this to be always present to catch for driver errors

15 years agochange null_getradiocaps to return the actual count of channels instead
Sam Leffler [Wed, 28 Jan 2009 18:37:46 +0000 (18:37 +0000)]
change null_getradiocaps to return the actual count of channels instead
of the true number; otherwise the caller may use the count to do things
with the data it should not (e.g. sort the channel table)

15 years agoActually remove the VA_MARK_ATIME flag. This should have been in the
John Baldwin [Wed, 28 Jan 2009 18:14:24 +0000 (18:14 +0000)]
Actually remove the VA_MARK_ATIME flag.  This should have been in the
earlier commit to add VOP_MARKATIME().

15 years agoAssert an exclusive vnode lock for fifo_cleanup() and fifo_close() since
John Baldwin [Wed, 28 Jan 2009 18:10:57 +0000 (18:10 +0000)]
Assert an exclusive vnode lock for fifo_cleanup() and fifo_close() since
they change v_fifoinfo.

Discussed with: ups (a while ago)

15 years agoOverhaul regulatory support:
Sam Leffler [Wed, 28 Jan 2009 18:00:22 +0000 (18:00 +0000)]
Overhaul regulatory support:
o remove HAL_CHANNEL; convert the hal to use net80211 channels; this
  mostly involves mechanical changes to variable names and channel
  attribute macros
o gut HAL_CHANNEL_PRIVATE as most of the contents are now redundant
  with the net80211 channel available
o change api for ath_hal_init_channels: no more reglass id's, no more outdoor
  indication (was a noop), anM contents
o add ath_hal_getchannels to have the hal construct a channel list without
  altering runtime state; this is used to retrieve the calibration list for
  the device in ath_getradiocaps
o add ath_hal_set_channels to take a channel list and regulatory data from
  above and construct internal state to match (maps frequencies for 900MHz
  cards, setup for CTL lookups, etc)
o compact the private channel table: we keep one private channel
  per frequency instead of one per HAL_CHANNEL; this gives a big
  space savings and potentially improves ani and calibration by
  sharing state (to be seen; didn't see anything in testing); a new config
  option AH_MAXCHAN controls the table size (default to 96 which
  was chosen to be ~3x the largest expected size)
o shrink ani state and change to mirror private channel table (one entry per
  frequency indexed by ic_devdata)
o move ani state flags to private channel state
o remove country codes; use net80211 definitions instead
o remove GSM regulatory support; it's no longer needed now that we
  pass in channel lists from above
o consolidate ADHOC_NO_11A attribute with DISALLOW_ADHOC_11A
o simplify initial channel list construction based on the EEPROM contents;
  we preserve country code support for now but may want to just fallback
  to a WWR sku and dispatch the discovered country code up to user space
  so the channel list can be constructed using the master regdomain tables
o defer to net80211 for max antenna gain
o eliminate sorting of internal channel table; now that we use ic_devdata
  as an index, table lookups are O(1)
o remove internal copy of the country code; the public one is sufficient
o remove AH_SUPPORT_11D conditional compilation; we always support 11d
o remove ath_hal_ispublicsafetysku; not needed any more
o remove ath_hal_isgsmsku; no more GSM stuff
o move Conformance Test Limit (CTL) state from private channel to a lookup
  using per-band pointers cached in the private state block
o remove regulatory class id support; was unused and belongs in net80211
o fix channel list construction to set IEEE80211_CHAN_NOADHOC,
  IEEE80211_CHAN_NOHOSTAP, and IEEE80211_CHAN_4MSXMIT
o remove private channel flags CHANNEL_DFS and CHANNEL_4MS_LIMIT; these are
  now set in the constructed net80211 channel
o store CHANNEL_NFCREQUIRED (Noise Floor Required) channel attribute in one
  of the driver-private flag bits of the net80211 channel
o move 900MHz frequency mapping into the hal; the mapped frequency is stored
  in the private channel and used throughout the hal (no more mapping in the
  driver and/or net80211)
o remove ath_hal_mhz2ieee; it's no longer needed as net80211 does the
  calculation and available in the net80211 channel
o change noise floor calibration logic to work with compacted private channel
  table setup; this may require revisiting as we no longer can distinguish
  channel attributes (e.g. 11b vs 11g vs turbo) but since the data is used
  only to calculate status data we can live with it for now
o change ah_getChipPowerLimits internal method to operate on a single channel
  instead of all channels in the private channel table
o add ath_hal_gethwchannel to map a net80211 channel to a h/w frequency
  (always the same except for 900MHz channels)
o add HAL_EEBADREG and HAL_EEBADCC status codes to better identify regulatory
  problems
o remove CTRY_DEBUG and CTRY_DEFAULT enum's; these come from net80211 now
o change ath_hal_getwirelessmodes to really return wireless modes supported
  by the hardware (was previously applying regulatory constraints)
o return channel interference status with IEEE80211_CHANSTATE_CWINT (should
  change to a callback so hal api's can take const pointers)
o remove some #define's no longer needed with the inclusion of
  <net80211/_ieee80211.h>

Sponsored by:   Carlson Wireless

15 years agoLast step of splitting up minor and unit numbers: remove minor().
Ed Schouten [Wed, 28 Jan 2009 17:57:16 +0000 (17:57 +0000)]
Last step of splitting up minor and unit numbers: remove minor().

Inside the kernel, the minor() function was responsible for obtaining
the device minor number of a character device. Because we made device
numbers dynamically allocated and independent of the unit number passed
to make_dev() a long time ago, it was actually a misnomer. If you really
want to obtain the device number, you should use dev2udev().

We already converted all the drivers to use dev2unit() to obtain the
device unit number, which is still used by a lot of drivers. I've
noticed not a single driver passes NULL to dev2unit(). Even if they
would, its behaviour would make little sense. This is why I've removed
the NULL check.

Ths commit removes minor(), minor2unit() and unit2minor() from the
kernel. Because there was a naming collision with uminor(), we can
rename umajor() and uminor() back to major() and minor(). This means
that the makedev(3) manual page also applies to kernel space code now.

I suspect umajor() and uminor() isn't used that often in external code,
but to make it easier for other parties to port their code, I've
increased __FreeBSD_version to 800062.

15 years agoRestore necessary NUL termination of locname.
Warner Losh [Wed, 28 Jan 2009 16:23:21 +0000 (16:23 +0000)]
Restore necessary NUL termination of locname.

Submitted by: ian dowse
MFC after: 2 days

15 years ago- Re-order SEE ALSO entries
Thomas Abthorpe [Wed, 28 Jan 2009 15:54:28 +0000 (15:54 +0000)]
- Re-order SEE ALSO entries

Noticed by: brueffer
Approved by: trhodes

15 years agoWhile OpenBSD's crypto/ framework has sha1 and md5 implementations that
Bjoern A. Zeeb [Wed, 28 Jan 2009 15:31:16 +0000 (15:31 +0000)]
While OpenBSD's crypto/ framework has sha1 and md5 implementations that
can cope with a result buffer of NULL in the "Final" function, we cannot.
Thus pass in a temporary buffer long enough for either md5 or sha1 results
so that we do not panic.

PR: bin/126468
MFC after: 1 week

15 years ago- Add initial version of portindex(5) manual page
Thomas Abthorpe [Wed, 28 Jan 2009 15:22:44 +0000 (15:22 +0000)]
- Add initial version of portindex(5) manual page

PR: docs/70652
Submitted by: Paul Armstrong <psa otoh.org>
Reviewed by: pav keramida trhodes
Approved by: keramida
MFC after: 3 days

15 years agoUpdate the description of KERN_PROC.
Tom Rhodes [Wed, 28 Jan 2009 15:21:38 +0000 (15:21 +0000)]
Update the description of KERN_PROC.

PR: 100242
Reviewed by: jhb

15 years agoBetter wording for clearing EOF indicator.
Tom Rhodes [Wed, 28 Jan 2009 14:38:41 +0000 (14:38 +0000)]
Better wording for clearing EOF indicator.

Submitted by: keramida and jhb

15 years agoinitialize a couple of variables, gcc 4.2.4-4 (linux) reports
Luigi Rizzo [Wed, 28 Jan 2009 13:39:01 +0000 (13:39 +0000)]
initialize a couple of variables, gcc 4.2.4-4 (linux) reports
some possible uninitialized uses and the warning does make sense.

15 years agoFor some reason (probably dating ages ago) an #ifdef SYSCTL_NODE / #endif
Luigi Rizzo [Wed, 28 Jan 2009 13:11:22 +0000 (13:11 +0000)]
For some reason (probably dating ages ago) an #ifdef SYSCTL_NODE / #endif
section included a lot of stuff that did not belong there.
So split the block in multiple components each around the relevant stuff.

This said, I wonder if building a kernel where SYSCTL_NODE is not
defined is supported at all.

Submitted by: Marta Carbone

15 years agoPrint disk offets as %jd rather than %lld; I fixed one before committing
Robert Watson [Wed, 28 Jan 2009 12:08:19 +0000 (12:08 +0000)]
Print disk offets as %jd rather than %lld; I fixed one before committing
but missed the other, which breaks 64-bit builds.

Reported by: bf <bf2006a at yahoo dot com>
MFC after: 1 week

15 years agoAvoid the use of duplicated typedefs -- see the comment for details.
Luigi Rizzo [Wed, 28 Jan 2009 11:43:12 +0000 (11:43 +0000)]
Avoid the use of duplicated typedefs -- see the comment for details.

15 years agoBump doc date for recent change.
Tom Rhodes [Wed, 28 Jan 2009 11:31:09 +0000 (11:31 +0000)]
Bump doc date for recent change.

15 years agoRemove another comment about clearing EOF indicator.
Tom Rhodes [Wed, 28 Jan 2009 11:25:22 +0000 (11:25 +0000)]
Remove another comment about clearing EOF indicator.

Noticed by: bde

15 years agoFix typo in last commit.
Gleb Smirnoff [Wed, 28 Jan 2009 11:04:27 +0000 (11:04 +0000)]
Fix typo in last commit.

15 years agoRemove remain <= MHLEN restriction in m_makespace(),
VANHULLEBUS Yvan [Wed, 28 Jan 2009 10:41:10 +0000 (10:41 +0000)]
Remove remain <= MHLEN restriction in m_makespace(),
which caused assert with big packets

PR: kern/124609
Submitted by: fabien.thomas@netasq.com
Approved by: gnn(mentor)
Obtained from: NetBSD
MFC after: 1 month

15 years agoAdd a new flag to dumpfs(8), -f, which causes dumpfs to list all free
Robert Watson [Wed, 28 Jan 2009 09:33:00 +0000 (09:33 +0000)]
Add a new flag to dumpfs(8), -f, which causes dumpfs to list all free
fragments in the file system by fragment (block) number.  This new
mode does the necessary arithmetic to generate absolute fragment
numbers rather than than the cg-relative numbers printed in the default
mode.

If -f is passed once, contiguous fragment ranges are collapsed into
an X-Y format as free block lists are currently printed in regular
dumpfs output, but if specified twice, all block numbers are printed
individually, allowing both compact and more script-friendly
representation.

This proves quite handy when attempting to recover deleted data, as it
allows exclusion of non-deleted data from blocks searched.
MFC after: 1 week
Discussed with: jeff, Richard Clayton <richard dot clayton at cl.cam.ac.uk>
Sponsored by: Google, Inc.

15 years agoat91dci isn't useful except on arm.
Warner Losh [Wed, 28 Jan 2009 08:39:48 +0000 (08:39 +0000)]
at91dci isn't useful except on arm.

15 years agoFix parsing of acregmin, acregmax, acdirmin and acdirmax NFS mount options
Craig Rodrigues [Wed, 28 Jan 2009 07:46:35 +0000 (07:46 +0000)]
Fix parsing of acregmin, acregmax, acdirmin and acdirmax NFS mount options
when passed as strings via nmount().

Submitted by: Jaakko Heinonen <jh saunalahti fi>

15 years agoUpdate the manpage to reflect r145172.
David Schultz [Wed, 28 Jan 2009 04:37:27 +0000 (04:37 +0000)]
Update the manpage to reflect r145172.

15 years agoVendor import of gdtoa 20081205.
David Schultz [Wed, 28 Jan 2009 04:36:34 +0000 (04:36 +0000)]
Vendor import of gdtoa 20081205.

15 years agoImport gdtoa sources dated 2008-12-05. Notable changes include a fix
David Schultz [Wed, 28 Jan 2009 03:52:02 +0000 (03:52 +0000)]
Import gdtoa sources dated 2008-12-05. Notable changes include a fix
for a regression in strtod() and support for multibyte decimal points.

15 years agoRemove comment about clearerr() being the only method of clearing
Tom Rhodes [Wed, 28 Jan 2009 01:11:20 +0000 (01:11 +0000)]
Remove comment about clearerr() being the only method of clearing
the EOF indicator, fseek() may also be used for this.

Bump document date.

PR: 76333
Submitted by: Yoshihiko Sarumaru <mistral@imasy.or.jp>

15 years agoExtend channel definition with:
Sam Leffler [Tue, 27 Jan 2009 23:48:13 +0000 (23:48 +0000)]
Extend channel definition with:
o max antenna gain
o driver private opaque data

Note this grows the size of a channel to 16 bytes; which makes the
default channel table 4Kbytes (up from 3Kbytes).

15 years agofix comment
Sam Leffler [Tue, 27 Jan 2009 23:43:20 +0000 (23:43 +0000)]
fix comment

15 years agoRemove assumptions about the max # channels in ioctl's:
Sam Leffler [Tue, 27 Jan 2009 23:42:14 +0000 (23:42 +0000)]
Remove assumptions about the max # channels in ioctl's:
o change ioctl's that pass channel lists in/out to handle variable-size
  arrays instead of a fixed (compile-time) value; we do this in a way
  that maintains binary compatibility
o change ifconfig so all channel list data structures are now allocated
  to hold MAXCHAN entries (1536); this, for example, allows the kernel
  to return > IEEE80211_CHAN_MAX entries for calls like IEEE80211_IOC_DEVCAPS

15 years agochange ic_getradiocaps driver callback to include the max # channels
Sam Leffler [Tue, 27 Jan 2009 23:19:36 +0000 (23:19 +0000)]
change ic_getradiocaps driver callback to include the max # channels
so callers know the size of the array passed down

15 years agoo add country codes from Atheros regulatory; these are not listed in
Sam Leffler [Tue, 27 Jan 2009 23:09:55 +0000 (23:09 +0000)]
o add country codes from Atheros regulatory; these are not listed in
  the ISO tables, mark them accordingly
o add sku's for handling 900MHz cards
o add opaque struct defs and change []'s to *'s so this file can be
  included w/o requiring all of net80211 to be pulled in
o make CTRY_DEBUG and CTRY_DEFAULT public

15 years agoremove %b msg bit defines now public
Sam Leffler [Tue, 27 Jan 2009 23:01:14 +0000 (23:01 +0000)]
remove %b msg bit defines now public

15 years agoo make %b msg bit defines public (to user apps too)
Sam Leffler [Tue, 27 Jan 2009 23:00:38 +0000 (23:00 +0000)]
o make %b msg bit defines public (to user apps too)
o rename IEEE80211_C_CRYPTO_BITS to IEEE80211_CRYPTO_BITS

15 years agofill in ieee channel #'s and max tx power for drivers that work exclusively
Sam Leffler [Tue, 27 Jan 2009 22:48:46 +0000 (22:48 +0000)]
fill in ieee channel #'s and max tx power for drivers that work exclusively
with frequencies; this mimics how ieee80211_setregdomain works

15 years agoadd new state bit to indicate when interference is observed on the channel
Sam Leffler [Tue, 27 Jan 2009 22:46:34 +0000 (22:46 +0000)]
add new state bit to indicate when interference is observed on the channel

15 years agochange IEEE80211_IS_CHAN_OFDM and IEEE80211_IS_CHAN_CCK to return true
Sam Leffler [Tue, 27 Jan 2009 22:45:31 +0000 (22:45 +0000)]
change IEEE80211_IS_CHAN_OFDM and IEEE80211_IS_CHAN_CCK to return true
for 11g (dynamic CCK/OFDM)

15 years agodefine IEEE80211_CHAN_108A and IEEE80211_CHAN_108G in terms of their
Sam Leffler [Tue, 27 Jan 2009 22:43:32 +0000 (22:43 +0000)]
define IEEE80211_CHAN_108A and IEEE80211_CHAN_108G in terms of their
non-turbo names to make the relationship more clear

15 years agoBump .Dd for r187782.
Giorgos Keramidas [Tue, 27 Jan 2009 22:24:09 +0000 (22:24 +0000)]
Bump .Dd for r187782.

15 years agoupdate to 0.5.11: some useful bug fixes (check ChangeLog)
Sam Leffler [Tue, 27 Jan 2009 22:18:04 +0000 (22:18 +0000)]
update to 0.5.11: some useful bug fixes (check ChangeLog)

Submitted by: scf
MFC after: 3 weeks

15 years agoFollowing a fair amount of real world experience with ACLs and
Robert Watson [Tue, 27 Jan 2009 21:48:47 +0000 (21:48 +0000)]
Following a fair amount of real world experience with ACLs and
extended attributes since FreeBSD 5, make the following semantic
changes:

- Don't update the inode modification time (mtime) when extended
  attributes (and hence also ACLs) are added, modified, or removed.
- Don't update the inode access tie (atime) when extended attributes
  (and hence also ACLs) are queried.

This means that rsync (and related tools) won't improperly think
that the data in the file has changed when only the ACL has changed.

Note that ffs_reallocblks() has not been changed to not update on an
IO_EXT transaction, but currently EAs don't use the cluster write
routines so this shouldn't be a problem.  If EAs grow support for
clustering, then VOP_REALLOCBLKS() will need to grow a flag argument
to carry down IO_EXT to UFS.

MFC after: 1 week
PR:             ports/125739
Reported by:    Alexander Zagrebin <alexz@visp.ru>
Tested by:      pluknet <pluknet@gmail.com>,
                Greg Byshenk <freebsd@byshenk.net>
Discussed with: kib, kientzle, timur, Alexander Bokovoy <ab@samba.org>

15 years agofix printing of uint64_t values, so we can use WARNS=2
Luigi Rizzo [Tue, 27 Jan 2009 20:26:45 +0000 (20:26 +0000)]
fix printing of uint64_t values, so we can use WARNS=2

15 years agoWhen synchronizing the clock at system startup time, use both
Giorgos Keramidas [Tue, 27 Jan 2009 20:13:24 +0000 (20:13 +0000)]
When synchronizing the clock at system startup time, use both
the -g and -q options.  They do a slightly different thing and
both are necessary when the time difference is large.

Noticed by: danger, in the forums
Approved by: roberto
MFC after: 1 week

15 years agoFix the input buffer at 1024. The previous calculated buffer size
Nick Hibma [Tue, 27 Jan 2009 19:37:30 +0000 (19:37 +0000)]
Fix the input buffer at 1024. The previous calculated buffer size
exceeded the maximum size of 1 page for OHCI controllers. Other serial
drivers use the same size, so I assume this should be enough (1MB/s
throughput?).

15 years agofix wrong variable usage...
Luigi Rizzo [Tue, 27 Jan 2009 12:24:53 +0000 (12:24 +0000)]
fix wrong variable usage...

15 years agoPut nat and ipv6 support in their own files.
Luigi Rizzo [Tue, 27 Jan 2009 12:01:30 +0000 (12:01 +0000)]
Put nat and ipv6 support in their own files.

Usual moving of code with no changes from ipfw2.c to the
newly created files, and addition of prototypes to ipfw2.h

I have added forward declarations for ipfw_insn_* in ipfw2.h
to avoid a global dependency on ip_fw.h

15 years agoPut dummynet-related code in a separate file.
Luigi Rizzo [Tue, 27 Jan 2009 11:06:59 +0000 (11:06 +0000)]
Put dummynet-related code in a separate file.
To this purpose, add prototypes for global functions in ipfw2.h
and move there also the list of tokens used in various places in the code.

15 years agonever mind, for the time being let's stick with WARNS=0 until
Luigi Rizzo [Tue, 27 Jan 2009 11:03:47 +0000 (11:03 +0000)]
never mind, for the time being let's stick with WARNS=0 until
we sort out all proper printf formats.

15 years agoStart splitting the monster file in smaller blocks.
Luigi Rizzo [Tue, 27 Jan 2009 10:18:55 +0000 (10:18 +0000)]
Start splitting the monster file in smaller blocks.

In this episode:
- introduce a common header with a minimal set of common definitions;
- bring the main() function and options parser in main.c
- rename the main functions with an ipfw_ prefix

No code changes except for the introduction of a global variable,
resvd_set_number, which stores the RESVD_SET value from ip_fw.h
and is used to remove the dependency of main.c from ip_fw.h
(and the subtree of dependencies) for just a single constant.

15 years ago- Add support for Moxa Technologies CP-168EL/PCIe card.
Stanislav Sedov [Tue, 27 Jan 2009 09:38:44 +0000 (09:38 +0000)]
- Add support for Moxa Technologies CP-168EL/PCIe card.

Submitted by: dmarck
MFC after: 1 week

15 years agoput the usage() function inline, it was only 1 line and used once;
Luigi Rizzo [Tue, 27 Jan 2009 09:27:13 +0000 (09:27 +0000)]
put the usage() function inline, it was only 1 line and used once;
slightly reformat the help() text;
slightly correct the text for the 'extraneous filename' error message;

15 years agoput all options in a single struct, and document them.
Luigi Rizzo [Tue, 27 Jan 2009 09:06:25 +0000 (09:06 +0000)]
put all options in a single struct, and document them.

This will allow us to easily restore the original values when processing
commands from a file (where each individual line can have its own options).

15 years agoI believe this is safe to build with WARNS=2 now
Luigi Rizzo [Tue, 27 Jan 2009 09:04:29 +0000 (09:04 +0000)]
I believe this is safe to build with WARNS=2 now

15 years agoremove a couple of rarely used #define;
Luigi Rizzo [Tue, 27 Jan 2009 07:40:16 +0000 (07:40 +0000)]
remove a couple of rarely used #define;

change PRINT_UINT from a macro to a function (renaming is
postponed to reduce clutter)

15 years ago - Add support for nehalem/corei7 cpus. This supports all of the core
Jeff Roberson [Tue, 27 Jan 2009 07:29:37 +0000 (07:29 +0000)]
 - Add support for nehalem/corei7 cpus.  This supports all of the core
   counters defined in the reference manual.  It does not support the
   'uncore' events.

Reviewed by: jkoshy
Sponsored by: Nokia

15 years agoFollow up with previous commit: mention -D, not -C when cg check
Xin LI [Tue, 27 Jan 2009 00:29:19 +0000 (00:29 +0000)]
Follow up with previous commit: mention -D, not -C when cg check
failed.

Submitted by: obrien

15 years agos/use/using/ in previous commit.
Tom Rhodes [Tue, 27 Jan 2009 00:23:43 +0000 (00:23 +0000)]
s/use/using/ in previous commit.

Suggested by: jhb

15 years agoAdd ENOMEM to the return values.
Tom Rhodes [Tue, 27 Jan 2009 00:22:16 +0000 (00:22 +0000)]
Add ENOMEM to the return values.
Remove invalid return values.
Remove reference to non-existent manual pages.
Remove reference to rfork (it does not discuss RFSTOPPED).
Add sys/unistd.h to the list of includes (required for RFSTOPPED).

PR: 126227
Submitted by: Mateusz Guzik <mjguzik@gmail.com> (based on, original version)
Reviewed by: jhb, Christoph Mallon <christoph.mallon@gmx.de>

15 years agoRemove DETACH event handling; this is race prone and does nothing useful.
Sam Leffler [Mon, 26 Jan 2009 23:05:50 +0000 (23:05 +0000)]
Remove DETACH event handling; this is race prone and does nothing useful.
Leave a comment for the next person that thinks they need to be helpful.

Reviewed by: imp, jhb
MFC after: 2 weeks

15 years agoDelete commented out ancient history.
Warner Losh [Mon, 26 Jan 2009 21:45:33 +0000 (21:45 +0000)]
Delete commented out ancient history.

15 years agoClean up ng_ubt2. Get rid of excessive use of NG_NODE_REF/UNREF().
Maksim Yevmenkin [Mon, 26 Jan 2009 20:59:41 +0000 (20:59 +0000)]
Clean up ng_ubt2. Get rid of excessive use of NG_NODE_REF/UNREF().
Make detach() completely synchronous. Properly handle stalled USB
transfers (use internal mechanism instead of submitting own control
transfers). Rename/remove a couple of variables and update comments.
This work was done in close collaboration with HPS.

Reviewed by: HPS

15 years agoDon't unlock the parent ppc lock until after releasing the ppbus.
John Baldwin [Mon, 26 Jan 2009 20:58:05 +0000 (20:58 +0000)]
Don't unlock the parent ppc lock until after releasing the ppbus.

Submitted by: csjp

15 years agoMake the Monty Python quote more google friendly instead of
Tom Rhodes [Mon, 26 Jan 2009 18:14:21 +0000 (18:14 +0000)]
Make the Monty Python quote more google friendly instead of
hacking it apart.

Discussed with: Christoph Mallon <christoph.mallon@gmx.de>

15 years agoMFp4 //depot/projects/usb/ @156706
Andrew Thompson [Mon, 26 Jan 2009 17:55:07 +0000 (17:55 +0000)]
MFp4 //depot/projects/usb/ @156706

 Adjust an UHCI portreset delay.

Submitted by: Hans Petter Selasky

15 years agoRegen.
Andrew Thompson [Mon, 26 Jan 2009 17:50:20 +0000 (17:50 +0000)]
Regen.

15 years agoMFp4 //depot/projects/usb/ @156522,156530
Andrew Thompson [Mon, 26 Jan 2009 17:49:58 +0000 (17:49 +0000)]
MFp4 //depot/projects/usb/ @156522,156530

 UHCI SOF Quirk. Makes some broken USB devices work again.  Reported by several
 people. Patch made by me.

Submitted by: Hans Petter Selasky

15 years agoMFp4 //depot/projects/usb/ @156521
Andrew Thompson [Mon, 26 Jan 2009 17:47:32 +0000 (17:47 +0000)]
MFp4 //depot/projects/usb/ @156521

 U3G regression issue. Patch to support multiple modem instances per logical
 USB interface.

Submitted by: Hans Petter Selasky

15 years agoFix up USB_GET_REPORT_DESC ioctl.
Andrew Thompson [Mon, 26 Jan 2009 17:45:50 +0000 (17:45 +0000)]
Fix up USB_GET_REPORT_DESC ioctl.

Submitted by: daichi