summaryrefslogtreecommitdiff
path: root/sys/arch/sgi/xbow
AgeCommit message (Collapse)Author
2010-03-21let this compile without DIAGNOSTIC; from miodTheo de Raadt
2010-03-21Fix widget probe order for BASEIO boards and P-Brick.Miod Vallat
2010-03-13Make sure non-console impact_screen struct gets zeroed upon allocation,Miod Vallat
otherwise backing store may not get allocated for it; "go ahead" kettenis@
2010-03-08Correctly initialize all members of struct wsemuldisplaydev_attach_argsMiod Vallat
before attaching wsdisplay; it was turning out harmless but using more cpu time for nothing than necessary. ok deraadt@
2010-03-08fix a miod typo (it has to be a typo; miod makes no real mistakes)Theo de Raadt
2010-03-07Minimalistic driver for the ImpactSR (Mardigras) video option found on olderMiod Vallat
Octane systems, as well as some Onyxes. With special permission to change a systemwide .h file and add a manpage from deraadt@ Magic numbers and operation sequencing borrowed from Linux; tested on Octane + ESI. ok deraadt@
2010-03-07Allow iockbc(4) and odysseey(4) to act as console devices and attach early;Miod Vallat
this gives us working glass console on Fuel, as well as on Octane systems with Odyssey graphics. Joint work with jsing@
2010-03-07Add an MD interface for PCI drivers to be able to retrieve the node and widgetMiod Vallat
number the PCI bus they are on is connected to. Will be used shortly to help the console device selection logic.
2010-03-06Fix typos.Joel Sing
2010-03-04Introduce odyssey(4), a driver for the SGI VPro (aka Odyssey) graphicsJoel Sing
card, which can be found in Octane, Octane2, Fuel, Tezro and Onyx systems. ok miod@
2009-12-26Register an interrupt handler for PCI error conditions (as well as xtalkMiod Vallat
errors at the widget level). Extremely crude for now.
2009-12-25Pass both the virtual address and the physical address of the memory rangeMiod Vallat
when invoking the cache functions. The physical address is needed when operating on physically-indexed caches, such as the L2 cache on Loongson processors. Preprocessor abuse makes sure that the physical address computation gets compiled out when running on a kernel compiled for virtually-indexed caches only, such as the sgi kernel.
2009-11-26Now IPI can interrupt to clock interrupt handler.Takuya ASADA
It prevents deadlock with TLB shootdown and clock interrupt. ok miod@
2009-11-25IP30 IPI implementation.Takuya ASADA
Also few xheart modification for SMP. ok miod@
2009-11-25Allow xbow_intr_establish() callers to provide optional storage for theMiod Vallat
struct intrhand, instead of having it malloc()'ed.
2009-11-19It turns out that the 2GB contiguous DMA direct map window also needsMiod Vallat
to be aligned on a 2GB boundary. Therefore the `add 512MB' bit used on Octane does not give us a 0.5GB-2.5GB usable DMA range, but a 0.5GB-2GB range; trying to use address in the 2GB-2.5GB range would cause PCI DMA errors at the xbridge level. There is no real benefit in using it, since this required us to keep subtracting or adding 0.5GB when converting DMA address to physical memory address or the other way around. So stop using it; this makes a few parts of the code simpler (and until bounce buffers are implemented, Octane systems will not use more than 1.5GB of memory).
2009-11-18Move widget register information apart from xbow software interface, andMiod Vallat
update #include needs. No functional change.
2009-11-12Move the interrupt makemasks() code to the interrupt template; no functionalMiod Vallat
change.
2009-11-11It turns out PCI IOC3 card which embed both the Ethernet controller and theMiod Vallat
superio chip interrupt on two different pins (yet do not advertize themselves as a multi-function device, of course). So, on one hand, this makes the ioc attachment code simpler, because it simply needs to map interrupt pins A and B, and another hand, this moves all the interrupt knowledge to the PCI bridge driver, since routing of pin B differs whether the device is the onboard IOC3 chip (and able to use any of the 8 bridge interrupt sources...) or on a PCI board (with pin mapping sane, since controlled by the bridge). This makes superio interrupts on CADduo boards work. Tested to cause no regressions on Origin 200, Octane and Fuel.
2009-11-08Add code to send L1 commands and parse command results; use it to add a wayMiod Vallat
for IP35 systems with IOC3 onboard Ethernet to get their Ethernet address since it's no longer stored as an owmac(4) device on the IOC3 device itself.
2009-11-07Replace option TGT_ORIGIN200 and TGT_ORIGIN2000 with a single option,Miod Vallat
TGT_ORIGIN, which enables support for all IP27 and IP35 systems. The original two options have always been used together, and go back to when pefo thought supporting multiple nodes would be significant work. Since an Origin 200 can be a dual-node system, making a distinction between single node and multiple node systems is a moot point anyway. Be sure to rerun config(8) before rebuilding a kernel.
2009-11-07Change sgi system identification from a single system type list, to a smallerMiod Vallat
system type list (which really is the system family) and a subsystem type. No functional change yet.
2009-10-31Blinkenlichten on Octane.Miod Vallat
2009-10-26Rename struct confargs to struct mainbus_attach_args for consistency and alsoMiod Vallat
to prevent further abuse of it.
2009-10-26Make pci_intr_string() on xbridge return both the xbridge irq and the crossbowMiod Vallat
irq we route it to; this makes clear that devices connected to different xbridges but using the same xbridge irq are actually not shared at all; and this also helps figure out which device cause spurious interrupts.
2009-10-26Add support for the Octane power button to power(4). Took me a while toMiod Vallat
figure out how the interrupt was routed from xbridge to xheart... (it bypasses the regular `have xbridge send a xio interrupt packet' mechanism)
2009-10-26Add new xbow routines to explicitely trigger or clear an interrupt source,Miod Vallat
instead of embedding that knowledge in xbridge(4); will be used elsewhere shortly.
2009-10-22Completely overhaul interrupt handling on sgi. Cpu state now only stores aMiod Vallat
logical IPL level, and per-platform (IP27/IP30/IP32) code will from the necessary hardware mask registers. This allows the use of more than one interrupt mask register. Also, the generic (platform independent) interrupt code shrinks a lot, and the actual interrupt handler chains and masking information is now per-platform private data. Interrupt dispatching is generated from a template; more routines will be added to the template to reduce platform-specific changes and share as much code as possible. Tested on IP27, IP30, IP32 and IP35.
2009-10-22With the splx() changes, it is no longer necessary to remember which interruptMiod Vallat
sources were masked and saved in ci_ipending, as splx() will unmask what needs to be unmasked anyway. ci_ipending only now needs to store pending soft interrupts, so rename it to ci_softpending.
2009-10-22The recent cleanups make blatantly visible that the pending_int handlerMiod Vallat
does almost exactly what splx() is doing if ipending is zero, and triggers soft interrupts as well. So don't bother checking for ipending in splx, and always invoke pending_int, which gets renamed as splx_handler for consistency.
2009-10-22Replace intrmask_t with uint32_t. This types only describes interrupt masksMiod Vallat
in the coprocessor 0 status register (coupled with ICR on rm7k/rm9k), and may be completely alien to real hardware interrupt masks, so don't make things unnecessary confusing.
2009-10-22Introduce a logical xbpci(4) device between xbridge and pci, since more thanMiod Vallat
one pci bus can attach to an xbridge (if PIC) and both being `bus 0' would make dmesg confusing. While there, seize the opportunity of this new dmesg line to display the bus mode (PCI or PCIX) and speed.
2009-10-16Make Octane kernels compile again after recent changes. My bad.Miod Vallat
2009-10-15regenMiod Vallat
2009-10-15Sort widgets by type instead of manufacturer code, add some TIO widgets,Miod Vallat
and add comments explaining why it's very unlikely we'll ever see TIO widgets on mips-based SGI systems (unless someone builds a Mengele-style XIO link).
2009-10-15The Octane boot PROM is accessible through the PCI space of the on-board i/oMiod Vallat
widget; make sure we reserve its address span so that no device risks having its resources overlap the PROM.
2009-10-14On IP30 and IP35 systems, try harder to figure out exactly what model we areMiod Vallat
running on, and report this both as the hw.product sysctl and in dmesg. Fuel and Origin 350 are no longer reported as being Origin 300 systems!
2009-10-14Report the crossbow widget part of bedrock as PXBow for consistency withMiod Vallat
the *{X,}Bow names and because this is what IRIX calls it.
2009-10-10Simplify interrupt address programming to avoid the need to act differentlyMiod Vallat
on PIC; no functional change.
2009-10-08Program the widget interrupt address register as a whole 64 bit registerMiod Vallat
instead of two 32 bit halves, as the supposedly `upper 32 bits' register ignores writes; makes interrupt on PIC route correctly.
2009-10-08regenMiod Vallat
2009-10-08Recognize the Bedrock as an XBow instead of reporting it as ``unknownMiod Vallat
xbow''; while there report vendor and product id of unknow xbow chips.
2009-10-08Recognize more brick types and probe fooX bricks in the same order asMiod Vallat
foo bricks (they differ by having PCI-X bridges instead of PCI bridges but are otherwise built the same)
2009-10-08PIC actually comes with two sets of widget registers, with different IDs,Miod Vallat
but we only care about the first for matching, so don't bother listing the second one in xbowdevs, and fix the description.
2009-10-07Do not truncate bridge register values to 32 bits, allows the few 64 bit PICMiod Vallat
registers to be programmed correctly.
2009-10-07ipending, cpl moved into cpu_infoTakuya ASADA
OK miod@
2009-10-07Try to keep existing IOC4 mappings, the same way we do on IOC3, in caseMiod Vallat
this is a console device.
2009-10-07Small steps towards getting the serial clock correct on IOC4 serial ports.Miod Vallat
2009-08-22Constify the what/name parameter of pci_intr_establish().Michael Knudsen
Tested by myself, sthen, oga, kettenis, and jasper. Input from sthen and jasper. ok kettenis (Manpage follows shortly.)
2009-08-18Blind support for SGI PIC PCI-X controller found on Origin 350 and TezroMiod Vallat
systems. PIC was supposed to be mostly XBridge compatible, but a silicon bug prevents it from working correctly if 32 bit register writes are used, so the xbridge(4) code now needs to issue 64 bit writes. In order to make this a bit more transparent, rebase all widget registers to a 8 byte boundary, and provide a few inline accessors which will do the right thing if you want 32 bit writes. Tested to not cause regressions on Octane, Origin 200 and Fuel; covering Bridge < 4, Bridge >= 4 and XBridge flavours.