Commit Graph

257 Commits

Author SHA1 Message Date
lukem
e4a87aa1a9 * convert to using MI allocsys(). most ports were using an MD allocsys(),
although a couple still used the old pre-4.4-lite (?) mechanism.
* use format_bytes() to format the various printf()s that print out memory sizes
1999-05-20 08:21:42 +00:00
thorpej
f98d358a1f Rework layer 2 protocol input routines. Instead of calling e.g. ether_input()
directly, call the function pointer (*if_input)(ifp, m).  The input routine
expects the packet header to be at the head of the packet, and will adjust
as necessary.  Privatize the layer 2 input and output routines, allowing
*_ifattach() to set them up as appropriate.
1999-05-18 23:52:51 +00:00
thorpej
e5f47f6307 Rewrite the USB keyboard console attachment (again). Grumble, Macintosh
firmware sets the "stdin" property of /chosen to be a pseudo-hid (yes, they
even spell it incorrectly) that merges all keyboard input into one stream,
so we can't find the USB controller we're attached to.  Instead, just give
it to the first USB keyboard found during autoconfiguration.  So that we
have SOMETHING available early on, use OpenFirmware i/o to do keyboard
input to the console wsdisplay until the USB code attaches the keyboard.

From Jason Thorpe <thorpej@nas.nasa.gov>
1999-05-13 23:37:19 +00:00
wrstuden
3c5aad8d3c For whatever reason, we just can't call pci_init() that early on Bandit
systems.  Why?  Who knows.  Firmware bugs, maybe.  In any case, moving
the call out of the ADB path works.  "Good enough for me."
1999-05-07 22:20:38 +00:00
wrstuden
1e90fa5723 BusLogic cards seem to work in my G3. :-) 1999-05-07 20:10:54 +00:00
drochner
fe310dd299 include <lib/libkern/libkern.h> for intoa()/inet_ntoa() 1999-05-07 16:19:27 +00:00
wrstuden
fb7f9b828f Add pciide config info. 1999-05-06 19:28:20 +00:00
thorpej
680c3ddbd2 Completely rewrite how cninit() determines which keyboard to use with
the console.  New algorithm:

* if stdin == keyboard, and parent of keyboard == adb, use ADB.
* else, must be a USB keyboard.  Search backwards though the parents
until the USB controller is located.  Determine its location in the PCI
domain, and which type of controller it is, and tell that controller that
it has the console input device.  The USB code will then attach the first
USB keyboard as the console input device during autoconfiguration.

The iMac and Blue and White G3 consoles are fully functional now!
1999-05-06 19:24:47 +00:00
thorpej
ac9eee8693 Take all of the OpenFirmware "stdin" grovelling out of the ADB keyboard
driver, as the smarts for this all live somewhere else now.
1999-05-06 19:20:59 +00:00
thorpej
35df607966 Allow pci_init() to be called twice, once just to find the PCI-Host
bridges and determine the "pci chipset" values (for making PCI tags),
and again to actually map the configuration space registers.
1999-05-06 19:16:44 +00:00
tsubai
661ae33963 Remove unused codes. 1999-05-06 04:37:44 +00:00
wrstuden
af849de633 MAke this cross-tools happy. 1999-05-06 01:04:48 +00:00
tsubai
9042054e51 Fix a small bug to make both IO and MEM enable bits in csr are set. 1999-05-05 08:43:53 +00:00
thorpej
fc645b996a - Always config_found() PCI busses, so we know if present PCI busses
aren't configured.
- Grab the bus's memory space tag from the pci_bridge structure for
the bus.
1999-05-05 04:40:00 +00:00
thorpej
654b0fff46 - Completely rewrite how bus space tags for PCI space are set up. Instead
of hard-coding them, decode the "ranges" property of the PCI bus node in
OpenFirmware.
- Do a little cleanup, and share some more code between the Bandit/Chaos
and MPC106.

XXX The bus_space(9) implementation for macppc really needs to be
rewritten.
1999-05-05 04:37:19 +00:00
thorpej
c448c97f2b - Add come comments.
- Do a little cleanup.
- Protect the entirety of pci_conf_{read,write}() with splhigh()/splx().
1999-05-05 04:32:28 +00:00
thorpej
341f87673b Add a bus space tag for PCI memory space to the pci_bridge structure. 1999-05-05 04:26:48 +00:00
tsubai
28b7777fd0 Provide CACHELINESIZE when _STANDALONE is defined too. 1999-05-03 05:19:59 +00:00
tsubai
8e885e921e Check "mac-io" and "/pci/mac-io". 1999-05-01 10:37:57 +00:00
tsubai
8dbaa0169e Find "mac-io" and "/pci/mac-io". 1999-05-01 10:36:08 +00:00
tsubai
5fff3dafe9 Use "compatible" property to match. 1999-05-01 10:23:42 +00:00
tsubai
9697f9c401 Add more sanity check. 1999-04-30 04:35:35 +00:00
tsubai
599ebb4db1 Now we can use symbols in DDB. :-) 1999-04-29 05:15:30 +00:00
tsubai
741030cc8a Add loadfile_machdep.h 1999-04-29 03:17:12 +00:00
tsubai
e4e1fcbaa6 Use MI loadfile(). 1999-04-29 03:16:20 +00:00
wrstuden
9b0e678d51 Fix compilation errors. 1999-04-22 18:48:59 +00:00
ws
5423093850 Modify syncicache on PowerPC from an inline to a real function.
Support different cache line sizes with the same object code in userland.
While here, move the function to implementation name space.
1999-04-17 21:16:45 +00:00
thorpej
e49833cd68 Now that we have direct-mapped pool pages, we can garbage-collect VM_MBUF_SIZE
and don't need to allocate mb_map.
1999-04-16 21:47:11 +00:00
thorpej
48a53c250d Add a stub pciide_machdep_compat_intr_establish() for Power Macintosh.
Power Macintoshes with PCI IDE (e.g. the new Blue G3) don't have them
wired to compatibility mode, so just return a NULL cookie.  We still have
to have this routine for the PCI IDE driver to link.
1999-04-16 21:15:29 +00:00
chs
f455dd6596 add a `flags' argument to uvm_pagealloc_strat().
define a flag UVM_PGA_USERESERVE to allow non-kernel object
allocations to use pages from the reserve.
use the new flag for allocations in pmap modules.
1999-04-11 04:04:04 +00:00
tsubai
bee9b5d9ab Enable "de". 1999-04-01 16:11:45 +00:00
thorpej
967b8c433c Don't call configure() from cpu_startup(). 1999-04-01 00:17:45 +00:00
tsubai
7c3a6002b3 Use interrupt-map property rather than hard-coding irqs.
(From Dan Winship <danw@MIT.EDU>. Slightly modified by me)
1999-03-29 12:12:03 +00:00
tsubai
e1410f9e82 Remove unused file. 1999-03-28 13:39:30 +00:00
tsubai
85cece609b Remove unused files. 1999-03-28 13:16:45 +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
tsubai
6dbdfeab77 include GENERIC. 1999-03-26 16:40:09 +00:00
tsubai
35a4f16a60 ``INSTALL'' + USB doesn't work (binutils bug?).
So use this instead.
1999-03-26 14:58:22 +00:00
mrg
7b93dd1117 remove opt_uvm.h 1999-03-25 00:41:46 +00:00
mrg
ca5f9685bb clean up kernel/config files files for machVM lossage. 1999-03-24 06:06:09 +00:00
mrg
d2397ac5f7 completely remove Mach VM support. all that is left is the all the
header files as UVM still uses (most of) these.
1999-03-24 05:50:49 +00:00
drochner
76fa1751fe Add a macro to check for sufficient pointer alignment in bus.h context,
"BUS_SPACE_ALIGNED_POINTER()".
Equal to the param.h "ALIGNED_POINTER()" normally, but obeys additional
requirements of the bus_space_xxx_n() macros. (BUS_SPACE_DEBUG)
1999-03-23 21:29:03 +00:00
wrstuden
3c8e65b670 Oops. macppc doesn't use PCLK as a baud rate source. 1999-03-23 18:07:19 +00:00
thorpej
63b6321834 VM_MBUF_SIZE is in terms of MCLBYTES, not CLBYTES. 1999-03-23 00:31:59 +00:00
cgd
284689634e Moved to arch/macppc/include/pci_machdep.h,v 1999-03-19 03:36:19 +00:00
cgd
49e6daa992 Moved from arch/macppc/pci/pci_machdep.h,v 1999-03-19 03:36:18 +00:00
sommerfe
bc533621ed defopt MINIROOTSIZE 1999-03-17 18:59:21 +00:00
tsubai
79c71e0bae Check the accessibility before reading from configuration space. 1999-03-15 03:03:10 +00:00
tsubai
07e094073c Remove bogus comment. 1999-03-15 02:26:10 +00:00
perry
d446fb449c exterminate ovbcopy. patches provided by Erik Bertelsen, pr-7145 1999-03-12 22:42:30 +00:00