freebsd-nq/sys/sparc64/include
Thomas Moestl c944338750 Fix interrupt assignment for non-builtin PCI devices on e450s.
This machine uses a non-standard scheme to specify the interrupts to
be assigned for devices in PCI slots; instead of giving the INO
or full interrupt number (which is done for the other devices in this
box), the firmware interrupt properties contain intpin numbers, which
have to be swizzled as usual on PCI-PCI bridges; however, the PCI host
bridge nodes have no interrupt map, so we need to guess the
correct INO by slot number of the device or the closest PCI-PCI
bridge leading to it, and the intpin.

To do this, this fix makes the following changes:
- Add a newbus method for sparc64 PCI host bridges to guess
  the INO, and glue code in ofw_pci_orb_callback() to invoke it based
  on a new quirk entry. The guessing is only done for interrupt numbers
  too low to contain any IGN found on e450s.
- Create another new quirk entry was created to prevent mapping of EBus
  interrupts  at PCI level; the e450 has full INOs in the interrupt
  properties of EBus devices, so trying to remap them could cause
  problems.
- Set both quirk entries for e450s; remove the no-swizzle entry.
- Determine the psycho half (bus A or B) a driver instance manages
  in psycho_attach()
- Implement the new guessing method for psycho, using the slot number,
  psycho half and property value (intpin).

Thanks go to the testers, especially Brian Denehy, who tested many kernels
for me until I had found the right workaround.

Tested by:	Brian Denehy <B.Denehy@90east.com>, jake, fenner,
		Marius Strobl <marius@alchemy.franken.de>,
		Marian Dobre <mari@onix.ro>
Approved by:	re (scottl)
2003-05-30 20:48:05 +00:00
..
_inttypes.h Since printf(3) now supports the `j' conversion specifier, use that 2002-06-30 05:48:03 +00:00
_limits.h sys/sys/limits.h: 2003-05-19 20:29:07 +00:00
_stdint.h Create a new header <machine/_stdint.h> for storing MD parts of 2002-07-29 17:41:23 +00:00
_types.h - Add vm_paddr_t, a physical address type. This is required for systems 2003-03-25 00:07:06 +00:00
asi.h Add ASI definitions of UltraSPARC-III (Cu) processors, and add some 2002-07-16 16:22:25 +00:00
asm.h - Fix placement of cvs ids in previous commit to match .S files in libc. 2003-04-29 00:37:41 +00:00
asmacros.h I was wrong, the ENTRY bits in asm.h did have a purpose -- for userland. 2003-04-26 20:54:45 +00:00
atomic.h Make the atomic arithmetic functions return the old value, since they're 2002-12-21 08:53:26 +00:00
bus_common.h Always initialize the UPA target module id in the interrupt mapping 2002-12-01 23:30:26 +00:00
bus_memio.h
bus_pio.h
bus_private.h Fixes for a number of problems in the IOMMU code: 2003-01-21 18:22:26 +00:00
bus.h Rename BUS_DMAMEM_NOSYNC to BUS_DMA_COHERENT. 2003-05-30 20:40:33 +00:00
cache.h Use vm_paddr_t for physical addresses. 2003-04-08 06:35:09 +00:00
ccr.h
clock.h Add two extern's for adjkerntz and wall_cmos_clock, all other 2002-10-05 20:14:49 +00:00
cpu.h Add declarations for btext and etext. 2002-07-28 01:01:14 +00:00
cpufunc.h Use the vis block copy/zero functions for pmap_copy_page and pmap_zero_page. 2003-04-06 17:05:26 +00:00
critical.h
db_machdep.h
eeprom.h
elf.h Make imgact_elf32.c compile on sparc64. 2003-01-05 03:48:55 +00:00
endian.h Be careful not to define GCC-specific optimizations in the non-GCC 2002-09-23 04:32:17 +00:00
exec.h
float.h Implement fpclassify(): 2003-02-08 20:37:55 +00:00
floatingpoint.h
fp.h - Rename pcb_fpstate to pcb_ufp (user floating point), and change it to 2003-04-01 04:02:45 +00:00
frame.h - Expand struct trapframe to 256 bytes, make all fields fixed width and the 2002-10-22 18:03:15 +00:00
fsr.h Clean up a bit, and add some more macros to access %fsr fields. 2002-09-14 17:58:54 +00:00
idprom.h
ieee.h
ieeefp.h Use the definitions in machine/fsr.h instead of duplicating these magic 2002-09-14 18:00:44 +00:00
in_cksum.h
instr.h Add new UltraSPARC-III VIS II instructions. 2002-07-16 17:44:01 +00:00
intr_machdep.h Renamed intr_enqueue to intr_vector and intr_dequeue to intr_fast, to 2002-09-28 03:06:35 +00:00
iommureg.h Some cleanup: 2003-01-06 17:10:07 +00:00
iommuvar.h De-orbit bus_dmamem_alloc_size(). It's a hack and was never used anyways. 2003-05-26 04:00:52 +00:00
kerneldump.h Use vm_paddr_t for physical addresses. 2003-04-08 06:35:09 +00:00
kse.h Add files that are new for KSE. 2002-06-29 07:04:59 +00:00
ktr.h Two tokens that don't together form a vaid preprocssor token cannot be 2003-04-26 17:00:10 +00:00
limits.h sys/sys/limits.h: 2003-05-19 20:29:07 +00:00
lsu.h Add new LSU bits for UltraSPARC-III. 2002-07-16 16:24:03 +00:00
md_var.h Use vm_paddr_t for physical addresses. 2003-04-08 06:35:09 +00:00
metadata.h Slight reorg and added AMD64 support. A couple of the MODINFOMD_* values 2003-05-01 03:31:18 +00:00
mutex.h
nexusvar.h
ofw_bus.h Fix interrupt assignment for non-builtin PCI devices on e450s. 2003-05-30 20:48:05 +00:00
ofw_machdep.h
ofw_mem.h Use vm_paddr_t for physical addresses. 2003-04-08 06:35:09 +00:00
ofw_nexus.h
ofw_upa.h
param.h Get rid of the TODO macro in the few places that still need work; either 2002-10-01 06:34:21 +00:00
pcb.h - Add space for kernel floating point registers to the pcb. These will be 2003-04-03 18:28:03 +00:00
pcpu.h Remove unused fields. 2003-03-18 08:15:24 +00:00
pmap.h - Move the routine for flushing all user mappings from the tlb from pmap to 2003-04-13 21:54:58 +00:00
proc.h
profile.h Add definitions for statistical and high-resolution profiling. The calling 2002-07-30 06:14:34 +00:00
pstate.h
ptrace.h
reg.h - Expand struct trapframe to 256 bytes, make all fields fixed width and the 2002-10-22 18:03:15 +00:00
reloc.h
resource.h
runq.h Move the "- 1" into the RQB_FFS(mask) macro itself so that 2002-06-20 06:21:20 +00:00
setjmp.h Fix namespace issues by using visibility conditionals from 2002-10-05 05:47:56 +00:00
sigframe.h
signal.h Split 4.x and 5.x signal handling so that we can keep 4.x signal 2002-10-25 19:10:58 +00:00
smp.h Use vm_paddr_t for physical addresses. 2003-04-08 06:35:09 +00:00
stdarg.h o Add conditionals to allow va_list to be defined in other headers. 2002-10-06 22:01:07 +00:00
sysarch.h
tick.h Initialize tick_MHz and related variables much earlier. After the last 2002-10-25 17:42:14 +00:00
tlb.h - Move the routine for flushing all user mappings from the tlb from pmap to 2003-04-13 21:54:58 +00:00
trap.h Allow fast instruction and data access mmu miss traps to be handled by 2003-04-29 21:30:59 +00:00
tsb.h Use vm_paddr_t for physical addresses. 2003-04-08 06:35:09 +00:00
tstate.h
tte.h Handle the fictitious pages created by the device pager. For fictitious 2003-03-27 02:16:31 +00:00
ucontext.h Don't allow user process to set an invalid window state through sigreturn. 2003-01-10 00:04:56 +00:00
upa.h
utrap.h Allow fast instruction and data access mmu miss traps to be handled by 2003-04-29 21:30:59 +00:00
varargs.h Add conditionals to allow va_list to be defined in other headers. 2002-10-06 22:02:06 +00:00
ver.h Add two new workaround for firmware anomalies: 2002-11-07 16:07:46 +00:00
vmparam.h Define UMA_MD_SMALL_ALLOC so that uma_small_alloc and uma_small_free will 2002-12-27 19:31:26 +00:00
watch.h Use vm_paddr_t for physical addresses. 2003-04-08 06:35:09 +00:00
wstate.h