summaryrefslogtreecommitdiffstats
path: root/sys/i386
Commit message (Collapse)AuthorAgeFilesLines
* Fix compiler warnings (systm.h wasn't included).bde1995-07-161-0/+1
|
* Add tw.bde1995-07-162-4/+10
|
* Truncate the fault address to a page boundry when calling vm_fault(). Thedg1995-07-161-3/+3
| | | | | last change to fix the fault-twice bug with page tables wasn't quite complete.
* Fixed bug that caused page tables to be faulted twice instead of once.dg1995-07-141-4/+7
| | | | Submitted by: John Dyson
* The following patch for v1.8 (2.0.5R) of seagate.c allows it to work withjkh1995-07-131-87/+163
| | | | | | | | | | | | Future Domain TMC-885 controllers. These beasts were just different enough in a number of perverse ways to be recognised but not work with the seagate stuff. I also whacked in blind transfers for DATAIN and DATAOUT phases - this more than doubles my throughput. If you're dubious about that, comment out the definition of SEA_BLINDTRANSFER. Anyway if you're running an ST01 or TMC-950 controller, please give this a go, I'd like to see if anything's broken for those beasts. Submitted by: Stephen Hocking <sysseh@devetir.qld.gov.au>
* NOTE: libkvm, w, ps, 'top', and any other utility which depends on structdg1995-07-134-14/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | proc or any VM system structure will have to be rebuilt!!! Much needed overhaul of the VM system. Included in this first round of changes: 1) Improved pager interfaces: init, alloc, dealloc, getpages, putpages, haspage, and sync operations are supported. The haspage interface now provides information about clusterability. All pager routines now take struct vm_object's instead of "pagers". 2) Improved data structures. In the previous paradigm, there is constant confusion caused by pagers being both a data structure ("allocate a pager") and a collection of routines. The idea of a pager structure has escentially been eliminated. Objects now have types, and this type is used to index the appropriate pager. In most cases, items in the pager structure were duplicated in the object data structure and thus were unnecessary. In the few cases that remained, a un_pager structure union was created in the object to contain these items. 3) Because of the cleanup of #1 & #2, a lot of unnecessary layering can now be removed. For instance, vm_object_enter(), vm_object_lookup(), vm_object_remove(), and the associated object hash list were some of the things that were removed. 4) simple_lock's removed. Discussion with several people reveals that the SMP locking primitives used in the VM system aren't likely the mechanism that we'll be adopting. Even if it were, the locking that was in the code was very inadequate and would have to be mostly re-done anyway. The locking in a uni-processor kernel was a no-op but went a long way toward making the code difficult to read and debug. 5) Places that attempted to kludge-up the fact that we don't have kernel thread support have been fixed to reflect the reality that we are really dealing with processes, not threads. The VM system didn't have complete thread support, so the comments and mis-named routines were just wrong. We now use tsleep and wakeup directly in the lock routines, for instance. 6) Where appropriate, the pagers have been improved, especially in the pager_alloc routines. Most of the pager_allocs have been rewritten and are now faster and easier to maintain. 7) The pagedaemon pageout clustering algorithm has been rewritten and now tries harder to output an even number of pages before and after the requested page. This is sort of the reverse of the ideal pagein algorithm and should provide better overall performance. 8) Unnecessary (incorrect) casts to caddr_t in calls to tsleep & wakeup have been removed. Some other unnecessary casts have also been removed. 9) Some almost useless debugging code removed. 10) Terminology of shadow objects vs. backing objects straightened out. The fact that the vm_object data structure escentially had this backwards really confused things. The use of "shadow" and "backing object" throughout the code is now internally consistent and correct in the Mach terminology. 11) Several minor bug fixes, including one in the vm daemon that caused 0 RSS objects to not get purged as intended. 12) A "default pager" has now been created which cleans up the transition of objects to the "swap" type. The previous checks throughout the code for swp->pg_data != NULL were really ugly. This change also provides the rudiments for future backing of "anonymous" memory by something other than the swap pager (via the vnode pager, for example), and it allows the decision about which of these pagers to use to be made dynamically (although will need some additional decision code to do this, of course). 13) (dyson) MAP_COPY has been deprecated and the corresponding "copy object" code has been removed. MAP_COPY was undocumented and non- standard. It was furthermore broken in several ways which caused its behavior to degrade to MAP_PRIVATE. Binaries that use MAP_COPY will continue to work correctly, but via the slightly different semantics of MAP_PRIVATE. 14) (dyson) Sharing maps have been removed. It's marginal usefulness in a threads design can be worked around in other ways. Both #12 and #13 were done to simplify the code and improve readability and maintain- ability. (As were most all of these changes) TODO: 1) Rewrite most of the vnode pager to use VOP_GETPAGES/PUTPAGES. Doing this will reduce the vnode pager to a mere fraction of its current size. 2) Rewrite vm_fault and the swap/vnode pagers to use the clustering information provided by the new haspage pager interface. This will substantially reduce the overhead by eliminating a large number of VOP_BMAP() calls. The VOP_BMAP() filesystem interface should be improved to provide both a "behind" and "ahead" indication of contiguousness. 3) Implement the extended features of pager_haspage in swap_pager_haspage(). It currently just says 0 pages ahead/behind. 4) Re-implement the swap device (swstrategy) in a more elegant way, perhaps via a much more general mechanism that could also be used for disk striping of regular filesystems. 5) Do something to improve the architecture of vm_object_collapse(). The fact that it makes calls into the swap pager and knows too much about how the swap pager operates really bothers me. It also doesn't allow for collapsing of non-swap pager objects ("unnamed" objects backed by other pagers).
* Fix races in scstart(). q_to_b() wasn't called at spltty(), so therebde1995-07-112-28/+14
| | | | | | | | | | | | | | were two races: - q_to_b() might unexpectedly return 0 (e.g, after a keyboard signal flushes the output queue and isn't echoed). ansi_put() interprets 0 bytes as 4GB... - more output (e.g. for echoes) might arrive afer q_to_b() returns 0. Then scstart() returns presumably and the new output might not be handled for a long time. Remove unused function scxint(). Fix prototypes (foo() isn't a prototype).
* Speed up the inner loop of ansi_put() by a few percent.bde1995-07-111-2/+10
| | | | | | | syscons' output is now only about 4-5 times slower than I want. It loses a factor of 2 for scrolling output by unnecessarily copying the screen buffer, a factor of 4/3 for dumb OPOST processing, and a factor of 3/2 for clist processing.
* Enable pcvt in LINT and don't generate a compile time error if sysconsbde1995-07-113-13/+13
| | | | | and pcvt are both configured when LINT is defined. There will be a link time error instead. This is to test building of pcvt more often.
* Release summary: (detailed descriptions in Edit History in matcd.c)jkh1995-07-113-68/+150
| | | | | | | | | | | | | | | | | | | | | | | | Adds support for non-Sound Blaster host adapters, including those distributed by Reveal, Lasermate, IBM, Media Vision, Crystal and others. The driver automatically senses the correct adapter type and you can have both in the system at the same time. (This change should eliminate a few complaints.) Corrected bit-masking problem that prevented use on SB Vibra-16 boards. Declared some internal data and functions static that should have been that way all along. Documentation changes reflect the new hardware support and change the appearance version to 2.0.5 (was 2.1). Nice and tidy. :-) Beta testers have verified functionality on SB16, Vibra-16, Media Vision and Reveal adapters. -Wall still shows no warnings. Frank Durda IV uhclem%nemesis@fw.ast.com Submitted by: Frank Durda IV <uhclem%nemesis@fw.ast.com>
* Correct a typo in a comment.ats1995-07-081-2/+2
|
* Multiplex the soft tty interrupt some more to support the cy driver.bde1995-07-051-1/+5
| | | | | This should be configured better, perhaps by providing a software interrupt and mask bit to go with every hardware interrupt.
* Fix error logging:bde1995-07-051-4/+10
| | | | | - get the timeout countdown right - report everything before turning timeouts off.
* Rewrite:bde1995-07-053-1328/+2388
| | | | | | | | | | | - use pseudo-dma - provide the same features and interface as sio - support multiple boards - fix bugs. Some compile-time configuration constants are set to support higher speeds and Cyclom-16Y's at a 30% relative cost in efficiency. Cyclom-16Y support is untested.
* Protected entire epioctl routine with splimp(). In this case, it is betterdg1995-07-051-1/+6
| | | | | | | | form to do this than it is relying on individual subroutines (the logic in epioctl is itself very minimal). Ideally, unnecessary splimp()'s should now be removed if they exist; I'll leave this for a later date (a complete code review of the driver needs to be done). Fixes a bug I noticed that would show up when ifconfig'ing the interface down.
* Dan Eischen's serial eeprom code.gibbs1995-07-042-0/+227
|
* First pass cleanup of this driver. This pass does not include the sequencergibbs1995-07-044-71/+399
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | optimizations I have been working on yet, but does bring in some bug fixes and performance improvments that were easy to regression test: Setup the data fifo threshold and bus off timing correctly for 27/284x cards. Users of these adapters with fast periferals (greater than 5MB/s) will notice a big performance difference. (Sometimes as large as going from 3.7->8.3MB/s). Fix handling of the active target flags. Some of the outbs where missing the base offset in the abort code. The abort code still needs lots of work. Support 3940 controllers, but only with 16 SCBs for now. Eventually I'll add support for all 255, but I need to find a tester for the code first since we have to enable the cards external SRAM to do this. Add Dan Eischen's serial eeprom reading facilities. This allows the 2940 adapters to pull additional information left over from SCSI-Select right out out of the configuration seeprom. If the BIOS is disabled on 274x controllers, reset all target parameters to there defaults since you can't rely on what is stored in scratch ram. Report motherboard controllers as such. Stick the first SG address and count into the SCB data and count areas for all transfers in preparation of a later sequencer optimization. Keep track of which targets can are allowed to have the disconnection priveledge since this will be handled by the kernel driver in the future. If a target issues a message reject in response to a tagged message, disable tagged queuing for that target. Some seagates say they can do tagged queuing, but lie, and its a shame to have to disable tagged queuing on all devices just because you have one that can't cope.
* Add entry for i386/scsi/93cx6.c, the file that handles serial eepromgibbs1995-07-041-1/+2
| | | | | routines for the aic7xxx driver. If and when other drivers start to access similar serial eeproms, this file should probably be moved.
* The PCI config mechanism 1 test failed for the Intel Aries.se1995-06-304-8/+8
| | | | | | Make it less strict ... Submitted by: NIIMI Satoshi <sa2c@and.or.jp>
* Fight with hanging modems continued:ache1995-06-281-1/+8
| | | | | return EIO after t_timeout expired instead infinite looping in "siotx" in comparam, consuming CPU time.
* PCI configuration mechanism now determined by a method, that doesn'tse1995-06-284-60/+68
| | | | | | fail on new hardware (Compaq Prolinea and Compaq Prosignea), and that doesn't erroneously identify old mech. 2 chip sets as using mech. 1. (See section 3.6.4.1.1 of the PCI bus specs rev. 2.0)
* Killed redundant vnode_pager_umount() call. This is already done atdg1995-06-281-6/+2
| | | | FS unmount time.
* Make path to kernel absolute if it is passed in relative. This fixesdg1995-06-281-4/+10
| | | | | | a related bug in some of the new 'foo'boot bootstrap code that has been added over the past months. This change makes it no longer necessary for the bootstrap to fix up the path (i.e. it can be removed).
* Fix standards conformance bugs in <signal.h>:bde1995-06-281-6/+8
| | | | | | | | | | | | | | | | | | | | | include/signal.h: There was massive namespace pollution from including <sys/types.h>. POSIX functions were declared even when _ANSI_SOURCE is defined. sys.sys/signal.h: NSIG was declared even if _ANSI_SOURCE or _POSIX_SOURCE is defined. sig_atomic_t wasn't declared if _POSIX_SOURCE is defined. Declare a typedef for signal handling functions and use it to unobfuscate declarations and to avoid half-baked function types that cause unwanted compiler warnings at certain warning levels. Fix confusing comment about SA_RESTART. sys/i386/include/signal.h: This has to be included to get the declaration of sig_atomic_t even when _ANSI_SOURCE is defined, so be more careful about polluting the ANSI namespace. Uniformize idempotency ifdefs.
* Define macros _BSD_OFF_T_ and _BSD_PID_T_ suitable for use insteadbde1995-06-281-3/+12
| | | | | | | | | | | | | of the typedefs off_t and pid_t when use of the latter would cause namespace pollution. These macros are used like _BSD_VA_LIST_ and aren't #undef'ed when the corresponding typedef is declared. off_t is very machine-dependent and should never have been decided in <sys/types.h> (its declaration is compiler-dependent). pid_t isn't very machine-dependent, but this might change. `long' is a wasteful type for it if longs are longer than ints. Move the definition of _BSD_VA_LIST_ away from the comment that suggests that it is #undefed when va_list is declared.
* Partially fix `sysctl machdep.console_device'. The fix will be completebde1995-06-262-5/+14
| | | | | | | | | | | | | when syscons stops mapping the console to minor MAXCONS. There is usually no corresponding device in /dev, and the correct device has minor 0. cons.c: Initialize cn_tty properly, so that CPU_CONSDEV can work. Comment about too many variants of the console tty pointer. machdep.c: Return device NODEV and not error EFAULT when there is no console device.
* The BT scsi driver has recently had a message changed - it could bejoerg1995-06-251-3/+3
| | | | | | | | | clearer. The "informational message" almost looks like an instruction to the user to change settings on the card.... It's cosmetic, but... Submitted by: peter@haywire.dialix.com
* First incarnation of our Linux emulator or rather compatibility code.sos1995-06-2512-0/+4413
| | | | | | | | | | | | This first shot only incorporaties so much functionality that DOOM can run (the X version), signal handling is VERY weak, so is many other things. But it meets my milestone number one (you guessed it - running DOOM). Uses /compat/linux as prefix for loading shared libs, so it won't conflict with our own libs. Kernel must be compiled with "options COMPAT_LINUX" for this to work.
* Reset defaults in case of boot() is looping several times (e.g. thejoerg1995-06-255-17/+21
| | | | | | | | | | | | user has entered a bogus kernel name in the first place). Also fix the broken #ifdef FORCE_COMCONSOLE, it has been disabled by accident. (NB: the keyboard probe remains disabled however.) Few cosmetic fixes (declare functions to be void instead of int), while i've been at this. Pointed out by: wosch@cs.tu-berlin.de (Wolfram Schneider), for the init bug
* Add a `reset' command to UserConfig. Our documentation doesjoerg1995-06-251-2/+4
| | | | | | | explicitly advise the users to reset the machine in case they have done bogus things (to prevent `dset' from merging the changes into /kernel), and it's also useful for machines with serial consoles that are physically in another place.
* Reduce timeout frequency from `hz' to 0 if no ports are open or to 1 ifbde1995-06-251-142/+236
| | | | | | | | | | | | | | | | | | | | | no ports are active, provided there are no polled ports and no `LOSESOUTINTS' ports. Do a little more in the interrupt handler instead. This is a little less efficient if there are are many active ports but a little more efficient otherwise. Polled ports are ones with no irq specified (as before). `LOSESOUTINTS' ports are ones with 0x08 set in their config flags. Unless this flag is set, it will now take up to one second to recover from lost output interrupts, if any. Some 8250s and 16450s lose output interrupts. Improve output buffering: copy the clist buffer to 2 linear buffers if necessary and possible instead of to 1. Handle an arbitrary queue of buffers in the interrupt handler. Check for waking up sleepers after copying characters out of the clist buffer instead of before. Delay translation of TIOCM_DTR to MCR_DTR etc. so that the top level routines are more machine independent. Fix bogus device register in unused code.
* 1) Enable boot from root partition which end > cyl 1023, it isn't criminalache1995-06-231-6/+11
| | | | | 2) Produce hard error when Bread attempts to read cyl >1023 Reviewed by: bde
* Add an option to the psm driver to skip the parts of the probe which breakdfr1995-06-223-2/+10
| | | | | | some laptops with PS/2 mice. Submitted by: nsayer@quack.kfu.com
* Use ifr_mtu for the mtu value rather than ifr_metric.dg1995-06-221-4/+4
|
* Change interface type...IFT_SLIP -> IFT_PARA.dg1995-06-211-2/+2
|
* 1. Supporting fast sync value displayin latest firmware.amurai1995-06-191-7/+13
| | | | | 2. Use restrict round-robin scheme rather than a agresive one if firmware has a this capability.
* Next version, many bugs fixedache1995-06-143-407/+527
|
* Convert to ANSI C: change #endif THING to #endif /* THING */.bde1995-06-141-59/+57
| | | | | | | | | | | | | | | | | Fix one such THING in code to match comment. Sort IO_GSC* into numeric order and update comments about the gaps. Sort common SCSI addresses into alphabetical order. Remove bogus comments about com ports having i/o size 4. Uniformize whitespace. Uniformize case in hex digits. This file is very incomplete. In particular, it doesn't mention any network cards. This doesn't matter much for the base addresses, but it means that the comments about which addresses are free are mostly bogus. The i/o sizes are unreliable because of split address ranges for many devices (VGA, wd). The i/o sizes are incomplete. In particular, there are no sizes for SCSI controllers. The bt driver still returns a truth value instead of a size.
* Don't convert \n to \r\n in pccnputc(). This is the responsibility ofbde1995-06-141-7/+3
| | | | cnputc().
* Replace \n\r by \n in error messages.bde1995-06-141-6/+6
|
* Output \n as \r\n, not as \n\r.bde1995-06-141-2/+2
|
* Merge RELENG_2_0_5 into HEADrgrimes1995-06-1111-202/+206
|
* Remove trailing whitespace.rgrimes1995-05-30191-3266/+3266
|
* Fix setdumpdev():dg1995-05-291-16/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - the major number wasn't checked, so accesses beyond the end of bdevsw[] were possible. Bogus major numbers are easy to get because `sysctl -w' doesn't handle dev_t's reasonably - it doesn't convert names to dev_t's and it converts the number 1025 to the dev_t 0x35323031. - Driver d_psize() functions return -1 to indicate error ENXIO or ENODEV (the interface is too braindamaged to say which). -1 was interpreted as a size and resulted in the bogus error ENOSPC. - it was possible to set the dumpdev for devices without a d_psize() function. This is equivalent to setting the dumpdev to NODEV except it confuses sysctl. - change a 512 to DEV_BSIZE. There is an official macro dtoc() for converting "pages" to disk blocks but it is never used in /usr/src/sys. There is much confusion between PAGE_SIZE sized pages and NBPG sized pages. Maxmem consists of both. Not fixed: - there is nothing to invalidate the dumpdev if the media goes away. This reduces the benefits of the early calculation of dumplo. Bounds checking in the dump routines is relied on to reduce the risk of damage and little would be lost by relying on the dump routines to calculate dumplo. - no attempt is made to stay away from the start of the device to avoid clobbering labels. Fix wrong && anachronistic comment about the type of bootdev. Reviewed by: davidg Submitted by: Bruce Evans
* Reduce the amount of bss the kzip stuff uses by moving big buffers intophk1995-05-296-236/+32
| | | | the first Mb of memory. Makes 4Mb machines more happy.
* Submitted by: dufaultrgrimes1995-05-282-10/+20
| | | | | | | | LINT talks about about 2.1. I changed that to 2.0.5, and clarified why certain devices need "at scbus?". There is still a crazy "PCVT=210" which shouldn't be there, but corrected comment as it is needed for 2.0.5.
* Increased delay after reset to 10ms. Suggested by several people, the lastdg1995-05-271-2/+2
| | | | | of which was Scott Mace. This fixes a bug where the card would be missed sometimes during the device probe.
* Update swap and dump stuff to match reality:dg1995-05-272-22/+8
| | | | | | | | | | | - option DODUMP no longer exists (remove all references to it). - directive `swap on' is now a no-op (don't bother documenting it; remove comment to match code). - directive `dumps on' still works (restore code to match comment; deprecate it in comment). Reviewed by: Poul-Henning Kamp, and me Submitted by: Bruce Evans
* Made "NMBCLUSTERS" calculation dynamic and fixed bogus use of "NMBCLUSTERS"dg1995-05-254-17/+7
| | | | | | | | | | | | in machdep.c (it should use the global nmbclusters). Moved the calculation of nmbclusters into conf/param.c (same place where nmbclusters has always been assigned), and made the calculation include an extra amount based on "maxusers". NMBCLUSTERS can still be overrided in the kernel config file as always, but this change will make that generally unnecessary. This fixes the "bug" reports from people who have misconfigured kernels seeing the network hang when the mbuf cluster pool runs out. Reviewed by: John Dyson
* Enclosed is a patch for if_ze.c which will allow it to operate withdg1995-05-241-2/+7
| | | | | | | | | the National Semiconductor InfoMover PCMCIA cards also. In tests on a NE4100 on Jordan's laptop here, the ze driver works fine with that card. Reviewed by: Jordan Hubbard, Rod Grimes, and me Submitted by: Gary Palmer
OpenPOWER on IntegriCloud