Commit Graph

60348 Commits

Author SHA1 Message Date
itohy
3e8cfbbf05 minor changes
fix typo
2002-12-06 16:03:52 +00:00
itohy
0d63741702 The buf structure (<sys/buf.h>) is not flexible since it is designed for disks,
and use home-grown buffer structure.

Handle display orientation (normal or upside-down) appropriately
by making use of devinfo of base device.
If the LCD is at an expansion slot of a base unit
whose di_connector_direction == MAPLE_CONN_TOP,
the driver automatically rotates the bitmap.
You need not rotate the bitmap before passing to the driver (spec change).
2002-12-06 15:59:53 +00:00
itohy
f972b5535e Pass devinfo of the base device (subunit == 0 of the same port)
to sub-drivers.
2002-12-06 15:49:31 +00:00
itohy
8f6d7bef0a The value of di_connector_direction is 1 for Dreamcast Gun, 0 for
other devices.  It looks like that the value represents the direction
of expansion units (Visual Memory, etc.).
Add definition of the directions.
2002-12-06 15:47:22 +00:00
pk
721e534a25 Use IPL_SOFTFDC. 2002-12-06 15:37:55 +00:00
pk
e093913db8 Use IPL_SOFTAUDIO. 2002-12-06 15:37:39 +00:00
pk
060fa93542 Start using IPL_* constants from intr.h; phase out PIL_* in psl.h 2002-12-06 15:36:45 +00:00
junyoung
6e278393ba Don't pollute struct cpu_info with throwaway variables. 2002-12-06 14:47:07 +00:00
drochner
10e96d1336 typo in comment 2002-12-06 14:05:34 +00:00
scw
dc63c50793 After a discussion with various folks, fix the strict-alias warning
by ditching 'void *rt' and passing retval directly to sys_mmap().
2002-12-06 12:00:57 +00:00
ad
57d787eeac - Handle DPT ioctls from native NetBSD binaries.
- SCSI targets could disapper mid-way through autoconfig if the board
  notifed us of a changed LCT at the wrong time. Fix that.
2002-12-06 11:22:25 +00:00
tron
96ece1f13e Fix namespace collision caused by recent change to "linux_machdep.h". 2002-12-06 10:51:27 +00:00
scw
57c2c2b87f Add a hack at the end of setregs() which works around a bug which can,
under some circumstances, leave turds in the icache following vmspace
teardown.

It's not yet clear if this is a pmap bug or a toolchain problem since
the hack is unecessary when the kernel is compiled with -O0. Of course
that could just be masking the problem due to increased icache pressure...
2002-12-06 10:22:15 +00:00
scw
f051850107 Avoid strict-alias warnings. 2002-12-06 10:14:10 +00:00
scw
41085b101b fsina.s, fsrra.s and fcosa.s take single-precision operands, not double. 2002-12-06 10:12:13 +00:00
scw
87897c05fe Qualify ptel and tlbcookie fields with volatile since they are
modified by the TLB miss handler.
2002-12-06 10:10:48 +00:00
scw
04fd530ec5 Avoid strict-alias warnings. 2002-12-06 10:07:10 +00:00
scw
381d46a4d1 Hard-code the simulated cpu speed to some fictional value. 2002-12-06 10:06:27 +00:00
scw
f88b19a600 Avoid strict-alias warnings. 2002-12-06 09:57:58 +00:00
simonb
ae1eaadf08 Fix a typo in the PCI map array (no functionality changes in practice). 2002-12-06 05:46:47 +00:00
junyoung
df482bbd8a Rename amd_cpuid_cpu_cacheinfo() to amd_cpu_cacheinfo(). 2002-12-06 05:03:02 +00:00
erh
6278998229 kern/12837: Provide a way to get working devices that violate the usb spec by
returning a non-matching CSW tag.
Defined a quirk for this and set it for Scanlogic SL11R, which gets my
NEO Jukebox working.
2002-12-06 03:57:51 +00:00
junyoung
9104ddf809 Fix compile error. 2002-12-06 03:37:19 +00:00
junyoung
281fa073dc Display the extended feature flags with non-Intel processors rather than
the standard flags. See also PR#19163.

Before:

cpu0: AMD Athlon XP 1800+ (686-class), 1532.11 MHz
cpu0: features 383f9ff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,SEP,MTRR>
cpu0: features 383f9ff<PGE,MCA,CMOV,FGPAT,PSE36,MMX>
cpu0: features 383f9ff<FXSR,SSE>

After:

cpu0: AMD Athlon XP 1800+ (686-class), 1532.11 MHz
cpu0: features c3cbf9ff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,SEP,MTRR>
cpu0: features c3cbf9ff<PGE,MCA,CMOV,PAT,PSE36,MPC,MMXX,MMX>
cpu0: features c3cbf9ff<FXSR,SSE,3DNOW2,3DNOW>

While I'm here, amd_cpuid_cpu_cacheinfo() is an info function rather
than a probe function.
2002-12-06 02:38:25 +00:00
jmc
5a69251dd8 Account for corner cases better in alloc_data_mapping and only ask for a 16s
reconnect time instead of 2^16s
2002-12-06 02:19:34 +00:00
jmc
9e81590397 Fill in sc1394_node_id after a self id cycle 2002-12-06 02:17:30 +00:00
jmc
9a4d03f9b2 Add a def for a smaller reconnect time that will be used by default 2002-12-06 02:14:59 +00:00
simonb
4ea9ad894f Avoid strict alias warning. 2002-12-06 01:55:55 +00:00
christos
ef042d8e23 add a linux_rt_sigframe to support SA_SIGINFO, and use it when SA_SIGINFO
is requested. This appears to be how linuxthreads decides which signal handler
to use.
2002-12-06 00:02:59 +00:00
christos
c363ae66f1 add offsets for linux_rt_sigframe 2002-12-06 00:00:20 +00:00
christos
6b0fccd61c simplify 2002-12-06 00:00:04 +00:00
manu
f0332ec923 In load_shared_file, do zero-fill uninitialized data segments that
explicitely request to be zero filled.
2002-12-05 22:48:53 +00:00
fredette
0fee3368c3 Fixed a null pointer passed to printf(). 2002-12-05 18:05:33 +00:00
junyoung
a2a55f2564 - FGPAT -> PAT, as documented in Intel manual.
- Feature flag 31 is "Signal Break on FERR" (SBF).
2002-12-05 17:25:26 +00:00
thorpej
4245ee1663 Wrap this file in "#ifndef _STANDALONE". 2002-12-05 17:12:06 +00:00
jdolecek
4c7e9f23da pipe_stat(): add S_IRUSR and S_IWUSR to mode; this is what Linux does,
and seems like generally sensible (more sensible than not doing so), so done
in generic code rather than compat glue only

Change proposed in PR kern/18767 by Emmanuel Dreyfus.
2002-12-05 16:30:55 +00:00
jdolecek
16e3e3cd55 Couple fork-bomb defense changes:
- leave 5 processes for root-only use, the previous value of 1
  was unsufficient to execute additional commands once logged, and
  perhaps also not enough to actually login remotely with recent (open)sshd
- protect the log of "proc: table full" with ratecheck(), so that
  the message is only logged once per 10 seconds; though syslogd normally
  doesn't pass the repeated messages through, this avoids flooding
  syslogd and potentially also screen/logs
- If the process hits either system limit of number of processes in system,
  or user's limit of same, force the process to sleep for 0.5 seconds
  before returning failure. This turns 2000 rampaging fork monsters into
  2000 harmlessly snoozing fork monsters.
  The sleep is intentionally uninterruptible by signals.

These are not intended as ultimate protection agains fork-bombs.
Determined attacker can eat CPU differently than via repeating
fork() calls. But this is good enough to help protect against
programming mistakes or simple-minded tests.

Based on FreeBSD kern_fork.c change in revision 1.132 by
Mike Silbersack <silby at FreeBSD org>

Change also discussed on tech-kern@NetBSD.org, thread
'Fork bomb protection patch'.
2002-12-05 16:24:46 +00:00
junyoung
72510c5d3b - Identify VIA C3 processors. Fix PR#19163.
- While here, make use of CPUID2STEPPING() macro.
2002-12-05 16:19:08 +00:00
agc
ecc0017939 Cast appropriately so that this compiles on sparc, sparc64, macppc etc. 2002-12-05 12:22:37 +00:00
pooka
98539df1fe Recognize a few more CT5880 chips. Only cosmetic, does not
affect functionality.
2002-12-05 11:26:26 +00:00
jdolecek
661f8e80e2 Add NOLUNS|NOSYNC quirk for NEC CD-ROM DRIVE:222.
Change sent in PR kern/19286 by Dave Barnes.
2002-12-05 10:39:58 +00:00
yamt
172a847692 initialize uvm.aiodoned_proc. 2002-12-05 10:30:00 +00:00
jdolecek
4ed167f658 a bit of KNF - function type on separate line than function name, function
name on start of line
2002-12-05 10:01:56 +00:00
ichiro
fa14fafc16 add IEEE1394 configuration(Comment out) 2002-12-05 09:32:22 +00:00
ichiro
f11d642c88 make compile 2002-12-05 09:21:26 +00:00
simonb
f8cc054e04 Fix typo in a.out link set macros (s/ifdef/ifndef/). 2002-12-05 05:47:24 +00:00
simonb
699bf96665 Drop the _KERNEL test; these functions are needed for SMP and other ports
don't bother with a _KERNEL check.
2002-12-05 02:56:51 +00:00
fvdl
cc2e1c4082 FIrst cut at INSTALL kernel. 2002-12-05 02:06:44 +00:00
david
2cf8089839 Include cbb, and its cardslot and pcmcia children. Needed by some wi cards. 2002-12-04 23:44:12 +00:00
uwe
6c05e7879f Fix an options<space><tab> nit. 2002-12-04 23:30:40 +00:00
fvdl
93f2be9ef0 For the resume/recurse case, make sure that the interrupt mask level
of the handler is set before acquiring the kernel lock, to avoid a
recursive chain of interrupt processing out of splx().
2002-12-04 23:13:09 +00:00
manu
56b9df9869 Improved mach_vm_map emulation: take into account proection, alignement,
and improve debug messages.
2002-12-04 22:55:11 +00:00
jdolecek
1a82d4f05f regen - addition of 0x90EE, IBM SVGA Adapter/A 2002-12-04 18:53:14 +00:00
jdolecek
53ba962fcf add 0x90EE - IBM SVGA Adapter/A 2002-12-04 18:52:28 +00:00
jdolecek
6227201ba9 If booting from floppy in 2.88MB drive, actually test if it's possible
to read sector 18, and fallback to 1.44MB drive geometry if that fails.
This allows to boot from 1.44MB floppy disk in 2.88MB drive.
Tested with 2.88MB drive in IBM PS/2 model 95 donated
by 'Yokotashi' <lhc at kanal ucw cz> and Pavel Cahyna
<pavel.cahyna at st ms mff cuni cz>
Bump biosboot version.

Fixes PR kern/3418 by Keith Moore.

Change okayed by Frank van den Linden.
2002-12-04 18:26:56 +00:00
thorpej
a13469e728 Revert my previous GCC 3.3-related changes; GCC 3.3 has been fixed
to handle our stdarg/varargs ABI for PowerPC.
2002-12-04 17:42:51 +00:00
imp
1d37d03cd9 Custom config file the the Deskstation rPC44 (aka ARCSTATION I and EPC44).
Untested on target hardware, but compiles and links.
2002-12-04 08:14:30 +00:00
imp
cad09ef8c4 Include machine/kbdreg.h when NPCKBC > 0. This is necessary to pick up
the KBDCMDP definition.
2002-12-04 07:43:55 +00:00
fvdl
5c45b70587 Don't use delay() in the IPI wait loop. Use an empty one instead, with
a counter check in the DIAGNOSTIC case.
2002-12-04 01:36:10 +00:00
fvdl
082d4707fd Create a proper frame in Xspllower if DDB is defined. 2002-12-04 01:33:58 +00:00
haya
805040f592 New Feature: add pseudo device for IEEE 1394 isochronous stream and
isochronous reception routine for IEEE 1394 OHCI (fwohci).  The
transmission part is under construction.

The minimum configuration options for this feature are:

# IEEE 1394 (i.LINK)
fwohci*	at pci? dev ? function ?
pseudo-device	fwiso		1
2002-12-04 00:28:39 +00:00
fvdl
b59af86db6 Install atomic.h 2002-12-03 22:13:58 +00:00
fvdl
567d82224b Synch with i386 (pmap, naming schemes, cpu_info structure). 2002-12-03 22:03:01 +00:00
fvdl
e6f74d6f68 Set the CR0_WP bit. 2002-12-03 22:01:26 +00:00
uwe
23c0293ee7 The chip treats weekday 1 == Sunday, correct dt_wday adjustment logic
appropriately.  NB: the old code would never write weekday zero that,
I've been told, might cause the RTC to reset.
Pointed out by kenh.
2002-12-03 17:54:54 +00:00
kenh
25c20430c3 The day-of-week register in the MC146818 has the value 1-7, but
clock_secs_to_ymdhms() returns dt_wday with a range of 0-6.  Make sure
the DOW register has the correct range.
2002-12-03 16:11:11 +00:00
jdolecek
e1c47ec557 remove obsolete comment 2002-12-03 14:34:33 +00:00
ichiro
ad74b473f7 initialize ixpcomconsaddr
use splserial()
fix IXPCOM registers
2002-12-03 09:28:27 +00:00
itojun
909d6f1e41 regen 2002-12-03 09:27:20 +00:00
itojun
b1780a969c fujitsu AH-F401U AirH" USB
(128K PPP device/should be attached as ucom, but not yet)
2002-12-03 09:27:00 +00:00
explorer
4c21f28434 make this compile without SBP2_DEBUG defined 2002-12-03 06:11:31 +00:00
explorer
eefd3c78e8 add Ricoh 5C552 Cardbus + Firewire product ID 2002-12-03 06:08:00 +00:00
ragge
0b23d06491 Revert Jason's changes to the boot startup code:
- All regs must be saved before any register is altered.
- movc{3,5} alters r0-r5, so clearing bss would clear the text instead.
This needs more thinking/testing to get it work correct; there are
different ways different CPUs call "boot".
2002-12-02 20:23:32 +00:00
ichiro
5a1cd5fee6 add NAPPI_MD config file 2002-12-02 14:26:52 +00:00
ichiro
05413e5da4 move location of pmap_debug() 2002-12-02 14:25:38 +00:00
ichiro
1e213be17b use bus_space map 2002-12-02 14:10:13 +00:00
ichiro
f2de71b067 changes&fix name of mapping registers 2002-12-02 14:08:57 +00:00
matt
f7ce29b0d5 Only declare ttydefchars if _KERNEL is defined. 2002-12-02 05:11:02 +00:00
toshii
350768d9f8 Don't stuff extra data when we receive data less than expected.
This situation is normal for asynchronous sources, and the byte stuffing
algorithm used generates unpleasant noise.
Also take care of scattered data buffer and do memcpy correctly.

This should fix PR kern/16385.
2002-12-02 02:36:14 +00:00
matt
9bd0cc2bb9 Make sure these all agree on the same definitons of various variables. 2002-12-01 23:02:10 +00:00
matt
b5e32a190e Don't define VA_EXCLUSIVE if it's not defined. If we do, it'll be a
different value from the one in <sys/vnode.h>
2002-12-01 23:00:51 +00:00
matt
b360b734b1 Add multiple inclusion protection. 2002-12-01 22:59:42 +00:00
matt
00ed0b8fb8 Reorder things so that with multiple inclusion protection that optional
definitions are outside the protection checks.
2002-12-01 22:58:43 +00:00
matt
e164bfcb71 Reorder things so that multiple inclusion protection so optional
definitions are outside the protection checks.
2002-12-01 22:57:17 +00:00
matt
3ec683c955 Move declartion of SIGPROP to outside of multiple inclusion protection.
If _KERNEL is defined and SIGPROP is not defined, define sigprop as an
extern.
2002-12-01 21:32:05 +00:00
matt
67ed9c3b4f Add multiple inclusion protection. 2002-12-01 21:25:10 +00:00
matt
74a001a61b If TTYDEFCHARS is not defined, define ttydefchars as an extern so the
variable is defined, if not instantiated.
2002-12-01 21:24:28 +00:00
matt
56effcf269 Add multiple inclusion protection. 2002-12-01 21:21:44 +00:00
matt
4913834e76 Fix inconsistencies in various definitions of avail_*, virtual_*, and
proc0paddr.
2002-12-01 21:20:31 +00:00
jmc
bd096e500d Set the only big quirk since the drives I've tried return errors on 6 byte cdbs 2002-12-01 12:12:09 +00:00
jmc
4e448779d8 Checkpoint checkin:
1. Clean up some debugging and trigger some on only extreme debugging needs
2. Comment alloc data mapping a bit better and fix some of the bugs here
(note..there still are some so for now the free method is never called while
I track these down)
3. Fix the copying logic in data_resp. It was calculating negative offsets
which blew up memcpy.

At this point I can probe, inquire and get through the findroot steps of a
boot:

sd0 at scsibus0 target 0 lun 0: <Maxtor, 1394 storage, 60> disk fixed
sd0: mode sense (4) returned nonsense; using fictitious geometry
sd0: 76293 MB, 76293 cyl, 64 head, 32 sec, 512 bytes/sect x 156250000 sectors
sd0: mode sense (4) returned nonsense; using fictitious geometry
sd0: no disk label
findroot: can't open dev sd0a (6)

NOTE: This will panic my machine right now with a simple disklabel -r sd0.
Also, since the free mappings routines are if (0)'d out at the moment do not
use this code for anything except experiments and then only on a machine
you don't mind panic'ing.

Fixing the mapping routines will be the next step and then finally chasing
down the proper mode sense these drives understand.
2002-12-01 12:09:56 +00:00
jmc
3b7f83f77f Correct calculating of offsets when memcpy returned data. 2002-12-01 12:05:11 +00:00
agc
35a5ff86d4 Make this compile in the presence of -Werror 2002-12-01 11:02:11 +00:00
isaki
c3d95a36c4 add bmd, memory disk driver for x68k. 2002-12-01 09:03:03 +00:00
isaki
14096cb14e Add bmd, memory disk driver for Nereid bank memory. 2002-12-01 09:00:35 +00:00
fvdl
8848e366f2 For softints, there's no intrframe on the stack, so don't try to use it.
Use a seperate lock function (in taking the same lock) instead.
2002-12-01 00:15:36 +00:00
matt
60db16d1ff Add multiple inclusion protection for headers. Fix mismatched
variable declarations (missing const's) as needed.
2002-12-01 00:12:06 +00:00
tsutsui
d03ac2a783 Fix botch in previous. This is pcb.h, not reg.h. 2002-11-30 22:50:01 +00:00
fvdl
14067df51c Fix format warnings in INTRDEBUG case. 2002-11-30 22:22:53 +00:00
kristerw
fa033b67e7 Softdep is mature enough that it shouldn't define DEBUG and DIAGNOSTIC
unconditionally.
2002-11-30 20:27:50 +00:00