source: rtems/c/src/lib/libbsp/i960/cvme961/shmsupp/mpisr.c @ 08311cc3

4.104.114.84.95
Last change on this file since 08311cc3 was 08311cc3, checked in by Joel Sherrill <joel.sherrill@…>, on Nov 17, 1999 at 5:51:34 PM

Updated copyright notice.

  • Property mode set to 100644
File size: 2.1 KB
Line 
1/*  Shm_isr_cvme961()
2 *
3 *  NOTE: This routine is not used when in polling mode.  Either
4 *        this routine OR Shm_clockisr is used in a particular system.
5 *
6 *        There must be sufficient time after the IACK (read at
7 *        0xb600000x) for the VIC068 to clear the interrupt request
8 *        before the interrupt request is cleared from IPND (sf0).
9 *
10 *  COPYRIGHT (c) 1989-1999.
11 *  On-Line Applications Research Corporation (OAR).
12 *
13 *  The license and distribution terms for this file may be
14 *  found in the file LICENSE in this distribution or at
15 *  http://www.OARcorp.com/rtems/license.html.
16 *
17 *  $Id$
18 */
19
20#include <rtems.h>
21#include <bsp.h>
22#include "shm.h"
23
24rtems_isr Shm_isr_cvme961(
25  rtems_vector_number vector
26)
27{
28  rtems_unsigned32 vic_vector;
29
30  /* enable_tracing(); */
31  vic_vector = (*(volatile rtems_unsigned8 *)0xb6000007);
32                                           /* reset intr by reading */
33                                           /*   vector at IPL=3 */
34  Shm_Interrupt_count += 1;
35  rtems_multiprocessing_announce();
36  (*(volatile rtems_unsigned8 *)0xa000005f) = 0; /* clear ICMS0 */
37  i960_clear_intr( 6 );
38
39}
40
41/*  void _Shm_setvec( )
42 *
43 *  This driver routine sets the SHM interrupt vector to point to the
44 *  driver's SHM interrupt service routine.
45 *
46 *  NOTE: See pp. 21-22, 36-39 of the CVME961 Manual for more info.
47 *
48 *  Input parameters:  NONE
49 *
50 *  Output parameters: NONE
51 */
52
53void Shm_setvec()
54{
55  rtems_unsigned32 isrlevel;
56
57  rtems_interrupt_disable( isrlevel );
58                                        /* set SQSIO4 CTL REG for */
59                                        /*   VME slave address */
60    (*(rtems_unsigned8 *)0xc00000b0) =
61      (Shm_RTEMS_MP_Configuration->node - 1) | 0x10;
62    set_vector( Shm_isr_cvme961, 6, 1 );
63                                        /* set ICMS Bector Base Register */
64    (*(rtems_unsigned8 *)0xa0000053) = 0x60;  /* XINT6 vector is 0x62 */
65                                        /* set  ICMS Intr Control Reg */
66    (*(rtems_unsigned8 *)0xa0000047) = 0xeb;  /* ICMS0 enabled, IPL=0 */
67    (*(rtems_unsigned8 *)0xa000005f) = 0;     /* clear ICMS0 */
68  rtems_interrupt_enable( isrlevel );
69}
Note: See TracBrowser for help on using the repository browser.