OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [or1ksim/] [testsuite/] [test-code-or1k/] [mc-async/] [mc-async.h] - Blame information for rev 581

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 90 jeremybenn
/* mc_async.h - Memory Controller testbench ASYNCdevices defines
2
 
3
   Copyright (C) 2001 Ivan Guzvinec
4
   Copyright (C) 2010 Embecosm Limited
5
 
6
   Contributor Ivan Guzvinec <ivang@opencores.org>
7
   Contributor Jeremy Bennett <jeremy.bennett@embecosm.com>
8
 
9
   This file is part of OpenRISC 1000 Architectural Simulator.
10
 
11
   This program is free software; you can redistribute it and/or modify it
12
   under the terms of the GNU General Public License as published by the Free
13
   Software Foundation; either version 3 of the License, or (at your option)
14
   any later version.
15
 
16
   This program is distributed in the hope that it will be useful, but WITHOUT
17
   ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18
   FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
19
   more details.
20
 
21
   You should have received a copy of the GNU General Public License along
22
   with this program.  If not, see <http:  www.gnu.org/licenses/>.  */
23
 
24
/* ----------------------------------------------------------------------------
25
   This code is commented throughout for use with Doxygen.
26
   --------------------------------------------------------------------------*/
27
 
28
#ifndef __MC_ASYNC_H
29
#define __MC_ASYNC_H
30
 
31
/* should configuration be readm from MC? */
32
#define MC_READ_CONF
33
 
34
/* TEMPLATE SELECTION       */
35
/* change #undef to #define */
36
#define _MC_TEST_TEMPLATE1
37
#undef  _MC_TEST_TEMPLATE2
38
#undef  _MC_TEST_TEMPLATE3
39
/* ------------------------ */
40
 
41
/* memory configuration that must reflect mcmem.cfg */
42
#define MC_ASYNC_CSMASK 0xFE    /* 8 bit mask for 8 chip selects. 1 ASYNC at CS, 0 something else at CS */
43
 
44
typedef struct MC_ASYNC_CS
45
{
46
  unsigned long BW;
47
  unsigned long M;
48
} MC_ASYNC_CS;
49
 
50
MC_ASYNC_CS mc_async_cs[8] = {
51
  { 2,    /* Bus Width : 0 - 8bit, 1 - 16bit, 2 - 32bit */
52
    0x02  /* SELect mask */
53
    },
54
  { 2, 0x04 },
55
  { 2, 0x06 },
56
  { 2, 0x08 },
57
  { 2, 0x0A },
58
  { 2, 0x0C },
59
  { 2, 0x0E },
60
  { 2, 0x10 } };
61
 
62
#define MC_ASYNC_TEST0  0x00000001LU /* no parity, bank after column, write enable */
63
#define MC_ASYNC_TEST1  0x00000002LU /* parity */
64
#define MC_ASYNC_TEST2  0x00000004LU /* bank after row */
65
#define MC_ASYNC_TEST3  0x00000008LU /* RO */
66
#define MC_ASYNC_TEST4  0x00000010LU /* - NOT DEFINED - */
67
 
68
#ifdef _MC_TEST_TEMPLATE1 
69
  #define MC_ASYNC_FLAGS        0x000002B4LU    /* MC_TEST_ flags... see mc_common.h */
70
  #define MC_ASYNC_TESTS        0x0000000FLU
71
#endif
72
 
73
#ifdef _MC_TEST_TEMPLATE2 
74
  #define MC_ASYNC_FLAGS        0x00000128LU    /* MC_TEST_ flags... see mc_common.h */
75
  #define MC_ASYNC_TESTS        0x00000008LU
76
#endif
77
 
78
#ifdef _MC_TEST_TEMPLATE3 
79
  #define MC_ASYNC_FLAGS        0x000007FFLU    /* MC_TEST_ flags... see mc_common.h */
80
  #define MC_ASYNC_TESTS        0x0000000FLU
81
#endif
82
 
83
#endif

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.