Commit Graph

80998 Commits

Author SHA1 Message Date
peter
b78a1645cf Deal with some SMP races by doing the entire copyin at once rather
than doing the checks piecemeal and then doing a second copyin later.

PR:		38021
Submitted by:	davidx (I've tweaked the patch a bit)
2002-09-28 22:44:45 +00:00
gioria
a172a51db3 Continuing MFen 1.423 2002-09-28 22:30:47 +00:00
phk
da9ce5cf0c Rename "struct device" to "struct midway_device" to avoid clashing
with newbus.
2002-09-28 21:59:59 +00:00
phk
1265230747 Move includ of <sys/bus_priate.h> later to get semantic identity of
device_t the same throughout kernel.

This is a very fine point of C which fortunatly does not make any
difference in normal circumstances but which due to the pervasiveness
of device_t in the kernel can make a lint barf a lot.
2002-09-28 21:38:35 +00:00
phk
a4c01edbf3 Change a return to a break so the local buffers get properly freeed.
Spotte by:	FlexeLint

Reviewed by:	rwatson
2002-09-28 21:34:31 +00:00
phk
983b8bb673 s/struct dev_t */dev_t */ 2002-09-28 21:21:01 +00:00
phk
0cdb6c3d20 This driver doesn't need to include <sys/bus_private.h> either.
Spotted by:	FlexeLint
2002-09-28 20:59:59 +00:00
phk
ff0f543527 Disabuse this driver of the notion that it needs to include
<sys/bus_private.h> to find the unit from a device_t.

Spotted by:	FlexeLint
2002-09-28 20:56:32 +00:00
peter
bfa14f852c There is no need for start/num to be signed in i386_ldt_args. 2002-09-28 20:42:04 +00:00
jmallett
64ed1d5707 Fix merge error in previous commit.
Sponsored by:	Bright Path Solutions
2002-09-28 20:04:17 +00:00
jmallett
06c333e3a8 Add empty default cases where they should be, remove non-local execution stuff
in compat.c which doesn't even have preprocessor-conditional-hidden support
code, and add a debugging statement where we might end up with a nil list
somehow, but where I doubt it.

First confirmed userland kill for Flexelint.

Sponsored by:	Bright Path Solutions
2002-09-28 20:03:26 +00:00
phk
45000db183 Zero the local-variable mutexes before we call mtx_init() on them,
failing to do this may lead mtx_init() to belive they have already
been initialized.

Detected by:	Marc Recht <marc@informatik.uni-bremen.de>
2002-09-28 19:38:29 +00:00
peter
a88841129c Repair range checking for reading the ldt list.
PR:		38016
Submitted by:	davidx
2002-09-28 19:37:54 +00:00
gioria
71cf537fe7 We go more on MFen 1.423 2002-09-28 19:05:34 +00:00
jmallett
a17c9b6f5c When spamming me with a printf(9), under DIAGNOSTIC, at least be nice enough
to include a newline.

MFC after:	4 days
Sponsored by:	Bright Path Solutions
2002-09-28 19:04:49 +00:00
phk
ed0285d90e Make P_MAGIC fit in p_magic. 2002-09-28 18:48:22 +00:00
iwasaki
0b1088792e Add support for the BCM5702x chips.
Reviewed by:	jdp
MFC after:	1 week
2002-09-28 18:04:12 +00:00
phk
9a53934a7f Don't use GCC shorthand for ?: unless it really matters. 2002-09-28 17:47:51 +00:00
phk
c5be3924c3 Remove unused includes.
Clarify the intention of a while();
Move a local variable to avoid potential name-confusion.
2002-09-28 17:46:30 +00:00
phk
d1681a7d3d Fix mis-indent. 2002-09-28 17:37:55 +00:00
imp
cff37d047e Newer Netgear MA401RA entry.
Submitted by: Michael Ranner
2002-09-28 17:36:52 +00:00
phk
825608e646 Don't call function in return() for a void function. 2002-09-28 17:36:29 +00:00
phk
87e8f8a0c1 Fix an indentation problem. 2002-09-28 17:34:31 +00:00
phk
8a5ad59602 Don't use unnamed anonymous structs: give it a name. 2002-09-28 17:33:31 +00:00
phk
1dfc2c167f Be consistent about "static" functions: if the function is marked
static in its prototype, mark it static at the definition too.

Inspired by:    FlexeLint warning #512
2002-09-28 17:15:38 +00:00
matusita
523f524386 Create symlink for /etc/group. MAKEDEV file will use this file (group name
to gid conversion).

PR:		43455
Submitted by:	n-kogane@syd.odn.ad.jp
X-MFC after:	immediately if re@ permits, or after 4.7-RELEASE is out
2002-09-28 17:06:07 +00:00
phk
e274a128a9 Put the casts on the right hand side of =. 2002-09-28 14:17:24 +00:00
phk
deb7ab6192 Don't return(foo(bla)) when foo returns void. 2002-09-28 14:03:27 +00:00
phk
30a9d81e1c I misplaced a local variable yesterday. 2002-09-28 13:42:04 +00:00
phk
107a67d351 Correctly order VI_UNLOCK(), local variables and block comment. 2002-09-28 12:15:44 +00:00
phk
6b59496dd8 Style, whitespace and lint fixes.
Sponsored by:	DARPA & NAI Labs.
2002-09-28 11:57:20 +00:00
phk
b5231fc7a7 Void functions cannot use return(foo) even if foo is also returning void.
Sponsored by:	DARPA & NAI Labs.
2002-09-28 11:43:20 +00:00
phk
7d954ea35d Fix two style problems which made FlexeLint unhappy:
Don't use zero-dimension array in struct pargs.

Comma after the last element of an enum doesn't make sense.
2002-09-28 11:28:44 +00:00
julian
e8d03df6f1 Rewrite the kse_create() function to better aproach the semantics we
have specified in the design.
2002-09-28 08:44:31 +00:00
phk
19335151f1 First confirmed kill from my Flexelint license: Check return value
of g_clone_bio().

Detected by:	http://www.gimpel.com/html/flex.htm
Sponsored by:	DARPA & NAI Labs.
2002-09-28 08:16:50 +00:00
tjr
79f7c6df9a Remove masking macros for getwc(), putwc(), putwchar() and getwchar().
Although there was nothing wrong with getwc() and putwc(), getwchar()
and putwchar() assumed that <stdio.h> had been included before <wchar.h>,
which is not allowed by the standard.
2002-09-28 07:43:44 +00:00
julian
609d82aa67 Place 'completed thread anchor' in pre-zero'd secion of the KSEGRP
structure, not the copied section.
2002-09-28 07:27:31 +00:00
ache
b91e8a14c2 Remove more two-letters names,
we don't use them in termcap already many years.

Add "su" as alias to "dumb" to help login, with comment.
2002-09-28 03:40:19 +00:00
jake
27927de410 Renamed intr_enqueue to intr_vector and intr_dequeue to intr_fast, to
better reflect how they are called.
2002-09-28 03:06:35 +00:00
jake
eeddd0ac0f Moved most interrupt related code to a new file, interrupt.S. 2002-09-28 01:56:24 +00:00
peter
0a7f0ba37e Zap now-unused SHLIB_MINOR 2002-09-28 00:25:32 +00:00
jake
c03e93ab3a Add a workaround for what seems to be confusion between binutils and the
sparc v9 ABI.  The Elf_Rela records for local symbols appear to already
have the symbol's value added in to the addend field, even though the ABI
specifies we need to lookup the symbol and add its value too.  This breaks
text relocations in klds because the symbol's value is added twice, and
the resulting address points off into nowhere land, so for now just use
the addend.

Tested by:	rwatson
2002-09-27 23:12:53 +00:00
gibbs
d08d61cf7e Add a missing pair of curly braces to a conditional debug
statement.  This ensures that debug code doesn't trigger if
it isn't enabled. <blush>
2002-09-27 23:00:35 +00:00
phk
358e076f1a Update to match current kernel code.
Fix a couple of reference data which were found to be in error.

Sponsored by:	DARPA & NAI Labs.
2002-09-27 22:20:53 +00:00
phk
2af09b2073 Add "missing scratch-pad register" to the first of the two ports
on the Argosy SP-320 dual-port async PCcard.

An amazing piece of hardware seen from an ISO9000 point of view.
2002-09-27 22:02:46 +00:00
phk
cc0058119e Add a field so we can specify flags per port to the underlying device driver. 2002-09-27 22:01:32 +00:00
phk
d2d1a6d2ea Add yet a quick flag to sio: 0x100000 "Scratch pad register missing".
The advanced stage of computer assisted hardware design and
verification is aptly illustrated by the fact that this is necessary
because only the first ports in a single-chip, dual-port async
PC-Card product lacks this register.
2002-09-27 22:00:23 +00:00
sos
ead9e9f4b3 Fix so it compiles with the new disklabel stuff. 2002-09-27 21:56:35 +00:00
phk
f1d8f5aa08 Extensively rework the geom_bsd method, put a lot of comments in, betting
that this will make people use this for their future copy&paste operations.

Rework the detection of raw-disk offsets in disklabels.  This actually
unearthed a number of bugs in the (now) previous version.

Also accept labels which don't have a magic RAW_PART, provided they don't
confuse us too much.

Change the order of our sanity-checks on labels found on disks to be more
robust.

Check against MAXPARTITIONS in our sanity-check and reject disklabels
we cannot cope with.

Create new g_bsd_modify() function to implment disklabel modifying
ioctls.

Implement DIOCSDINFO and DIOCWDINFO with the provision that the latter
still not writes your change back to disk.  I didn't have the nerves
for that yet.

In the start routine, use g_call_me() for complex ioctls to prevent
sleeping.

Sponsored by:   DARPA & NAI Labs.
2002-09-27 21:54:37 +00:00
phk
bd4b849139 Add the new g_slice_config() call, which can add/delete/change a slice,
with support for trying, doing and forcing.

This will eventually replace g_slice_addslice() which gets changed from
grabbing topology to requing it in this commit as well.

Sponsored by:   DARPA & NAI Labs.
2002-09-27 21:37:11 +00:00