Changeset fcee56c0 in rtems


Ignore:
Timestamp:
07/01/99 23:39:13 (24 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, 5, master
Children:
258fd79
Parents:
2a6a029f
Message:

Patch from Eric Valette <valette@…> to clean up the
previous submission.

Location:
c/src/lib
Files:
77 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/powerpc/mcp750/Makefile.in

    r2a6a029f rfcee56c0  
    1818# wrapup is the one that actually builds and installs the library
    1919#  from the individual .rel files built in other directories
    20 SUB_DIRS= console include pci residual openpic irq vectors start startup bootloader wrapup
     20SUB_DIRS= console include pci residual openpic irq vectors start startup bootloader dec21140 wrapup
  • c/src/lib/libbsp/powerpc/mcp750/bootloader/Makefile.in

    r2a6a029f rfcee56c0  
    11#
    2 #  $Id:
     2#  $Id$
    33#
    44
  • c/src/lib/libbsp/powerpc/mcp750/bootloader/bootldr.h

    r2a6a029f rfcee56c0  
    11/*
    2  *  include/asm-ppc/bloader.h -- Include file for bootloader.
    3  *
    4  *  Copyright (C) 1998 Gabriel Paubert, paubert@iram.es
    5  *
    6  *  This file is subject to the terms and conditions of the GNU General Public
    7  *  License.  See the file COPYING in the main directory of this archive
    8  *  for more details.
     2 *  bootldr.h -- Include file for bootloader.
     3 *
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
     5 *
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
     8 *
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
    916 */
    1017
  • c/src/lib/libbsp/powerpc/mcp750/bootloader/em86.c

    r2a6a029f rfcee56c0  
     1/*
     2 *  em86.c -- Include file for bootloader.
     3 *
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
     5 *
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
     8 *
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
     16 */
     17
    118/*****************************************************************************
    219*
  • c/src/lib/libbsp/powerpc/mcp750/bootloader/em86real.S

    r2a6a029f rfcee56c0  
    11/*
    2  *  arch/ppc/boot/em86real.S -- Small x86 emulator for video board setup
     2 *  em86real.S
    33 *
    4  *  Copyright (C) 1998 Gabriel Paubert, paubert@iram.es
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
    55 *
    6  *  This file is subject to the terms and conditions of the GNU General Public
    7  *  License.  See the file COPYING in the main directory of this archive
    8  *  for more details.
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
     8 *
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
    916 */
    1017
  • c/src/lib/libbsp/powerpc/mcp750/bootloader/exception.S

    r2a6a029f rfcee56c0  
    11/*
    2  *  arch/ppc/loader/exceotion.S -- Exception handlers for early boot.
    3  *
    4  *  Copyright (C) 1998 Gabriel Paubert, paubert@iram.es
    5  *
    6  *  This file is subject to the terms and conditions of the GNU General Public
    7  *  License.  See the file COPYING in the main directory of this archive
    8  *  for more details.
     2 *  exception.S -- Exception handlers for early boot.
     3 *
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
     5 *
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
     8 *
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
    916 */
    1017
  • c/src/lib/libbsp/powerpc/mcp750/bootloader/head.S

    r2a6a029f rfcee56c0  
    11/*
     2 *  head.S -- Bootloader Entry point
     3 *
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
     5 *
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
     8 *
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
    215 * $Id$
    3  *     
    4  * This code is loaded by the ROM loader at some arbitrary location.
    5  * Move it to high memory so that it can load the kernel at 0x0000.
    6  *
    716 */
    817
  • c/src/lib/libbsp/powerpc/mcp750/bootloader/misc.c

    r2a6a029f rfcee56c0  
    11/*
    2  * arch/ppc/prepboot/misc.c
     2 *  head.S -- Bootloader Entry point
    33 *
    4  *  Copyright (C) 1998 Gabriel Paubert, paubert@iram.es
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
    55 *
    6  *  This file is based on arch/ppc/boot misc.c in previous versions of
    7  * Linux/PPC but has been so extensively changed that only a few lines
    8  * remain from the original.
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
    98 *
    10  *  This file is subject to the terms and conditions of the GNU General Public
    11  *  License.  See the file COPYING in the main directory of this archive
    12  *  for more details.
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
    1316 */
    1417
  • c/src/lib/libbsp/powerpc/mcp750/bootloader/mm.c

    r2a6a029f rfcee56c0  
    11/*
    2  *  arch/ppc/prepboot/mm.c -- Crude memory management for early boot.
     2 *  mm.c -- Crude memory management for early boot.
    33 *
    4  *  Copyright (C) 1998 Gabriel Paubert, paubert@iram.es
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
    55 *
    6  *  This file is subject to the terms and conditions of the GNU General Public
    7  *  License.  See the file COPYING in the main directory of this archive
    8  *  for more details.
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
     8 *
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
    916 */
    1017
  • c/src/lib/libbsp/powerpc/mcp750/bootloader/pci.c

    r2a6a029f rfcee56c0  
    11/*
    2  *  arch/ppc/prepboot/pci.c -- Crude pci handling for early boot.
     2 *  pci.c -- Crude pci handling for early boot.
    33 *
    4  *  Copyright (C) 1998 Gabriel Paubert, paubert@iram.es
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
    55 *
    6  *  The pci_scan_bus and pci_read_bases functions are slightly modified
    7  * versions of functions with the same name in linux/drivers/pci.c by
    8  * Martin Mares (mj@ucw.cz) and others (taken around linux-2.1.120).
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
    98 *
    10  *  This file is subject to the terms and conditions of the GNU General Public
    11  *  License.  See the file COPYING in the main directory of this archive
    12  *  for more details.
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
    1316 */
    1417
  • c/src/lib/libbsp/powerpc/mcp750/console/console.c

    r2a6a029f rfcee56c0  
    1 /*-------------------------------------------------------------------------+
    2 | console.c v1.1 - PC386 BSP - 1997/08/07
    3 +--------------------------------------------------------------------------+
    4 | This file contains the PC386 console I/O package.
    5 +--------------------------------------------------------------------------+
    6 | (C) Copyright 1997 -
    7 | - NavIST Group - Real-Time Distributed Systems and Industrial Automation
    8 |
    9 | http://pandora.ist.utl.pt
    10 |
    11 | Instituto Superior Tecnico * Lisboa * PORTUGAL
    12 +--------------------------------------------------------------------------+
    13 | Disclaimer:
    14 |
    15 | This file is provided "AS IS" without warranty of any kind, either
    16 | expressed or implied.
    17 +--------------------------------------------------------------------------+
    18 | This code is based on:
    19 |   console.c,v 1.4 1995/12/19 20:07:23 joel Exp - go32 BSP
    20 | With the following copyright notice:
    21 | **************************************************************************
    22 | *  COPYRIGHT (c) 1989-1998.
    23 | *  On-Line Applications Research Corporation (OAR).
    24 | *  Copyright assigned to U.S. Government, 1994.
    25 | *
    26 | *  The license and distribution terms for this file may be
    27 | *  found in found in the file LICENSE in this distribution or at
    28 | *  http://www.OARcorp.com/rtems/license.html.
    29 | **************************************************************************
    30 |
    31 |  $Id$
    32 +--------------------------------------------------------------------------*/
    33 
    34 #include <stdio.h>
     1/*
     2 *  console.c  -- console I/O package
     3 *
     4 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     5 *
     6 * This code is based on the pc386 BSP console.c so the following
     7 * copyright also applies :
     8 *
     9 * (C) Copyright 1997 -
     10 * - NavIST Group - Real-Time Distributed Systems and Industrial Automation
     11 *
     12 * http://pandora.ist.utl.pt
     13 *
     14 * Instituto Superior Tecnico * Lisboa * PORTUGAL
     15 *  The license and distribution terms for this file may be
     16 *  found in found in the file LICENSE in this distribution or at
     17 *  http://www.OARcorp.com/rtems/license.html.
     18 *
     19 * $Id$
     20 */
     21 
    3522#include <stdlib.h>
    3623#include <assert.h>
  • c/src/lib/libbsp/powerpc/mcp750/console/consoleIo.h

    r2a6a029f rfcee56c0  
     1/*
     2 *  consoleIo.h  -- console I/O package interface
     3 *
     4 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     5 *
     6 *  The license and distribution terms for this file may be
     7 *  found in found in the file LICENSE in this distribution or at
     8 *  http://www.OARcorp.com/rtems/license.html.
     9 *
     10 * $Id$
     11 */
     12
    113#ifndef __CONSOLE_IO_H
    214#define __CONSOLE_IO_H
  • c/src/lib/libbsp/powerpc/mcp750/console/consoleLib.S

    r2a6a029f rfcee56c0  
    11/*
     2 *  consoleLib.S  -- console I/O package utility functions.
     3 *
     4 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     5 *
     6 *  The license and distribution terms for this file may be
     7 *  found in found in the file LICENSE in this distribution or at
     8 *  http://www.OARcorp.com/rtems/license.html.
     9 *
    210 * $Id$
    3  *     
    4  * This code is loaded by the ROM loader at some arbitrary location.
    5  * Move it to high memory so that it can load the kernel at 0x0000.
    6  *
    711 */
     12
    813/* A few utility functions, some copied from arch/ppc/lib/string.S */
     14
    915#include <libcpu/cpu.h>
    1016#include <rtems/score/targopts.h>
  • c/src/lib/libbsp/powerpc/mcp750/console/inch.c

    r2a6a029f rfcee56c0  
    1 /*-------------------------------------------------------------------------+
    2 | inch.c v1.1 - PC386 BSP - 1997/08/07
    3 +--------------------------------------------------------------------------+
    4 | (C) Copyright 1997 -
    5 | - NavIST Group - Real-Time Distributed Systems and Industrial Automation
    6 |
    7 | http://pandora.ist.utl.pt
    8 |
    9 | Instituto Superior Tecnico * Lisboa * PORTUGAL
    10 +--------------------------------------------------------------------------+
    11 | Disclaimer:
    12 |
    13 | This file is provided "AS IS" without warranty of any kind, either
    14 | expressed or implied.
    15 +--------------------------------------------------------------------------+
    16 | This code is based on:
    17 |   inch.c,v 1.3 1995/12/19 20:07:25 joel Exp - go32 BSP
    18 | With the following copyright notice:
    19 | With the following copyright notice:
    20 | **************************************************************************
    21 | *  COPYRIGHT (c) 1989-1998.
    22 | *  On-Line Applications Research Corporation (OAR).
    23 | *  Copyright assigned to U.S. Government, 1994.
    24 | *
    25 | *  The license and distribution terms for this file may be
    26 | *  found in found in the file LICENSE in this distribution or at
    27 | *  http://www.OARcorp.com/rtems/license.html.
    28 | **************************************************************************
    29 |
    30 |  $Id$
    31 +--------------------------------------------------------------------------*/
     1/*
     2 *  inch.c  -- keyboard minimal driver
     3 *
     4 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     5 *
     6 * This code is based on the pc386 BSP inch.c so the following
     7 * copyright also applies :
     8 *
     9 * (C) Copyright 1997 -
     10 * - NavIST Group - Real-Time Distributed Systems and Industrial Automation
     11 *
     12 * http://pandora.ist.utl.pt
     13 *
     14 * Instituto Superior Tecnico * Lisboa * PORTUGAL
     15 *  The license and distribution terms for this file may be
     16 *  found in found in the file LICENSE in this distribution or at
     17 *  http://www.OARcorp.com/rtems/license.html.
     18 *
     19 * $Id$
     20 */
    3221
    3322#include <bsp.h>
  • c/src/lib/libbsp/powerpc/mcp750/console/keyboard.h

    r2a6a029f rfcee56c0  
     1/*
     2 *  keyboard.h  -- keyboard definitions.
     3 *
     4 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     5 *
     6 *  The license and distribution terms for this file may be
     7 *  found in found in the file LICENSE in this distribution or at
     8 *  http://www.OARcorp.com/rtems/license.html.
     9 *
     10 * $Id$
     11 */
     12
    113#ifndef __LINUX_KEYBOARD_H
    214#define __LINUX_KEYBOARD_H
  • c/src/lib/libbsp/powerpc/mcp750/console/polled_io.c

    r2a6a029f rfcee56c0  
    11/*
    2  * arch/ppc/prepboot/console.c
     2 *  polled_io.c -- Basic input/output for early boot
    33 *
    4  *  Copyright (C) 1998 Gabriel Paubert, paubert@iram.es
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
    55 *
    6  *  This file is based on arch/ppc/boot/{kbd,vreset}.c in previous versions
    7  * of Linux/PPC, mostly contributed by Gary Thomas and Cort Dougan.
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
    88 *
    9  *  This file is subject to the terms and conditions of the GNU General Public
    10  *  License.  See the file COPYING in the main directory of this archive
    11  *  for more details.
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
    1216 */
    1317
  • c/src/lib/libbsp/powerpc/mcp750/include/bsp.h

    r2a6a029f rfcee56c0  
    11/*
    2  * empty file. Just because referenced by portable application layer.
     2 *  bsp.h  -- contain BSP API definition.
     3 *
     4 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     5 *
     6 *  The license and distribution terms for this file may be
     7 *  found in found in the file LICENSE in this distribution or at
     8 *  http://www.OARcorp.com/rtems/license.html.
     9 *
     10 * $Id$
    311 */
    412#ifndef LIBBSP_POWERPC_MCP750_BSP_H
  • c/src/lib/libbsp/powerpc/mcp750/include/nvram.h

    r2a6a029f rfcee56c0  
    11/*
    22 * PreP compliant NVRAM access
     3 *
     4 * This file can be found in motorla or IBP PPC site.
     5 *
     6 * $Id$
    37 */
    48
  • c/src/lib/libbsp/powerpc/mcp750/irq/i8259.c

    r2a6a029f rfcee56c0  
    1 /* i8259.c
    2  *
     1
     2/*
    33 *  This file contains the implementation of the function described in irq.h
    44 *  related to Intel 8259 Programmable Interrupt controller.
    55 *
    6  *  CopyRight (C) 1998 valette@crf.canon.fr
     6 *  Copyright (C) 1998, 1999 valette@crf.canon.fr
    77 *
    88 *  The license and distribution terms for this file may be
     
    1212 *  $Id$
    1313 */
    14 
    15 
     14 
    1615#include <bsp.h>
    1716#include <bsp/irq.h>
  • c/src/lib/libbsp/powerpc/mcp750/irq/irq.c

    r2a6a029f rfcee56c0  
    1 /* irq.c
     1/*
    22 *
    33 *  This file contains the implementation of the function described in irq.h
    44 *
    5  *  CopyRight (C) 1998 valette@crf.canon.fr
     5 *  Copyright (C) 1998, 1999 valette@crf.canon.fr
    66 *
    77 *  The license and distribution terms for this file may be
     
    1111 *  $Id$
    1212 */
    13 
    14 
     13 
    1514#include <bsp.h>
    1615#include <bsp/irq.h>
     
    2019#include <libcpu/raw_exception.h>
    2120#include <bsp/vectors.h>
    22 #include <libcpu/processor.h>
     21#include <libcpu/cpu.h>
    2322
    2423#define RAVEN_INTR_ACK_REG 0xfeff0030
  • c/src/lib/libbsp/powerpc/mcp750/irq/irq_asm.S

    r2a6a029f rfcee56c0  
    11/*
    2  * (c) 1999, Eric Valette valette@crf.canon.fr
    3  *
    4  *
    52 *  This file contains the assembly code for the PowerPC
    63 *  IRQ veneers for RTEMS.
    74 *
     5 *  The license and distribution terms for this file may be
     6 *  found in found in the file LICENSE in this distribution or at
     7 *  http://www.OARcorp.com/rtems/license.html.
     8 *
    89 * $Id$
    910 */
    10        
    11 
    12 
     11       
    1312#include <bsp/vectors.h>
    1413#include <libcpu/cpu.h>
  • c/src/lib/libbsp/powerpc/mcp750/openpic/openpic.c

    r2a6a029f rfcee56c0  
    11/*
    2  *  arch/ppc/kernel/openpic.c -- OpenPIC Interrupt Handling
     2 *  openpic.c -- OpenPIC Interrupt Handling
    33 *
    44 *  Copyright (C) 1997 Geert Uytterhoeven
    55 *
    6  *  This file is subject to the terms and conditions of the GNU General Public
    7  *  License.  See the file COPYING in the main directory of this archive
    8  *  for more details.
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
     8 *
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
    916 */
    10 
    1117
    1218/*
     
    2026#include <libcpu/io.h>
    2127#include <libcpu/byteorder.h>
    22 
    23 /* #include <asm/irq.h> */
    2428
    2529#define NULL 0
  • c/src/lib/libbsp/powerpc/mcp750/openpic/openpic.h

    r2a6a029f rfcee56c0  
    11/*
    2  *  linux/openpic.h -- OpenPIC definitions
     2 *  openpic.h -- OpenPIC definitions
    33 *
    44 *  Copyright (C) 1997 Geert Uytterhoeven
     
    2222 *  License.  See the file COPYING in the main directory of this archive
    2323 *  for more details.
     24 *
     25 *  Modified to compile in RTEMS development environment
     26 *  by Eric Valette
     27 *
     28 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     29 *
     30 *  The license and distribution terms for this file may be
     31 *  found in found in the file LICENSE in this distribution or at
     32 *  http://www.OARcorp.com/rtems/license.html.
     33 *
     34 * $Id$
    2435 */
    2536
  • c/src/lib/libbsp/powerpc/mcp750/pci/pci.c

    r2a6a029f rfcee56c0  
     1/*
     2 * pci.c :  this file contains basic PCI Io functions.
     3 *
     4 *  CopyRight (C) 1999 valette@crf.canon.fr
     5 *
     6 *  This code is heavilly inspired by the public specification of STREAM V2
     7 *  that can be found at :
     8 *
     9 *      <http://www.chorus.com/Documentation/index.html> by following
     10 *  the STREAM API Specification Document link.
     11 *
     12 *  The license and distribution terms for this file may be
     13 *  found in found in the file LICENSE in this distribution or at
     14 *  http://www.OARcorp.com/rtems/license.html.
     15 *
     16 *  $Id$
     17 */
     18
    119#include <bsp/consoleIo.h>
    220#include <libcpu/io.h>
  • c/src/lib/libbsp/powerpc/mcp750/pci/pci.h

    r2a6a029f rfcee56c0  
    1212 *      PCI to PCI Bridge Specification
    1313 *      PCI System Design Guide
     14 *
     15 * $Id$
    1416 */
    1517
  • c/src/lib/libbsp/powerpc/mcp750/residual/pnp.h

    r2a6a029f rfcee56c0  
    1414/* For enum's: if given in hex then they are bit significant, i.e.            */
    1515/* only one bit is on for each enum                                           */
     16
     17/*
     18 * $Id$
     19 */
    1620
    1721#ifndef _PNP_
  • c/src/lib/libbsp/powerpc/mcp750/residual/residual.c

    r2a6a029f rfcee56c0  
     1/*
     2 * residual.c : function used to parse residual data.
     3 *
     4 *  CopyRight (C) 1999 valette@crf.canon.fr
     5 *
     6 *  This code is heavilly inspired by the public specification of STREAM V2
     7 *  that can be found at :
     8 *
     9 *  The license and distribution terms for this file may be
     10 *  found in found in the file LICENSE in this distribution or at
     11 *  http://www.OARcorp.com/rtems/license.html.
     12 *
     13 *  $Id$
     14 */
     15
    116#include <bsp/residual.h>
    217#include <libcpu/io.h>
  • c/src/lib/libbsp/powerpc/mcp750/residual/residual.h

    r2a6a029f rfcee56c0  
    1010/*             i.e. only one bit is on for each enum                          */
    1111/* Reserved fields must be filled with zeros.                                */
     12
     13/*
     14 * $Id$
     15 */
    1216
    1317#ifndef _RESIDUAL_
  • c/src/lib/libbsp/powerpc/mcp750/startup/bspstart.c

    r2a6a029f rfcee56c0  
    1212 *  found in the file LICENSE in this distribution or at
    1313 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 *  Modified to support the MCP750.
     16 *  Modifications Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
    1417 *
    1518 *  $Id$
     
    120123{
    121124    extern int end;
    122     rtems_unsigned32        heap_start;
     125    rtems_unsigned32        heap_start;   
     126    rtems_unsigned32        heap_size;
    123127
    124128    heap_start = ((rtems_unsigned32) &__rtems_end) +INIT_STACK_SIZE + INTR_STACK_SIZE;
     
    126130        heap_start = (heap_start + CPU_ALIGNMENT) & ~(CPU_ALIGNMENT-1);
    127131
    128     bsp_libc_init((void *) heap_start, 64 * 1024, 0);
     132    heap_size = (BSP_mem_size - heap_start) - BSP_Configuration.work_space_size;
     133
     134    printk(" HEAP start %x  size %x\n", heap_start, heap_size);
     135    bsp_libc_init((void *) heap_start, heap_size, 0);
    129136
    130137#ifdef RTEMS_DEBUG
  • c/src/lib/libbsp/powerpc/mcp750/startup/cEntry.c

    r2a6a029f rfcee56c0  
    1 /*
    2  *
    3  */
    4 #include <bsp/consoleIo.h>
    5 #include <libcpu/spr.h>
    6 #include <bsp/residual.h>
    7 #include <bsp/pci.h>
    8 #include <bsp/openpic.h>
    9 #include <bsp/irq.h>
    10 #include <bsp.h>
    11 #include <libcpu/bat.h>
    12 
    13 extern void _return_to_ppcbug();
    14 extern unsigned long __rtems_end;
    15 
    16 RESIDUAL residualCopy;
    17 #define INIT_STACK_SIZE 0x1000
    18 #define INTR_STACK_SIZE 0x4000
    19 
    20 void BSP_panic(char *s)
    21 {
    22   printk("RTEMS 4.x PANIC %s\n", s);
    23   _return_to_ppcbug();
    24 }
    25 
    26 void _BSP_Fatal_error(unsigned int v)
    27 {
    28   printk("RTEMS 4.x PANIC ERROR %x\n", v);
    29   _return_to_ppcbug();
    30 }
    31 
    32 void
    33 boot_card(RESIDUAL* r3, void *r4, void* r5, char *additional_boot_options)
    34 {
    35   int err;
    36   unsigned char *stack;
    37   unsigned l2cr;
    38   register unsigned char* intrStack;
    39   register unsigned int intrNestingLevel = 0;
    40  
    41   L1_caches_enables();
    42   stack = ((unsigned char*) &__rtems_end) + INIT_STACK_SIZE;
    43   intrStack = ((unsigned char*) &__rtems_end) + INIT_STACK_SIZE + INTR_STACK_SIZE;
    44   asm volatile ("mtspr  273, %0" : "=r" (intrStack) : "0" (intrStack));
    45   asm volatile ("mtspr  272, %0" : "=r" (intrNestingLevel) : "0" (intrNestingLevel));
    46   residualCopy = *r3;
    47 #define NO_DYNAMIC_EXCEPTION_VECTOR_INSTALL
    48 #undef  NO_DYNAMIC_EXCEPTION_VECTOR_INSTALL
    49 #ifndef NO_DYNAMIC_EXCEPTION_VECTOR_INSTALL 
    50   initialize_exceptions();
    51 #endif
    52   select_console(CONSOLE_LOG);
    53 
    54   /* We check that the keyboard is present and immediately
    55    * select the serial console if not.
    56    */
    57   err = kbdreset();
    58   if (err) select_console(CONSOLE_SERIAL);
    59 
    60  
    61   printk("Welcome to RTEMS 4.0.2 on Motorola MCP750\n\n\n");
    62   printk("-----------------------------------------\n");
    63   printk("Residuals are located at %x\n", (unsigned) r3);
    64   printk("Additionnal boot options are %s\n", additional_boot_options);
    65   printk("-----------------------------------------\n");
    66 
    67   printk("Initial system stack at %x\n",stack);
    68   l2cr = get_L2CR();
    69   printk("Initial L2CR value = %x\n", l2cr);
    70   if (! (l2cr & 0x80000000))
    71     set_L2CR(0xb9A14000);
    72 #ifdef TEST_RETURN_TO_PPCBUG 
    73   printk("Hit <Enter> to return to PPCBUG monitor\n");
    74   printk("When Finished hit GO. It should print <Back from monitor>\n");
    75   debug_getc();
    76   _return_to_ppcbug();
    77   printk("Back from monitor\n");
    78   _return_to_ppcbug();
    79 #endif /* TEST_RETURN_TO_PPCBUG  */
    80 
    81   /*
    82    * Init MMU block address translation to enable hardware
    83    * access
    84    */
    85   /*
    86    * PC legacy IO space used for inb/outb and all PC
    87    * compatible hardware
    88    */
    89   setdbat(1, 0x80000000, 0x80000000, 0x10000000, IO_PAGE);
    90   /*
    91    * PCI devices memory area. Needed to access OPENPIC features
    92    * provided by the RAVEN
    93    */
    94   setdbat(2, 0xc0000000, 0xc0000000, 0x08000000, IO_PAGE);
    95   /*
    96    * Must have acces to open pic PCI ACK registers
    97    * provided by the RAVEN
    98    */
    99   setdbat(3, 0xfeff0000, 0xfeff0000, 0x10000, IO_PAGE);
    100 
    101   printk("Going to start PCI buses scanning and initialization\n");
    102   InitializePCI();
    103   printk("Number of PCI buses is found : %d\n", BusCountPCI());
    104 #ifdef TEST_RAW_EXCEPTION_CODE 
    105   printk("Testing exception handling Part 1\n");
    106   /*
    107    * Cause a software exception
    108    */
    109   __asm__ __volatile ("sc");
    110   /*
    111    * Check we can still catch exceptions
    112    */
    113   printk("Testing exception handling Part 2\n");
    114   __asm__ __volatile ("sc");
    115 #endif 
    116   BSP_rtems_irq_mng_init(0);
    117   printk("Init done\n");
    118   debug_getc();
    119   while(1);
    120 }
    121 
  • c/src/lib/libbsp/powerpc/mcp750/vectors/vectors.h

    r2a6a029f rfcee56c0  
     1/*
     2 * vectors.h Exception frame related contant and API.
     3 *
     4 *  This include file describe the data structure and the functions implemented
     5 *  by rtems to handle exceptions.
     6 *
     7 *  CopyRight (C) 1999 valette@crf.canon.fr
     8 *
     9 *  The license and distribution terms for this file may be
     10 *  found in found in the file LICENSE in this distribution or at
     11 *  http://www.OARcorp.com/rtems/license.html.
     12 *
     13 *  $Id$
     14 */
    115#ifndef LIBBSP_POWERPC_MCP750_VECTORS_H
    216#define LIBBSP_POWERPC_MCP750_VECTORS_H
  • c/src/lib/libbsp/powerpc/mcp750/vectors/vectors_init.c

    r2a6a029f rfcee56c0  
    1 /*
     1/*
     2 * vectors_init.c Exception hanlding initialisation (and generic handler).
    23 *
     4 *  This include file describe the data structure and the functions implemented
     5 *  by rtems to handle exceptions.
     6 *
     7 *  CopyRight (C) 1999 valette@crf.canon.fr
     8 *
     9 *  The license and distribution terms for this file may be
     10 *  found in found in the file LICENSE in this distribution or at
     11 *  http://www.OARcorp.com/rtems/license.html.
     12 *
     13 *  $Id$
    314 */
    415#include <bsp/vectors.h>
  • c/src/lib/libbsp/powerpc/mcp750/wrapup/Makefile.in

    r2a6a029f rfcee56c0  
    1616VPATH = @srcdir@
    1717
    18 BSP_PIECES=console irq openpic pci residual startup vectors
     18BSP_PIECES=console irq openpic pci residual startup dec21140 vectors
    1919GENERIC_PIECES=
    2020
  • c/src/lib/libbsp/powerpc/motorola_powerpc/Makefile.in

    r2a6a029f rfcee56c0  
    1818# wrapup is the one that actually builds and installs the library
    1919#  from the individual .rel files built in other directories
    20 SUB_DIRS= console include pci residual openpic irq vectors start startup bootloader wrapup
     20SUB_DIRS= console include pci residual openpic irq vectors start startup bootloader dec21140 wrapup
  • c/src/lib/libbsp/powerpc/motorola_powerpc/bootloader/Makefile.in

    r2a6a029f rfcee56c0  
    11#
    2 #  $Id:
     2#  $Id$
    33#
    44
  • c/src/lib/libbsp/powerpc/motorola_powerpc/bootloader/bootldr.h

    r2a6a029f rfcee56c0  
    11/*
    2  *  include/asm-ppc/bloader.h -- Include file for bootloader.
    3  *
    4  *  Copyright (C) 1998 Gabriel Paubert, paubert@iram.es
    5  *
    6  *  This file is subject to the terms and conditions of the GNU General Public
    7  *  License.  See the file COPYING in the main directory of this archive
    8  *  for more details.
     2 *  bootldr.h -- Include file for bootloader.
     3 *
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
     5 *
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
     8 *
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
    916 */
    1017
  • c/src/lib/libbsp/powerpc/motorola_powerpc/bootloader/em86.c

    r2a6a029f rfcee56c0  
     1/*
     2 *  em86.c -- Include file for bootloader.
     3 *
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
     5 *
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
     8 *
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
     16 */
     17
    118/*****************************************************************************
    219*
  • c/src/lib/libbsp/powerpc/motorola_powerpc/bootloader/em86real.S

    r2a6a029f rfcee56c0  
    11/*
    2  *  arch/ppc/boot/em86real.S -- Small x86 emulator for video board setup
     2 *  em86real.S
    33 *
    4  *  Copyright (C) 1998 Gabriel Paubert, paubert@iram.es
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
    55 *
    6  *  This file is subject to the terms and conditions of the GNU General Public
    7  *  License.  See the file COPYING in the main directory of this archive
    8  *  for more details.
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
     8 *
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
    916 */
    1017
  • c/src/lib/libbsp/powerpc/motorola_powerpc/bootloader/exception.S

    r2a6a029f rfcee56c0  
    11/*
    2  *  arch/ppc/loader/exceotion.S -- Exception handlers for early boot.
    3  *
    4  *  Copyright (C) 1998 Gabriel Paubert, paubert@iram.es
    5  *
    6  *  This file is subject to the terms and conditions of the GNU General Public
    7  *  License.  See the file COPYING in the main directory of this archive
    8  *  for more details.
     2 *  exception.S -- Exception handlers for early boot.
     3 *
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
     5 *
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
     8 *
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
    916 */
    1017
  • c/src/lib/libbsp/powerpc/motorola_powerpc/bootloader/head.S

    r2a6a029f rfcee56c0  
    11/*
     2 *  head.S -- Bootloader Entry point
     3 *
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
     5 *
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
     8 *
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
    215 * $Id$
    3  *     
    4  * This code is loaded by the ROM loader at some arbitrary location.
    5  * Move it to high memory so that it can load the kernel at 0x0000.
    6  *
    716 */
    817
  • c/src/lib/libbsp/powerpc/motorola_powerpc/bootloader/misc.c

    r2a6a029f rfcee56c0  
    11/*
    2  * arch/ppc/prepboot/misc.c
     2 *  head.S -- Bootloader Entry point
    33 *
    4  *  Copyright (C) 1998 Gabriel Paubert, paubert@iram.es
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
    55 *
    6  *  This file is based on arch/ppc/boot misc.c in previous versions of
    7  * Linux/PPC but has been so extensively changed that only a few lines
    8  * remain from the original.
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
    98 *
    10  *  This file is subject to the terms and conditions of the GNU General Public
    11  *  License.  See the file COPYING in the main directory of this archive
    12  *  for more details.
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
    1316 */
    1417
  • c/src/lib/libbsp/powerpc/motorola_powerpc/bootloader/mm.c

    r2a6a029f rfcee56c0  
    11/*
    2  *  arch/ppc/prepboot/mm.c -- Crude memory management for early boot.
     2 *  mm.c -- Crude memory management for early boot.
    33 *
    4  *  Copyright (C) 1998 Gabriel Paubert, paubert@iram.es
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
    55 *
    6  *  This file is subject to the terms and conditions of the GNU General Public
    7  *  License.  See the file COPYING in the main directory of this archive
    8  *  for more details.
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
     8 *
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
    916 */
    1017
  • c/src/lib/libbsp/powerpc/motorola_powerpc/bootloader/pci.c

    r2a6a029f rfcee56c0  
    11/*
    2  *  arch/ppc/prepboot/pci.c -- Crude pci handling for early boot.
     2 *  pci.c -- Crude pci handling for early boot.
    33 *
    4  *  Copyright (C) 1998 Gabriel Paubert, paubert@iram.es
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
    55 *
    6  *  The pci_scan_bus and pci_read_bases functions are slightly modified
    7  * versions of functions with the same name in linux/drivers/pci.c by
    8  * Martin Mares (mj@ucw.cz) and others (taken around linux-2.1.120).
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
    98 *
    10  *  This file is subject to the terms and conditions of the GNU General Public
    11  *  License.  See the file COPYING in the main directory of this archive
    12  *  for more details.
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
    1316 */
    1417
  • c/src/lib/libbsp/powerpc/motorola_powerpc/console/console.c

    r2a6a029f rfcee56c0  
    1 /*-------------------------------------------------------------------------+
    2 | console.c v1.1 - PC386 BSP - 1997/08/07
    3 +--------------------------------------------------------------------------+
    4 | This file contains the PC386 console I/O package.
    5 +--------------------------------------------------------------------------+
    6 | (C) Copyright 1997 -
    7 | - NavIST Group - Real-Time Distributed Systems and Industrial Automation
    8 |
    9 | http://pandora.ist.utl.pt
    10 |
    11 | Instituto Superior Tecnico * Lisboa * PORTUGAL
    12 +--------------------------------------------------------------------------+
    13 | Disclaimer:
    14 |
    15 | This file is provided "AS IS" without warranty of any kind, either
    16 | expressed or implied.
    17 +--------------------------------------------------------------------------+
    18 | This code is based on:
    19 |   console.c,v 1.4 1995/12/19 20:07:23 joel Exp - go32 BSP
    20 | With the following copyright notice:
    21 | **************************************************************************
    22 | *  COPYRIGHT (c) 1989-1998.
    23 | *  On-Line Applications Research Corporation (OAR).
    24 | *  Copyright assigned to U.S. Government, 1994.
    25 | *
    26 | *  The license and distribution terms for this file may be
    27 | *  found in found in the file LICENSE in this distribution or at
    28 | *  http://www.OARcorp.com/rtems/license.html.
    29 | **************************************************************************
    30 |
    31 |  $Id$
    32 +--------------------------------------------------------------------------*/
    33 
    34 #include <stdio.h>
     1/*
     2 *  console.c  -- console I/O package
     3 *
     4 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     5 *
     6 * This code is based on the pc386 BSP console.c so the following
     7 * copyright also applies :
     8 *
     9 * (C) Copyright 1997 -
     10 * - NavIST Group - Real-Time Distributed Systems and Industrial Automation
     11 *
     12 * http://pandora.ist.utl.pt
     13 *
     14 * Instituto Superior Tecnico * Lisboa * PORTUGAL
     15 *  The license and distribution terms for this file may be
     16 *  found in found in the file LICENSE in this distribution or at
     17 *  http://www.OARcorp.com/rtems/license.html.
     18 *
     19 * $Id$
     20 */
     21 
    3522#include <stdlib.h>
    3623#include <assert.h>
  • c/src/lib/libbsp/powerpc/motorola_powerpc/console/consoleIo.h

    r2a6a029f rfcee56c0  
     1/*
     2 *  consoleIo.h  -- console I/O package interface
     3 *
     4 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     5 *
     6 *  The license and distribution terms for this file may be
     7 *  found in found in the file LICENSE in this distribution or at
     8 *  http://www.OARcorp.com/rtems/license.html.
     9 *
     10 * $Id$
     11 */
     12
    113#ifndef __CONSOLE_IO_H
    214#define __CONSOLE_IO_H
  • c/src/lib/libbsp/powerpc/motorola_powerpc/console/consoleLib.S

    r2a6a029f rfcee56c0  
    11/*
     2 *  consoleLib.S  -- console I/O package utility functions.
     3 *
     4 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     5 *
     6 *  The license and distribution terms for this file may be
     7 *  found in found in the file LICENSE in this distribution or at
     8 *  http://www.OARcorp.com/rtems/license.html.
     9 *
    210 * $Id$
    3  *     
    4  * This code is loaded by the ROM loader at some arbitrary location.
    5  * Move it to high memory so that it can load the kernel at 0x0000.
    6  *
    711 */
     12
    813/* A few utility functions, some copied from arch/ppc/lib/string.S */
     14
    915#include <libcpu/cpu.h>
    1016#include <rtems/score/targopts.h>
  • c/src/lib/libbsp/powerpc/motorola_powerpc/console/inch.c

    r2a6a029f rfcee56c0  
    1 /*-------------------------------------------------------------------------+
    2 | inch.c v1.1 - PC386 BSP - 1997/08/07
    3 +--------------------------------------------------------------------------+
    4 | (C) Copyright 1997 -
    5 | - NavIST Group - Real-Time Distributed Systems and Industrial Automation
    6 |
    7 | http://pandora.ist.utl.pt
    8 |
    9 | Instituto Superior Tecnico * Lisboa * PORTUGAL
    10 +--------------------------------------------------------------------------+
    11 | Disclaimer:
    12 |
    13 | This file is provided "AS IS" without warranty of any kind, either
    14 | expressed or implied.
    15 +--------------------------------------------------------------------------+
    16 | This code is based on:
    17 |   inch.c,v 1.3 1995/12/19 20:07:25 joel Exp - go32 BSP
    18 | With the following copyright notice:
    19 | With the following copyright notice:
    20 | **************************************************************************
    21 | *  COPYRIGHT (c) 1989-1998.
    22 | *  On-Line Applications Research Corporation (OAR).
    23 | *  Copyright assigned to U.S. Government, 1994.
    24 | *
    25 | *  The license and distribution terms for this file may be
    26 | *  found in found in the file LICENSE in this distribution or at
    27 | *  http://www.OARcorp.com/rtems/license.html.
    28 | **************************************************************************
    29 |
    30 |  $Id$
    31 +--------------------------------------------------------------------------*/
     1/*
     2 *  inch.c  -- keyboard minimal driver
     3 *
     4 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     5 *
     6 * This code is based on the pc386 BSP inch.c so the following
     7 * copyright also applies :
     8 *
     9 * (C) Copyright 1997 -
     10 * - NavIST Group - Real-Time Distributed Systems and Industrial Automation
     11 *
     12 * http://pandora.ist.utl.pt
     13 *
     14 * Instituto Superior Tecnico * Lisboa * PORTUGAL
     15 *  The license and distribution terms for this file may be
     16 *  found in found in the file LICENSE in this distribution or at
     17 *  http://www.OARcorp.com/rtems/license.html.
     18 *
     19 * $Id$
     20 */
    3221
    3322#include <bsp.h>
  • c/src/lib/libbsp/powerpc/motorola_powerpc/console/keyboard.h

    r2a6a029f rfcee56c0  
     1/*
     2 *  keyboard.h  -- keyboard definitions.
     3 *
     4 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     5 *
     6 *  The license and distribution terms for this file may be
     7 *  found in found in the file LICENSE in this distribution or at
     8 *  http://www.OARcorp.com/rtems/license.html.
     9 *
     10 * $Id$
     11 */
     12
    113#ifndef __LINUX_KEYBOARD_H
    214#define __LINUX_KEYBOARD_H
  • c/src/lib/libbsp/powerpc/motorola_powerpc/console/polled_io.c

    r2a6a029f rfcee56c0  
    11/*
    2  * arch/ppc/prepboot/console.c
     2 *  polled_io.c -- Basic input/output for early boot
    33 *
    4  *  Copyright (C) 1998 Gabriel Paubert, paubert@iram.es
     4 *  Copyright (C) 1998, 1999 Gabriel Paubert, paubert@iram.es
    55 *
    6  *  This file is based on arch/ppc/boot/{kbd,vreset}.c in previous versions
    7  * of Linux/PPC, mostly contributed by Gary Thomas and Cort Dougan.
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
    88 *
    9  *  This file is subject to the terms and conditions of the GNU General Public
    10  *  License.  See the file COPYING in the main directory of this archive
    11  *  for more details.
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
    1216 */
    1317
  • c/src/lib/libbsp/powerpc/motorola_powerpc/include/bsp.h

    r2a6a029f rfcee56c0  
    11/*
    2  * empty file. Just because referenced by portable application layer.
     2 *  bsp.h  -- contain BSP API definition.
     3 *
     4 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     5 *
     6 *  The license and distribution terms for this file may be
     7 *  found in found in the file LICENSE in this distribution or at
     8 *  http://www.OARcorp.com/rtems/license.html.
     9 *
     10 * $Id$
    311 */
    412#ifndef LIBBSP_POWERPC_MCP750_BSP_H
  • c/src/lib/libbsp/powerpc/motorola_powerpc/include/nvram.h

    r2a6a029f rfcee56c0  
    11/*
    22 * PreP compliant NVRAM access
     3 *
     4 * This file can be found in motorla or IBP PPC site.
     5 *
     6 * $Id$
    37 */
    48
  • c/src/lib/libbsp/powerpc/motorola_powerpc/irq/i8259.c

    r2a6a029f rfcee56c0  
    1 /* i8259.c
    2  *
     1
     2/*
    33 *  This file contains the implementation of the function described in irq.h
    44 *  related to Intel 8259 Programmable Interrupt controller.
    55 *
    6  *  CopyRight (C) 1998 valette@crf.canon.fr
     6 *  Copyright (C) 1998, 1999 valette@crf.canon.fr
    77 *
    88 *  The license and distribution terms for this file may be
     
    1212 *  $Id$
    1313 */
    14 
    15 
     14 
    1615#include <bsp.h>
    1716#include <bsp/irq.h>
  • c/src/lib/libbsp/powerpc/motorola_powerpc/irq/irq.c

    r2a6a029f rfcee56c0  
    1 /* irq.c
     1/*
    22 *
    33 *  This file contains the implementation of the function described in irq.h
    44 *
    5  *  CopyRight (C) 1998 valette@crf.canon.fr
     5 *  Copyright (C) 1998, 1999 valette@crf.canon.fr
    66 *
    77 *  The license and distribution terms for this file may be
     
    1111 *  $Id$
    1212 */
    13 
    14 
     13 
    1514#include <bsp.h>
    1615#include <bsp/irq.h>
     
    2019#include <libcpu/raw_exception.h>
    2120#include <bsp/vectors.h>
    22 #include <libcpu/processor.h>
     21#include <libcpu/cpu.h>
    2322
    2423#define RAVEN_INTR_ACK_REG 0xfeff0030
  • c/src/lib/libbsp/powerpc/motorola_powerpc/irq/irq_asm.S

    r2a6a029f rfcee56c0  
    11/*
    2  * (c) 1999, Eric Valette valette@crf.canon.fr
    3  *
    4  *
    52 *  This file contains the assembly code for the PowerPC
    63 *  IRQ veneers for RTEMS.
    74 *
     5 *  The license and distribution terms for this file may be
     6 *  found in found in the file LICENSE in this distribution or at
     7 *  http://www.OARcorp.com/rtems/license.html.
     8 *
    89 * $Id$
    910 */
    10        
    11 
    12 
     11       
    1312#include <bsp/vectors.h>
    1413#include <libcpu/cpu.h>
  • c/src/lib/libbsp/powerpc/motorola_powerpc/openpic/openpic.c

    r2a6a029f rfcee56c0  
    11/*
    2  *  arch/ppc/kernel/openpic.c -- OpenPIC Interrupt Handling
     2 *  openpic.c -- OpenPIC Interrupt Handling
    33 *
    44 *  Copyright (C) 1997 Geert Uytterhoeven
    55 *
    6  *  This file is subject to the terms and conditions of the GNU General Public
    7  *  License.  See the file COPYING in the main directory of this archive
    8  *  for more details.
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
     8 *
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
    916 */
    10 
    1117
    1218/*
     
    2026#include <libcpu/io.h>
    2127#include <libcpu/byteorder.h>
    22 
    23 /* #include <asm/irq.h> */
    2428
    2529#define NULL 0
  • c/src/lib/libbsp/powerpc/motorola_powerpc/openpic/openpic.h

    r2a6a029f rfcee56c0  
    11/*
    2  *  linux/openpic.h -- OpenPIC definitions
     2 *  openpic.h -- OpenPIC definitions
    33 *
    44 *  Copyright (C) 1997 Geert Uytterhoeven
     
    2222 *  License.  See the file COPYING in the main directory of this archive
    2323 *  for more details.
     24 *
     25 *  Modified to compile in RTEMS development environment
     26 *  by Eric Valette
     27 *
     28 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     29 *
     30 *  The license and distribution terms for this file may be
     31 *  found in found in the file LICENSE in this distribution or at
     32 *  http://www.OARcorp.com/rtems/license.html.
     33 *
     34 * $Id$
    2435 */
    2536
  • c/src/lib/libbsp/powerpc/motorola_powerpc/pci/pci.c

    r2a6a029f rfcee56c0  
     1/*
     2 * pci.c :  this file contains basic PCI Io functions.
     3 *
     4 *  CopyRight (C) 1999 valette@crf.canon.fr
     5 *
     6 *  This code is heavilly inspired by the public specification of STREAM V2
     7 *  that can be found at :
     8 *
     9 *      <http://www.chorus.com/Documentation/index.html> by following
     10 *  the STREAM API Specification Document link.
     11 *
     12 *  The license and distribution terms for this file may be
     13 *  found in found in the file LICENSE in this distribution or at
     14 *  http://www.OARcorp.com/rtems/license.html.
     15 *
     16 *  $Id$
     17 */
     18
    119#include <bsp/consoleIo.h>
    220#include <libcpu/io.h>
  • c/src/lib/libbsp/powerpc/motorola_powerpc/pci/pci.h

    r2a6a029f rfcee56c0  
    1212 *      PCI to PCI Bridge Specification
    1313 *      PCI System Design Guide
     14 *
     15 * $Id$
    1416 */
    1517
  • c/src/lib/libbsp/powerpc/motorola_powerpc/residual/pnp.h

    r2a6a029f rfcee56c0  
    1414/* For enum's: if given in hex then they are bit significant, i.e.            */
    1515/* only one bit is on for each enum                                           */
     16
     17/*
     18 * $Id$
     19 */
    1620
    1721#ifndef _PNP_
  • c/src/lib/libbsp/powerpc/motorola_powerpc/residual/residual.c

    r2a6a029f rfcee56c0  
     1/*
     2 * residual.c : function used to parse residual data.
     3 *
     4 *  CopyRight (C) 1999 valette@crf.canon.fr
     5 *
     6 *  This code is heavilly inspired by the public specification of STREAM V2
     7 *  that can be found at :
     8 *
     9 *  The license and distribution terms for this file may be
     10 *  found in found in the file LICENSE in this distribution or at
     11 *  http://www.OARcorp.com/rtems/license.html.
     12 *
     13 *  $Id$
     14 */
     15
    116#include <bsp/residual.h>
    217#include <libcpu/io.h>
  • c/src/lib/libbsp/powerpc/motorola_powerpc/residual/residual.h

    r2a6a029f rfcee56c0  
    1010/*             i.e. only one bit is on for each enum                          */
    1111/* Reserved fields must be filled with zeros.                                */
     12
     13/*
     14 * $Id$
     15 */
    1216
    1317#ifndef _RESIDUAL_
  • c/src/lib/libbsp/powerpc/motorola_powerpc/startup/bspstart.c

    r2a6a029f rfcee56c0  
    1212 *  found in the file LICENSE in this distribution or at
    1313 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 *  Modified to support the MCP750.
     16 *  Modifications Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
    1417 *
    1518 *  $Id$
     
    120123{
    121124    extern int end;
    122     rtems_unsigned32        heap_start;
     125    rtems_unsigned32        heap_start;   
     126    rtems_unsigned32        heap_size;
    123127
    124128    heap_start = ((rtems_unsigned32) &__rtems_end) +INIT_STACK_SIZE + INTR_STACK_SIZE;
     
    126130        heap_start = (heap_start + CPU_ALIGNMENT) & ~(CPU_ALIGNMENT-1);
    127131
    128     bsp_libc_init((void *) heap_start, 64 * 1024, 0);
     132    heap_size = (BSP_mem_size - heap_start) - BSP_Configuration.work_space_size;
     133
     134    printk(" HEAP start %x  size %x\n", heap_start, heap_size);
     135    bsp_libc_init((void *) heap_start, heap_size, 0);
    129136
    130137#ifdef RTEMS_DEBUG
  • c/src/lib/libbsp/powerpc/motorola_powerpc/startup/cEntry.c

    r2a6a029f rfcee56c0  
    1 /*
    2  *
    3  */
    4 #include <bsp/consoleIo.h>
    5 #include <libcpu/spr.h>
    6 #include <bsp/residual.h>
    7 #include <bsp/pci.h>
    8 #include <bsp/openpic.h>
    9 #include <bsp/irq.h>
    10 #include <bsp.h>
    11 #include <libcpu/bat.h>
    12 
    13 extern void _return_to_ppcbug();
    14 extern unsigned long __rtems_end;
    15 
    16 RESIDUAL residualCopy;
    17 #define INIT_STACK_SIZE 0x1000
    18 #define INTR_STACK_SIZE 0x4000
    19 
    20 void BSP_panic(char *s)
    21 {
    22   printk("RTEMS 4.x PANIC %s\n", s);
    23   _return_to_ppcbug();
    24 }
    25 
    26 void _BSP_Fatal_error(unsigned int v)
    27 {
    28   printk("RTEMS 4.x PANIC ERROR %x\n", v);
    29   _return_to_ppcbug();
    30 }
    31 
    32 void
    33 boot_card(RESIDUAL* r3, void *r4, void* r5, char *additional_boot_options)
    34 {
    35   int err;
    36   unsigned char *stack;
    37   unsigned l2cr;
    38   register unsigned char* intrStack;
    39   register unsigned int intrNestingLevel = 0;
    40  
    41   L1_caches_enables();
    42   stack = ((unsigned char*) &__rtems_end) + INIT_STACK_SIZE;
    43   intrStack = ((unsigned char*) &__rtems_end) + INIT_STACK_SIZE + INTR_STACK_SIZE;
    44   asm volatile ("mtspr  273, %0" : "=r" (intrStack) : "0" (intrStack));
    45   asm volatile ("mtspr  272, %0" : "=r" (intrNestingLevel) : "0" (intrNestingLevel));
    46   residualCopy = *r3;
    47 #define NO_DYNAMIC_EXCEPTION_VECTOR_INSTALL
    48 #undef  NO_DYNAMIC_EXCEPTION_VECTOR_INSTALL
    49 #ifndef NO_DYNAMIC_EXCEPTION_VECTOR_INSTALL 
    50   initialize_exceptions();
    51 #endif
    52   select_console(CONSOLE_LOG);
    53 
    54   /* We check that the keyboard is present and immediately
    55    * select the serial console if not.
    56    */
    57   err = kbdreset();
    58   if (err) select_console(CONSOLE_SERIAL);
    59 
    60  
    61   printk("Welcome to RTEMS 4.0.2 on Motorola MCP750\n\n\n");
    62   printk("-----------------------------------------\n");
    63   printk("Residuals are located at %x\n", (unsigned) r3);
    64   printk("Additionnal boot options are %s\n", additional_boot_options);
    65   printk("-----------------------------------------\n");
    66 
    67   printk("Initial system stack at %x\n",stack);
    68   l2cr = get_L2CR();
    69   printk("Initial L2CR value = %x\n", l2cr);
    70   if (! (l2cr & 0x80000000))
    71     set_L2CR(0xb9A14000);
    72 #ifdef TEST_RETURN_TO_PPCBUG 
    73   printk("Hit <Enter> to return to PPCBUG monitor\n");
    74   printk("When Finished hit GO. It should print <Back from monitor>\n");
    75   debug_getc();
    76   _return_to_ppcbug();
    77   printk("Back from monitor\n");
    78   _return_to_ppcbug();
    79 #endif /* TEST_RETURN_TO_PPCBUG  */
    80 
    81   /*
    82    * Init MMU block address translation to enable hardware
    83    * access
    84    */
    85   /*
    86    * PC legacy IO space used for inb/outb and all PC
    87    * compatible hardware
    88    */
    89   setdbat(1, 0x80000000, 0x80000000, 0x10000000, IO_PAGE);
    90   /*
    91    * PCI devices memory area. Needed to access OPENPIC features
    92    * provided by the RAVEN
    93    */
    94   setdbat(2, 0xc0000000, 0xc0000000, 0x08000000, IO_PAGE);
    95   /*
    96    * Must have acces to open pic PCI ACK registers
    97    * provided by the RAVEN
    98    */
    99   setdbat(3, 0xfeff0000, 0xfeff0000, 0x10000, IO_PAGE);
    100 
    101   printk("Going to start PCI buses scanning and initialization\n");
    102   InitializePCI();
    103   printk("Number of PCI buses is found : %d\n", BusCountPCI());
    104 #ifdef TEST_RAW_EXCEPTION_CODE 
    105   printk("Testing exception handling Part 1\n");
    106   /*
    107    * Cause a software exception
    108    */
    109   __asm__ __volatile ("sc");
    110   /*
    111    * Check we can still catch exceptions
    112    */
    113   printk("Testing exception handling Part 2\n");
    114   __asm__ __volatile ("sc");
    115 #endif 
    116   BSP_rtems_irq_mng_init(0);
    117   printk("Init done\n");
    118   debug_getc();
    119   while(1);
    120 }
    121 
  • c/src/lib/libbsp/powerpc/motorola_powerpc/vectors/vectors.h

    r2a6a029f rfcee56c0  
     1/*
     2 * vectors.h Exception frame related contant and API.
     3 *
     4 *  This include file describe the data structure and the functions implemented
     5 *  by rtems to handle exceptions.
     6 *
     7 *  CopyRight (C) 1999 valette@crf.canon.fr
     8 *
     9 *  The license and distribution terms for this file may be
     10 *  found in found in the file LICENSE in this distribution or at
     11 *  http://www.OARcorp.com/rtems/license.html.
     12 *
     13 *  $Id$
     14 */
    115#ifndef LIBBSP_POWERPC_MCP750_VECTORS_H
    216#define LIBBSP_POWERPC_MCP750_VECTORS_H
  • c/src/lib/libbsp/powerpc/motorola_powerpc/vectors/vectors_init.c

    r2a6a029f rfcee56c0  
    1 /*
     1/*
     2 * vectors_init.c Exception hanlding initialisation (and generic handler).
    23 *
     4 *  This include file describe the data structure and the functions implemented
     5 *  by rtems to handle exceptions.
     6 *
     7 *  CopyRight (C) 1999 valette@crf.canon.fr
     8 *
     9 *  The license and distribution terms for this file may be
     10 *  found in found in the file LICENSE in this distribution or at
     11 *  http://www.OARcorp.com/rtems/license.html.
     12 *
     13 *  $Id$
    314 */
    415#include <bsp/vectors.h>
  • c/src/lib/libbsp/powerpc/motorola_powerpc/wrapup/Makefile.in

    r2a6a029f rfcee56c0  
    1616VPATH = @srcdir@
    1717
    18 BSP_PIECES=console irq openpic pci residual startup vectors
     18BSP_PIECES=console irq openpic pci residual startup dec21140 vectors
    1919GENERIC_PIECES=
    2020
  • c/src/lib/libcpu/powerpc/mpc750/clock/c_clock.c

    r2a6a029f rfcee56c0  
    1414 *  the file LICENSE in this distribution or at
    1515 *  http://www.OARcorp.com/rtems/license.html.
     16 *
     17 *  Modified to support the MPC750.
     18 *  Modifications Copyright (c) 1999 Eric Valette valette@crf.canon.fr
    1619 *
    1720 *  $Id$
  • c/src/lib/libcpu/powerpc/mpc750/mmu/mmuAsm.S

    r2a6a029f rfcee56c0  
    99 *  features.
    1010 *
    11  *  This program is free software; you can redistribute it and/or
    12  *  modify it under the terms of the GNU General Public License
    13  *  as published by the Free Software Foundation; either version
    14  *  2 of the License, or (at your option) any later version.
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
    1514 *     
    1615 */
    1716
    1817#include <libcpu/cpu.h>
    19 #include <libcpu/processor.h>
    2018#include <libcpu/io.h>
    2119#include <rtems/score/targopts.h>
  • c/src/lib/libcpu/powerpc/shared/Makefile.in

    r2a6a029f rfcee56c0  
    1515C_O_FILES=$(C_PIECES:%=${ARCH}/%.o)
    1616
    17 H_FILES=$(srcdir)/cpu.h $(srcdir)/spr.h $(srcdir)/io.h $(srcdir)/mmu.h $(srcdir)/page.h $(srcdir)/byteorder.h $(srcdir)/pgtable.h $(srcdir)/processor.h
     17H_FILES=$(srcdir)/cpu.h $(srcdir)/spr.h $(srcdir)/io.h $(srcdir)/mmu.h $(srcdir)/page.h $(srcdir)/byteorder.h $(srcdir)/pgtable.h
    1818
    1919# Assembly source names, if any, go here -- minus the .s
  • c/src/lib/libcpu/powerpc/shared/byteorder.h

    r2a6a029f rfcee56c0  
     1/*
     2 * byteorder.h
     3 *
     4 *        This file contains inline implementation of function to
     5 *          deal with endian conversion.
     6 *
     7 * It is a stripped down version of linux ppc file...
     8 *
     9 * Copyright (C) 1999  Eric Valette (valette@crf.canon.fr)
     10 *                     Canon Centre Recherche France.
     11 *
     12 *  The license and distribution terms for this file may be
     13 *  found in found in the file LICENSE in this distribution or at
     14 *  http://www.OARcorp.com/rtems/license.html.
     15 *
     16 *  $Id$
     17 */
     18
    119#ifndef _PPC_BYTEORDER_H
    220#define _PPC_BYTEORDER_H
  • c/src/lib/libcpu/powerpc/shared/cpu.h

    r2a6a029f rfcee56c0  
     1/*
     2 * cpu.h
     3 *
     4 *          This file contains some powerpc MSR and registers access definitions.
     5 *
     6 * It is a stripped down version of linux ppc processor.h file...
     7 *
     8 * Copyright (C) 1999  Eric Valette (valette@crf.canon.fr)
     9 *                     Canon Centre Recherche France.
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 *  $Id$
     16 */
     17
    118#ifndef __ASM_PPC_PROCESSOR_H
    219#define __ASM_PPC_PROCESSOR_H
  • c/src/lib/libcpu/powerpc/shared/io.h

    r2a6a029f rfcee56c0  
     1/*
     2 * io.h
     3 *
     4 *          This file contains inline implementation of function to
     5 *          deal with IO.
     6 *
     7 * It is a stripped down version of linux ppc file...
     8 *
     9 * Copyright (C) 1999  Eric Valette (valette@crf.canon.fr)
     10 *                     Canon Centre Recherche France.
     11 *
     12 *  The license and distribution terms for this file may be
     13 *  found in found in the file LICENSE in this distribution or at
     14 *  http://www.OARcorp.com/rtems/license.html.
     15 *
     16 *  $Id$
     17 */
    118#ifndef _LIBCPU_IO_H_
    219#define _LIBCPU_IO_H_
  • c/src/lib/libcpu/powerpc/shared/mmu.h

    r2a6a029f rfcee56c0  
    11/*
    2  * PowerPC memory management structures
     2 * mmu.h
     3 *
     4 *      PowerPC memory management structures
     5 *
     6 * It is a stripped down version of linux ppc file...
     7 *
     8 * Copyright (C) 1999  Eric Valette (valette@crf.canon.fr)
     9 *                     Canon Centre Recherche France.
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 *  $Id$
    316 */
    417
  • c/src/lib/libcpu/powerpc/shared/page.h

    r2a6a029f rfcee56c0  
     1/*
     2 * page.h
     3 *
     4 *      PowerPC memory management structures
     5 *
     6 * It is a stripped down version of linux ppc file...
     7 *
     8 * Copyright (C) 1999  Eric Valette (valette@crf.canon.fr)
     9 *                     Canon Centre Recherche France.
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 *  $Id$
     16 */
     17
    118#ifndef _PPC_PAGE_H
    219#define _PPC_PAGE_H
  • c/src/lib/libcpu/powerpc/shared/pgtable.h

    r2a6a029f rfcee56c0  
     1/*
     2 * pgtable.h
     3 *
     4 *      PowerPC memory management structures
     5 *
     6 * It is a stripped down version of linux ppc file...
     7 *
     8 * Copyright (C) 1999  Eric Valette (valette@crf.canon.fr)
     9 *                     Canon Centre Recherche France.
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 *  $Id$
     16 */
     17
    118#ifndef _PPC_PGTABLE_H
    219#define _PPC_PGTABLE_H
  • c/src/lib/libcpu/powerpc/shared/processor.h

    r2a6a029f rfcee56c0  
    1 #ifndef __ASM_PPC_PROCESSOR_H
    2 #define __ASM_PPC_PROCESSOR_H
    3 
    4 #include <bsp/residual.h>
    5 
    6 /* Bit encodings for Machine State Register (MSR) */
    7 #define MSR_POW         (1<<18)         /* Enable Power Management */
    8 #define MSR_TGPR        (1<<17)         /* TLB Update registers in use */
    9 #define MSR_ILE         (1<<16)         /* Interrupt Little-Endian enable */
    10 #define MSR_EE          (1<<15)         /* External Interrupt enable */
    11 #define MSR_PR          (1<<14)         /* Supervisor/User privilege */
    12 #define MSR_FP          (1<<13)         /* Floating Point enable */
    13 #define MSR_ME          (1<<12)         /* Machine Check enable */
    14 #define MSR_FE0         (1<<11)         /* Floating Exception mode 0 */
    15 #define MSR_SE          (1<<10)         /* Single Step */
    16 #define MSR_BE          (1<<9)          /* Branch Trace */
    17 #define MSR_FE1         (1<<8)          /* Floating Exception mode 1 */
    18 #define MSR_IP          (1<<6)          /* Exception prefix 0x000/0xFFF */
    19 #define MSR_IR          (1<<5)          /* Instruction MMU enable */
    20 #define MSR_DR          (1<<4)          /* Data MMU enable */
    21 #define MSR_RI          (1<<1)          /* Recoverable Exception */
    22 #define MSR_LE          (1<<0)          /* Little-Endian enable */
    23 
    24 #define MSR_            MSR_ME|MSR_RI
    25 #define MSR_KERNEL      MSR_|MSR_IR|MSR_DR
    26 #define MSR_USER        MSR_KERNEL|MSR_PR|MSR_EE
    27 
    28 /* Bit encodings for Hardware Implementation Register (HID0)
    29    on PowerPC 603, 604, etc. processors (not 601). */
    30 #define HID0_EMCP       (1<<31)         /* Enable Machine Check pin */
    31 #define HID0_EBA        (1<<29)         /* Enable Bus Address Parity */
    32 #define HID0_EBD        (1<<28)         /* Enable Bus Data Parity */
    33 #define HID0_SBCLK      (1<<27)
    34 #define HID0_EICE       (1<<26)
    35 #define HID0_ECLK       (1<<25)
    36 #define HID0_PAR        (1<<24)
    37 #define HID0_DOZE       (1<<23)
    38 #define HID0_NAP        (1<<22)
    39 #define HID0_SLEEP      (1<<21)
    40 #define HID0_DPM        (1<<20)
    41 #define HID0_ICE        (1<<15)         /* Instruction Cache Enable */
    42 #define HID0_DCE        (1<<14)         /* Data Cache Enable */
    43 #define HID0_ILOCK      (1<<13)         /* Instruction Cache Lock */
    44 #define HID0_DLOCK      (1<<12)         /* Data Cache Lock */
    45 #define HID0_ICFI       (1<<11)         /* Instruction Cache Flash Invalidate */
    46 #define HID0_DCI        (1<<10)         /* Data Cache Invalidate */
    47 #define HID0_SIED       (1<<7)          /* Serial Instruction Execution [Disable] */
    48 #define HID0_BHTE       (1<<2)          /* Branch History Table Enable */
    49 #define HID0_BTCD       (1<<1)          /* Branch target cache disable */
    50 
    51 /* fpscr settings */
    52 #define FPSCR_FX        (1<<31)
    53 #define FPSCR_FEX       (1<<30)
    54 
    55 #define _MACH_prep     1
    56 #define _MACH_Pmac     2 /* pmac or pmac clone (non-chrp) */
    57 #define _MACH_chrp     4 /* chrp machine */
    58 #define _MACH_mbx      8 /* Motorola MBX board */
    59 #define _MACH_apus    16 /* amiga with phase5 powerup */
    60 #define _MACH_fads    32 /* Motorola FADS board */
    61 
    62 /* see residual.h for these */
    63 #define _PREP_Motorola 0x01  /* motorola prep */
    64 #define _PREP_Firm     0x02  /* firmworks prep */
    65 #define _PREP_IBM      0x00  /* ibm prep */
    66 #define _PREP_Bull     0x03  /* bull prep */
    67 
    68 /* these are arbitrary */
    69 #define _CHRP_Motorola 0x04  /* motorola chrp, the cobra */
    70 #define _CHRP_IBM     0x05   /* IBM chrp, the longtrail and longtrail 2 */
    71 
    72 #define _GLOBAL(n)\
    73         .globl n;\
    74 n:
    75 
    76 #define TBRU    269     /* Time base Upper/Lower (Reading) */
    77 #define TBRL    268
    78 #define TBWU    284     /* Time base Upper/Lower (Writing) */
    79 #define TBWL    285
    80 #define XER     1
    81 #define LR      8
    82 #define CTR     9
    83 #define HID0    1008    /* Hardware Implementation */
    84 #define PVR     287     /* Processor Version */
    85 #define IBAT0U  528     /* Instruction BAT #0 Upper/Lower */
    86 #define IBAT0L  529
    87 #define IBAT1U  530     /* Instruction BAT #1 Upper/Lower */
    88 #define IBAT1L  531
    89 #define IBAT2U  532     /* Instruction BAT #2 Upper/Lower */
    90 #define IBAT2L  533
    91 #define IBAT3U  534     /* Instruction BAT #3 Upper/Lower */
    92 #define IBAT3L  535
    93 #define DBAT0U  536     /* Data BAT #0 Upper/Lower */
    94 #define DBAT0L  537
    95 #define DBAT1U  538     /* Data BAT #1 Upper/Lower */
    96 #define DBAT1L  539
    97 #define DBAT2U  540     /* Data BAT #2 Upper/Lower */
    98 #define DBAT2L  541
    99 #define DBAT3U  542     /* Data BAT #3 Upper/Lower */
    100 #define DBAT3L  543
    101 #define DMISS   976     /* TLB Lookup/Refresh registers */
    102 #define DCMP    977
    103 #define HASH1   978
    104 #define HASH2   979
    105 #define IMISS   980
    106 #define ICMP    981
    107 #define RPA     982
    108 #define SDR1    25      /* MMU hash base register */
    109 #define DAR     19      /* Data Address Register */
    110 #define SPR0    272     /* Supervisor Private Registers */
    111 #define SPRG0   272
    112 #define SPR1    273
    113 #define SPRG1   273
    114 #define SPR2    274
    115 #define SPRG2   274
    116 #define SPR3    275
    117 #define SPRG3   275
    118 #define DSISR   18
    119 #define SRR0    26      /* Saved Registers (exception) */
    120 #define SRR1    27
    121 #define IABR    1010    /* Instruction Address Breakpoint */
    122 #define DEC     22      /* Decrementer */
    123 #define EAR     282     /* External Address Register */
    124 #define L2CR    1017    /* PPC 750 L2 control register */
    125 
    126 #define THRM1   1020
    127 #define THRM2   1021
    128 #define THRM3   1022
    129 #define THRM1_TIN 0x1
    130 #define THRM1_TIV 0x2
    131 #define THRM1_THRES (0x7f<<2)
    132 #define THRM1_TID (1<<29)
    133 #define THRM1_TIE (1<<30)
    134 #define THRM1_V   (1<<31)
    135 #define THRM3_E   (1<<31)
    136 
    137 /* Segment Registers */
    138 #define SR0     0
    139 #define SR1     1
    140 #define SR2     2
    141 #define SR3     3
    142 #define SR4     4
    143 #define SR5     5
    144 #define SR6     6
    145 #define SR7     7
    146 #define SR8     8
    147 #define SR9     9
    148 #define SR10    10
    149 #define SR11    11
    150 #define SR12    12
    151 #define SR13    13
    152 #define SR14    14
    153 #define SR15    15
    154 
    155 #endif /* __ASM_PPC_PROCESSOR_H */
    156 
    157 
    158 
    159 
    160 
    161 
    162 
  • c/src/lib/libcpu/powerpc/shared/spr.h

    r2a6a029f rfcee56c0  
    11/*
    2  *  include/asm-ppc/spr.h -- Access to special purpose registers.
     2 *  spr.h -- Access to special purpose registers.
    33 *
    44 *  Copyright (C) 1998 Gabriel Paubert, paubert@iram.es
    55 *
    6  *  This file is subject to the terms and conditions of the GNU General Public
    7  *  License.  See the file COPYING in the main directory of this archive
    8  *  for more details.
     6 *  Modified to compile in RTEMS development environment
     7 *  by Eric Valette
     8 *
     9 *  Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
     10 *
     11 *  The license and distribution terms for this file may be
     12 *  found in found in the file LICENSE in this distribution or at
     13 *  http://www.OARcorp.com/rtems/license.html.
     14 *
     15 * $Id$
     16 *
    917 */
    1018
Note: See TracChangeset for help on using the changeset viewer.