Commit Graph

154262 Commits

Author SHA1 Message Date
Xin LI
36e60cda45 Remove GNU cpio after fix of CVE-2010-0624.
Note that this is actually a no-op for most users, as this GNU
cpio was broken on -HEAD and 8-STABLE since last March until
the recent fix.

FreeBSD 8.0+ uses BSD cpio by default and the code is being
actively maintained.

Blessed by:	kientzle
With hat:	secteam
MFC after:	3 days
2010-03-26 17:02:32 +00:00
Matt Jacob
670508b16a Clean up some printing stuff so that we can have a bit finer control
on debug output. Add a new platform function requirement to allow
for printing based upon the ITL nexus instead of the isp unit plus
channel, target and lun. This allows some printouts and error messages
from the core code to appear in the same format as the platform's
subsystem (in FreeBSD's case, CAM path).

MFC after:	1 week
2010-03-26 15:13:31 +00:00
Alexander Leidinger
2e2d757e51 Revert r205683 to resolve some code quality issues which do not affect the
build or use of linprocfs, before committing the reworked patch again.

Requested by:	des
2010-03-26 14:36:16 +00:00
Fabien Thomas
662cf71968 Handling SIGPIPE will cause deadlock/crash.
Return an error immediatly in case of hard shutdown.

MFC after: 3days
2010-03-26 14:35:48 +00:00
Fabien Thomas
75109b48f4 Do not overflow the term in the case of multi-line display.
MFC after: 3days
2010-03-26 14:29:57 +00:00
Dag-Erling Smørgrav
344523ac35 Tighten my grip on pseudofs, procfs, linprocfs. 2010-03-26 12:59:15 +00:00
Alexander Leidinger
6cdf931c46 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
2010-03-26 11:43:15 +00:00
Jaakko Heinonen
246b651054 Support only LOOKUP operation for "/" in relookup() because lookup()
can't succeed for CREATE, DELETE and RENAME.

Discussed with:	bde
2010-03-26 11:33:12 +00:00
Alexander Leidinger
2ac4d1f92f - add some usb devices (scanner, printer, usb storage)
- add quirks for the usb storage

Reviewed by:	hselasky
2010-03-26 11:02:01 +00:00
Alexander Motin
d542863e48 Use last 16 bytes of serial number in metadata instead of first ones,
same as Intel MatrixRAID does.

PR:		kern/124064
2010-03-26 10:18:19 +00:00
Alexander Leidinger
3fd1e05bab Fix a typo in a comment. 2010-03-26 08:47:07 +00:00
Alexander Leidinger
90782c0a14 Fix some problems which may lead to a panic:
- right order of src and dst in memcpy
 - NULL out the clips after freeing to prevent an accident

Noticed by:	hselasky
2010-03-26 08:42:11 +00:00
Neel Natu
bfd506a024 Replace sb_store64()/sb_load64() with mips3_sd()/mips3_ld() respectively.
Obtained from NetBSD.

Suggested by: jmallett@
2010-03-26 07:15:27 +00:00
Maxim Konovalov
16d1ba4f62 o Fix typo.
PR:		docs/145031
Submitted by:	olgeni
MFC after:	1 week
2010-03-26 05:35:25 +00:00
Maxim Konovalov
a787a4cbb1 o Trim leading w/space.
PR:		docs/145030
Submitted by:	olgeni
MFC after:	1 week
2010-03-26 05:34:13 +00:00
Marcel Moolenaar
f4926eabc2 Only use the interval timer for clock interrupts on the BSP and
have the BSP use IPIs to trigger clock interrupts on the APs.
This allows us to run on hardware configurations for which the
ITC has non-uniform frequencies across CPUs.

While here, change the clock XIV to type IPI so as to protect
the interrupt delivery against CPU re-balancing once that's
implemented.
2010-03-26 02:29:15 +00:00
Rick Macklem
7482701cd4 Patch the experimental NFS server in a manner analagous to r205661
for the regular NFS server, to ensure that ESTALE is
returned to the client for all errors returned by VFS_FHTOVP().

MFC after:	2 weeks
2010-03-26 01:35:19 +00:00
Xin LI
2561854d2b Our boot loader is capable of booting both i386 and amd64 kernels so
call it "x86" instead of "i386".

Suggested by:	jhb in response to Alexander Best's loader proposal
MFC after:	1 month
2010-03-26 01:30:53 +00:00
Rick Macklem
6cdfa1ce97 Patch the regular NFS server so that it returns ESTALE to the client
for all errors returned by VFS_FHTOVP(). This is required to ensure
that EIO doesn't get returned to the client when ZFS is used as the
server file system.

Tested by:	korvus AT comcast.net
Reviewed by:	jhb
MFC after:	2 weeks
2010-03-26 01:19:29 +00:00
Nathan Whitehorn
d4425a31a5 Fix the ia64 build.
Pointy hat to: me
2010-03-26 00:53:13 +00:00
Daniel Gerzo
2261a4056e - update zfs and zpool manual pages to match the current state of the source
PR:		144984
Submitted by:	mm@
Approved by:	pjd@
Obtained from:	OpenSolaris
MFC after:	4 days
2010-03-26 00:49:06 +00:00
Xin LI
d56cc55917 Check that gl_pathc is bigger than zero before derefencing gl_pathv.
When gl_pathc == 0, the content of gl_pathv is undefined.

PR:		bin/144761
Submitted by:	David BERARD <contact davidberard fr>
Obtained from:	OpenBSD
MFC after:	1 week
2010-03-25 22:41:01 +00:00
Xin LI
780179e871 The rmt client in GNU cpio could have a heap overflow when a malicious
remote tape service returns deliberately crafted packets containing
more data than requested.

Fix this by checking the returned amount of data and bail out when it
is more than what we requested.

PR:		gnu/145010
Submitted by:	naddy
Reviewed by:	imp
MFC after:	immediately
Security:	CVE-2010-0624
2010-03-25 20:02:54 +00:00
Jung-uk Kim
bb6ba5f6b9 Do not penalize correct or correctable VESA mode tables by calling another
VBE function.  Most problems should be corrected by the mode table sanity
check and we only need the paranoid in extremely rare cases.
2010-03-25 17:51:05 +00:00
Alan Cox
09fcdf114e A ptrace(2) by one processor may trigger a promotion in the address space
of another process.  Modify pmap_promote_pde() to handle this.  (This is
not a problem on amd64 due to implementation differences.)

Reported by:	jh@
MFC after:	1 week
2010-03-25 17:24:03 +00:00
Pyun YongHyeon
d2b6e9a0bc Use pci_get_max_read_req() and pci_set_max_read_req() to set maximim
read request size.
2010-03-25 17:17:35 +00:00
Jung-uk Kim
bfd026445f Revert accidentally committed initial real mode %sp change of r205347.
Note I am keeping %ds change because X.org int10 handler does it and
it seems reasonable.
2010-03-25 17:14:47 +00:00
Jung-uk Kim
d7312c88b4 Optimize real mode page table lookup. 2010-03-25 17:03:52 +00:00
Jung-uk Kim
ad51361a2c Fix stupid typos. Some VESA BIOSes directly call BIOS interrupt handlers
within the VBE interrupt handler.  Unfortunately it was causing real mode
page faults because we were fetching instructions from bogus addresses.
Pass me the pointyhat, please.

PR:		kern/144654
MFC after:	3 days
2010-03-25 15:56:04 +00:00
Nathan Whitehorn
a0ea661f5e Add the ELF relocation base to struct image_params. This will be
required to correctly relocate the executable entry point's function
descriptor on powerpc64.
2010-03-25 14:31:26 +00:00
Nathan Whitehorn
a107d8aac9 Change the arguments of exec_setregs() so that it receives a pointer
to the image_params struct instead of several members of that struct
individually. This makes it easier to expand its arguments in the future
without touching all platforms.

Reviewed by:	jhb
2010-03-25 14:24:00 +00:00
Nathan Whitehorn
920acedb80 Change the way text_addr and data_addr are computed to use the
executable status of segments instead of detecting the main text segment
by which segment contains the program entry point. This affects
obreak() and is required for correct operation of that function
on 64-bit PowerPC systems. The previous behavior was apparently
required only for the Alpha, which is no longer supported.

Reviewed by:	jhb
Tested on:	amd64, sparc64, powerpc
2010-03-25 14:21:22 +00:00
Alexander Leidinger
627693305a Propagate CONF_CFLAGS (from makeoptions) to the module build too.
Discussed with:	jhb (on arch@)
2010-03-25 13:47:21 +00:00
Bjoern A. Zeeb
d715e397f0 We are holding a write lock here so avoid aquiring it twice calling
the "locked" version rather than the wrapper function.

MFC after:	6 days
2010-03-25 10:29:00 +00:00
Gleb Smirnoff
cecdd23f87 Remove disabled code. In 99% cases exports are send to ng_ksocket(4), which
already forces queued mode, so what was suggested in disabled code is already
done.
2010-03-25 10:13:21 +00:00
Luigi Rizzo
c72c2330d0 fix another bug in "ipfw set N ..."
Submitted by:	Marcin Wisnicki
2010-03-24 23:06:16 +00:00
Warner Losh
ebbcc89c45 This broke when we went to gnu99 as the default standard. Fix the build
by reverting to the gnu89 standard.
2010-03-24 20:20:28 +00:00
Randall Stewart
ff014514ee Adds the option of keeping per-cpu statistics in SCTP. This
may be useful since it gets rid of atomics but I want it to
remain an option until I can do further testing on if it really
speeds things up.
2010-03-24 20:02:40 +00:00
Randall Stewart
7fa19ca6c1 lagging file I forgot to commit with my nr-sack fixes... opps
Reviewed by:	tuexen@freebsd.org
2010-03-24 20:01:14 +00:00
Randall Stewart
77acdc2565 Fix for NR-Sack code. The code was NOT working properly when
enabled. Basically most of the operations were incorrect causing
bad sacks when you enabled nr-sack. The fixes range across
4 files and unifiy most of the processing so that we only test
nr_sack flags to decide which type of sack to generate.

Optimization left for this is to combine the sack generation
code and make it capable of generating either sack thus shrinking
out a routine.

Reviewed by:	tuexen@freebsd.org
2010-03-24 19:45:36 +00:00
Bjoern A. Zeeb
2430ab4629 Print the pointer to the lock with the panic message. The previous
panic: rw lock not unlocked
was not really helpful for debugging. Now one can at least call
	show lock <ptr>
form ddb to learn more about the lock.

MFC after:	3 days
2010-03-24 19:21:26 +00:00
Xin LI
e56900fc9f Expose MACHINE_CPU while building lib32 target. 2010-03-24 18:40:57 +00:00
Luigi Rizzo
a9b8ae9a0c make the module loadable
Submitted by:	Marcin Wisnicki
2010-03-24 18:35:31 +00:00
Alexander Motin
a5be8eb530 Do not fetch precise time of request start when stats collection disabled.
Reviewed by:	pjd, phk
2010-03-24 18:04:25 +00:00
Shteryana Shopova
438be77d54 Now actually implement reading/refreshing/returning data from the pfTablesAddrTable
and modify the BEGEMOT-PF-MIB to add support for IPV6 address' statistics in the PF
tables via pfTablesAddrNetType and pfTablesAddrNet. While here, upgrade the
pf_tree.def file to the new format that includes enumerated values. Also make sure
to return SNMP_ERR_NOSUCHNAME for ALTQ objects, if ALTQ is disabled, so that the agent
will know to skip the pfAltq subtree when servicing GETNEXT requests from SNMP clients
(otherwise snmpwalk on begemotPf would stop at the pfAltq subtree with bsnmpd returning
SNMP_ERR_GENERR).
2010-03-24 16:07:33 +00:00
Pietro Cerutti
071ab531db - Remove const'ness from dlerror(3) prototype, for consistency with POSIX.
Approved by:	cognet
MFC after:	1 week
2010-03-24 15:59:51 +00:00
Jung-uk Kim
c2bce7cc39 Align memory access of 24-bit pixel renderer to word boundary. 2010-03-24 15:40:18 +00:00
Jung-uk Kim
1e161437f8 Teach VGA framebuffer about 8-bit palette format for VESA. 2010-03-24 15:37:47 +00:00
Luigi Rizzo
592a685e33 Honor ip.fw.one_pass when a packet comes out of a pipe without being delayed.
I forgot to handle this case when i did the mtag cleanup three months ago.

PR:		145004
2010-03-24 15:16:59 +00:00
Ed Schouten
192f4e2efc Prune empty directories. 2010-03-24 15:16:05 +00:00