]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
14 years agosh: Add test for some associativity in arithmetic.
jilles [Sun, 4 Apr 2010 16:29:48 +0000 (16:29 +0000)]
sh: Add test for some associativity in arithmetic.

14 years agoFix compilation error on amd64.
ume [Sun, 4 Apr 2010 15:21:09 +0000 (15:21 +0000)]
Fix compilation error on amd64.

Reported by: stefanf
MFC after: 2 weeks

14 years agoAdd missing MNT_NFS4ACLS.
jh [Sun, 4 Apr 2010 14:48:43 +0000 (14:48 +0000)]
Add missing MNT_NFS4ACLS.

14 years agoFix compilation error on 9-CURRENT.
ume [Sun, 4 Apr 2010 14:23:28 +0000 (14:23 +0000)]
Fix compilation error on 9-CURRENT.

Reported by: nyan
MFC after: 2 weeks

14 years agosh: Document the expansion changes in the man page.
jilles [Sun, 4 Apr 2010 13:17:05 +0000 (13:17 +0000)]
sh: Document the expansion changes in the man page.

Note that the following sentence
> Enclosing the full parameter expansion string in double-quotes does not
> cause the following four varieties of pattern characters to be quoted,
> whereas quoting characters within the braces has this effect.
is now true, but used to be incorrect.

14 years agoservices_mkdb; generate db file from services(5) to increase
ume [Sun, 4 Apr 2010 08:38:14 +0000 (08:38 +0000)]
services_mkdb; generate db file from services(5) to increase
speed of getserv*()

Obtained from: NetBSD
MFC after: 2 weeks

14 years agoAdd capability to use a db version of services. It is enabled by
ume [Sun, 4 Apr 2010 08:31:03 +0000 (08:31 +0000)]
Add capability to use a db version of services.  It is enabled by
specifying `db' as source of service in /etc/nsswitch.conf.

MFC after: 2 weeks

14 years agoReduce duplicate code.
ume [Sun, 4 Apr 2010 07:31:10 +0000 (07:31 +0000)]
Reduce duplicate code.

MFC after: 2 weeks

14 years agoTreat '+' as special only when in compat mode, and simplify
ume [Sun, 4 Apr 2010 07:21:45 +0000 (07:21 +0000)]
Treat '+' as special only when in compat mode, and simplify
the logic bit.

MFC after: 2 weeks

14 years agoStop adding trailing '\n'. The servent_unpack() doesn't expect
ume [Sun, 4 Apr 2010 07:02:10 +0000 (07:02 +0000)]
Stop adding trailing '\n'.  The servent_unpack() doesn't expect
lines terminated with '\n'.

MFC after: 2 weeks

14 years agoUse also SCTP/IPv6 checksum offloading in special cases.
tuexen [Sat, 3 Apr 2010 23:51:41 +0000 (23:51 +0000)]
Use also SCTP/IPv6 checksum offloading in special cases.

MFC after: 2 weeks

14 years agosh: Do tilde expansion in substitutions.
jilles [Sat, 3 Apr 2010 22:04:44 +0000 (22:04 +0000)]
sh: Do tilde expansion in substitutions.

This applies to word in ${v-word}, ${v+word}, ${v=word}, ${v?word} (which
inherits quoting from the outside) and in ${v%word}, ${v%%word}, ${v#word},
${v##word} (which does not inherit any quoting).

In all cases tilde expansion is only attempted at the start of word, even if
word contains spaces. This agrees with POSIX and other shells.

This is the last part of the patch tested in the exp-run.

Exp-run done by: erwin (with some other sh(1) changes)

14 years agosh: Fix duplicate variable name in test.
jilles [Sat, 3 Apr 2010 21:56:24 +0000 (21:56 +0000)]
sh: Fix duplicate variable name in test.

14 years agosh: Add some testcases for the working parts of tilde expansion.
jilles [Sat, 3 Apr 2010 21:32:22 +0000 (21:32 +0000)]
sh: Add some testcases for the working parts of tilde expansion.

14 years agosh: Allow quoting pattern match characters in ${v%pat} and ${v#pat}.
jilles [Sat, 3 Apr 2010 21:07:50 +0000 (21:07 +0000)]
sh: Allow quoting pattern match characters in ${v%pat} and ${v#pat}.

Note that this depends on r206145 for allowing pattern match characters to
have their special meaning inside a double-quoted expansion like "${v%pat}".

PR: bin/117748
Exp-run done by: erwin (with some other sh(1) changes)

14 years agosh: Remove special handling for ' and " in arithmetic.
jilles [Sat, 3 Apr 2010 21:01:01 +0000 (21:01 +0000)]
sh: Remove special handling for ' and " in arithmetic.
They will be treated like normal characters, resulting in a runtime
arithmetic expression error.

Exp-run done by: erwin (with some other sh(1) changes)

14 years agosh: Fix various things about expansions:
jilles [Sat, 3 Apr 2010 20:55:56 +0000 (20:55 +0000)]
sh: Fix various things about expansions:
* remove the backslash from \} inside double quotes inside +-=?
  substitutions, e.g. "${$+\}a}"
* maintain separate double-quote state for ${v#...} and ${v%...};
  single and double quotes are special inside, even in a double-quoted
  string or here document
* keep track of correct order of substitutions and arithmetic

This is different from dash's approach, which does not track individual
double quotes in the parser, trying to fix this up during expansion.
This treats single quotes inside "${v#...}" incorrectly, however.

This is similar to NetBSD's approach (as submitted in PR bin/57554), but
recognizes the difference between +-=? and #% substitutions hinted at in
POSIX and is more refined for arithmetic expansion and here documents.

PR: bin/57554
Exp-run done by: erwin (with some other sh(1) changes)

14 years agosh: Treat unexpected newlines in substitutions as a syntax error.
jilles [Sat, 3 Apr 2010 20:35:39 +0000 (20:35 +0000)]
sh: Treat unexpected newlines in substitutions as a syntax error.

The old approach was wrong because PS2 was not used and seems unlikely to
parse extensions (ksh93's ${ COMMAND} may well fail to parse).

Exp-run done by: erwin (with some other sh(1) changes)

14 years agosh: Add some testcases for the working parts of ${v%...} and ${v#...}.
jilles [Sat, 3 Apr 2010 20:14:10 +0000 (20:14 +0000)]
sh: Add some testcases for the working parts of ${v%...} and ${v#...}.

14 years agoMake _vm_map_init() the one place where the vm map's pmap field is
alc [Sat, 3 Apr 2010 19:07:05 +0000 (19:07 +0000)]
Make _vm_map_init() the one place where the vm map's pmap field is
initialized.

Reviewed by: kib

14 years agoJust use <stdint.h> instead of <inttypes.h>. We don't need it here.
ed [Sat, 3 Apr 2010 17:22:28 +0000 (17:22 +0000)]
Just use <stdint.h> instead of <inttypes.h>. We don't need it here.

14 years agoRe-enable the call to pmap_release() by vmspace_dofree(). The accounting
alc [Sat, 3 Apr 2010 16:20:22 +0000 (16:20 +0000)]
Re-enable the call to pmap_release() by vmspace_dofree().  The accounting
problem that is described in the comment has been addressed.

Submitted by: kib
Tested by: pho (a few months ago)
MFC after: 6 weeks

14 years ago* Fix some race condition in SACK/NR-SACK processing.
tuexen [Sat, 3 Apr 2010 15:40:14 +0000 (15:40 +0000)]
* Fix some race condition in SACK/NR-SACK processing.
* Fix handling of mapping arrays when draining mbufs or processing
  FORWARD-TSN chunks.
* Cleanup code (no duplicate code anymore for SACKs and NR-SACKs).
Part of this code was developed together with rrs.
MFC after: 2 weeks.

14 years agoAdd a forward declaration to silence a warning when compiling ia32_genassym.c.
bz [Sat, 3 Apr 2010 12:34:32 +0000 (12:34 +0000)]
Add a forward declaration to silence a warning when compiling ia32_genassym.c.

Reviewed by: kib
MFC after: 3 days

14 years agoFix some whitespace nits.
pjd [Sat, 3 Apr 2010 11:19:20 +0000 (11:19 +0000)]
Fix some whitespace nits.

14 years agoAdd missing mnt_kern_flag flags in 'show mount' output.
pjd [Sat, 3 Apr 2010 11:15:55 +0000 (11:15 +0000)]
Add missing mnt_kern_flag flags in 'show mount' output.

14 years agoBump PKG_INSTALL_VERSION to 20100403.
flz [Sat, 3 Apr 2010 10:57:13 +0000 (10:57 +0000)]
Bump PKG_INSTALL_VERSION to 20100403.

14 years agoFix pkg_delete, check if the file we're trying to delete is a
flz [Sat, 3 Apr 2010 10:55:11 +0000 (10:55 +0000)]
Fix pkg_delete, check if the file we're trying to delete is a
symlink before complaining that it doesn't exist. Typical case
would be a leftover library symlink that's left over after the
actual library has been removed.

Reported by: tabthorpe

14 years agog_vfs_open: allow only one mount per device vnode
avg [Sat, 3 Apr 2010 08:53:53 +0000 (08:53 +0000)]
g_vfs_open: allow only one mount per device vnode

In other words, deny multiple read-only mounts of the same device.
Shared read-only mounts should theoretically be possible, but,
unfortunately, can not be implemented correctly using current
buffer cache code/interface and results in an eventual system crash.
Also, using nullfs seems to be a more efficient way to achieve the same
goal.

This gets us back to where we were before GEOM and where other BSDs are.

Submitted by: pjd (idea for checking for shared mounting)
Discussed with: phk, pjd
Silence from: fs@, geom@
MFC after: 2 weeks

14 years agovn_stat: take into account va_blocksize when setting st_blksize
avg [Sat, 3 Apr 2010 08:39:00 +0000 (08:39 +0000)]
vn_stat: take into account va_blocksize when setting st_blksize

As currently st_blksize is always PAGE_SIZE, it is playing safe to not
use any smaller value.  For some cases this might not be optimal, but
at least nothing should get broken.

Generally I don't expect this commit to change much for the following
reasons (in case of VREG, VDIR):
- application I/O and physical I/O are sufficiently decoupled by
  filesystem code, buffer cache code, cluster and read-ahead logic
- not all applications use st_blksize as a hint, some use f_iosize, some
  use fixed block sizes

I expect writes to the middle of files on ZFS to benefit the most from
this change.

Silence from: fs@
MFC after: 2 weeks

14 years agoffs_mount: remove redundant assignment of geom consumer to devvp.v_bufobj
avg [Sat, 3 Apr 2010 08:25:04 +0000 (08:25 +0000)]
ffs_mount: remove redundant assignment of geom consumer to devvp.v_bufobj

The assignment is already done in g_vfs_open.
Redundant assignment is harmless, but can become a problem if g_vfs_open
logic is changed.

MFC after: 1 week

14 years agoKeep the list of default keywords sorted so that paranoid folks like me
yar [Sat, 3 Apr 2010 00:47:48 +0000 (00:47 +0000)]
Keep the list of default keywords sorted so that paranoid folks like me
don't try to find a hidden meaning in the strange order.  The list used
to be sorted in rev. 1.1 from 4.4BSD but the order was broken as soon as
in rev. 1.2 by a single-character fix.

MFC after: 3 days

14 years agoMerge ACPICA 20100331 (and four additional upstream patches).
jkim [Fri, 2 Apr 2010 23:04:31 +0000 (23:04 +0000)]
Merge ACPICA 20100331 (and four additional upstream patches).

14 years agoWith r205496 in place we should ensure that nargs and nreturns are always
marius [Fri, 2 Apr 2010 21:48:27 +0000 (21:48 +0000)]
With r205496 in place we should ensure that nargs and nreturns are always
set to sane values as they no longer default to 0, otherwise some OFW
implementation might copy in or out arguments not based on what the actual
function takes but what ever stack garbage nargs and nreturns supply.

Reviewed by: nwhitehorn

14 years agoNullify our periph pointer in dacleanup to try and catch
mjacob [Fri, 2 Apr 2010 20:08:44 +0000 (20:08 +0000)]
Nullify our periph pointer in dacleanup to try and catch
race conditions in callbacks/downcalls.

14 years agoFix a logic error in ipsec code that extracts
eri [Fri, 2 Apr 2010 18:15:23 +0000 (18:15 +0000)]
Fix a logic error in ipsec code that extracts
information from the packets.

Reviewed by: bz, mlaier
Approved by: mlaier(mentor)
MFC after: 1 month

14 years agoIncrease response queue size to avoid starvation, add a counter
np [Fri, 2 Apr 2010 17:50:52 +0000 (17:50 +0000)]
Increase response queue size to avoid starvation, add a counter
to track it when it does occur.

14 years agoindent.pro: replace a bunch of -T types with -ta introduced in r205989
avg [Fri, 2 Apr 2010 16:09:55 +0000 (16:09 +0000)]
indent.pro: replace a bunch of -T types with -ta introduced in r205989

Suggested by: bde, Hans Petter Selasky
MFC after: 10 days

14 years agoadd example indent.pro file believed to produce code with minimal differences from KNF
avg [Fri, 2 Apr 2010 16:06:46 +0000 (16:06 +0000)]
add example indent.pro file believed to produce code with minimal differences from KNF

This file is what bde uses!
With addition of some types from queue(3) by hps.
Please note that the output will not be KNF and currently it's not
possible to achieve correct KNF with any combination of options.
indent(1) needs to be made smarter.

Some issues:
o indent produces a space between a queue type macro and opening
  parenthesis
o indent produces a tab before __packed and __aligned
o indent produce a space after #define

bde also notes difference in the following options between this profile
and profile in /usr/src/admin/style of 4.4BSD:
-cdb -ei -ip8 -nsob

Also, NetBSD uses -di0 instead of -di8.

Location for the profile is suggested by jh.

Submitted by: Hans Petter Selasky (parts)
Obtained from: bde :-)
MFC after: 10 days
X-ToDo: make indent able to produce proper (perfect) KNF
X-Perhaps-ToDo: make KNF default output

14 years agomountmsdosfs: reject too high value of bytes per cluster
avg [Fri, 2 Apr 2010 15:22:23 +0000 (15:22 +0000)]
mountmsdosfs: reject too high value of bytes per cluster

Bytes per cluster are calcuated as bytes per sector times sectors per
cluster.  Too high value can overflow an internal variable with type
that can hold only values in valid range.  Trying to use a wider type
results in an attempt to read more than MAXBSIZE at once, a panic.
Unfortunately, it is FreeBSD newfs_msdos that  produces filesystems
with invalid parameters for certain types of media.

Reported by: Fabian Keil <freebsd-listen@fabiankeil.de>,
Paul B. Mahol <onemda@gmail.com>
Discussed with: bde, kib
MFC after: 1 week
X-ToDo: fix newfs_msdos

14 years agobo_bsize: revert r205860 and take an alternative approch in getblk
avg [Fri, 2 Apr 2010 15:12:31 +0000 (15:12 +0000)]
bo_bsize: revert r205860 and take an alternative approch in getblk

In r205860 I missed the fact that there is code that strongly assumes
that devvp bo_bsize is equal to underlying provider's sectorsize.
In those places it is hard to obtain the sectorsize in an alternative
way if devvp bo_bsize is set to something else.
So, I am reverting bo_bsize assigment in g_vfs_open.
Instead, in getblk I use DEV_BSIZE block size for b_offset calculation
if vp is a disk vp as reported by vn_isdisk.  This should coinside with
vp being a devvp.

Reported by: Mykola Dzham <i@levsha.me>
Tested by: Mykola Dzham <i@levsha.me>
Pointyhat to: avg
MFC after: 2 weeks
X-ToDo: convert bread(devvp) in all fs to use bo_bsize-d blocks

14 years agoProperly initialize the timestamp when using ac -w.
ed [Fri, 2 Apr 2010 14:30:56 +0000 (14:30 +0000)]
Properly initialize the timestamp when using ac -w.

When using ac -w, we must use the last timestamp to terminate the log
file. I accidentally removed this when I ported the code to use utmpx.

Reported by: avg

14 years agoSupply default implementation of VOP_RENAME() that does neccessary
kib [Fri, 2 Apr 2010 14:03:43 +0000 (14:03 +0000)]
Supply default implementation of VOP_RENAME() that does neccessary
unlocks and unreferences for argument vnodes, as expected by
kern_renameat(9), and returns EOPNOTSUPP. This fixes locks and
reference leaks when rename is attempted on fs that does not
implement rename.

PR: kern/107439
Based on submission by: Mikolaj Golub <to.my.trociny gmail com>
Tested by: Mikolaj Golub
MFC after: 1 week

14 years agoAdd function vop_rename_fail(9) that performs needed cleanup for locks
kib [Fri, 2 Apr 2010 14:03:01 +0000 (14:03 +0000)]
Add function vop_rename_fail(9) that performs needed cleanup for locks
and references of the VOP_RENAME(9) arguments. Use vop_rename_fail()
in deadfs_rename().

Tested by: Mikolaj Golub
MFC after: 1 week

14 years agoImprove "top" header by:
fabient [Fri, 2 Apr 2010 13:34:28 +0000 (13:34 +0000)]
Improve "top" header by:
- Display sample received per PMCs (or merged PMCs).
- Display percentage vs all samples

14 years ago- Support for uncore counting events: one fixed PMC with the uncore
fabient [Fri, 2 Apr 2010 13:23:49 +0000 (13:23 +0000)]
- Support for uncore counting events: one fixed PMC with the uncore
  domain clock, 8 programmable PMC.
- Westmere based CPU (Xeon 5600, Corei7 980X) support.
- New man pages with events list for core and uncore.
- Updated Corei7 events with Intel 253669-033US December 2009 doc.
  There is some removed events in the documentation, they have been
  kept in the code but documented in the man page as obsolete.
- Offcore response events can be setup with rsp token.

Sponsored by: NETASQ

14 years agoChange how getent utmpx works.
ed [Fri, 2 Apr 2010 11:05:59 +0000 (11:05 +0000)]
Change how getent utmpx works.

- Always require active, log or lastlogin to be provided.
- Allow the user to provide custom filenames.

14 years ago- Try do deal gracefully with correctable ECC errors.
marius [Fri, 2 Apr 2010 10:36:40 +0000 (10:36 +0000)]
- Try do deal gracefully with correctable ECC errors.
- Improve the reporting of unhandled kernel and user traps.

14 years agoWITH_CTF can now be specified in src.conf (not recommended, there
netchild [Fri, 2 Apr 2010 06:55:31 +0000 (06:55 +0000)]
WITH_CTF can now be specified in src.conf (not recommended, there
are some problems with static executables), make.conf (would also
affect ports which do not use GNU make and do not override the
compile targets) or in the kernel config (via "makeoptions
WITH_CTF=yes").

Additional (related) changes:
 - propagate WITH_CTF to module builds
 - do not add -g to the linker flags, it's a noop there anyway
   (at least according to the man page of ld)
 - do not add -g to CFLAGS unconditionally
   we need to have a look if it is really needed (IMO not) or if there
   is a way to add it only when WITH_CTF is used

Note: ctfconvert / ctfmerge lines will not appear in the build output,
to protect the innocent (those which do not build with WITH_CTF would
see the shell-test and may think WITH_CTF is used).

Reviewed by: imp, jhb, scottl (earlier version)
Discussed on: arch@

14 years agoRe-apply r205683 with some modifications:
netchild [Fri, 2 Apr 2010 06:50:28 +0000 (06:50 +0000)]
Re-apply r205683 with some modifications:
  Fix some bogus values in linprocfs.

  Submitted by: Petr Salinger <Petr.Salinger@seznam.cz>
  Verified on: GNU/kFreeBSD debian 8.0-1-686 (by submitter)
  PR: 144584

Reviewed by / discussed with: kib, des, jhb, submitter

14 years agoFor the experimental NFS server, add a call to free the lookup
rmacklem [Fri, 2 Apr 2010 02:19:28 +0000 (02:19 +0000)]
For the experimental NFS server, add a call to free the lookup
path buffer for one case where it was missing when doing mkdir.
This could have conceivably resulted in a leak of a buffer, but
a leak was never observed during testing, so I suspect it would
have occurred rarely, if ever, in practice.

MFC after: 2 weeks

14 years agoAdd SAVENAME to the cn_flags for all cases in the experimental
rmacklem [Fri, 2 Apr 2010 01:53:48 +0000 (01:53 +0000)]
Add SAVENAME to the cn_flags for all cases in the experimental
NFS server for the CREATE cn_nameiop where SAVESTART isn't set.
I was not aware that this needed to be done by the caller until
recently.

Tested by: lampa AT fit.vutbr.cz (link case)
Submitted by: lampa AT fit.vutbr.cz (link case)
MFC after: 2 weeks

14 years agoRemove _LARGEFILE64_SOURCE==1 case which is supposed to be always false
delphij [Thu, 1 Apr 2010 22:52:09 +0000 (22:52 +0000)]
Remove _LARGEFILE64_SOURCE==1 case which is supposed to be always false
on FreeBSD.

Pointed out by: dougb

14 years agoFor now, hardcode FreeBSD configuration that will never change on zlib.h:
delphij [Thu, 1 Apr 2010 21:21:45 +0000 (21:21 +0000)]
For now, hardcode FreeBSD configuration that will never change on zlib.h:

unifdef -D_FILE_OFFSET_BITS=64 -U_LFS64_LARGEFILE -U_LARGEFILE64_SOURCE

14 years agoSpecify the parameter in the format_k2 prototype.
brucec [Thu, 1 Apr 2010 21:20:19 +0000 (21:20 +0000)]
Specify the parameter in the format_k2 prototype.
This fixes top on ARM, which assumes that format_k2 takes an int.

Approved by: rrs (mentor)

14 years agoOops! Wrong copy-paste in r206053.
mav [Thu, 1 Apr 2010 19:05:43 +0000 (19:05 +0000)]
Oops! Wrong copy-paste in r206053.

14 years agoFill extended ATA command registers in cPRD to support 48bit commands.
mav [Thu, 1 Apr 2010 18:17:53 +0000 (18:17 +0000)]
Fill extended ATA command registers in cPRD to support 48bit commands.

14 years agoWe don't need to note that mkproto is missing anymore. It is
imp [Thu, 1 Apr 2010 17:04:37 +0000 (17:04 +0000)]
We don't need to note that mkproto is missing anymore.  It is
definitely OBE in a number of ways, and likely should have been
removed in 2000, not 2010.

14 years agoIOCPARM_MAX defines maximum size of a structure that can be passed
pjd [Thu, 1 Apr 2010 16:21:35 +0000 (16:21 +0000)]
IOCPARM_MAX defines maximum size of a structure that can be passed
directly to ioctl(2). Because of how ioctl command is build using _IO*()
macros we have only 13 bits to encode structure size. So the structure
can be up to 8kB-1.

Currently we define IOCPARM_MAX as PAGE_SIZE.

This is IMHO wrong for three main reasons:

1. It is confusing on archs with page size larger than 8kB (not really
   sure if we support such archs (sparc64?)), as even if PAGE_SIZE is
   bigger than 8kB, we won't be able to encode anything larger in ioctl
   command.

2. It is a waste. Why the structure can be only 4kB on most archs if we
   have 13 bits dedicated for that, not 12?

3. It shouldn't depend on architecture and page size. My ioctl command
   can work on one arch, but can't on the other?

Increase IOCPARM_MAX to 8kB and make it independed of PAGE_SIZE and
architecture it is compiled for. This allows to use all the bits on all the
archs for size. Note that this doesn't mean we will copy more on every ioctl(2)
call. No. We still copyin(9)/copyout(9) only exact number of bytes encoded in
ioctl command.

Practical use for this change is ZFS. zfs_cmd_t structure used for ZFS
ioctls is larger than 4kB.

Silence on: arch@
MFC after: 1 month

14 years agoRemove alignment constraints.
mav [Thu, 1 Apr 2010 16:20:36 +0000 (16:20 +0000)]
Remove alignment constraints.

14 years agoRemove alignment constraints.
mav [Thu, 1 Apr 2010 16:18:16 +0000 (16:18 +0000)]
Remove alignment constraints.

14 years agoRegenerate manual pages for OpenSSL 0.9.8n.
simon [Thu, 1 Apr 2010 15:37:38 +0000 (15:37 +0000)]
Regenerate manual pages for OpenSSL 0.9.8n.

14 years ago- Make it slightly simpler to update OpenSSL version information
simon [Thu, 1 Apr 2010 15:35:29 +0000 (15:35 +0000)]
- Make it slightly simpler to update OpenSSL version information
  for regenerating OpenSSL manual pages.
- Explicitly set the OpenSSL release date so manual pages contain
  the date OpenSSL was released and not just the date OpenSSL was
  imported into the FreeBSD base system.
- Update for Makefile for OpenSSL 0.9.8n.

14 years agoMerge OpenSSL 0.9.8n into head.
simon [Thu, 1 Apr 2010 15:19:51 +0000 (15:19 +0000)]
Merge OpenSSL 0.9.8n into head.

This fixes CVE-2010-0740 which only affected -CURRENT (OpenSSL 0.9.8m)
but not -STABLE branches.

I have not yet been able to find out if CVE-2010-0433 impacts FreeBSD.
This will be investigated further.

Security: CVE-2010-0433, CVE-2010-0740
Security: http://www.openssl.org/news/secadv_20100324.txt

14 years agoVarious fixes.
flz [Thu, 1 Apr 2010 14:27:29 +0000 (14:27 +0000)]
Various fixes.

- Replace hardcoded INDEX version. [1]
- Fix a buffer overlap. [2]
- Remove empty package when fetching fails and -K is used. [3]
- Remove useless chmod2() after mkdtemp(3). [4]
- Replace mkdir(1) call with mkdir(2). [5]
- Get rid of some vsystem() calls.
- Switch from lstat(2) to open(2) in fexists().
- Try rename(2) in move_file() first.
- Bump PKG_INSTALL_VERSION to 20100401.

PR: bin/145101 [1], bin/139492 [2], bin/144919 [3]
bin/144920 [4], bin/144921 [5]
Submitted by: gcooper [1,2,3,4,5]

14 years agoForgot to initialize the debug variable.
des [Thu, 1 Apr 2010 13:16:32 +0000 (13:16 +0000)]
Forgot to initialize the debug variable.

MFC after: 2 weeks

14 years agoAdd -k to the recommended fingerd(8) command line.
des [Thu, 1 Apr 2010 13:13:09 +0000 (13:13 +0000)]
Add -k to the recommended fingerd(8) command line.

MFC after: 2 weeks

14 years agoAdd a debugging option (-d)
des [Thu, 1 Apr 2010 13:11:39 +0000 (13:11 +0000)]
Add a debugging option (-d)
Add a -k option which fingerd(8) passes through to finger(1).

MFC after: 2 weeks

14 years ago- Add my birthday to the calendar
decke [Thu, 1 Apr 2010 12:26:29 +0000 (12:26 +0000)]
- Add my birthday to the calendar

Approved by: miwi (mentor), beat (co-mentor)

14 years ago- Add myself to the ports committer list
decke [Thu, 1 Apr 2010 12:18:44 +0000 (12:18 +0000)]
- Add myself to the ports committer list

Approved by: miwi (mentor), beat (co-mentor)

14 years agoFix the gap between mute and lowest possible volume. The es1370 mixer
joel [Thu, 1 Apr 2010 11:30:46 +0000 (11:30 +0000)]
Fix the gap between mute and lowest possible volume. The es1370 mixer
volumes were incorrectly calculated.

I've tested this with one of my es1370 cards and I can confirm that it
works.

PR: 98167
Submitted by: Joseph Terner <jtsn@gmx.de>
Approved by: kib

14 years agoRemove alignment constraints.
mav [Thu, 1 Apr 2010 10:41:01 +0000 (10:41 +0000)]
Remove alignment constraints.

14 years agoAdd a couple missing basic mode page codes.
mjacob [Thu, 1 Apr 2010 01:49:43 +0000 (01:49 +0000)]
Add a couple missing basic mode page codes.

MFC after: 1 week

14 years agoThe ALQ should not be considered drained until it has been made inactive.
lstewart [Thu, 1 Apr 2010 01:27:10 +0000 (01:27 +0000)]
The ALQ should not be considered drained until it has been made inactive.

Sponsored by: FreeBSD Foundation
Reviewed by: dwmalone, jeff, rpaulo, rwatson (as part of a larger patch)
Approved by: kmacy (mentor)
MFC after: 1 month

14 years agoAccording to SLEEP(9), msleep() is deprecated in favour of mtx_sleep().
lstewart [Thu, 1 Apr 2010 01:23:36 +0000 (01:23 +0000)]
According to SLEEP(9), msleep() is deprecated in favour of mtx_sleep().

Sponsored by: FreeBSD Foundation
Reviewed by: dwmalone, jeff, rpaulo, rwatson (as part of a larger patch)
Approved by: kmacy (mentor)
MFC after: 1 month

14 years ago- Factor code to destroy an ALQ out of alq_close() into a private alq_destroy().
lstewart [Thu, 1 Apr 2010 01:16:00 +0000 (01:16 +0000)]
- Factor code to destroy an ALQ out of alq_close() into a private alq_destroy().

- Use the new alq_destroy() to properly handle a failure case in alq_open().

Sponsored by: FreeBSD Foundation
Reviewed by: dwmalone, jeff, rpaulo, rwatson (as part of a larger patch)
Approved by: kmacy (mentor)
MFC after: 1 month

14 years agoThe POLL code was missed in the queue conversion,
jfv [Wed, 31 Mar 2010 23:24:42 +0000 (23:24 +0000)]
The POLL code was missed in the queue conversion,
change the argument type to igb_rxeof() to the
correct type. Note, any users of POLLING must
be sure and set the number of queues to 1 for
things to work correctly.

14 years agoAdd definition of IPv6 mobility header's protocol number, as assigned by
delphij [Wed, 31 Mar 2010 23:02:25 +0000 (23:02 +0000)]
Add definition of IPv6 mobility header's protocol number, as assigned by
IANA and defined in RFC 3775.

Obtained from: KAME

14 years agoRemove some more alignment constraints.
mav [Wed, 31 Mar 2010 22:47:55 +0000 (22:47 +0000)]
Remove some more alignment constraints.

14 years agoUse device_get_nameunit(9) rather than device_get_name(9) so one can
marius [Wed, 31 Mar 2010 22:32:56 +0000 (22:32 +0000)]
Use device_get_nameunit(9) rather than device_get_name(9) so one can
identify the reporting bridge in machines with multiple PCI domains.

14 years agoDon't re-implement device_get_nameunit(9).
marius [Wed, 31 Mar 2010 22:27:33 +0000 (22:27 +0000)]
Don't re-implement device_get_nameunit(9).

14 years ago- Take advantage of the INTCLR_* macros.
marius [Wed, 31 Mar 2010 22:19:00 +0000 (22:19 +0000)]
- Take advantage of the INTCLR_* macros.
- Right-justify the backslashes as per style(9).

14 years agoMake ng_ksocket fulfill lower protocol stack layers alignment requirements
mav [Wed, 31 Mar 2010 22:16:05 +0000 (22:16 +0000)]
Make ng_ksocket fulfill lower protocol stack layers alignment requirements
on platforms with strict alignment constraints.
This fixes kernel panics on arm and probably other architectures.

PR: sparc64/80410

14 years agoMake ng_l2tp irrelevant to data alignment.
mav [Wed, 31 Mar 2010 22:11:06 +0000 (22:11 +0000)]
Make ng_l2tp irrelevant to data alignment.

14 years agoUpdate to 1.2.4.1 (beta).
delphij [Wed, 31 Mar 2010 20:55:13 +0000 (20:55 +0000)]
Update to 1.2.4.1 (beta).

14 years agoHook the identification LEDs of igb(4), lem(4) and em(4) devices up with
marius [Wed, 31 Mar 2010 20:43:24 +0000 (20:43 +0000)]
Hook the identification LEDs of igb(4), lem(4) and em(4) devices up with
led(4) so they can be lit or f.e. made blink via `echo f2 > /dev/led/em0`
for localization purposes.

Approved by: jfv
MFC afer: 1 week (after r205869)

14 years agoMake ng_ppp fulfill upper protocol stack layers alignment requirements
mav [Wed, 31 Mar 2010 20:37:44 +0000 (20:37 +0000)]
Make ng_ppp fulfill upper protocol stack layers alignment requirements
on platforms with strict alignment constraints.
This fixes kernel panics on arm and probably other architectures.

PR: sparc64/80410

14 years agong_gif depends on gif.
mav [Wed, 31 Mar 2010 20:15:20 +0000 (20:15 +0000)]
ng_gif depends on gif.

14 years agoIf there is multiple PMCs for the same interrupt ignore new post.
fabient [Wed, 31 Mar 2010 20:00:44 +0000 (20:00 +0000)]
If there is multiple PMCs for the same interrupt ignore new post.
This will indirectly fix a bug where the thread will be pinned
forever if the assert is not compiled.

MFC after: 3days

14 years agoAdd prototype for libc internal interfaces.
delphij [Wed, 31 Mar 2010 18:37:00 +0000 (18:37 +0000)]
Add prototype for libc internal interfaces.

14 years agoAdd prototypes for libc private interfaces.
delphij [Wed, 31 Mar 2010 18:36:04 +0000 (18:36 +0000)]
Add prototypes for libc private interfaces.

While I'm there, apply __unused whenever appropriate.

Reviewed by: md5(1)

14 years agoSync fortunes with other *BSDs
uqs [Wed, 31 Mar 2010 18:21:25 +0000 (18:21 +0000)]
Sync fortunes with other *BSDs

- Spelling errors
- Typographical fixes
- Consistent attributions
- Use Jr. more consistently
- Capitalization of dictionary-like entries
- Sorting using tools/do_sort
- Remove duplicate fortunes
- Style according to the Notes file
- Reflect correct default fortune name in Notes
- Remove some no longer needed spelling hints
- Drop latin1 characters (sorry MÃ¥rten)

This is a partial sync against the DragonflyBSD sources, where a lot of
fixes from Free, Net and OpenBSD were merged previously. Only about 50%
of the changes originate from there, the rest was done by dougb and
yours truly.

Partial review by: wilko (earlier version), ed (dito)
In collaboration with: dougb
Approved by: ed (co-mentor)

14 years agoTwo fixes:
imp [Wed, 31 Mar 2010 18:18:37 +0000 (18:18 +0000)]
Two fixes:

(1) We don't need a custom install_kernel.  We can install without
symbols by adding INSTALL_NODEBUG (which likely should be
WITHOUT_KERNEL_SYMBOLS_FILE, or something shorter) to CONF_INSTALL
(2) for make buildenv stage, use NANO_MAKE_CONF_BUILD rather than the
non-existant NANO_MAKE_CONF.

MFC after: 7 days

14 years agoFor unhandled actions in xpt_action_default, remember to call
mjacob [Wed, 31 Mar 2010 17:47:57 +0000 (17:47 +0000)]
For unhandled actions in xpt_action_default, remember to call
xpt_done for queued requests. This solves the problem of
indefinite hangs for unspecified transports when XPT_SCAN_BUS
is called.

A few minor cosmetics elsewhere.

MFC after: 1 week

14 years agoMake -r mean exactly the same thing as -E for increased compatibility
imp [Wed, 31 Mar 2010 17:40:13 +0000 (17:40 +0000)]
Make -r mean exactly the same thing as -E for increased compatibility
with GNU sed.

MFC after: 7 days

14 years agoindent(1): add a new option, -ta, to treat all *_t identifiers as types
avg [Wed, 31 Mar 2010 17:05:30 +0000 (17:05 +0000)]
indent(1): add a new option, -ta, to treat all *_t identifiers as types

Submitted by: Hans Petter Selasky
Discussed with: bde
MFC after: 10 days

14 years agoindent(1): correctly handle case/label at the very start of a function
avg [Wed, 31 Mar 2010 16:55:47 +0000 (16:55 +0000)]
indent(1): correctly handle case/label at the very start of a function

Obtained from: NetBSD (rev. 1.11 of indent.c)
MFC after: 1 week

14 years agoFix poll handler declaration.
jfv [Wed, 31 Mar 2010 16:42:22 +0000 (16:42 +0000)]
Fix poll handler declaration.

14 years agoConstify vap argument of ieee80211_{note,discard}* functions.
rpaulo [Wed, 31 Mar 2010 16:07:36 +0000 (16:07 +0000)]
Constify vap argument of ieee80211_{note,discard}* functions.

MFC after: 1 week

14 years agoStop hard coding i386 as the arch for the build. Instead, default to the
imp [Wed, 31 Mar 2010 14:42:07 +0000 (14:42 +0000)]
Stop hard coding i386 as the arch for the build.  Instead, default to the
processor we're running on.  Also, supply amd64 version of create_diskimage
that's the same as i386's.

# didn't fix the confusion between using the processor for this and using
# the machine (which would be more appropriate).  NANO_ARCH smashes the two
# together right now.

MFC after: 7 days