
# -*- python -*-

__id__ = "$Id: vci_cc_xcache_wrapper_v4.sd 188 2012-01-08 13:36:49Z alain $"
__version__ = "$Revision: 188 $"

Module('caba:vci_cc_xcache_wrapper_v4',
	classname = 'soclib::caba::VciCcXCacheWrapperV4',
	tmpl_parameters = [
		parameter.Module('vci_param', default = 'caba:vci_param'),
		parameter.Module('iss_t'),
		],
	header_files = [
		'../source/include/vci_cc_xcache_wrapper_v4.h',
		],
	implementation_files = [
		'../source/src/vci_cc_xcache_wrapper_v4.cpp',
		],
	uses = [
		Uses('caba:base_module'),
		Uses('common:mapping_table'),
		Uses('common:iss2'),
		Uses('caba:multi_write_buffer'),
		Uses('caba:generic_fifo'),
                Uses('caba:generic_cam'),
		Uses('caba:generic_cache', addr_t = 'uint32_t'),
		],
	ports = [
		Port('caba:vci_initiator', 'p_vci_ini_d'),
		Port('caba:vci_initiator', 'p_vci_ini_c'),
		Port('caba:vci_target', 'p_vci_tgt_c'),
		Port('caba:bit_in', 'p_irq', parameter.Constant('n_irq')),
		Port('caba:bit_in', 'p_resetn', auto = 'resetn'),
		Port('caba:clock_in', 'p_clk', auto = 'clock'),
		],
	instance_parameters = [
		parameter.Int('proc_id'),
		parameter.Module('mtd', 'common:mapping_table'),
		parameter.Module('mtc', 'common:mapping_table'),
		parameter.IntTab('initiator_index_d'),
		parameter.IntTab('initiator_index_c'),
		parameter.IntTab('target_index_c'),
		parameter.Int('icache_ways'),
		parameter.Int('icache_sets'),
		parameter.Int('icache_words'),
		parameter.Int('dcache_ways'),
		parameter.Int('dcache_sets'),
		parameter.Int('dcache_words'),
		parameter.Int('wbuf_nwords'),
		parameter.Int('wbuf_nlines'),
		parameter.Int('max_frozen_cycles'),
		],
	extensions = [
		'dsx:get_ident='
		'initiator_index_d:p_vci_ini_d:mtd,'
		'initiator_index_c:p_vci_ini_c:mtc'
		'target_index_c:p_vci_tgt_c:mtc',
		'dsx:cpu=wrapper:iss_t',
		'dsx:addressable=target_index_c',
		'dsx:on_segment=mtc:add_index:initiator_index_d',
		'dsx:mapping_type=processor:proc_id',
		],
)
