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

Subversion Repositories or1k

[/] [or1k/] [tags/] [nog_patch_69/] [or1ksim/] [testbench/] [mc_ssram.h] - Blame information for rev 1765

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 454 ivang
/* mc_ssram.h - Memory Controller testbench SSRAM defines
2
         Copyright (C) 2001 by Ivan Guzvinec, ivang@opencores.org
3
 
4
         This file is part of OpenRISC 1000 Architectural Simulator.
5
 
6
         This program is free software; you can redistribute it and/or modify
7
         it under the terms of the GNU General Public License as published by
8
         the Free Software Foundation; either version 2 of the License, or
9
         (at your option) any later version.
10
 
11
         This program is distributed in the hope that it will be useful,
12
         but WITHOUT ANY WARRANTY; without even the implied warranty of
13
         MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.    See the
14
         GNU General Public License for more details.
15
 
16
         You should have received a copy of the GNU General Public License
17
         along with this program; if not, write to the Free Software
18
         Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
19
*/
20
 
21
#ifndef __MC_SSRAM_H
22
#define __MC_SSRAM_H
23
 
24 552 ivang
/* should configuration be read form MC? */
25
#define MC_READ_CONF
26
 
27 469 ivang
/* TEMPLATE SELECTION       */
28
/* change #undef to #define */
29
#define _MC_TEST_TEMPLATE1
30
#undef  _MC_TEST_TEMPLATE2
31
#undef  _MC_TEST_TEMPLATE3
32
/* ------------------------ */
33
 
34 454 ivang
/* memory configuration that must reflect mcmem.cfg */
35 469 ivang
#define MC_SSRAM_CSMASK 0xFE    /* 8 bit mask for 8 chip selects. 1 SSRAM at CS, 0 something else at CS */
36 454 ivang
 
37
typedef struct MC_SSRAM_CS
38
{
39 552 ivang
  unsigned long M;
40 454 ivang
} MC_SSRAM_CS;
41
 
42
MC_SSRAM_CS mc_ssram_cs[8] = {
43
  {  0x02  /* SELect mask */
44
    },
45
  { 0x04 },
46
  { 0x06 },
47
  { 0x08 },
48
  { 0x0A },
49
  { 0x0C },
50
  { 0x0E },
51
  { 0x10 } };
52
 
53 469 ivang
#define MC_SSRAM_TEST0  0x00000001LU /* no parity, bank after column, write enable */
54
#define MC_SSRAM_TEST1  0x00000002LU /* parity */
55
#define MC_SSRAM_TEST2  0x00000004LU /* bank after row */
56
#define MC_SSRAM_TEST3  0x00000008LU /* RO */
57
#define MC_SSRAM_TEST4  0x00000010LU /* - NOT DEFINED - */
58
#define MC_SSRAM_TEST5  0x00000020LU /* - NOT DEFINED - */
59 454 ivang
 
60 469 ivang
#ifdef _MC_TEST_TEMPLATE1
61
  #define MC_SSRAM_FLAGS        0x000002B8LU    /* MC_TEST_ flags... see mc_common.h */ 
62
  #define MC_SSRAM_TESTS        0x00000005LU
63
#endif
64 454 ivang
 
65 469 ivang
#ifdef _MC_TEST_TEMPLATE2
66
  #define MC_SSRAM_FLAGS        0x00000128LU    /* MC_TEST_ flags... see mc_common.h */ 
67
  #define MC_SSRAM_TESTS        0x00000008LU
68 454 ivang
#endif
69 469 ivang
 
70
#ifdef _MC_TEST_TEMPLATE3
71
  #define MC_SSRAM_FLAGS        0x000007FFLU    /* MC_TEST_ flags... see mc_common.h */ 
72
  #define MC_SSRAM_TESTS        0x0000003FLU
73
#endif
74
 
75
#endif

powered by: WebSVN 2.1.0

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