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

Subversion Repositories mips_enhanced

[/] [mips_enhanced/] [trunk/] [grlib-gpl-1.0.19-b3188/] [lib/] [gaisler/] [ata/] [ata.vhd] - Blame information for rev 2

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 2 dimamali
------------------------------------------------------------------------------
2
--  This file is a part of the GRLIB VHDL IP LIBRARY
3
--  Copyright (C) 2003, Gaisler Research
4
--
5
--  This program is free software; you can redistribute it and/or modify
6
--  it under the terms of the GNU General Public License as published by
7
--  the Free Software Foundation; either version 2 of the License, or
8
--  (at your option) any later version.
9
--
10
--  This program is distributed in the hope that it will be useful,
11
--  but WITHOUT ANY WARRANTY; without even the implied warranty of
12
--  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13
--  GNU General Public License for more details.
14
--
15
--  You should have received a copy of the GNU General Public License
16
--  along with this program; if not, write to the Free Software
17
--  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA 
18
-----------------------------------------------------------------------------
19
-- Entity:  ata
20
-- File: ata.vhd
21
-- Authors: Nils-Johan Wessman, Jiri Gaisler - Gaisler Research
22
-- Description: ATA controller package
23
------------------------------------------------------------------------------
24
 
25
library ieee;
26
use ieee.std_logic_1164.all;
27
library grlib;
28
use grlib.amba.all;
29
 
30
package ata is
31
 
32
type ata_in_type is record
33
   ddi   : std_logic_vector(15 downto 0);
34
   iordy : std_logic;
35
   intrq : std_logic;
36
   dmarq : std_logic;
37
end record;
38
 
39
type ata_out_type is record
40
   rstn  : std_logic;
41
   ddo   : std_logic_vector(15 downto 0);
42
   oen   : std_logic;
43
   da    : std_logic_vector(2 downto 0);
44
   cs0   : std_logic;
45
   cs1   : std_logic;
46
   dior  : std_logic;
47
   diow  : std_logic;
48
   dmack : std_logic;
49
end record;
50
 
51
type cf_out_type is record
52
   power    : std_logic;
53
   atasel   : std_logic;
54
   we       : std_logic;
55
   csel     : std_logic;
56
   da       : std_logic_vector(10 downto 3);
57
end record;
58
 
59
component atactrl is
60
 generic (
61
   tech    : integer := 0;
62
   fdepth  : integer := 8;
63
   mhindex : integer := 0;
64
   shindex  : integer := 0;
65
   haddr   : integer := 0;
66
   hmask   : integer := 16#ff0#;
67
   pirq    : integer := 0;
68
   mwdma   : integer := 0;
69
 
70
   TWIDTH : natural := 8;                      -- counter width
71
 
72
   -- PIO mode 0 settings (@100MHz clock)
73
   PIO_mode0_T1 : natural := 6;                -- 70ns
74
   PIO_mode0_T2 : natural := 28;               -- 290ns
75
   PIO_mode0_T4 : natural := 2;                -- 30ns
76
   PIO_mode0_Teoc : natural := 23              -- 240ns ==> T0 - T1 - T2 = 600 - 70 - 290 = 240
77
 
78
 );
79
 port (
80
   rst     : in  std_ulogic;
81
   arst    : in  std_ulogic;
82
   clk     : in  std_ulogic;
83
   ahbsi   : in  ahb_slv_in_type;
84
   ahbso   : out ahb_slv_out_type;
85
   ahbmi   : in  ahb_mst_in_type;
86
   ahbmo   : out ahb_mst_out_type;
87
   cfo     : out cf_out_type;
88
   atai    : in ata_in_type;
89
   atao    : out ata_out_type
90
 );
91
end component;
92
 
93
end;

powered by: WebSVN 2.1.0

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