Commit Graph

4076 Commits

Author SHA1 Message Date
Ruslan Ermilov
743d0f6640 Hack around a problem with sys/tools/usbdevs2h.awk that generates
both usbdevs.h and usbdevs_data.h.  (The latter was not cleaned.)
2004-10-24 08:26:48 +00:00
Poul-Henning Kamp
ff7c5a4880 Alas, poor SPECFS! -- I knew him, Horatio; A filesystem of infinite
jest, of most excellent fancy: he hath taught me lessons a thousand
times; and now, how abhorred in my imagination it is! my gorge rises
at it.  Here were those hacks that I have curs'd I know not how
oft.  Where be your kludges now? your workarounds? your layering
violations, that were wont to set the table on a roar?

Move the skeleton of specfs into devfs where it now belongs and
bury the rest.
2004-10-22 09:59:37 +00:00
Hidetoshi Shimokawa
fdebdf10bc Add dcons_os.{c,h}. 2004-10-13 05:41:09 +00:00
Ruslan Ermilov
f49f4f366b Back out cumulative changes from revs. 1.92-1.94: "make depend"
followed by "make depend" shouldn't do anything.  It doesn't
seem to be a problem anymore, and if someone finds it to break
again, please contact me so we can work on a real fix.

Reviewed by:	bde
2004-10-12 15:08:24 +00:00
Ruslan Ermilov
1f0896165b Style fixes, including:
- Sort kmod.mk knobs in the documentation section.
- Fixed misuses of the word "KLD" which stands for
  "kernel ld", or "kernel linker", where kernel
  module is meant.
- Removed redundant uses of ${.OBJDIR}.
- Whitespace and indentation fixes.
- CLEANFILES cleanup.
- Target redefinition protection (install.debug).

Submitted by:	bde, ru
Reviewed by:	ru, bde
2004-10-12 15:04:10 +00:00
Joerg Wunsch
31e81ae45d Revert the change from rev 1.168. ru convinced me that the situation
that was fixed by this should not normally happen, and since I did not
record the traces of my failed build attempt that had been solved with
that change, it's not entirely clear whether it hadn't been a pilot
error on my end.  In dubio pro reo. :-)
2004-10-11 21:23:56 +00:00
Joerg Wunsch
4e8ba8de26 Forcibly create symlinked headers, otherwise the build process may fail
if the target link already existed (e. g. -DNO_KERNELCLEAN).
2004-10-09 13:51:28 +00:00
Pyun YongHyeon
e60fc88fa6 Port NetBSD auxio driver. The driver was modified to use led(4) and can
be used to announce various system activity.
The auxio device provides auxiliary I/O functions and is found on various
SBus/EBus UltraSPARC models. At present, only front panel LED is
controlled by this driver.

Approved by:    jake (mentor)
Reviewed by:    joerg
Tested by:      joerg
2004-10-09 07:31:03 +00:00
Brooks Davis
ab67442f0c Since net/net_osdep.c contained only one function that could be
trivially implemented as a macro, do that and remove it.  NetBSD did
this quite a while ago.
2004-10-08 00:24:30 +00:00
Ken Smith
de4447e1c0 Back out v1.58... We still don't know what is causing the specific
problem I had but it's happening in code that is messing around with
register windows - I'm willing to live with that piece being sensitive
to this and it looks like the other problems we had reported lately
are not fixed by using -O instead of -O2.

Sorry for the churn.  Looks like I need a second pointy hat.  Someone
tells me they stack well.  :-))))
2004-10-07 20:36:56 +00:00
Warner Losh
bacb482d94 Port pbio to HEAD.
OK'd by: dds
2004-10-07 16:21:03 +00:00
Ken Smith
e47bf36158 Back out v1.49. Recent findings suggest sparc64 may not be ready for
-O2 on kernel compiles after all.  While working on adding a KASSERT
to sparc64/sparc64/rwindow.c I found that it was "position sensitive",
putting it above a call to flushw() instead of below caused corruption
of processes on the system.  jake and jhb have both confirmed there is
no obvious explanation for that.  The exact same kernel code does not
have the process corruption problem if compiled with -O instead of -O2.
There have been signs of similar issues floated on the sparc64@ mailing
list, lets see if this helps make them go away.

Note this isn't an optimal fix as far as the file format goes, if this
disgusts too many people I'll fix it the right way.  Since compiling
with something other than -O is a known problem this format would prevent
a change to the default causing grief.  And this may also help motivate
finding out what the compiler is doing wrong so we can shift back to
using -O2. :-)

My turn for the pointy hat...  One of the florescent ones...

MFC after:	2 days
2004-10-06 19:55:14 +00:00
Yaroslav Tykhiy
fc67901f36 Add a more verbose description for `device vlan'
to the above comment block devoted to such descriptions.
2004-10-04 14:16:17 +00:00
Yaroslav Tykhiy
1270082c84 Hint a kernel builder that vlan needs miibus, which isn't obvious. 2004-10-04 14:06:01 +00:00
Warner Losh
000d5e07e0 assign 187 to ata over ethernet for Sam's ata over ethernet driver.
# Yes, this is the right thing to do: we keep assignments for 4.x here
# to document them, and Sam has a nearly completed driver.
2004-10-01 06:04:24 +00:00
Poul-Henning Kamp
f6bde1fd05 Add a new API for allocating unit number (-like) resources.
Allocation is always lowest free unit number.

A mixed range/bitmap strategy for maximum memory efficiency.  In
the typical case where no unit numbers are freed total memory usage
is 56 bytes on i386.

malloc is called M_WAITOK but no locking is provided (yet).  A bit of
experience will be necessary to determine the best strategy.  Hopefully
a "caller provides locking" strategy can be maintained, but that may
require use of M_NOWAIT allocation and failure handling.

A userland test driver is included.
2004-09-30 07:04:03 +00:00
Mark Murray
932fc0bcb3 Be consistant; make the memrange bit be part of the mem module like
i386.
2004-09-28 07:29:54 +00:00
Marcel Moolenaar
03bfdd1362 Move the IA-32 trap handling from trap() to ia32_trap(). Move the
ia32_syscall() function along with it to ia32_trap.c. When COMPAT_IA32
is not defined, we'll raise SIGEMT instead.
2004-09-25 04:27:44 +00:00
Peter Wemm
2169193596 Converge towards i386. I originally resisted creating <machine/pc/bios.h>
because it was mostly irrelevant - except for the silly BIOS_PADDRTOVADDR
etc macros.  Along the way of working around this, I missed a few things.

* Make syscons properly inherit the bios capslock/shiftlock/etc state like
  i386 does.  Note that we cannot inherit the bios key repeat rate because
  that requires a bios call (which is impossible for us).
* Give syscons the ability to beep on amd64.  Oops.

While here, make bios.c compile and add it to files.amd64.
2004-09-24 01:08:34 +00:00
Olivier Houchard
107d4bd621 Use -O2 for the arm kernel as well 2004-09-23 22:53:22 +00:00
Olivier Houchard
c60e48e2b6 Use the address provided in the conf file, instead of hardcode 0xc0000000. 2004-09-23 22:52:55 +00:00
Olivier Houchard
c2f29b3e64 Add new options :
PHYSADDR : Address of the physical memory
KERNPHYSADDR : Physical address where the kernel starts
KERNVIRTADDR : Virtual address of the kernel
STARTUP_PAGETABLE_ADDR : Where to put the page table at bootstrap
+ Xscale specific options
2004-09-23 22:52:25 +00:00
Olivier Houchard
332d16a165 Add the possibility to specify the kernel virtual address and the kernel
physical address in the kernel config file, as it varies from CPU to CPU.
2004-09-23 22:47:57 +00:00
Poul-Henning Kamp
08d0c00b91 Per recent HEADSUP: Disconnect (old)vinum from the kernel build.
Users should move to the new geom_vinum implementation instead.

The refcount logic which is being added to devices to enable safe module
unloading and the buf/vm work also in progress would require a major rework
of the (old)-vinum code to comply with the new semantics.

The actual source files will not be removed until I have coordinated with
the geomvinum people if they need any bits repo-copied etc.
2004-09-23 08:34:50 +00:00
Ruslan Ermilov
e8f7141ed8 Pass the idea of the make(1) binary to use down to newvers.sh.
This is necessary so source upgrades use the correct binary.

MFC after:	3 days

For the record: Problem spotted by Scott Long, who mentioned
that source upgrades from 4.7 to recent 5.x and 6.0 are broken.
Detailed analysis shows that 4.7 has a broken make(1) binary.
A breakage was fixed in RELENG_4 in make/main.c,v 1.35.2.7 by
imp@, though the commit log erroneously stated "MFC 1.68"
while in fact it should have been spelled as "MFC 1.67".
2004-09-17 09:17:33 +00:00
Gleb Smirnoff
cec50dea12 Attach ng_netflow to kernel build.
Approved by:	julian (mentor)
2004-09-16 20:35:28 +00:00
Ceri Davies
8c5923d931 Typo fix. 2004-09-12 12:13:29 +00:00
Bill Paul
a07bd003bf Add device driver support for the VIA Networking Technologies
VT6122 gigabit ethernet chip and integrated 10/100/1000 copper PHY.
The vge driver has been added to GENERIC for i386, pc98 and amd64,
but not to sparc or ia64 since I don't have the ability to test
it there. The vge(4) driver supports VLANs, checksum offload and
jumbo frames.

Also added the lge(4) and nge(4) drivers to GENERIC for i386 and
pc98 since I was in the neighborhood. There's no reason to leave them
out anymore.
2004-09-10 20:57:46 +00:00
Ruslan Ermilov
673974d9ee Fixed sound-related hints. (Yes, this is ambiguous but matches reality.)
Reviewed by:	matk, cg (an earlier version)
MT5 after:	3 days
2004-09-08 08:42:36 +00:00
Dag-Erling Smørgrav
8985c52bb6 Device driver for the Cypress CY7C637xx and CY7C640/1xx families of USB
to RS232 bridges, such as the one found in the DeLorme Earthmate USB GPS
receiver (which is the only device currently supported by this driver).

While other USB to serial drivers in the tree rely heavily on ucom, this
one is self-contained.  The reason for that is that ucom assumes that
the bridge uses bulk pipes for I/O, while the Cypress parts actually
register as human interface devices and use HID reports for configuration
and I/O.

The driver is not entirely complete: there is no support yet for flow
control, and output doesn't seem to work, though I don't know if that is
because of a bug in the code, or simply because the Earthmate is a read-
only device.
2004-09-05 09:43:47 +00:00
Julian Elischer
ed062c8d66 Refactor a bunch of scheduler code to give basically the same behaviour
but with slightly cleaned up interfaces.

The KSE structure has become the same as the "per thread scheduler
private data" structure. In order to not make the diffs too great
one is #defined as the other at this time.

The KSE (or td_sched) structure is  now allocated per thread and has no
allocation code of its own.

Concurrency for a KSEGRP is now kept track of via a simple pair of counters
rather than using KSE structures as tokens.

Since the KSE structure is different in each scheduler, kern_switch.c
is now included at the end of each scheduler. Nothing outside the
scheduler knows the contents of the KSE (aka td_sched) structure.

The fields in the ksegrp structure that are to do with the scheduler's
queueing mechanisms are now moved to the kg_sched structure.
(per ksegrp scheduler private data structure). In other words how the
scheduler queues and keeps track of threads is no-one's business except
the scheduler's. This should allow people to write experimental
schedulers with completely different internal structuring.

A scheduler call sched_set_concurrency(kg, N) has been added that
notifies teh scheduler that no more than N threads from that ksegrp
should be allowed to be on concurrently scheduled. This is also
used to enforce 'fainess' at this time so that a ksegrp with
10000 threads can not swamp a the run queue and force out a process
with 1 thread, since the current code will not set the concurrency above
NCPU, and both schedulers will not allow more than that many
onto the system run queue at a time. Each scheduler should eventualy develop
their own methods to do this now that they are effectively separated.

Rejig libthr's kernel interface to follow the same code paths as
linkse for scope system threads. This has slightly hurt libthr's performance
but I will work to recover as much of it as I can.

Thread exit code has been cleaned up greatly.
exit and exec code now transitions a process back to
'standard non-threaded mode' before taking the next step.
Reviewed by:	scottl, peter
MFC after:	1 week
2004-09-05 02:09:54 +00:00
Ruslan Ermilov
46e7a66ba0 Fixed more spacing bugs. 2004-09-03 06:32:11 +00:00
Scott Long
f93675b033 Fix whitespace from last commit.
Submitted by: ru
2004-09-02 22:21:51 +00:00
Alfred Perlstein
0793d4d1e4 Hook autofs to the build. 2004-09-02 20:44:56 +00:00
Scott Long
9923b511ed Turn PREEMPTION into a kernel option. Make sure that it's defined if
FULL_PREEMPTION is defined.  Add a runtime warning to ULE if PREEMPTION is
enabled (code inspired by the PREEMPTION warning in kern_switch.c).  This
is a possible MT5 candidate.
2004-09-02 18:59:15 +00:00
Brooks Davis
b443062227 General modernization of coda:
- Ditch NVCODA
 - Don't use a static major
 - Don't declare functions extern

Reviewed by:	peter
2004-09-01 01:19:52 +00:00
Peter Wemm
5fe155d0fd Add the mp_watchdog hooks, although it locks up my SMP test box. It might
be useable to somebody.
2004-08-30 23:33:33 +00:00
Peter Wemm
f37a929ca1 Kill count device support from config. I've changed the last few
remaining consumers to have the count passed as an option.  This is
i4b, pc98/wdc, and coda.

Bump configvers.h from 500013 to 600000.

Remove heuristics that tried to parse "device ed5" as 5 units of the ed
device.  This broke things like the snd_emu10k1 device, which required
quotes to make it parse right.  The no-longer-needed quotes have been
removed from NOTES, GENERIC etc.  eg, I've removed the quotes from:
   device  snd_maestro
   device  "snd_maestro3"
   device  snd_mss

I believe everything will still compile and work after this.
2004-08-30 23:03:58 +00:00
Ruslan Ermilov
03fd8674c1 Finish the removal of the HW_WDOG option.
Hopefully, we'll finally have the compilable LINT kernels again.  ;)
2004-08-29 15:03:06 +00:00
Dag-Erling Smørgrav
b8e543f9f1 Back out previous commit, ichwd is i386-only. 2004-08-29 11:26:36 +00:00
Dag-Erling Smørgrav
0eac4495db Remove the HW_WDOG option; it serves no purpose.
MFC after:	3 days
2004-08-29 11:10:09 +00:00
Dag-Erling Smørgrav
6c420ed90e Back out the two previous commits; ichwd is i386-only. 2004-08-29 10:52:39 +00:00
Ian Dowse
776981d545 Add an entry for ichwd to hopefully unbreak the LINT build. 2004-08-29 03:59:49 +00:00
Ian Dowse
83c457dc27 Unconditionally add `-fno-omit-frame-pointer' to CFLAGS when building
modules on the amd64 platform. Without this, ddb stack traces cannot
follow module function calls, which makes debugging very difficult.
2004-08-29 02:00:50 +00:00
Ruslan Ermilov
cd0bd20d63 Fixed untested change. 2004-08-28 19:40:03 +00:00
Alexander Leidinger
3e41e813b7 Add the Intel ICH watchdog timer driver.
Approved by:	des
2004-08-28 15:41:31 +00:00
Robert Watson
1d8cd39e71 Change the default disposition of debug.mpsafenet from 0 to 1, which
will cause the network stack to operate without the Giant lock by
default.  This change has the potential to improve performance by
increasing parallelism and decreasing latency in network processing.

Due to the potential exposure of existing or new bugs, the following
compatibility functionality is maintained:

- It is still possible to disable Giant-free operation by setting
  debug.mpsafenet to 0 in loader.conf.

- Add "options NET_WITH_GIANT", which will restore the default value of
  debug.mpsafenet to 0, and is intended for use on systems compiled with
  known unsafe components, or where a more conservative configuration is
  desired.

- Add a new declaration, NET_NEEDS_GIANT("componentname"), which permits
  kernel components to declare dependence on Giant over the network
  stack.  If the declaration is made by a preloaded module or a compiled
  in component, the disposition of debug.mpsafenet will be set to 0 and
  a warning concerning performance degraded operation printed to the
  console.  If it is declared by a loadable kernel module after boot, a
  warning is displayed but the disposition cannot be changed.  This is
  implemented by defining a new SYSINIT() value, SI_SUB_SETTINGS, which
  is intended for the processing of configuration choices after tunables
  are read in and the console is available to generate errors, but
  before much else gets going.

This compatibility behavior will go away when we've finished the last
of the locking work and are confident that operation is correct.
2004-08-28 15:11:13 +00:00
Marcel Moolenaar
f697dffaa4 Have the linker provide the btext symbol when referenced. This is needed
for profiling kernels. Apparently, nobody has ever tried to build one on
alpha...
2004-08-27 19:13:35 +00:00
Andre Oppermann
4429922511 Properly document and enable the IPFIREWALL_FORWARD option. 2004-08-27 15:46:16 +00:00
Andre Oppermann
c21fd23260 Always compile PFIL_HOOKS into the kernel and remove the associated kernel
compile option.  All FreeBSD packet filters now use the PFIL_HOOKS API and
thus it becomes a standard part of the network stack.

If no hooks are connected the entire packet filter hooks section and related
activities are jumped over.  This removes any performance impact if no hooks
are active.

Both OpenBSD and DragonFlyBSD have integrated PFIL_HOOKS permanently as well.
2004-08-27 15:16:24 +00:00