Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions | Variables
mac_via.h File Reference

Go to the source code of this file.

Macros

#define VIA1_BASE   (0x50F00000)
 
#define VIA2_BASE   (0x50F02000)
 
#define RBV_BASE   (0x50F26000)
 
#define VIA1A_vSccWrReq
 
#define VIA1A_vRev8
 
#define VIA1A_vHeadSel
 
#define VIA1A_vOverlay
 
#define VIA1A_vSync
 
#define VIA1A_vVolume   0x07 /* Audio volume mask for PWM */
 
#define VIA1A_CPUID0   0x02 /* CPU id bit 0 on RBV, others */
 
#define VIA1A_CPUID1   0x04 /* CPU id bit 0 on RBV, others */
 
#define VIA1A_CPUID2   0x10 /* CPU id bit 0 on RBV, others */
 
#define VIA1A_CPUID3   0x40 /* CPU id bit 0 on RBV, others */
 
#define VIA1B_vSound
 
#define VIA1B_vMystery
 
#define VIA1B_vADBS2   0x20 /* ADB state input bit 1 (unused on IIfx) */
 
#define VIA1B_vADBS1   0x10 /* ADB state input bit 0 (unused on IIfx) */
 
#define VIA1B_vADBInt   0x08 /* ADB interrupt 0=interrupt (unused on IIfx)*/
 
#define VIA1B_vRTCEnb   0x04 /* Enable Real time clock. 0=enabled. */
 
#define VIA1B_vRTCClk   0x02 /* Real time clock serial-clock line. */
 
#define VIA1B_vRTCData   0x01 /* Real time clock serial-data line. */
 
#define EVRB_XCVR   0x08 /* XCVR_SESSION* */
 
#define EVRB_FULL   0x10 /* VIA_FULL */
 
#define EVRB_SYSES   0x20 /* SYS_SESSION */
 
#define EVRB_AUXIE   0x00 /* Enable A/UX Interrupt Scheme */
 
#define EVRB_AUXID   0x40 /* Disable A/UX Interrupt Scheme */
 
#define EVRB_SFTWRIE   0x00 /* Software Interrupt ReQuest */
 
#define EVRB_SFTWRID   0x80 /* Software Interrupt ReQuest */
 
#define VIA2A_vRAM1   0x80 /* RAM size bit 1 (IIci: reserved) */
 
#define VIA2A_vRAM0   0x40 /* RAM size bit 0 (IIci: internal video IRQ) */
 
#define VIA2A_vIRQE   0x20 /* IRQ from slot $E */
 
#define VIA2A_vIRQD   0x10 /* IRQ from slot $D */
 
#define VIA2A_vIRQC   0x08 /* IRQ from slot $C */
 
#define VIA2A_vIRQB   0x04 /* IRQ from slot $B */
 
#define VIA2A_vIRQA   0x02 /* IRQ from slot $A */
 
#define VIA2A_vIRQ9   0x01 /* IRQ from slot $9 */
 
#define VIA2B_vVBL
 
#define VIA2B_vSndJck
 
#define VIA2B_vTfr0   0x20 /* Transfer mode bit 0 ack from NuBus */
 
#define VIA2B_vTfr1   0x10 /* Transfer mode bit 1 ack from NuBus */
 
#define VIA2B_vMode32
 
#define VIA2B_vPower
 
#define VIA2B_vBusLk
 
#define VIA2B_vCDis
 
#define vBufB   0x0000 /* [VIA/RBV] Register B */
 
#define vBufAH   0x0200 /* [VIA only] Buffer A, with handshake. DON'T USE! */
 
#define vDirB   0x0400 /* [VIA only] Data Direction Register B. */
 
#define vDirA   0x0600 /* [VIA only] Data Direction Register A. */
 
#define vT1CL   0x0800 /* [VIA only] Timer one counter low. */
 
#define vT1CH   0x0a00 /* [VIA only] Timer one counter high. */
 
#define vT1LL   0x0c00 /* [VIA only] Timer one latches low. */
 
#define vT1LH   0x0e00 /* [VIA only] Timer one latches high. */
 
#define vT2CL   0x1000 /* [VIA only] Timer two counter low. */
 
#define vT2CH   0x1200 /* [VIA only] Timer two counter high. */
 
#define vSR   0x1400 /* [VIA only] Shift register. */
 
#define vACR   0x1600 /* [VIA only] Auxiliary control register. */
 
#define vPCR   0x1800 /* [VIA only] Peripheral control register. */
 
#define vIFR   0x1a00 /* [VIA/RBV] Interrupt flag register. */
 
#define vIER   0x1c00 /* [VIA/RBV] Interrupt enable register. */
 
#define vBufA   0x1e00 /* [VIA/RBV] register A (no handshake) */
 
#define rBufB   0x0000 /* [VIA/RBV] Register B */
 
#define rExp   0x0001 /* [RBV only] RBV future expansion (always 0) */
 
#define rSIFR   0x0002 /* [RBV only] RBV slot interrupts register. */
 
#define rIFR   0x1a03 /* [VIA/RBV] RBV interrupt flag register. */
 
#define rMonP   0x0010 /* [RBV only] RBV video monitor type. */
 
#define rChpT   0x0011 /* [RBV only] RBV test mode register (reads as 0). */
 
#define rSIER   0x0012 /* [RBV only] RBV slot interrupt enables. */
 
#define rIER   0x1c13 /* [VIA/RBV] RBV interrupt flag enable register. */
 
#define rBufA   rSIFR /* the 'slot interrupts register' is BufA on a VIA */
 
#define RBV_DEPTH   0x07 /* bits per pixel: 000=1,001=2,010=4,011=8 */
 
#define RBV_MONID   0x38 /* monitor type, as below. */
 
#define RBV_VIDOFF   0x40 /* 1 turns off onboard video */
 
#define MON_15BW   (1<<3) /* 15" BW portrait. */
 
#define MON_IIGS   (2<<3) /* 12" color (modified IIGS monitor). */
 
#define MON_15RGB   (5<<3) /* 15" RGB portrait. */
 
#define MON_12OR13   (6<<3) /* 12" BW or 13" RGB. */
 
#define MON_NONE   (7<<3) /* No monitor attached. */
 
#define IER_SET_BIT(b)   (0x80 | (1<<(b)) )
 
#define IER_CLR_BIT(b)   (0x7F & (1<<(b)) )
 

Functions

void via_register_interrupts (void)
 
void via_irq_enable (int)
 
void via_irq_disable (int)
 
void via_nubus_irq_startup (int irq)
 
void via_nubus_irq_shutdown (int irq)
 
void via1_irq (unsigned int irq, struct irq_desc *desc)
 
void via1_set_head (int)
 
int via2_scsi_drq_pending (void)
 

Variables

volatile __u8via1
 
volatile __u8via2
 
int rbv_present
 
int via_alt_mapping
 

Macro Definition Documentation

#define EVRB_AUXID   0x40 /* Disable A/UX Interrupt Scheme */

Definition at line 77 of file mac_via.h.

#define EVRB_AUXIE   0x00 /* Enable A/UX Interrupt Scheme */

Definition at line 76 of file mac_via.h.

#define EVRB_FULL   0x10 /* VIA_FULL */

Definition at line 74 of file mac_via.h.

#define EVRB_SFTWRID   0x80 /* Software Interrupt ReQuest */

Definition at line 79 of file mac_via.h.

#define EVRB_SFTWRIE   0x00 /* Software Interrupt ReQuest */

Definition at line 78 of file mac_via.h.

#define EVRB_SYSES   0x20 /* SYS_SESSION */

Definition at line 75 of file mac_via.h.

#define EVRB_XCVR   0x08 /* XCVR_SESSION* */

Definition at line 73 of file mac_via.h.

#define IER_CLR_BIT (   b)    (0x7F & (1<<(b)) )

Definition at line 191 of file mac_via.h.

#define IER_SET_BIT (   b)    (0x80 | (1<<(b)) )

Definition at line 190 of file mac_via.h.

#define MON_12OR13   (6<<3) /* 12" BW or 13" RGB. */

Definition at line 186 of file mac_via.h.

#define MON_15BW   (1<<3) /* 15" BW portrait. */

Definition at line 183 of file mac_via.h.

#define MON_15RGB   (5<<3) /* 15" RGB portrait. */

Definition at line 185 of file mac_via.h.

#define MON_IIGS   (2<<3) /* 12" color (modified IIGS monitor). */

Definition at line 184 of file mac_via.h.

#define MON_NONE   (7<<3) /* No monitor attached. */

Definition at line 187 of file mac_via.h.

#define rBufA   rSIFR /* the 'slot interrupts register' is BufA on a VIA */

Definition at line 174 of file mac_via.h.

#define rBufB   0x0000 /* [VIA/RBV] Register B */

Definition at line 166 of file mac_via.h.

#define RBV_BASE   (0x50F26000)

Definition at line 23 of file mac_via.h.

#define RBV_DEPTH   0x07 /* bits per pixel: 000=1,001=2,010=4,011=8 */

Definition at line 179 of file mac_via.h.

#define RBV_MONID   0x38 /* monitor type, as below. */

Definition at line 180 of file mac_via.h.

#define RBV_VIDOFF   0x40 /* 1 turns off onboard video */

Definition at line 181 of file mac_via.h.

#define rChpT   0x0011 /* [RBV only] RBV test mode register (reads as 0). */

Definition at line 171 of file mac_via.h.

#define rExp   0x0001 /* [RBV only] RBV future expansion (always 0) */

Definition at line 167 of file mac_via.h.

#define rIER   0x1c13 /* [VIA/RBV] RBV interrupt flag enable register. */

Definition at line 173 of file mac_via.h.

#define rIFR   0x1a03 /* [VIA/RBV] RBV interrupt flag register. */

Definition at line 169 of file mac_via.h.

#define rMonP   0x0010 /* [RBV only] RBV video monitor type. */

Definition at line 170 of file mac_via.h.

#define rSIER   0x0012 /* [RBV only] RBV slot interrupt enables. */

Definition at line 172 of file mac_via.h.

#define rSIFR   0x0002 /* [RBV only] RBV slot interrupts register. */

Definition at line 168 of file mac_via.h.

#define vACR   0x1600 /* [VIA only] Auxiliary control register. */

Definition at line 148 of file mac_via.h.

#define vBufA   0x1e00 /* [VIA/RBV] register A (no handshake) */

Definition at line 155 of file mac_via.h.

#define vBufAH   0x0200 /* [VIA only] Buffer A, with handshake. DON'T USE! */

Definition at line 138 of file mac_via.h.

#define vBufB   0x0000 /* [VIA/RBV] Register B */

Definition at line 137 of file mac_via.h.

#define vDirA   0x0600 /* [VIA only] Data Direction Register A. */

Definition at line 140 of file mac_via.h.

#define vDirB   0x0400 /* [VIA only] Data Direction Register B. */

Definition at line 139 of file mac_via.h.

#define VIA1_BASE   (0x50F00000)

Definition at line 21 of file mac_via.h.

#define VIA1A_CPUID0   0x02 /* CPU id bit 0 on RBV, others */

Definition at line 54 of file mac_via.h.

#define VIA1A_CPUID1   0x04 /* CPU id bit 0 on RBV, others */

Definition at line 55 of file mac_via.h.

#define VIA1A_CPUID2   0x10 /* CPU id bit 0 on RBV, others */

Definition at line 56 of file mac_via.h.

#define VIA1A_CPUID3   0x40 /* CPU id bit 0 on RBV, others */

Definition at line 57 of file mac_via.h.

#define VIA1A_vHeadSel
Value:
0x20 /* Head select for IWM.
* [CHRP] unused.
* [Macintosh Family] "Floppy disk
* state-control line SEL" on all but IIfx
*/

Definition at line 40 of file mac_via.h.

#define VIA1A_vOverlay
Value:
0x10 /* [Macintosh Family] On SE/30,II,IIx,IIcx
* this bit enables the "Overlay" address
* map in the address decoders as it is on
* reset for mapping the ROM over the reset
* vector. 1=use overlay map.
* On the IIci,IIfx it is another bit of the
* CPU ID: 0=normal IIci, 1=IIci with parity
* feature or IIfx.
* [CHRP] En WaitReqA: Lets the WaitReq_L
* signal from port A of the SCC appear
* on the PA7 input pin (CHRP). Output.
* [MkLinux] "Drive Select"
* (with 0x20 being 'disk head select')
*/

Definition at line 41 of file mac_via.h.

#define VIA1A_vRev8
Value:
0x40 /* Revision 8 board ???
* [CHRP] En WaitReqB: Lets the WaitReq_L
* signal from port B of the SCC appear on
* the PA7 input pin. Output.
* [Macintosh Family] On the SE/30, this
* is the bit to flip screen buffers.
* 0=alternate, 1=main.
* on II,IIx,IIcx,IIci,IIfx this is a bit
* for Rev ID. 0=II,IIx, 1=IIcx,IIci,IIfx
*/

Definition at line 39 of file mac_via.h.

#define VIA1A_vSccWrReq
Value:
0x80 /* SCC write. (input)
* [CHRP] SCC WREQ: Reflects the state of the
* Wait/Request pins from the SCC.
* [Macintosh Family Hardware]
* as CHRP on SE/30,II,IIx,IIcx,IIci.
* on IIfx, "0 means an active request"
*/

Definition at line 38 of file mac_via.h.

#define VIA1A_vSync
Value:
0x08 /* [CHRP] Sync Modem: modem clock select:
* 1: select the external serial clock to
* drive the SCC's /RTxCA pin.
* 0: Select the 3.6864MHz clock to drive
* the SCC cell.
* [Macintosh Family] Correct on all but IIfx
*/

Definition at line 42 of file mac_via.h.

#define VIA1A_vVolume   0x07 /* Audio volume mask for PWM */

Definition at line 53 of file mac_via.h.

#define VIA1B_vADBInt   0x08 /* ADB interrupt 0=interrupt (unused on IIfx)*/

Definition at line 65 of file mac_via.h.

#define VIA1B_vADBS1   0x10 /* ADB state input bit 0 (unused on IIfx) */

Definition at line 64 of file mac_via.h.

#define VIA1B_vADBS2   0x20 /* ADB state input bit 1 (unused on IIfx) */

Definition at line 63 of file mac_via.h.

#define VIA1B_vMystery
Value:
0x40 /* On IIci, parity enable. 0=enabled,1=disabled
* On SE/30, vertical sync interrupt enable.
* 0=enabled. This vSync interrupt shows up
* as a slot $E interrupt. */

Definition at line 62 of file mac_via.h.

#define VIA1B_vRTCClk   0x02 /* Real time clock serial-clock line. */

Definition at line 67 of file mac_via.h.

#define VIA1B_vRTCData   0x01 /* Real time clock serial-data line. */

Definition at line 68 of file mac_via.h.

#define VIA1B_vRTCEnb   0x04 /* Enable Real time clock. 0=enabled. */

Definition at line 66 of file mac_via.h.

#define VIA1B_vSound
Value:
0x80 /* Sound enable (for compatibility with
* PWM hardware) 0=enabled.
* Also, on IIci w/parity, shows parity error
* 0=error, 1=OK. */

Definition at line 61 of file mac_via.h.

#define VIA2_BASE   (0x50F02000)

Definition at line 22 of file mac_via.h.

#define VIA2A_vIRQ9   0x01 /* IRQ from slot $9 */

Definition at line 98 of file mac_via.h.

#define VIA2A_vIRQA   0x02 /* IRQ from slot $A */

Definition at line 97 of file mac_via.h.

#define VIA2A_vIRQB   0x04 /* IRQ from slot $B */

Definition at line 96 of file mac_via.h.

#define VIA2A_vIRQC   0x08 /* IRQ from slot $C */

Definition at line 95 of file mac_via.h.

#define VIA2A_vIRQD   0x10 /* IRQ from slot $D */

Definition at line 94 of file mac_via.h.

#define VIA2A_vIRQE   0x20 /* IRQ from slot $E */

Definition at line 93 of file mac_via.h.

#define VIA2A_vRAM0   0x40 /* RAM size bit 0 (IIci: internal video IRQ) */

Definition at line 92 of file mac_via.h.

#define VIA2A_vRAM1   0x80 /* RAM size bit 1 (IIci: reserved) */

Definition at line 91 of file mac_via.h.

#define VIA2B_vBusLk
Value:
0x02 /* Lock NuBus transactions, 0=locked.
* on SE/30 sent to PDS card. */

Definition at line 118 of file mac_via.h.

#define VIA2B_vCDis
Value:
0x01 /* Cache control. On IIci, 1=disable cache card
* on others, 0=disable processor's instruction
* and data caches. */

Definition at line 119 of file mac_via.h.

#define VIA2B_vMode32
Value:
0x08 /* 24/32bit switch - doubles as cache flush
* on II, AMU/PMMU control.
* if AMU, 0=24bit to 32bit translation
* if PMMU, 1=PMMU is accessing page table.
* on SE/30 tied low.
* on IIx,IIcx,IIfx, unused.
* on IIci/RBV, cache control. 0=flush cache.
*/

Definition at line 116 of file mac_via.h.

#define VIA2B_vPower
Value:
0x04 /* Power off, 0=shut off power.
* on SE/30 this signal sent to PDS card. */

Definition at line 117 of file mac_via.h.

#define VIA2B_vSndJck
Value:
0x40 /* External sound jack status.
* 0=plug is inserted. On SE/30, always 0 */

Definition at line 113 of file mac_via.h.

#define VIA2B_vTfr0   0x20 /* Transfer mode bit 0 ack from NuBus */

Definition at line 114 of file mac_via.h.

#define VIA2B_vTfr1   0x10 /* Transfer mode bit 1 ack from NuBus */

Definition at line 115 of file mac_via.h.

#define VIA2B_vVBL
Value:
0x80 /* VBL output to VIA1 (60.15Hz) driven by
* timer T1.
* on IIci, parity test: 0=test mode.
* [MkLinux] RBV_PARODD: 1=odd,0=even. */

Definition at line 112 of file mac_via.h.

#define vIER   0x1c00 /* [VIA/RBV] Interrupt enable register. */

Definition at line 154 of file mac_via.h.

#define vIFR   0x1a00 /* [VIA/RBV] Interrupt flag register. */

Definition at line 153 of file mac_via.h.

#define vPCR   0x1800 /* [VIA only] Peripheral control register. */

Definition at line 149 of file mac_via.h.

#define vSR   0x1400 /* [VIA only] Shift register. */

Definition at line 147 of file mac_via.h.

#define vT1CH   0x0a00 /* [VIA only] Timer one counter high. */

Definition at line 142 of file mac_via.h.

#define vT1CL   0x0800 /* [VIA only] Timer one counter low. */

Definition at line 141 of file mac_via.h.

#define vT1LH   0x0e00 /* [VIA only] Timer one latches high. */

Definition at line 144 of file mac_via.h.

#define vT1LL   0x0c00 /* [VIA only] Timer one latches low. */

Definition at line 143 of file mac_via.h.

#define vT2CH   0x1200 /* [VIA only] Timer two counter high. */

Definition at line 146 of file mac_via.h.

#define vT2CL   0x1000 /* [VIA only] Timer two counter low. */

Definition at line 145 of file mac_via.h.

Function Documentation

void via1_irq ( unsigned int  irq,
struct irq_desc desc 
)

Definition at line 450 of file via.c.

void via1_set_head ( int  )

Definition at line 609 of file via.c.

int via2_scsi_drq_pending ( void  )

Definition at line 618 of file via.c.

void via_irq_disable ( int  )

Definition at line 582 of file via.c.

void via_irq_enable ( int  )

Definition at line 550 of file via.c.

void via_nubus_irq_shutdown ( int  irq)

Definition at line 431 of file via.c.

void via_nubus_irq_startup ( int  irq)

Definition at line 409 of file via.c.

void via_register_interrupts ( void  )

Definition at line 536 of file via.c.

Variable Documentation

int rbv_present

Definition at line 41 of file via.c.

volatile __u8* via1

Definition at line 40 of file via.c.

volatile __u8 * via2

Definition at line 40 of file via.c.

int via_alt_mapping

Definition at line 42 of file via.c.