Commit Graph

229 Commits

Author SHA1 Message Date
uch
d7285d12b4 clean up a little. 2002-03-11 15:58:20 +00:00
lukem
cd19d52695 * rename MINIROOTSIZE to MEMORY_DISK_SIZE, so that all md(4) options
are now consistently named
* fold opt_mdsize.h into opt_md.h
2002-03-10 19:56:37 +00:00
uch
672baca18b proc0 and page table intialize routines are moved to sh3_machdep.c 2002-03-10 07:46:12 +00:00
uch
f9201a1606 common part are moved to sh3/include/param.h 2002-03-10 07:45:31 +00:00
uch
dc55dc2c73 remove unneeded code and files. 2002-03-08 13:22:11 +00:00
uch
2f603eaa17 CTL_MACHDEP definitions are integrated into sh3/include/cpu.h again. 2002-03-04 14:36:13 +00:00
uch
bf5bf0be48 remove obsolete headers. 2002-03-03 14:59:55 +00:00
uch
90baa8b206 SR related parts moved to psl.h. cpufunc.h segments.h are removed.
kernel mode checking is only SR.MD. no check stack pointer.
2002-03-03 14:31:24 +00:00
uch
17fbf85dc3 machine dependent sysctl are moved to machine/cpu.h
dreamcast, hpcsh ... CPU_CONSDEV
	mmeye, evbsh3	 ... CPU_CONSDEV, CPU_LOADANDRESET
2002-03-03 14:28:48 +00:00
uch
24ebe31f30 remove unneeded configuration. 2002-03-03 14:27:24 +00:00
uch
6042c0a3fc Initial support for KGDB on the sh3. 2002-03-02 22:26:25 +00:00
uch
9c21656766 cpu_dumpconf, reserve_dumppages, dumpsys, cpu_reset are moved to sh3/sh3_machdep.c 2002-02-28 16:54:28 +00:00
uch
f52cc0a5e4 Fix comment to reflect reality. 2002-02-28 16:52:46 +00:00
simonb
4324f37586 Use "#define<tab>". 2002-02-28 03:17:23 +00:00
uch
bbc655c4fb Cleanup register definition 2002-02-28 01:56:57 +00:00
uch
40382c6556 Change foo_r0_r1 macro in sh3/locore.h to foo(Rn, Rm) 2002-02-28 01:53:42 +00:00
uch
06fbd079f5 Remove unneeded header. 2002-02-28 01:52:28 +00:00
christos
6b030ee036 - define other DEV_ constants that the local port uses.
- delete cdev_decl(mm) since <sys/conf.h> does it.
2002-02-27 01:19:03 +00:00
simonb
d9ab16ba2f Purge CLSIZE, CLSIZELOG2 and MCLOFSET.
Be consistant in the way that MSIZE, MCLSHIFT, MCLBYTES and NMBCLUSTERS
  are defined.
Remove old VM constants from cesfic port.
Bump MSIZE to 256 on mipsco (the only one that wasn't already 256).
2002-02-26 15:13:19 +00:00
uch
693be1956c Move common exception vector and scheduler code to
sh3/sh3/exception_vector.S and sh3/sh3/locore_subr.S. exception
vectors are installed by sh_cpu_init().  machine/locore.S contains
kernel entry, interrupt handler, and some MD code.
2002-02-24 18:19:40 +00:00
uch
45407e955f setjmp,longjmp are moved to sh3/locore_subr.S 2002-02-22 19:45:31 +00:00
uch
f694c9fdd7 New NetBSD/sh3 clock framework.
+ hardclock source is moved from TMU1 to TMU0.
 + SH3/SH4 common kernel support.
 + PCLOCK estimation.
 + remove duplicated code.
2002-02-22 19:43:58 +00:00
uch
1bdc7cc5ca Clean up functions
disable_intr, enable_intr, disable_interrupt, enable_interrupt,
disable_ext_intr, enable_ext_intr.
New functions:
for external interrupt:
_cpu_intr_suspend and _cpu_intr_resume.
for exception:
_cpu_exception_suspend and _cpu_exception_resume.
2002-02-19 17:21:18 +00:00
uch
70826aa2cd sh_cpu_init() is added. its initialize cache, MMU ops appropriately.
machine locore code call this at first.
2002-02-17 20:57:09 +00:00
uch
615800d782 Fix calling convention. r0-r7 are caller saved. 2002-02-17 20:53:01 +00:00
uch
4202622d3c if PCLOCK isn't setted, use estimated value calculated by kernel. 2002-02-01 17:52:54 +00:00
jdolecek
6d265bd894 add options PIPE_SOCKETPAIR to individual kernel configs
the option is commented out on everything but kernels I was able
to recognize as INSTALL-like or ones for small memory machines
2002-01-27 13:23:08 +00:00
thorpej
1964af2d8a Update for a leading-underscore-free ELF world. 2002-01-27 09:02:37 +00:00
manu
2efb671770 Added clockctl 2002-01-12 13:00:46 +00:00
martin
b506d6e135 Add PPPoE to all generic kernels that should be able to use it.
XXX TODO: do this for INSTALL kernels too, add sysinst support and make the
XXX needed binaries available on the ramdisk root fs.
2001-12-28 12:21:52 +00:00
gmcgarry
bdd225baa1 Add a blurb to the top of all GENERIC files. This serves three purposes:
- to clarify some terminology
- to clarify the intention of the GENERIC file
- to cross-reference some useful man pages
2001-12-14 05:34:45 +00:00
atatat
b45c51b1fc Roll the rest of the ports over to the new MI kernel build machinery.
Any problems reported by testers have been fixed, and massive
cross-compiling of kernels has shown that any problems that remain
with actually building kernels are not related to this.
2001-12-09 05:00:40 +00:00
atatat
239aeafb2e Fixes to eliminate some compiler complaints, such as:
suggest explicit braces to avoid ambiguous `else'
suggest parentheses around assignment used as truth value
2001-12-04 15:27:35 +00:00
lukem
ecb81c3f6d - convert usage of "defopt" to "defflag" where the relevant option does
not support a value (e.g., it's to be used as "options FOO" instead of
  "options FOO=xxx"). options that take a value were converted to
  defparam recently.
- minor whitespace & formatting cleanups
2001-11-28 10:21:10 +00:00
lukem
0fa231134c - replace "defopt" with "defparam" for options which must take a value,
as config(8) will warn for value-less defparam options
- minor whitespace/formatting cleanup
- consolidate opt_tcp_recvspace.h and opt_tcp_sendspace.h into opt_tcp_space.h
2001-11-20 14:34:18 +00:00
lukem
03aef4723c cleanup:
options SPACE TAB
	makeoptions TAB
	psuedo-device TAB
	remove trailing whitespace
	replace multiple spaces -> tabs
	options "FOO" -> options FOO
	options "FOO=bar" -> options FOO=bar
	options "FOO=\"bar\"" -> options FOO="\"bar\""
2001-11-20 12:56:17 +00:00
msaitoh
32b3143333 Fix incorrect kernelmode check in INTRENTRY macro.
Broken INTRENTRY causes CPU reset when sigaltstack is used.
2001-10-27 03:46:19 +00:00
thorpej
693eff0e2e No need to set MACHINE now that config(8) sets it. 2001-10-23 19:55:56 +00:00
chris
0e7661f023 Update pmap_update to now take the updated pmap as an argument.
This will allow improvements to the pmaps so that they can more easily defer expensive operations, eg tlb/cache flush, til the last possible moment.

Currently this is a no-op on most platforms, so they should see no difference.

Reviewed by Jason.
2001-09-10 21:19:08 +00:00
thorpej
b42556773f Driver for the Dreamcast mouse, based on the programming info
on Marcus's web site.

Not yet thoroughly tested, but does appear to generate events
that look okay.
2001-09-06 22:07:39 +00:00
thorpej
2d2a66209d Indent. 2001-09-06 20:04:49 +00:00
atatat
97c67a9bae Add bridge pseudo devices to GENERIC configs 2001-09-01 21:52:23 +00:00
msaitoh
e380d9806e devclass of sci[f] is tty 2001-08-22 13:32:45 +00:00
msaitoh
0756145b0f fix a ldtlb handling bug:
- set to PTE{H,L,A} and call LDTLB must do atomically.
 - never call LDTLB when it's unnecessary.

Broken kernel oocasionally causes cpu reset when /etc/security is called.
Now fix this problem.
2001-08-10 18:27:08 +00:00
wiz
8eaf0a103e bcopy -> memcpy, bzero -> memset 2001-07-22 15:46:41 +00:00
thorpej
babefc5331 Add BUS_DMA_READ and BUS_DMA_WRITE flags, that hint the back-end
at dmamap load time that the mapping will be used for a unidirectional
transfer of the specified direction.
2001-07-19 15:32:10 +00:00
darcy
ce0ec1e208 Add System V semaphore resource limits to each GENERIC file that has an
option for System V semaphores.  It appears that there are no overrides
in the code and each file has the following added.

 options    SYSVSEM     # System V semaphores
+#options   SEMMNI=10   # number of semaphore identifiers
+#options   SEMMNS=60   # number of semaphores in system
+#options   SEMUME=10   # max number of undo entries per process
+#options   SEMMNU=30   # number of undo structures in system
 options    SYSVSHM     # System V shared memory

If anyone thinks that this is incorrect for any of these files, please
correct it.

Note - the i386 port was not forgotten.  It was done separately.
2001-06-30 11:00:31 +00:00
msaitoh
a76500b70d trim PCLOCK to 49.9MHz 2001-06-24 04:57:58 +00:00
lukem
d84d2c6c85 add missing #include "opt_kgdb.h" 2001-05-30 15:24:23 +00:00
chs
e44e9dec8a replace vm_page_t with struct vm_page *. 2001-05-26 21:27:02 +00:00
marcus
e90e316b11 Changed maple device to attach per function instead of per unit.
Raw maple unit access is now possible through /dev/maple*.
2001-05-26 19:04:39 +00:00
msaitoh
9ae59f3041 convert two consecutive "shll"s with one "shll2" 2001-05-15 08:54:56 +00:00
marcus
bc069b939c Abstracted handling of System ASIC controlled IRQ:s a little.
Three different IRQ:s can be selected for each event, 9, 11, or 13
(which selects hardware priority).  More events to be added as they
are discovered.  Do not use shb_intr_establish() to register IRQ 9, 11
or 13 anymore.
2001-04-24 19:43:23 +00:00
thorpej
1c3a62e066 Sprinkle pmap_update() calls after calls to:
- pmap_enter()
- pmap_remove()
- pmap_protect()
- pmap_kenter_pa()
- pmap_kremove()
as described in pmap(9).

These calls are relatively conservative.  It may be possible to
optimize these a little more.
2001-04-24 04:30:50 +00:00
uch
63ec3bc3fa dreamcast clock module was separated. 2001-04-23 11:20:41 +00:00
kleink
f06533a1ee Add definitions of C99 integer format conversion macros.
XXX Fastest minimum-width integer types haven't been decided upon yet.
2001-04-15 17:13:04 +00:00
kleink
739cb75837 Add definitions of C99 specified-width integer type limits.
XXX Fastest minimum-width integer types haven't been decided upon yet.
2001-04-15 15:29:02 +00:00
kleink
cdcf9f46c5 Add definitions of C99 integer constant macros.
Tidy Makefiles up a little.
2001-04-14 22:46:19 +00:00
kleink
a7c20e5788 Add definitions of C99 integer constant macros. 2001-04-14 22:38:33 +00:00
kleink
7affdab52e Add definitions of C99 minimum-width and greatest-width integer types.
XXX Fastest minimum-width integer types haven't been decided upon yet.
2001-04-14 12:19:49 +00:00
lukem
20ba07f2fe - add dev_noimpl(xxx,yyy) macro to replace "(dev_type_xxx((*))) yyy",
and use appropriately

- create more helper macros:
   . cdev__xyz_init(c,n), such as cdev__ocri_init() for
     /* open, close, read, ioctl */, etc.
   . cdev__xRy_init(c,n), where nullop is used instead of enodev to dummy out
     method `R' and the comments now read /* xxx (read) yyy */ instead
   . cdev__xyz_t_init(c,n,t) - as per cdev__xyz_init, but sets d_type = t
     as well

- use seltrue instead of dev_noimpl(poll,*), as (IIRC) cdevsw.d_poll should
  always DTRT WRT returning a valid result.  (a few devices previously
  incorrectly returned ENODEV)

- use dev_noimpl(stop,enodev) instead of dev_noimpl(stop,nullop) if tty
  == 0, because it doesn't matter if dev_type_stop isn't implemented in that
  case, and it allows the use of the cdev__xyz_init macros. certain ports
  (sparc,sparc64,x68k) used the nullop method for dev_type_stop in a few
  drivers, whereas everything else uses enodev

- ensure that the comments are accurate WRT the behaviour of a given entry
2001-03-26 12:33:22 +00:00
marcus
fab9e9b3bb sc_port_units was set incorrectly at probe time. 2001-03-16 19:57:49 +00:00
thorpej
2c4c690f14 Add the BUS_DMA_STREAMING flag. 2001-03-07 22:42:16 +00:00
marcus
d152e7d2f8 Off-by-one error on v_absolute_size fixed. 2001-03-05 02:45:24 +00:00
marcus
a6ecc2d5de Made it possible to mmap the frame buffer. 2001-03-04 01:36:35 +00:00
marcus
f693207ab0 Support cross-compilers that add the underscore for a little longer.
This _will_ go away.
2001-03-03 19:45:57 +00:00
marcus
33090db137 Harmonized keycodes with USB. 2001-03-02 00:25:06 +00:00
marcus
104415e253 Dropped the leading underscore on _etext and _end, due to move to ELF. 2001-03-01 23:35:20 +00:00
marcus
389ac2109b Kernel binary format is hereby officially changed to ELF32. 2001-03-01 23:34:08 +00:00
msaitoh
f4b23a11a4 fix a check code whether mkbs is console or not 2001-02-22 15:34:28 +00:00
uch
e0a4623854 move disksubr.c define to machine-port. 2001-02-21 16:42:04 +00:00
marcus
7d1d4a2f4d New, interrupt-driven implementation. 2001-02-20 00:04:40 +00:00
marcus
143a120848 Added GDROM interrupt support at IRQ9 (need to clean this up...) 2001-02-20 00:03:53 +00:00
marcus
037484799a PAL support... 2001-02-19 21:37:31 +00:00
marcus
b5f05acab7 Removed LED_ADDR (Dreamcast doesn't have program controllable LEDs). 2001-02-15 18:30:31 +00:00
msaitoh
47410d3a5a sync with Makefile.mmeye.in for ELF 2001-02-14 18:06:50 +00:00
msaitoh
2633a5dcb5 _C_LABEL() 2001-02-14 17:57:31 +00:00
itojun
818f432bec have rnd(4) 2001-02-14 04:57:44 +00:00
uch
78af56fcfd move VM_PHYSSEG_MAX, VM_NFREELIST, VM_FREELIST_DEFAULT defines to
machine/vmparam.h
2001-02-07 14:53:09 +00:00
uch
6a7b420b7e move machine-port specific file to machine directory.
for evbsh3, mmeye and dreamcast, use MI md_root.c
2001-02-06 16:45:19 +00:00
thorpej
40c4d1e0c3 Rename the CLI/STI/ECLI/ESTI macros to more descriptive names,
and add comments to describe exactly what they do (because it's
not totally obvious at a glance, due to the number juggling necessary
to frob the correct bits in SR):

CLI -> EXCEPT_DISABLE (sets SR.BL)
STI -> EXCEPT_ENABLE (clears SR.BL)

ECLI -> INTR_DISABLE (sets SR.I[0-3])
ESTI -> INTR_ENABLE (clears SR.I[0-3])
2001-02-05 18:14:42 +00:00
marcus
0d6830073e Added subunit scan. 2001-02-03 23:25:51 +00:00
marcus
3f60497b85 Increased HZ to 100. 2001-02-03 23:24:30 +00:00
marcus
5592504080 Fixed type mismatch in debug output... 2001-02-02 06:27:44 +00:00
thorpej
4fab177f7e Don't make the reporting of the keyboard type a parenthetical. 2001-02-02 03:09:16 +00:00
thorpej
2ae9f715f6 Report the VGA/NTSC RGB/composite mode of the display. 2001-02-02 03:07:29 +00:00
thorpej
6195ca3474 Add some info to the dmamap_sync assertion messages. 2001-02-01 19:56:44 +00:00
marcus
fc7cc52392 Fixed the last raw accesses to use bus_space. Also added DMA mem size field. 2001-02-01 19:35:04 +00:00
thorpej
f436156dd7 Use the BOLD8x16 font for the console, and remove the RCONS_16BPP
option (no longer needed).
2001-02-01 01:27:59 +00:00
thorpej
f16d219c1b Config glue for rasops/wsfont. 2001-02-01 01:27:04 +00:00
thorpej
fbfc0872d8 New PowerVR display driver, based on the TURBOchannel "cfb"
driver by Tohru Nisimura (a very good framework for a FB driver,
BTW!), using bits of Marcus's original driver for the hardware
access.

The main advantage of this version is that is uses rasops (which
is faster than the rcons stuff) and wsfont, so you can select the
console font in the kernel config file.  Using the BOLD8x16 font,
you get an 80x30 console (vast improvement compared to the Gallant12x22
font).
2001-02-01 01:25:56 +00:00
thorpej
41b0cdf3e5 Add configuration info for the SEGA Broadband Adapter,
and enable the NFS file system and DHCP NFS root support.
2001-02-01 01:09:12 +00:00
thorpej
26cf6921bc GAPS PCI bridge support. Low-level stuff from Marcus, bus_dma
implementation from me.
2001-02-01 01:04:55 +00:00
thorpej
e2c0abd45d Implement {read,write}_region_1, and sprinkle some __volatile
around for sanity.
2001-02-01 01:01:50 +00:00
marcus
f2358f8d43 Basic G2 locking implemented. 2001-01-31 21:58:37 +00:00
thorpej
d729ba2b1f Support for masking/unmasking IRQ 11 (used by the G2/GAPS bridge).
From Marcus.
2001-01-31 18:44:07 +00:00
thorpej
a42d651b53 G2/GAPS PCI configuration glue, for the Broadband Adapter. 2001-01-31 18:39:46 +00:00
thorpej
9342211052 PCI glue, from Marcus. 2001-01-31 18:38:26 +00:00
thorpej
7135afee31 New bus_space and bus_dma framework, based on the Alpha implemetation. 2001-01-31 18:37:11 +00:00
thorpej
63885cd020 G2 bus support. Low level stuff by Marcus, bus_space stuff by me. 2001-01-31 18:33:24 +00:00
thorpej
c625c7ee25 Set the keyboard layout based on what type of keyboard
we probe, defaulting to Japanese if we don't know what
kind of keyboard we have.

XXX This should be done differently, if we ever want to
support multiple keyboards.
2001-01-31 03:21:03 +00:00
thorpej
37aca7f3f0 Add a US keyboard map. This may need to be reworked, as this
uses the Japanese keyboard map as the base.
2001-01-31 03:19:50 +00:00
thorpej
b81a17e100 Make the "maple" bus a direct config bus. Now, when a device is
not configured into the kernel, you know about it, e.g.:

Dreamcast Controller         at maple0 port 0 not configured
2001-01-31 00:14:29 +00:00
thorpej
5c8624a602 Recognize the US keyboard. 2001-01-31 00:08:35 +00:00
msaitoh
69ababe7ba more use _C_LABEL() 2001-01-30 01:32:56 +00:00
msaitoh
14bda6deb9 use macro for CCR register 2001-01-29 22:19:19 +00:00
marcus
7df82ad12b Changed implementation of partitions, multisession discs now work better. 2001-01-25 01:41:47 +00:00
marcus
3c59914ed6 Added GDROM device. 2001-01-21 23:38:34 +00:00
marcus
36382f4889 Primitive GDROM support. 2001-01-21 23:30:28 +00:00
marcus
28f7e6dde5 Corrected license text. 2001-01-21 22:45:57 +00:00
marcus
ec45004dfc Fixed double-stroke bug. 2001-01-21 22:44:40 +00:00
christos
d36fa12430 knf, some symbolic constants would be nice [pvrreg.h]
christos
2001-01-21 05:26:10 +00:00
marcus
8cd0ae534a Better DMA allocator (thanks to Jason R. Thorpe). 2001-01-19 20:27:31 +00:00
fvdl
c7f1462f3e Add machdep file for procfs. Currently only used for linux-style
/proc/cpuinfo (only active when procfs is mounted with -o linux).
For ports other than the i386 this currently produces an empty
string.
2001-01-17 00:07:18 +00:00
marcus
2e39f7eacf Added keymap for European keyboards. 2001-01-16 00:56:29 +00:00
marcus
322c255ab3 WSCONS console added. 2001-01-16 00:33:50 +00:00
marcus
839caf1064 PowerVR display driver. 2001-01-16 00:33:20 +00:00
marcus
ecb24087d2 Maple bus keyboard driver. 2001-01-16 00:33:01 +00:00
marcus
ee6259c508 Maple bus driver. 2001-01-16 00:32:42 +00:00
thorpej
d74e432ed3 Make softclock a generic soft interrupt of the API is available,
adding the requisite void * argument to softclock().
2001-01-15 20:19:50 +00:00
marcus
fb7be69768 Fixed initial cache setup to handle launch from P2 as well as P1. 2001-01-05 01:14:31 +00:00
marcus
d1e05bffc3 Updated linker script set include only RAM based image for Dreamcast. 2001-01-05 01:13:23 +00:00
itojun
1e7e3274f4 split MACHINE_ARCH sh3e[lb]. userland build still needs checking. 2001-01-04 07:03:21 +00:00
itojun
1d25215235 $NetBSD$ 2001-01-03 18:15:47 +00:00
itojun
10e1d3091a share sys/arch/sh3/conf/Makefile.sh3 across sh3-based architectures.
cleanup param.h a bit.
2001-01-03 18:14:44 +00:00
itojun
00fbe713e7 remove #if 0'ed portion 2001-01-03 15:26:17 +00:00
itojun
4469b35a09 retain empty "compile" directory 2001-01-03 15:22:14 +00:00
jdolecek
cacec11253 delete obsolete comment 2000-12-17 15:52:39 +00:00
marcus
83334549fb Initial import of port "dreamcast" (cloned from port "evbsh3"). 2000-12-11 18:19:12 +00:00