Commit Graph

35 Commits

Author SHA1 Message Date
pk 406e0f779f Add a `device class' interrupt level argument (from machine/intr.h)
to bus_interrupt_establish().

It's currently only used in sparc64/dev/psycho.c to assign a CPU interrupt
level to devices in PCI slots.
2000-07-09 20:57:41 +00:00
mrg 4b21f66d57 work around a bug passing arguments to iommu_dvma_load_raw() 2000-07-07 12:53:29 +00:00
mrg 4d14e81c0b remove include of <vm/vm.h>. <vm/vm.h> -> <uvm/uvm_extern.h> 2000-06-29 07:37:53 +00:00
eeh 6c5d2dbbac With these changes the kernel seems almost stable again. 2000-06-24 20:48:36 +00:00
eeh be308420d4 Get rid of vaddrs.h. 2000-06-24 04:20:58 +00:00
eeh 860feb4e74 Fix ordering of sync operations depending on whether it's PRE- or POST-. 2000-06-08 17:41:46 +00:00
eeh 3b90b5c5c4 Add support for bus_dma_load_raw() so the le driver will work again. 2000-05-17 02:31:12 +00:00
mrg 1013298c2a whole bunch of changes:
- merge IOMMU DVMA code from sbus/psycho into iommu.c.  this code was
  identical and a few minor inconsistencies had crept in.  this way
  keeps them all in sync.
- with this code gone from psycho, merge the psycho.c and psycho_bus.c
  files.  same with ebus/ebus_bus.c.  delete the _bus.c files.
- add a _ds_boundary member to the dma segment structure, so that later
  dma mappings can find this value.
- set _ds_boundary in machdep.c:_bus_dmamem_alloc().
- kill much dead code.
2000-04-22 17:05:59 +00:00
mrg 5aa4575432 - convert to DPRINTF() style debug messages.
- kill dead code.
- use the sbus dv_xname to construct a dvma map map, to pass to
  extent_alloc(), to help support multiple sbusses
2000-04-22 12:36:29 +00:00
pk cfadc0991a Get a kernel without DDB to build. 2000-04-10 13:34:18 +00:00
mrg d360a37afd - remove unused variable.
- include <sparc64/sparc64/cache.h> to get cache_flush() prototype.
- remove an unnecessary cast.
2000-04-08 04:17:31 +00:00
soren 95054da1a1 Fix doubled 'the's in comments. 2000-03-13 23:52:25 +00:00
pk cd1f76b21b Remove old-style boot device recognition. 2000-01-14 14:27:14 +00:00
mrg ca66e6b619 - pass slot number to sbus_get_intr() as a new argument.
- in sbus_get_intr(), if we are not an onboard device (ie, sbus card),
  encode the slot number into the sbi_pri so that we can later extract
  it and use it to find the interrupt map & clear registers for this
  device.
- remove "intr" support as it is really pre-sun4u only.
- don't "pause" for so long in sbus interrupt debug messages..

with the slot number being passed back from sbus_get_intr(), the FS/BE
card in an ultra2 now appears to get interrupts and gets beyond
waiting for the scsibus probe!
1999-11-25 05:03:53 +00:00
thorpej 1946167939 Update for pmap_enter() API change. No functional difference. 1999-11-13 00:30:26 +00:00
thorpej 3ebbe095e0 Change the pmap_extract() interface to:
boolean_t pmap_extract(pmap_t, vaddr_t, paddr_t *);
This makes it possible for the pmap to map physical address 0.
1999-07-08 18:05:21 +00:00
eeh 9cf2782159 Move the DVMA mapin/mapout functions from the SBus driver to the iommu driver. 1999-06-20 00:51:29 +00:00
eeh 1884f05354 Another general cleanup:
Remove the entire idea of fasttrap interrupts since V9 traps are really cheap,
the CPUs are really fast, and the completely different trap frames would make
these handlers really difficult to implement.

pmap_changeprot() was only used by the clock and one other place; deprecate it.

probeget() and probeset() now take 64-bit addresses even in 32-bit mode so we
can probe IO locations by physical addresses.

Some pmap cleanup.

Some more copyright cleanup.
1999-06-07 05:28:03 +00:00
mrg cc49a21298 use common IOMMU routines. 1999-06-05 05:30:43 +00:00
eeh b14c7f77cb Garbage collect. 1999-05-31 00:14:00 +00:00
eeh 64b891fc8d Add code to support using %tick as the system clock if no "counter-timer" node
is found.
1999-05-30 19:13:33 +00:00
thorpej 5832084eaf bus_dmamem_map() maps DMA safe memory, which is usually one or more
managed pages, into KVA space.  Since the pages are managed, we should
use pmap_enter(), not pmap_kenter_pa().

Also, when entering the mappings, enter with an access_type of
VM_PROT_READ | VM_PROT_WRITE.  We do this for a couple of reasons:

	(1) On systems that have H/W mod/ref attributes, the hardware
	    may not be able to track mod/ref done by a bus master.

	(2) On systems that have to do mod/ref emulation, this prevents
	    a mod/ref page fault from potentially happening while in an
	    interrupt context, which can be problematic.

This latter change is fairly important if we ever want to be able to
transfer DMA-safe memory pages to anonymous memory objects; we will need
to know that the pages are modified, or else data could be lost!

Note that while the pages are unowned (i.e. "just DMA-safe memory pages"),
they won't consume any swap resources, as the mappings are wired, and
the pages aren't on the active or inactive queues.
1999-05-25 23:14:03 +00:00
mrg ae1a84a61f place iommu definitions in iommureg.h 1999-05-23 07:24:02 +00:00
eeh 60b89ebf96 Well, looks like the MI allocsys() broke the dvmamap, so instead of using a
single map move it to the bus controller driver so each bus can handle its own
IOMMU without conflicts.
1999-05-22 20:33:55 +00:00
mycroft 9c6b797796 Changes for modified pmap_enter() API:
* Map the message buffer with access_type = VM_PROT_READ|VM_PROT_WRITE `just
  because'.
* Map the file system buffers with access_type = VM_PROT_READ|VM_PROT_WRITE to
  avoid possible problems with pagemove().
* Do not use VM_PROT_EXEC with either of the above.
* Map pages for /dev/mem with access_type = prot.  Also, DO NOT use
  pmap_kenter() for this, as we DO NOT want to lose modification information.
* Map pages in dumpsys() with VM_PROT_READ.
* Map pages in m68k mappedcopyin()/mappedcopyout() and writeback() with
  access_type = prot.
* For now, bus_dma*(), pmap_map(), vmapbuf(), and similar functions still use
  access_type = 0.  This should probably be revisited.
1999-03-26 23:41:25 +00:00
eeh 3c8b9d7307 Some devices don't have a `device-type' property we can use to allocate
an IPL.  Check for those by name.  Give the rest a default IPL of 2.
(Added `SUNW,CS4231' to the list.)
1999-03-18 03:23:53 +00:00
eeh 9c06e4a454 Need to put IGN in SBUS slot interrupt vectors as well. (From Kapil Chowksey) 1999-01-10 23:32:57 +00:00
eeh a112a2a4cc It slices. It dices. It does everything except exec a sparc32_compat init. 1998-09-05 23:57:24 +00:00
pk c20e88b71e #include <dev/sbus/sbusvar.h> 1998-09-05 16:50:37 +00:00
pk 181a8253a0 Nuke temporary `getpropA()'. 1998-09-05 16:23:08 +00:00
eeh cf9a8a5a53 Periodic update: now starts probing devices. 1998-09-02 05:51:35 +00:00
eeh 26d2d906c7 Some more 64-bit cleanup. Now everything compiles. 1998-08-30 15:32:16 +00:00
eeh a2dd74ed79 Merge paddr_t changes into the main branch. 1998-08-13 02:10:37 +00:00
eeh d94474ccc9 General update:
Added genassym.cf
	Removed lderr which should never have gotten in
	Removed lots of dead code from locore.s
	Added some softint stuff to intr.c
	Added support for halt -p
	esp and le both use bus_dmamap_*() functions now
		instead of kdvma_mapin()
	groundwork for PCI (but we still have no drivers for
		any sun4u PCI devices)
1998-07-07 03:05:02 +00:00
eeh 01e2e698b6 Import of sparc64. 1998-06-20 04:58:50 +00:00