OpenSSD Cosmos+ Platform Firmware
0.0.2
The firmware of Cosmos+ OpenSSD Platform for TOSHIBA nand flash module.
memory_map.h
Go to the documentation of this file.
1
2
// memory_map.h for Cosmos+ OpenSSD
3
// Copyright (c) 2017 Hanyang University ENC Lab.
4
// Contributed by Yong Ho Song <yhsong@enc.hanyang.ac.kr>
5
// Jaewook Kwak <jwkwak@enc.hanyang.ac.kr>
6
// Sangjin Lee <sjlee@enc.hanyang.ac.kr>
7
//
8
// This file is part of Cosmos+ OpenSSD.
9
//
10
// Cosmos+ OpenSSD is free software; you can redistribute it and/or modify
11
// it under the terms of the GNU General Public License as published by
12
// the Free Software Foundation; either version 3, or (at your option)
13
// any later version.
14
//
15
// Cosmos+ OpenSSD is distributed in the hope that it will be useful,
16
// but WITHOUT ANY WARRANTY; without even the implied warranty of
17
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
18
// See the GNU General Public License for more details.
19
//
20
// You should have received a copy of the GNU General Public License
21
// along with Cosmos+ OpenSSD; see the file COPYING.
22
// If not, see <http://www.gnu.org/licenses/>.
24
26
// Company: ENC Lab. <http://enc.hanyang.ac.kr>
27
// Engineer: Jaewook Kwak <jwkwak@enc.hanyang.ac.kr>
28
//
29
// Project Name: Cosmos+ OpenSSD
30
// Design Name: Cosmos+ Firmware
31
// Module Name: Static Memory Allocator
32
// File Name: memory_map.h
33
//
34
// Version: v1.0.0
35
//
36
// Description:
37
// - allocate DRAM address space (0x0010_0000 ~ 0x3FFF_FFFF) to each module
39
41
// Revision History:
42
//
43
// * v1.0.0
44
// - First draft
46
47
#ifndef MEMORY_MAP_H_
48
#define MEMORY_MAP_H_
49
50
#include "
data_buffer.h
"
51
#include "
address_translation.h
"
52
#include "
request_allocation.h
"
53
#include "
request_schedule.h
"
54
#include "
request_transform.h
"
55
#include "
garbage_collection.h
"
56
57
#define DRAM_START_ADDR 0x00100000
58
59
#define MEMORY_SEGMENTS_START_ADDR DRAM_START_ADDR
60
#define MEMORY_SEGMENTS_END_ADDR 0x001FFFFF
61
62
#define NVME_MANAGEMENT_START_ADDR 0x00200000
63
#define NVME_MANAGEMENT_END_ADDR 0x002FFFFF
64
65
#define RESERVED0_START_ADDR 0x00300000
66
#define RESERVED0_END_ADDR 0x0FFFFFFF
67
68
#define FTL_MANAGEMENT_START_ADDR 0x10000000
69
// Uncached & Unbuffered
70
// for data buffer
71
77
#define DATA_BUFFER_BASE_ADDR 0x10000000
78
#define TEMPORARY_DATA_BUFFER_BASE_ADDR \
79
(DATA_BUFFER_BASE_ADDR + AVAILABLE_DATA_BUFFER_ENTRY_COUNT * BYTES_PER_DATA_REGION_OF_SLICE)
80
#define SPARE_DATA_BUFFER_BASE_ADDR \
81
(TEMPORARY_DATA_BUFFER_BASE_ADDR + \
82
AVAILABLE_TEMPORARY_DATA_BUFFER_ENTRY_COUNT * BYTES_PER_DATA_REGION_OF_SLICE)
83
#define TEMPORARY_SPARE_DATA_BUFFER_BASE_ADDR \
84
(SPARE_DATA_BUFFER_BASE_ADDR + AVAILABLE_DATA_BUFFER_ENTRY_COUNT * BYTES_PER_SPARE_REGION_OF_SLICE)
85
#define RESERVED_DATA_BUFFER_BASE_ADDR \
86
(TEMPORARY_SPARE_DATA_BUFFER_BASE_ADDR + \
87
AVAILABLE_TEMPORARY_DATA_BUFFER_ENTRY_COUNT * BYTES_PER_SPARE_REGION_OF_SLICE)
88
// for nand request completion
89
#define COMPLETE_FLAG_TABLE_ADDR 0x17000000
90
#define STATUS_REPORT_TABLE_ADDR (COMPLETE_FLAG_TABLE_ADDR + sizeof(COMPLETE_FLAG_TABLE))
91
#define ERROR_INFO_TABLE_ADDR (STATUS_REPORT_TABLE_ADDR + sizeof(STATUS_REPORT_TABLE))
92
#define TEMPORARY_PAY_LOAD_ADDR (ERROR_INFO_TABLE_ADDR + sizeof(ERROR_INFO_TABLE))
93
// cached & buffered
94
// for buffers
95
#define DATA_BUFFER_MAP_ADDR 0x18000000
96
#define DATA_BUFFFER_HASH_TABLE_ADDR (DATA_BUFFER_MAP_ADDR + sizeof(DATA_BUF_MAP))
97
#define TEMPORARY_DATA_BUFFER_MAP_ADDR (DATA_BUFFFER_HASH_TABLE_ADDR + sizeof(DATA_BUF_HASH_TABLE))
98
// for map tables
99
#define LOGICAL_SLICE_MAP_ADDR (TEMPORARY_DATA_BUFFER_MAP_ADDR + sizeof(TEMPORARY_DATA_BUF_MAP))
100
#define VIRTUAL_SLICE_MAP_ADDR (LOGICAL_SLICE_MAP_ADDR + sizeof(LOGICAL_SLICE_MAP))
101
#define VIRTUAL_BLOCK_MAP_ADDR (VIRTUAL_SLICE_MAP_ADDR + sizeof(VIRTUAL_SLICE_MAP))
102
#define PHY_BLOCK_MAP_ADDR (VIRTUAL_BLOCK_MAP_ADDR + sizeof(VIRTUAL_BLOCK_MAP))
103
#define BAD_BLOCK_TABLE_INFO_MAP_ADDR (PHY_BLOCK_MAP_ADDR + sizeof(PHY_BLOCK_MAP))
104
#define VIRTUAL_DIE_MAP_ADDR (BAD_BLOCK_TABLE_INFO_MAP_ADDR + sizeof(BAD_BLOCK_TABLE_INFO_MAP))
105
// for GC victim selection
106
#define GC_VICTIM_MAP_ADDR (VIRTUAL_DIE_MAP_ADDR + sizeof(VIRTUAL_DIE_MAP))
107
108
// for request pool
109
#define REQ_POOL_ADDR (GC_VICTIM_MAP_ADDR + sizeof(GC_VICTIM_MAP))
110
// for dependency table
111
#define ROW_ADDR_DEPENDENCY_TABLE_ADDR (REQ_POOL_ADDR + sizeof(REQ_POOL))
112
// for request scheduler
113
#define DIE_STATE_TABLE_ADDR (ROW_ADDR_DEPENDENCY_TABLE_ADDR + sizeof(ROW_ADDR_DEPENDENCY_TABLE))
114
#define RETRY_LIMIT_TABLE_ADDR (DIE_STATE_TABLE_ADDR + sizeof(DIE_STATE_TABLE))
115
#define WAY_PRIORITY_TABLE_ADDR (RETRY_LIMIT_TABLE_ADDR + sizeof(RETRY_LIMIT_TABLE))
116
117
#define FTL_MANAGEMENT_END_ADDR ((WAY_PRIORITY_TABLE_ADDR + sizeof(WAY_PRIORITY_TABLE)) - 1)
118
119
#define RESERVED1_START_ADDR (FTL_MANAGEMENT_END_ADDR + 1)
120
#define RESERVED1_END_ADDR 0x3FFFFFFF
121
122
#define DRAM_END_ADDR 0x3FFFFFFF
123
124
#endif
/* MEMORY_MAP_H_ */
address_translation.h
data_buffer.h
garbage_collection.h
request_allocation.h
request_schedule.h
request_transform.h
Toshiba-8c8w
memory_map.h
Generated by
1.9.4