Changeset f05b2ac in rtems for c/src/lib/libbsp/m68k


Ignore:
Timestamp:
Apr 21, 2004, 4:01:48 PM (16 years ago)
Author:
Ralf Corsepius <ralf.corsepius@…>
Branches:
4.10, 4.11, 4.8, 4.9, 5, master
Children:
7dd6e8d
Parents:
6128a4a
Message:

Remove duplicate white lines.

Location:
c/src/lib/libbsp/m68k
Files:
70 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/m68k/dmv152/configure.ac

    r6128a4a rf05b2ac  
    2424[set to 1 to indicate this serial port to be used as RTEMS_CONSOLE])
    2525
    26 
    2726# Explicitly list all Makefiles here
    2827AC_CONFIG_FILES([Makefile])
  • c/src/lib/libbsp/m68k/dmv152/console/console.c

    r6128a4a rf05b2ac  
    111111  /* should enable interrupts here */
    112112}
    113 
    114113
    115114/*
  • c/src/lib/libbsp/m68k/dmv152/timer/timer.c

    r6128a4a rf05b2ac  
    1717 *  $Id$
    1818 */
    19 
    2019
    2120#include <rtems.h>
  • c/src/lib/libbsp/m68k/gen68302/console/console.c

    r6128a4a rf05b2ac  
    123123}
    124124
    125 
    126125/*  inbyte
    127126 *
     
    155154    return ch;
    156155}
    157 
    158156
    159157/*  outbyte
  • c/src/lib/libbsp/m68k/gen68302/include/m302_int.h

    r6128a4a rf05b2ac  
    4343#define EDMA_BLIM_MASK      0x0007
    4444#define EDMA_BLIM_8ACCESS    0x0003
    45 
    4645
    4746/* Ethernet Maximum Receive Buffer Length EMRBLR */
     
    104103
    105104#define AR_CNTRL_MULTI_MASK      (AR_CNTRL_BIT_MULTI0 | AR_CNTRL_BIT_MULTI1)
    106 
    107105
    108106/* Ethernet buffer Status TX */
     
    120118#define BUF_STAT_TO              0x4000
    121119#define BUF_STAT_READY          0x8000
    122 
    123120
    124121/* Ethernet buffer Status RX */
     
    281278  uchar  reserved_3[0x74A];
    282279
    283 
    284 
    285280/****************** 68 EN 302 specific registers **********************/
    286281/** only available here if
     
    303298
    304299  uchar  dram_reserved[0x7E8];
    305 
    306300
    307301    /* Ethernet Controller Registers */
     
    388382#define M68302imp_sccs(i)            (M68302imp_ scc_regs[i].sccs)
    389383
    390 
    391384/*----------------------------------------------------------------------------*/
    392385
     
    399392#define M68en302imp_drfrsh           (M68302imp_ drfrsh)
    400393#define M68en302imp_dba(i)           (M68302imp_ dba[i])
    401 
    402394
    403395#define M68en302imp_ecntrl           (M68302imp_ ecntrl)
     
    518510#define M68302_CS_READ_AND_WRITE 0x00 /* read and write memory access */
    519511
    520 
    521512#define M68302_cs_install(cs_nb,base_add,range,nb_wait_state,read_write) \
    522513  do { \
  • c/src/lib/libbsp/m68k/gen68302/network/network.c

    r6128a4a rf05b2ac  
    159159#define FDE             0x0020
    160160
    161 
    162 
    163161        /*
    164162         * standard loopback
     
    166164        M68302imp_port_data     (1) &= ~(LBK);
    167165        M68302imp_port_data     (1) |= (FDE);
    168 
    169166
    170167        M68en302imp_ecntrl=0x0001;
     
    189186         */
    190187        M68en302imp_intr_vect = M302_ETHER_IVECTOR;
    191 
    192188
    193189        M68en302imp_intr_mask=0x0;
     
    233229        cam[6] = (hwaddr[4] << 8) | hwaddr[5];
    234230
    235 
    236231        /*
    237232         * Set receiver and transmitter buffer descriptor bases
    238233         */
    239234        a_bd = M68302imp_a_eth_bd (0);                  /* point to first BD */
    240 
    241235
    242236        for (i=0;i<128;i++){
     
    246240                M68302_scc_bd_p_buffer  (a_bd + i) = NULL;
    247241        }
    248 
    249242
    250243        sc->txBdBase = M68302imp_a_eth_bd (  0 );                       /* point to first BD */
     
    306299                                BUF_STAT_UNDERRUN)) {
    307300                        int j;
    308 
    309301
    310302                        if (status & BUF_STAT_LATE_COLLISION)
     
    404396                rxBd->p_buffer = mtod (m, void *);
    405397
    406 
    407398                if (++rxBdIndex == sc->rxBdCount) {
    408399                        rxBd->stat_ctrl = BUF_STAT_EMPTY | BUF_STAT_INTERRUPT | BUF_STAT_WRAP;
     
    452443                        }
    453444                }
    454 
    455445
    456446                /*
     
    778768                m302Enet_initialize_hardware (sc);
    779769
    780 
    781770                sc->txDaemonTid = rtems_bsdnet_newproc ("SCtx", 4096, scc_txDaemon, sc);
    782771                sc->rxDaemonTid = rtems_bsdnet_newproc ("SCrx", 4096, scc_rxDaemon, sc);
     
    821810
    822811}
    823 
    824812
    825813/*
     
    904892}
    905893
    906 
    907894/*
    908895 * Attach an SCC driver to the system
  • c/src/lib/libbsp/m68k/gen68302/start/start.S

    r6128a4a rf05b2ac  
    4141  .set  FLASH_BASE,     0xc00000        | start of FLASH''s normal location
    4242
    43 
    4443BEGIN_CODE
    4544         PUBLIC (M68Kvec)               | Vector Table
     
    233232END_CODE
    234233
    235 
    236234BEGIN_DATA
    237235
     
    258256        .set   SYM (stack_size),0x1000
    259257
    260 
    261258END_DATA
    262259END
  • c/src/lib/libbsp/m68k/gen68302/timer/timer.c

    r6128a4a rf05b2ac  
    2020 */
    2121
    22 
    2322#include <rtems.h>
    2423#include <bsp.h>
    2524#include <rtems/m68k/m68302.h>
    26 
    2725
    2826#define TMR2_VAL 0x071b /* Timer mode register
     
    111109}
    112110
    113 
    114111/*
    115112 *  Empty function call used in loops to measure basic cost of looping
  • c/src/lib/libbsp/m68k/gen68340/console/Modif_cpu_asm.S

    r6128a4a rf05b2ac  
    1515 *  $Id$
    1616 */
    17 
    1817
    1918#include <rtems/asm.h>
     
    7675        movew   a7@(SAVED+FVO_OFFSET),d0 | d0 = F/VO
    7776        andl    #0x0fff,d0               | d0 = vector offset in vbr
    78 
    7977
    8078#if ( CPU_HAS_SOFTWARE_INTERRUPT_STACK == 1 )
     
    148146        beq     Debug_exit               | No, then Debug_exit
    149147
    150 
    151148bframe: clrl    SYM (_ISR_Signals_to_thread_executing)
    152149                                         | If sent, will be processed
  • c/src/lib/libbsp/m68k/gen68340/include/m340timer.h

    r6128a4a rf05b2ac  
    7878#define m340_COM                (1<<8)
    7979
    80 
    8180#endif
  • c/src/lib/libbsp/m68k/gen68340/start/start.S

    r6128a4a rf05b2ac  
    623623/*      move.b          #0x3F,crt0_pdcs                                         pour test */
    624624
    625 
    626625        /*---------------------------------------*/
    627626        /* -- EPLD chip-select initialization -- */
     
    720719        move.l          #68349,crt0_cpu_type
    721720
    722 
    723721        /* -- jump back to PROM -- */
    724722
     
    762760        move.b  #0,crt0_csswitch                                | CPU
    763761        move.b  #1,crt0_buswidth                                | 16 bits
    764 
    765762
    766763        /*-------------------------------------------------
  • c/src/lib/libbsp/m68k/gen68340/start/startfor340only.S

    r6128a4a rf05b2ac  
    336336_crt0_init_stktop:
    337337
    338 
    339338BEGIN_CODE
    340339        dc.l    _crt0_init_stktop        /* reset SP */
  • c/src/lib/libbsp/m68k/gen68360/network/network.c

    r6128a4a rf05b2ac  
    859859}
    860860
    861 
    862861/*
    863862 * Show interface statistics
  • c/src/lib/libbsp/m68k/gen68360/startup/bspstart.c

    r6128a4a rf05b2ac  
    5959   */
    6060
    61 
    6261  /*
    6362   *  Allocate the memory for the RTEMS Work Space.  This can come from
  • c/src/lib/libbsp/m68k/idp/clock/ckinit.c

    r6128a4a rf05b2ac  
    4848rtems_device_major_number rtems_clock_major = ~0;
    4949rtems_device_minor_number rtems_clock_minor;
    50 
    5150
    5251/*
  • c/src/lib/libbsp/m68k/idp/console/console.c

    r6128a4a rf05b2ac  
    7575}
    7676
    77 
    7877/*  is_character_ready
    7978 *
     
    146145  return tmp_char;
    147146}
    148 
    149147
    150148/*  outbyte
  • c/src/lib/libbsp/m68k/idp/console/duart.c

    r6128a4a rf05b2ac  
    153153  MC68681_WRITE(DUART_ADDR, MC68681_CLOCK_SELECT_REG_B, MC68681_BAUD_RATE_MASK_9600);
    154154
    155 
    156155#define EIGHT_BITS_NO_PARITY
    157156#ifdef EIGHT_BITS_NO_PARITY
     
    168167                (MC68681_WITH_PARITY |  MC68681_7BIT_CHARS) );
    169168#endif
    170 
    171169
    172170  /*
     
    247245}
    248246
    249 
    250247/*#####################################################################
    251248# This is the routine that actually transmits a character one at a time
  • c/src/lib/libbsp/m68k/idp/startup/bspstart.c

    r6128a4a rf05b2ac  
    7979    M68Kvec[ index ] = monitors_vector_table[ 32 ];
    8080
    81 
    8281  M68Kvec[  2 ] = monitors_vector_table[  2 ];   /* bus error vector */
    8382  M68Kvec[  4 ] = monitors_vector_table[  4 ];   /* breakpoints vector */
  • c/src/lib/libbsp/m68k/idp/timer/timer.c

    r6128a4a rf05b2ac  
    2525 *  $Id$
    2626 */
    27 
    2827
    2928#include <rtems.h>
  • c/src/lib/libbsp/m68k/mcf5206elite/console/console.c

    r6128a4a rf05b2ac  
    2121#include "mcf5206/mcf5206e.h"
    2222#include "mcf5206/mcfuart.h"
    23 
    2423
    2524/* Descriptor structures for two on-chip UART channels */
  • c/src/lib/libbsp/m68k/mcf5206elite/i2c/i2c.c

    r6128a4a rf05b2ac  
    156156}
    157157
    158 
    159158/* i2c_write --
    160159 *     Send single message over specified I2C bus to addressed device and
  • c/src/lib/libbsp/m68k/mcf5206elite/i2c/i2cdrv.c

    r6128a4a rf05b2ac  
    7979/* Forward function declaration */
    8080static void i2cdrv_unload(void);
    81 
    8281
    8382/* i2cdrv_done --
     
    190189}
    191190
    192 
    193191/* i2cdrv_initialize --
    194192 *     I2C driver initialization (rtems I/O driver primitive)
     
    250248}
    251249
    252 
    253250/* i2c_poll --
    254251 *     Poll I2C bus controller for events and hanle it. This function is
  • c/src/lib/libbsp/m68k/mcf5206elite/include/bsp.h

    r6128a4a rf05b2ac  
    2727
    2828/*** Board resources allocation ***/
    29 
    3029
    3130/*
  • c/src/lib/libbsp/m68k/mcf5206elite/nvram/nvram.c

    r6128a4a rf05b2ac  
    2525#include <i2c.h>
    2626#include <ds1307.h>
    27 
    2827
    2928/* nvram_driver_initialize --
  • c/src/lib/libbsp/m68k/mcf5206elite/start/start.S

    r6128a4a rf05b2ac  
    415415        jmp     _unexp_int
    416416
    417 
    418417END_CODE
    419418
  • c/src/lib/libbsp/m68k/mcf5206elite/startup/init5206e.c

    r6128a4a rf05b2ac  
    6060#define mcf5206e_enable_cache() \
    6161  m68k_set_cacr( MCF5206E_CACR_CENB )
    62 
    6362
    6463#define mcf5206e_disable_cache() \
  • c/src/lib/libbsp/m68k/mrm332/console/console.c

    r6128a4a rf05b2ac  
    139139  rtems_termios_initialize();
    140140
    141 
    142141  /*
    143142   * register the SCI device name for termios
     
    151150    rtems_fatal_error_occurred(status);
    152151  }
    153 
    154152
    155153  /*
  • c/src/lib/libbsp/m68k/mrm332/console/sci.c

    r6128a4a rf05b2ac  
    3737*
    3838* $Log$
     39* Revision 1.7  2004/04/21 10:42:52  ralf
     40* Remove stray white spaces.
     41*
    3942* Revision 1.6  2004/04/15 13:26:13  ralf
    4043* Remove stray white spaces.
     
    167170#define SCI_MINOR       0                   // minor device number
    168171
    169 
    170172// IMPORTANT - if the device driver api is opened, it means the sci is being
    171173// used for direct hardware access, so other users (like termios) get ignored
     
    173175#define DRIVER_CLOSED   0                   // the device driver api is closed
    174176#define DRIVER_OPENED   1                   // the device driver api is opened
    175 
    176177
    177178// system clock definitions, i dont have documentation on this...
     
    197198
    198199
    199 
    200200/*****************************************************************************
    201201  Section D - External Functions
     
    275275static struct rtems_termios_tty *SciTermioTty;
    276276
    277 
    278277static uint8_t   SciInited = 0;             // has the driver been inited
    279278
     
    300299
    301300#endif
    302 
    303301
    304302// cvs id string so you can use the unix ident command on the object
     
    349347};
    350348
    351 
    352349/*****************************************************************************
    353350  Section I - RTEMS termios callbacks for the polled version of the driver
     
    375372/////////////////////////////////////////////////////////////////////////////
    376373
    377 
    378374/****************************************************************************
    379375* Func:     SCI_output_char
     
    433429    uint8_t   ch;
    434430
    435 
    436431    if ( (*SCSR) & SCI_ERROR_PARITY  )   SciErrorsParity  ++;
    437432    if ( (*SCSR) & SCI_ERROR_FRAMING )   SciErrorsFraming ++;
    438433    if ( (*SCSR) & SCI_ERROR_NOISE   )   SciErrorsNoise   ++;
    439434    if ( (*SCSR) & SCI_ERROR_OVERRUN )   SciErrorsOverrun ++;
    440 
    441435
    442436    // see if it was a transmit interrupt
     
    489483/////////////////////////////////////////////////////////////////////////////
    490484
    491 
    492485/****************************************************************************
    493486* Func:     SciRcvBufGetChar
     
    524517    return ch;                                  // return the char
    525518}
    526 
    527519
    528520
     
    601593//
    602594/////////////////////////////////////////////////////////////////////////////
    603 
    604595
    605596/****************************************************************************
     
    653644    SciSetDataBits(SCI_8_DATA_BITS);            // set data bits to 8
    654645
    655 
    656646    // Install our interrupt handler into RTEMS, where does 66 come from?
    657647
     
    799789    }
    800790
    801 
    802791    //  set the number of data bits, 8 is most common
    803792
     
    815804    }
    816805
    817 
    818806    //  the number of stop bits; always 1 for SCI
    819807
     
    823811    }
    824812
    825 
    826813    // setup the hardware with these serial port parameters
    827814
     
    831818
    832819    SciSetDataBits(sci_databits);               // set the data bits
    833 
    834820
    835821    return RTEMS_SUCCESSFUL;
     
    1003989//
    1004990/////////////////////////////////////////////////////////////////////////////
    1005 
    1006991
    1007992/****************************************************************************
     
    10261011//printk("%s\r\n", __FUNCTION__);
    10271012
    1028 
    10291013    // register the SCI device name for termios console i/o
    10301014    // this is done over in console.c which doesn't seem exactly right
     
    10361020//      rtems_fatal_error_occurred(status);
    10371021
    1038 
    10391022    SciMajor = major;                           // save the rtems major number
    10401023
    10411024    SciOpened = DRIVER_CLOSED;                  // initial state is closed
    10421025
    1043 
    10441026    // if you have an interrupt handler, install it here
    1045 
    10461027
    10471028    SciInited = 1;                              // set the inited flag
     
    11581139    rw_args = (rtems_libio_rw_args_t *) arg;    // arguments to read()
    11591140
    1160 
    11611141    if (minor != SCI_MINOR)
    11621142    {
     
    13131293/////////////////////////////////////////////////////////////////////////////
    13141294
    1315 
    13161295/****************************************************************************
    13171296* Func:     SciSetBaud
     
    13301309// when you open the console you need to set the termio struct baud rate
    13311310// it has a default value of 9600, when someone calls tcsetattr it reverts!
    1332 
    13331311
    13341312    SciBaud = rate;                             // save the rate
     
    15361514}
    15371515
    1538 
    15391516/****************************************************************************
    15401517* Func:     SciWriteCharNoWait
     
    15921569}
    15931570
    1594 
    15951571/****************************************************************************
    15961572* Func:     SciReadCharNoWait
     
    16151591    return ch;                                  // return the char
    16161592}
    1617 
    16181593
    16191594
     
    16691644/////////////////////////////////////////////////////////////////////////////
    16701645
    1671 
    16721646/****************************************************************************
    16731647* Func:     SciUnitTest
     
    16871661    uint16_t   result;                          // result of ioctl
    16881662
    1689 
    16901663    fd = open("/dev/sci",O_RDWR);               // open the device
    16911664
    16921665printk("SCI open fd=%d\r\n",fd);
    16931666
    1694 
    16951667    result = write(fd, "abcd\r\n", 6);          // send a string
    16961668
    16971669printk("SCI write result=%d\r\n",result);
    1698 
    16991670
    17001671    result = read(fd, &byte, 1);                // read a byte
  • c/src/lib/libbsp/m68k/mrm332/console/sci.h

    r6128a4a rf05b2ac  
    99****************************************************************************/
    1010
    11 
    1211#ifndef _sci_h_
    1312#define _sci_h_
    14 
    1513
    1614/*******************************************************************************
     
    4846
    4947
    50 
    5148/*******************************************************************************
    5249  SCI Registers
    5350*******************************************************************************/
    54 
    5551
    5652// SCI Control Register 0  (SCCR0)  $FFFC08
     
    8177//  0 0 0 0 - 0 0 0 0 - 0 0 0 0 - 0 1 0 0       reset value - (64k baud?)
    8278
    83 
    8479#define SCI_BAUD_57_6K            9
    8580#define SCI_BAUD_38_4K           14
     
    8984#define SCI_BAUD_2400           218
    9085#define SCI_BAUD_1200           437
    91 
    9286
    9387
     
    186180//  0 0 0 0 - 0 0 0 1 - 1 0 0 0 - 0 0 0 0       reset value
    187181
    188 
    189182#define SCI_ERROR_PARITY        0x0001          // 0000-0000-0000-0001
    190183#define SCI_ERROR_FRAMING       0x0002          // 0000-0000-0000-0010
     
    216209#endif
    217210
    218 
    219211// look at console_open to see how this is called
    220212
    221213const rtems_termios_callbacks * SciGetTermiosHandlers( int32_t   polled );
    222214
    223 
    224215/* SCI interrupt */
    225216
    226217//rtems_isr SciIsr( rtems_vector_number vector );
    227 
    228218
    229219//int32_t   SciOpenPolled    ( int32_t   major, int32_t   minor, void *arg );
     
    238228
    239229//int32_t   SciSetAttributes ( int32_t   minor, const struct termios *t );
    240 
    241230
    242231#ifdef __cplusplus
     
    244233#endif
    245234
    246 
    247235#endif  // _sci_h_
  • c/src/lib/libbsp/m68k/mrm332/include/mrm332.h

    r6128a4a rf05b2ac  
    77#define _MRM332_H_
    88
    9 
    109/* SIM_MM (SIM Module Mapping) determines the location of the control
    1110   register block. When MM=0, register addresses range fom 0x7ff000 to
     
    1312   0xffffff. */
    1413#define SIM_MM 1
    15 
    1614
    1715/* Interrupt related definitions */
     
    2826#define EFI_INT1 25             /* CTS interrupt */
    2927#define ISRL_SCI 6
    30 
    31 
    3228
    3329/* System Clock definitions */
     
    5854#define SCI_BAUD 19200          /* RS232 Baud Rate */
    5955
    60 
    6156/* macros/functions */
    6257
  • c/src/lib/libbsp/m68k/mrm332/start/start.S

    r6128a4a rf05b2ac  
    2525        movel  d0,sp
    2626        movel  d0,a6
    27 
    2827
    2928  /* include in ram_init.S */
  • c/src/lib/libbsp/m68k/mrm332/startup/except_vect_332_ROM.S

    r6128a4a rf05b2ac  
    281281        .long reboot   /* exception vector: 255 */
    282282
    283 
    284283_reboot:
    285284        move    #0x2700,%sr     /* mask interrupts */
  • c/src/lib/libbsp/m68k/mrm332/timer/timer.c

    r6128a4a rf05b2ac  
    1919 *  $Id$
    2020 */
    21 
    2221
    2322#include <bsp.h>
     
    6564}
    6665
    67 
    6866/*
    6967 *  Empty function call used in loops to measure basic cost of looping
  • c/src/lib/libbsp/m68k/mvme136/console/console.c

    r6128a4a rf05b2ac  
    5151}
    5252
    53 
    5453/*  is_character_ready
    5554 *
     
    9190  return _Read_m681->rbb;
    9291}
    93 
    9492
    9593/*  outbyte
  • c/src/lib/libbsp/m68k/mvme136/include/bsp.h

    r6128a4a rf05b2ac  
    9090#define FRAMEERR      0x40               /* status reg frame error mask */
    9191
    92 
    9392#define FOREVER       1                  /* infinite loop */
    9493
  • c/src/lib/libbsp/m68k/mvme136/timer/timer.c

    r6128a4a rf05b2ac  
    2323 *  $Id$
    2424 */
    25 
    2625
    2726#include <bsp.h>
  • c/src/lib/libbsp/m68k/mvme147/clock/ckinit.c

    r6128a4a rf05b2ac  
    4343rtems_device_major_number rtems_clock_major = ~0;
    4444rtems_device_minor_number rtems_clock_minor;
    45 
    4645
    4746/*
  • c/src/lib/libbsp/m68k/mvme147/console/console.c

    r6128a4a rf05b2ac  
    2323#include <rtems/libio.h>
    2424#include <rtems/zilog/z8530.h>
    25 
    2625
    2726/*  console_initialize
  • c/src/lib/libbsp/m68k/mvme147/include/bsp.h

    r6128a4a rf05b2ac  
    9595#define z8530 0xfffe3001
    9696
    97 
    9897/* interrupt vectors - see MVME146/D1 4.14 */
    9998#define PCC_BASE_VECTOR        0x40 /* First user int */
     
    114113#define CONSOLE_DATA     0xfffe3001
    115114#endif
    116 
    117 
    118115
    119116#define FOREVER       1                  /* infinite loop */
     
    156153#define Lower_tm27_intr()
    157154
    158 
    159155/* miscellaneous stuff assumed to exist */
    160156
  • c/src/lib/libbsp/m68k/mvme147s/include/bsp.h

    r6128a4a rf05b2ac  
    130130#define vme_lcsr      ((volatile struct vme_lcsr_map * const) 0xfffe2000)
    131131
    132 
    133132struct vme_gcsr_map {
    134133  uint8_t         unused_1;
     
    152151#define vme_gcsr      ((volatile struct vme_gcsr_map * const) 0xfffe2020)
    153152
    154 
    155 
    156153#define z8530 0xfffe3001
    157 
    158154
    159155/* interrupt vectors - see MVME147/D1 4.14 */
     
    179175#endif
    180176
    181 
    182 
    183177#define FOREVER       1                  /* infinite loop */
    184178
     
    220214#define Lower_tm27_intr()
    221215
    222 
    223216/* miscellaneous stuff assumed to exist */
    224217
  • c/src/lib/libbsp/m68k/mvme147s/startup/bspstart.c

    r6128a4a rf05b2ac  
    9494  }
    9595
    96 
    9796  node_number =
    9897    (uint8_t)
  • c/src/lib/libbsp/m68k/mvme162/clock/ckinit.c

    r6128a4a rf05b2ac  
    4646rtems_device_major_number rtems_clock_major = ~0;
    4747rtems_device_minor_number rtems_clock_minor;
    48 
    4948
    5049/*
  • c/src/lib/libbsp/m68k/mvme162/include/bsp.h

    r6128a4a rf05b2ac  
    4444
    4545#include <mvme16x_hw.h>
    46 
    4746
    4847/*----------------------------------------------------------------*/
  • c/src/lib/libbsp/m68k/mvme162/include/tod.h

    r6128a4a rf05b2ac  
    1717 *  $Id$
    1818 */
    19 
    2019
    2120#ifndef TOD_H
  • c/src/lib/libbsp/m68k/mvme162/startup/page_table.c

    r6128a4a rf05b2ac  
    7171    return addr;
    7272}
    73 
    74 
    7573
    7674/*
  • c/src/lib/libbsp/m68k/mvme162/timer/timer.c

    r6128a4a rf05b2ac  
    7979}
    8080
    81 
    8281rtems_status_code Empty_function( void )
    8382{
  • c/src/lib/libbsp/m68k/mvme162/tools/sload.c

    r6128a4a rf05b2ac  
    2323#include <string.h>
    2424#include <ctype.h>
    25 
    2625
    2726#include <sys/types.h>
  • c/src/lib/libbsp/m68k/mvme167/clock/ckinit.c

    r6128a4a rf05b2ac  
    5959volatile uint32_t         Clock_driver_ticks;
    6060
    61 
    6261/*
    6362 *  Clock_isrs is the number of clock ISRs until the next invocation of the
     
    7170uint32_t         Clock_isrs;
    7271
    73 
    7472/*
    7573 *  Records the previous clock ISR (should be NULL)
     
    7775rtems_isr_entry  Old_ticker;
    7876
    79 
    8077/*
    8178 *  Called when the kernel exits.
    8279 */
    8380void clock_exit( void );
    84 
    8581
    8682/*
     
    132128    Clock_isrs -= overflow;
    133129}
    134 
    135130
    136131/*
     
    172167}
    173168
    174 
    175169/*
    176170 *  clock_exit
     
    194188  set_vector( Old_ticker, CLOCK_VECTOR, 1 );
    195189}
    196 
    197190
    198191/*
     
    229222  return RTEMS_SUCCESSFUL;
    230223}
    231 
    232224
    233225/*
  • c/src/lib/libbsp/m68k/mvme167/console/console-recording.h

    r6128a4a rf05b2ac  
    2525#define CD2401_RECORD_DELAY
    2626
    27 
    2827/* Call the data recording functions */
    2928#ifdef CD2401_RECORD_WRITE
     
    104103#define CD2401_RECORD_DELAY_INFO( args )
    105104#endif
    106 
    107105
    108106/* Define the data and the recording functions */
     
    124122#define CD2401_DRAIN_OUTPUT_INFO      14
    125123#define CD2401_DELAY_INFO             15
    126 
    127124
    128125struct cd2401_debug_info {
     
    245242}
    246243
    247 
    248244void cd2401_record_write_info(
    249245  int len,
     
    266262  cd2401_debug_index = (cd2401_debug_index + 1 ) % CD2401_DEBUG_BUFFER_SIZE;
    267263}
    268 
    269264
    270265void cd2401_record_tx_isr_info(
     
    288283  cd2401_debug_index = (cd2401_debug_index + 1 ) % CD2401_DEBUG_BUFFER_SIZE;
    289284}
    290 
    291285
    292286void cd2401_record_tx_isr_spurious_info(
     
    313307}
    314308
    315 
    316309void cd2401_record_tx_isr_buserr_info(
    317310  unsigned char ch,
     
    337330}
    338331
    339 
    340332void cd2401_record_rx_isr_info(
    341333  unsigned char ch,
     
    357349  cd2401_debug_index = (cd2401_debug_index + 1 ) % CD2401_DEBUG_BUFFER_SIZE;
    358350}
    359 
    360351
    361352void cd2401_record_rx_isr_spurious_info(
     
    378369}
    379370
    380 
    381371void cd2401_record_re_isr_spurious_info(
    382372  unsigned char ch,
     
    396386}
    397387
    398 
    399388void cd2401_record_modem_isr_spurious_info(
    400389  unsigned char ch,
     
    414403}
    415404
    416 
    417405void cd2401_record_first_open_info(
    418406  unsigned char ch,
     
    430418}
    431419
    432 
    433420void cd2401_record_last_close_info(
    434421  unsigned char ch,
     
    446433}
    447434
    448 
    449435void cd2401_record_start_remote_tx_info(
    450436  unsigned char ch
     
    460446}
    461447
    462 
    463448void cd2401_record_stop_remote_tx_info(
    464449  unsigned char ch
     
    473458  cd2401_debug_index = (cd2401_debug_index + 1 ) % CD2401_DEBUG_BUFFER_SIZE;
    474459}
    475 
    476460
    477461void cd2401_record_set_attributes_info(
     
    531515}
    532516
    533 
    534517void cd2401_record_drain_output_info(
    535518  uint8_t         txEmpty,
     
    548531  cd2401_debug_index = (cd2401_debug_index + 1 ) % CD2401_DEBUG_BUFFER_SIZE;
    549532}
    550 
    551533
    552534void cd2401_record_delay_info(
     
    568550  cd2401_debug_index = (cd2401_debug_index + 1 ) % CD2401_DEBUG_BUFFER_SIZE;
    569551}
    570 
    571552
    572553#else
  • c/src/lib/libbsp/m68k/mvme167/console/console.c

    r6128a4a rf05b2ac  
    158158int _167Bug_pollWrite( int minor, const char *buf, int len );
    159159
    160 
    161160/* Printk function */
    162161static void _BSP_output_char( char c );
    163162BSP_output_char_function_type BSP_output_char = _BSP_output_char;
    164 
    165163
    166164/* Channel info */
     
    189187uint8_t         Init_count;
    190188
    191 
    192189/* Record previous handlers */
    193190rtems_isr_entry Prev_re_isr;        /* Previous rx exception isr */
     
    196193rtems_isr_entry Prev_modem_isr;     /* Previous modem/timer isr */
    197194
    198 
    199195/* Define the following symbol to trace the calls to this driver */
    200196/* #define CD2401_RECORD_DEBUG_INFO */
    201197#include "console-recording.h"
    202198
    203 
    204199/*
    205200 *  Utility functions.
     
    236231  CD2401_RECORD_DELAY_INFO(( start_ticks, end_ticks, current_ticks, i ));
    237232}
    238 
    239233
    240234/*
     
    274268  }
    275269}
    276 
    277270
    278271/*
     
    314307  return( clksource | divisor );
    315308}
    316 
    317309
    318310/*
     
    402394}
    403395
    404 
    405396/*
    406397 *  cd2401_interrupts_initialize
     
    446437}
    447438
    448 
    449439/* ISRs */
    450440
     
    481471                                          CD2401_Channel_Info[ch].spur_cnt ));
    482472}
    483 
    484473
    485474/*
     
    519508                                       CD2401_Channel_Info[ch].spur_cnt ));
    520509}
    521 
    522510
    523511/*
     
    568556}
    569557
    570 
    571558/*
    572559 *  cd2401_tx_isr
     
    664651  }
    665652}
    666 
    667653
    668654/*
     
    752738}
    753739
    754 
    755740/*
    756741 * cd2401_lastClose
     
    794779  return RTEMS_SUCCESSFUL;
    795780}
    796 
    797781
    798782/*
     
    10841068}
    10851069
    1086 
    10871070/*
    10881071 *  cd2401_startRemoreTx
     
    11241107  return RTEMS_SUCCESSFUL;
    11251108}
    1126 
    11271109
    11281110/*
     
    11671149}
    11681150
    1169 
    11701151/*
    11711152 *  cd2401_write
     
    12671248#endif
    12681249
    1269 
    12701250/*
    12711251 * _167Bug_pollRead
     
    13251305}
    13261306
    1327 
    13281307/*
    13291308 * _167Bug_pollWrite
     
    13631342}
    13641343
    1365 
    13661344/*
    13671345 *  do_poll_read
     
    14431421  return RTEMS_SUCCESSFUL;
    14441422}
    1445 
    14461423
    14471424/*
     
    14691446      _167Bug_pollWrite(printk_minor, &cr, 1);
    14701447}
    1471 
    14721448
    14731449/*
     
    16021578}
    16031579
    1604 
    16051580/*
    16061581 * Close the device
     
    16321607}
    16331608
    1634 
    16351609/*
    16361610 * Read from the device
     
    16621636}
    16631637
    1664 
    16651638/*
    16661639 * Write to the device
     
    16921665}
    16931666
    1694 
    16951667/*
    16961668 * Handle ioctl request.
  • c/src/lib/libbsp/m68k/mvme167/fatal/bspfatal.c

    r6128a4a rf05b2ac  
    4141  return i;
    4242}
    43 
    4443
    4544/*
  • c/src/lib/libbsp/m68k/mvme167/include/bsp.h

    r6128a4a rf05b2ac  
    2121#ifndef __MVME167_H
    2222#define __MVME167_H
    23 
    2423
    2524#ifdef __cplusplus
     
    3433#include <rtems/iosupp.h>
    3534#include <rtems/bspIo.h>
    36 
    3735
    3836/*
     
    143141#define memc040_2   ((memc040_regs * const) 0xFFF43100)
    144142
    145 
    146143/*
    147144 *  The MVME167 may be equiped with error-correcting RAM cards. In this case,
     
    154151 *  can be used to read those first eight registers.
    155152 */
    156 
    157153
    158154/*
     
    299295} cd2401_regs;
    300296
    301 
    302297/*
    303298 *  Base address of the CD2401.
     
    305300 */
    306301#define cd2401          ((cd2401_regs * const) 0xFFF45000)
    307 
    308302
    309303/* CD2401 is clocked at 20 MHz */
     
    346340#define BSP_LIBIO_MAX_FDS       20
    347341
    348 
    349342/* miscellaneous stuff assumed to exist */
    350343
     
    352345
    353346extern m68k_isr_entry M68Kvec[];   /* vector table address */
    354 
    355347
    356348/*
  • c/src/lib/libbsp/m68k/mvme167/network/network.c

    r6128a4a rf05b2ac  
    5050#define NIC_RESET_EVENT         RTEMS_EVENT_3
    5151
    52 
    5352#include <bsp.h>
    5453#include <stdio.h>
     
    120119  0x3f    /* Byte 13: no multi IA, backoff enabled */
    121120};
    122 
    123121
    124122/* Local Routines */
     
    156154static void send_packet ( struct ifnet *, struct mbuf * );
    157155
    158 
    159156/* Required RTEMS network driver functions and tasks (plus reset daemon) */
    160157
     
    179176#endif
    180177
    181 
    182 
    183178/*
    184179 *  word_swap
     
    200195  return (((val >> 16)&(0x0000ffff)) | ((val << 16)&(0xffff0000)));
    201196}
    202 
    203197
    204198/*
     
    237231}
    238232
    239 
    240233/*
    241234 *  uti596_scp_alloc
     
    274267}
    275268
    276 
    277269/*
    278270 *  uti596_writePortFunction
     
    299291}
    300292
    301 
    302293/*
    303294 *  uti596_portReset
     
    315306  uti596_writePortFunction( NULL, UTI596_RESET_PORT_FUNCTION );
    316307}
    317 
    318308
    319309/* currently unused by RTEMS */
     
    371361#endif
    372362
    373 
    374363/* currently unused by RTEMS */
    375364#if 0
     
    423412}
    424413#endif
    425 
    426414
    427415/*
     
    458446    case UTI596_NO_WAIT:
    459447      return 0;
    460 
    461448
    462449    case UTI596_WAIT_FOR_CU_ACCEPT:
     
    522509}
    523510
    524 
    525511/*
    526512 *  uti596_issueCA
     
    551537}
    552538
    553 
    554539/*
    555540 *  uti596_addCmd
     
    605590}
    606591
    607 
    608592/*
    609593 *  uti596_addPolledCmd
     
    649633}
    650634
    651 
    652635/* currently unused by RTEMS */
    653636#if 0
     
    678661}
    679662#endif
    680 
    681663
    682664/*
     
    708690}
    709691
    710 
    711692/*
    712693 *  uti596_setScpAndScb
     
    740721  return ( uti596_issueCA ( sc, UTI596_WAIT_FOR_INITIALIZATION ) );
    741722}
    742 
    743723
    744724/*
     
    769749}
    770750
    771 
    772751/*
    773752 *  uti596_configure
     
    797776}
    798777
    799 
    800778/*
    801779 *  uti596_IAsetup
     
    829807  return ( uti596_wait ( sc, UTI596_WAIT_FOR_STAT_C ) );
    830808}
    831 
    832809
    833810/*
     
    877854  return 0;
    878855}
    879 
    880856
    881857/*
     
    962938}
    963939
    964 
    965940/*
    966941 *  uti596_initMem
     
    10751050  sc->scb.command = 0;
    10761051}
    1077 
    10781052
    10791053/*
     
    11261100}
    11271101
    1128 
    11291102/*
    11301103 *  uti596_reset_hardware
     
    11761149}
    11771150
    1178 
    11791151/*
    11801152 *  uti596_clearListStatus
     
    11981170  }
    11991171}
    1200 
    12011172
    12021173/*
     
    12421213  sc->pCmdHead = sc->pCmdTail = sc->scb.pCmd = I596_NULL;
    12431214
    1244 
    12451215  /* restore the RFA */
    12461216
     
    12781248        #endif
    12791249}
    1280 
    12811250
    12821251/*
     
    13191288  return pRfd;
    13201289}
    1321 
    13221290
    13231291/*
     
    13671335  }
    13681336}
    1369 
    13701337
    13711338/*
     
    15041471}
    15051472
    1506 
    15071473/*
    15081474 *  send_packet
     
    16461612}
    16471613
    1648 
    16491614/***********************************************************************
    16501615 *  Function:   uti596_attach
     
    19341899  i82596->chan_attn = 0x00000000;
    19351900}
    1936 
    1937 
    19381901
    19391902/***********************************************************************
     
    21252088}
    21262089
    2127 
    21282090/***********************************************************************
    21292091 *  Function:   void uti596_resetDaemon
     
    21582120  }
    21592121}
    2160 
    21612122
    21622123/***********************************************************************
     
    22092170    uti596_softc.nic_reset = 1;
    22102171  }
    2211 
    22122172
    22132173  if ( (scbStatus & SCB_STAT_CX) && !(scbStatus & SCB_STAT_CNA) ) {
     
    23252285    }
    23262286  } /* end if ( scbStatus & SCB_STAT_FR ) */
    2327 
    23282287
    23292288 /*
     
    24742433    }
    24752434  }  /* end if command complete */
    2476 
    24772435
    24782436 /*
     
    26082566  count_rx=0;
    26092567
    2610 
    26112568 /* Do this last, to ensure that the reset is called at the right time. */
    26122569  if ( uti596_softc.nic_reset ) {
     
    26182575  return;
    26192576}
    2620 
    26212577
    26222578/***********************************************************************
     
    26882644  return error;
    26892645}
    2690 
    26912646
    26922647/***********************************************************************
     
    27402695}
    27412696
    2742 
    2743 
    2744 
    27452697/************************ PACKET DEBUG ROUTINES ************************/
    27462698
     
    27812733  }
    27822734}
    2783 
    27842735
    27852736/*
     
    28262777}
    28272778
    2828 
    28292779/*
    28302780 *  show_queues
     
    28612811  printk(("uti596_softc.pEndRFA: %p\n",uti596_softc.pEndRFA))
    28622812}
    2863 
    28642813
    28652814/*
     
    29242873    printk (("%u\n", add[41]))
    29252874  }
    2926 
    29272875
    29282876  if ( add[12] == 0x08 && add[13] == 0x00 ) {
     
    29512899}
    29522900
    2953 
    29542901/*
    29552902 *  print_hdr
     
    29792926  printk (("print_hdr: completed"))
    29802927}
    2981 
    29822928
    29832929/*
     
    30663012}
    30673013
    3068 
    30693014/*
    30703015 *  print_echo
  • c/src/lib/libbsp/m68k/mvme167/network/uti596.h

    r6128a4a rf05b2ac  
    101101#define I596_NULL ( ( void * ) 0xffffffff)
    102102#define UTI_596_END_OF_FRAME 0x8000
    103 
    104103
    105104struct i596_tbd;  /* necessary forward declaration */
  • c/src/lib/libbsp/m68k/mvme167/startup/bspstart.c

    r6128a4a rf05b2ac  
    1818 *  $Id$
    1919 */
    20 
    2120
    2221#include <string.h>
     
    9695  m68k_set_vbr( rom_monitor_vector_table );
    9796
    98 
    9997  /*
    10098   *  Copy 167Bug Bus Error handler into our exception vector. All 167Bug
  • c/src/lib/libbsp/m68k/mvme167/startup/page_table.c

    r6128a4a rf05b2ac  
    132132}
    133133
    134 
    135134/*
    136135 *  page_table_teardown
  • c/src/lib/libbsp/m68k/mvme167/timer/timer.c

    r6128a4a rf05b2ac  
    9393#define LEAST_VALID       3UL   /* Don't trust a value lower than this */
    9494
    95 
    9695/*
    9796 *  This routine reads the Tick Timer 1 on the MVME167 board.
     
    122121}
    123122
    124 
    125123/*
    126124 *  Empty function call used in loops to measure basic cost of looping
     
    135133  return RTEMS_SUCCESSFUL;
    136134}
    137 
    138135
    139136/*
  • c/src/lib/libbsp/m68k/ods68302/console/console.c

    r6128a4a rf05b2ac  
    7777}
    7878
    79 
    8079/*  inbyte
    8180 *
     
    9796  return ch;
    9897}
    99 
    10098
    10199/*  outbyte
  • c/src/lib/libbsp/m68k/ods68302/start/reset.S

    r6128a4a rf05b2ac  
    855855        .space  4,0
    856856
    857 
    858857|
    859858| Uninitialised data
  • c/src/lib/libbsp/m68k/ods68302/startup/gdb-hooks.c

    r6128a4a rf05b2ac  
    77 */
    88/*****************************************************************************/
    9 
    109
    1110#include <bsp.h>
  • c/src/lib/libbsp/m68k/ods68302/startup/m68302scc.c

    r6128a4a rf05b2ac  
    77 */
    88/*****************************************************************************/
    9 
    109
    1110#include <bsp.h>
  • c/src/lib/libbsp/m68k/ods68302/startup/m68k-stub.c

    r6128a4a rf05b2ac  
    528528#endif
    529529
    530 
    531530/*
    532531 * remcomHandler is a front end for handle_exception.  It moves the
     
    639638/* send the packet in buffer.  The host get's one chance to read it.
    640639   This routine does not wait for a positive acknowledge.  */
    641 
    642640
    643641void
     
    10281026}
    10291027
    1030 
    10311028void initializeRemcomErrorFrame()
    10321029{
  • c/src/lib/libbsp/m68k/ods68302/timer/timer.c

    r6128a4a rf05b2ac  
    2020 */
    2121
    22 
    2322#include <rtems.h>
    2423#include <bsp.h>
    2524#include <rtems/m68k/m68302.h>
    26 
    2725
    2826#define TMR2_VAL 0x071b /* Timer mode register
     
    111109}
    112110
    113 
    114111/*
    115112 *  Empty function call used in loops to measure basic cost of looping
  • c/src/lib/libbsp/m68k/shared/gdbstub/gdb_if.h

    r6128a4a rf05b2ac  
    3232
    3333int parse_zbreak(const char *in, int *type, unsigned char **addr, int *len);
    34 
    3534
    3635char* mem2hstr(char *buf, const unsigned char *mem, int count);
     
    172171#define NUM_REGS        72
    173172
    174 
    175 
    176 
    177 
    178173void mips_gdb_stub_install(int enableThreads) ;
    179174#endif /* defined (__mips__) */
    180 
    181175
    182176#define MEMOPT_READABLE   1
     
    187181int gdbstub_add_memsegment(unsigned,unsigned,int);
    188182
    189 
    190 
    191183#endif /* _GDB_IF_H */
  • c/src/lib/libbsp/m68k/shared/gdbstub/m68k-stub.c

    r6128a4a rf05b2ac  
    130130typedef void (*Function)();           /* pointer to a function */
    131131
    132 
    133132extern void putDebugChar();     /* write a single character      */
    134133extern int getDebugChar();      /* read and return a single char */
    135 
    136134
    137135/************************/
     
    154152#define highhex(x) gdb_hexchars [(x >> 4) & 0xf]
    155153#define lowhex(x) gdb_hexchars [x & 0xf]
    156 
    157154
    158155
     
    207204 */
    208205const short exceptionSize[] = { 4,4,6,6,4,4,4,30,29,10,16,46,12,4,4,4 };
    209 
    210206
    211207/************* jump buffer used for setjmp/longjmp **************************/
     
    323319#endif
    324320asm("   rte");
    325 
    326321
    327322#if M68K_HAS_VBR
     
    495490#endif
    496491
    497 
    498492/*
    499493 * remcomHandler is a front end for handle_exception.  It moves the
     
    554548  return (-1);
    555549}
    556 
    557550
    558551/* scan for the sequence $<data>#<checksum>     */
     
    611604/* send the packet in buffer.  The host get's one chance to read it.
    612605   This routine does not wait for a positive acknowledge.  */
    613 
    614606
    615607/*
     
    666658static short error;
    667659
    668 
    669660void debug_error(
    670661  char * format,
     
    955946            mem2hex (regptr, remcomOutBuffer, sizeof registers);
    956947            break;
    957 
    958948
    959949         case 'G':       /* set the values of the CPU registers - return OK */
     
    12451235}
    12461236
    1247 
    12481237void
    12491238initializeRemcomErrorFrame()
  • c/src/lib/libbsp/m68k/shared/m68kpretaskinghook.c

    r6128a4a rf05b2ac  
    3939extern void          *_HeapSize;
    4040
    41 
    4241unsigned long  _M68k_Ramsize;
    4342
  • c/src/lib/libbsp/m68k/shared/mvme/mvme16x_hw.h

    r6128a4a rf05b2ac  
    5555 */
    5656#define GROUP_BASE_ADDRESS 0x0000CC00
    57 
    5857
    5958/*
     
    245244#endif
    246245
    247 
    248246/*
    249247 *  Flag to indicate if J1-4 is on (and parameters should be
     
    258256#endif
    259257
    260 
    261258#ifdef __cplusplus
    262259}
  • c/src/lib/libbsp/m68k/sim68000/clock/clockdrv.c

    r6128a4a rf05b2ac  
    1111#define Clock_driver_support_install_isr( _new, _old )  \
    1212  do { _old = (rtems_isr_entry) set_vector( _new, CLOCK_VECTOR, 1 ); } while(0)
    13 
    1413
    1514typedef struct {
     
    4544}
    4645
    47 
    4846void Clock_driver_support_shutdown_hardware()
    4947{
  • c/src/lib/libbsp/m68k/sim68000/console/conscfg.c

    r6128a4a rf05b2ac  
    3838#endif
    3939
    40 
    41 
    4240console_tbl     Console_Port_Tbl[] = {
    4341        {
  • c/src/lib/libbsp/m68k/sim68000/start/start.S

    r6128a4a rf05b2ac  
    392392        jmp     bsp_exitted
    393393
    394 
    395394|
    396395| Initialised data
Note: See TracChangeset for help on using the changeset viewer.