Commit Graph

113908 Commits

Author SHA1 Message Date
Sam Leffler
f6ef5ddaa4 correct logic so we recognize timeout on alloc
Noticed by:	Coverity Prevent analysis tool
2005-03-26 23:43:54 +00:00
Sam Leffler
83888a7f30 purge dead code
Noticed by:	Coverity Prevent analysis tool
2005-03-26 23:37:54 +00:00
Sam Leffler
52c94c38dc deal with malloc failure when setting up the multicast filter
Noticed by:	Coverity Prevent analysis tool
2005-03-26 23:26:49 +00:00
Sam Leffler
af5691cdd5 handle malloc failure and sk_vpd_prodname potentially being null for
other reasons

Noticed by:	Coverity Prevent analysis tool
Reviewed by:	bz, jmg
2005-03-26 22:57:28 +00:00
Sam Leffler
5309f84168 deal with malloc failures
Noticed by:	Coverity Prevent analysis tool
Together with:	mdodd
2005-03-26 22:20:22 +00:00
John-Mark Gurney
1a82818b98 fix a copy/paste typo for scanner/gameport...
Spotted by:	Michal Mertl <mime@traveller.cz>
2005-03-26 22:17:48 +00:00
Poul-Henning Kamp
23db907c0f Don't call mlx_free() i mlx_attach() in case of failure. Doing so
in mlx_attach_pci() is much cleaner.

Inspired by:	Coverity
2005-03-26 21:58:09 +00:00
Sam Leffler
7a7fa27b23 rt_newaddrmsg will blow up if given something other than RTM_ADD
or RTM_DELETE; add an assertion, may want to do something more
heavyhanded in the future

Noticed by:	Coverity Prevent analysis tool
Reviewed by:	mdodd
2005-03-26 21:49:43 +00:00
Sam Leffler
2f83086184 deal with malloc failure
Noticed by:	Coverity Prevent analysis tool
2005-03-26 21:34:12 +00:00
Sam Leffler
4204b6b9a0 deal with failed malloc calls
Noticed by:	Coverity Prevent analysis tool
Glanced at by:	mdodd
2005-03-26 21:30:49 +00:00
Poul-Henning Kamp
9bb329f4e5 fix a "modify after free" bug which is practically impossible to
experience.

Found by:	Coverity (id #540 #541)
2005-03-26 21:07:35 +00:00
John-Mark Gurney
4ea3b0e7e2 add some additional pci classes and sub-classes..
Reviewed by:	imp (almost 6 months ago)
2005-03-26 20:31:09 +00:00
Ruslan Ermilov
77d23c9bc3 xl(4) meets polling(4). Hardware for this work kindly provided by
Eric Masson.

MFC after:	3 weeks
2005-03-26 20:22:58 +00:00
Poul-Henning Kamp
4a650cc291 Make (some) serial ports implement the PPS-API again. This change
appearantly fell out during the tty code cleanup.
2005-03-26 20:12:39 +00:00
Colin Percival
c0be525bed netstart is now obsoleted by /etc/rc.d/*, not by /etc/rc.network.
Reported by:	Martin Jakob, on freebsd-stable@
MFC after:	1 month
2005-03-26 20:10:24 +00:00
Poul-Henning Kamp
f83856243d s/ENOTTY/ENOIOCTL/ 2005-03-26 20:04:28 +00:00
Sam Leffler
2307fc820c deref correct mbuf ptr to collect any vlan tag
Noticed by:	Coverity Prevent analysis tool
2005-03-26 18:47:17 +00:00
Sam Leffler
05aabdfcf1 eliminate double free when sym_cam_attach fails
Noticed by:	Coverity Prevent analysis tool
2005-03-26 18:17:58 +00:00
Sam Leffler
ca640ca965 check copyin return values when loading pallete
Noticed by:	Coverity Prevent analysis tool
2005-03-26 18:01:35 +00:00
Nate Lawson
55fa5feab7 Check for invalid frequencies after parsing the package. Keep a running
count of valid frequencies and use that as the final package count, don't
give up when the first invalid state is found.  Also, add 0x9999 and expand
our upper check to >= 0xffff Mhz [2].

Submitted by:	Bruno Ducrot, Jung-uk Kim [2]
2005-03-26 17:30:34 +00:00
Pawel Jakub Dawidek
34cb151796 If an error occurs, clean up before returning from g_raid3_connect_disk(). 2005-03-26 17:24:19 +00:00
Pawel Jakub Dawidek
c2ca10933d Make the code more obvious - when an error occurs in g_mirror_connect_disk(),
detach and destroy consumer before returning.
2005-03-26 17:23:01 +00:00
Pawel Jakub Dawidek
cc6aa917b9 Check for return values.
Submitted by:	sam
Found by:	Coverity Prevent analysis tool
2005-03-26 16:51:19 +00:00
Xin LI
a431ada687 Do not do write gathering for NFSv3, since it makes no sense unless
the client is broken and does sync writes all the time.

Obtained from:	NetBSD (sys/nfs/nfs_syscalls.c,v 1.44)
Reviewed by:	-arch (bde)
2005-03-26 11:29:02 +00:00
David Schultz
b4a12fe13b Teach libstdc++ about frexpl() and ldexpl(). 2005-03-26 08:27:53 +00:00
Sam Leffler
c9a4bb99b0 when WPA is enabled discard association requests w/o a WPA ie
Submitted by:	Divy Le Ray
2005-03-26 07:15:34 +00:00
Sam Leffler
d6ec172c3a don't include wme ie in probe request frames; it was meant for probe response
frames--move it there

Noticed by:	Ghislain Mary
Submitted by:	Michael Wong
2005-03-26 07:11:31 +00:00
Kenneth D. Merry
53372d3a6d Fix a problem with the cd(4) driver -- the CAMGETPASSTHRU ioctl wouldn't
succeed if there was no media in the drive.

This was broken in rev 1.72 when the media check was added to cdioctl().

For now, check the ioctl group to decide whether to check for media or not.
(We only need to check for media on CD-specific ioctls.)

Reported by:	bland
MFC after:	3 days
2005-03-26 06:05:06 +00:00
Kenneth D. Merry
e9e4d3e4d4 Add "report only" functionality to 'camcontrol format', so users can get a
report on the status of a format already running on a drive.

Fix status reporting for 'camcontrol format'.  This was broken in rev 1.34
of camcontrol.c, almost 4 years ago!

Submitted by:	joerg (most of the reportonly changes)
MFC after:	3 days
2005-03-26 05:34:54 +00:00
Colin Percival
6e34b4796d When executing mount_foo, pass "mount_foo" as argv[0] instead of "foo".
This unbreaks "/rescue/mount -t foo" -- previously it was necessary to
explicitly call "/rescue/mount_foo".

Hints from:	gordon
X-MFC after:	3 days (if approved by re@)
2005-03-26 04:45:53 +00:00
Kenneth D. Merry
b3b73720f2 Fix a place where we were referencing a pointer after it had been freed.
Submitted by:	"Henry Miller" <hank@blackhole.com>
MFC after:	3 days
2005-03-26 04:21:11 +00:00
Brooks Davis
6c6faad6dd Remove bogus (but harmless) -I.. from CFLAGS. It makes no difference to
.depends other then the commant line.

Also remove -g from CFLAGS.  The user should add it to CFLAGS if they
desire debug support.

Reviewed by:	ru (in concept)
MFC After:	7 days
2005-03-25 22:08:59 +00:00
Maxim Sobolev
e33b116b78 Comment out rue_miibus_statchg() function. Using trial-and-error approach I
found it guilty in putting the card into unusable state after UP->DOWN->UP
media status change.

Looks like some of register writes in this functions mess up PHY interface.

No visible regressions has been found after commenting this code out -
the card properly handles forceful local mode changes and auto-detects changes
made remotely (tested with Auto, 10HD, 10FD, 100HD, 100FD).

Sponsored by:	PBXpress Inc.
MFC after:	3 days
2005-03-25 20:19:18 +00:00
David Schultz
188f6433f6 When the softupdates worklist gets too long, threads that attempt to
add more work are forced to process two worklist items first.
However, processing an item may generate additional work, causing the
unlucky thread to recursively process the worklist.  Add a per-thread
flag to detect this situation and avoid the recursion.  This should
fix the stack overflows that could occur while removing large
directory trees.

Tested by:	kris
Reviewed by:	mckusick
2005-03-25 17:30:31 +00:00
Warner Losh
aad0ac34fe Revert bogus += -g change. I needed it to debug the problem.
Noticed by: njl, Andrej Tobola
2005-03-25 17:30:20 +00:00
John-Mark Gurney
a517cb3040 remove unimplemented part of the interface..
MFC after:	3 days
2005-03-25 16:23:48 +00:00
Andrew Gallatin
f83935f874 Zero the reserved fields of the header, as per rfc 2734. This change
results in connectivty to MacOSX hosts via fwip.

Thanks to Apple's Arulchandran Paramasivam <arulchandranp@apple.com> for
letting us know what we were doing wrong.

Reviewed by: dfr
MFC After: 7 days
2005-03-25 16:05:42 +00:00
John Baldwin
5165a17df5 Add code to read the primary PCI bus number out of the Compaq/HP 6010
hotplug Host to PCI bridge.  This is only needed for the non-ACPI case
as the BIOS includes a proper _BBN method in ACPI.
2005-03-25 14:18:50 +00:00
Maxim Sobolev
ddbcc78273 Add /* _FOO_H_ */ after the final #endif to make danfe happy. 2005-03-25 13:22:58 +00:00
Maxim Sobolev
8eadbd831e Fix identation. 2005-03-25 12:55:06 +00:00
Maxim Sobolev
f1cc4b713e Add missed KUE_UNLOCK(). This is NOOP yet, but may be handy later on. 2005-03-25 12:53:26 +00:00
Maxim Sobolev
5135f8e687 Fix breakage in the previous commit caused by the last-minute change. 2005-03-25 12:50:57 +00:00
Maxim Sobolev
87fcbb8fe0 Protect against multiple inclusions. 2005-03-25 12:49:26 +00:00
Maxim Sobolev
d521dc21e7 Move Rx/Tx lists management routines into central location. 2005-03-25 12:42:30 +00:00
Jeff Roberson
7d2832e654 - Pass LK_EXCLUSIVE as the lock type to vget in vfs_hash_insert(). 2005-03-25 10:51:55 +00:00
Maxim Sobolev
710fa1d820 GC unused fields. 2005-03-25 10:39:23 +00:00
Jeff Roberson
eb8d0e01c0 - The td_locks check is currently broken with snapshots and possibly
some case in unmount.  Disable the KASSERT until these problems can
   be diagnosed.

Sponsored by:	Isilon Systems, Inc.
2005-03-25 09:56:56 +00:00
Maxim Sobolev
9245facb49 GC unused field. 2005-03-25 09:48:24 +00:00
Warner Losh
66b4217151 Restore the ability to read FreeBSD 1 tapes (and I think any net2
based tapes, but I'm not sure where NFS_MAGIC was introduced after
4.3).  When support for the pre-4.4 format was removed (the ability to
read 4.2 and 4.3 BSD tapes), the old format inode conversion was
junked as well.  However, FreeBSD 1 dump tapes use the NFS_MAGIC
format, but have this inode format.  Before, restore would fail
complaining that '.' wasn't found and the root directory wasn't on
this tape.  Since the conversion from the not so old format is
relatively trivial, restore the code to make that conversion.

FreeBSD 1 dumps are once again readable.

MFC After: a few days
2005-03-25 07:35:59 +00:00
Warner Losh
a2c0855654 dcvt is unused since the support for converting pre-4.4 tapes was
removed.  Go ahead and remove it and struct odirent since it too is
unused.

# FreeBSD 1.1.5 tapes are still unreadable, but 2.0 and newer work.
2005-03-25 06:57:50 +00:00