Drivers tcl changes

This commit is contained in:
Nava kishore Manne 2015-06-25 19:26:33 +05:30
parent a0d323d79d
commit f09612b531
60 changed files with 159 additions and 10479 deletions

View file

@ -56,26 +56,26 @@ proc xdefine_dma_include_file {drv_handle file_name drv_string args} {
set file_handle [xopen_include_file $file_name]
# Get all peripherals connected to this driver
set periphs [xget_sw_iplist_for_driver $drv_handle]
set periphs [xget_sw_iplist_for_driver $drv_handle]
# Handle special cases
set arg "NUM_INSTANCES"
set posn [lsearch -exact $args $arg]
if {$posn > -1} {
puts $file_handle "/* Definitions for driver [string toupper [common::get_property NAME $drv_handle]] */"
puts $file_handle "/* Definitions for driver [string toupper [get_property NAME $drv_handle]] */"
# Define NUM_INSTANCES
puts $file_handle "#define [xget_dname $drv_string $arg] [llength $periphs]"
set args [lreplace $args $posn $posn]
}
# Check if it is a driver parameter
lappend newargs
lappend newargs
foreach arg $args {
set value [common::get_property CONFIG.$arg $drv_handle]
set value [get_property CONFIG.$arg $drv_handle]
if {[llength $value] == 0} {
lappend newargs $arg
} else {
puts $file_handle "#define [xget_dname $drv_string $arg] [common::get_property CONFIG.$arg $drv_handle]"
puts $file_handle "#define [xget_dname $drv_string $arg] [get_property CONFIG.$arg $drv_handle]"
}
}
set args $newargs
@ -84,7 +84,7 @@ proc xdefine_dma_include_file {drv_handle file_name drv_string args} {
set device_id 0
foreach periph $periphs {
puts $file_handle ""
puts $file_handle "/* Definitions for peripheral [string toupper [common::get_property NAME $periph]] */"
puts $file_handle "/* Definitions for peripheral [string toupper [get_property NAME $periph]] */"
foreach arg $args {
if {[string compare -nocase "DEVICE_ID" $arg] == 0} {
set value $device_id
@ -92,7 +92,7 @@ proc xdefine_dma_include_file {drv_handle file_name drv_string args} {
} else {
set value [xget_param_value $periph $arg]
if {[string compare -nocase $arg "C_INCLUDE_SG"] == 0} {
if {[llength $value] == 0} {
if {[llength $value] == 0} {
set value 1
}
} else {
@ -101,7 +101,7 @@ proc xdefine_dma_include_file {drv_handle file_name drv_string args} {
}
}
if {[string compare -nocase $arg "C_MICRO_DMA"] == 0} {
if {[llength $value] == 0} {
if {[llength $value] == 0} {
set value 1
}
} else {
@ -119,7 +119,7 @@ proc xdefine_dma_include_file {drv_handle file_name drv_string args} {
}
}
puts $file_handle ""
}
}
puts $file_handle "\n/******************************************************************/\n"
close $file_handle
}
@ -138,7 +138,7 @@ proc xdefine_axidma_canonical_xpars {drv_handle file_name drv_string args} {
# Get the names of all the peripherals connected to this driver
foreach periph $periphs {
set peripheral_name [string toupper [common::get_property NAME $periph]]
set peripheral_name [string toupper [get_property NAME $periph]]
lappend peripherals $peripheral_name
}
@ -148,7 +148,7 @@ proc xdefine_axidma_canonical_xpars {drv_handle file_name drv_string args} {
foreach periph $periphs {
set canonical_name [string toupper [format "%s_%s" $drv_string $device_id]]
lappend canonicals $canonical_name
# Create a list of IDs of the peripherals whose hardware instance name
# doesn't match the canonical name. These IDs can be used later to
# generate canonical definitions
@ -160,7 +160,7 @@ proc xdefine_axidma_canonical_xpars {drv_handle file_name drv_string args} {
set i 0
foreach periph $periphs {
set periph_name [string toupper [common::get_property NAME $periph]]
set periph_name [string toupper [get_property NAME $periph]]
# Generate canonical definitions only for the peripherals whose
# canonical name is not the same as hardware instance name
@ -176,7 +176,7 @@ proc xdefine_axidma_canonical_xpars {drv_handle file_name drv_string args} {
set rvalue [xget_param_value $periph $arg]
if {[string compare -nocase $arg "C_INCLUDE_SG"] == 0} {
if {[llength $rvalue] == 0} {
if {[llength $rvalue] == 0} {
set rvalue 1
}
} else {
@ -185,7 +185,7 @@ proc xdefine_axidma_canonical_xpars {drv_handle file_name drv_string args} {
}
}
if {[string compare -nocase $arg "C_MICRO_DMA"] == 0} {
if {[llength $rvalue] == 0} {
if {[llength $rvalue] == 0} {
set rvalue 1
}
} else {
@ -194,7 +194,7 @@ proc xdefine_axidma_canonical_xpars {drv_handle file_name drv_string args} {
}
}
set rvalue [xformat_addr_string $rvalue $arg]
puts $file_handle "#define $lvalue $rvalue"
}

View file

@ -43,6 +43,8 @@
# properly (CR 810643)
# 29/10/14 adk Added support for generating parameters for SGMII/1000BaseX modes
# When IP is configured with the PCS/PMA core (CR 828796)
# 8/1/15 adk Fixed TCL errors when axiethernet is configured with the
# Axi stream fifo (CR 835605).
#
###############################################################################
#uses "xillib.tcl"
@ -102,7 +104,7 @@ proc xdefine_axiethernet_include_file {drv_handle file_name drv_string} {
# Handle NUM_INSTANCES
set periph_ninstances 0
puts $file_handle "/* Definitions for driver [string toupper [common::get_property NAME $drv_handle]] */"
puts $file_handle "/* Definitions for driver [string toupper [get_property NAME $drv_handle]] */"
foreach periph $periphs {
init_periph_config_struct $periph_ninstances
incr periph_ninstances 1
@ -179,9 +181,9 @@ proc xdefine_axi_target_params {periphs file_handle} {
# Get unique list of p2p peripherals
foreach periph $periphs {
set p2p_periphs [list]
set periph_name [string toupper [common::get_property NAME $periph]]
set periph_name [string toupper [get_property NAME $periph]]
# Get all point2point buses for periph
set p2p_busifs_i [hsi::get_intf_pins -of_objects $periph -filter "TYPE==INITIATOR"]
set p2p_busifs_i [get_intf_pins -of_objects $periph -filter "TYPE==INITIATOR"]
puts $file_handle ""
puts $file_handle "/* Canonical Axi parameters for $periph_name */"
@ -189,21 +191,21 @@ proc xdefine_axi_target_params {periphs file_handle} {
# Add p2p periphs
foreach p2p_busif $p2p_busifs_i {
set busif_name [string toupper [common::get_property NAME $p2p_busif]]
set busif_name [string toupper [get_property NAME $p2p_busif]]
set conn_busif_handle [::hsi::utils::get_connected_intf $periph $busif_name]
if { [string compare -nocase $conn_busif_handle ""] == 0} {
continue
} else {
# if there is a single match, we know if it is FIFO or DMA
# no need for further iterations
set conn_busif_name [common::get_property NAME $conn_busif_handle]
set target_periph [hsi::get_cells -of_objects $conn_busif_handle]
set target_periph_type [common::get_property IP_NAME $target_periph]
set conn_busif_name [get_property NAME $conn_busif_handle]
set target_periph [get_cells -of_objects $conn_busif_handle]
set target_periph_type [get_property IP_NAME $target_periph]
if { [string compare -nocase $target_periph_type "tri_mode_ethernet_mac"] == 0 } {
continue
}
set tartget_per_name [common::get_property NAME $target_periph]
set target_periph_name [string toupper [common::get_property NAME $target_periph]]
set tartget_per_name [get_property NAME $target_periph]
set target_periph_name [string toupper [get_property NAME $target_periph]]
set canonical_tag [string toupper [format "AXIETHERNET_%d" $device_id ]]
set validentry 1
break
@ -218,16 +220,16 @@ proc xdefine_axi_target_params {periphs file_handle} {
puts $file_handle "#define $canonical_name XPAR_AXI_FIFO"
add_field_to_periph_config_struct $device_id $canonical_name
set axi_fifo_baseaddr [common::get_property CONFIG.C_BASEADDR $target_periph]
set axi_fifo_baseaddr [get_property CONFIG.C_BASEADDR $target_periph]
set canonical_name [format "XPAR_%s_CONNECTED_BASEADDR" $canonical_tag]
puts $file_handle [format "#define $canonical_name %s" $axi_fifo_baseaddr]
add_field_to_periph_config_struct $device_id $canonical_name
# FIFO Interrupts Handling
set int_pin [hsi::get_pins -of_objects [hsi::get_cells $tartget_per_name] INTERRUPT]
set int_pin [get_pins -of_objects [get_cells $tartget_per_name] INTERRUPT]
set intc_periph_type [::hsi::utils::get_connected_intr_cntrl $tartget_per_name $int_pin]
set intc_name [common::get_property IP_NAME $intc_periph_type]
set intc_name [get_property IP_NAME $intc_periph_type]
if { $intc_name != [format "ps7_scugic"] } {
set int_id [::hsi::utils::get_port_intr_id [hsi::get_cells $tartget_per_name] $int_pin]
set int_id [::hsi::utils::get_port_intr_id [get_cells $tartget_per_name] $int_pin]
set canonical_name [format "XPAR_%s_CONNECTED_FIFO_INTR" $canonical_tag]
puts $file_handle [format "#define $canonical_name %d" $int_id]
add_field_to_periph_config_struct $device_id $canonical_name
@ -237,9 +239,9 @@ proc xdefine_axi_target_params {periphs file_handle} {
add_field_to_periph_config_struct $device_id 0xFF
} else {
set canonical_name [format "XPAR_%s_CONNECTED_FIFO_INTR" $canonical_tag]
set target_periph_name [string toupper [common::get_property NAME $target_periph_type]]
puts $file_handle [format "#define $canonical_name XPAR_FABRIC_%s_S2MM_INTROUT_INTR" $target_periph_name]
add_field_to_periph_config_struct $deviceid $canonical_name
set temp [string toupper $int_pin]
puts $file_handle [format "#define $canonical_name XPAR_FABRIC_%s_%s_INTR" $target_periph_name $temp]
add_field_to_periph_config_struct $device_id $canonical_name
puts $file_handle [format "#define XPAR_%s_CONNECTED_DMARX_INTR 0xFF" $canonical_tag]
puts $file_handle [format "#define XPAR_%s_CONNECTED_DMATX_INTR 0xFF" $canonical_tag]
add_field_to_periph_config_struct $device_id 0xFF
@ -247,7 +249,7 @@ proc xdefine_axi_target_params {periphs file_handle} {
}
}
if {$target_periph_type == "axi_dma"} {
set axi_dma_baseaddr [common::get_property CONFIG.C_BASEADDR $target_periph]
set axi_dma_baseaddr [get_property CONFIG.C_BASEADDR $target_periph]
# Handle base address and connection type
set canonical_name [format "XPAR_%s_CONNECTED_TYPE" $canonical_tag]
puts $file_handle "#define $canonical_name XPAR_AXI_DMA"
@ -279,7 +281,7 @@ proc xdefine_axi_target_params {periphs file_handle} {
# ------------------------------------------------------------------
proc xdefine_temac_params_canonical {file_handle periph device_id} {
puts $file_handle "\n/* Canonical definitions for peripheral [string toupper [common::get_property NAME $periph]] */"
puts $file_handle "\n/* Canonical definitions for peripheral [string toupper [get_property NAME $periph]] */"
set canonical_tag [string toupper [format "XPAR_AXIETHERNET_%d" $device_id]]
@ -459,10 +461,10 @@ proc xdefine_axiethernet_config_file {file_name drv_string} {
# ------------------------------------------------------------------
proc xdefine_dma_interrupts {file_handle target_periph deviceid canonical_tag dmarx_signal dmatx_signal} {
set target_periph_name [string toupper [common::get_property NAME $target_periph]]
set target_periph_name [string toupper [get_property NAME $target_periph]]
# First get the interrupt ports on this AXI peripheral
set interrupt_port [hsi::get_pins -of_objects $target_periph -filter {TYPE==INTERRUPT&&DIRECTION==O}]
set interrupt_port [get_pins -of_objects $target_periph -filter {TYPE==INTERRUPT&&DIRECTION==O}]
if {$interrupt_port == ""} {
puts "Info: There are no AXIDMA Interrupt ports"
puts $file_handle [format "#define XPAR_%s_CONNECTED_DMARX_INTR 0xFF" $canonical_tag]
@ -477,8 +479,8 @@ proc xdefine_dma_interrupts {file_handle target_periph deviceid canonical_tag dm
set dmarx "null"
set dmatx "null"
foreach intr_port $interrupt_port {
set interrupt_signal_name [common::get_property NAME $intr_port]
set intc_port [hsi::get_pins -of_objects $target_periph -filter {TYPE==INTERRUPT&&DIRECTION==O}]
set interrupt_signal_name [get_property NAME $intr_port]
set intc_port [get_pins -of_objects $target_periph -filter {TYPE==INTERRUPT&&DIRECTION==O}]
# Make sure the interrupt signal was connected in this design. We assume
# at least one is. (could be a bug if user just wants polled mode)
@ -487,7 +489,7 @@ proc xdefine_dma_interrupts {file_handle target_periph deviceid canonical_tag dm
foreach intr_sink $intc_port {
set pname_type [::hsi::utils::get_connected_intr_cntrl $target_periph $intr_sink]
if {$pname_type != "chipscope_ila"} {
set special [common::get_property IP_TYPE $pname_type]
set special [get_property IP_TYPE $pname_type]
if {[string compare -nocase $special "INTERRUPT_CNTLR"] == 0} {
set found_intc $intr_sink
}
@ -503,9 +505,9 @@ proc xdefine_dma_interrupts {file_handle target_periph deviceid canonical_tag dm
add_field_to_periph_config_struct $deviceid 0xFF
return
}
set intc_periph [hsi::get_cells -of_objects $found_intc]
set intc_periph_type [common::get_property IP_NAME $pname_type]
set intc_name [string toupper [common::get_property NAME $pname_type]]
set intc_periph [get_cells -of_objects $found_intc]
set intc_periph_type [get_property IP_NAME $pname_type]
set intc_name [string toupper [get_property NAME $pname_type]]
} else {
puts "Info: $target_periph_name interrupt signal $interrupt_signal_name not connected"
continue
@ -555,7 +557,7 @@ proc xdefine_dma_interrupts {file_handle target_periph deviceid canonical_tag dm
proc xdefine_temac_interrupt {file_handle periph device_id} {
#set mhs_handle [xget_hw_parent_handle $periph]
set periph_name [string toupper [common::get_property NAME $periph]]
set periph_name [string toupper [get_property NAME $periph]]
# set up the canonical constant name
set canonical_name [format "XPAR_AXIETHERNET_%d_INTR" $device_id]
@ -565,7 +567,7 @@ proc xdefine_temac_interrupt {file_handle periph device_id} {
# for the interrupt ID based on the interrupt signal name of the TEMAC
#
# First get the interrupt ports on this peripheral
set interrupt_port [hsi::get_pins -of_objects $periph -filter {TYPE==INTERRUPT&&DIRECTION==O}]
set interrupt_port [get_pins -of_objects $periph -filter {TYPE==INTERRUPT&&DIRECTION==O}]
if {$interrupt_port == ""} {
puts "Info: There are no AXI Ethernet Interrupt ports"
# No interrupts were connected, so add dummy entry to the config structure
@ -576,19 +578,19 @@ proc xdefine_temac_interrupt {file_handle periph device_id} {
# For each interrupt port, find out the ordinal of the interrupt line
# as connected to an interrupt controller
set addentry 0
set interrupt_signal_name [common::get_property NAME $interrupt_port]
set interrupt_signal_name [get_property NAME $interrupt_port]
#set interrupt_signal [xget_hw_value $interrupt_port]
set intc_prt [::hsi::utils::get_sink_pins [hsi::get_pins -of_objects [hsi::get_cells $periph] INTERRUPT]]
set intc_prt [::hsi::utils::get_sink_pins [get_pins -of_objects [get_cells $periph] INTERRUPT]]
# Make sure the interrupt signal was connected in this design. We assume
# at least one is. (could be a bug if user just wants polled mode)
if { $intc_prt != "" } {
set found_intc ""
foreach intr_sink $intc_prt {
set phandle [hsi::get_cells -of_objects $intr_sink]
set pname_type [common::get_property NAME $phandle]
set phandle [get_cells -of_objects $intr_sink]
set pname_type [get_property NAME $phandle]
if {$pname_type != "chipscope_ila"} {
set special [common::get_property IP_TYPE [hsi::get_cells $pname_type]]
set special [get_property IP_TYPE [get_cells $pname_type]]
if {[string compare -nocase $special "INTERRUPT_CNTLR"] == 0} {
set found_intc $intr_sink
break
@ -604,9 +606,9 @@ proc xdefine_temac_interrupt {file_handle periph device_id} {
return
}
set intc_periph [hsi::get_cells -of_objects $found_intc]
set intc_periph_type [common::get_property IP_NAME $intc_periph]
set intc_name [string toupper [common::get_property NAME $intc_periph]]
set intc_periph [get_cells -of_objects $found_intc]
set intc_periph_type [get_property IP_NAME $intc_periph]
set intc_name [string toupper [get_property NAME $intc_periph]]
} else {
puts "Info: $periph_name interrupt signal $interrupt_signal_name not connected"
# No interrupts were connected, so add dummy entry to the config structure
@ -620,7 +622,7 @@ proc xdefine_temac_interrupt {file_handle periph device_id} {
# matches the original interrupt signal we were tracking.
if { $intc_periph_type != [format "ps7_scugic"] } {
set ethernet_int_signal_name [hsi::get_pins -of_objects $periph INTERRUPT]
set ethernet_int_signal_name [get_pins -of_objects $periph INTERRUPT]
set int_id [::hsi::utils::get_port_intr_id $periph $ethernet_int_signal_name]
puts $file_handle "\#define $canonical_name $int_id"
add_field_to_periph_config_struct $device_id $canonical_name
@ -640,17 +642,17 @@ proc xdefine_temac_interrupt {file_handle periph device_id} {
proc generate_sgmii_params {drv_handle file_name} {
set file_handle [::hsi::utils::open_include_file $file_name]
set ips [hsi::get_cells "*"]
set ips [get_cells "*"]
foreach ip $ips {
set periph [common::get_property IP_NAME $ip]
set periph [get_property IP_NAME $ip]
if { [string compare -nocase $periph "gig_ethernet_pcs_pma"] == 0} {
set PhyStandard [common::get_property CONFIG.Standard $ip]
set PhyStandard [get_property CONFIG.Standard $ip]
}
}
foreach ip $ips {
set periph [common::get_property IP_NAME $ip]
set periph [get_property IP_NAME $ip]
if { [string compare -nocase $periph "axi_ethernet_buffer"] == 0} {
set phya [is_gige_pcs_pma_ip_present $ip]
if { $phya == 0} {
@ -679,14 +681,14 @@ proc is_gige_pcs_pma_ip_present {slave} {
set phy_addr 0
set ipconv 0
set ips [hsi::get_cells "*"]
set enetipinstance_name [common::get_property IP_NAME $slave]
set ips [get_cells "*"]
set enetipinstance_name [get_property IP_NAME $slave]
foreach ip $ips {
set periph [common::get_property IP_NAME $ip]
set periph [get_property IP_NAME $ip]
if { [string compare -nocase $periph "gig_ethernet_pcs_pma"] == 0} {
set sgmii_param [common::get_property CONFIG.c_is_sgmii $ip]
set PhyStandarrd [common::get_property CONFIG.Standard $ip]
set sgmii_param [get_property CONFIG.c_is_sgmii $ip]
set PhyStandarrd [get_property CONFIG.Standard $ip]
if {$sgmii_param == true || $PhyStandarrd == "1000BASEX"} {
set ipconv $ip
}
@ -695,7 +697,7 @@ proc is_gige_pcs_pma_ip_present {slave} {
}
if { $ipconv != 0 } {
set port_value [hsi::get_pins -of_objects [hsi::get_nets -of_objects [hsi::get_pins -of_objects $ipconv gmii_txd]]]
set port_value [get_pins -of_objects [get_nets -of_objects [get_pins -of_objects $ipconv gmii_txd]]]
if { $port_value != 0 } {
if { [string compare -nocase $enetipinstance_name "axi_ethernet_buffer"] == 0} {
set phyaddr [::hsi::utils::get_param_value $ipconv C_PHYADDR]

View file

@ -117,7 +117,7 @@ proc gen_init_code {swproj mhsinst} {
}
if {$swproj == 1} {
set ipname [common::get_property NAME $mhsinst]
set ipname [get_property NAME $mhsinst]
set ifintr [::hsi::utils::is_ip_interrupting_current_proc $mhsinst]
if {$ifintr == 1} {
@ -157,9 +157,9 @@ proc gen_testfunc_call {swproj mhsinst} {
return ""
}
set ipname [common::get_property NAME $mhsinst]
set ipname [get_property NAME $mhsinst]
set deviceid [::hsi::utils::get_ip_param_name $mhsinst "DEVICE_ID"]
set stdout [common::get_property CONFIG.STDOUT [hsi::get_os]]
set stdout [get_property CONFIG.STDOUT [get_os]]
if { $stdout == "" || $stdout == "none" } {
set hasStdout 0
} else {
@ -175,10 +175,10 @@ proc gen_testfunc_call {swproj mhsinst} {
set dma_ipname [get_dma_info $mhsinst "name"]
if {$ifintr == 1} {
set intr_pin_name [hsi::get_pins -of_objects [hsi::get_cells $ipname] INTERRUPT]
set intr_pin_name [get_pins -of_objects [get_cells $ipname] INTERRUPT]
set intcname [::hsi::utils::get_connected_intr_cntrl $ipname $intr_pin_name]
set intcvar intc
set proc [common::get_property IP_NAME [hsi::get_cells [hsi::get_sw_processor]]]
set proc [get_property IP_NAME [get_cells [get_sw_processor]]]
}
@ -350,11 +350,11 @@ proc gen_testfunc_call {swproj mhsinst} {
proc get_fifo_info {mhsHandle type} {
set ipinst_list [hsi::get_cells $mhsHandle "*"]
set ipinst_list [get_cells $mhsHandle "*"]
foreach ipinst $ipinst_list {
set coreName [common::get_property IP_NAME $ipinst]
set instName [common::get_property NAME $ipinst]
set coreName [get_property IP_NAME $ipinst]
set instName [get_property NAME $ipinst]
if {[string compare -nocase $coreName "axi_fifo_mm_s"] == 0} {
@ -370,26 +370,26 @@ proc get_fifo_info {mhsHandle type} {
}
proc get_dma_info {mhsinst type} {
set ipinst_list [hsi::get_cells $mhsinst "*"]
set ipinst_list [get_cells $mhsinst "*"]
set p2p_busifs_i [hsi::get_intf_pins -of_objects $mhsinst -filter "TYPE==INITIATOR"]
set p2p_busifs_i [get_intf_pins -of_objects $mhsinst -filter "TYPE==INITIATOR"]
# Add p2p periphs
foreach p2p_busif $p2p_busifs_i {
set busif_name [string toupper [common::get_property NAME $p2p_busif]]
set busif_name [string toupper [get_property NAME $p2p_busif]]
set conn_busif_handle [::hsi::utils::get_connected_intf $mhsinst $busif_name]
if { [string compare -nocase $conn_busif_handle ""] == 0} {
continue
} else {
# if there is a single match, we know if it is FIFO or DMA
# no need for further iterations
set conn_busif_name [common::get_property NAME $conn_busif_handle]
set target_periph [hsi::get_cells -of_objects $conn_busif_handle]
set target_periph_type [common::get_property IP_NAME $target_periph]
set conn_busif_name [get_property NAME $conn_busif_handle]
set target_periph [get_cells -of_objects $conn_busif_handle]
set target_periph_type [get_property IP_NAME $target_periph]
if { [string compare -nocase $target_periph_type "tri_mode_ethernet_mac"] == 0 } {
continue
}
set target_periph_name [string toupper [common::get_property NAME $target_periph]]
set instName [common::get_property NAME $target_periph]
set target_periph_name [string toupper [get_property NAME $target_periph]]
set instName [get_property NAME $target_periph]
if {[string compare -nocase $target_periph_type "axi_dma"] == 0} {
if {[string compare -nocase $type "id"] == 0} {
set deviceid [::hsi::utils::get_ip_param_name $target_periph "DEVICE_ID"]

View file

@ -46,7 +46,7 @@
# 4.05a srt 05/01/3 Merged v4.03a driver with v4.04a driver.
# Driver v4.03a - Supports VDMA IPv5.04a XPS release
# Driver v4.04a - Supports VDMA IPv6.00a IPI release
# The parameters C_ENABLE_DEBUG_* are only available in
# The parameters C_ENABLE_DEBUG_* are only available in
# VDMA IPv6.00a. These parameters should be set to '1'
# for older versions of IP (XPS) and added this logic in
# this file.
@ -76,7 +76,7 @@ proc xdefine_vdma_include_file {drv_handle file_name drv_string args} {
set arg "NUM_INSTANCES"
set posn [lsearch -exact $args $arg]
if {$posn > -1} {
puts $file_handle "/* Definitions for driver [string toupper [common::get_property NAME $drv_handle]] */"
puts $file_handle "/* Definitions for driver [string toupper [get_property NAME $drv_handle]] */"
# Define NUM_INSTANCES
puts $file_handle "#define [hsi::utils::get_driver_param_name $drv_string $arg] [llength $periphs]"
set args [lreplace $args $posn $posn]
@ -85,11 +85,11 @@ proc xdefine_vdma_include_file {drv_handle file_name drv_string args} {
lappend newargs
foreach arg $args {
set value [common::get_property CONFIG.$arg $drv_handle]
set value [get_property CONFIG.$arg $drv_handle]
if {[llength $value] == 0} {
lappend newargs $arg
} else {
puts $file_handle "#define [hsi::utils::get_driver_param_name $drv_string $arg] [common::get_property CONFIG.$arg $drv_handle]"
puts $file_handle "#define [hsi::utils::get_driver_param_name $drv_string $arg] [get_property CONFIG.$arg $drv_handle]"
}
}
set args $newargs
@ -98,7 +98,7 @@ proc xdefine_vdma_include_file {drv_handle file_name drv_string args} {
set device_id 0
foreach periph $periphs {
puts $file_handle ""
puts $file_handle "/* Definitions for peripheral [string toupper [common::get_property NAME $periph]] */"
puts $file_handle "/* Definitions for peripheral [string toupper [get_property NAME $periph]] */"
foreach arg $args {
if {[string compare -nocase "DEVICE_ID" $arg] == 0} {
set value $device_id
@ -110,11 +110,11 @@ proc xdefine_vdma_include_file {drv_handle file_name drv_string args} {
set value 0
}
# Check for *_ENABLE_DEBUG_* parameters. These parameters are applicable
# to VDMA IPv6.00a (IPI release). For all the previous versions these
# to VDMA IPv6.00a (IPI release). For all the previous versions these
# parameters should be set.
if {[string first "ENABLE_DEBUG" $arg] >= 0} {
set foundparam [::hsi::utils::get_param_value $periph $arg]
if {[llength $foundparam] == 0} {
if {[llength $foundparam] == 0} {
set value 1
}
}
@ -140,7 +140,7 @@ proc xdefine_vdma_canonical_xpars {drv_handle file_name drv_string args} {
# Get the names of all the peripherals connected to this driver
foreach periph $periphs {
set peripheral_name [string toupper [common::get_property NAME $periph]]
set peripheral_name [string toupper [get_property NAME $periph]]
lappend peripherals $peripheral_name
}
@ -162,7 +162,7 @@ proc xdefine_vdma_canonical_xpars {drv_handle file_name drv_string args} {
set i 0
foreach periph $periphs {
set periph_name [string toupper [common::get_property NAME $periph]]
set periph_name [string toupper [get_property NAME $periph]]
# Generate canonical definitions only for the peripherals whose
# canonical name is not the same as hardware instance name
@ -181,11 +181,11 @@ proc xdefine_vdma_canonical_xpars {drv_handle file_name drv_string args} {
set rvalue 0
}
# Check for *_ENABLE_DEBUG_* parameters. These parameters are applicable
# to VDMA IPv6.00a (IPI release). For all the previous versions these
# to VDMA IPv6.00a (IPI release). For all the previous versions these
# parameters should be set.
if {[string first "ENABLE_DEBUG" $arg] >= 0} {
set foundparam [::hsi::utils::get_param_value $periph $arg]
if {[llength $foundparam] == 0} {
if {[llength $foundparam] == 0} {
set rvalue 1
}
}

View file

@ -1,53 +0,0 @@
/* xtag_csp_common_v1_00_a.c - Xilinx driver inclusion file */
/*
XILINX IS PROVIDING THIS DESIGN, CODE, OR INFORMATION "AS IS"
AS A COURTESY TO YOU, SOLELY FOR USE IN DEVELOPING PROGRAMS AND
SOLUTIONS FOR XILINX DEVICES. BY PROVIDING THIS DESIGN, CODE,
OR INFORMATION AS ONE POSSIBLE IMPLEMENTATION OF THIS FEATURE,
APPLICATION OR STANDARD, XILINX IS MAKING NO REPRESENTATION
THAT THIS IMPLEMENTATION IS FREE FROM ANY CLAIMS OF INFRINGEMENT,
AND YOU ARE RESPONSIBLE FOR OBTAINING ANY RIGHTS YOU MAY REQUIRE
FOR YOUR IMPLEMENTATION. XILINX EXPRESSLY DISCLAIMS ANY
WARRANTY WHATSOEVER WITH RESPECT TO THE ADEQUACY OF THE
IMPLEMENTATION, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OR
REPRESENTATIONS THAT THIS IMPLEMENTATION IS FREE FROM CLAIMS OF
INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
FOR A PARTICULAR PURPOSE.
(c) Copyright 2002 Xilinx Inc.
All rights reserved.
*/
/*
modification history
--------------------
01a,02apr02,rmm First release.
*/
/*
DESCRIPTION
This file is used to compile the common component of the Xilinx Chip Support
Package (CSP).
INCLUDE FILES:
SEE ALSO:
*/
#include "vxWorks.h"
#include "config.h"
#ifdef INCLUDE_XCOMMON
# include "xbasic_types.c"
# include "xversion.c"
#endif

View file

@ -1,40 +0,0 @@
###############################################################################
#
# Copyright (C) 2004 - 2014 Xilinx, Inc. All rights reserved.
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in
# all copies or substantial portions of the Software.
#
# Use of the Software is limited solely to applications:
# (a) running on a Xilinx device, or
# (b) that interact with a Xilinx device through a bus or interconnect.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
# XILINX BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
# WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
# OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.
#
# Except as contained in this notice, the name of the Xilinx shall not be used
# in advertising or otherwise to promote the sale, use or other dealings in
# this Software without prior written authorization from Xilinx.
#
###############################################################################
OPTION psf_version = 2.1;
BEGIN driver common
OPTION NAME = common;
OPTION supported_peripherals = ();
END driver

View file

@ -1,32 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: Data Structures
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li id="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li id="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
</ul></div>
<h1>Xilinx Driver common v1_00_a Data Structures</h1>Here are the data structures with brief descriptions:<table>
<tr><td class="indexkey"><a class="el" href="struct_x_e_n_v___t_i_m_e___s_t_a_m_p.html">XENV_TIME_STAMP</a></td><td class="indexvalue"></td></tr>
</table>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,45 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: File Index
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li id="current"><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<h1>Xilinx Driver common v1_00_a File List</h1>Here is a list of all documented files with brief descriptions:<table>
<tr><td class="indexkey"><a class="el" href="xbasic__types_8c.html">xbasic_types.c</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="xbasic__types_8h.html">xbasic_types.h</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="xenv_8h.html">xenv.h</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="xenv__linux_8h.html">xenv_linux.h</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="xenv__none_8h.html">xenv_none.h</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="xenv__standalone_8h.html">xenv_standalone.h</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="xenv__vxworks_8h.html">xenv_vxworks.h</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="xparameters_8h.html">xparameters.h</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="xstatus_8h.html">xstatus.h</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="xutil_8h.html">xutil.h</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="xutil__memtest_8c.html">xutil_memtest.c</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="xversion_8c.html">xversion.c</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="xversion_8h.html">xversion.h</a></td><td class="indexvalue"></td></tr>
</table>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,93 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: Data Fields
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li id="current"><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li id="current"><a href="globals.html"><span>All</span></a></li>
<li><a href="globals_func.html"><span>Functions</span></a></li>
<li><a href="globals_vars.html"><span>Variables</span></a></li>
<li><a href="globals_type.html"><span>Typedefs</span></a></li>
<li><a href="globals_defs.html"><span>Defines</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="#index_x"><span>x</span></a></li>
</ul>
</div>
<p>
Here is a list of all documented functions, variables, defines, enums, and typedefs with links to the documentation:
<p>
<h3><a class="anchor" name="index_x">- x -</a></h3><ul>
<li>XAssert()
: <a class="el" href="xbasic__types_8h.html#1f67a1ee7cf8cc0958f6d4d3c2936c5f">xbasic_types.h</a>, <a class="el" href="xbasic__types_8c.html#acbb4519b91c8f880f32b039ede107b2">xbasic_types.c</a><li>XASSERT_NONVOID
: <a class="el" href="xbasic__types_8h.html#b3a5c2bd864ed0dd4578c3adcd4d8d65">xbasic_types.h</a><li>XASSERT_NONVOID_ALWAYS
: <a class="el" href="xbasic__types_8h.html#a17eb37a9efa42a855596455d8071c15">xbasic_types.h</a><li>XASSERT_VOID
: <a class="el" href="xbasic__types_8h.html#7765783631e6609472f5674e47ece3c5">xbasic_types.h</a><li>XASSERT_VOID_ALWAYS
: <a class="el" href="xbasic__types_8h.html#8e42b9a913b0695a55388d039af80550">xbasic_types.h</a><li>XAssertCallback
: <a class="el" href="xbasic__types_8h.html#1f5b744ce282b4f67cf6eccf348bcf94">xbasic_types.h</a><li>XAssertSetCallback()
: <a class="el" href="xbasic__types_8h.html#2b2df8e50ec26df3ecb901bdd8599ed6">xbasic_types.h</a>, <a class="el" href="xbasic__types_8c.html#2b2df8e50ec26df3ecb901bdd8599ed6">xbasic_types.c</a><li>XAssertStatus
: <a class="el" href="xbasic__types_8h.html#d9dbab8a843c44e98c8c9b96d2849432">xbasic_types.h</a>, <a class="el" href="xbasic__types_8c.html#d9dbab8a843c44e98c8c9b96d2849432">xbasic_types.c</a><li>Xboolean
: <a class="el" href="xbasic__types_8h.html#c229a98d42331dd3035340b4dffa7c30">xbasic_types.h</a><li>XCOMPONENT_IS_READY
: <a class="el" href="xbasic__types_8h.html#ce7cba48175b32d6a97a24c95e2d5dc1">xbasic_types.h</a><li>XCOMPONENT_IS_STARTED
: <a class="el" href="xbasic__types_8h.html#14425162dda5c83496fac101f3ac3b39">xbasic_types.h</a><li>XENV_MEM_COPY
: <a class="el" href="xenv__vxworks_8h.html#aa4d213e22a5ede5b7099ab34ff79d38">xenv_vxworks.h</a>, <a class="el" href="xenv__standalone_8h.html#aa4d213e22a5ede5b7099ab34ff79d38">xenv_standalone.h</a>, <a class="el" href="xenv__linux_8h.html#aa4d213e22a5ede5b7099ab34ff79d38">xenv_linux.h</a><li>XENV_MEM_FILL
: <a class="el" href="xenv__vxworks_8h.html#0d8dfe452111356b4703424441ae8101">xenv_vxworks.h</a>, <a class="el" href="xenv__standalone_8h.html#0d8dfe452111356b4703424441ae8101">xenv_standalone.h</a>, <a class="el" href="xenv__linux_8h.html#0d8dfe452111356b4703424441ae8101">xenv_linux.h</a><li>XENV_TIME_STAMP
: <a class="el" href="xenv__standalone_8h.html#e6b941709f64b60384a60ebd4cb12957">xenv_standalone.h</a>, <a class="el" href="xenv__linux_8h.html#e6b941709f64b60384a60ebd4cb12957">xenv_linux.h</a><li>XENV_TIME_STAMP_DELTA_MS
: <a class="el" href="xenv__vxworks_8h.html#fd056d3e6807f31827018bd78df00b53">xenv_vxworks.h</a>, <a class="el" href="xenv__standalone_8h.html#fd056d3e6807f31827018bd78df00b53">xenv_standalone.h</a>, <a class="el" href="xenv__linux_8h.html#fd056d3e6807f31827018bd78df00b53">xenv_linux.h</a><li>XENV_TIME_STAMP_DELTA_US
: <a class="el" href="xenv__vxworks_8h.html#1a080520bc88e99f438a03a7fee6a061">xenv_vxworks.h</a>, <a class="el" href="xenv__standalone_8h.html#1a080520bc88e99f438a03a7fee6a061">xenv_standalone.h</a>, <a class="el" href="xenv__linux_8h.html#1a080520bc88e99f438a03a7fee6a061">xenv_linux.h</a><li>XENV_TIME_STAMP_GET
: <a class="el" href="xenv__vxworks_8h.html#b29cb639eed7d2baf1a3d87744260df1">xenv_vxworks.h</a>, <a class="el" href="xenv__standalone_8h.html#b29cb639eed7d2baf1a3d87744260df1">xenv_standalone.h</a>, <a class="el" href="xenv__linux_8h.html#b29cb639eed7d2baf1a3d87744260df1">xenv_linux.h</a><li>XENV_USLEEP
: <a class="el" href="xenv__vxworks_8h.html#b5bf353013ce12567b705a2123efd198">xenv_vxworks.h</a>, <a class="el" href="xenv__standalone_8h.html#b5bf353013ce12567b705a2123efd198">xenv_standalone.h</a>, <a class="el" href="xenv__linux_8h.html#b5bf353013ce12567b705a2123efd198">xenv_linux.h</a><li>XExceptionHandler
: <a class="el" href="xbasic__types_8h.html#cfa2257db2a92b2c2ca5d01a8b2cdba5">xbasic_types.h</a><li>Xfloat32
: <a class="el" href="xbasic__types_8h.html#78377cf4c372772008826fef885d0877">xbasic_types.h</a><li>Xfloat64
: <a class="el" href="xbasic__types_8h.html#4ae97cf4631e3eb9568636635b1acae0">xbasic_types.h</a><li>Xint16
: <a class="el" href="xbasic__types_8h.html#af1b2a7c8a73b7c812a37be0c34703e1">xbasic_types.h</a><li>Xint32
: <a class="el" href="xbasic__types_8h.html#0d57781a20d39780c62a2dc799f42483">xbasic_types.h</a><li>Xint8
: <a class="el" href="xbasic__types_8h.html#2545b71497eceff3c9baaca5c775249d">xbasic_types.h</a><li>XInterruptHandler
: <a class="el" href="xbasic__types_8h.html#c832ba88139f2bdb785df8ce07c0a510">xbasic_types.h</a><li>XNULL
: <a class="el" href="xbasic__types_8h.html#6993225d9cad2fca07266780ebb30f82">xbasic_types.h</a><li>XNullHandler()
: <a class="el" href="xbasic__types_8h.html#875c7885b68c71912fb32c4690063504">xbasic_types.h</a>, <a class="el" href="xbasic__types_8c.html#875c7885b68c71912fb32c4690063504">xbasic_types.c</a><li>Xuint16
: <a class="el" href="xbasic__types_8h.html#444b60b25c332c45da7262f20e7c3d93">xbasic_types.h</a><li>Xuint32
: <a class="el" href="xbasic__types_8h.html#f08247645ba692e675a481f42599730c">xbasic_types.h</a><li>XUINT64_LSW
: <a class="el" href="xbasic__types_8h.html#7af2620485199c26302dadd0b8173e48">xbasic_types.h</a><li>XUINT64_MSW
: <a class="el" href="xbasic__types_8h.html#6a2811b888a5d84ac350e6d3dfd09f10">xbasic_types.h</a><li>Xuint8
: <a class="el" href="xbasic__types_8h.html#ff6fcfd0df5ba1eef8a88eb7779898d7">xbasic_types.h</a><li>XUT_ALLMEMTESTS
: <a class="el" href="xutil_8h.html#611891b0e5c78d9849169a8ed9b37457">xutil.h</a><li>XUtil_MemoryTest16()
: <a class="el" href="xutil__memtest_8c.html#3fa3b8c52b52a5d3bde1830f15d4242b">xutil_memtest.c</a>, <a class="el" href="xutil_8h.html#3fa3b8c52b52a5d3bde1830f15d4242b">xutil.h</a><li>XUtil_MemoryTest32()
: <a class="el" href="xutil__memtest_8c.html#100d836b52f019cb2778dde05b8d5f9d">xutil_memtest.c</a>, <a class="el" href="xutil_8h.html#100d836b52f019cb2778dde05b8d5f9d">xutil.h</a><li>XUtil_MemoryTest8()
: <a class="el" href="xutil__memtest_8c.html#c823123744399391209d230c658e9bbc">xutil_memtest.c</a>, <a class="el" href="xutil_8h.html#c823123744399391209d230c658e9bbc">xutil.h</a><li>XVersion_Copy()
: <a class="el" href="xversion_8h.html#c6dc2f6cf4c2da3f6588eef8387d3b71">xversion.h</a>, <a class="el" href="xversion_8c.html#c6dc2f6cf4c2da3f6588eef8387d3b71">xversion.c</a><li>XVersion_FromString()
: <a class="el" href="xversion_8h.html#22fd522b3e13c6512573a164b1a41d6e">xversion.h</a>, <a class="el" href="xversion_8c.html#22fd522b3e13c6512573a164b1a41d6e">xversion.c</a><li>XVersion_IsEqual()
: <a class="el" href="xversion_8h.html#a60d242fb47a09b74d9273048938bc40">xversion.h</a>, <a class="el" href="xversion_8c.html#a60d242fb47a09b74d9273048938bc40">xversion.c</a><li>XVersion_Pack()
: <a class="el" href="xversion_8h.html#5cf6f72f47d99df8141526aa6e9090b2">xversion.h</a>, <a class="el" href="xversion_8c.html#c899b60e44960582459c9b83e1e68095">xversion.c</a><li>XVersion_ToString()
: <a class="el" href="xversion_8h.html#5509d59e756d51585c81b132cae02935">xversion.h</a>, <a class="el" href="xversion_8c.html#5509d59e756d51585c81b132cae02935">xversion.c</a><li>XVersion_UnPack()
: <a class="el" href="xversion_8h.html#83e7589d43e80a3c55f89d437bf72cee">xversion.h</a>, <a class="el" href="xversion_8c.html#83e7589d43e80a3c55f89d437bf72cee">xversion.c</a><li>XWaitInAssert
: <a class="el" href="xbasic__types_8c.html#b7fe61ef437a6dcb262405d5020cbf57">xbasic_types.c</a></ul>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,59 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: Data Fields
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li id="current"><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="globals.html"><span>All</span></a></li>
<li><a href="globals_func.html"><span>Functions</span></a></li>
<li><a href="globals_vars.html"><span>Variables</span></a></li>
<li><a href="globals_type.html"><span>Typedefs</span></a></li>
<li id="current"><a href="globals_defs.html"><span>Defines</span></a></li>
</ul>
</div>
&nbsp;
<p>
<ul>
<li>XASSERT_NONVOID
: <a class="el" href="xbasic__types_8h.html#b3a5c2bd864ed0dd4578c3adcd4d8d65">xbasic_types.h</a><li>XASSERT_NONVOID_ALWAYS
: <a class="el" href="xbasic__types_8h.html#a17eb37a9efa42a855596455d8071c15">xbasic_types.h</a><li>XASSERT_VOID
: <a class="el" href="xbasic__types_8h.html#7765783631e6609472f5674e47ece3c5">xbasic_types.h</a><li>XASSERT_VOID_ALWAYS
: <a class="el" href="xbasic__types_8h.html#8e42b9a913b0695a55388d039af80550">xbasic_types.h</a><li>XCOMPONENT_IS_READY
: <a class="el" href="xbasic__types_8h.html#ce7cba48175b32d6a97a24c95e2d5dc1">xbasic_types.h</a><li>XCOMPONENT_IS_STARTED
: <a class="el" href="xbasic__types_8h.html#14425162dda5c83496fac101f3ac3b39">xbasic_types.h</a><li>XENV_MEM_COPY
: <a class="el" href="xenv__vxworks_8h.html#aa4d213e22a5ede5b7099ab34ff79d38">xenv_vxworks.h</a>, <a class="el" href="xenv__standalone_8h.html#aa4d213e22a5ede5b7099ab34ff79d38">xenv_standalone.h</a>, <a class="el" href="xenv__linux_8h.html#aa4d213e22a5ede5b7099ab34ff79d38">xenv_linux.h</a><li>XENV_MEM_FILL
: <a class="el" href="xenv__vxworks_8h.html#0d8dfe452111356b4703424441ae8101">xenv_vxworks.h</a>, <a class="el" href="xenv__standalone_8h.html#0d8dfe452111356b4703424441ae8101">xenv_standalone.h</a>, <a class="el" href="xenv__linux_8h.html#0d8dfe452111356b4703424441ae8101">xenv_linux.h</a><li>XENV_TIME_STAMP_DELTA_MS
: <a class="el" href="xenv__vxworks_8h.html#fd056d3e6807f31827018bd78df00b53">xenv_vxworks.h</a>, <a class="el" href="xenv__standalone_8h.html#fd056d3e6807f31827018bd78df00b53">xenv_standalone.h</a>, <a class="el" href="xenv__linux_8h.html#fd056d3e6807f31827018bd78df00b53">xenv_linux.h</a><li>XENV_TIME_STAMP_DELTA_US
: <a class="el" href="xenv__vxworks_8h.html#1a080520bc88e99f438a03a7fee6a061">xenv_vxworks.h</a>, <a class="el" href="xenv__standalone_8h.html#1a080520bc88e99f438a03a7fee6a061">xenv_standalone.h</a>, <a class="el" href="xenv__linux_8h.html#1a080520bc88e99f438a03a7fee6a061">xenv_linux.h</a><li>XENV_TIME_STAMP_GET
: <a class="el" href="xenv__vxworks_8h.html#b29cb639eed7d2baf1a3d87744260df1">xenv_vxworks.h</a>, <a class="el" href="xenv__standalone_8h.html#b29cb639eed7d2baf1a3d87744260df1">xenv_standalone.h</a>, <a class="el" href="xenv__linux_8h.html#b29cb639eed7d2baf1a3d87744260df1">xenv_linux.h</a><li>XENV_USLEEP
: <a class="el" href="xenv__vxworks_8h.html#b5bf353013ce12567b705a2123efd198">xenv_vxworks.h</a>, <a class="el" href="xenv__standalone_8h.html#b5bf353013ce12567b705a2123efd198">xenv_standalone.h</a>, <a class="el" href="xenv__linux_8h.html#b5bf353013ce12567b705a2123efd198">xenv_linux.h</a><li>XNULL
: <a class="el" href="xbasic__types_8h.html#6993225d9cad2fca07266780ebb30f82">xbasic_types.h</a><li>XUINT64_LSW
: <a class="el" href="xbasic__types_8h.html#7af2620485199c26302dadd0b8173e48">xbasic_types.h</a><li>XUINT64_MSW
: <a class="el" href="xbasic__types_8h.html#6a2811b888a5d84ac350e6d3dfd09f10">xbasic_types.h</a><li>XUT_ALLMEMTESTS
: <a class="el" href="xutil_8h.html#611891b0e5c78d9849169a8ed9b37457">xutil.h</a></ul>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,55 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: Data Fields
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li id="current"><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="globals.html"><span>All</span></a></li>
<li id="current"><a href="globals_func.html"><span>Functions</span></a></li>
<li><a href="globals_vars.html"><span>Variables</span></a></li>
<li><a href="globals_type.html"><span>Typedefs</span></a></li>
<li><a href="globals_defs.html"><span>Defines</span></a></li>
</ul>
</div>
&nbsp;
<p>
<ul>
<li>XAssert()
: <a class="el" href="xbasic__types_8h.html#1f67a1ee7cf8cc0958f6d4d3c2936c5f">xbasic_types.h</a>, <a class="el" href="xbasic__types_8c.html#acbb4519b91c8f880f32b039ede107b2">xbasic_types.c</a><li>XAssertSetCallback()
: <a class="el" href="xbasic__types_8h.html#2b2df8e50ec26df3ecb901bdd8599ed6">xbasic_types.h</a>, <a class="el" href="xbasic__types_8c.html#2b2df8e50ec26df3ecb901bdd8599ed6">xbasic_types.c</a><li>XNullHandler()
: <a class="el" href="xbasic__types_8h.html#875c7885b68c71912fb32c4690063504">xbasic_types.h</a>, <a class="el" href="xbasic__types_8c.html#875c7885b68c71912fb32c4690063504">xbasic_types.c</a><li>XUtil_MemoryTest16()
: <a class="el" href="xutil__memtest_8c.html#3fa3b8c52b52a5d3bde1830f15d4242b">xutil_memtest.c</a>, <a class="el" href="xutil_8h.html#3fa3b8c52b52a5d3bde1830f15d4242b">xutil.h</a><li>XUtil_MemoryTest32()
: <a class="el" href="xutil__memtest_8c.html#100d836b52f019cb2778dde05b8d5f9d">xutil_memtest.c</a>, <a class="el" href="xutil_8h.html#100d836b52f019cb2778dde05b8d5f9d">xutil.h</a><li>XUtil_MemoryTest8()
: <a class="el" href="xutil__memtest_8c.html#c823123744399391209d230c658e9bbc">xutil_memtest.c</a>, <a class="el" href="xutil_8h.html#c823123744399391209d230c658e9bbc">xutil.h</a><li>XVersion_Copy()
: <a class="el" href="xversion_8h.html#c6dc2f6cf4c2da3f6588eef8387d3b71">xversion.h</a>, <a class="el" href="xversion_8c.html#c6dc2f6cf4c2da3f6588eef8387d3b71">xversion.c</a><li>XVersion_FromString()
: <a class="el" href="xversion_8h.html#22fd522b3e13c6512573a164b1a41d6e">xversion.h</a>, <a class="el" href="xversion_8c.html#22fd522b3e13c6512573a164b1a41d6e">xversion.c</a><li>XVersion_IsEqual()
: <a class="el" href="xversion_8h.html#a60d242fb47a09b74d9273048938bc40">xversion.h</a>, <a class="el" href="xversion_8c.html#a60d242fb47a09b74d9273048938bc40">xversion.c</a><li>XVersion_Pack()
: <a class="el" href="xversion_8h.html#5cf6f72f47d99df8141526aa6e9090b2">xversion.h</a>, <a class="el" href="xversion_8c.html#c899b60e44960582459c9b83e1e68095">xversion.c</a><li>XVersion_ToString()
: <a class="el" href="xversion_8h.html#5509d59e756d51585c81b132cae02935">xversion.h</a>, <a class="el" href="xversion_8c.html#5509d59e756d51585c81b132cae02935">xversion.c</a><li>XVersion_UnPack()
: <a class="el" href="xversion_8h.html#83e7589d43e80a3c55f89d437bf72cee">xversion.h</a>, <a class="el" href="xversion_8c.html#83e7589d43e80a3c55f89d437bf72cee">xversion.c</a></ul>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,56 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: Data Fields
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li id="current"><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="globals.html"><span>All</span></a></li>
<li><a href="globals_func.html"><span>Functions</span></a></li>
<li><a href="globals_vars.html"><span>Variables</span></a></li>
<li id="current"><a href="globals_type.html"><span>Typedefs</span></a></li>
<li><a href="globals_defs.html"><span>Defines</span></a></li>
</ul>
</div>
&nbsp;
<p>
<ul>
<li>XAssertCallback
: <a class="el" href="xbasic__types_8h.html#1f5b744ce282b4f67cf6eccf348bcf94">xbasic_types.h</a><li>Xboolean
: <a class="el" href="xbasic__types_8h.html#c229a98d42331dd3035340b4dffa7c30">xbasic_types.h</a><li>XENV_TIME_STAMP
: <a class="el" href="xenv__standalone_8h.html#e6b941709f64b60384a60ebd4cb12957">xenv_standalone.h</a>, <a class="el" href="xenv__linux_8h.html#e6b941709f64b60384a60ebd4cb12957">xenv_linux.h</a><li>XExceptionHandler
: <a class="el" href="xbasic__types_8h.html#cfa2257db2a92b2c2ca5d01a8b2cdba5">xbasic_types.h</a><li>Xfloat32
: <a class="el" href="xbasic__types_8h.html#78377cf4c372772008826fef885d0877">xbasic_types.h</a><li>Xfloat64
: <a class="el" href="xbasic__types_8h.html#4ae97cf4631e3eb9568636635b1acae0">xbasic_types.h</a><li>Xint16
: <a class="el" href="xbasic__types_8h.html#af1b2a7c8a73b7c812a37be0c34703e1">xbasic_types.h</a><li>Xint32
: <a class="el" href="xbasic__types_8h.html#0d57781a20d39780c62a2dc799f42483">xbasic_types.h</a><li>Xint8
: <a class="el" href="xbasic__types_8h.html#2545b71497eceff3c9baaca5c775249d">xbasic_types.h</a><li>XInterruptHandler
: <a class="el" href="xbasic__types_8h.html#c832ba88139f2bdb785df8ce07c0a510">xbasic_types.h</a><li>Xuint16
: <a class="el" href="xbasic__types_8h.html#444b60b25c332c45da7262f20e7c3d93">xbasic_types.h</a><li>Xuint32
: <a class="el" href="xbasic__types_8h.html#f08247645ba692e675a481f42599730c">xbasic_types.h</a><li>Xuint8
: <a class="el" href="xbasic__types_8h.html#ff6fcfd0df5ba1eef8a88eb7779898d7">xbasic_types.h</a></ul>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,45 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: Data Fields
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li id="current"><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="globals.html"><span>All</span></a></li>
<li><a href="globals_func.html"><span>Functions</span></a></li>
<li id="current"><a href="globals_vars.html"><span>Variables</span></a></li>
<li><a href="globals_type.html"><span>Typedefs</span></a></li>
<li><a href="globals_defs.html"><span>Defines</span></a></li>
</ul>
</div>
&nbsp;
<p>
<ul>
<li>XAssertStatus
: <a class="el" href="xbasic__types_8h.html#d9dbab8a843c44e98c8c9b96d2849432">xbasic_types.h</a>, <a class="el" href="xbasic__types_8c.html#d9dbab8a843c44e98c8c9b96d2849432">xbasic_types.c</a><li>XWaitInAssert
: <a class="el" href="xbasic__types_8c.html#b7fe61ef437a6dcb262405d5020cbf57">xbasic_types.c</a></ul>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,27 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: Main Page
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li id="current"><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul></div>
<h1>Xilinx Driver common v1_00_a Documentation</h1>
<p>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,37 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: XENV_TIME_STAMP Struct Reference
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li id="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
</ul></div>
<h1>XENV_TIME_STAMP Struct Reference</h1><!-- doxytag: class="XENV_TIME_STAMP" --><hr><a name="_details"></a><h2>Detailed Description</h2>
A structure that contains a time stamp used by other time stamp macros defined below. This structure is processor dependent.
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
</table>
<hr>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="xenv__vxworks_8h.html">xenv_vxworks.h</a></ul>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 35 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 706 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

View file

@ -1,102 +0,0 @@
/* tabs styles, based on http://www.alistapart.com/articles/slidingdoors */
DIV.tabs
{
float : left;
width : 100%;
background : url("tab_b.gif") repeat-x bottom;
margin-bottom : 4px;
}
DIV.tabs UL
{
margin : 0px;
padding-left : 10px;
list-style : none;
}
DIV.tabs LI, DIV.tabs FORM
{
display : inline;
margin : 0px;
padding : 0px;
}
DIV.tabs FORM
{
float : right;
}
DIV.tabs A
{
float : left;
background : url("tab_r.gif") no-repeat right top;
border-bottom : 1px solid #84B0C7;
font-size : x-small;
font-weight : bold;
text-decoration : none;
}
DIV.tabs A:hover
{
background-position: 100% -150px;
}
DIV.tabs A:link, DIV.tabs A:visited,
DIV.tabs A:active, DIV.tabs A:hover
{
color: #1A419D;
}
DIV.tabs SPAN
{
float : left;
display : block;
background : url("tab_l.gif") no-repeat left top;
padding : 5px 9px;
white-space : nowrap;
}
DIV.tabs INPUT
{
float : right;
display : inline;
font-size : 1em;
}
DIV.tabs TD
{
font-size : x-small;
font-weight : bold;
text-decoration : none;
}
/* Commented Backslash Hack hides rule from IE5-Mac \*/
DIV.tabs SPAN {float : none;}
/* End IE5-Mac hack */
DIV.tabs A:hover SPAN
{
background-position: 0% -150px;
}
DIV.tabs LI#current A
{
background-position: 100% -150px;
border-width : 0px;
}
DIV.tabs LI#current SPAN
{
background-position: 0% -150px;
padding-bottom : 6px;
}
DIV.nav
{
background : none;
border : none;
border-bottom : 1px solid #84B0C7;
}

View file

@ -1,182 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: xbasic_types.c File Reference
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<h1>xbasic_types.c File Reference</h1><hr><a name="_details"></a><h2>Detailed Description</h2>
This file contains basic functions for Xilinx software IP.<p>
<pre>
MODIFICATION HISTORY:</pre><p>
<pre> Ver Who Date Changes
----- ---- -------- -------------------------------------------------------
1.00a rpm 11/07/03 Added XNullHandler function as a stub interrupt handler
1.00a xd 11/03/04 Improved support for doxygen.
1.00a bss 13/01/12 Removed a compiler warning in XNullHandler;
</pre>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8c.html#acbb4519b91c8f880f32b039ede107b2">XAssert</a> (char *File, int Line)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8c.html#2b2df8e50ec26df3ecb901bdd8599ed6">XAssertSetCallback</a> (<a class="el" href="xbasic__types_8h.html#1f5b744ce282b4f67cf6eccf348bcf94">XAssertCallback</a> Routine)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8c.html#875c7885b68c71912fb32c4690063504">XNullHandler</a> (void *NullParameter)</td></tr>
<tr><td colspan="2"><br><h2>Variables</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">unsigned int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8c.html#d9dbab8a843c44e98c8c9b96d2849432">XAssertStatus</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8c.html#b7fe61ef437a6dcb262405d5020cbf57">XWaitInAssert</a></td></tr>
</table>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="acbb4519b91c8f880f32b039ede107b2"></a><!-- doxytag: member="xbasic_types.c::XAssert" ref="acbb4519b91c8f880f32b039ede107b2" args="(char *File, int Line)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void XAssert </td>
<td>(</td>
<td class="paramtype">char *&nbsp;</td>
<td class="paramname"> <em>File</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>Line</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Implements assert. Currently, it calls a user-defined callback function if one has been set. Then, it potentially enters an infinite loop depending on the value of the XWaitInAssert variable.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>File</em>&nbsp;</td><td>is the name of the filename of the source </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Line</em>&nbsp;</td><td>is the linenumber within File</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<a class="anchor" name="2b2df8e50ec26df3ecb901bdd8599ed6"></a><!-- doxytag: member="xbasic_types.c::XAssertSetCallback" ref="2b2df8e50ec26df3ecb901bdd8599ed6" args="(XAssertCallback Routine)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void XAssertSetCallback </td>
<td>(</td>
<td class="paramtype"><a class="el" href="xbasic__types_8h.html#1f5b744ce282b4f67cf6eccf348bcf94">XAssertCallback</a>&nbsp;</td>
<td class="paramname"> <em>Routine</em> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Sets up a callback function to be invoked when an assert occurs. If there was already a callback installed, then it is replaced.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>Routine</em>&nbsp;</td><td>is the callback to be invoked when an assert is taken</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>This function has no effect if NDEBUG is set </dd></dl>
</div>
</div><p>
<a class="anchor" name="875c7885b68c71912fb32c4690063504"></a><!-- doxytag: member="xbasic_types.c::XNullHandler" ref="875c7885b68c71912fb32c4690063504" args="(void *NullParameter)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void XNullHandler </td>
<td>(</td>
<td class="paramtype">void *&nbsp;</td>
<td class="paramname"> <em>NullParameter</em> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Null handler function. This follows the XInterruptHandler signature for interrupt handlers. It can be used to assign a null handler (a stub) to an interrupt controller vector table.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>NullParameter</em>&nbsp;</td><td>is an arbitrary void pointer and not used.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<hr><h2>Variable Documentation</h2>
<a class="anchor" name="d9dbab8a843c44e98c8c9b96d2849432"></a><!-- doxytag: member="xbasic_types.c::XAssertStatus" ref="d9dbab8a843c44e98c8c9b96d2849432" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">unsigned int <a class="el" href="xbasic__types_8h.html#d9dbab8a843c44e98c8c9b96d2849432">XAssertStatus</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This variable allows testing to be done easier with asserts. An assert sets this variable such that a driver can evaluate this variable to determine if an assert occurred.
</div>
</div><p>
<a class="anchor" name="b7fe61ef437a6dcb262405d5020cbf57"></a><!-- doxytag: member="xbasic_types.c::XWaitInAssert" ref="b7fe61ef437a6dcb262405d5020cbf57" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int <a class="el" href="xbasic__types_8c.html#b7fe61ef437a6dcb262405d5020cbf57">XWaitInAssert</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This variable allows the assert functionality to be changed for testing such that it does not wait infinitely. Use the debugger to disable the waiting during testing of asserts.
</div>
</div><p>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,617 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: xbasic_types.h File Reference
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<h1>xbasic_types.h File Reference</h1><hr><a name="_details"></a><h2>Detailed Description</h2>
This file contains basic types for Xilinx software IP. These types do not follow the standard naming convention with respect to using the component name in front of each name because they are considered to be primitives.<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
This file contains items which are architecture dependent.<p>
<pre>
MODIFICATION HISTORY:</pre><p>
<pre> Ver Who Date Changes
----- ---- -------- -------------------------------------------------------
1.00a rmm 12/14/01 First release
rmm 05/09/03 Added "xassert always" macros to rid ourselves of diab
compiler warnings
1.00a rpm 11/07/03 Added XNullHandler function as a stub interrupt handler
1.00a rpm 07/21/04 Added XExceptionHandler typedef for processor exceptions
1.00a xd 11/03/04 Improved support for doxygen.
1.00a wre 01/25/07 Added Linux style data types u32, u16, u8, TRUE, FALSE
1.00a rpm 04/02/07 Added ifndef KERNEL around u32, u16, u8 data types
</pre>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Structures</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct &nbsp;</td><td class="memItemRight" valign="bottom"><b>Xuint64</b></td></tr>
<tr><td colspan="2"><br><h2>Legacy types</h2></td></tr>
<tr><td colspan="2">Deprecated legacy types. <br><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef unsigned char&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#ff6fcfd0df5ba1eef8a88eb7779898d7">Xuint8</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef char&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#2545b71497eceff3c9baaca5c775249d">Xint8</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef unsigned short&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#444b60b25c332c45da7262f20e7c3d93">Xuint16</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef short&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#af1b2a7c8a73b7c812a37be0c34703e1">Xint16</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef unsigned long&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#f08247645ba692e675a481f42599730c">Xuint32</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef long&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#0d57781a20d39780c62a2dc799f42483">Xint32</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef float&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#78377cf4c372772008826fef885d0877">Xfloat32</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef double&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#4ae97cf4631e3eb9568636635b1acae0">Xfloat64</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef unsigned long&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#c229a98d42331dd3035340b4dffa7c30">Xboolean</a></td></tr>
<tr><td colspan="2"><br><h2>New types</h2></td></tr>
<tr><td colspan="2">New simple types. <br><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="341e7918d39c8573e9b37ce517cc0daf"></a><!-- doxytag: member="xbasic_types.h::u32" ref="341e7918d39c8573e9b37ce517cc0daf" args="" -->
typedef <a class="el" href="xbasic__types_8h.html#f08247645ba692e675a481f42599730c">Xuint32</a>&nbsp;</td><td class="memItemRight" valign="bottom"><b>u32</b></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="151ab6ffc25f3034f9f8a6effec66067"></a><!-- doxytag: member="xbasic_types.h::u16" ref="151ab6ffc25f3034f9f8a6effec66067" args="" -->
typedef <a class="el" href="xbasic__types_8h.html#444b60b25c332c45da7262f20e7c3d93">Xuint16</a>&nbsp;</td><td class="memItemRight" valign="bottom"><b>u16</b></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="bc4ec5c3dd42390bbe6ebddcce7f5058"></a><!-- doxytag: member="xbasic_types.h::u8" ref="bc4ec5c3dd42390bbe6ebddcce7f5058" args="" -->
typedef <a class="el" href="xbasic__types_8h.html#ff6fcfd0df5ba1eef8a88eb7779898d7">Xuint8</a>&nbsp;</td><td class="memItemRight" valign="bottom"><b>u8</b></td></tr>
<tr><td colspan="2"><br><h2>Defines</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#6993225d9cad2fca07266780ebb30f82">XNULL</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#ce7cba48175b32d6a97a24c95e2d5dc1">XCOMPONENT_IS_READY</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#14425162dda5c83496fac101f3ac3b39">XCOMPONENT_IS_STARTED</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#6a2811b888a5d84ac350e6d3dfd09f10">XUINT64_MSW</a>(x)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#7af2620485199c26302dadd0b8173e48">XUINT64_LSW</a>(x)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#7765783631e6609472f5674e47ece3c5">XASSERT_VOID</a>(expression)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#b3a5c2bd864ed0dd4578c3adcd4d8d65">XASSERT_NONVOID</a>(expression)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#8e42b9a913b0695a55388d039af80550">XASSERT_VOID_ALWAYS</a>()</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#a17eb37a9efa42a855596455d8071c15">XASSERT_NONVOID_ALWAYS</a>()</td></tr>
<tr><td colspan="2"><br><h2>Typedefs</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*)&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#c832ba88139f2bdb785df8ce07c0a510">XInterruptHandler</a> (void *InstancePtr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*)&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#cfa2257db2a92b2c2ca5d01a8b2cdba5">XExceptionHandler</a> (void *InstancePtr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*)&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#1f5b744ce282b4f67cf6eccf348bcf94">XAssertCallback</a> (char *FilenamePtr, int LineNumber)</td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#1f67a1ee7cf8cc0958f6d4d3c2936c5f">XAssert</a> (char *, int)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#2b2df8e50ec26df3ecb901bdd8599ed6">XAssertSetCallback</a> (<a class="el" href="xbasic__types_8h.html#1f5b744ce282b4f67cf6eccf348bcf94">XAssertCallback</a> Routine)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#875c7885b68c71912fb32c4690063504">XNullHandler</a> (void *NullParameter)</td></tr>
<tr><td colspan="2"><br><h2>Variables</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">unsigned int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbasic__types_8h.html#d9dbab8a843c44e98c8c9b96d2849432">XAssertStatus</a></td></tr>
</table>
<hr><h2>Define Documentation</h2>
<a class="anchor" name="b3a5c2bd864ed0dd4578c3adcd4d8d65"></a><!-- doxytag: member="xbasic_types.h::XASSERT_NONVOID" ref="b3a5c2bd864ed0dd4578c3adcd4d8d65" args="(expression)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XASSERT_NONVOID </td>
<td>(</td>
<td class="paramtype">expression&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This assert macro is to be used for functions that do return a value. This in conjunction with the XWaitInAssert boolean can be used to accomodate tests so that asserts which fail allow execution to continue.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>expression</em>&nbsp;</td><td>is the expression to evaluate. If it evaluates to false, the assert occurs.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>Returns 0 unless the XWaitInAssert variable is true, in which case no return is made and an infinite loop is entered.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<a class="anchor" name="a17eb37a9efa42a855596455d8071c15"></a><!-- doxytag: member="xbasic_types.h::XASSERT_NONVOID_ALWAYS" ref="a17eb37a9efa42a855596455d8071c15" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XASSERT_NONVOID_ALWAYS </td>
<td>(</td>
&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Always assert. This assert macro is to be used for functions that do return a value. Use for instances where an assert should always occur.<p>
<dl compact><dt><b>Returns:</b></dt><dd>Returns void unless the XWaitInAssert variable is true, in which case no return is made and an infinite loop is entered.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<a class="anchor" name="7765783631e6609472f5674e47ece3c5"></a><!-- doxytag: member="xbasic_types.h::XASSERT_VOID" ref="7765783631e6609472f5674e47ece3c5" args="(expression)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XASSERT_VOID </td>
<td>(</td>
<td class="paramtype">expression&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This assert macro is to be used for functions that do not return anything (void). This in conjunction with the XWaitInAssert boolean can be used to accomodate tests so that asserts which fail allow execution to continue.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>expression</em>&nbsp;</td><td>is the expression to evaluate. If it evaluates to false, the assert occurs.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>Returns void unless the XWaitInAssert variable is true, in which case no return is made and an infinite loop is entered.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<a class="anchor" name="8e42b9a913b0695a55388d039af80550"></a><!-- doxytag: member="xbasic_types.h::XASSERT_VOID_ALWAYS" ref="8e42b9a913b0695a55388d039af80550" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XASSERT_VOID_ALWAYS </td>
<td>(</td>
&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Always assert. This assert macro is to be used for functions that do not return anything (void). Use for instances where an assert should always occur.<p>
<dl compact><dt><b>Returns:</b></dt><dd>Returns void unless the XWaitInAssert variable is true, in which case no return is made and an infinite loop is entered.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<a class="anchor" name="ce7cba48175b32d6a97a24c95e2d5dc1"></a><!-- doxytag: member="xbasic_types.h::XCOMPONENT_IS_READY" ref="ce7cba48175b32d6a97a24c95e2d5dc1" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XCOMPONENT_IS_READY </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
component has been initialized
</div>
</div><p>
<a class="anchor" name="14425162dda5c83496fac101f3ac3b39"></a><!-- doxytag: member="xbasic_types.h::XCOMPONENT_IS_STARTED" ref="14425162dda5c83496fac101f3ac3b39" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XCOMPONENT_IS_STARTED </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
component has been started
</div>
</div><p>
<a class="anchor" name="6993225d9cad2fca07266780ebb30f82"></a><!-- doxytag: member="xbasic_types.h::XNULL" ref="6993225d9cad2fca07266780ebb30f82" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XNULL </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Xilinx NULL, TRUE and FALSE legacy support. Deprecated.
</div>
</div><p>
<a class="anchor" name="7af2620485199c26302dadd0b8173e48"></a><!-- doxytag: member="xbasic_types.h::XUINT64_LSW" ref="7af2620485199c26302dadd0b8173e48" args="(x)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XUINT64_LSW </td>
<td>(</td>
<td class="paramtype">x&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Return the least significant half of the 64 bit data type.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>x</em>&nbsp;</td><td>is the 64 bit word.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>The lower 32 bits of the 64 bit word.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<a class="anchor" name="6a2811b888a5d84ac350e6d3dfd09f10"></a><!-- doxytag: member="xbasic_types.h::XUINT64_MSW" ref="6a2811b888a5d84ac350e6d3dfd09f10" args="(x)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XUINT64_MSW </td>
<td>(</td>
<td class="paramtype">x&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Return the most significant half of the 64 bit data type.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>x</em>&nbsp;</td><td>is the 64 bit word.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>The upper 32 bits of the 64 bit word.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<hr><h2>Typedef Documentation</h2>
<a class="anchor" name="1f5b744ce282b4f67cf6eccf348bcf94"></a><!-- doxytag: member="xbasic_types.h::XAssertCallback" ref="1f5b744ce282b4f67cf6eccf348bcf94" args="(char *FilenamePtr, int LineNumber)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void(*) <a class="el" href="xbasic__types_8h.html#1f5b744ce282b4f67cf6eccf348bcf94">XAssertCallback</a>(char *FilenamePtr, int LineNumber) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This data type defines a callback to be invoked when an assert occurs. The callback is invoked only when asserts are enabled
</div>
</div><p>
<a class="anchor" name="c229a98d42331dd3035340b4dffa7c30"></a><!-- doxytag: member="xbasic_types.h::Xboolean" ref="c229a98d42331dd3035340b4dffa7c30" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef unsigned long <a class="el" href="xbasic__types_8h.html#c229a98d42331dd3035340b4dffa7c30">Xboolean</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
boolean (XTRUE or XFALSE)
</div>
</div><p>
<a class="anchor" name="cfa2257db2a92b2c2ca5d01a8b2cdba5"></a><!-- doxytag: member="xbasic_types.h::XExceptionHandler" ref="cfa2257db2a92b2c2ca5d01a8b2cdba5" args="(void *InstancePtr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void(*) <a class="el" href="xbasic__types_8h.html#cfa2257db2a92b2c2ca5d01a8b2cdba5">XExceptionHandler</a>(void *InstancePtr) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This data type defines an exception handler for a processor. The argument points to the instance of the component
</div>
</div><p>
<a class="anchor" name="78377cf4c372772008826fef885d0877"></a><!-- doxytag: member="xbasic_types.h::Xfloat32" ref="78377cf4c372772008826fef885d0877" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef float <a class="el" href="xbasic__types_8h.html#78377cf4c372772008826fef885d0877">Xfloat32</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
32-bit floating point
</div>
</div><p>
<a class="anchor" name="4ae97cf4631e3eb9568636635b1acae0"></a><!-- doxytag: member="xbasic_types.h::Xfloat64" ref="4ae97cf4631e3eb9568636635b1acae0" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef double <a class="el" href="xbasic__types_8h.html#4ae97cf4631e3eb9568636635b1acae0">Xfloat64</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
64-bit double precision FP
</div>
</div><p>
<a class="anchor" name="af1b2a7c8a73b7c812a37be0c34703e1"></a><!-- doxytag: member="xbasic_types.h::Xint16" ref="af1b2a7c8a73b7c812a37be0c34703e1" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef short <a class="el" href="xbasic__types_8h.html#af1b2a7c8a73b7c812a37be0c34703e1">Xint16</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
signed 16-bit
</div>
</div><p>
<a class="anchor" name="0d57781a20d39780c62a2dc799f42483"></a><!-- doxytag: member="xbasic_types.h::Xint32" ref="0d57781a20d39780c62a2dc799f42483" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef long <a class="el" href="xbasic__types_8h.html#0d57781a20d39780c62a2dc799f42483">Xint32</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
signed 32-bit
</div>
</div><p>
<a class="anchor" name="2545b71497eceff3c9baaca5c775249d"></a><!-- doxytag: member="xbasic_types.h::Xint8" ref="2545b71497eceff3c9baaca5c775249d" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef char <a class="el" href="xbasic__types_8h.html#2545b71497eceff3c9baaca5c775249d">Xint8</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
signed 8-bit
</div>
</div><p>
<a class="anchor" name="c832ba88139f2bdb785df8ce07c0a510"></a><!-- doxytag: member="xbasic_types.h::XInterruptHandler" ref="c832ba88139f2bdb785df8ce07c0a510" args="(void *InstancePtr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void(*) <a class="el" href="xbasic__types_8h.html#c832ba88139f2bdb785df8ce07c0a510">XInterruptHandler</a>(void *InstancePtr) </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This data type defines an interrupt handler for a device. The argument points to the instance of the component
</div>
</div><p>
<a class="anchor" name="444b60b25c332c45da7262f20e7c3d93"></a><!-- doxytag: member="xbasic_types.h::Xuint16" ref="444b60b25c332c45da7262f20e7c3d93" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef unsigned short <a class="el" href="xbasic__types_8h.html#444b60b25c332c45da7262f20e7c3d93">Xuint16</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
unsigned 16-bit
</div>
</div><p>
<a class="anchor" name="f08247645ba692e675a481f42599730c"></a><!-- doxytag: member="xbasic_types.h::Xuint32" ref="f08247645ba692e675a481f42599730c" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef unsigned long <a class="el" href="xbasic__types_8h.html#f08247645ba692e675a481f42599730c">Xuint32</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
unsigned 32-bit
</div>
</div><p>
<a class="anchor" name="ff6fcfd0df5ba1eef8a88eb7779898d7"></a><!-- doxytag: member="xbasic_types.h::Xuint8" ref="ff6fcfd0df5ba1eef8a88eb7779898d7" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef unsigned char <a class="el" href="xbasic__types_8h.html#ff6fcfd0df5ba1eef8a88eb7779898d7">Xuint8</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
unsigned 8-bit
</div>
</div><p>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="1f67a1ee7cf8cc0958f6d4d3c2936c5f"></a><!-- doxytag: member="xbasic_types.h::XAssert" ref="1f67a1ee7cf8cc0958f6d4d3c2936c5f" args="(char *, int)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void XAssert </td>
<td>(</td>
<td class="paramtype">char *&nbsp;</td>
<td class="paramname"> <em>File</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>Line</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Implements assert. Currently, it calls a user-defined callback function if one has been set. Then, it potentially enters an infinite loop depending on the value of the XWaitInAssert variable.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>File</em>&nbsp;</td><td>is the name of the filename of the source </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Line</em>&nbsp;</td><td>is the linenumber within File</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<a class="anchor" name="2b2df8e50ec26df3ecb901bdd8599ed6"></a><!-- doxytag: member="xbasic_types.h::XAssertSetCallback" ref="2b2df8e50ec26df3ecb901bdd8599ed6" args="(XAssertCallback Routine)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void XAssertSetCallback </td>
<td>(</td>
<td class="paramtype"><a class="el" href="xbasic__types_8h.html#1f5b744ce282b4f67cf6eccf348bcf94">XAssertCallback</a>&nbsp;</td>
<td class="paramname"> <em>Routine</em> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Sets up a callback function to be invoked when an assert occurs. If there was already a callback installed, then it is replaced.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>Routine</em>&nbsp;</td><td>is the callback to be invoked when an assert is taken</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>This function has no effect if NDEBUG is set </dd></dl>
</div>
</div><p>
<a class="anchor" name="875c7885b68c71912fb32c4690063504"></a><!-- doxytag: member="xbasic_types.h::XNullHandler" ref="875c7885b68c71912fb32c4690063504" args="(void *NullParameter)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void XNullHandler </td>
<td>(</td>
<td class="paramtype">void *&nbsp;</td>
<td class="paramname"> <em>NullParameter</em> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Null handler function. This follows the XInterruptHandler signature for interrupt handlers. It can be used to assign a null handler (a stub) to an interrupt controller vector table.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>NullParameter</em>&nbsp;</td><td>is an arbitrary void pointer and not used.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<hr><h2>Variable Documentation</h2>
<a class="anchor" name="d9dbab8a843c44e98c8c9b96d2849432"></a><!-- doxytag: member="xbasic_types.h::XAssertStatus" ref="d9dbab8a843c44e98c8c9b96d2849432" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">unsigned int <a class="el" href="xbasic__types_8h.html#d9dbab8a843c44e98c8c9b96d2849432">XAssertStatus</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This variable allows testing to be done easier with asserts. An assert sets this variable such that a driver can evaluate this variable to determine if an assert occurred.
</div>
</div><p>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,44 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: xenv.h File Reference
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<h1>xenv.h File Reference</h1><hr><a name="_details"></a><h2>Detailed Description</h2>
Defines common services that are typically found in a host operating. environment. This include file simply includes an OS specific file based on the compile-time constant BUILD_ENV_*, where * is the name of the target environment.<p>
All services are defined as macros.<p>
<pre>
MODIFICATION HISTORY:</pre><p>
<pre> Ver Who Date Changes
----- ---- -------- -----------------------------------------------
1.00b ch 10/24/02 Added XENV_LINUX
1.00a rmm 04/17/02 First release
</pre>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
</table>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,272 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: xenv_linux.h File Reference
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<h1>xenv_linux.h File Reference</h1><hr><a name="_details"></a><h2>Detailed Description</h2>
Defines common services specified by <a class="el" href="xenv_8h.html">xenv.h</a>.<p>
<dl compact><dt><b>Note:</b></dt><dd>This file is not intended to be included directly by driver code. Instead, the generic <a class="el" href="xenv_8h.html">xenv.h</a> file is intended to be included by driver code.</dd></dl>
<pre>
MODIFICATION HISTORY:</pre><p>
<pre> Ver Who Date Changes
----- ---- -------- -----------------------------------------------
1.00a wgr 02/28/07 Added cache handling macros.
1.00a wgr 02/27/07 Simplified code. Deprecated old-style macro names.
1.00a xd 11/03/04 Improved support for doxygen.
1.00a ch 10/24/02 First release
1.10a wgr 03/22/07 Converted to new coding style.
</pre>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Defines</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__linux_8h.html#aa4d213e22a5ede5b7099ab34ff79d38">XENV_MEM_COPY</a>(DestPtr, SrcPtr, Bytes)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__linux_8h.html#0d8dfe452111356b4703424441ae8101">XENV_MEM_FILL</a>(DestPtr, Data, Bytes)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__linux_8h.html#b29cb639eed7d2baf1a3d87744260df1">XENV_TIME_STAMP_GET</a>(StampPtr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__linux_8h.html#1a080520bc88e99f438a03a7fee6a061">XENV_TIME_STAMP_DELTA_US</a>(Stamp1Ptr, Stamp2Ptr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__linux_8h.html#fd056d3e6807f31827018bd78df00b53">XENV_TIME_STAMP_DELTA_MS</a>(Stamp1Ptr, Stamp2Ptr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__linux_8h.html#b5bf353013ce12567b705a2123efd198">XENV_USLEEP</a>(delay)</td></tr>
<tr><td colspan="2"><br><h2>Typedefs</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__linux_8h.html#e6b941709f64b60384a60ebd4cb12957">XENV_TIME_STAMP</a></td></tr>
</table>
<hr><h2>Define Documentation</h2>
<a class="anchor" name="aa4d213e22a5ede5b7099ab34ff79d38"></a><!-- doxytag: member="xenv_linux.h::XENV_MEM_COPY" ref="aa4d213e22a5ede5b7099ab34ff79d38" args="(DestPtr, SrcPtr, Bytes)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_MEM_COPY </td>
<td>(</td>
<td class="paramtype">DestPtr, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">SrcPtr, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">Bytes&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Copies a non-overlapping block of memory.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>DestPtr</em>&nbsp;</td><td>Destination address to copy data to.</td></tr>
<tr><td valign="top"></td><td valign="top"><em>SrcPtr</em>&nbsp;</td><td>Source address to copy data from.</td></tr>
<tr><td valign="top"></td><td valign="top"><em>Bytes</em>&nbsp;</td><td>Number of bytes to copy.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<a class="anchor" name="0d8dfe452111356b4703424441ae8101"></a><!-- doxytag: member="xenv_linux.h::XENV_MEM_FILL" ref="0d8dfe452111356b4703424441ae8101" args="(DestPtr, Data, Bytes)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_MEM_FILL </td>
<td>(</td>
<td class="paramtype">DestPtr, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">Data, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">Bytes&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Fills an area of memory with constant data.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>DestPtr</em>&nbsp;</td><td>Destination address to copy data to.</td></tr>
<tr><td valign="top"></td><td valign="top"><em>Data</em>&nbsp;</td><td>Value to set.</td></tr>
<tr><td valign="top"></td><td valign="top"><em>Bytes</em>&nbsp;</td><td>Number of bytes to copy.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<a class="anchor" name="fd056d3e6807f31827018bd78df00b53"></a><!-- doxytag: member="xenv_linux.h::XENV_TIME_STAMP_DELTA_MS" ref="fd056d3e6807f31827018bd78df00b53" args="(Stamp1Ptr, Stamp2Ptr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_TIME_STAMP_DELTA_MS </td>
<td>(</td>
<td class="paramtype">Stamp1Ptr, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">Stamp2Ptr&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This macro is not yet implemented and always returns 0.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>Stamp1Ptr</em>&nbsp;</td><td>is the first sampled time stamp. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Stamp2Ptr</em>&nbsp;</td><td>is the second sampled time stamp.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>0</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
This macro must be implemented by the user
</div>
</div><p>
<a class="anchor" name="1a080520bc88e99f438a03a7fee6a061"></a><!-- doxytag: member="xenv_linux.h::XENV_TIME_STAMP_DELTA_US" ref="1a080520bc88e99f438a03a7fee6a061" args="(Stamp1Ptr, Stamp2Ptr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_TIME_STAMP_DELTA_US </td>
<td>(</td>
<td class="paramtype">Stamp1Ptr, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">Stamp2Ptr&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This macro is not yet implemented and always returns 0.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>Stamp1Ptr</em>&nbsp;</td><td>is the first sampled time stamp. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Stamp2Ptr</em>&nbsp;</td><td>is the second sampled time stamp.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>0</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
This macro must be implemented by the user.
</div>
</div><p>
<a class="anchor" name="b29cb639eed7d2baf1a3d87744260df1"></a><!-- doxytag: member="xenv_linux.h::XENV_TIME_STAMP_GET" ref="b29cb639eed7d2baf1a3d87744260df1" args="(StampPtr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_TIME_STAMP_GET </td>
<td>(</td>
<td class="paramtype">StampPtr&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Time is derived from the 64 bit PPC timebase register<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>StampPtr</em>&nbsp;</td><td>is the storage for the retrieved time stamp.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
Signature: void <a class="el" href="xenv__vxworks_8h.html#b29cb639eed7d2baf1a3d87744260df1">XENV_TIME_STAMP_GET(XTIME_STAMP *StampPtr)</a> <br>
<br>
This macro must be implemented by the user.
</div>
</div><p>
<a class="anchor" name="b5bf353013ce12567b705a2123efd198"></a><!-- doxytag: member="xenv_linux.h::XENV_USLEEP" ref="b5bf353013ce12567b705a2123efd198" args="(delay)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_USLEEP </td>
<td>(</td>
<td class="paramtype">delay&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Delay the specified number of microseconds.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>delay</em>&nbsp;</td><td>Number of microseconds to delay.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>XENV_USLEEP is deprecated. Use udelay() instead. </dd></dl>
</div>
</div><p>
<hr><h2>Typedef Documentation</h2>
<a class="anchor" name="e6b941709f64b60384a60ebd4cb12957"></a><!-- doxytag: member="xenv_linux.h::XENV_TIME_STAMP" ref="e6b941709f64b60384a60ebd4cb12957" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef int <a class="el" href="struct_x_e_n_v___t_i_m_e___s_t_a_m_p.html">XENV_TIME_STAMP</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
A structure that contains a time stamp used by other time stamp macros defined below. This structure is processor dependent.
</div>
</div><p>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,37 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: xenv_none.h File Reference
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<h1>xenv_none.h File Reference</h1><hr><a name="_details"></a><h2>Detailed Description</h2>
This is a legacy file kept for backwards compatibility.<p>
Please modify your code to include "xenv_standalone.h" instead.
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
</table>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,281 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: xenv_standalone.h File Reference
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<h1>xenv_standalone.h File Reference</h1><hr><a name="_details"></a><h2>Detailed Description</h2>
Defines common services specified by <a class="el" href="xenv_8h.html">xenv.h</a>.<p>
<dl compact><dt><b>Note:</b></dt><dd>This file is not intended to be included directly by driver code. Instead, the generic <a class="el" href="xenv_8h.html">xenv.h</a> file is intended to be included by driver code.</dd></dl>
<pre>
MODIFICATION HISTORY:</pre><p>
<pre> Ver Who Date Changes
----- ---- -------- -----------------------------------------------
1.00a wgr 02/28/07 Added cache handling macros.
1.00a wgr 02/27/07 Simplified code. Deprecated old-style macro names.
1.00a rmm 01/24/06 Implemented XENV_USLEEP. Assume implementation is being
used under Xilinx standalone BSP.
1.00a xd 11/03/04 Improved support for doxygen.
1.00a rmm 03/21/02 First release
1.00a wgr 03/22/07 Converted to new coding style.
1.00a rpm 06/29/07 Added udelay macro for standalone
1.00a xd 07/19/07 Included <a class="el" href="xparameters_8h.html">xparameters.h</a> as XPAR_ constants are referred
to in MICROBLAZE section
1.00a ecm 09/19/08 updated for v7.20 of Microblaze, new functionality</pre><p>
<pre> </pre>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Defines</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__standalone_8h.html#aa4d213e22a5ede5b7099ab34ff79d38">XENV_MEM_COPY</a>(DestPtr, SrcPtr, Bytes)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__standalone_8h.html#0d8dfe452111356b4703424441ae8101">XENV_MEM_FILL</a>(DestPtr, Data, Bytes)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__standalone_8h.html#b29cb639eed7d2baf1a3d87744260df1">XENV_TIME_STAMP_GET</a>(StampPtr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__standalone_8h.html#1a080520bc88e99f438a03a7fee6a061">XENV_TIME_STAMP_DELTA_US</a>(Stamp1Ptr, Stamp2Ptr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__standalone_8h.html#fd056d3e6807f31827018bd78df00b53">XENV_TIME_STAMP_DELTA_MS</a>(Stamp1Ptr, Stamp2Ptr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__standalone_8h.html#b5bf353013ce12567b705a2123efd198">XENV_USLEEP</a>(delay)</td></tr>
<tr><td colspan="2"><br><h2>Typedefs</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__standalone_8h.html#e6b941709f64b60384a60ebd4cb12957">XENV_TIME_STAMP</a></td></tr>
</table>
<hr><h2>Define Documentation</h2>
<a class="anchor" name="aa4d213e22a5ede5b7099ab34ff79d38"></a><!-- doxytag: member="xenv_standalone.h::XENV_MEM_COPY" ref="aa4d213e22a5ede5b7099ab34ff79d38" args="(DestPtr, SrcPtr, Bytes)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_MEM_COPY </td>
<td>(</td>
<td class="paramtype">DestPtr, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">SrcPtr, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">Bytes&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Copies a non-overlapping block of memory.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>DestPtr</em>&nbsp;</td><td>Destination address to copy data to.</td></tr>
<tr><td valign="top"></td><td valign="top"><em>SrcPtr</em>&nbsp;</td><td>Source address to copy data from.</td></tr>
<tr><td valign="top"></td><td valign="top"><em>Bytes</em>&nbsp;</td><td>Number of bytes to copy.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>The use of XENV_MEM_COPY is deprecated. Use memcpy() instead.<p>
This implemention MAY BREAK work if source and target memory area are overlapping. </dd></dl>
</div>
</div><p>
<a class="anchor" name="0d8dfe452111356b4703424441ae8101"></a><!-- doxytag: member="xenv_standalone.h::XENV_MEM_FILL" ref="0d8dfe452111356b4703424441ae8101" args="(DestPtr, Data, Bytes)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_MEM_FILL </td>
<td>(</td>
<td class="paramtype">DestPtr, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">Data, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">Bytes&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Fills an area of memory with constant data.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>DestPtr</em>&nbsp;</td><td>Destination address to copy data to.</td></tr>
<tr><td valign="top"></td><td valign="top"><em>Data</em>&nbsp;</td><td>Value to set.</td></tr>
<tr><td valign="top"></td><td valign="top"><em>Bytes</em>&nbsp;</td><td>Number of bytes to copy.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>The use of XENV_MEM_FILL is deprecated. Use memset() instead. </dd></dl>
</div>
</div><p>
<a class="anchor" name="fd056d3e6807f31827018bd78df00b53"></a><!-- doxytag: member="xenv_standalone.h::XENV_TIME_STAMP_DELTA_MS" ref="fd056d3e6807f31827018bd78df00b53" args="(Stamp1Ptr, Stamp2Ptr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_TIME_STAMP_DELTA_MS </td>
<td>(</td>
<td class="paramtype">Stamp1Ptr, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">Stamp2Ptr&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This macro is not yet implemented and always returns 0.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>Stamp1Ptr</em>&nbsp;</td><td>is the first sampled time stamp. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Stamp2Ptr</em>&nbsp;</td><td>is the second sampled time stamp.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>0</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
This macro must be implemented by the user.
</div>
</div><p>
<a class="anchor" name="1a080520bc88e99f438a03a7fee6a061"></a><!-- doxytag: member="xenv_standalone.h::XENV_TIME_STAMP_DELTA_US" ref="1a080520bc88e99f438a03a7fee6a061" args="(Stamp1Ptr, Stamp2Ptr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_TIME_STAMP_DELTA_US </td>
<td>(</td>
<td class="paramtype">Stamp1Ptr, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">Stamp2Ptr&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This macro is not yet implemented and always returns 0.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>Stamp1Ptr</em>&nbsp;</td><td>is the first sampled time stamp. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Stamp2Ptr</em>&nbsp;</td><td>is the second sampled time stamp.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>0</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
This macro must be implemented by the user.
</div>
</div><p>
<a class="anchor" name="b29cb639eed7d2baf1a3d87744260df1"></a><!-- doxytag: member="xenv_standalone.h::XENV_TIME_STAMP_GET" ref="b29cb639eed7d2baf1a3d87744260df1" args="(StampPtr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_TIME_STAMP_GET </td>
<td>(</td>
<td class="paramtype">StampPtr&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Time is derived from the 64 bit PPC timebase register<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>StampPtr</em>&nbsp;</td><td>is the storage for the retrieved time stamp.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
Signature: void <a class="el" href="xenv__vxworks_8h.html#b29cb639eed7d2baf1a3d87744260df1">XENV_TIME_STAMP_GET(XTIME_STAMP *StampPtr)</a> <br>
<br>
This macro must be implemented by the user.
</div>
</div><p>
<a class="anchor" name="b5bf353013ce12567b705a2123efd198"></a><!-- doxytag: member="xenv_standalone.h::XENV_USLEEP" ref="b5bf353013ce12567b705a2123efd198" args="(delay)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_USLEEP </td>
<td>(</td>
<td class="paramtype">delay&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<a class="el" href="xenv__vxworks_8h.html#b5bf353013ce12567b705a2123efd198">XENV_USLEEP(unsigned delay)</a><p>
Delay the specified number of microseconds. Not implemented without OS support.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>delay</em>&nbsp;</td><td>Number of microseconds to delay.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<hr><h2>Typedef Documentation</h2>
<a class="anchor" name="e6b941709f64b60384a60ebd4cb12957"></a><!-- doxytag: member="xenv_standalone.h::XENV_TIME_STAMP" ref="e6b941709f64b60384a60ebd4cb12957" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef int <a class="el" href="struct_x_e_n_v___t_i_m_e___s_t_a_m_p.html">XENV_TIME_STAMP</a> </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
A structure that contains a time stamp used by other time stamp macros defined below. This structure is processor dependent.
</div>
</div><p>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,257 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: xenv_vxworks.h File Reference
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<h1>xenv_vxworks.h File Reference</h1><hr><a name="_details"></a><h2>Detailed Description</h2>
Defines common services specified by <a class="el" href="xenv_8h.html">xenv.h</a>.<p>
<dl compact><dt><b>Note:</b></dt><dd>This file is not intended to be included directly by driver code. Instead, the generic <a class="el" href="xenv_8h.html">xenv.h</a> file is intended to be included by driver code.</dd></dl>
<pre>
MODIFICATION HISTORY:</pre><p>
<pre> Ver Who Date Changes
----- ---- -------- -----------------------------------------------
1.00a wgr 02/28/07 Added cache handling macros.
1.00a wgr 02/27/07 Simplified code. Deprecated old-style macro names.
1.00a xd 11/03/04 Improved support for doxygen.
rmm 09/13/03 CR 177068: Fix compiler warning in XENV_MEM_FILL
rmm 10/24/02 Added XENV_USLEEP macro
1.00a rmm 07/16/01 First release
1.10a wgr 03/22/07 Converted to new coding style.
</pre>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Structures</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_x_e_n_v___t_i_m_e___s_t_a_m_p.html">XENV_TIME_STAMP</a></td></tr>
<tr><td colspan="2"><br><h2>Defines</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__vxworks_8h.html#aa4d213e22a5ede5b7099ab34ff79d38">XENV_MEM_COPY</a>(DestPtr, SrcPtr, Bytes)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__vxworks_8h.html#0d8dfe452111356b4703424441ae8101">XENV_MEM_FILL</a>(DestPtr, Data, Bytes)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__vxworks_8h.html#b29cb639eed7d2baf1a3d87744260df1">XENV_TIME_STAMP_GET</a>(StampPtr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__vxworks_8h.html#1a080520bc88e99f438a03a7fee6a061">XENV_TIME_STAMP_DELTA_US</a>(Stamp1Ptr, Stamp2Ptr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__vxworks_8h.html#fd056d3e6807f31827018bd78df00b53">XENV_TIME_STAMP_DELTA_MS</a>(Stamp1Ptr, Stamp2Ptr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xenv__vxworks_8h.html#b5bf353013ce12567b705a2123efd198">XENV_USLEEP</a>(delay)</td></tr>
</table>
<hr><h2>Define Documentation</h2>
<a class="anchor" name="aa4d213e22a5ede5b7099ab34ff79d38"></a><!-- doxytag: member="xenv_vxworks.h::XENV_MEM_COPY" ref="aa4d213e22a5ede5b7099ab34ff79d38" args="(DestPtr, SrcPtr, Bytes)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_MEM_COPY </td>
<td>(</td>
<td class="paramtype">DestPtr, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">SrcPtr, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">Bytes&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Copies a non-overlapping block of memory.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>DestPtr</em>&nbsp;</td><td>Destination address to copy data to.</td></tr>
<tr><td valign="top"></td><td valign="top"><em>SrcPtr</em>&nbsp;</td><td>Source address to copy data from.</td></tr>
<tr><td valign="top"></td><td valign="top"><em>Bytes</em>&nbsp;</td><td>Number of bytes to copy.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>XENV_MEM_COPY is deprecated. Use memcpy() instead. </dd></dl>
</div>
</div><p>
<a class="anchor" name="0d8dfe452111356b4703424441ae8101"></a><!-- doxytag: member="xenv_vxworks.h::XENV_MEM_FILL" ref="0d8dfe452111356b4703424441ae8101" args="(DestPtr, Data, Bytes)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_MEM_FILL </td>
<td>(</td>
<td class="paramtype">DestPtr, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">Data, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">Bytes&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Fills an area of memory with constant data.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>DestPtr</em>&nbsp;</td><td>Destination address to copy data to.</td></tr>
<tr><td valign="top"></td><td valign="top"><em>Data</em>&nbsp;</td><td>Value to set.</td></tr>
<tr><td valign="top"></td><td valign="top"><em>Bytes</em>&nbsp;</td><td>Number of bytes to copy.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>XENV_MEM_FILL is deprecated. Use memset() instead. </dd></dl>
</div>
</div><p>
<a class="anchor" name="fd056d3e6807f31827018bd78df00b53"></a><!-- doxytag: member="xenv_vxworks.h::XENV_TIME_STAMP_DELTA_MS" ref="fd056d3e6807f31827018bd78df00b53" args="(Stamp1Ptr, Stamp2Ptr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_TIME_STAMP_DELTA_MS </td>
<td>(</td>
<td class="paramtype">Stamp1Ptr, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">Stamp2Ptr&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This macro is not yet implemented and always returns 0.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>Stamp1Ptr</em>&nbsp;</td><td>is the first sampled time stamp. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Stamp2Ptr</em>&nbsp;</td><td>is the second sampled time stamp.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>0</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
None.
</div>
</div><p>
<a class="anchor" name="1a080520bc88e99f438a03a7fee6a061"></a><!-- doxytag: member="xenv_vxworks.h::XENV_TIME_STAMP_DELTA_US" ref="1a080520bc88e99f438a03a7fee6a061" args="(Stamp1Ptr, Stamp2Ptr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_TIME_STAMP_DELTA_US </td>
<td>(</td>
<td class="paramtype">Stamp1Ptr, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">Stamp2Ptr&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
This macro is not yet implemented and always returns 0.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>Stamp1Ptr</em>&nbsp;</td><td>is the first sampled time stamp. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Stamp2Ptr</em>&nbsp;</td><td>is the second sampled time stamp.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>0</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<a class="anchor" name="b29cb639eed7d2baf1a3d87744260df1"></a><!-- doxytag: member="xenv_vxworks.h::XENV_TIME_STAMP_GET" ref="b29cb639eed7d2baf1a3d87744260df1" args="(StampPtr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_TIME_STAMP_GET </td>
<td>(</td>
<td class="paramtype">StampPtr&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Time is derived from the 64 bit PPC timebase register<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>StampPtr</em>&nbsp;</td><td>is the storage for the retrieved time stamp.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
Signature: void <a class="el" href="xenv__vxworks_8h.html#b29cb639eed7d2baf1a3d87744260df1">XENV_TIME_STAMP_GET(XTIME_STAMP *StampPtr)</a>
</div>
</div><p>
<a class="anchor" name="b5bf353013ce12567b705a2123efd198"></a><!-- doxytag: member="xenv_vxworks.h::XENV_USLEEP" ref="b5bf353013ce12567b705a2123efd198" args="(delay)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XENV_USLEEP </td>
<td>(</td>
<td class="paramtype">delay&nbsp;</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Delay the specified number of microseconds.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>delay</em>&nbsp;</td><td>Number of microseconds to delay.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,37 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: xparameters.h File Reference
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<h1>xparameters.h File Reference</h1><hr><a name="_details"></a><h2>Detailed Description</h2>
This file contains system parameters for the Xilinx device driver environment. It is a representation of the system in that it contains the number of each device in the system as well as the parameters and memory map for each device. The user can view this file to obtain a summary of the devices in their system and the device parameters.<p>
This file may be automatically generated by a design tool such as System Generator.
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
</table>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,36 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: xstatus.h File Reference
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<h1>xstatus.h File Reference</h1><hr><a name="_details"></a><h2>Detailed Description</h2>
This file contains Xilinx software status codes. Status codes have their own data type called int. These codes are used throughout the Xilinx device drivers.
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
</table>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,271 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: xutil.h File Reference
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<h1>xutil.h File Reference</h1><hr><a name="_details"></a><h2>Detailed Description</h2>
This file contains utility functions such as memory test functions.<p>
<b>Memory test description</b><p>
A subset of the memory tests can be selected or all of the tests can be run in order. If there is an error detected by a subtest, the test stops and the failure code is returned. Further tests are not run even if all of the tests are selected.<p>
Subtest descriptions: <pre>
XUT_ALLMEMTESTS:
Runs all of the following tests</pre><p>
<pre> XUT_INCREMENT:
Incrementing Value Test.
This test starts at 'XUT_MEMTEST_INIT_VALUE' and uses the incrementing
value as the test value for memory.</pre><p>
<pre> XUT_WALKONES:
Walking Ones Test.
This test uses a walking '1' as the test value for memory.
location 1 = 0x00000001
location 2 = 0x00000002
...</pre><p>
<pre> XUT_WALKZEROS:
Walking Zero's Test.
This test uses the inverse value of the walking ones test
as the test value for memory.
location 1 = 0xFFFFFFFE
location 2 = 0xFFFFFFFD
...</pre><p>
<pre> XUT_INVERSEADDR:
Inverse Address Test.
This test uses the inverse of the address of the location under test
as the test value for memory.</pre><p>
<pre> XUT_FIXEDPATTERN:
Fixed Pattern Test.
This test uses the provided patters as the test value for memory.
If zero is provided as the pattern the test uses '0xDEADBEEF".
</pre><p>
<em>WARNING</em><p>
The tests are <b>DESTRUCTIVE</b>. Run before any initialized memory spaces have been set up.<p>
The address, Addr, provided to the memory tests is not checked for validity except for the NULL case. It is possible to provide a code-space pointer for this test to start with and ultimately destroy executable code causing random failures.<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
Used for spaces where the address range of the region is smaller than the data width. If the memory range is greater than 2 ** width, the patterns used in XUT_WALKONES and XUT_WALKZEROS will repeat on a boundry of a power of two making it more difficult to detect addressing errors. The XUT_INCREMENT and XUT_INVERSEADDR tests suffer the same problem. Ideally, if large blocks of memory are to be tested, break them up into smaller regions of memory to allow the test patterns used not to repeat over the region tested.<p>
<pre>
MODIFICATION HISTORY:</pre><p>
<pre> Ver Who Date Changes
----- ---- -------- -----------------------------------------------
1.00a ecm 11/01/01 First release
1.00a xd 11/03/04 Improved support for doxygen.
</pre>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Memory subtests</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xutil_8h.html#611891b0e5c78d9849169a8ed9b37457">XUT_ALLMEMTESTS</a></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xutil_8h.html#100d836b52f019cb2778dde05b8d5f9d">XUtil_MemoryTest32</a> (u32 *Addr, u32 Words, u32 Pattern, u8 Subtest)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xutil_8h.html#3fa3b8c52b52a5d3bde1830f15d4242b">XUtil_MemoryTest16</a> (u16 *Addr, u32 Words, u16 Pattern, u8 Subtest)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xutil_8h.html#c823123744399391209d230c658e9bbc">XUtil_MemoryTest8</a> (u8 *Addr, u32 Words, u8 Pattern, u8 Subtest)</td></tr>
</table>
<hr><h2>Define Documentation</h2>
<a class="anchor" name="611891b0e5c78d9849169a8ed9b37457"></a><!-- doxytag: member="xutil.h::XUT_ALLMEMTESTS" ref="611891b0e5c78d9849169a8ed9b37457" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define XUT_ALLMEMTESTS </td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
See the detailed description of the subtests in the file description.
</div>
</div><p>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="3fa3b8c52b52a5d3bde1830f15d4242b"></a><!-- doxytag: member="xutil.h::XUtil_MemoryTest16" ref="3fa3b8c52b52a5d3bde1830f15d4242b" args="(u16 *Addr, u32 Words, u16 Pattern, u8 Subtest)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int XUtil_MemoryTest16 </td>
<td>(</td>
<td class="paramtype">u16 *&nbsp;</td>
<td class="paramname"> <em>Addr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u32&nbsp;</td>
<td class="paramname"> <em>Words</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u16&nbsp;</td>
<td class="paramname"> <em>Pattern</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u8&nbsp;</td>
<td class="paramname"> <em>Subtest</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Performs a destructive 16-bit wide memory test.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>Addr</em>&nbsp;</td><td>is a pointer to the region of memory to be tested. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Words</em>&nbsp;</td><td>is the length of the block. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Pattern</em>&nbsp;</td><td>is the constant used for the constant pattern test, if 0, 0xDEADBEEF is used. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Subtest</em>&nbsp;</td><td>is the test selected. See <a class="el" href="xutil_8h.html">xutil.h</a> for possible values.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd></dd></dl>
<ul>
<li>XST_MEMTEST_FAILED is returned for a failure</li><li>XST_SUCCESS is returned for a pass</li></ul>
<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
Used for spaces where the address range of the region is smaller than the data width. If the memory range is greater than 2 ** width, the patterns used in XUT_WALKONES and XUT_WALKZEROS will repeat on a boundry of a power of two making it more difficult to detect addressing errors. The XUT_INCREMENT and XUT_INVERSEADDR tests suffer the same problem. Ideally, if large blocks of memory are to be tested, break them up into smaller regions of memory to allow the test patterns used not to repeat over the region tested.
</div>
</div><p>
<a class="anchor" name="100d836b52f019cb2778dde05b8d5f9d"></a><!-- doxytag: member="xutil.h::XUtil_MemoryTest32" ref="100d836b52f019cb2778dde05b8d5f9d" args="(u32 *Addr, u32 Words, u32 Pattern, u8 Subtest)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int XUtil_MemoryTest32 </td>
<td>(</td>
<td class="paramtype">u32 *&nbsp;</td>
<td class="paramname"> <em>Addr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u32&nbsp;</td>
<td class="paramname"> <em>Words</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u32&nbsp;</td>
<td class="paramname"> <em>Pattern</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u8&nbsp;</td>
<td class="paramname"> <em>Subtest</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Performs a destructive 32-bit wide memory test.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>Addr</em>&nbsp;</td><td>is a pointer to the region of memory to be tested. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Words</em>&nbsp;</td><td>is the length of the block. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Pattern</em>&nbsp;</td><td>is the constant used for the constant pattern test, if 0, 0xDEADBEEF is used. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Subtest</em>&nbsp;</td><td>is the test selected. See <a class="el" href="xutil_8h.html">xutil.h</a> for possible values.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd></dd></dl>
<ul>
<li>XST_MEMTEST_FAILED is returned for a failure</li><li>XST_SUCCESS is returned for a pass</li></ul>
<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
Used for spaces where the address range of the region is smaller than the data width. If the memory range is greater than 2 ** width, the patterns used in XUT_WALKONES and XUT_WALKZEROS will repeat on a boundry of a power of two making it more difficult to detect addressing errors. The XUT_INCREMENT and XUT_INVERSEADDR tests suffer the same problem. Ideally, if large blocks of memory are to be tested, break them up into smaller regions of memory to allow the test patterns used not to repeat over the region tested.
</div>
</div><p>
<a class="anchor" name="c823123744399391209d230c658e9bbc"></a><!-- doxytag: member="xutil.h::XUtil_MemoryTest8" ref="c823123744399391209d230c658e9bbc" args="(u8 *Addr, u32 Words, u8 Pattern, u8 Subtest)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int XUtil_MemoryTest8 </td>
<td>(</td>
<td class="paramtype">u8 *&nbsp;</td>
<td class="paramname"> <em>Addr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u32&nbsp;</td>
<td class="paramname"> <em>Words</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u8&nbsp;</td>
<td class="paramname"> <em>Pattern</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u8&nbsp;</td>
<td class="paramname"> <em>Subtest</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Performs a destructive 8-bit wide memory test.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>Addr</em>&nbsp;</td><td>is a pointer to the region of memory to be tested. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Words</em>&nbsp;</td><td>is the length of the block. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Pattern</em>&nbsp;</td><td>is the constant used for the constant pattern test, if 0, 0xDEADBEEF is used. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Subtest</em>&nbsp;</td><td>is the test selected. See <a class="el" href="xutil_8h.html">xutil.h</a> for possible values.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd></dd></dl>
<ul>
<li>XST_MEMTEST_FAILED is returned for a failure</li><li>XST_SUCCESS is returned for a pass</li></ul>
<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
Used for spaces where the address range of the region is smaller than the data width. If the memory range is greater than 2 ** width, the patterns used in XUT_WALKONES and XUT_WALKZEROS will repeat on a boundry of a power of two making it more difficult to detect addressing errors. The XUT_INCREMENT and XUT_INVERSEADDR tests suffer the same problem. Ideally, if large blocks of memory are to be tested, break them up into smaller regions of memory to allow the test patterns used not to repeat over the region tested.
</div>
</div><p>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,216 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: xutil_memtest.c File Reference
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<h1>xutil_memtest.c File Reference</h1><hr><a name="_details"></a><h2>Detailed Description</h2>
Contains the memory test utility functions.<p>
<pre>
MODIFICATION HISTORY:</pre><p>
<pre> Ver Who Date Changes
----- ---- -------- -----------------------------------------------
1.00a ecm 11/01/01 First release
1.00a xd 11/03/04 Improved support for doxygen.
</pre>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xutil__memtest_8c.html#100d836b52f019cb2778dde05b8d5f9d">XUtil_MemoryTest32</a> (u32 *Addr, u32 Words, u32 Pattern, u8 Subtest)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xutil__memtest_8c.html#3fa3b8c52b52a5d3bde1830f15d4242b">XUtil_MemoryTest16</a> (u16 *Addr, u32 Words, u16 Pattern, u8 Subtest)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xutil__memtest_8c.html#c823123744399391209d230c658e9bbc">XUtil_MemoryTest8</a> (u8 *Addr, u32 Words, u8 Pattern, u8 Subtest)</td></tr>
</table>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="3fa3b8c52b52a5d3bde1830f15d4242b"></a><!-- doxytag: member="xutil_memtest.c::XUtil_MemoryTest16" ref="3fa3b8c52b52a5d3bde1830f15d4242b" args="(u16 *Addr, u32 Words, u16 Pattern, u8 Subtest)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int XUtil_MemoryTest16 </td>
<td>(</td>
<td class="paramtype">u16 *&nbsp;</td>
<td class="paramname"> <em>Addr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u32&nbsp;</td>
<td class="paramname"> <em>Words</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u16&nbsp;</td>
<td class="paramname"> <em>Pattern</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u8&nbsp;</td>
<td class="paramname"> <em>Subtest</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Performs a destructive 16-bit wide memory test.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>Addr</em>&nbsp;</td><td>is a pointer to the region of memory to be tested. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Words</em>&nbsp;</td><td>is the length of the block. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Pattern</em>&nbsp;</td><td>is the constant used for the constant pattern test, if 0, 0xDEADBEEF is used. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Subtest</em>&nbsp;</td><td>is the test selected. See <a class="el" href="xutil_8h.html">xutil.h</a> for possible values.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd></dd></dl>
<ul>
<li>XST_MEMTEST_FAILED is returned for a failure</li><li>XST_SUCCESS is returned for a pass</li></ul>
<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
Used for spaces where the address range of the region is smaller than the data width. If the memory range is greater than 2 ** width, the patterns used in XUT_WALKONES and XUT_WALKZEROS will repeat on a boundry of a power of two making it more difficult to detect addressing errors. The XUT_INCREMENT and XUT_INVERSEADDR tests suffer the same problem. Ideally, if large blocks of memory are to be tested, break them up into smaller regions of memory to allow the test patterns used not to repeat over the region tested.
</div>
</div><p>
<a class="anchor" name="100d836b52f019cb2778dde05b8d5f9d"></a><!-- doxytag: member="xutil_memtest.c::XUtil_MemoryTest32" ref="100d836b52f019cb2778dde05b8d5f9d" args="(u32 *Addr, u32 Words, u32 Pattern, u8 Subtest)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int XUtil_MemoryTest32 </td>
<td>(</td>
<td class="paramtype">u32 *&nbsp;</td>
<td class="paramname"> <em>Addr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u32&nbsp;</td>
<td class="paramname"> <em>Words</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u32&nbsp;</td>
<td class="paramname"> <em>Pattern</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u8&nbsp;</td>
<td class="paramname"> <em>Subtest</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Performs a destructive 32-bit wide memory test.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>Addr</em>&nbsp;</td><td>is a pointer to the region of memory to be tested. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Words</em>&nbsp;</td><td>is the length of the block. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Pattern</em>&nbsp;</td><td>is the constant used for the constant pattern test, if 0, 0xDEADBEEF is used. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Subtest</em>&nbsp;</td><td>is the test selected. See <a class="el" href="xutil_8h.html">xutil.h</a> for possible values.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd></dd></dl>
<ul>
<li>XST_MEMTEST_FAILED is returned for a failure</li><li>XST_SUCCESS is returned for a pass</li></ul>
<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
Used for spaces where the address range of the region is smaller than the data width. If the memory range is greater than 2 ** width, the patterns used in XUT_WALKONES and XUT_WALKZEROS will repeat on a boundry of a power of two making it more difficult to detect addressing errors. The XUT_INCREMENT and XUT_INVERSEADDR tests suffer the same problem. Ideally, if large blocks of memory are to be tested, break them up into smaller regions of memory to allow the test patterns used not to repeat over the region tested.
</div>
</div><p>
<a class="anchor" name="c823123744399391209d230c658e9bbc"></a><!-- doxytag: member="xutil_memtest.c::XUtil_MemoryTest8" ref="c823123744399391209d230c658e9bbc" args="(u8 *Addr, u32 Words, u8 Pattern, u8 Subtest)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int XUtil_MemoryTest8 </td>
<td>(</td>
<td class="paramtype">u8 *&nbsp;</td>
<td class="paramname"> <em>Addr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u32&nbsp;</td>
<td class="paramname"> <em>Words</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u8&nbsp;</td>
<td class="paramname"> <em>Pattern</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u8&nbsp;</td>
<td class="paramname"> <em>Subtest</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Performs a destructive 8-bit wide memory test.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>Addr</em>&nbsp;</td><td>is a pointer to the region of memory to be tested. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Words</em>&nbsp;</td><td>is the length of the block. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Pattern</em>&nbsp;</td><td>is the constant used for the constant pattern test, if 0, 0xDEADBEEF is used. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>Subtest</em>&nbsp;</td><td>is the test selected. See <a class="el" href="xutil_8h.html">xutil.h</a> for possible values.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd></dd></dl>
<ul>
<li>XST_MEMTEST_FAILED is returned for a failure</li><li>XST_SUCCESS is returned for a pass</li></ul>
<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
Used for spaces where the address range of the region is smaller than the data width. If the memory range is greater than 2 ** width, the patterns used in XUT_WALKONES and XUT_WALKZEROS will repeat on a boundry of a power of two making it more difficult to detect addressing errors. The XUT_INCREMENT and XUT_INVERSEADDR tests suffer the same problem. Ideally, if large blocks of memory are to be tested, break them up into smaller regions of memory to allow the test patterns used not to repeat over the region tested.
</div>
</div><p>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,297 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: xversion.c File Reference
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<h1>xversion.c File Reference</h1><hr><a name="_details"></a><h2>Detailed Description</h2>
This file contains the implementation of the XVersion component. This component represents a version ID. It is encapsulated within a component so that it's type and implementation can change without affecting users of it.<p>
The version is formatted as X.YYZ where X = 0 - 9, Y = 00 - 99, Z = a - z X is the major revision, YY is the minor revision, and Z is the compatability revision.<p>
Packed versions are also utilized for the configuration ROM such that memory is minimized. A packed version consumes only 16 bits and is formatted as follows.<p>
<pre>
Revision Range Bit Positions</pre><p>
<pre> Major Revision 0 - 9 Bits 15 - 12
Minor Revision 0 - 99 Bits 11 - 5
Compatability Revision a - z Bits 4 - 0</pre><p>
<pre> MODIFICATION HISTORY:</pre><p>
<pre> Ver Who Date Changes
----- ---- -------- -------------------------------------------------------
1.00a xd 11/03/04 Improved support for doxygen.
</pre>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xversion_8c.html#83e7589d43e80a3c55f89d437bf72cee">XVersion_UnPack</a> (XVersion *InstancePtr, u16 PackedVersion)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xversion_8c.html#c899b60e44960582459c9b83e1e68095">XVersion_Pack</a> (XVersion *InstancePtr, u16 *PackedVersionPtr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xversion_8c.html#a60d242fb47a09b74d9273048938bc40">XVersion_IsEqual</a> (XVersion *InstancePtr, XVersion *VersionPtr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xversion_8c.html#5509d59e756d51585c81b132cae02935">XVersion_ToString</a> (XVersion *InstancePtr, char *StringPtr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xversion_8c.html#22fd522b3e13c6512573a164b1a41d6e">XVersion_FromString</a> (XVersion *InstancePtr, char *StringPtr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xversion_8c.html#c6dc2f6cf4c2da3f6588eef8387d3b71">XVersion_Copy</a> (XVersion *InstancePtr, XVersion *VersionPtr)</td></tr>
</table>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="c6dc2f6cf4c2da3f6588eef8387d3b71"></a><!-- doxytag: member="xversion.c::XVersion_Copy" ref="c6dc2f6cf4c2da3f6588eef8387d3b71" args="(XVersion *InstancePtr, XVersion *VersionPtr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void XVersion_Copy </td>
<td>(</td>
<td class="paramtype">XVersion *&nbsp;</td>
<td class="paramname"> <em>InstancePtr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">XVersion *&nbsp;</td>
<td class="paramname"> <em>VersionPtr</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Copies the contents of a version to another version.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>InstancePtr</em>&nbsp;</td><td>points to the version which is the source of data for the copy operation. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>VersionPtr</em>&nbsp;</td><td>points to another version which is the destination of the copy operation.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd></dd></dl>
None.<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
None.
</div>
</div><p>
<a class="anchor" name="22fd522b3e13c6512573a164b1a41d6e"></a><!-- doxytag: member="xversion.c::XVersion_FromString" ref="22fd522b3e13c6512573a164b1a41d6e" args="(XVersion *InstancePtr, char *StringPtr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int XVersion_FromString </td>
<td>(</td>
<td class="paramtype">XVersion *&nbsp;</td>
<td class="paramname"> <em>InstancePtr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">char *&nbsp;</td>
<td class="paramname"> <em>StringPtr</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Initializes a version from a null terminated string. Since the string may not be a format which is compatible with the version, an error could occur.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>InstancePtr</em>&nbsp;</td><td>points to the version which is to be initialized. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>StringPtr</em>&nbsp;</td><td>points to a null terminated string which will be converted to a version. The format of the string must match the version string format which is X.YYX where X = 0 - 9, YY = 00 - 99, Z = a - z.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd></dd></dl>
A status, XST_SUCCESS, indicating the conversion was accomplished successfully, or XST_INVALID_VERSION indicating the version string format was not valid.<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
None.
</div>
</div><p>
<a class="anchor" name="a60d242fb47a09b74d9273048938bc40"></a><!-- doxytag: member="xversion.c::XVersion_IsEqual" ref="a60d242fb47a09b74d9273048938bc40" args="(XVersion *InstancePtr, XVersion *VersionPtr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int XVersion_IsEqual </td>
<td>(</td>
<td class="paramtype">XVersion *&nbsp;</td>
<td class="paramname"> <em>InstancePtr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">XVersion *&nbsp;</td>
<td class="paramname"> <em>VersionPtr</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Determines if two versions are equal.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>InstancePtr</em>&nbsp;</td><td>points to the first version to be compared. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>VersionPtr</em>&nbsp;</td><td>points to a second version to be compared.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd></dd></dl>
TRUE if the versions are equal, FALSE otherwise.<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
None.
</div>
</div><p>
<a class="anchor" name="c899b60e44960582459c9b83e1e68095"></a><!-- doxytag: member="xversion.c::XVersion_Pack" ref="c899b60e44960582459c9b83e1e68095" args="(XVersion *InstancePtr, u16 *PackedVersionPtr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int XVersion_Pack </td>
<td>(</td>
<td class="paramtype">XVersion *&nbsp;</td>
<td class="paramname"> <em>InstancePtr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u16 *&nbsp;</td>
<td class="paramname"> <em>PackedVersionPtr</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Packs a version into the specified packed version. Versions are packed into the configuration ROM to reduce the amount storage.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>InstancePtr</em>&nbsp;</td><td>points to the version to pack. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>PackedVersionPtr</em>&nbsp;</td><td>points to the packed version which will receive the new packed version.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd></dd></dl>
A status, XST_SUCCESS, indicating the packing was accomplished successfully, or an error, XST_INVALID_VERSION, indicating the specified input version was not valid such that the pack did not occur <br>
<br>
The packed version pointed to by PackedVersionPtr is modified with the new packed version if the status indicates success.<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
None.
</div>
</div><p>
<a class="anchor" name="5509d59e756d51585c81b132cae02935"></a><!-- doxytag: member="xversion.c::XVersion_ToString" ref="5509d59e756d51585c81b132cae02935" args="(XVersion *InstancePtr, char *StringPtr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void XVersion_ToString </td>
<td>(</td>
<td class="paramtype">XVersion *&nbsp;</td>
<td class="paramname"> <em>InstancePtr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">char *&nbsp;</td>
<td class="paramname"> <em>StringPtr</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Converts a version to a null terminated string.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>InstancePtr</em>&nbsp;</td><td>points to the version to convert. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>StringPtr</em>&nbsp;</td><td>points to the string which will be the result of the conversion. This does not need to point to a null terminated string as an input, but must point to storage which is an adequate amount to hold the result string.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd></dd></dl>
The null terminated string is inserted at the location pointed to by StringPtr if the status indicates success.<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
It is necessary for the caller to have already allocated the storage to contain the string. The amount of memory necessary for the string is specified in the version header file.
</div>
</div><p>
<a class="anchor" name="83e7589d43e80a3c55f89d437bf72cee"></a><!-- doxytag: member="xversion.c::XVersion_UnPack" ref="83e7589d43e80a3c55f89d437bf72cee" args="(XVersion *InstancePtr, u16 PackedVersion)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void XVersion_UnPack </td>
<td>(</td>
<td class="paramtype">XVersion *&nbsp;</td>
<td class="paramname"> <em>InstancePtr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u16&nbsp;</td>
<td class="paramname"> <em>PackedVersion</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Unpacks a packed version into the specified version. Versions are packed into the configuration ROM to reduce the amount storage. A packed version is a binary format as oppossed to a non-packed version which is implemented as a string.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>InstancePtr</em>&nbsp;</td><td>points to the version to unpack the packed version into. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>PackedVersion</em>&nbsp;</td><td>contains the packed version to unpack.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,297 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>
Xilinx Driver common v1_00_a: xversion.h File Reference
</title>
<link href="../../../../../../../doc/usenglish/css/driver_api_doxygen.css" rel="stylesheet" type="text/css">
</head>
<h3 class="PageHeader">Xilinx Processor IP Library</h3>
<hl>Software Drivers</hl>
<hr class="whs1">
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<h1>xversion.h File Reference</h1><hr><a name="_details"></a><h2>Detailed Description</h2>
This file contains the interface for the XVersion component. This component represents a version ID. It is encapsulated within a component so that it's type and implementation can change without affecting users of it.<p>
The version is formatted as X.YYZ where X = 0 - 9, Y = 00 - 99, Z = a - z X is the major revision, YY is the minor revision, and Z is the compatability revision.<p>
Packed versions are also utilized for the configuration ROM such that memory is minimized. A packed version consumes only 16 bits and is formatted as follows.<p>
<pre>
Revision Range Bit Positions</pre><p>
<pre> Major Revision 0 - 9 Bits 15 - 12
Minor Revision 0 - 99 Bits 11 - 5
Compatability Revision a - z Bits 4 - 0</pre><p>
<pre> MODIFICATION HISTORY:</pre><p>
<pre> Ver Who Date Changes
----- ---- -------- -------------------------------------------------------
1.00a xd 11/03/04 Improved support for doxygen.
</pre>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xversion_8h.html#83e7589d43e80a3c55f89d437bf72cee">XVersion_UnPack</a> (XVersion *InstancePtr, u16 PackedVersion)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xversion_8h.html#5cf6f72f47d99df8141526aa6e9090b2">XVersion_Pack</a> (XVersion *InstancePtr, u16 *PackedVersion)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xversion_8h.html#a60d242fb47a09b74d9273048938bc40">XVersion_IsEqual</a> (XVersion *InstancePtr, XVersion *VersionPtr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xversion_8h.html#5509d59e756d51585c81b132cae02935">XVersion_ToString</a> (XVersion *InstancePtr, char *StringPtr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xversion_8h.html#22fd522b3e13c6512573a164b1a41d6e">XVersion_FromString</a> (XVersion *InstancePtr, char *StringPtr)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xversion_8h.html#c6dc2f6cf4c2da3f6588eef8387d3b71">XVersion_Copy</a> (XVersion *InstancePtr, XVersion *VersionPtr)</td></tr>
</table>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="c6dc2f6cf4c2da3f6588eef8387d3b71"></a><!-- doxytag: member="xversion.h::XVersion_Copy" ref="c6dc2f6cf4c2da3f6588eef8387d3b71" args="(XVersion *InstancePtr, XVersion *VersionPtr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void XVersion_Copy </td>
<td>(</td>
<td class="paramtype">XVersion *&nbsp;</td>
<td class="paramname"> <em>InstancePtr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">XVersion *&nbsp;</td>
<td class="paramname"> <em>VersionPtr</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Copies the contents of a version to another version.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>InstancePtr</em>&nbsp;</td><td>points to the version which is the source of data for the copy operation. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>VersionPtr</em>&nbsp;</td><td>points to another version which is the destination of the copy operation.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd></dd></dl>
None.<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
None.
</div>
</div><p>
<a class="anchor" name="22fd522b3e13c6512573a164b1a41d6e"></a><!-- doxytag: member="xversion.h::XVersion_FromString" ref="22fd522b3e13c6512573a164b1a41d6e" args="(XVersion *InstancePtr, char *StringPtr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int XVersion_FromString </td>
<td>(</td>
<td class="paramtype">XVersion *&nbsp;</td>
<td class="paramname"> <em>InstancePtr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">char *&nbsp;</td>
<td class="paramname"> <em>StringPtr</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Initializes a version from a null terminated string. Since the string may not be a format which is compatible with the version, an error could occur.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>InstancePtr</em>&nbsp;</td><td>points to the version which is to be initialized. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>StringPtr</em>&nbsp;</td><td>points to a null terminated string which will be converted to a version. The format of the string must match the version string format which is X.YYX where X = 0 - 9, YY = 00 - 99, Z = a - z.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd></dd></dl>
A status, XST_SUCCESS, indicating the conversion was accomplished successfully, or XST_INVALID_VERSION indicating the version string format was not valid.<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
None.
</div>
</div><p>
<a class="anchor" name="a60d242fb47a09b74d9273048938bc40"></a><!-- doxytag: member="xversion.h::XVersion_IsEqual" ref="a60d242fb47a09b74d9273048938bc40" args="(XVersion *InstancePtr, XVersion *VersionPtr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int XVersion_IsEqual </td>
<td>(</td>
<td class="paramtype">XVersion *&nbsp;</td>
<td class="paramname"> <em>InstancePtr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">XVersion *&nbsp;</td>
<td class="paramname"> <em>VersionPtr</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Determines if two versions are equal.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>InstancePtr</em>&nbsp;</td><td>points to the first version to be compared. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>VersionPtr</em>&nbsp;</td><td>points to a second version to be compared.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd></dd></dl>
TRUE if the versions are equal, FALSE otherwise.<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
None.
</div>
</div><p>
<a class="anchor" name="5cf6f72f47d99df8141526aa6e9090b2"></a><!-- doxytag: member="xversion.h::XVersion_Pack" ref="5cf6f72f47d99df8141526aa6e9090b2" args="(XVersion *InstancePtr, u16 *PackedVersion)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int XVersion_Pack </td>
<td>(</td>
<td class="paramtype">XVersion *&nbsp;</td>
<td class="paramname"> <em>InstancePtr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u16 *&nbsp;</td>
<td class="paramname"> <em>PackedVersionPtr</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Packs a version into the specified packed version. Versions are packed into the configuration ROM to reduce the amount storage.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>InstancePtr</em>&nbsp;</td><td>points to the version to pack. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>PackedVersionPtr</em>&nbsp;</td><td>points to the packed version which will receive the new packed version.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd></dd></dl>
A status, XST_SUCCESS, indicating the packing was accomplished successfully, or an error, XST_INVALID_VERSION, indicating the specified input version was not valid such that the pack did not occur <br>
<br>
The packed version pointed to by PackedVersionPtr is modified with the new packed version if the status indicates success.<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
None.
</div>
</div><p>
<a class="anchor" name="5509d59e756d51585c81b132cae02935"></a><!-- doxytag: member="xversion.h::XVersion_ToString" ref="5509d59e756d51585c81b132cae02935" args="(XVersion *InstancePtr, char *StringPtr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void XVersion_ToString </td>
<td>(</td>
<td class="paramtype">XVersion *&nbsp;</td>
<td class="paramname"> <em>InstancePtr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">char *&nbsp;</td>
<td class="paramname"> <em>StringPtr</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Converts a version to a null terminated string.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>InstancePtr</em>&nbsp;</td><td>points to the version to convert. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>StringPtr</em>&nbsp;</td><td>points to the string which will be the result of the conversion. This does not need to point to a null terminated string as an input, but must point to storage which is an adequate amount to hold the result string.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd></dd></dl>
The null terminated string is inserted at the location pointed to by StringPtr if the status indicates success.<p>
<dl compact><dt><b>Note:</b></dt><dd></dd></dl>
It is necessary for the caller to have already allocated the storage to contain the string. The amount of memory necessary for the string is specified in the version header file.
</div>
</div><p>
<a class="anchor" name="83e7589d43e80a3c55f89d437bf72cee"></a><!-- doxytag: member="xversion.h::XVersion_UnPack" ref="83e7589d43e80a3c55f89d437bf72cee" args="(XVersion *InstancePtr, u16 PackedVersion)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void XVersion_UnPack </td>
<td>(</td>
<td class="paramtype">XVersion *&nbsp;</td>
<td class="paramname"> <em>InstancePtr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">u16&nbsp;</td>
<td class="paramname"> <em>PackedVersion</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Unpacks a packed version into the specified version. Versions are packed into the configuration ROM to reduce the amount storage. A packed version is a binary format as oppossed to a non-packed version which is implemented as a string.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>InstancePtr</em>&nbsp;</td><td>points to the version to unpack the packed version into. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>PackedVersion</em>&nbsp;</td><td>contains the packed version to unpack.</td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>None.</dd></dl>
<dl compact><dt><b>Note:</b></dt><dd>None. </dd></dl>
</div>
</div><p>
<p class="Copyright">
Copyright &copy; 1995-2011 Xilinx, Inc. All rights reserved.
</p>
</body>
</html>

View file

@ -1,28 +0,0 @@
COMPILER=
ARCHIVER=
CP=cp
COMPILER_FLAGS=
EXTRA_COMPILER_FLAGS=
LIB=libxil.a
RELEASEDIR=../../../lib
INCLUDEDIR=../../../include
INCLUDES=-I${INCLUDEDIR}
OUTS = *.o
LIBSOURCES=*.c
INCLUDEFILES=xbasic_types.h xenv.h xenv_none.h xenv_standalone.h xenv_vxworks.h xstatus.h xutil.h xversion.h xdebug.h
libs:
echo "Compiling common"
$(COMPILER) $(COMPILER_FLAGS) $(EXTRA_COMPILER_FLAGS) $(INCLUDES) $(LIBSOURCES)
$(ARCHIVER) -r ${RELEASEDIR}/${LIB} ${OUTS}
make clean
include:
${CP} $(INCLUDEFILES) $(INCLUDEDIR)
clean:
rm -rf $(OUTS)

View file

@ -1,147 +0,0 @@
/******************************************************************************
*
* Copyright (C) 2002 - 2014 Xilinx, Inc. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* Use of the Software is limited solely to applications:
* (a) running on a Xilinx device, or
* (b) that interact with a Xilinx device through a bus or interconnect.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* XILINX BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
* OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
* Except as contained in this notice, the name of the Xilinx shall not be used
* in advertising or otherwise to promote the sale, use or other dealings in
* this Software without prior written authorization from Xilinx.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file xbasic_types.c
*
* This file contains basic functions for Xilinx software IP.
*
* <pre>
* MODIFICATION HISTORY:
*
* Ver Who Date Changes
* ----- ---- -------- -------------------------------------------------------
* 1.00a rpm 11/07/03 Added XNullHandler function as a stub interrupt handler
* 1.00a xd 11/03/04 Improved support for doxygen.
* 1.00a bss 13/01/12 Removed a compiler warning in XNullHandler;
* </pre>
*
******************************************************************************/
/***************************** Include Files *********************************/
#include "xbasic_types.h"
/************************** Constant Definitions *****************************/
/**************************** Type Definitions *******************************/
/***************** Macros (Inline Functions) Definitions *********************/
/************************** Variable Definitions *****************************/
/**
* This variable allows testing to be done easier with asserts. An assert
* sets this variable such that a driver can evaluate this variable
* to determine if an assert occurred.
*/
unsigned int XAssertStatus;
/**
* This variable allows the assert functionality to be changed for testing
* such that it does not wait infinitely. Use the debugger to disable the
* waiting during testing of asserts.
*/
int XWaitInAssert = TRUE;
/* The callback function to be invoked when an assert is taken */
static XAssertCallback XAssertCallbackRoutine = (XAssertCallback) NULL;
/************************** Function Prototypes ******************************/
/*****************************************************************************/
/**
*
* Implements assert. Currently, it calls a user-defined callback function
* if one has been set. Then, it potentially enters an infinite loop depending
* on the value of the XWaitInAssert variable.
*
* @param File is the name of the filename of the source
* @param Line is the linenumber within File
*
* @return None.
*
* @note None.
*
******************************************************************************/
void XAssert(char *File, int Line)
{
/* if the callback has been set then invoke it */
if (XAssertCallbackRoutine != NULL) {
(*XAssertCallbackRoutine) (File, Line);
}
/* if specified, wait indefinitely such that the assert will show up
* in testing
*/
while (XWaitInAssert) {
}
}
/*****************************************************************************/
/**
*
* Sets up a callback function to be invoked when an assert occurs. If there
* was already a callback installed, then it is replaced.
*
* @param Routine is the callback to be invoked when an assert is taken
*
* @return None.
*
* @note This function has no effect if NDEBUG is set
*
******************************************************************************/
void XAssertSetCallback(XAssertCallback Routine)
{
XAssertCallbackRoutine = Routine;
}
/*****************************************************************************/
/**
*
* Null handler function. This follows the XInterruptHandler signature for
* interrupt handlers. It can be used to assign a null handler (a stub) to an
* interrupt controller vector table.
*
* @param NullParameter is an arbitrary void pointer and not used.
*
* @return None.
*
* @note None.
*
******************************************************************************/
void XNullHandler(void *NullParameter)
{
(void) NullParameter;
}

View file

@ -1,310 +0,0 @@
/******************************************************************************
*
* Copyright (C) 2002 - 2014 Xilinx, Inc. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* Use of the Software is limited solely to applications:
* (a) running on a Xilinx device, or
* (b) that interact with a Xilinx device through a bus or interconnect.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* XILINX BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
* OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
* Except as contained in this notice, the name of the Xilinx shall not be used
* in advertising or otherwise to promote the sale, use or other dealings in
* this Software without prior written authorization from Xilinx.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file xbasic_types.h
*
* This file contains basic types for Xilinx software IP. These types do not
* follow the standard naming convention with respect to using the component
* name in front of each name because they are considered to be primitives.
*
* @note
*
* This file contains items which are architecture dependent.
*
* <pre>
* MODIFICATION HISTORY:
*
* Ver Who Date Changes
* ----- ---- -------- -------------------------------------------------------
* 1.00a rmm 12/14/01 First release
* rmm 05/09/03 Added "xassert always" macros to rid ourselves of diab
* compiler warnings
* 1.00a rpm 11/07/03 Added XNullHandler function as a stub interrupt handler
* 1.00a rpm 07/21/04 Added XExceptionHandler typedef for processor exceptions
* 1.00a xd 11/03/04 Improved support for doxygen.
* 1.00a wre 01/25/07 Added Linux style data types u32, u16, u8, TRUE, FALSE
* 1.00a rpm 04/02/07 Added ifndef KERNEL around u32, u16, u8 data types
* </pre>
*
******************************************************************************/
#ifndef XBASIC_TYPES_H /* prevent circular inclusions */
#define XBASIC_TYPES_H /* by using protection macros */
#ifdef __cplusplus
extern "C" {
#endif
/***************************** Include Files *********************************/
/************************** Constant Definitions *****************************/
#ifndef TRUE
# define TRUE 1
#endif
#ifndef FALSE
# define FALSE 0
#endif
#ifndef NULL
#define NULL 0
#endif
/** Xilinx NULL, TRUE and FALSE legacy support. Deprecated. */
#define XNULL NULL
#define XTRUE TRUE
#define XFALSE FALSE
#define XCOMPONENT_IS_READY 0x11111111 /**< component has been initialized */
#define XCOMPONENT_IS_STARTED 0x22222222 /**< component has been started */
/* the following constants and declarations are for unit test purposes and are
* designed to be used in test applications.
*/
#define XTEST_PASSED 0
#define XTEST_FAILED 1
#define XASSERT_NONE 0
#define XASSERT_OCCURRED 1
extern unsigned int XAssertStatus;
extern void XAssert(char *, int);
/**************************** Type Definitions *******************************/
/** @name Legacy types
* Deprecated legacy types.
* @{
*/
typedef unsigned char Xuint8; /**< unsigned 8-bit */
typedef char Xint8; /**< signed 8-bit */
typedef unsigned short Xuint16; /**< unsigned 16-bit */
typedef short Xint16; /**< signed 16-bit */
typedef unsigned long Xuint32; /**< unsigned 32-bit */
typedef long Xint32; /**< signed 32-bit */
typedef float Xfloat32; /**< 32-bit floating point */
typedef double Xfloat64; /**< 64-bit double precision FP */
typedef unsigned long Xboolean; /**< boolean (XTRUE or XFALSE) */
#if !defined __XUINT64__
typedef struct
{
Xuint32 Upper;
Xuint32 Lower;
} Xuint64;
#endif
/** @name New types
* New simple types.
* @{
*/
#ifndef __KERNEL__
#ifndef XIL_TYPES_H
typedef Xuint32 u32;
typedef Xuint16 u16;
typedef Xuint8 u8;
#endif
#else
#include <linux/types.h>
#endif
/*@}*/
/**
* This data type defines an interrupt handler for a device.
* The argument points to the instance of the component
*/
typedef void (*XInterruptHandler) (void *InstancePtr);
/**
* This data type defines an exception handler for a processor.
* The argument points to the instance of the component
*/
typedef void (*XExceptionHandler) (void *InstancePtr);
/**
* This data type defines a callback to be invoked when an
* assert occurs. The callback is invoked only when asserts are enabled
*/
typedef void (*XAssertCallback) (char *FilenamePtr, int LineNumber);
/***************** Macros (Inline Functions) Definitions *********************/
/*****************************************************************************/
/**
* Return the most significant half of the 64 bit data type.
*
* @param x is the 64 bit word.
*
* @return The upper 32 bits of the 64 bit word.
*
* @note None.
*
******************************************************************************/
#define XUINT64_MSW(x) ((x).Upper)
/*****************************************************************************/
/**
* Return the least significant half of the 64 bit data type.
*
* @param x is the 64 bit word.
*
* @return The lower 32 bits of the 64 bit word.
*
* @note None.
*
******************************************************************************/
#define XUINT64_LSW(x) ((x).Lower)
#ifndef NDEBUG
/*****************************************************************************/
/**
* This assert macro is to be used for functions that do not return anything
* (void). This in conjunction with the XWaitInAssert boolean can be used to
* accomodate tests so that asserts which fail allow execution to continue.
*
* @param expression is the expression to evaluate. If it evaluates to
* false, the assert occurs.
*
* @return Returns void unless the XWaitInAssert variable is true, in which
* case no return is made and an infinite loop is entered.
*
* @note None.
*
******************************************************************************/
#define XASSERT_VOID(expression) \
{ \
if (expression) \
{ \
XAssertStatus = XASSERT_NONE; \
} \
else \
{ \
XAssert(__FILE__, __LINE__); \
XAssertStatus = XASSERT_OCCURRED; \
return; \
} \
}
/*****************************************************************************/
/**
* This assert macro is to be used for functions that do return a value. This in
* conjunction with the XWaitInAssert boolean can be used to accomodate tests so
* that asserts which fail allow execution to continue.
*
* @param expression is the expression to evaluate. If it evaluates to false,
* the assert occurs.
*
* @return Returns 0 unless the XWaitInAssert variable is true, in which case
* no return is made and an infinite loop is entered.
*
* @note None.
*
******************************************************************************/
#define XASSERT_NONVOID(expression) \
{ \
if (expression) \
{ \
XAssertStatus = XASSERT_NONE; \
} \
else \
{ \
XAssert(__FILE__, __LINE__); \
XAssertStatus = XASSERT_OCCURRED; \
return 0; \
} \
}
/*****************************************************************************/
/**
* Always assert. This assert macro is to be used for functions that do not
* return anything (void). Use for instances where an assert should always
* occur.
*
* @return Returns void unless the XWaitInAssert variable is true, in which case
* no return is made and an infinite loop is entered.
*
* @note None.
*
******************************************************************************/
#define XASSERT_VOID_ALWAYS() \
{ \
XAssert(__FILE__, __LINE__); \
XAssertStatus = XASSERT_OCCURRED; \
return; \
}
/*****************************************************************************/
/**
* Always assert. This assert macro is to be used for functions that do return
* a value. Use for instances where an assert should always occur.
*
* @return Returns void unless the XWaitInAssert variable is true, in which case
* no return is made and an infinite loop is entered.
*
* @note None.
*
******************************************************************************/
#define XASSERT_NONVOID_ALWAYS() \
{ \
XAssert(__FILE__, __LINE__); \
XAssertStatus = XASSERT_OCCURRED; \
return 0; \
}
#else
#define XASSERT_VOID(expression)
#define XASSERT_VOID_ALWAYS()
#define XASSERT_NONVOID(expression)
#define XASSERT_NONVOID_ALWAYS()
#endif
/************************** Function Prototypes ******************************/
void XAssertSetCallback(XAssertCallback Routine);
void XNullHandler(void *NullParameter);
#ifdef __cplusplus
}
#endif
#endif /* end of protection macro */

View file

@ -1,61 +0,0 @@
#ifndef XDEBUG
#define XDEBUG
#undef DEBUG
#if defined(DEBUG) && !defined(NDEBUG)
#ifndef XDEBUG_WARNING
#define XDEBUG_WARNING
#warning DEBUG is enabled
#endif
int printf(const char *format, ...);
#define XDBG_DEBUG_ERROR 0x00000001 /* error condition messages */
#define XDBG_DEBUG_GENERAL 0x00000002 /* general debug messages */
#define XDBG_DEBUG_ALL 0xFFFFFFFF /* all debugging data */
#define XDBG_DEBUG_FIFO_REG 0x00000100 /* display register reads/writes */
#define XDBG_DEBUG_FIFO_RX 0x00000101 /* receive debug messages */
#define XDBG_DEBUG_FIFO_TX 0x00000102 /* transmit debug messages */
#define XDBG_DEBUG_FIFO_ALL 0x0000010F /* all fifo debug messages */
#define XDBG_DEBUG_TEMAC_REG 0x00000400 /* display register reads/writes */
#define XDBG_DEBUG_TEMAC_RX 0x00000401 /* receive debug messages */
#define XDBG_DEBUG_TEMAC_TX 0x00000402 /* transmit debug messages */
#define XDBG_DEBUG_TEMAC_ALL 0x0000040F /* all temac debug messages */
#define XDBG_DEBUG_TEMAC_ADPT_RX 0x00000800 /* receive debug messages */
#define XDBG_DEBUG_TEMAC_ADPT_TX 0x00000801 /* transmit debug messages */
#define XDBG_DEBUG_TEMAC_ADPT_IOCTL 0x00000802 /* ioctl debug messages */
#define XDBG_DEBUG_TEMAC_ADPT_MISC 0x00000803 /* debug msg for other routines */
#define XDBG_DEBUG_TEMAC_ADPT_ALL 0x0000080F /* all temac adapter debug messages */
#define xdbg_current_types (XDBG_DEBUG_ERROR)
#define xdbg_stmnt(x) x
/* In VxWorks, if _WRS_GNU_VAR_MACROS is defined, special syntax is needed for
* macros that accept variable number of arguments
*/
#if defined(XENV_VXWORKS) && defined(_WRS_GNU_VAR_MACROS)
#define xdbg_printf(type, args...) (((type) & xdbg_current_types) ? printf (## args) : 0)
#else /* ANSI Syntax */
#define xdbg_printf(type, ...) (((type) & xdbg_current_types) ? printf (__VA_ARGS__) : 0)
#endif
#else /* defined(DEBUG) && !defined(NDEBUG) */
#define xdbg_stmnt(x)
/* See VxWorks comments above */
#if defined(XENV_VXWORKS) && defined(_WRS_GNU_VAR_MACROS)
#define xdbg_printf(type, args...)
#else /* ANSI Syntax */
#define xdbg_printf(...)
#endif
#endif /* defined(DEBUG) && !defined(NDEBUG) */
#endif /* XDEBUG */

View file

@ -1,188 +0,0 @@
/******************************************************************************
*
* Copyright (C) 2002 - 2014 Xilinx, Inc. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* Use of the Software is limited solely to applications:
* (a) running on a Xilinx device, or
* (b) that interact with a Xilinx device through a bus or interconnect.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* XILINX BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
* OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
* Except as contained in this notice, the name of the Xilinx shall not be used
* in advertising or otherwise to promote the sale, use or other dealings in
* this Software without prior written authorization from Xilinx.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file xenv.h
*
* Defines common services that are typically found in a host operating.
* environment. This include file simply includes an OS specific file based
* on the compile-time constant BUILD_ENV_*, where * is the name of the target
* environment.
*
* All services are defined as macros.
*
* <pre>
* MODIFICATION HISTORY:
*
* Ver Who Date Changes
* ----- ---- -------- -----------------------------------------------
* 1.00b ch 10/24/02 Added XENV_LINUX
* 1.00a rmm 04/17/02 First release
* </pre>
*
******************************************************************************/
#ifndef XENV_H /* prevent circular inclusions */
#define XENV_H /* by using protection macros */
#ifdef __cplusplus
extern "C" {
#endif
/*
* Select which target environment we are operating under
*/
/* VxWorks target environment */
#if defined XENV_VXWORKS
#include "xenv_vxworks.h"
/* Linux target environment */
#elif defined XENV_LINUX
#include "xenv_linux.h"
/* Unit test environment */
#elif defined XENV_UNITTEST
#include "ut_xenv.h"
/* Integration test environment */
#elif defined XENV_INTTEST
#include "int_xenv.h"
/* Standalone environment selected */
#else
#include "xenv_standalone.h"
#endif
/*
* The following comments specify the types and macro wrappers that are
* expected to be defined by the target specific header files
*/
/**************************** Type Definitions *******************************/
/*****************************************************************************/
/**
*
* XENV_TIME_STAMP
*
* A structure that contains a time stamp used by other time stamp macros
* defined below. This structure is processor dependent.
*/
/***************** Macros (Inline Functions) Definitions *********************/
/*****************************************************************************/
/**
*
* XENV_MEM_COPY(void *DestPtr, void *SrcPtr, unsigned Bytes)
*
* Copies a non-overlapping block of memory.
*
* @param DestPtr is the destination address to copy data to.
* @param SrcPtr is the source address to copy data from.
* @param Bytes is the number of bytes to copy.
*
* @return None
*/
/*****************************************************************************/
/**
*
* XENV_MEM_FILL(void *DestPtr, char Data, unsigned Bytes)
*
* Fills an area of memory with constant data.
*
* @param DestPtr is the destination address to set.
* @param Data contains the value to set.
* @param Bytes is the number of bytes to set.
*
* @return None
*/
/*****************************************************************************/
/**
*
* XENV_TIME_STAMP_GET(XTIME_STAMP *StampPtr)
*
* Samples the processor's or external timer's time base counter.
*
* @param StampPtr is the storage for the retrieved time stamp.
*
* @return None
*/
/*****************************************************************************/
/**
*
* XENV_TIME_STAMP_DELTA_US(XTIME_STAMP *Stamp1Ptr, XTIME_STAMP* Stamp2Ptr)
*
* Computes the delta between the two time stamps.
*
* @param Stamp1Ptr - First sampled time stamp.
* @param Stamp1Ptr - Sedond sampled time stamp.
*
* @return An unsigned int value with units of microseconds.
*/
/*****************************************************************************/
/**
*
* XENV_TIME_STAMP_DELTA_MS(XTIME_STAMP *Stamp1Ptr, XTIME_STAMP* Stamp2Ptr)
*
* Computes the delta between the two time stamps.
*
* @param Stamp1Ptr - First sampled time stamp.
* @param Stamp1Ptr - Sedond sampled time stamp.
*
* @return An unsigned int value with units of milliseconds.
*/
/*****************************************************************************//**
*
* XENV_USLEEP(unsigned delay)
*
* Delay the specified number of microseconds.
*
* @param delay is the number of microseconds to delay.
*
* @return None
*/
#ifdef __cplusplus
}
#endif
#endif /* end of protection macro */

View file

@ -1,252 +0,0 @@
/******************************************************************************
*
* Copyright (C) 2002 - 2014 Xilinx, Inc. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* Use of the Software is limited solely to applications:
* (a) running on a Xilinx device, or
* (b) that interact with a Xilinx device through a bus or interconnect.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* XILINX BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
* OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
* Except as contained in this notice, the name of the Xilinx shall not be used
* in advertising or otherwise to promote the sale, use or other dealings in
* this Software without prior written authorization from Xilinx.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file xenv_linux.h
*
* Defines common services specified by xenv.h.
*
* @note
* This file is not intended to be included directly by driver code.
* Instead, the generic xenv.h file is intended to be included by driver
* code.
*
* <pre>
* MODIFICATION HISTORY:
*
* Ver Who Date Changes
* ----- ---- -------- -----------------------------------------------
* 1.00a wgr 02/28/07 Added cache handling macros.
* 1.00a wgr 02/27/07 Simplified code. Deprecated old-style macro names.
* 1.00a xd 11/03/04 Improved support for doxygen.
* 1.00a ch 10/24/02 First release
* 1.10a wgr 03/22/07 Converted to new coding style.
* </pre>
*
*
******************************************************************************/
#ifndef XENV_LINUX_H
#define XENV_LINUX_H
#ifdef __cplusplus
extern "C" {
#endif
/***************************** Include Files *********************************/
#include <asm/cache.h>
#include <asm/cacheflush.h>
#include <linux/string.h>
#include <linux/delay.h>
/******************************************************************************
*
* MEMCPY / MEMSET related macros.
*
* Those macros are defined to catch legacy code in Xilinx drivers. The
* XENV_MEM_COPY and XENV_MEM_FILL macros were used in early Xilinx driver
* code. They are being replaced by memcpy() and memset() function calls. These
* macros are defined to catch any remaining occurences of those macros.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* Copies a non-overlapping block of memory.
*
* @param DestPtr
* Destination address to copy data to.
*
* @param SrcPtr
* Source address to copy data from.
*
* @param Bytes
* Number of bytes to copy.
*
* @return None.
*
*****************************************************************************/
#define XENV_MEM_COPY(DestPtr, SrcPtr, Bytes) \
memcpy(DestPtr, SrcPtr, Bytes)
/* do_not_use_XENV_MEM_COPY_use_memcpy_instead */
/*****************************************************************************/
/**
*
* Fills an area of memory with constant data.
*
* @param DestPtr
* Destination address to copy data to.
*
* @param Data
* Value to set.
*
* @param Bytes
* Number of bytes to copy.
*
* @return None.
*
*****************************************************************************/
#define XENV_MEM_FILL(DestPtr, Data, Bytes) \
memset(DestPtr, Data, Bytes)
/* do_not_use_XENV_MEM_FILL_use_memset_instead */
/******************************************************************************
*
* TIME related macros
*
******************************************************************************/
/**
* A structure that contains a time stamp used by other time stamp macros
* defined below. This structure is processor dependent.
*/
typedef int XENV_TIME_STAMP;
/*****************************************************************************/
/**
*
* Time is derived from the 64 bit PPC timebase register
*
* @param StampPtr is the storage for the retrieved time stamp.
*
* @return None.
*
* @note
*
* Signature: void XENV_TIME_STAMP_GET(XTIME_STAMP *StampPtr)
* <br><br>
* This macro must be implemented by the user.
*
*****************************************************************************/
#define XENV_TIME_STAMP_GET(StampPtr)
/*****************************************************************************/
/**
*
* This macro is not yet implemented and always returns 0.
*
* @param Stamp1Ptr is the first sampled time stamp.
* @param Stamp2Ptr is the second sampled time stamp.
*
* @return 0
*
* @note
*
* This macro must be implemented by the user.
*
*****************************************************************************/
#define XENV_TIME_STAMP_DELTA_US(Stamp1Ptr, Stamp2Ptr) (0)
/*****************************************************************************/
/**
*
* This macro is not yet implemented and always returns 0.
*
* @param Stamp1Ptr is the first sampled time stamp.
* @param Stamp2Ptr is the second sampled time stamp.
*
* @return 0
*
* @note
*
* This macro must be implemented by the user
*
*****************************************************************************/
#define XENV_TIME_STAMP_DELTA_MS(Stamp1Ptr, Stamp2Ptr) (0)
/*****************************************************************************/
/**
*
* Delay the specified number of microseconds.
*
* @param delay
* Number of microseconds to delay.
*
* @return None.
*
* @note XENV_USLEEP is deprecated. Use udelay() instead.
*
*****************************************************************************/
#define XENV_USLEEP(delay) udelay(delay)
/* do_not_use_XENV_MEM_COPY_use_memcpy_instead */
/******************************************************************************
*
* CACHE handling macros / mappings
*
* The implementation of the cache handling functions can be found in
* arch/microblaze.
*
* These #defines are simple mappings to the Linux API.
*
* The underlying Linux implementation will take care of taking the right
* actions depending on the configuration of the MicroBlaze processor in the
* system.
*
******************************************************************************/
#define XCACHE_ENABLE_DCACHE() __enable_dcache()
#define XCACHE_DISABLE_DCACHE() __disable_dcache()
#define XCACHE_ENABLE_ICACHE() __enable_icache()
#define XCACHE_DISABLE_ICACHE() __disable_icache()
#define XCACHE_INVALIDATE_DCACHE_RANGE(Addr, Len) invalidate_dcache_range((u32)(Addr), ((u32)(Addr)+(Len)))
#define XCACHE_FLUSH_DCACHE_RANGE(Addr, Len) flush_dcache_range((u32)(Addr), ((u32)(Addr)+(Len)))
#define XCACHE_INVALIDATE_ICACHE_RANGE(Addr, Len) "XCACHE_INVALIDATE_ICACHE_RANGE unsupported"
#define XCACHE_FLUSH_ICACHE_RANGE(Addr, Len) flush_icache_range(Addr, Len)
#define XCACHE_ENABLE_CACHE() \
{ XCACHE_ENABLE_DCACHE(); XCACHE_ENABLE_ICACHE(); }
#define XCACHE_DISABLE_CACHE() \
{ XCACHE_DISABLE_DCACHE(); XCACHE_DISABLE_ICACHE(); }
#ifdef __cplusplus
}
#endif
#endif /* end of protection macro */

View file

@ -1,52 +0,0 @@
/******************************************************************************
*
* Copyright (C) 2002 - 2014 Xilinx, Inc. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* Use of the Software is limited solely to applications:
* (a) running on a Xilinx device, or
* (b) that interact with a Xilinx device through a bus or interconnect.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* XILINX BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
* OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
* Except as contained in this notice, the name of the Xilinx shall not be used
* in advertising or otherwise to promote the sale, use or other dealings in
* this Software without prior written authorization from Xilinx.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file xenv_none.h
*
* This is a legacy file kept for backwards compatibility.
*
* Please modify your code to #include "xenv_standalone.h" instead.
*
*
******************************************************************************/
#warning ********************************************************************
#warning *
#warning * Use of xenv_none.h deprecated.
#warning * Please include the new xenv_standalone.h file instead.
#warning *
#warning ********************************************************************
#include "xenv_standalone.h"

View file

@ -1,367 +0,0 @@
/******************************************************************************
*
* Copyright (C) 2002 - 2014 Xilinx, Inc. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* Use of the Software is limited solely to applications:
* (a) running on a Xilinx device, or
* (b) that interact with a Xilinx device through a bus or interconnect.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* XILINX BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
* OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
* Except as contained in this notice, the name of the Xilinx shall not be used
* in advertising or otherwise to promote the sale, use or other dealings in
* this Software without prior written authorization from Xilinx.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file xenv_standalone.h
*
* Defines common services specified by xenv.h.
*
* @note
* This file is not intended to be included directly by driver code.
* Instead, the generic xenv.h file is intended to be included by driver
* code.
*
* <pre>
* MODIFICATION HISTORY:
*
* Ver Who Date Changes
* ----- ---- -------- -----------------------------------------------
* 1.00a wgr 02/28/07 Added cache handling macros.
* 1.00a wgr 02/27/07 Simplified code. Deprecated old-style macro names.
* 1.00a rmm 01/24/06 Implemented XENV_USLEEP. Assume implementation is being
* used under Xilinx standalone BSP.
* 1.00a xd 11/03/04 Improved support for doxygen.
* 1.00a rmm 03/21/02 First release
* 1.00a wgr 03/22/07 Converted to new coding style.
* 1.00a rpm 06/29/07 Added udelay macro for standalone
* 1.00a xd 07/19/07 Included xparameters.h as XPAR_ constants are referred
* to in MICROBLAZE section
* 1.00a ecm 09/19/08 updated for v7.20 of Microblaze, new functionality
*
* </pre>
*
*
******************************************************************************/
#ifndef XENV_STANDALONE_H
#define XENV_STANDALONE_H
#ifdef __cplusplus
extern "C" {
#endif
/***************************** Include Files *********************************/
/******************************************************************************
*
* Get the processor dependent includes
*
******************************************************************************/
#include <string.h>
#if defined __MICROBLAZE__
# include "mb_interface.h"
# include "xparameters.h" /* XPAR constants used below in MB section */
#elif defined __PPC__
# include "sleep.h"
# include "xcache_l.h" /* also include xcache_l.h for caching macros */
#endif
/******************************************************************************
*
* MEMCPY / MEMSET related macros.
*
* The following are straight forward implementations of memset and memcpy.
*
* NOTE: memcpy may not work if source and target memory area are overlapping.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* Copies a non-overlapping block of memory.
*
* @param DestPtr
* Destination address to copy data to.
*
* @param SrcPtr
* Source address to copy data from.
*
* @param Bytes
* Number of bytes to copy.
*
* @return None.
*
* @note
* The use of XENV_MEM_COPY is deprecated. Use memcpy() instead.
*
* @note
* This implemention MAY BREAK work if source and target memory
* area are overlapping.
*
*****************************************************************************/
#define XENV_MEM_COPY(DestPtr, SrcPtr, Bytes) \
memcpy((void *) DestPtr, (const void *) SrcPtr, (size_t) Bytes)
/*****************************************************************************/
/**
*
* Fills an area of memory with constant data.
*
* @param DestPtr
* Destination address to copy data to.
*
* @param Data
* Value to set.
*
* @param Bytes
* Number of bytes to copy.
*
* @return None.
*
* @note
* The use of XENV_MEM_FILL is deprecated. Use memset() instead.
*
*****************************************************************************/
#define XENV_MEM_FILL(DestPtr, Data, Bytes) \
memset((void *) DestPtr, (int) Data, (size_t) Bytes)
/******************************************************************************
*
* TIME related macros
*
******************************************************************************/
/**
* A structure that contains a time stamp used by other time stamp macros
* defined below. This structure is processor dependent.
*/
typedef int XENV_TIME_STAMP;
/*****************************************************************************/
/**
*
* Time is derived from the 64 bit PPC timebase register
*
* @param StampPtr is the storage for the retrieved time stamp.
*
* @return None.
*
* @note
*
* Signature: void XENV_TIME_STAMP_GET(XTIME_STAMP *StampPtr)
* <br><br>
* This macro must be implemented by the user.
*
*****************************************************************************/
#define XENV_TIME_STAMP_GET(StampPtr)
/*****************************************************************************/
/**
*
* This macro is not yet implemented and always returns 0.
*
* @param Stamp1Ptr is the first sampled time stamp.
* @param Stamp2Ptr is the second sampled time stamp.
*
* @return 0
*
* @note
*
* This macro must be implemented by the user.
*
*****************************************************************************/
#define XENV_TIME_STAMP_DELTA_US(Stamp1Ptr, Stamp2Ptr) (0)
/*****************************************************************************/
/**
*
* This macro is not yet implemented and always returns 0.
*
* @param Stamp1Ptr is the first sampled time stamp.
* @param Stamp2Ptr is the second sampled time stamp.
*
* @return 0
*
* @note
*
* This macro must be implemented by the user.
*
*****************************************************************************/
#define XENV_TIME_STAMP_DELTA_MS(Stamp1Ptr, Stamp2Ptr) (0)
/*****************************************************************************/
/**
* XENV_USLEEP(unsigned delay)
*
* Delay the specified number of microseconds. Not implemented without OS
* support.
*
* @param delay
* Number of microseconds to delay.
*
* @return None.
*
*****************************************************************************/
#ifdef __PPC__
#define XENV_USLEEP(delay) usleep(delay)
#define udelay(delay) usleep(delay)
#else
#define XENV_USLEEP(delay)
#define udelay(delay)
#endif
/******************************************************************************
*
* CACHE handling macros / mappings
*
******************************************************************************/
/******************************************************************************
*
* Processor independent macros
*
******************************************************************************/
#define XCACHE_ENABLE_CACHE() \
{ XCACHE_ENABLE_DCACHE(); XCACHE_ENABLE_ICACHE(); }
#define XCACHE_DISABLE_CACHE() \
{ XCACHE_DISABLE_DCACHE(); XCACHE_DISABLE_ICACHE(); }
/******************************************************************************
*
* MicroBlaze case
*
* NOTE: Currently the following macros will only work on systems that contain
* only ONE MicroBlaze processor. Also, the macros will only be enabled if the
* system is built using a xparameters.h file.
*
******************************************************************************/
#if defined __MICROBLAZE__
/* Check if MicroBlaze data cache was built into the core.
*/
#if (XPAR_MICROBLAZE_USE_DCACHE == 1)
# define XCACHE_ENABLE_DCACHE() microblaze_enable_dcache()
# define XCACHE_DISABLE_DCACHE() microblaze_disable_dcache()
# define XCACHE_INVALIDATE_DCACHE() microblaze_invalidate_dcache()
# define XCACHE_INVALIDATE_DCACHE_RANGE(Addr, Len) \
microblaze_invalidate_dcache_range((int)(Addr), (int)(Len))
#if (XPAR_MICROBLAZE_DCACHE_USE_WRITEBACK == 1)
# define XCACHE_FLUSH_DCACHE() microblaze_flush_dcache()
# define XCACHE_FLUSH_DCACHE_RANGE(Addr, Len) \
microblaze_flush_dcache_range((int)(Addr), (int)(Len))
#else
# define XCACHE_FLUSH_DCACHE() microblaze_invalidate_dcache()
# define XCACHE_FLUSH_DCACHE_RANGE(Addr, Len) \
microblaze_invalidate_dcache_range((int)(Addr), (int)(Len))
#endif /*XPAR_MICROBLAZE_DCACHE_USE_WRITEBACK*/
#else
# define XCACHE_ENABLE_DCACHE()
# define XCACHE_DISABLE_DCACHE()
# define XCACHE_INVALIDATE_DCACHE_RANGE(Addr, Len)
# define XCACHE_FLUSH_DCACHE_RANGE(Addr, Len)
#endif /*XPAR_MICROBLAZE_USE_DCACHE*/
/* Check if MicroBlaze instruction cache was built into the core.
*/
#if (XPAR_MICROBLAZE_USE_ICACHE == 1)
# define XCACHE_ENABLE_ICACHE() microblaze_enable_icache()
# define XCACHE_DISABLE_ICACHE() microblaze_disable_icache()
# define XCACHE_INVALIDATE_ICACHE() microblaze_invalidate_icache()
# define XCACHE_INVALIDATE_ICACHE_RANGE(Addr, Len) \
microblaze_invalidate_icache_range((int)(Addr), (int)(Len))
#else
# define XCACHE_ENABLE_ICACHE()
# define XCACHE_DISABLE_ICACHE()
#endif /*XPAR_MICROBLAZE_USE_ICACHE*/
/******************************************************************************
*
* PowerPC case
*
* Note that the XCACHE_ENABLE_xxx functions are hardcoded to enable a
* specific memory region (0x80000001). Each bit (0-30) in the regions
* bitmask stands for 128MB of memory. Bit 31 stands for the upper 2GB
* range.
*
* regions --> cached address range
* ------------|--------------------------------------------------
* 0x80000000 | [0, 0x7FFFFFF]
* 0x00000001 | [0xF8000000, 0xFFFFFFFF]
* 0x80000001 | [0, 0x7FFFFFF],[0xF8000000, 0xFFFFFFFF]
*
******************************************************************************/
#elif defined __PPC__
#define XCACHE_ENABLE_DCACHE() XCache_EnableDCache(0x80000001)
#define XCACHE_DISABLE_DCACHE() XCache_DisableDCache()
#define XCACHE_ENABLE_ICACHE() XCache_EnableICache(0x80000001)
#define XCACHE_DISABLE_ICACHE() XCache_DisableICache()
#define XCACHE_INVALIDATE_DCACHE_RANGE(Addr, Len) \
XCache_InvalidateDCacheRange((unsigned int)(Addr), (unsigned)(Len))
#define XCACHE_FLUSH_DCACHE_RANGE(Addr, Len) \
XCache_FlushDCacheRange((unsigned int)(Addr), (unsigned)(Len))
#define XCACHE_INVALIDATE_ICACHE() XCache_InvalidateICache()
/******************************************************************************
*
* Unknown processor / architecture
*
******************************************************************************/
#else
/* #error "Unknown processor / architecture. Must be MicroBlaze or PowerPC." */
#endif
#ifdef __cplusplus
}
#endif
#endif /* #ifndef XENV_STANDALONE_H */

View file

@ -1,269 +0,0 @@
/******************************************************************************
*
* Copyright (C) 2002 - 2014 Xilinx, Inc. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* Use of the Software is limited solely to applications:
* (a) running on a Xilinx device, or
* (b) that interact with a Xilinx device through a bus or interconnect.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* XILINX BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
* OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
* Except as contained in this notice, the name of the Xilinx shall not be used
* in advertising or otherwise to promote the sale, use or other dealings in
* this Software without prior written authorization from Xilinx.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file xenv_vxworks.h
*
* Defines common services specified by xenv.h.
*
* @note
* This file is not intended to be included directly by driver code.
* Instead, the generic xenv.h file is intended to be included by driver
* code.
*
* <pre>
* MODIFICATION HISTORY:
*
* Ver Who Date Changes
* ----- ---- -------- -----------------------------------------------
* 1.00a wgr 02/28/07 Added cache handling macros.
* 1.00a wgr 02/27/07 Simplified code. Deprecated old-style macro names.
* 1.00a xd 11/03/04 Improved support for doxygen.
* rmm 09/13/03 CR 177068: Fix compiler warning in XENV_MEM_FILL
* rmm 10/24/02 Added XENV_USLEEP macro
* 1.00a rmm 07/16/01 First release
* 1.10a wgr 03/22/07 Converted to new coding style.
* </pre>
*
*
******************************************************************************/
#ifndef XENV_VXWORKS_H
#define XENV_VXWORKS_H
#ifdef __cplusplus
extern "C" {
#endif
/***************************** Include Files *********************************/
#include "xbasic_types.h"
#include "vxWorks.h"
#include "vxLib.h"
#include "sysLibExtra.h"
#include "cacheLib.h"
#include <string.h>
/*****************************************************************************/
/**
*
* Copies a non-overlapping block of memory.
*
* @param DestPtr
* Destination address to copy data to.
*
* @param SrcPtr
* Source address to copy data from.
*
* @param Bytes
* Number of bytes to copy.
*
* @return None.
*
* @note XENV_MEM_COPY is deprecated. Use memcpy() instead.
*
*****************************************************************************/
#define XENV_MEM_COPY(DestPtr, SrcPtr, Bytes) \
memcpy((void *) DestPtr, (const void *) SrcPtr, (size_t) Bytes)
/*****************************************************************************/
/**
*
* Fills an area of memory with constant data.
*
* @param DestPtr
* Destination address to copy data to.
*
* @param Data
* Value to set.
*
* @param Bytes
* Number of bytes to copy.
*
* @return None.
*
* @note XENV_MEM_FILL is deprecated. Use memset() instead.
*
*****************************************************************************/
#define XENV_MEM_FILL(DestPtr, Data, Bytes) \
memset((void *) DestPtr, (int) Data, (size_t) Bytes)
#if (CPU_FAMILY==PPC)
/**
* A structure that contains a time stamp used by other time stamp macros
* defined below. This structure is processor dependent.
*/
typedef struct
{
u32 TimeBaseUpper;
u32 TimeBaseLower;
} XENV_TIME_STAMP;
/*****************************************************************************/
/**
*
* Time is derived from the 64 bit PPC timebase register
*
* @param StampPtr is the storage for the retrieved time stamp.
*
* @return None.
*
* @note
*
* Signature: void XENV_TIME_STAMP_GET(XTIME_STAMP *StampPtr)
*
*****************************************************************************/
#define XENV_TIME_STAMP_GET(StampPtr) \
{ \
vxTimeBaseGet((UINT32*)&(StampPtr)->TimeBaseUpper, \
(UINT32*)&(StampPtr)->TimeBaseLower); \
}
/*****************************************************************************/
/**
*
* This macro is not yet implemented and always returns 0.
*
* @param Stamp1Ptr is the first sampled time stamp.
* @param Stamp2Ptr is the second sampled time stamp.
*
* @return 0
*
* @note None.
*
*****************************************************************************/
#define XENV_TIME_STAMP_DELTA_US(Stamp1Ptr, Stamp2Ptr) (0)
/*****************************************************************************/
/**
*
* This macro is not yet implemented and always returns 0.
*
* @param Stamp1Ptr is the first sampled time stamp.
* @param Stamp2Ptr is the second sampled time stamp.
*
* @return 0
*
* @note
*
* None.
*
*****************************************************************************/
#define XENV_TIME_STAMP_DELTA_MS(Stamp1Ptr, Stamp2Ptr) (0)
/* For non-PPC systems the above macros are not defined. Generate a error to
* make the developer aware of the problem.
*/
#else
#error "XENV_TIME_STAMP_GET used in a non-PPC system. Aborting."
#endif
/*****************************************************************************/
/**
*
* Delay the specified number of microseconds.
*
* @param delay
* Number of microseconds to delay.
*
* @return None.
*
*****************************************************************************/
#define XENV_USLEEP(delay) sysUsDelay(delay)
#define udelay(delay) sysUsDelay(delay)
/******************************************************************************
*
* CACHE handling macros / mappings
*
******************************************************************************/
/******************************************************************************
*
* PowerPC case
*
******************************************************************************/
#if (CPU_FAMILY==PPC)
#define XCACHE_ENABLE_CACHE() \
{ XCACHE_ENABLE_DCACHE(); XCACHE_ENABLE_ICACHE(); }
#define XCACHE_DISABLE_CACHE() \
{ XCACHE_DISABLE_DCACHE(); XCACHE_DISABLE_ICACHE(); }
#define XCACHE_ENABLE_DCACHE() cacheEnable(DATA_CACHE)
#define XCACHE_DISABLE_DCACHE() cacheDisable(DATA_CACHE)
#define XCACHE_ENABLE_ICACHE() cacheEnable(INSTRUCTION_CACHE)
#define XCACHE_DISABLE_ICACHE() cacheDisable(INSTRUCTION_CACHE)
#define XCACHE_INVALIDATE_DCACHE_RANGE(Addr, Len) \
cacheInvalidate(DATA_CACHE, (void *)(Addr), (Len))
#define XCACHE_FLUSH_DCACHE_RANGE(Addr, Len) \
cacheFlush(DATA_CACHE, (void *)(Addr), (Len))
#define XCACHE_INVALIDATE_ICACHE_RANGE(Addr, Len) \
cacheInvalidate(INSTRUCTION_CACHE, (void *)(Addr), (Len))
#define XCACHE_FLUSH_ICACHE_RANGE(Addr, Len) \
cacheFlush(INSTRUCTION_CACHE, (void *)(Addr), (Len))
/******************************************************************************
*
* Unknown processor / architecture
*
******************************************************************************/
#else
#error "Unknown processor / architecture. Must be PPC for VxWorks."
#endif
#ifdef __cplusplus
}
#endif
#endif /* #ifdef XENV_VXWORKS_H */

View file

@ -1,728 +0,0 @@
/******************************************************************************
*
* Copyright (C) 2002 - 2014 Xilinx, Inc. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* Use of the Software is limited solely to applications:
* (a) running on a Xilinx device, or
* (b) that interact with a Xilinx device through a bus or interconnect.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* XILINX BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
* OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
* Except as contained in this notice, the name of the Xilinx shall not be used
* in advertising or otherwise to promote the sale, use or other dealings in
* this Software without prior written authorization from Xilinx.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file xparameters.h
*
* This file contains system parameters for the Xilinx device driver environment.
* It is a representation of the system in that it contains the number of each
* device in the system as well as the parameters and memory map for each
* device. The user can view this file to obtain a summary of the devices in
* their system and the device parameters.
*
* This file may be automatically generated by a design tool such as System
* Generator.
*
******************************************************************************/
/***************************** Include Files *********************************/
#ifndef XPARAMETERS_H /* prevent circular inclusions */
#define XPARAMETERS_H /* by using protection macros */
#ifdef __cplusplus
extern "C" {
#endif
/* unifying driver changes
added XPAR_INTC_0_ACK_BEFORE, XPAR_INTC_1_ACK_BEFORE
changed XPAR_INTC_MAX_ID to XPAR_INTC_MAX_NUM_INTR_INPUTS
deleted XPAR_INTC_0_MAX_ID, XPAR_INTC_1_MAX_ID
*/
/************************** Constant Definitions *****************************/
/*
* The following constants are for each device.
*
* An instance must exist for each physical device that exists in the system.
* The device IDs in the following constants are unique between all devices to
* allow device IDs to be searched in the future.
*/
/*****************************************************************************
*
* System Level defines. These constants are for devices that do not require
* a device driver. Examples of these types of devices include volatile RAM
* devices.
*/
#define XPAR_ZBT_NUM_INSTANCES 1
#define XPAR_ZBT_0_BASE 0x00000000
#define XPAR_ZBT_0_SIZE 0x00100000
#define XPAR_SRAM_NUM_INSTANCES 1
#define XPAR_SRAM_0_BASE 0x00100000
#define XPAR_SRAM_0_SIZE 0x00200000
#define XPAR_DDR_NUM_INSTANCES 1
#define XPAR_DDR_0_BASE 0xF0000000
#define XPAR_DDR_0_SIZE 0x01000000
#define XPAR_CORE_CLOCK_FREQ_HZ 12500000
#define XPAR_CPU_PPC405_CORE_CLOCK_FREQ_HZ XPAR_CORE_CLOCK_FREQ_HZ
/*****************************************************************************
*
* Interrupt Controller (Intc) defines.
* DeviceID starts at 0
*/
#define XPAR_XINTC_NUM_INSTANCES 2 /* Number of instances */
#define XPAR_INTC_MAX_NUM_INTR_INPUTS 31 /* max # inputs of all */
#define XPAR_INTC_SINGLE_BASEADDR 0x70800000 /* low level driver base */
#define XPAR_INTC_SINGLE_DEVICE_ID 0 /* single instance ID */
#define XPAR_INTC_SINGLE_ACK_BEFORE 0xFFFF00FF /* low level driver */
#define XPAR_INTC_0_DEVICE_ID 1 /* Device ID for instance */
#define XPAR_INTC_0_ACK_BEFORE 0xFFFF00FF /* Ack timing, before/after */
#define XPAR_INTC_0_BASEADDR 0x70800000 /* Register base address */
#define XPAR_INTC_0_UARTLITE_0_VEC_ID 4 /* Interrupt source for vector */
#define XPAR_INTC_0_WDTTB_0_VEC_ID 5 /* Interrupt source for vector */
#define XPAR_INTC_0_WD_0_VEC_ID 6 /* Interrupt source for vector */
#define XPAR_INTC_0_TMRCTR_0_VEC_ID 7 /* Interrupt source for vector */
#define XPAR_INTC_0_SPI_0_VEC_ID 11 /* Interrupt source for vector */
#define XPAR_INTC_0_IIC_0_VEC_ID 12 /* Interrupt source for vector */
#define XPAR_INTC_0_UARTNS550_0_VEC_ID 13 /* Interrupt source for vector */
#define XPAR_INTC_0_UARTNS550_1_VEC_ID 14 /* Interrupt source for vector */
#define XPAR_INTC_0_EMAC_0_VEC_ID 15 /* Interrupt source for vector */
#define XPAR_INTC_0_AXIDMA_0_S2MM_INTROUT_VEC_ID 16 /* Intr ID for AXIDMA rx */
#define XPAR_INTC_0_AXIDMA_0_MM2S_INTROUT_VEC_ID 17 /* Intr ID for AXIDMA tx */
#define XPAR_INTC_0_AXICDMA_0_VEC_ID 18 /* Intr ID for AXICDMA */
#define XPAR_INTC_0_AXIVDMA_0_S2MM_INTROUT_VEC_ID 19 /* AXIVDMA write intr */
#define XPAR_INTC_0_AXIVDMA_0_MM2S_INTROUT_VEC_ID 20 /* AXIVDMA read intr */
#define XPAR_INTC_1_DEVICE_ID 2 /* Device ID for instance */
#define XPAR_INTC_1_ACK_BEFORE 0xFFFF00FF /* Ack timing, before/after */
#define XPAR_INTC_1_BASEADDR 0x70800020 /* Register base address */
#define XPAR_INTC_1_OPB_TO_PLB_ERR_VEC_ID 0 /* Interrupt source for vector */
#define XPAR_INTC_1_PLB_TO_OPB_ERR_VEC_ID 1 /* Interrupt source for vector */
/*****************************************************************************
*
* AXI DMA defines
*/
#define XPAR_XAXIDMA_NUM_INSTANCES 1
#define XPAR_AXI_DMA_0_DEVICE_ID 0
#define XPAR_AXI_DMA_0_BASEADDR 0x40000000
#define XPAR_AXI_DMA_0_HIGHADDR 0x4000007F
#define XPAR_AXI_DMA_0_SG_INCLUDE_STSCNTRL_STRM 1
#define XPAR_AXI_DMA_0_INCLUDE_MM2S_DRE 1
#define XPAR_AXI_DMA_0_INCLUDE_S2MM_DRE 1
#define XPAR_AXI_DMA_0_INCLUDE_MM2S 1
#define XPAR_AXI_DMA_0_INCLUDE_S2MM 1
#define XPAR_AXI_DMA_0_M_AXIS_MM2S_DATA_WIDTH 32
#define XPAR_AXI_DMA_0_S_AXIS_S2MM_DATA_WIDTH 32
/*****************************************************************************
*
* AXI Central DMA defines
*/
#define XPAR_XAXICDMA_NUM_INSTANCES 1
#define XPAR_AXI_CDMA_0_DEVICE_ID 0
#define XPAR_AXI_CDMA_0_BASEADDR 0x40001000
#define XPAR_AXI_CDMA_0_HIGHADDR 0x4000107F
#define XPAR_AXI_CDMA_0_INCLUDE_DRE 1
#define XPAR_AXI_CDMA_0_USE_DATAMOVER_LITE 0
#define XPAR_AXI_CDMA_0_M_AXI_DATA_WIDTH 32
/*****************************************************************************
*
* AXI Video DMA defines
*/
#define XPAR_XAXIVDMA_NUM_INSTANCES 1
#define XPAR_AXI_VDMA_0_DEVICE_ID 0
#define XPAR_AXI_VDMA_0_BASEADDR 0x40002000
#define XPAR_AXI_VDMA_0_NUM_FSTORES 16
#define XPAR_AXI_VDMA_0_INCLUDE_MM2S 1
#define XPAR_AXI_VDMA_0_INCLUDE_MM2S_DRE 1
#define XPAR_AXI_VDMA_0_M_AXIS_MM2S_DATA_WIDTH 32
#define XPAR_AXI_VDMA_0_INCLUDE_S2MM 1
#define XPAR_AXI_VDMA_0_INCLUDE_S2MM_DRE 1
#define XPAR_AXI_VDMA_0_S_AXIS_S2MM_DATA_WIDTH 32
/*****************************************************************************
*
* Ethernet 10/100 MAC defines.
* DeviceID starts at 10
*/
#define XPAR_XEMAC_NUM_INSTANCES 1 /* Number of instances */
#define XPAR_EMAC_0_DEVICE_ID 10 /* Device ID for instance */
#define XPAR_EMAC_0_BASEADDR 0x60000000/* Device base address */
#define XPAR_EMAC_0_DMA_PRESENT FALSE /* Does device have DMA? */
#define XPAR_EMAC_0_ERR_COUNT_EXIST TRUE /* Does device have counters? */
#define XPAR_EMAC_0_MII_EXIST TRUE /* Does device support MII? */
/*****************************************************************************
*
* NS16550 UART defines.
* DeviceID starts at 20
*/
#define XPAR_XUARTNS550_NUM_INSTANCES 1 /* Number of instances */
#define XPAR_UARTNS550_0_DEVICE_ID 20 /* Device ID for instance */
#define XPAR_UARTNS550_0_BASEADDR 0xA0010000 /* IPIF base address */
#define XPAR_UARTNS550_0_CLOCK_HZ (66000000L)/* 66 MHz clock */
#define XPAR_UARTNS550_1_DEVICE_ID 21 /* Device ID for instance */
#define XPAR_UARTNS550_1_BASEADDR 0xA0000000 /* IPIF base address */
#define XPAR_UARTNS550_1_CLOCK_HZ (66000000L)/* 66 MHz clock */
/*****************************************************************************
*
* UartLite defines.
* DeviceID starts at 30
*/
#define XPAR_XUARTLITE_NUM_INSTANCES 1 /* Number of instances */
#define XPAR_UARTLITE_0_DEVICE_ID 30 /* Device ID for instance */
#define XPAR_UARTLITE_0_BASEADDR 0xA0020000 /* Device base address */
#define XPAR_UARTLITE_0_BAUDRATE 19200 /* Baud rate */
#define XPAR_UARTLITE_0_USE_PARITY FALSE /* Parity generator enabled */
#define XPAR_UARTLITE_0_ODD_PARITY FALSE /* Type of parity generated */
#define XPAR_UARTLITE_0_DATA_BITS 8 /* Data bits */
/*****************************************************************************
*
* ATM controller defines.
* DeviceID starts at 40
*/
#define XPAR_XATMC_NUM_INSTANCES 1 /* Number of instances */
#define XPAR_ATMC_0_DEVICE_ID 40 /* Device ID for instance */
#define XPAR_ATMC_0_BASEADDR 0x70000000 /* Device base address */
#define XPAR_ATMC_0_DMA_PRESENT FALSE /* Does device have DMA? */
/*****************************************************************************
*
* Serial Peripheral Interface (SPI) defines.
* DeviceID starts at 50
*/
#define XPAR_XSPI_NUM_INSTANCES 2 /* Number of instances */
#define XPAR_SPI_0_DEVICE_ID 50 /* Device ID for instance */
#define XPAR_SPI_0_BASEADDR 0x50000000 /* Device base address */
#define XPAR_SPI_0_FIFO_EXIST TRUE /* Does device have FIFOs? */
#define XPAR_SPI_0_SLAVE_ONLY FALSE /* Is the device slave only? */
#define XPAR_SPI_0_NUM_SS_BITS 32 /* Number of slave select bits */
#define XPAR_SPI_1_DEVICE_ID 51 /* Device ID for instance */
#define XPAR_SPI_1_BASEADDR 0x50000100 /* IPIF base address */
#define XPAR_SPI_1_FIFO_EXIST TRUE /* Does device have FIFOs? */
#define XPAR_SPI_1_SLAVE_ONLY FALSE /* Is the device slave only? */
#define XPAR_SPI_1_NUM_SS_BITS 32 /* Number of slave select bits */
/*****************************************************************************
*
* OPB Arbiter defines.
* DeviceID starts at 60
*/
#define XPAR_XOPBARB_NUM_INSTANCES 1 /* Number of instances */
#define XPAR_OPBARB_0_DEVICE_ID 60 /* Device ID for instance */
#define XPAR_OPBARB_0_BASEADDR 0x80000000 /* Register base address */
#define XPAR_OPBARB_0_NUM_MASTERS 8 /* Number of masters on bus */
/*****************************************************************************
*
* Watchdog timer/timebase (WdtTb) defines.
* DeviceID starts at 70
*/
#define XPAR_XWDTTB_NUM_INSTANCES 1 /* Number of instances */
#define XPAR_WDTTB_0_DEVICE_ID 70 /* Device ID for instance */
#define XPAR_WDTTB_0_BASEADDR 0x70800040 /* Register base address */
/*****************************************************************************
*
* Timer Counter (TmrCtr) defines.
* DeviceID starts at 80
*/
#define XPAR_XTMRCTR_NUM_INSTANCES 2 /* Number of instances */
#define XPAR_TMRCTR_0_DEVICE_ID 80 /* Device ID for instance */
#define XPAR_TMRCTR_0_BASEADDR 0x70800100 /* Register base address */
/*****************************************************************************
*
* IIC defines.
* DeviceID starts at 90
*/
#define XPAR_XIIC_NUM_INSTANCES 2 /* Number of instances */
#define XPAR_IIC_0_DEVICE_ID 90 /* Device ID for instance */
#define XPAR_IIC_0_BASEADDR 0xA8000000 /* Device base address */
#define XPAR_IIC_0_TEN_BIT_ADR TRUE /* Supports 10 bit addresses */
#define XPAR_IIC_1_DEVICE_ID 91 /* Device ID for instance */
#define XPAR_IIC_1_BASEADDR 0xA8000000 /* Device base address */
#define XPAR_IIC_1_TEN_BIT_ADR TRUE /* Supports 10 bit addresses */
/*****************************************************************************
*
* Flash defines.
* DeviceID starts at 100
*/
#define XPAR_XFLASH_NUM_INSTANCES 1 /* Number of instances */
#define XPAR_FLASH_INTEL_SUPPORT /* Include intel flash support */
#define XPAR_FLASH_0_DEVICE_ID 100 /* Device ID for first instance
*/
#define XPAR_FLASH_0_BASEADDR 0xFF000000 /* Base address of parts */
#define XPAR_FLASH_0_NUM_PARTS 2 /* Number of parts in array */
#define XPAR_FLASH_0_PART_WIDTH 2 /* Width of each part in bytes */
#define XPAR_FLASH_0_PART_MODE 2 /* Mode of each part in bytes */
/*****************************************************************************
*
* GPIO defines.
* DeviceID starts at 110
*/
#define XPAR_XGPIO_NUM_INSTANCES 1
#define XPAR_GPIO_0_DEVICE_ID 110 /* Device ID for instance */
#define XPAR_GPIO_0_BASEADDR 0x90000000 /* Register base address */
#define XPAR_GPIO_0_INTERRUPT_PRESENT 0 /* Interrupts supported? */
#define XPAR_GPIO_0_IS_DUAL 0 /* Dual channels supported? */
/*****************************************************************************
*
* EMC defines.
* DeviceID starts at 120
*/
#define XPAR_XEMC_NUM_INSTANCES 1
#define XPAR_EMC_0_DEVICE_ID 120 /* Device ID for instance */
#define XPAR_EMC_0_BASEADDR 0xE0000000 /* Register base address */
#define XPAR_EMC_0_NUM_BANKS_MEM 3 /* Number of banks */
/*****************************************************************************
*
* PLB Arbiter defines.
* DeviceID starts at 130
*/
#define XPAR_XPLBARB_NUM_INSTANCES 1
#define XPAR_PLBARB_0_DEVICE_ID 130 /* Device ID for instance */
#define XPAR_PLBARB_0_BASEADDR 0x300 /* Register base address */
#define XPAR_PLBARB_0_NUM_MASTERS 1 /* Number of masters on bus */
/*****************************************************************************
*
* PLB To OPB Bridge defines.
* DeviceID starts at 140
*/
#define XPAR_XPLB2OPB_NUM_INSTANCES 1
#define XPAR_PLB2OPB_0_DEVICE_ID 140 /* Device ID for instance */
#define XPAR_PLB2OPB_0_DCR_BASEADDR 0x0 /* DCR Register base address
*/
#define XPAR_PLB2OPB_0_NUM_MASTERS 1 /* Number of masters on bus
*/
/*****************************************************************************
*
* OPB To PLB Bridge defines.
* DeviceID starts at 150
*/
#define XPAR_XOPB2PLB_NUM_INSTANCES 1
#define XPAR_XOPB2PLB_ANY_OPB_REG_INTF /* Accessible from OPB, not DCR */
#define XPAR_OPB2PLB_0_DEVICE_ID 150 /* Device ID for instance */
#define XPAR_OPB2PLB_0_OPB_BASEADDR 0x0 /* Register base address */
#define XPAR_OPB2PLB_0_DCR_BASEADDR 0x0 /* DCR Register base address */
/*****************************************************************************
*
* System ACE defines.
* DeviceID starts at 160
*/
#define XPAR_XSYSACE_NUM_INSTANCES 1
#define XPAR_SYSACE_0_DEVICE_ID 160 /* Device ID for instance */
#define XPAR_SYSACE_0_BASEADDR 0xCF000000 /* Register base address */
/*****************************************************************************
*
* HDLC defines.
* DeviceID starts at 170
*/
#define XPAR_XHDLC_NUM_INSTANCES 1
#define XPAR_HDLC_0_DEVICE_ID 170 /* Device ID for instance */
#define XPAR_HDLC_0_BASEADDR 0x60010000 /* Register base address */
#define XPAR_HDLC_0_TX_MEM_DEPTH 2048 /* Tx FIFO depth (bytes) */
#define XPAR_HDLC_0_RX_MEM_DEPTH 2048 /* Rx FIFO depth (bytes) */
#define XPAR_HDLC_0_DMA_PRESENT 3 /* DMA SG in hardware */
/*****************************************************************************
*
* PS2 Reference driver defines.
* DeviceID starts at 180
*/
#define XPAR_XPS2_NUM_INSTANCES 2
#define XPAR_PS2_0_DEVICE_ID 180 /* Device ID for instance */
#define XPAR_PS2_0_BASEADDR 0x40010000 /* Register base address */
#define XPAR_PS2_1_DEVICE_ID 181 /* Device ID for instance */
#define XPAR_PS2_1_BASEADDR 0x40020000 /* Register base address */
/*****************************************************************************
*
* Rapid IO defines.
* DeviceID starts at 190
*/
#define XPAR_XRAPIDIO_NUM_INSTANCES 1
#define XPAR_RAPIDIO_0_DEVICE_ID 190 /* Device ID for instance */
#define XPAR_RAPIDIO_0_BASEADDR 0x60000000 /* Register base address */
/*****************************************************************************
*
* PCI defines.
* DeviceID starts at 200
*/
#define XPAR_XPCI_NUM_INSTANCES 1
#define XPAR_OPB_PCI_1_DEVICE_ID 200
#define XPAR_OPB_PCI_1_BASEADDR 0x86000000
#define XPAR_OPB_PCI_1_HIGHADDR 0x860001FF
#define XPAR_OPB_PCI_1_PCIBAR_0 0x10000000
#define XPAR_OPB_PCI_1_PCIBAR_LEN_0 27
#define XPAR_OPB_PCI_1_PCIBAR2IPIF_0 0xF0000000
#define XPAR_OPB_PCI_1_PCIBAR_ENDIAN_TRANSLATE_EN_0 0
#define XPAR_OPB_PCI_1_PCI_PREFETCH_0 1
#define XPAR_OPB_PCI_1_PCI_SPACETYPE_0 1
#define XPAR_OPB_PCI_1_PCIBAR_1 0x3F000000
#define XPAR_OPB_PCI_1_PCIBAR_LEN_1 15
#define XPAR_OPB_PCI_1_PCIBAR2IPIF_1 0xC0FF8000
#define XPAR_OPB_PCI_1_PCIBAR_ENDIAN_TRANSLATE_EN_1 0
#define XPAR_OPB_PCI_1_PCI_PREFETCH_1 1
#define XPAR_OPB_PCI_1_PCI_SPACETYPE_1 1
#define XPAR_OPB_PCI_1_PCIBAR_2 0x5F000000
#define XPAR_OPB_PCI_1_PCIBAR_LEN_2 16
#define XPAR_OPB_PCI_1_PCIBAR2IPIF_2 0x00000000
#define XPAR_OPB_PCI_1_PCIBAR_ENDIAN_TRANSLATE_EN_2 0
#define XPAR_OPB_PCI_1_PCI_PREFETCH_2 1
#define XPAR_OPB_PCI_1_PCI_SPACETYPE_2 1
#define XPAR_OPB_PCI_1_IPIFBAR_0 0x80000000
#define XPAR_OPB_PCI_1_IPIF_HIGHADDR_0 0x81FFFFFF
#define XPAR_OPB_PCI_1_IPIFBAR2PCI_0 0xF0000000
#define XPAR_OPB_PCI_1_IPIFBAR_ENDIAN_TRANSLATE_EN_0 0
#define XPAR_OPB_PCI_1_IPIF_PREFETCH_0 1
#define XPAR_OPB_PCI_1_IPIF_SPACETYPE_0 1
#define XPAR_OPB_PCI_1_IPIFBAR_1 0x82000000
#define XPAR_OPB_PCI_1_IPIF_HIGHADDR_1 0x820007FF
#define XPAR_OPB_PCI_1_IPIFBAR2PCI_1 0xCE000000
#define XPAR_OPB_PCI_1_IPIFBAR_ENDIAN_TRANSLATE_EN_1 0
#define XPAR_OPB_PCI_1_IPIF_PREFETCH_1 1
#define XPAR_OPB_PCI_1_IPIF_SPACETYPE_1 1
#define XPAR_OPB_PCI_1_IPIFBAR_2 0x82320000
#define XPAR_OPB_PCI_1_IPIF_HIGHADDR_2 0x8232FFFF
#define XPAR_OPB_PCI_1_IPIFBAR2PCI_2 0x00010000
#define XPAR_OPB_PCI_1_IPIFBAR_ENDIAN_TRANSLATE_EN_2 0
#define XPAR_OPB_PCI_1_IPIF_PREFETCH_2 1
#define XPAR_OPB_PCI_1_IPIF_SPACETYPE_2 1
#define XPAR_OPB_PCI_1_IPIFBAR_3 0x82330000
#define XPAR_OPB_PCI_1_IPIF_HIGHADDR_3 0x8233FFFF
#define XPAR_OPB_PCI_1_IPIFBAR2PCI_3 0x00010000
#define XPAR_OPB_PCI_1_IPIFBAR_ENDIAN_TRANSLATE_EN_3 0
#define XPAR_OPB_PCI_1_IPIF_PREFETCH_3 1
#define XPAR_OPB_PCI_1_IPIF_SPACETYPE_3 0
#define XPAR_OPB_PCI_1_IPIFBAR_4 0x82340000
#define XPAR_OPB_PCI_1_IPIF_HIGHADDR_4 0x8234FFFF
#define XPAR_OPB_PCI_1_IPIFBAR2PCI_4 0x00010000
#define XPAR_OPB_PCI_1_IPIFBAR_ENDIAN_TRANSLATE_EN_4 0
#define XPAR_OPB_PCI_1_IPIF_PREFETCH_4 0
#define XPAR_OPB_PCI_1_IPIF_SPACETYPE_4 0
#define XPAR_OPB_PCI_1_IPIFBAR_5 0x82350000
#define XPAR_OPB_PCI_1_IPIF_HIGHADDR_5 0x8235FFFF
#define XPAR_OPB_PCI_1_IPIFBAR2PCI_5 0x00010000
#define XPAR_OPB_PCI_1_IPIFBAR_ENDIAN_TRANSLATE_EN_5 0
#define XPAR_OPB_PCI_1_IPIF_PREFETCH_5 1
#define XPAR_OPB_PCI_1_IPIF_SPACETYPE_5 1
#define XPAR_OPB_PCI_1_DMA_BASEADDR 0x87000000
#define XPAR_OPB_PCI_1_DMA_HIGHADDR 0x8700007F
#define XPAR_OPB_PCI_1_DMA_CHAN_TYPE 0
#define XPAR_OPB_PCI_1_DMA_LENGTH_WIDTH 11
/*****************************************************************************
*
* GEmac defines.
* DeviceID starts at 210
*/
#define XPAR_XGEMAC_NUM_INSTANCES 1
#define XPAR_GEMAC_0_DEVICE_ID 210
#define XPAR_GEMAC_0_BASEADDR 0x61000000
#define XPAR_GEMAC_0_DMA_TYPE 9
#define XPAR_GEMAC_0_MIIM_EXIST 0
#define XPAR_GEMAC_0_INCLUDE_STATS 0
/*****************************************************************************
*
* Touchscreen defines .
* DeviceID starts at 220
*/
#define XPAR_XTOUCHSCREEN_NUM_INSTANCES 1
#define XPAR_TOUCHSCREEN_0_DEVICE_ID 220
#define XPAR_TOUCHSCREEN_0_BASEADDR 0x70000000
/*****************************************************************************
*
* DDR defines .
* DeviceID starts at 230
*/
#define XPAR_XDDR_NUM_INSTANCES 1
#define XPAR_DDR_0_DEVICE_ID 230
#define XPAR_DDR_0_BASEADDR 0
#define XPAR_DDR_0_INTERRUPT_PRESENT 0
/*****************************************************************************
*
* EmacLite defines .
* DeviceID starts at 240
*/
#define XPAR_XEMACLITE_NUM_INSTANCES 1
#define XPAR_EMACLITE_0_DEVICE_ID 240
#define XPAR_EMACLITE_0_BASEADDR 0
#define XPAR_EMACLITE_0_TX_PING_PONG 0
#define XPAR_EMACLITE_0_RX_PING_PONG 0
/*****************************************************************************
*
* DSDAC defines .
* DeviceID starts at 250
*/
#define XPAR_XDSDAC_NUM_INSTANCES 1
#define XPAR_DSDAC_0_DEVICE_ID 250
#define XPAR_DSDAC_0_BASEADDR 0
/*****************************************************************************
*
* DSADC defines .
* DeviceID starts at 260
*/
#define XPAR_XDSADC_NUM_INSTANCES 1
#define XPAR_DSADC_0_DEVICE_ID 260
#define XPAR_DSADC_0_BASEADDR 0
/*****************************************************************************
*
* PCI Arbiter defines.
* DeviceID starts at 270
*/
#define XPAR_XPCIARB_NUM_INSTANCES 1
#define XPAR_OPB_PCI_ARBITER_0_DEVICE_ID 270
#define XPAR_OPB_PCI_ARBITER_0_BASEADDR 0
#define XPAR_OPB_PCI_ARBITER_0_NUM_PCI_MSTRS 2
/*****************************************************************************
*
* TEMAC defines .
* DeviceID starts at 280
*/
#define XPAR_XTEMAC_NUM_INSTANCES 1
#define XPAR_TEMAC_0_DEVICE_ID 280
#define XPAR_TEMAC_0_BASEADDR 0
#define XPAR_TEMAC_0_DMA_TYPE 3
#define XPAR_TEMAC_0_RDFIFO_DEPTH 131072
#define XPAR_TEMAC_0_WRFIFO_DEPTH 131072
#define XPAR_TEMAC_0_MAC_FIFO_DEPTH 16
#define XPAR_TEMAC_0_TEMAC_DCR_HOST 0
#define XPAR_TEMAC_0_DRE 0
/*****************************************************************************
*
* DMACENTRAL defines .
* DeviceID starts at 290
*/
#define XPAR_XDMACENTRAL_NUM_INSTANCES 1
#define XPAR_DMACENTRAL_0_DEVICE_ID 290
#define XPAR_DMACENTRAL_0_BASEADDR 0
#define XPAR_DMACENTRAL_0_READ_OPTIONAL_REGS 0
/*****************************************************************************
*
* CAN defines
* DeviceID starts at 300
*/
#define XPAR_XCAN_NUM_INSTANCES 1
#define XPAR_CAN_0_DEVICE_ID 300
/* Definitions for FLEXRAY Driver */
#define XPAR_XFLEXRAY_NUM_INSTANCES 1
#define XPAR_OPB_FLEXRAY_0_DEVICE_ID 0
#define XPAR_OPB_FLEXRAY_0_BASEADDR 0x7D80E000
#define XPAR_OPB_FLEXRAY_MAX_PAYLOAD_SIZE 254
#define XPAR_OPB_FLEXRAY_NO_OF_TX_BUFFERS 128
#define XPAR_OPB_FLEXRAY_NO_OF_RX_BUFFERS 128
#define XPAR_OPB_FLEXRAY_RX_FIFO_DEPTH 16
/* Definitions for MOST driver */
#define XPAR_XMOST_NUM_INSTANCES 1
#define XPAR_MOST_0_DEVICE_ID 0
#define XPAR_MOST_0_BASEADDR 0x7D810000
#define XPAR_MOST_OPMODE 0
#define XPAR_MOST_FWC 16
#define XPAR_MOST_EWC 16
/* Definitions for USB driver */
#define XPAR_XUSB_NUM_INSTANCES 1
#define XPAR_USB_0_DEVICE_ID 0
#define XPAR_USB_0_BASEADDR 0x7D813000
/*****************************************************************************
*
* HWICAP defines .
*/
#define XPAR_XHWICAP_NUM_INSTANCES 1
#define XPAR_OPB_HWICAP_0_DEVICE_ID 0
#define XPAR_OPB_HWICAP_0_BASEADDR 0xFFFFFFFF
/*****************************************************************************
*
* LLTEMAC and LLFIFO defines .
*/
#define XPAR_XLLTEMAC_NUM_INSTANCES 1
#define XPAR_XLLFIFO_NUM_INSTANCES 1
/*****************************************************************************
*
* PCIe defines .
*/
#define XPAR_XPCIE_NUM_INSTANCES 1
/*****************************************************************************
*
* MPMC defines .
*/
#define XPAR_XMPMC_NUM_INSTANCES 1
/*****************************************************************************
*
* SYSMON defines .
*/
#define XPAR_XSYSMON_NUM_INSTANCES 1
/*****************************************************************************
*
* AXI Ethernet defines .
*/
#define XPAR_XAXIETHERNET_NUM_INSTANCES 1
/*****************************************************************************
*
* TFT defines .
*/
#define XPAR_XTFT_NUM_INSTANCES 1
/*****************************************************************************
*
* MBox defines .
*/
#define XPAR_XMBOX_NUM_INSTANCES 1
#define XPAR_XMBOX_0_DEVICE_ID 0
#define XPAR_XMBOX_0_BASEADDR 0x7D814000
#define XPAR_XMBOX_0_NUM_CHANNELS 1
#define XPAR_XMBOX_0_USE_FSL 0
/*****************************************************************************
*
* Mutex defines .
*/
#define XPAR_XMUTEX_NUM_INSTANCES 1
#define XPAR_XMUTEX_0_DEVICE_ID 0
#define XPAR_XMUTEX_0_BASEADDR 0x7D815000
#define XPAR_XMUTEX_0_NUM_MUTEX 2
#define XPAR_XMUTEX_0_ENABLE_USER 1
/*
* MicroBlaze sets this define but for the build check to
* function it needs to be set here
*/
#define XPAR_CPU_ID 0
/*****************************************************************************
*
* BRAM defines .
*/
#define XPAR_XBRAM_NUM_INSTANCES 1
/*****************************************************************************
*
* AXI PCIE defines .
*/
#define XPAR_XAXIPCIE_NUM_INSTANCES 1
/*****************************************************************************
*
* V6 DDRX efines .
*/
#define XPAR_XV6DDR_NUM_INSTANCES 1
/**************************** Type Definitions *******************************/
/***************** Macros (Inline Functions) Definitions *********************/
#ifdef __cplusplus
}
#endif
#endif /* end of protection macro */

View file

@ -1,429 +0,0 @@
/******************************************************************************
*
* Copyright (C) 2002 - 2014 Xilinx, Inc. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* Use of the Software is limited solely to applications:
* (a) running on a Xilinx device, or
* (b) that interact with a Xilinx device through a bus or interconnect.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* XILINX BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
* OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
* Except as contained in this notice, the name of the Xilinx shall not be used
* in advertising or otherwise to promote the sale, use or other dealings in
* this Software without prior written authorization from Xilinx.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file xstatus.h
*
* This file contains Xilinx software status codes. Status codes have their
* own data type called int. These codes are used throughout the Xilinx
* device drivers.
*
******************************************************************************/
#ifndef XSTATUS_H /* prevent circular inclusions */
#define XSTATUS_H /* by using protection macros */
#ifdef __cplusplus
extern "C" {
#endif
/***************************** Include Files *********************************/
#include "xbasic_types.h"
/************************** Constant Definitions *****************************/
/*********************** Common statuses 0 - 500 *****************************/
#define XST_SUCCESS 0L
#define XST_FAILURE 1L
#define XST_DEVICE_NOT_FOUND 2L
#define XST_DEVICE_BLOCK_NOT_FOUND 3L
#define XST_INVALID_VERSION 4L
#define XST_DEVICE_IS_STARTED 5L
#define XST_DEVICE_IS_STOPPED 6L
#define XST_FIFO_ERROR 7L /* an error occurred during an
operation with a FIFO such as
an underrun or overrun, this
error requires the device to
be reset */
#define XST_RESET_ERROR 8L /* an error occurred which requires
the device to be reset */
#define XST_DMA_ERROR 9L /* a DMA error occurred, this error
typically requires the device
using the DMA to be reset */
#define XST_NOT_POLLED 10L /* the device is not configured for
polled mode operation */
#define XST_FIFO_NO_ROOM 11L /* a FIFO did not have room to put
the specified data into */
#define XST_BUFFER_TOO_SMALL 12L /* the buffer is not large enough
to hold the expected data */
#define XST_NO_DATA 13L /* there was no data available */
#define XST_REGISTER_ERROR 14L /* a register did not contain the
expected value */
#define XST_INVALID_PARAM 15L /* an invalid parameter was passed
into the function */
#define XST_NOT_SGDMA 16L /* the device is not configured for
scatter-gather DMA operation */
#define XST_LOOPBACK_ERROR 17L /* a loopback test failed */
#define XST_NO_CALLBACK 18L /* a callback has not yet been
registered */
#define XST_NO_FEATURE 19L /* device is not configured with
the requested feature */
#define XST_NOT_INTERRUPT 20L /* device is not configured for
interrupt mode operation */
#define XST_DEVICE_BUSY 21L /* device is busy */
#define XST_ERROR_COUNT_MAX 22L /* the error counters of a device
have maxed out */
#define XST_IS_STARTED 23L /* used when part of device is
already started i.e.
sub channel */
#define XST_IS_STOPPED 24L /* used when part of device is
already stopped i.e.
sub channel */
#define XST_DATA_LOST 26L /* driver defined error */
#define XST_RECV_ERROR 27L /* generic receive error */
#define XST_SEND_ERROR 28L /* generic transmit error */
#define XST_NOT_ENABLED 29L /* a requested service is not
available because it has not
been enabled */
/***************** Utility Component statuses 401 - 500 *********************/
#define XST_MEMTEST_FAILED 401L /* memory test failed */
/***************** Common Components statuses 501 - 1000 *********************/
/********************* Packet Fifo statuses 501 - 510 ************************/
#define XST_PFIFO_LACK_OF_DATA 501L /* not enough data in FIFO */
#define XST_PFIFO_NO_ROOM 502L /* not enough room in FIFO */
#define XST_PFIFO_BAD_REG_VALUE 503L /* self test, a register value
was invalid after reset */
#define XST_PFIFO_ERROR 504L /* generic packet FIFO error */
#define XST_PFIFO_DEADLOCK 505L /* packet FIFO is reporting
* empty and full simultaneously
*/
/************************** DMA statuses 511 - 530 ***************************/
#define XST_DMA_TRANSFER_ERROR 511L /* self test, DMA transfer
failed */
#define XST_DMA_RESET_REGISTER_ERROR 512L /* self test, a register value
was invalid after reset */
#define XST_DMA_SG_LIST_EMPTY 513L /* scatter gather list contains
no buffer descriptors ready
to be processed */
#define XST_DMA_SG_IS_STARTED 514L /* scatter gather not stopped */
#define XST_DMA_SG_IS_STOPPED 515L /* scatter gather not running */
#define XST_DMA_SG_LIST_FULL 517L /* all the buffer desciptors of
the scatter gather list are
being used */
#define XST_DMA_SG_BD_LOCKED 518L /* the scatter gather buffer
descriptor which is to be
copied over in the scatter
list is locked */
#define XST_DMA_SG_NOTHING_TO_COMMIT 519L /* no buffer descriptors have been
put into the scatter gather
list to be commited */
#define XST_DMA_SG_COUNT_EXCEEDED 521L /* the packet count threshold
specified was larger than the
total # of buffer descriptors
in the scatter gather list */
#define XST_DMA_SG_LIST_EXISTS 522L /* the scatter gather list has
already been created */
#define XST_DMA_SG_NO_LIST 523L /* no scatter gather list has
been created */
#define XST_DMA_SG_BD_NOT_COMMITTED 524L /* the buffer descriptor which was
being started was not committed
to the list */
#define XST_DMA_SG_NO_DATA 525L /* the buffer descriptor to start
has already been used by the
hardware so it can't be reused
*/
#define XST_DMA_SG_LIST_ERROR 526L /* general purpose list access
error */
#define XST_DMA_BD_ERROR 527L /* general buffer descriptor
error */
/************************** IPIF statuses 531 - 550 ***************************/
#define XST_IPIF_REG_WIDTH_ERROR 531L /* an invalid register width
was passed into the function */
#define XST_IPIF_RESET_REGISTER_ERROR 532L /* the value of a register at
reset was not valid */
#define XST_IPIF_DEVICE_STATUS_ERROR 533L /* a write to the device interrupt
status register did not read
back correctly */
#define XST_IPIF_DEVICE_ACK_ERROR 534L /* the device interrupt status
register did not reset when
acked */
#define XST_IPIF_DEVICE_ENABLE_ERROR 535L /* the device interrupt enable
register was not updated when
other registers changed */
#define XST_IPIF_IP_STATUS_ERROR 536L /* a write to the IP interrupt
status register did not read
back correctly */
#define XST_IPIF_IP_ACK_ERROR 537L /* the IP interrupt status register
did not reset when acked */
#define XST_IPIF_IP_ENABLE_ERROR 538L /* IP interrupt enable register was
not updated correctly when other
registers changed */
#define XST_IPIF_DEVICE_PENDING_ERROR 539L /* The device interrupt pending
register did not indicate the
expected value */
#define XST_IPIF_DEVICE_ID_ERROR 540L /* The device interrupt ID register
did not indicate the expected
value */
#define XST_IPIF_ERROR 541L /* generic ipif error */
/****************** Device specific statuses 1001 - 4095 *********************/
/********************* Ethernet statuses 1001 - 1050 *************************/
#define XST_EMAC_MEMORY_SIZE_ERROR 1001L /* Memory space is not big enough
* to hold the minimum number of
* buffers or descriptors */
#define XST_EMAC_MEMORY_ALLOC_ERROR 1002L /* Memory allocation failed */
#define XST_EMAC_MII_READ_ERROR 1003L /* MII read error */
#define XST_EMAC_MII_BUSY 1004L /* An MII operation is in progress */
#define XST_EMAC_OUT_OF_BUFFERS 1005L /* Driver is out of buffers */
#define XST_EMAC_PARSE_ERROR 1006L /* Invalid driver init string */
#define XST_EMAC_COLLISION_ERROR 1007L /* Excess deferral or late
* collision on polled send */
/*********************** UART statuses 1051 - 1075 ***************************/
#define XST_UART
#define XST_UART_INIT_ERROR 1051L
#define XST_UART_START_ERROR 1052L
#define XST_UART_CONFIG_ERROR 1053L
#define XST_UART_TEST_FAIL 1054L
#define XST_UART_BAUD_ERROR 1055L
#define XST_UART_BAUD_RANGE 1056L
/************************ IIC statuses 1076 - 1100 ***************************/
#define XST_IIC_SELFTEST_FAILED 1076 /* self test failed */
#define XST_IIC_BUS_BUSY 1077 /* bus found busy */
#define XST_IIC_GENERAL_CALL_ADDRESS 1078 /* mastersend attempted with */
/* general call address */
#define XST_IIC_STAND_REG_RESET_ERROR 1079 /* A non parameterizable reg */
/* value after reset not valid */
#define XST_IIC_TX_FIFO_REG_RESET_ERROR 1080 /* Tx fifo included in design */
/* value after reset not valid */
#define XST_IIC_RX_FIFO_REG_RESET_ERROR 1081 /* Rx fifo included in design */
/* value after reset not valid */
#define XST_IIC_TBA_REG_RESET_ERROR 1082 /* 10 bit addr incl in design */
/* value after reset not valid */
#define XST_IIC_CR_READBACK_ERROR 1083 /* Read of the control register */
/* didn't return value written */
#define XST_IIC_DTR_READBACK_ERROR 1084 /* Read of the data Tx reg */
/* didn't return value written */
#define XST_IIC_DRR_READBACK_ERROR 1085 /* Read of the data Receive reg */
/* didn't return value written */
#define XST_IIC_ADR_READBACK_ERROR 1086 /* Read of the data Tx reg */
/* didn't return value written */
#define XST_IIC_TBA_READBACK_ERROR 1087 /* Read of the 10 bit addr reg */
/* didn't return written value */
#define XST_IIC_NOT_SLAVE 1088 /* The device isn't a slave */
/*********************** ATMC statuses 1101 - 1125 ***************************/
#define XST_ATMC_ERROR_COUNT_MAX 1101L /* the error counters in the ATM
controller hit the max value
which requires the statistics
to be cleared */
/*********************** Flash statuses 1126 - 1150 **************************/
#define XST_FLASH_BUSY 1126L /* Flash is erasing or programming
*/
#define XST_FLASH_READY 1127L /* Flash is ready for commands */
#define XST_FLASH_ERROR 1128L /* Flash had detected an internal
error. Use XFlash_DeviceControl
to retrieve device specific codes
*/
#define XST_FLASH_ERASE_SUSPENDED 1129L /* Flash is in suspended erase state
*/
#define XST_FLASH_WRITE_SUSPENDED 1130L /* Flash is in suspended write state
*/
#define XST_FLASH_PART_NOT_SUPPORTED 1131L /* Flash type not supported by
driver */
#define XST_FLASH_NOT_SUPPORTED 1132L /* Operation not supported */
#define XST_FLASH_TOO_MANY_REGIONS 1133L /* Too many erase regions */
#define XST_FLASH_TIMEOUT_ERROR 1134L /* Programming or erase operation
aborted due to a timeout */
#define XST_FLASH_ADDRESS_ERROR 1135L /* Accessed flash outside its
addressible range */
#define XST_FLASH_ALIGNMENT_ERROR 1136L /* Write alignment error */
#define XST_FLASH_BLOCKING_CALL_ERROR 1137L /* Couldn't return immediately from
write/erase function with
XFL_NON_BLOCKING_WRITE/ERASE
option cleared */
#define XST_FLASH_CFI_QUERY_ERROR 1138L /* Failed to query the device */
/*********************** SPI statuses 1151 - 1175 ****************************/
#define XST_SPI_MODE_FAULT 1151 /* master was selected as slave */
#define XST_SPI_TRANSFER_DONE 1152 /* data transfer is complete */
#define XST_SPI_TRANSMIT_UNDERRUN 1153 /* slave underruns transmit register */
#define XST_SPI_RECEIVE_OVERRUN 1154 /* device overruns receive register */
#define XST_SPI_NO_SLAVE 1155 /* no slave has been selected yet */
#define XST_SPI_TOO_MANY_SLAVES 1156 /* more than one slave is being
* selected */
#define XST_SPI_NOT_MASTER 1157 /* operation is valid only as master */
#define XST_SPI_SLAVE_ONLY 1158 /* device is configured as slave-only
*/
#define XST_SPI_SLAVE_MODE_FAULT 1159 /* slave was selected while disabled */
#define XST_SPI_SLAVE_MODE 1160 /* device has been addressed as slave */
#define XST_SPI_RECEIVE_NOT_EMPTY 1161 /* device received data in slave mode */
#define XST_SPI_COMMAND_ERROR 1162 /* unrecognised command - qspi only */
/********************** OPB Arbiter statuses 1176 - 1200 *********************/
#define XST_OPBARB_INVALID_PRIORITY 1176 /* the priority registers have either
* one master assigned to two or more
* priorities, or one master not
* assigned to any priority
*/
#define XST_OPBARB_NOT_SUSPENDED 1177 /* an attempt was made to modify the
* priority levels without first
* suspending the use of priority
* levels
*/
#define XST_OPBARB_PARK_NOT_ENABLED 1178 /* bus parking by id was enabled but
* bus parking was not enabled
*/
#define XST_OPBARB_NOT_FIXED_PRIORITY 1179 /* the arbiter must be in fixed
* priority mode to allow the
* priorities to be changed
*/
/************************ Intc statuses 1201 - 1225 **************************/
#define XST_INTC_FAIL_SELFTEST 1201 /* self test failed */
#define XST_INTC_CONNECT_ERROR 1202 /* interrupt already in use */
/********************** TmrCtr statuses 1226 - 1250 **************************/
#define XST_TMRCTR_TIMER_FAILED 1226 /* self test failed */
/********************** WdtTb statuses 1251 - 1275 ***************************/
#define XST_WDTTB_TIMER_FAILED 1251L
/********************** PlbArb statuses 1276 - 1300 **************************/
#define XST_PLBARB_FAIL_SELFTEST 1276L
/********************** Plb2Opb statuses 1301 - 1325 *************************/
#define XST_PLB2OPB_FAIL_SELFTEST 1301L
/********************** Opb2Plb statuses 1326 - 1350 *************************/
#define XST_OPB2PLB_FAIL_SELFTEST 1326L
/********************** SysAce statuses 1351 - 1360 **************************/
#define XST_SYSACE_NO_LOCK 1351L /* No MPU lock has been granted */
/********************** PCI Bridge statuses 1361 - 1375 **********************/
#define XST_PCI_INVALID_ADDRESS 1361L
/********************** FlexRay constants 1400 - 1409 *************************/
#define XST_FR_TX_ERROR 1400
#define XST_FR_TX_BUSY 1401
#define XST_FR_BUF_LOCKED 1402
#define XST_FR_NO_BUF 1403
/****************** USB constants 1410 - 1420 *******************************/
#define XST_USB_ALREADY_CONFIGURED 1410
#define XST_USB_BUF_ALIGN_ERROR 1411
#define XST_USB_NO_DESC_AVAILABLE 1412
#define XST_USB_BUF_TOO_BIG 1413
#define XST_USB_NO_BUF 1414
/****************** HWICAP constants 1421 - 1429 *****************************/
#define XST_HWICAP_WRITE_DONE 1421
/****************** AXI VDMA constants 1430 - 1440 *****************************/
#define XST_VDMA_MISMATCH_ERROR 1430
/*********************** NAND Flash statuses 1441 - 1459 *********************/
#define XST_NAND_BUSY 1441L /* Flash is erasing or
* programming
*/
#define XST_NAND_READY 1442L /* Flash is ready for commands
*/
#define XST_NAND_ERROR 1443L /* Flash had detected an
* internal error.
*/
#define XST_NAND_PART_NOT_SUPPORTED 1444L /* Flash type not supported by
* driver
*/
#define XST_NAND_OPT_NOT_SUPPORTED 1445L /* Operation not supported
*/
#define XST_NAND_TIMEOUT_ERROR 1446L /* Programming or erase
* operation aborted due to a
* timeout
*/
#define XST_NAND_ADDRESS_ERROR 1447L /* Accessed flash outside its
* addressible range
*/
#define XST_NAND_ALIGNMENT_ERROR 1448L /* Write alignment error
*/
#define XST_NAND_PARAM_PAGE_ERROR 1449L /* Failed to read parameter
* page of the device
*/
#define XST_NAND_CACHE_ERROR 1450L /* Flash page buffer error
*/
#define XST_NAND_WRITE_PROTECTED 1451L /* Flash is write protected
*/
/**************************** Type Definitions *******************************/
typedef int XStatus;
/***************** Macros (Inline Functions) Definitions *********************/
/************************** Function Prototypes ******************************/
#ifdef __cplusplus
}
#endif
#endif /* end of protection macro */

View file

@ -1,164 +0,0 @@
/******************************************************************************
*
* Copyright (C) 2002 - 2014 Xilinx, Inc. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* Use of the Software is limited solely to applications:
* (a) running on a Xilinx device, or
* (b) that interact with a Xilinx device through a bus or interconnect.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* XILINX BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
* OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
* Except as contained in this notice, the name of the Xilinx shall not be used
* in advertising or otherwise to promote the sale, use or other dealings in
* this Software without prior written authorization from Xilinx.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file xutil.h
*
* This file contains utility functions such as memory test functions.
*
* <b>Memory test description</b>
*
* A subset of the memory tests can be selected or all of the tests can be run
* in order. If there is an error detected by a subtest, the test stops and the
* failure code is returned. Further tests are not run even if all of the tests
* are selected.
*
* Subtest descriptions:
* <pre>
* XUT_ALLMEMTESTS:
* Runs all of the following tests
*
* XUT_INCREMENT:
* Incrementing Value Test.
* This test starts at 'XUT_MEMTEST_INIT_VALUE' and uses the incrementing
* value as the test value for memory.
*
* XUT_WALKONES:
* Walking Ones Test.
* This test uses a walking '1' as the test value for memory.
* location 1 = 0x00000001
* location 2 = 0x00000002
* ...
*
* XUT_WALKZEROS:
* Walking Zero's Test.
* This test uses the inverse value of the walking ones test
* as the test value for memory.
* location 1 = 0xFFFFFFFE
* location 2 = 0xFFFFFFFD
* ...
*
* XUT_INVERSEADDR:
* Inverse Address Test.
* This test uses the inverse of the address of the location under test
* as the test value for memory.
*
* XUT_FIXEDPATTERN:
* Fixed Pattern Test.
* This test uses the provided patters as the test value for memory.
* If zero is provided as the pattern the test uses '0xDEADBEEF".
* </pre>
*
* <i>WARNING</i>
*
* The tests are <b>DESTRUCTIVE</b>. Run before any initialized memory spaces
* have been set up.
*
* The address, Addr, provided to the memory tests is not checked for
* validity except for the NULL case. It is possible to provide a code-space
* pointer for this test to start with and ultimately destroy executable code
* causing random failures.
*
* @note
*
* Used for spaces where the address range of the region is smaller than
* the data width. If the memory range is greater than 2 ** width,
* the patterns used in XUT_WALKONES and XUT_WALKZEROS will repeat on a
* boundry of a power of two making it more difficult to detect addressing
* errors. The XUT_INCREMENT and XUT_INVERSEADDR tests suffer the same
* problem. Ideally, if large blocks of memory are to be tested, break
* them up into smaller regions of memory to allow the test patterns used
* not to repeat over the region tested.
*
* <pre>
* MODIFICATION HISTORY:
*
* Ver Who Date Changes
* ----- ---- -------- -----------------------------------------------
* 1.00a ecm 11/01/01 First release
* 1.00a xd 11/03/04 Improved support for doxygen.
* </pre>
*
******************************************************************************/
#ifndef XUTIL_H /* prevent circular inclusions */
#define XUTIL_H /* by using protection macros */
#ifdef __cplusplus
extern "C" {
#endif
/***************************** Include Files *********************************/
#include "xbasic_types.h"
#include "xstatus.h"
/************************** Constant Definitions *****************************/
/**************************** Type Definitions *******************************/
/* xutil_memtest defines */
#define XUT_MEMTEST_INIT_VALUE 1
/** @name Memory subtests
* @{
*/
/**
* See the detailed description of the subtests in the file description.
*/
#define XUT_ALLMEMTESTS 0
#define XUT_INCREMENT 1
#define XUT_WALKONES 2
#define XUT_WALKZEROS 3
#define XUT_INVERSEADDR 4
#define XUT_FIXEDPATTERN 5
#define XUT_MAXTEST XUT_FIXEDPATTERN
/* @} */
/***************** Macros (Inline Functions) Definitions *********************/
/************************** Function Prototypes ******************************/
/* xutil_memtest prototypes */
int XUtil_MemoryTest32(u32 *Addr, u32 Words, u32 Pattern, u8 Subtest);
int XUtil_MemoryTest16(u16 *Addr, u32 Words, u16 Pattern, u8 Subtest);
int XUtil_MemoryTest8(u8 *Addr, u32 Words, u8 Pattern, u8 Subtest);
#ifdef __cplusplus
}
#endif
#endif /* end of protection macro */

File diff suppressed because it is too large Load diff

View file

@ -1,354 +0,0 @@
/******************************************************************************
*
* Copyright (C) 2002 - 2014 Xilinx, Inc. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* Use of the Software is limited solely to applications:
* (a) running on a Xilinx device, or
* (b) that interact with a Xilinx device through a bus or interconnect.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* XILINX BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
* OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
* Except as contained in this notice, the name of the Xilinx shall not be used
* in advertising or otherwise to promote the sale, use or other dealings in
* this Software without prior written authorization from Xilinx.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file xversion.c
*
* This file contains the implementation of the XVersion component. This
* component represents a version ID. It is encapsulated within a component
* so that it's type and implementation can change without affecting users of
* it.
*
* The version is formatted as X.YYZ where X = 0 - 9, Y = 00 - 99, Z = a - z
* X is the major revision, YY is the minor revision, and Z is the
* compatability revision.
*
* Packed versions are also utilized for the configuration ROM such that
* memory is minimized. A packed version consumes only 16 bits and is
* formatted as follows.
*
* <pre>
* Revision Range Bit Positions
*
* Major Revision 0 - 9 Bits 15 - 12
* Minor Revision 0 - 99 Bits 11 - 5
* Compatability Revision a - z Bits 4 - 0
*
* MODIFICATION HISTORY:
*
* Ver Who Date Changes
* ----- ---- -------- -------------------------------------------------------
* 1.00a xd 11/03/04 Improved support for doxygen.
</pre>
*
******************************************************************************/
/***************************** Include Files *********************************/
#include "xbasic_types.h"
#include "xversion.h"
/************************** Constant Definitions *****************************/
/* the following constants define the masks and shift values to allow the
* revisions to be packed and unpacked, a packed version is packed into a 16
* bit value in the following format, XXXXYYYYYYYZZZZZ, where XXXX is the
* major revision, YYYYYYY is the minor revision, and ZZZZZ is the compatability
* revision
*/
#define XVE_MAJOR_SHIFT_VALUE 12
#define XVE_MINOR_ONLY_MASK 0x0FE0
#define XVE_MINOR_SHIFT_VALUE 5
#define XVE_COMP_ONLY_MASK 0x001F
/* the following constants define the specific characters of a version string
* for each character of the revision, a version string is in the following
* format, "X.YYZ" where X is the major revision (0 - 9), YY is the minor
* revision (00 - 99), and Z is the compatability revision (a - z)
*/
#define XVE_MAJOR_CHAR 0 /* major revision 0 - 9 */
#define XVE_MINOR_TENS_CHAR 2 /* minor revision tens 0 - 9 */
#define XVE_MINOR_ONES_CHAR 3 /* minor revision ones 0 - 9 */
#define XVE_COMP_CHAR 4 /* compatability revision a - z */
#define XVE_END_STRING_CHAR 5
/**************************** Type Definitions *******************************/
/***************** Macros (Inline Functions) Definitions *********************/
/************************** Function Prototypes ******************************/
static int IsVersionStringValid(char *StringPtr);
/*****************************************************************************/
/**
*
* Unpacks a packed version into the specified version. Versions are packed
* into the configuration ROM to reduce the amount storage. A packed version
* is a binary format as oppossed to a non-packed version which is implemented
* as a string.
*
* @param InstancePtr points to the version to unpack the packed version into.
* @param PackedVersion contains the packed version to unpack.
*
* @return None.
*
* @note None.
*
******************************************************************************/
void XVersion_UnPack(XVersion *InstancePtr, u16 PackedVersion)
{
(void) InstancePtr;
(void) PackedVersion;
/* not implemented yet since CROM related */
}
/*****************************************************************************/
/**
*
* Packs a version into the specified packed version. Versions are packed into
* the configuration ROM to reduce the amount storage.
*
* @param InstancePtr points to the version to pack.
* @param PackedVersionPtr points to the packed version which will receive
* the new packed version.
*
* @return
*
* A status, XST_SUCCESS, indicating the packing was accomplished
* successfully, or an error, XST_INVALID_VERSION, indicating the specified
* input version was not valid such that the pack did not occur
* <br><br>
* The packed version pointed to by PackedVersionPtr is modified with the new
* packed version if the status indicates success.
*
* @note
*
* None.
*
******************************************************************************/
int XVersion_Pack(XVersion *InstancePtr, u16 *PackedVersionPtr)
{
/* not implemented yet since CROM related */
(void) InstancePtr;
(void) PackedVersionPtr;
return XST_SUCCESS;
}
/*****************************************************************************/
/**
*
* Determines if two versions are equal.
*
* @param InstancePtr points to the first version to be compared.
* @param VersionPtr points to a second version to be compared.
*
* @return
*
* TRUE if the versions are equal, FALSE otherwise.
*
* @note
*
* None.
*
******************************************************************************/
int XVersion_IsEqual(XVersion *InstancePtr, XVersion *VersionPtr)
{
u8 *Version1 = (u8 *) InstancePtr;
u8 *Version2 = (u8 *) VersionPtr;
u32 Index;
/* assert to verify input arguments */
XASSERT_NONVOID(InstancePtr != NULL);
XASSERT_NONVOID(VersionPtr != NULL);
/* check each byte of the versions to see if they are the same,
* return at any point a byte differs between them
*/
for (Index = 0; Index < sizeof(XVersion); Index++) {
if (Version1[Index] != Version2[Index]) {
return FALSE;
}
}
/* No byte was found to be different between the versions, so indicate
* the versions are equal
*/
return TRUE;
}
/*****************************************************************************/
/**
*
* Converts a version to a null terminated string.
*
* @param InstancePtr points to the version to convert.
* @param StringPtr points to the string which will be the result of the
* conversion. This does not need to point to a null terminated
* string as an input, but must point to storage which is an adequate
* amount to hold the result string.
*
* @return
*
* The null terminated string is inserted at the location pointed to by
* StringPtr if the status indicates success.
*
* @note
*
* It is necessary for the caller to have already allocated the storage to
* contain the string. The amount of memory necessary for the string is
* specified in the version header file.
*
******************************************************************************/
void XVersion_ToString(XVersion *InstancePtr, char *StringPtr)
{
/* assert to verify input arguments */
XASSERT_VOID(InstancePtr != NULL);
XASSERT_VOID(StringPtr != NULL);
/* since version is implemented as a string, just copy the specified
* input into the specified output
*/
XVersion_Copy(InstancePtr, (XVersion *) StringPtr);
}
/*****************************************************************************/
/**
*
* Initializes a version from a null terminated string. Since the string may not
* be a format which is compatible with the version, an error could occur.
*
* @param InstancePtr points to the version which is to be initialized.
* @param StringPtr points to a null terminated string which will be
* converted to a version. The format of the string must match the
* version string format which is X.YYX where X = 0 - 9, YY = 00 - 99,
* Z = a - z.
*
* @return
*
* A status, XST_SUCCESS, indicating the conversion was accomplished
* successfully, or XST_INVALID_VERSION indicating the version string format
* was not valid.
*
* @note
*
* None.
*
******************************************************************************/
int XVersion_FromString(XVersion *InstancePtr, char *StringPtr)
{
/* assert to verify input arguments */
XASSERT_NONVOID(InstancePtr != NULL);
XASSERT_NONVOID(StringPtr != NULL);
/* if the version string specified is not valid, return an error */
if (!IsVersionStringValid(StringPtr)) {
return XST_INVALID_VERSION;
}
/* copy the specified string into the specified version and indicate the
* conversion was successful
*/
XVersion_Copy((XVersion *) StringPtr, InstancePtr);
return XST_SUCCESS;
}
/*****************************************************************************/
/**
*
* Copies the contents of a version to another version.
*
* @param InstancePtr points to the version which is the source of data for
* the copy operation.
* @param VersionPtr points to another version which is the destination of
* the copy operation.
*
* @return
*
* None.
*
* @note
*
* None.
*
******************************************************************************/
void XVersion_Copy(XVersion *InstancePtr, XVersion *VersionPtr)
{
u8 *Source = (u8 *) InstancePtr;
u8 *Destination = (u8 *) VersionPtr;
u32 Index;
/* assert to verify input arguments */
XASSERT_VOID(InstancePtr != NULL);
XASSERT_VOID(VersionPtr != NULL);
/* copy each byte of the source version to the destination version */
for (Index = 0; Index < sizeof(XVersion); Index++) {
Destination[Index] = Source[Index];
}
}
/*****************************************************************************/
/**
*
* Determines if the specified version is valid.
*
* @param StringPtr points to the string to be validated.
*
* @return
*
* TRUE if the version string is a valid format, FALSE otherwise.
*
* @note
*
* None.
*
******************************************************************************/
static int IsVersionStringValid(char *StringPtr)
{
/* if the input string is not a valid format, "X.YYZ" where X = 0 - 9,
* YY = 00 - 99, and Z = a - z, then indicate it's not valid
*/
if ((StringPtr[XVE_MAJOR_CHAR] < '0') ||
(StringPtr[XVE_MAJOR_CHAR] > '9') ||
(StringPtr[XVE_MINOR_TENS_CHAR] < '0') ||
(StringPtr[XVE_MINOR_TENS_CHAR] > '9') ||
(StringPtr[XVE_MINOR_ONES_CHAR] < '0') ||
(StringPtr[XVE_MINOR_ONES_CHAR] > '9') ||
(StringPtr[XVE_COMP_CHAR] < 'a') ||
(StringPtr[XVE_COMP_CHAR] > 'z')) {
return FALSE;
}
return TRUE;
}

View file

@ -1,108 +0,0 @@
/******************************************************************************
*
* Copyright (C) 2002 - 2014 Xilinx, Inc. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* Use of the Software is limited solely to applications:
* (a) running on a Xilinx device, or
* (b) that interact with a Xilinx device through a bus or interconnect.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* XILINX BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
* OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
* Except as contained in this notice, the name of the Xilinx shall not be used
* in advertising or otherwise to promote the sale, use or other dealings in
* this Software without prior written authorization from Xilinx.
*
******************************************************************************/
/*****************************************************************************/
/**
* @file xversion.h
*
* This file contains the interface for the XVersion component. This
* component represents a version ID. It is encapsulated within a component
* so that it's type and implementation can change without affecting users of
* it.
*
* The version is formatted as X.YYZ where X = 0 - 9, Y = 00 - 99, Z = a - z
* X is the major revision, YY is the minor revision, and Z is the
* compatability revision.
*
* Packed versions are also utilized for the configuration ROM such that
* memory is minimized. A packed version consumes only 16 bits and is
* formatted as follows.
*
* <pre>
* Revision Range Bit Positions
*
* Major Revision 0 - 9 Bits 15 - 12
* Minor Revision 0 - 99 Bits 11 - 5
* Compatability Revision a - z Bits 4 - 0
*
* MODIFICATION HISTORY:
*
* Ver Who Date Changes
* ----- ---- -------- -------------------------------------------------------
* 1.00a xd 11/03/04 Improved support for doxygen.
* </pre>
*
******************************************************************************/
#ifndef XVERSION_H /* prevent circular inclusions */
#define XVERSION_H /* by using protection macros */
#ifdef __cplusplus
extern "C" {
#endif
/***************************** Include Files *********************************/
#include "xbasic_types.h"
#include "xstatus.h"
/************************** Constant Definitions *****************************/
/**************************** Type Definitions *******************************/
/* the following data type is used to hold a null terminated version string
* consisting of the following format, "X.YYX"
*/
typedef char XVersion[6];
/***************** Macros (Inline Functions) Definitions *********************/
/************************** Function Prototypes ******************************/
void XVersion_UnPack(XVersion *InstancePtr, u16 PackedVersion);
int XVersion_Pack(XVersion *InstancePtr, u16 *PackedVersion);
int XVersion_IsEqual(XVersion *InstancePtr, XVersion *VersionPtr);
void XVersion_ToString(XVersion *InstancePtr, char *StringPtr);
int XVersion_FromString(XVersion *InstancePtr, char *StringPtr);
void XVersion_Copy(XVersion *InstancePtr, XVersion *VersionPtr);
#ifdef __cplusplus
}
#endif
#endif /* end of protection macro */

View file

@ -42,43 +42,14 @@
#--------------------------------
proc generate {drv_handle} {
# This returns the C_FAMILY parameter from the processor.
# MicroBlaze has C_FAMILY defined, but PowerPC does not.
set sw_proc_handle [get_sw_processor]
set prochandle [get_cells [get_property HW_INSTANCE $sw_proc_handle] ]
set proctype [string tolower [get_property SPECIAL $prochandle]]
set family [string tolower [get_property CONFIG.C_FAMILY $prochandle]]
# Create a definition in a header file
set filename "./src/xhwicap_family.h"
set filehandle [ open $filename a ]
::hsm::utils::write_c_header $filehandle "Device family"
if {[string compare $family "kintex7"] == 0} {
puts $filehandle "#define XHI_FPGA_FAMILY 7\n"
} elseif {[string compare $family "virtex7"] == 0} {
puts $filehandle "#define XHI_FPGA_FAMILY 8\n"
} elseif {[string compare $family "artix7"] == 0} {
puts $filehandle "#define XHI_FPGA_FAMILY 9\n"
} elseif {[string compare $family "zynq"] == 0} {
puts $filehandle "#define XHI_FPGA_FAMILY 10\n"
} elseif {[string compare $family "kintex8"] == 0} {
puts $filehandle "#define XHI_FPGA_FAMILY 11\n"
} elseif {[string compare $family "kintexu"] == 0} {
puts $filehandle "#define XHI_FPGA_FAMILY 11\n"
} else {
puts $filehandle "#define XHI_FPGA_FAMILY 1\n"
}
close $filehandle
# Generate #defines in xparameters.h
::hsi::utils::define_include_file $drv_handle "xparameters.h" "XHwIcap" "NUM_INSTANCES" "C_BASEADDR" "C_HIGHADDR" "DEVICE_ID" "C_ICAP_DWIDTH" "C_MODE"
xdefine_include_file $drv_handle "xparameters.h" "XHwIcap" "NUM_INSTANCES" "C_BASEADDR" "C_HIGHADDR" "DEVICE_ID" "C_ICAP_DWIDTH" "C_MODE"
# Generate the _g.c configuration file
::hsi::utils::define_config_file $drv_handle "xhwicap_g.c" "XHwIcap" "DEVICE_ID" "C_BASEADDR" "C_ICAP_DWIDTH" "C_MODE"
xdefine_config_file $drv_handle "xhwicap_g.c" "XHwIcap" "DEVICE_ID" "C_BASEADDR" "C_ICAP_DWIDTH" "C_MODE"
::hsi::utils::define_canonical_xpars $drv_handle "xparameters.h" "HwIcap" "DEVICE_ID" "C_BASEADDR" "C_HIGHADDR" "C_ICAP_DWIDTH" "C_MODE"
xdefine_canonical_xpars $drv_handle "xparameters.h" "HwIcap" "DEVICE_ID" "C_BASEADDR" "C_HIGHADDR" "C_ICAP_DWIDTH" "C_MODE"
}

View file

@ -37,7 +37,7 @@
## @BEGIN_CHANGELOG EDK_I
##
## - include header files
##
##
## @END_CHANGELOG
## @BEGIN_CHANGELOG EDK_H
@ -45,7 +45,7 @@
## - Added support for generation of multiple applications.
## All TCL procedures are now required to have a software
## project type as its first argument
##
##
## @END_CHANGELOG
# Uses $XILINX_EDK/bin/lib/xillib_sw.tcl
@ -93,10 +93,10 @@ proc gen_testfunc_call {swproj mhsinst} {
if {$swproj == 0} {
return ""
}
set ipname [common::get_property NAME $mhsinst]
set ipname [get_property NAME $mhsinst]
set deviceid [::hsi::utils::get_ip_param_name $mhsinst "DEVICE_ID"]
set stdout [common::get_property CONFIG.STDOUT [hsi::get_os]]
set stdout [get_property CONFIG.STDOUT [get_os]]
if { $stdout == "" || $stdout == "none" } {
set hasStdout 0
} else {
@ -111,7 +111,7 @@ proc gen_testfunc_call {swproj mhsinst} {
{
int status;
status = IicSelfTestExample(${deviceid});
}"
@ -121,12 +121,12 @@ proc gen_testfunc_call {swproj mhsinst} {
{
int status;
print(\"\\r\\n Running IicSelfTestExample() for ${ipname}...\\r\\n\");
status = IicSelfTestExample(${deviceid});
if (status == 0) {
print(\"IicSelfTestExample PASSED\\r\\n\");
}
@ -138,4 +138,3 @@ proc gen_testfunc_call {swproj mhsinst} {
return $testfunc_call
}

View file

@ -1,275 +0,0 @@
/******************************************************************************
*
* XILINX IS PROVIDING THIS DESIGN, CODE, OR INFORMATION "AS IS"
* AS A COURTESY TO YOU, SOLELY FOR USE IN DEVELOPING PROGRAMS AND
* SOLUTIONS FOR XILINX DEVICES. BY PROVIDING THIS DESIGN, CODE,
* OR INFORMATION AS ONE POSSIBLE IMPLEMENTATION OF THIS FEATURE,
* APPLICATION OR STANDARD, XILINX IS MAKING NO REPRESENTATION
* THAT THIS IMPLEMENTATION IS FREE FROM ANY CLAIMS OF INFRINGEMENT,
* AND YOU ARE RESPONSIBLE FOR OBTAINING ANY RIGHTS YOU MAY REQUIRE
* FOR YOUR IMPLEMENTATION. XILINX EXPRESSLY DISCLAIMS ANY
* WARRANTY WHATSOEVER WITH RESPECT TO THE ADEQUACY OF THE
* IMPLEMENTATION, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OR
* REPRESENTATIONS THAT THIS IMPLEMENTATION IS FREE FROM CLAIMS OF
* INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
* FOR A PARTICULAR PURPOSE.
*
* (c) Copyright 2008 Xilinx Inc.
* All rights reserved.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file ct.h
*
* Code test (CT) utility driver.
*
* This package is intented to help designers test their Xilinx device drivers
* in unit and integration testing environments. The macros and functions
* provide the following services:
*
* - Automated data comparison
* - Xilinx driver assert testing
* - Interrupt utilities
* - Error & message logging
* - Test sequencing utilities
* - Timing utilities
*
* The main benefit of this package is to simplify test code and make it easier
* for the tester to get more coverage in their integration and unit testing
* without having to replicate common testing constructs.
*
* <b>Integrating CT Source code</b>
*
* This package consists of this header file and an implementation file. The
* implementation can be operating system specific. When including this package
* in your test, use this file and one of the CT implementation files such as
* ct_vxworks.c.
*
* There are GNU specific "C" extensions used in this package and as a result
* make it non-ANSI compliant. The tester must compile this package and their
* other test code with the GNU compiler suite.
*
* The CT package requires that there be available standard header files
* stdio.h, string.h, and stdarg.h.
*
*
* <b>Setup and Test Sequencing</b>
*
* Before calling any comparison or utility function in this package, the tester
* should call CT_Init() to initialize the library. This function only needs to
* be called once.
*
* During tests, your code may be segmented into subtests where you would want
* separate out the results. At the end of all subtests, you may want to
* summarize all the tests run. The following pseudo code shows how this is done
* with CT sequencing function calls:
*
* <pre>
*
* CT_Init();
*
* // Subtest #1
* CT_TestReset("This is my Subtest #1");
* ...
* // Subtest code
* ...
* Failures = CT_GetTestFailures();
* CT_Message("Subtest #1 had %d failures\n", Failures);
*
* // Subtest #2
* CT_TestReset("This is my Subtest #2");
* ...
* // Subtest code
* ...
* Failures = CT_GetTestFailures();
* CT_Message("Subtest #2 had %d failures\n", Failures);
*
* Failures = CT_GetTotalFailures();
* CT_Message("Total test failures = %d\n", Failures);
*
* </pre>
*
* <b>General Usage</b>
*
* The heart of this package utilizes macros to compare variables or memory
* areas. For example,
*
* <pre>
*
* CT_CMP_NUM(int, ActualValue, ExpectedValue);
*
* </pre>
*
* compares two values of type int. If they are not equal, then an error message
* is logged and an internal counter is incremented. If they are equal, then the
* test proceeds as if nothing had occurred. Other examples:
*
* <pre>
*
* CT_CMP_NUM(int, *ActualPtr, 5);
* CT_CMP_NUM(int*, ActualPtr, 0x20002100);
*
* </pre>
*
* With each failure, a descriptive message is printed along with the line
* number of the invoking code.
*
* If the tester needs to make a comparison manually, then they can use the
* CT_LOG_FAILURE() macro to note the error in case the comparison is negative.
* If the tester needs to emit an informational message, then they can use the
* CT_Mesage() function. Calling this function does not increment error
* counters.
*
*
* <b>Message Logging</b>
*
* This package uses the printf() library for message logging.
*
* Ideally, the tester's environment should include some sort of UART. By
* default CT utilizes a pre configured console UART.
*
* If your system does not contain a UART, then another method of providing
* results includes printf'ing messages to memory. To enable this method,
* enable the definition of IO_USE_BUFFER in this file. To further tailor this
* method of logging, change IO_BUF_SIZE and IO_BUF_CUSHION. All output will
* be written to the TextBuf array. Use your debugger or your own test
* utilities to examine this buffer for generated output.
*
*
* <b>Limitations</b>
*
* - This package must be compiled under the GNU compiler suite.
* - CT_CMP macros can compare only ordinal data types. Structure type
* comparisons require the tester to implement their own function.
* - Some sort of BSP is required to support implementation of string.h,
* stdio.h, and stdarg.h at a minimum.
* - Advanced BSP support of signal.h is required to use CT_SetAlarm().
* If support is not available, then this function will return an error.
* - Testing asserts requires that NDEBUG not be defined in your driver under
* test code.
*
* <pre>
* MODIFICATION HISTORY:
*
* Ver Who Date Changes
* --- ---- -------- -----------------------------------------------
* 1 rmm 12/23/03 First release for VxWorks
* </pre>
*
******************************************************************************/
#ifndef CT_H
#define CT_H
/***************************** Include Files *********************************/
#include "xil_types.h" /* Needed for assert testing */
#include "xil_assert.h"
#include <stdio.h>
#include <string.h>
#include <stdarg.h>
/************************** Constant Definitions *****************************/
/*
* This is what the CT_Log* lines will be prepended with. The numerical arg
* should be the line number within the source file containing the call to
* the CT library function or macro.
*/
#define CT_ERR_FMT "FAIL: %04d: "
/**************************** Type Definitions *******************************/
/***************** Macros (Inline Functions) Definitions *********************/
/*****************************************************************************/
/**
*
* Log a failure with a supplied message. This provides a useful wrapper
* around the CT_LogFailure function that prints messages of the same format
* as other CT macros:
*
* <pre>
* 1 int i;
* 2
* 3 i = 10;
* 4 if (i != 5)
* 5 {
* 6 CT_LOG_FAILURE("GetDataFromDevice() returned %d instead of 5", i);
* 7 CT_LOG_FAILURE("D'oh");
* 8 }
*
* yields the output:
*
* FAIL: 0006: GetDataFromDevice() returned 10 instead of 5
* FAIL: 0007: D'oh
* </pre>
*
* @param fmt is a printf style format string
* @param args is a variable argument list that matches fields in the
* fmt string.
* @note
* Usage: CT_LOG_FAILURE(char* fmt, ...)
*
*****************************************************************************/
#define CT_LOG_FAILURE(fmt, args...) \
CT_LogFailure(CT_ERR_FMT fmt "\n", __LINE__ , ## args)
/*****************************************************************************/
/**
*
* Compare numbers. If not equal, then output message and increment fail
* counter. The message contains the line number of the failure, the
* name of the variable, and its actual and expected values in hex and
* decimal. An example:
*
* <pre>
* 1 UINT32 result = 5;
* 2 UINT32 expected = 17;
* 3
* 4 CT_CMP_NUM(UINT32, result, expected)
*
* yields the output:
*
* FAIL: 0004: result=5(5h), expected 17(11h)
*
* </pre>
*
* @param type is data type to compare (must be an ordinal type such as
* int)
* @param actual is the actual data retrieved from test
* @param expected is the expected value
*
* @note Usage: CT_CMP_NUM(<type>, actual, expected)
*
****************************************************************************/
#define CT_CMP_NUM(type, actual, expected) \
if ((type)(actual) != (type)(expected)) \
{ \
CT_LogFailure(CT_ERR_FMT "%s=%d(%Xh), expected %d(%Xh)\n", \
__LINE__, #actual, (int)actual, (int)actual, \
(int)expected, (int)expected); \
}
/************************** Function Prototypes ******************************/
void CT_Init(void);
void CT_TestReset(char *fmt, ...);
void CT_NotifyNextPass(void);
void CT_LogFailure(char* fmt, ...);
unsigned CT_GetTestFailures(void);
unsigned CT_GetTotalFailures(void);
void CT_Message(char *fmt, ...);
void CT_MemSet(void *Address, char Value, unsigned Bytes);
int CT_IsAssertDisabled(void);
void CT_VerboseOn(void);
void CT_VerboseOff(void);
int CT_GetUserInput(char* Prompt, char* Response, int MaxChars);
extern char inbyte(void); /* Implemented by standalone BSP */
extern void outbyte(char); /* Implemented by standalone BSP */
#endif /* CT_H */

View file

@ -1,366 +0,0 @@
/******************************************************************************
*
* XILINX IS PROVIDING THIS DESIGN, CODE, OR INFORMATION "AS IS"
* AS A COURTESY TO YOU, SOLELY FOR USE IN DEVELOPING PROGRAMS AND
* SOLUTIONS FOR XILINX DEVICES. BY PROVIDING THIS DESIGN, CODE,
* OR INFORMATION AS ONE POSSIBLE IMPLEMENTATION OF THIS FEATURE,
* APPLICATION OR STANDARD, XILINX IS MAKING NO REPRESENTATION
* THAT THIS IMPLEMENTATION IS FREE FROM ANY CLAIMS OF INFRINGEMENT,
* AND YOU ARE RESPONSIBLE FOR OBTAINING ANY RIGHTS YOU MAY REQUIRE
* FOR YOUR IMPLEMENTATION. XILINX EXPRESSLY DISCLAIMS ANY
* WARRANTY WHATSOEVER WITH RESPECT TO THE ADEQUACY OF THE
* IMPLEMENTATION, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OR
* REPRESENTATIONS THAT THIS IMPLEMENTATION IS FREE FROM CLAIMS OF
* INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
* FOR A PARTICULAR PURPOSE.
*
* (c) Copyright 2014 Xilinx Inc.
* All rights reserved.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file ct_standalone.c
*
* Implements Code test (CT) utility driver. Test.
*
* <pre>
* MODIFICATION HISTORY:
*
* Ver Who Date Changes
* ----- ------ -------- -----------------------------------------------
* 7.0 adk 01/09/14 First release.
* </pre>
*
******************************************************************************/
/***************************** Include Files *********************************/
#include <stdio.h>
#include <string.h>
#include <stdarg.h>
#include <unistd.h>
#include "ct.h"
/************************** Constant Definitions *****************************/
/**************************** Type Definitions *******************************/
/***************** Macros (Inline Functions) Definitions *********************/
/************************** Function Prototypes ******************************/
/************************** Variable Definitions *****************************/
unsigned CT_TotalFailures;
unsigned CT_TestFailures;
unsigned CT_TestPass;
static int Verbose = 0; /* Verbosity flag */
/*****************************************************************************/
/**
*
* Initialize the CT subsystem.
*
* @return None
*
******************************************************************************/
void CT_Init(void)
{
CT_TestFailures = 0;
CT_TotalFailures = 0;
CT_TestPass = 0;
}
/*****************************************************************************/
/**
*
* Reset for a new test and display a test specific message. This involves:
*
* - Zero out test failure counter.
* - Print a message specified by the fmt parameter and its associated
* arguments.
*
* @param Fmt is a "printf" style format string.
* @param ... is a variable number of arguments that match "Fmt"
*
* @return None
*
******************************************************************************/
void CT_TestReset(char *Fmt, ...)
{
va_list Args;
CT_TestFailures = 0;
CT_TestPass = 1;
/*
* Print out the format and its associated argument list
*/
va_start(Args, Fmt);
vprintf(Fmt, Args);
CT_Message("\n========================================================");
va_end(Args);
CT_Message("\n");
}
/*****************************************************************************/
/**
* Display current test pass number to user
*
* @return None
*
******************************************************************************/
void CT_NotifyNextPass(void)
{
CT_Message("\n=====>Pass %d\n", CT_TestPass++);
}
/*****************************************************************************/
/**
*
* Log a test failure. This involves incrementing test failure and total test
* failure counters, and displaying test specific message.
*
* @param Fmt is a "printf" style format string.
* @param ... is a variable number of arguments that match "fmt"
*
* @return None
*
******************************************************************************/
void CT_LogFailure(char* Fmt, ...)
{
va_list Args;
/*
* Increment failure counters
*/
CT_TestFailures++;
CT_TotalFailures++;
/*
* Print out the format and its associated argument list.
*/
va_start(Args, Fmt);
vprintf(Fmt, Args);
va_end(Args);
}
/*****************************************************************************/
/**
*
* Return the number of test failures since CT_TestReset() was called.
*
* @return Number of failures logged.
*
******************************************************************************/
unsigned CT_GetTestFailures(void)
{
return(CT_TestFailures);
}
/*****************************************************************************/
/**
*
* Return the number of test failures since CT_Init() was called.
*
* @return Total number of failures logged.
*
******************************************************************************/
unsigned CT_GetTotalFailures(void)
{
return(CT_TotalFailures);
}
/*****************************************************************************/
/**
* Return status of the Xilinx driver assert mechanism.
*
* @return 1 if asserts are disabled, 0 otherwise
*
*****************************************************************************/
int CT_IsAssertDisabled(void)
{
#ifdef NDEBUG
return(1);
#else
return(0);
#endif
}
/*****************************************************************************/
/**
*
* Print a message based on the given format string and parameters.
*
* @param Fmt is a "printf" style format string.
* @param ... is a variable number of arguments that match "fmt"
*
* @return None
*
******************************************************************************/
void CT_Message(char *Fmt, ...)
{
va_list Args;
va_start(Args, Fmt);
vprintf(Fmt, Args);
va_end(Args);
}
/*****************************************************************************/
/**
*
* Set a series of bytes in memory to a specific value
*
* @param AddressPtr is the start address in memory to write
* @param Value is the value to set memory to
* @param Bytes is the number of bytes to set
*
* @return None
*
******************************************************************************/
void CT_MemSet(void *AddressPtr, char Value, unsigned Bytes)
{
char* AdrPtr = AddressPtr;
while(Bytes--)
{
*AdrPtr++ = Value;
}
}
/*****************************************************************************/
/**
*
* Retrieve a line of input from the user. A line is defined as all characters
* up to a new line.
*
* @param PromptPtr Printed before string is accepted to que the user to
* enter something.
*
* @param ResponsePtr Null terminated string with new line stripped
*
* @param MaxChars Maximum number of characters to read (excluding null)
*
* @return Number of characters read (excluding new line)
*
* @note None
*
******************************************************************************/
int CT_GetUserInput(char* PromptPtr, char* ResponsePtr, int MaxChars)
{
u32 Index;
u8 Finished;
/*
* Display prompt
*/
if (PromptPtr) printf(PromptPtr);
/*
* This basically implements a fgets function. The standalone EDK stdin
* is apparently buggy because it behaves differently when new line is
* entered by itself vs. when it is entered after a number of regular chars
* have been entered.Characters entered are echoed back.
*/
Finished = 0;
Index = 0;
while(!Finished)
{
/*
* Flush out any output pending in stdout
*/
fflush(stdout);
/*
* Wait for a character to arrive
*/
ResponsePtr[Index] = inbyte();
/*
* Normal chars, add them to the string and keep going
*/
if ((ResponsePtr[Index] >= 0x20) && (ResponsePtr[Index] <=0x7E))
{
printf("%c", ResponsePtr[Index++]);
continue;
}
/*
* Control chars
*/
switch(ResponsePtr[Index])
{
/*
* Carriage return
*/
case '\r':
case '\n':
ResponsePtr[Index] = 0;
Finished = 1;
printf("\n");
break;
/*
* Backspace
*/
case 0x08:
if (Index != 0)
{
/*
* Erase previous character and move cursor back one space
*/
printf("\b \b");
ResponsePtr[--Index] = 0;
}
break;
/*
* Ignore all other control chars
*/
default:
continue;
}
}
return(Index);
}
/*****************************************************************************/
/**
*
* Enable output of CT_MessageV().
*
* @return None
*
* @note None
*
******************************************************************************/
void CT_VerboseOn(void)
{
Verbose = 1;
}
/*****************************************************************************/
/**
* Disable output of CT_MessageV().
*
* @return None
*
* @note None
*
******************************************************************************/
void CT_VerboseOff(void)
{
Verbose = 0;
}

View file

@ -1,671 +0,0 @@
/******************************************************************************
*
* XILINX IS PROVIDING THIS DESIGN, CODE, OR INFORMATION "AS IS"
* AS A COURTESY TO YOU, SOLELY FOR USE IN DEVELOPING PROGRAMS AND
* SOLUTIONS FOR XILINX DEVICES. BY PROVIDING THIS DESIGN, CODE,
* OR INFORMATION AS ONE POSSIBLE IMPLEMENTATION OF THIS FEATURE,
* APPLICATION OR STANDARD, XILINX IS MAKING NO REPRESENTATION
* THAT THIS IMPLEMENTATION IS FREE FROM ANY CLAIMS OF INFRINGEMENT,
* AND YOU ARE RESPONSIBLE FOR OBTAINING ANY RIGHTS YOU MAY REQUIRE
* FOR YOUR IMPLEMENTATION. XILINX EXPRESSLY DISCLAIMS ANY
* WARRANTY WHATSOEVER WITH RESPECT TO THE ADEQUACY OF THE
* IMPLEMENTATION, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OR
* REPRESENTATIONS THAT THIS IMPLEMENTATION IS FREE FROM CLAIMS OF
* INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
* FOR A PARTICULAR PURPOSE.
*
* (c) Copyright 2014 Xilinx Inc.
* All rights reserved.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file scaler_intg_basic.c
*
* @note
*
* This test works with Zynq702 system.
*
* <pre>
*
* MODIFICATION HISTORY:
*
* Ver Who Date Changes
* ----- ------ -------- ---------------------------------------------
* 7.0 adk 22/08/14 First release.
* </pre>
*
******************************************************************************/
/***************************** Include Files *********************************/
#include "xscaler.h"
#include "xscaler_hw.h"
#include "xparameters.h"
#include "scaler_intgtest.h"
/************************** Constant Definitions *****************************/
/***************** Macros (Inline Functions) Definitions *********************/
/*****************************************************************************/
/**
*
* Compare numbers. If not equal, then output message and increment fail
* counter. The message contains the line number of the failure, the
* name of the variable, and its actual and expected values in hex and
* decimal. If equal, display current test pass number to user.
* An example:
*
* <pre>
* 1 UINT32 result = 5;
* 2 UINT32 expected = 17;
* 3
* 4 CT_CMP_NUM(UINT32, result, expected)
*
* yields the output:
*
* FAIL: 0004: result=5(5h), expected 17(11h)
* </pre>
*
* @param Type is data type to compare (must be an ordinal type such
* as int)
* @param Val_16 is the actual data retrieved from test
* @param Val_32 is the expected value
*
* @note Usage: CT_CMP_NUM(<type>, actual, expected)
*
*****************************************************************************/
#define check_status_update(Type, Val_16, Val_32) \
if((Type)(Val_16) != (Type)(Val_32)){ \
CT_CMP_NUM(Type, XST_FAILURE, XST_SUCCESS); \
} \
else{ \
CT_NotifyNextPass(); \
} \
/**************************** Type Definitions *******************************/
#define round(x) ((x) >= 0 ? (s32)((x) + 0.5) : (s32)((x) - 0.5))
/************************** Function Prototypes ******************************/
/************************** Variable Definitions *****************************/
/************************** Function Definitions *****************************/
/*****************************************************************************/
/**
*
* This function executes the XScaler Self test.
*
* @param TestLoops is the number of times to execute test.
*
* @return Returns the total number of test failures.
*
* @note None.
*
******************************************************************************/
int Scaler_Intg_SelfTest(int TestLoops)
{
u32 Status = (u32)XST_SUCCESS;
double HoriScaleFactor;
double VertScaleFactor;
u32 OldScalerReg;
u32 NewScalerReg;
u32 LumaLeftH;
u32 LumaTopV;
u32 ChromaLeftH;
u32 ChromaTopV;
u32 OutSize;
u32 InLine;
u32 InPixel;
u32 SrcSize;
u32 QuantizedHoriSize;
u32 QuantizedVertSize;
u32 QuantizedInLastPixel;
u32 QuantizedInLastLine;
u32 PhaseRegValue;
u16 VertPhaseNum;
u16 HoriPhaseNum;
u8 ChromaFormat;
u8 ChromaLumaShareCoeff;
u8 HoriVertShareCoeff;
u8 VertSetIndex;
u8 HoriSetIndex;
u32 InLine_1;
u32 InPixel_1;
u32 OutSize_1 ;
u32 SrcSize_1 ;
double HoriScaleFactor_1;
double VertScaleFactor_1;
XScaler ScalerInst;
XScalerStartFraction StartFractionInst;
XScalerCoeffBank CoeffBankPtr;
XScalerAperture AperturePtr;
XScalerAperture AperturePtr_1;
XScaler_Config *Config;
CT_TestReset("Scaler Self Test .. ..");
while (TestLoops--) {
CT_NotifyNextPass();
/* Initialize the XScaler instance. */
Status = Scaler_Initialize(&ScalerInst, (u16)SCALER_0_DEVICE_ID);
if (Status != XST_SUCCESS) {
return Status;
}
/*****************************************************************************/
/* XScaler_GetVersion */
/*Test case 1 */
NewScalerReg = XScaler_GetVersion(&ScalerInst);
if (NewScalerReg != 0x00000000) {
check_status_update(u32, 1, 1);
}
else {
check_status_update(u32, 0, 1);
}
/*Test case 3 */
// XScaler_GetVersion(Null);
/*****************************************************************************/
/* XScaler_Disable */
/*Test case 1 */
XScaler_Disable(&ScalerInst);
if (0x0 == ((XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_CTL_OFFSET)) & ~(XSCL_CTL_SW_EN_MASK))) {
check_status_update(u32, 1, 1);
}
else {
check_status_update(u32, 0, 1);
}
/*
* Negative Test Case
*/
// XScaler_Disable(&ScalerInst);
/*****************************************************************************/
/* XScaler_Enable */
/* check the bit 0 of control register, default is 0*/
/*Test case 1 */
XScaler_Enable(&ScalerInst);
if(0x00000001 == ((XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_CTL_OFFSET)) | (XSCL_CTL_SW_EN_MASK))){
check_status_update(u32, 1, 1);
}
else{
check_status_update(u32, 0, 1);
}
XScaler_Enable(&ScalerInst);
/*****************************************************************************/
/* XScaler_SetPhaseNum */
/* Test case 1*/
VertPhaseNum = 1;
ScalerInst.Config.MaxPhaseNum = 1;
HoriPhaseNum = 1;
ScalerInst.Config.MaxPhaseNum = 1;
XScaler_SetPhaseNum(&ScalerInst, VertPhaseNum, HoriPhaseNum);
OldScalerReg = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_NUMPHASE_OFFSET);
NewScalerReg = (VertPhaseNum << XSCL_NUMPHASE_VERT_SHIFT) &
XSCL_NUMPHASE_VERT_MASK;
NewScalerReg |= HoriPhaseNum & XSCL_NUMPHASE_HORI_MASK;
if (NewScalerReg == OldScalerReg) {
check_status_update(u32, 1, 1);
}
else {
check_status_update(u32, 0, 1);
}
/* Test case 2 */
XScaler_SetPhaseNum(&ScalerInst, VertPhaseNum, HoriPhaseNum);
OldScalerReg = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_NUMPHASE_OFFSET);
if ((VertPhaseNum == (OldScalerReg & XSCL_NUMPHASE_VERT_MASK) >>
XSCL_NUMPHASE_VERT_SHIFT) &&
(HoriPhaseNum == (OldScalerReg &
XSCL_NUMPHASE_HORI_MASK))) {
check_status_update(u32, 1, 1);
}
else {
check_status_update(u32, 0, 1);
}
/*
* Negative Test Case
*/
/* Test case 3 */
//XScaler_SetPhaseNum(Null, VertPhaseNum, HoriPhaseNum);
/*****************************************************************************/
/* XScaler_GetPhaseNum */
XScaler_GetPhaseNum(&ScalerInst, &VertPhaseNum, &HoriPhaseNum);
PhaseRegValue = XScaler_ReadReg((ScalerInst).Config.BaseAddress,
XSCL_NUMPHASE_OFFSET);
OldScalerReg = (PhaseRegValue & XSCL_NUMPHASE_VERT_MASK) >>
XSCL_NUMPHASE_VERT_SHIFT;
NewScalerReg = PhaseRegValue & XSCL_NUMPHASE_HORI_MASK;
if ((NewScalerReg == HoriPhaseNum) && (OldScalerReg == VertPhaseNum)) {
check_status_update(u32, 1, 1);
}
else {
check_status_update(u32, 0, 1);
}
/*
* Negative Test Case
*/
/* Test case 3 */
//XScaler_GetPhaseNum(Null, &VertPhaseNum, &HoriPhaseNum);
/*****************************************************************************/
XScaler_SetStartFraction(&ScalerInst, &StartFractionInst);
LumaLeftH = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_FRCTLUMALEFT_OFFSET);
LumaTopV = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_FRCTLUMATOP_OFFSET);
ChromaLeftH = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_FRCTCHROMALEFT_OFFSET);
ChromaTopV = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_FRCTCHROMATOP_OFFSET);
if(((LumaLeftH)==((u32)StartFractionInst.LumaLeftHori &
XSCL_FRCTLUMALEFT_VALUE_MASK)) &&
( LumaTopV == ((u32)StartFractionInst.LumaTopVert &
XSCL_FRCTLUMATOP_VALUE_MASK)) &&
(ChromaLeftH == ((u32)StartFractionInst.ChromaLeftHori &
XSCL_FRCTCHROMALEFT_VALUE_MASK)) &&
(ChromaTopV == ((u32)StartFractionInst.ChromaTopVert &
XSCL_FRCTCHROMATOP_VALUE_MASK))) {
check_status_update(u32, 1, 1);
}
else {
check_status_update(u32, 0, 1);
}
/*
* Negative Test Case
*/
//XScaler_SetStartFraction(Null, Null1);
/*****************************************************************************/
XScaler_GetStartFraction(&ScalerInst, &StartFractionInst);
LumaLeftH = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_FRCTLUMALEFT_OFFSET) &
XSCL_FRCTLUMALEFT_VALUE_MASK;
LumaTopV = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_FRCTLUMATOP_OFFSET) &
XSCL_FRCTLUMATOP_VALUE_MASK;
ChromaLeftH = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_FRCTCHROMALEFT_OFFSET) &
XSCL_FRCTCHROMALEFT_VALUE_MASK;
ChromaTopV = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_FRCTCHROMATOP_OFFSET) &
XSCL_FRCTCHROMATOP_VALUE_MASK;
if ((LumaLeftH == StartFractionInst.LumaLeftHori) &&
(LumaTopV == StartFractionInst.LumaTopVert) &&
(ChromaLeftH == StartFractionInst.ChromaLeftHori) &&
(ChromaTopV == StartFractionInst.ChromaTopVert)) {
check_status_update(u32, 1, 1);
}
else
{
check_status_update(u32, 0, 1);
}
/*
* Negative Test Case
*/
//XScaler_GetStartFraction(Null, Null1);
/*****************************************************************************/
XScaler_GetCoeffBankSharingInfo(&ScalerInst,
&ChromaFormat,
&ChromaLumaShareCoeff,
&HoriVertShareCoeff);
if (ChromaFormat == ScalerInst.Config.ChromaFormat) {
check_status_update(u32, 1, 1);
}
else
{
check_status_update(u32, 0, 1);
}
if (ScalerInst.Config.SeparateHvCoef !=0 ) {
if (HoriVertShareCoeff == 0) {
check_status_update(u32, 1, 1);
}
else
{
check_status_update(u32, 0, 1);
}
}
else {
if (HoriVertShareCoeff == 1) {
check_status_update(u32, 1, 1);
}
else
{
check_status_update(u32, 0, 1);
}
}
if (ChromaFormat ==XSCL_CHROMA_FORMAT_422 ) {
if(ScalerInst.Config.SeparateYcCoef!=0)
{
if (ChromaLumaShareCoeff == 0) {
check_status_update(u32, 1, 1);
}
else
{
check_status_update(u32, 0, 1);
}
}
}
if(ChromaFormat == XSCL_CHROMA_FORMAT_422){
if (ChromaLumaShareCoeff == 1) {
check_status_update(u32, 1, 1);
}
else
{
check_status_update(u32, 0, 1);
}
}
/*****************************************************************************/
InLine_1= 23;
OutSize_1 = 22;
SrcSize_1 = 11 ;
InPixel_1 = 63;
XScaler_CoefValueLookup(InLine_1, OutSize_1, SrcSize_1, InPixel_1);
if(Xil_AssertStatus == XIL_ASSERT_NONE) {
check_status_update(u32, 1, 1);
}
else{
check_status_update(u32, 0, 1);
}
/*****************************************************************************/
/* Xil_AssertVoid(CoeffBankPtr->SetIndex <
InstancePtr->Config.CoeffSetNum);
Xil_AssertVoid(CoeffBankPtr->CoeffValueBuf != NULL);
Xil_AssertVoid(CoeffBankPtr->PhaseNum >= (XSCL_MIN_PHASE_NUM));
Xil_AssertVoid(CoeffBankPtr->PhaseNum <=
InstancePtr->Config.MaxPhaseNum);
Xil_AssertVoid(CoeffBankPtr->TapNum > 0U);
Xil_AssertVoid(CoeffBankPtr->TapNum <= (XSCL_MAX_TAP_NUM)); */
CoeffBankPtr.SetIndex = 1;
ScalerInst.Config.CoeffSetNum = 2;
CoeffBankPtr.PhaseNum = 6;
ScalerInst.Config.MaxPhaseNum = 6;
CoeffBankPtr.TapNum = (XSCL_MAX_TAP_NUM);
CoeffBankPtr.CoeffValueBuf = XScaler_CoefValueLookup(640, 480,CoeffBankPtr.TapNum, CoeffBankPtr.PhaseNum);
XScaler_LoadCoeffBank(&ScalerInst, &CoeffBankPtr);
NewScalerReg = CoeffBankPtr.SetIndex & XSCL_COEFFSETADDR_ADDR_MASK;
OldScalerReg = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_COEFFSETADDR_OFFSET);
if (NewScalerReg == OldScalerReg) {
check_status_update(u32, 1, 1);
}
else {
check_status_update(u32, 0, 1);
}
/*
* Negative Test Case
*/
//XScaler_LoadCoeffBank(Null, Null2);
/****************************************************************************/
VertSetIndex = 0 ;
ScalerInst.Config.CoeffSetNum = 1 ;
HoriSetIndex = 0;
ScalerInst.Config.CoeffSetNum = 1;
XScaler_SetActiveCoeffSet(&ScalerInst, VertSetIndex, HoriSetIndex);
OldScalerReg = ((u32)HoriSetIndex) & XSCL_COEFFSETS_HORI_MASK;
OldScalerReg |= (((u32)VertSetIndex) << XSCL_COEFFSETS_VERT_SHIFT) &
XSCL_COEFFSETS_VERT_MASK;
NewScalerReg = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_COEFFSETS_OFFSET);
if (NewScalerReg == OldScalerReg) {
check_status_update(u32, 1, 1);
}
else {
check_status_update(u32, 0, 1);
}
/*
* Negative Test Case
*/
//XScaler_SetActiveCoeffSet(Null, VertSetIndex, HoriSetIndex);
/*****************************************************************************/
XScaler_GetActiveCoeffSet(&ScalerInst, &VertSetIndex, &HoriSetIndex);
NewScalerReg = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_COEFFSETS_OFFSET);
if (((u8)(NewScalerReg & XSCL_COEFFSETS_VERT_MASK) >>
XSCL_COEFFSETS_VERT_SHIFT) == VertSetIndex &&
(u8)(NewScalerReg & XSCL_COEFFSETS_HORI_MASK) ==
HoriSetIndex) {
check_status_update(u32, 1, 1);
} else {
check_status_update(u32, 0, 1);
}
/*****************************************************************************/
memset((void *)&AperturePtr, 0, sizeof(XScalerAperture));
memset((void *)&AperturePtr_1, 0, sizeof(XScalerAperture));
// memset((void *)&ScalerInst, 0, sizeof(XScaler));
AperturePtr.InFirstLine = 0;
AperturePtr.InLastLine = 719;
AperturePtr.InLastPixel = 1279;
AperturePtr.InFirstPixel = 0;
AperturePtr.OutVertSize = 1280;
AperturePtr.OutHoriSize =720;
XScaler_SetAperture(&ScalerInst, &AperturePtr);
/* Calculate vertical and horizontal scale factors */
VertScaleFactor = (double)(AperturePtr.InLastLine -
AperturePtr.InFirstLine + 1.0);
VertScaleFactor /= (double)(AperturePtr.OutVertSize);
HoriScaleFactor = (double)(AperturePtr.InLastPixel -
AperturePtr.InFirstPixel + 1.0);
HoriScaleFactor /= (double)AperturePtr.OutHoriSize;
/* Convert HoriScaleFactor and VertScaleFactor values into a format
* to write to HSF and VSF registers.
*/
VertScaleFactor = (u32)(VertScaleFactor * XSCL_SHRINK_FACTOR);
HoriScaleFactor = (u32)(HoriScaleFactor * XSCL_SHRINK_FACTOR);
/* Quantize Aperture - feed scale-factor back in to provide the
* actual aperture required to generate the desired number of output
* samples.
*/
QuantizedHoriSize = AperturePtr.OutHoriSize - 1;
QuantizedHoriSize = (u32)(((double)QuantizedHoriSize *
HoriScaleFactor) / XSCL_SHRINK_FACTOR);
QuantizedHoriSize += 1 + (ScalerInst.Config.HoriTapNum + 1) / 2;
QuantizedInLastPixel = AperturePtr.InFirstPixel + QuantizedHoriSize
- 1;
if (QuantizedInLastPixel > AperturePtr.InLastPixel)
QuantizedInLastPixel = AperturePtr.InLastPixel;
QuantizedVertSize = AperturePtr.OutVertSize - 1;
QuantizedVertSize = (u32)(((float)QuantizedVertSize *
VertScaleFactor) / XSCL_SHRINK_FACTOR);
QuantizedVertSize += 1 + (ScalerInst.Config.VertTapNum + 1) / 2;
QuantizedInLastLine = AperturePtr.InFirstLine + QuantizedVertSize - 1;
if (QuantizedInLastLine > AperturePtr.InLastLine)
QuantizedInLastLine = AperturePtr.InLastLine;
/* Calculate input line, pixel and output size values */
InLine = AperturePtr.InFirstLine & XSCL_APTVERT_FIRSTLINE_MASK;
InLine |= (QuantizedInLastLine << XSCL_APTVERT_LASTLINE_SHIFT)
& XSCL_APTVERT_LASTLINE_MASK;
InPixel = AperturePtr.InFirstPixel & XSCL_APTHORI_FIRSTPXL_MASK;
InPixel |= (QuantizedInLastPixel << XSCL_APTHORI_LASTPXL_SHIFT)
& XSCL_APTHORI_LASTPXL_MASK;
OutSize = AperturePtr.OutHoriSize & XSCL_OUTSIZE_NUMPXL_MASK;
OutSize |= (AperturePtr.OutVertSize << XSCL_OUTSIZE_NUMLINE_SHIFT)
& XSCL_OUTSIZE_NUMLINE_MASK;
SrcSize = AperturePtr.SrcHoriSize & XSCL_SRCSIZE_NUMPXL_MASK;
SrcSize |= (AperturePtr.SrcVertSize << XSCL_SRCSIZE_NUMLINE_SHIFT)
& XSCL_SRCSIZE_NUMLINE_MASK;
//InLine_1 = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
// XSCL_FRCTLUMALEFT_OFFSET);
InLine_1 = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_APTVERT_OFFSET);
InPixel_1 = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_APTHORI_OFFSET);
OutSize_1 =XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_OUTSIZE_OFFSET);
SrcSize_1 =XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_SRCSIZE_OFFSET);
HoriScaleFactor_1 =XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_HSF_OFFSET);
HoriScaleFactor_1 = (u32)round(HoriScaleFactor_1);
VertScaleFactor_1=XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_VSF_OFFSET);
VertScaleFactor_1 = (u32)round(VertScaleFactor_1);
/*if ((InLine == XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_FRCTLUMALEFT_OFFSET)) && (InPixel ==
XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_APTHORI_OFFSET)) &&
(OutSize == XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_OUTSIZE_OFFSET)) &&
(SrcSize == XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_SRCSIZE_OFFSET)) &&
((u32)(round(HoriScaleFactor)) ==
XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_HSF_OFFSET)) &&
((u32)(round(VertScaleFactor)) ==
XScaler_ReadReg(ScalerInst.Config.BaseAddress,
XSCL_VSF_OFFSET))) */
if (InLine == InLine_1 && InPixel == InPixel_1 && OutSize == OutSize_1
&& SrcSize== SrcSize_1 && HoriScaleFactor == HoriScaleFactor_1
&& VertScaleFactor == VertScaleFactor_1) {
check_status_update(u32, 1, 1);
}
else {
check_status_update(u32, 0, 1);
}
/*
* Negative Test Case
*/
//XScaler_SetAperture(Null, Null3);
/****************************************************************************/
AperturePtr.InFirstLine = 0;
AperturePtr.InLastLine = 719;
AperturePtr.InLastPixel = 1279;
AperturePtr.InFirstPixel = 0;
AperturePtr.OutVertSize = 1280;
AperturePtr.OutHoriSize = 720;
XScaler_GetAperture(&ScalerInst, &AperturePtr);
InLine = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
(XSCL_APTVERT_OFFSET));
InPixel = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
(XSCL_APTHORI_OFFSET));
OutSize = XScaler_ReadReg(ScalerInst.Config.BaseAddress,
(XSCL_OUTSIZE_OFFSET));
/* Parse the info and populate the aperture structure */
AperturePtr_1.InFirstLine = (InLine) & (XSCL_APTVERT_FIRSTLINE_MASK);
AperturePtr_1.InLastLine = ((InLine) & (XSCL_APTVERT_LASTLINE_MASK)) >>
(XSCL_APTVERT_LASTLINE_SHIFT);
AperturePtr_1.InFirstPixel = (InPixel) & (XSCL_APTHORI_FIRSTPXL_MASK);
AperturePtr_1.InLastPixel = ((InPixel) &
(XSCL_APTHORI_LASTPXL_MASK)) >>
(XSCL_APTHORI_LASTPXL_SHIFT);
AperturePtr_1.OutHoriSize = (OutSize) & (XSCL_OUTSIZE_NUMPXL_MASK);
AperturePtr_1.OutVertSize = ((OutSize) &
(XSCL_OUTSIZE_NUMLINE_MASK)) >>
(XSCL_OUTSIZE_NUMLINE_SHIFT);
if(!(memcmp(&AperturePtr, &AperturePtr_1, sizeof(XScalerAperture)))) {
check_status_update(u32, 1, 1);
}
else {
check_status_update(u32, 0, 1);
}
/*
* Run XScaler self test.
*/
// Status = XScaler_SelfTest(&ScalerInst);
// if (Status != XST_SUCCESS) {
// check_status_update(u32, 0, 1);
// return XST_FAILURE;
// }
// else{
// check_status_update(u32, 1, 1);
// }
/*
* Test case for lookupconfig
*/
Config = XScaler_LookupConfig(XSCALAR_DEVICEID);
if(Config == NULL) {
check_status_update(u32, 1, 1);
}
else {
check_status_update(u32, 0, 1);
}
CT_CMP_NUM(int, Status, XST_SUCCESS);
}
return (u32)(CT_GetTestFailures());
}

View file

@ -1,237 +0,0 @@
/*****************************************************************************
*
* XILINX IS PROVIDING THIS DESIGN, CODE, OR INFORMATION "AS IS"
* AS A COURTESY TO YOU, SOLELY FOR USE IN DEVELOPING PROGRAMS AND
* SOLUTIONS FOR XILINX DEVICES. BY PROVIDING THIS DESIGN, CODE,
* OR INFORMATION AS ONE POSSIBLE IMPLEMENTATION OF THIS FEATURE,
* APPLICATION OR STANDARD, XILINX IS MAKING NO REPRESENTATION
* THAT THIS IMPLEMENTATION IS FREE FROM ANY CLAIMS OF INFRINGEMENT,
* AND YOU ARE RESPONSIBLE FOR OBTAINING ANY RIGHTS YOU MAY REQUIRE
* FOR YOUR IMPLEMENTATION. XILINX EXPRESSLY DISCLAIMS ANY
* WARRANTY WHATSOEVER WITH RESPECT TO THE ADEQUACY OF THE
* IMPLEMENTATION, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OR
* REPRESENTATIONS THAT THIS IMPLEMENTATION IS FREE FROM CLAIMS OF
* INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
* FOR A PARTICULAR PURPOSE.
*
* (c) Copyright 2014 Xilinx Inc.
* All rights reserved.
*
*****************************************************************************/
/*****************************************************************************/
/**
*
* @file scaler_intg_intr.c
*
* This file contains an integration test on Scaler driver in interrupt mode.
*
* @note
*
* This code assumes that Zynq702 is the processor in the hardware system.
*
* <pre>
* MODIFICATION HISTORY:
*
* Ver Who Date Changes
* ----- ------ -------- ---------------------------------------------
* 7.0 adk 22/08/14 First release.
* </pre>
*
******************************************************************************/
/***************************** Include Files *********************************/
#include "scaler_intgtest.h"
/************************** Constant Definitions *****************************/
/************************** Constant Definitions *****************************/
/**************************** Type Definitions *******************************/
/***************** Macros (Inline Functions) Definitions *********************/
/************************** Function Prototypes ******************************/
static int SetupInterruptSystem(XScaler *ScalerInstPtr);
/* void Handler(void *CallBackRef, u32 Event, unsigned int EventData);*/
void Handler(void *CallBackRef, u32 Event);
static int ScalerInterruptTest(int TestLoops);
/************************** Variable Definitions *****************************/
/*****************************************************************************/
/**
*
* This function setups the interrupt system so interrupts can occur for the
* SCALER core. The function is application-specific since the actual system may
* or may not have an interrupt controller. The SCALER device could be directly
* connected to a processor without an interrupt controller. The user should
* modify this function to fit the application.
*
* @param ScalerInstPtr contains a pointer to the instance of the XScaler
* which is going to be connected to the interrupt controller.
*
* @return XST_SUCCESS if successful, or a specific error code defined in
* "xstatus.h" if an error occurs.
*
* @note This function assumes a Zynq702 system and no operating system
* is used.
*
******************************************************************************/
static int SetupInterruptSystem(XScaler * ScalerInstPtr)
{
int Status;
/* The configuration parameters of the interrupt controller */
XScuGic_Config *IntcConfig;
/* Initialize the interrupt controller driver so that it is ready
* to use
*/
IntcConfig = XScuGic_LookupConfig(INTC_DEVICE_ID);
if (NULL == IntcConfig) {
return XST_FAILURE;
}
Status = XScuGic_CfgInitialize(&InterruptController, IntcConfig,
IntcConfig->CpuBaseAddress);
if (Status != XST_SUCCESS) {
return XST_FAILURE;
}
/* Connect the interrupt controller interrupt handler to the hardware
* interrupt handling logic in the Zynq702 processor.
*/
Xil_ExceptionRegisterHandler(XIL_EXCEPTION_ID_INT,
(Xil_ExceptionHandler)XScuGic_InterruptHandler,
&InterruptController);
/* Connect the device driver handler that will be called when an interrupt
* for the device occurs, the handler defined above performs the specific
* interrupt processing for the device
*/
Status = XScuGic_Connect(&InterruptController,
SCALER_INT_IRQ_ID,
(Xil_ExceptionHandler)XScaler_IntrHandler,
ScalerInstPtr);
if (Status != XST_SUCCESS) {
return Status;
}
/* Enable the interrupt for the Scaler device */
XScuGic_Enable(&InterruptController, SCALER_INT_IRQ_ID);
/* Enable interrupts in the Zynq702 */
Xil_ExceptionEnableMask(XIL_EXCEPTION_IRQ);
return XST_SUCCESS;
}
/****************************************************************************/
/**
*
* This function tests the interrupt functionality of the Scaler driver.
*
* @param TestLoops is the number of times to run the test.
*
* @return the number of errors that occurred.
*
* @note None.
*
****************************************************************************/
int Scaler_Intg_InterruptTest(int TestLoops)
{
int Status = 0;
CT_TestReset("Scaler interrupt mode test .. ..");
while (TestLoops--) {
CT_NotifyNextPass();
Status = ScalerInterruptTest(TestLoops);
}
CT_CMP_NUM(int, Status, XST_SUCCESS);
return (CT_GetTestFailures());
}
/*****************************************************************************/
/**
*
* This function implements the Scaler interrupt mode test functionality.
*
* @param TestLoops is the number of times to run the test.
*
* @return XST_SUCCESS if successful else XST_FAILURE.
*
* @note None.
*
******************************************************************************/
static int ScalerInterruptTest(int TestLoops)
{
int Status;
/* u32 LoopCount;
u32 IntrMask;
u8 Bytes; */
/* Initialize XScaler instance. */
Status = Scaler_Initialize(&ScalerInst, (u16)SCALER_0_DEVICE_ID);
if (Status != XST_SUCCESS) {
return Status;
}
/* Setup interrupt system */
Status = SetupInterruptSystem(&ScalerInst);
CT_CMP_NUM(int, Status, XST_SUCCESS);
if (Status != XST_SUCCESS) {
CT_Message("Failed test(s): %u\n", CT_GetTestFailures());
return Status;
}
/* Set Handler, so the application specific processing can be
* performed for state change due to interrupt.
*/
XScaler_SetCallBack(&ScalerInst,
(XScaler_CallBack)Handler, (void *)(&ScalerInst));
// XScaler_SetCallBack(&ScalerInst, 5,
// (XScaler_CallBack)Handler, (void *)(&ScalerInst));
/* Enable interrupts for the device. */
XScaler_IntrEnable(&ScalerInst);
/* Disable interrupts for the device. */
XScaler_IntrDisable(&ScalerInst);
/* IntrMask = ;*/
return (CT_GetTestFailures());
}
/*****************************************************************************/
/**
*
* This function handles application specific processing for the interrupt.
*
* @param CallBackRef pointer to the provided argument.
* @param Event is event that triggered the interrupt.
*
* @return None.
*
* @note None.
*
******************************************************************************/
void Handler(void *CallBackRef, u32 Event)
{
xil_printf("Scaler Intr\n");
/* Implement what you want to after interrupt */
}

View file

@ -1,310 +0,0 @@
/******************************************************************************
*
* XILINX IS PROVIDING THIS DESIGN, CODE, OR INFORMATION "AS IS"
* AS A COURTESY TO YOU, SOLELY FOR USE IN DEVELOPING PROGRAMS AND
* SOLUTIONS FOR XILINX DEVICES. BY PROVIDING THIS DESIGN, CODE,
* OR INFORMATION AS ONE POSSIBLE IMPLEMENTATION OF THIS FEATURE,
* APPLICATION OR STANDARD, XILINX IS MAKING NO REPRESENTATION
* THAT THIS IMPLEMENTATION IS FREE FROM ANY CLAIMS OF INFRINGEMENT,
* AND YOU ARE RESPONSIBLE FOR OBTAINING ANY RIGHTS YOU MAY REQUIRE
* FOR YOUR IMPLEMENTATION. XILINX EXPRESSLY DISCLAIMS ANY
* WARRANTY WHATSOEVER WITH RESPECT TO THE ADEQUACY OF THE
* IMPLEMENTATION, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OR
* REPRESENTATIONS THAT THIS IMPLEMENTATION IS FREE FROM CLAIMS OF
* INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
* FOR A PARTICULAR PURPOSE.
*
* (c) Copyright 2014 Xilinx Inc.
* All rights reserved.
*
******************************************************************************/
/*****************************************************************************/
/**
* @file scaler_intg_main.c
*
* This file contains the integration test functions for the SCALER device.
*
* This file contains a list of functions providing the menu driven test
* functionality for various integration tests.
*
* @note None
*
* <pre>
* MODIFICATION HISTORY:
*
* Ver Who Date Changes
* ----- ------ -------- ------------------------------------------------
* 7.0 adk 22/08/14 First release.
* </pre>
*
******************************************************************************/
/***************************** Include Files *********************************/
#include "scaler_intgtest.h"
#include <stdlib.h>
/************************** Constant Definitions *****************************/
/************************** Constant Definitions *****************************/
/*
* Main menu selections.
*/
#define MENU_MAIN_TEST 1 /**<Menu test */
#define MENU_MAIN_EXIT 99 /**<Menu Exit */
/*
* Test sub-menu selections.
*/
#define MENU_TEST_ALL 0 /**<Menu test all */
#define MENU_TEST_BASIC 1 /**<Menu test basic */
//#define MENU_TEST_POLLED 2 /**<Menu test polled */
#define MENU_TEST_INTR 2 /**<Menu test interrupt */
#define MENU_TEST_EXIT 99 /**<Menu test exit */
/* Create unique bit masks from the test numbers. */
#define SCALER_INTG_TEST_ALL 0xFFFFFFFF /**<SCALER Menu test all */
#define SCALER_INTG_TEST_BASIC (1 << MENU_TEST_BASIC) /**<Scaler Menu test
* basic */
#define SCALER_INTG_TEST_POLLED (1 << MENU_TEST_POLLED) /**<Scaler Menu test
* polled */
#define SCALER_INTG_TEST_INTR (1 << MENU_TEST_INTR) /**<Scaler menu test
* Interrupt */
/**************************** Type Definitions *******************************/
/***************** Macros (Inline Functions) Definitions *********************/
/************************** Function Prototypes ******************************/
static int GetMainMenuCommand(char *CmdLine);
static void RunTestMenu(char *CmdLine);
/************************** Variable Definitions *****************************/
char CmdLine[132]; /**< To read Menu Command arguments */
/*****************************************************************************/
/**
*
* Main entry point for integration tests on Scaler.
*
* @return XST_SUCCESS if successful else XST_FAILURE.
*
* @note None.
*
******************************************************************************/
int main()
{
int Status;
#ifdef AUTOMATIC_TEST_MODE
int TestLoops;
int TestFailures;
#endif
printf("\nScaler COMPONENT INTEGRATION TEST\n");
printf("Created on %s\n\n", __DATE__);
printf("================================\n");
Status = Scaler_Initialize(&ScalerInst, (u16)SCALER_0_DEVICE_ID);
if (Status != XST_SUCCESS) {
return Status;
}
#ifndef AUTOMATIC_TEST_MODE
/*
* Prompt user for menu selections.
*/
while (1) {
switch (GetMainMenuCommand(CmdLine)) {
case MENU_MAIN_TEST:
RunTestMenu(CmdLine);
break;
case MENU_MAIN_EXIT:
printf("\nBye\n");
return (0);
default:
printf("Invalid selections.\n");
}
}
#else
/* set defaults */
TestLoops = 1;
TestFailures = 0;
TestFailures += Scaler_Intg_SelfTest(TestLoops);
/* TestFailures += Scaler_Intg_PolledTest(TestLoops); */
TestFailures += Scaler_Intg_InterruptTest(TestLoops);
if (TestFailures) {
XIL_FAIL(TestFailures);
}
else {
XIL_PASS();
}
#endif
return 0;
}
/*****************************************************************************/
/**
*
* Prompt the user for selections in the main menu. The user is allowed to
* enter one command at a time.
*
* @param CmdLine - Storage to use for User input.
*
* @return Numeric command entered.
*
* @note None.
*
******************************************************************************/
static int GetMainMenuCommand(char *CmdLine)
{
/* Prompt user. */
printf("\nMain Menu:\n");
printf("1 - Test menu\n");
/* printf("2 - Util menu\n");*/
/* printf("3 - One of, experimental & misc functions\n");*/
printf("99 - Exit\n");
/*
* Wait for input.
*/
while (!CT_GetUserInput("Enter selection: ", CmdLine,
sizeof(CmdLine) - 1));
return (atoi(CmdLine));
}
/*****************************************************************************/
/**
*
* Prompt the user for a sequence of tests to run in the test sub-menu.
*
* @param CmdLine - Storage to use for User input.
*
* @return None.
*
* @note None.
*
*****************************************************************************/
static void RunTestMenu(char *CmdLine)
{
char *Token;
char *tmp;
int QuitToMain = 0;
int TestLoops;
int TestFailures;
u32 RunTestMask;
while (!QuitToMain) {
/*
* Set defaults.
*/
TestLoops = 1;
RunTestMask = 0;
TestFailures = 0;
/*
* Prompt user.
*/
printf("\nTest Menu:\n");
printf("0 - All tests\n");
printf("1 - Basic Self test\n");
/* printf("2 - Polled mode tests\n"); */
printf("2 - Interrupt mode tests\n");
printf("99 - Exit to main menu\n");
printf("Adding l<number> sets the number of test loops\n");
/*
* Wait for input.
*/
while (!CT_GetUserInput("Enter selection: ", CmdLine,
sizeof(CmdLine) - 1));
/*
* Parse input line.
*/
Token = strtok_r(CmdLine, " ", &tmp);
while (Token) {
if ((*Token == 'l') || (*Token == 'L')) {
TestLoops = atoi(Token + 1);
}
else {
switch (atoi(Token)) {
case MENU_TEST_ALL:
RunTestMask |= SCALER_INTG_TEST_ALL;
break;
case MENU_TEST_BASIC:
RunTestMask |= SCALER_INTG_TEST_BASIC;
break;
/* case MENU_TEST_POLLED:
RunTestMask |= SCALER_INTG_TEST_POLLED;
break; */
case MENU_TEST_INTR:
RunTestMask |= SCALER_INTG_TEST_INTR;
break;
case MENU_TEST_EXIT:
QuitToMain = 1;
break;
default:
printf("Unknown test id %s\n", Token);
}
}
Token = strtok_r(0, " ", &tmp);
}
if(!QuitToMain) {
/*
* Execute selected tests.
*/
printf("\n********************************************\
*******\n");
printf("* Test sequence mask = %08X, TestLoops = %d\n",
(int) RunTestMask, TestLoops);
printf("**********************************************\
*******\n");
if (RunTestMask & SCALER_INTG_TEST_BASIC) {
TestFailures +=
Scaler_Intg_SelfTest(TestLoops);
}
/*if (RunTestMask & SCALER_INTG_TEST_POLLED) {
TestFailures +=
Scaler_Intg_PolledTest(TestLoops);
}*/
if (RunTestMask & SCALER_INTG_TEST_INTR) {
TestFailures +=
Scaler_Intg_InterruptTest(TestLoops);
}
printf("\n********************************************\
******\n");
if (TestFailures) {
printf("* %d test FAILURES recorded\n", \
TestFailures);
}
else {
printf("* Tests pass.\n");
}
printf("\n********************************************\
******\n");
}
}
}

View file

@ -1,108 +0,0 @@
/******************************************************************************
*
* XILINX IS PROVIDING THIS DESIGN, CODE, OR INFORMATION "AS IS"
* AS A COURTESY TO YOU, SOLELY FOR USE IN DEVELOPING PROGRAMS AND
* SOLUTIONS FOR XILINX DEVICES. BY PROVIDING THIS DESIGN, CODE,
* OR INFORMATION AS ONE POSSIBLE IMPLEMENTATION OF THIS FEATURE,
* APPLICATION OR STANDARD, XILINX IS MAKING NO REPRESENTATION
* THAT THIS IMPLEMENTATION IS FREE FROM ANY CLAIMS OF INFRINGEMENT,
* AND YOU ARE RESPONSIBLE FOR OBTAINING ANY RIGHTS YOU MAY REQUIRE
* FOR YOUR IMPLEMENTATION. XILINX EXPRESSLY DISCLAIMS ANY
* WARRANTY WHATSOEVER WITH RESPECT TO THE ADEQUACY OF THE
* IMPLEMENTATION, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OR
* REPRESENTATIONS THAT THIS IMPLEMENTATION IS FREE FROM CLAIMS OF
* INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
* FOR A PARTICULAR PURPOSE.
*
* (c) Copyright 2014 Xilinx Inc.
* All rights reserved.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file scaler_intg_util.c
*
* This file contains utility functions used by all integration test on
* Scaler driver.
*
* @note
*
* This code works for Zynq702 system.
*
* <pre>
* MODIFICATION HISTORY:
*
* Ver Who Date Changes
* ----- ------ -------- --------------------------------------------
* 7.0 adk 22/08/14 First release.
* </pre>
*
******************************************************************************/
/***************************** Include Files *********************************/
#include "scaler_intgtest.h"
/************************** Constant Definitions *****************************/
/**************************** Type Definitions *******************************/
/***************** Macros (Inline Functions) Definitions *********************/
/************************** Function Prototypes ******************************/
/************************** Variable Definitions *****************************/
/* Instance of SCALER driver core struct XScaler. */
XScaler ScalerInst; /**< Instance of XScaler */
/* Instance of the XIntc driver. */
XScuGic InterruptController;
/*****************************************************************************/
/**
*
* This function initializes the Scaler core.
*
* @param InstancePtr to the instance under test.
* @param DeviceId is unique ID which identifies the device
*
* @return - XST_FAILURE if there are errors.
* - XST_SUCCESS if there are no errors.
*
* @note None.
*
******************************************************************************/
int Scaler_Initialize(XScaler *InstancePtr, u16 DeviceId)
{
XScaler_Config *Config;
int Status;
/*
* Initialize the Scaler driver so that it's ready to use
* Look up the configuration in the config table,
* then initialize it.
*/
Config = XScaler_LookupConfig(DeviceId);
if (NULL == Config)
{
return XST_FAILURE;
}
Status = XScaler_CfgInitialize(InstancePtr, Config, Config->BaseAddress);
if (Status != XST_SUCCESS)
{
return XST_FAILURE;
}
/*
* Need to set standard and data_width if at all core is supported.
*/
return XST_SUCCESS;
}

View file

@ -1,127 +0,0 @@
/******************************************************************************
*
* XILINX IS PROVIDING THIS DESIGN, CODE, OR INFORMATION "AS IS"
* AS A COURTESY TO YOU, SOLELY FOR USE IN DEVELOPING PROGRAMS AND
* SOLUTIONS FOR XILINX DEVICES. BY PROVIDING THIS DESIGN, CODE,
* OR INFORMATION AS ONE POSSIBLE IMPLEMENTATION OF THIS FEATURE,
* APPLICATION OR STANDARD, XILINX IS MAKING NO REPRESENTATION
* THAT THIS IMPLEMENTATION IS FREE FROM ANY CLAIMS OF INFRINGEMENT,
* AND YOU ARE RESPONSIBLE FOR OBTAINING ANY RIGHTS YOU MAY REQUIRE
* FOR YOUR IMPLEMENTATION. XILINX EXPRESSLY DISCLAIMS ANY
* WARRANTY WHATSOEVER WITH RESPECT TO THE ADEQUACY OF THE
* IMPLEMENTATION, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OR
* REPRESENTATIONS THAT THIS IMPLEMENTATION IS FREE FROM CLAIMS OF
* INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
* FOR A PARTICULAR PURPOSE.
*
* (c) Copyright 2014 Xilinx Inc.
* All rights reserved.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file scaler_intgtest.h
*
* This header file contains the integration test functions prototypes,
* constants and variable definitions used in the test. This test runs on a
* Zynq702 system.
*
* @note None
*
* <pre>
* MODIFICATION HISTORY:
*
* Ver Who Date Changes
* ----- ------ -------- -----------------------------------------------------
* 7.0 adk 22/08/14 First release.
* </pre>
*
******************************************************************************/
#ifndef SCALER_INTEGTEST_H
#define SCALER_INTEGTEST_H /**< Prevent circular inclusions by using
* protection macros. */
#ifdef __cplusplus
extern "C" {
#endif
/***************************** Include Files *********************************/
/*
* Includes that define system hardware constants.
*/
#include "xparameters.h"
#include "xscaler.h"
#include "xscugic.h"
#include "xstatus.h"
#include "xil_testlib.h"
/*
* Includes that define test utility APIs.
*/
#include "ct.h"
#include "xil_exception.h"
/************************** Constant Definitions *****************************/
#define LOOP_TIME_OUT 0x000FFFFF /**< Loop time out macro */
/*
* Constants indicating INTC device ID and interrupt ID. They are defined in
* xparameters.h.
*/
#ifndef SCALER_XSCALER_0_INTR
#define SCALER_XSCALER_0_INTR 92 /**<SCALER Interrupt */
#endif
#define SCALER_0_DEVICE_ID XPAR_XSCALER_0_DEVICE_ID /**<SCALER Device
* Id */
#define INTC_DEVICE_ID XPAR_SCUGIC_SINGLE_DEVICE_ID /**<INTC Device
* Id */
#define SCALER_INT_IRQ_ID SCALER_XSCALER_0_INTR /**<Scaler Interrupt
* IRQ Id */
#define XSCALAR_DEVICEID 5 /**< Random device id*/
/* Pele Regression tests */
#define AUTOMATIC_TEST_MODE /**<Automatic Test Mode */
/**************************** Type Definitions *******************************/
/***************** Macros (Inline Functions) Definitions *********************/
/************************** Variable Definitions *****************************/
/* Instance of the Scaler driver. */
extern XScaler ScalerInst;
/* Instance of the XScuGic driver. */
extern XScuGic InterruptController;
/* User command storage */
extern char CmdLine[132];
/************************** Function Prototypes ******************************/
/* Basic self test implemented in scaler_intg_basic.c. */
int Scaler_Intg_SelfTest(int TestLoops);
/* Polled mode test implemented in scaler_intg_polled.c. */
/*int Scaler_Intg_PolledTest(int TestLoops);*/
/* Interrupt mode test implemented in scaler_intg_intr.c. */
int Scaler_Intg_InterruptTest(int TestLoops);
/* Scaler initialization that restores the format and operation mode in
* scaler_intg_util.c.
*/
int Scaler_Initialize(XScaler *InstancePtr, u16 DeviceID);
#ifdef __cplusplus
}
#endif
#endif /* End of protection macro. */

View file

@ -1,70 +0,0 @@
/******************************************************************************
*
* XILINX IS PROVIDING THIS DESIGN, CODE, OR INFORMATION "AS IS"
* AS A COURTESY TO YOU, SOLELY FOR USE IN DEVELOPING PROGRAMS AND
* SOLUTIONS FOR XILINX DEVICES. BY PROVIDING THIS DESIGN, CODE,
* OR INFORMATION AS ONE POSSIBLE IMPLEMENTATION OF THIS FEATURE,
* APPLICATION OR STANDARD, XILINX IS MAKING NO REPRESENTATION
* THAT THIS IMPLEMENTATION IS FREE FROM ANY CLAIMS OF INFRINGEMENT,
* AND YOU ARE RESPONSIBLE FOR OBTAINING ANY RIGHTS YOU MAY REQUIRE
* FOR YOUR IMPLEMENTATION. XILINX EXPRESSLY DISCLAIMS ANY
* WARRANTY WHATSOEVER WITH RESPECT TO THE ADEQUACY OF THE
* IMPLEMENTATION, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OR
* REPRESENTATIONS THAT THIS IMPLEMENTATION IS FREE FROM CLAIMS OF
* INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
* FOR A PARTICULAR PURPOSE.
*
* (c) Copyright 2002-2014 Xilinx Inc.
* All rights reserved.
*
******************************************************************************/
/*****************************************************************************/
/**
*
* @file xil_testlib.h
*
* This file contains Xilinx software exit messages. These messages are set to
* be matched with the scan strings for board test such that board test would
* know the result of a standalone test program.
*
******************************************************************************/
/***************************** Include Files *********************************/
#include <xil_printf.h>
#ifndef XIL_TESTLIB_H /* prevent circular inclusions */
#define XIL_TESTLIB_H /* by using protection macros */
#ifdef __cplusplus
extern "C" {
#endif
/***************** Macros (Inline Functions) Definitions *********************/
/*
* XIL_PASS puts out a message to signal board test that a program has pass
* the testing program without errors
*
* @return None.
*
* @note None.
*/
#define XIL_PASS() xil_printf("\r\nREGRESSION TEST PASS.\r\n")
/* XIL_FAIL puts out a message to signal board test that a program has not
* pass the testing program
*
* @param numErrors, number of errors.
*
* @return None.
*
* @note None.
*/
#define XIL_FAIL(numErrors) xil_printf("\r\nREGRESSION TEST FAIL WITH %d \
ERRORS.\r\n", numErrors)
#ifdef __cplusplus
}
#endif
#endif /* end of protection macro */

View file

@ -53,7 +53,7 @@ proc generate {drv_handle} {
xdefine_gic_params $drv_handle
xdefine_zynq_include_file $drv_handle "xparameters.h" "XScuGic" "NUM_INSTANCES" "DEVICE_ID" "C_S_AXI_BASEADDR" "C_S_AXI_HIGHADDR" "C_DIST_BASEADDR"
::hsi::utils::define_zynq_config_file $drv_handle "xscugic_g.c" "XScuGic" "DEVICE_ID" "C_S_AXI_BASEADDR" "C_DIST_BASEADDR"
xdefine_zynq_config_file $drv_handle "xscugic_g.c" "XScuGic" "DEVICE_ID" "C_S_AXI_BASEADDR" "C_DIST_BASEADDR"
xdefine_zynq_canonical_xpars $drv_handle "xparameters.h" "ScuGic" "DEVICE_ID" "C_S_AXI_BASEADDR" "C_S_AXI_HIGHADDR" "C_DIST_BASEADDR"
}

View file

@ -47,25 +47,25 @@
# -----------------------------------------------------------------
proc gen_include_files {swproj mhsinst} {
if {$swproj == 0} {
return ""
}
if {$swproj == 1} {
set inc_file_lines {xscutimer.h scutimer_header.h}
}
}
return $inc_file_lines
}
proc gen_src_files {swproj mhsinst} {
if {$swproj == 0} {
return ""
}
if {$swproj == 1} {
set inc_file_lines {examples/xscutimer_polled_example.c examples/xscutimer_intr_example.c data/scutimer_header.h}
return $inc_file_lines
}
}
@ -75,40 +75,40 @@ proc gen_testfunc_def {swproj mhsinst} {
}
proc gen_init_code {swproj mhsinst} {
if {$swproj == 0} {
return ""
}
if {$swproj == 1} {
set ipname [common::get_property NAME $mhsinst]
set ipname [get_property NAME $mhsinst]
set decl " static XScuTimer ${ipname};"
set inc_file_lines $decl
return $inc_file_lines
}
}
proc gen_testfunc_call {swproj mhsinst} {
if {$swproj == 0} {
return ""
}
set ipname [common::get_property NAME $mhsinst]
set ipname [get_property NAME $mhsinst]
set deviceid [::hsi::utils::get_ip_param_name $mhsinst "DEVICE_ID"]
set stdout [common::get_property CONFIG.STDOUT [hsi::get_os]]
set stdout [get_property CONFIG.STDOUT [get_os]]
if { $stdout == "" || $stdout == "none" } {
set hasStdout 0
} else {
set hasStdout 1
}
set isintr [::hsi::utils::is_ip_interrupting_current_proc $mhsinst]
set intcvar intc
set testfunc_call ""
if {${hasStdout} == 0} {
@ -117,17 +117,17 @@ proc gen_testfunc_call {swproj mhsinst} {
{
int Status;
Status = ScuTimerPolledExample(${deviceid});
}"
if {$isintr == 1} {
set intr_id "XPAR_${ipname}_INTR"
set intr_id [string toupper $intr_id]
append testfunc_call "
{
int Status;
Status = ScuTimerIntrExample(&${intcvar}, &${ipname}, \\
@ -144,11 +144,11 @@ proc gen_testfunc_call {swproj mhsinst} {
{
int Status;
print(\"\\r\\n Running ScuTimerPolledExample() for ${ipname}...\\r\\n\");
Status = ScuTimerPolledExample(${deviceid});
if (Status == 0) {
print(\"ScuTimerPolledExample PASSED\\r\\n\");
}
@ -160,20 +160,20 @@ proc gen_testfunc_call {swproj mhsinst} {
if {$isintr ==1 } {
set intr_id "XPAR_${ipname}_INTR"
set intr_id [string toupper $intr_id]
append testfunc_call "
{
int Status;
print(\"\\r\\n Running Interrupt Test for ${ipname}...\\r\\n\");
Status = ScuTimerIntrExample(&${intcvar}, &${ipname}, \\
${deviceid}, \\
${intr_id});
if (Status == 0) {
print(\"ScuTimerIntrExample PASSED\\r\\n\");
}
}
else {
print(\"ScuTimerIntrExample FAILED\\r\\n\");
}

View file

@ -49,24 +49,24 @@
# -----------------------------------------------------------------
proc gen_include_files {swproj mhsinst} {
if {$swproj == 0} {
return ""
}
if {$swproj == 1} {
set inc_file_lines {xscuwdt.h scuwdt_header.h}
}
}
return $inc_file_lines
}
proc gen_src_files {swproj mhsinst} {
if {$swproj == 0} {
return ""
}
if {$swproj == 1} {
set inc_file_lines {examples/xscuwdt_intr_example.c data/scuwdt_header.h}
return $inc_file_lines
}
}
@ -76,50 +76,50 @@ proc gen_testfunc_def {swproj mhsinst} {
}
proc gen_init_code {swproj mhsinst} {
if {$swproj == 0} {
return ""
}
if {$swproj == 1} {
set ipname [common::get_property NAME $mhsinst]
set ipname [get_property NAME $mhsinst]
set decl " static XScuWdt ${ipname};"
set inc_file_lines $decl
return $inc_file_lines
}
}
proc gen_testfunc_call {swproj mhsinst} {
if {$swproj == 0} {
return ""
}
set ipname [common::get_property NAME $mhsinst]
set ipname [get_property NAME $mhsinst]
set deviceid [::hsi::utils::get_ip_param_name $mhsinst "DEVICE_ID"]
set stdout [common::get_property CONFIG.STDOUT [hsi::get_os]]
set stdout [get_property CONFIG.STDOUT [get_os]]
if { $stdout == "" || $stdout == "none" } {
set hasStdout 0
} else {
set hasStdout 1
}
set isintr [::hsi::utils::is_ip_interrupting_current_proc $mhsinst]
set intcvar intc
set testfunc_call ""
if {${hasStdout} == 0} {
if {$isintr == 1} {
if {$isintr == 1} {
set intr_id "XPAR_${ipname}_INTR"
set intr_id [string toupper $intr_id]
append testfunc_call "
{
int Status;
Status = ScuWdtIntrExample(&${intcvar}, &${ipname}, \\
@ -131,32 +131,32 @@ proc gen_testfunc_call {swproj mhsinst} {
} else {
if {$isintr == 1} {
set intr_id "XPAR_${ipname}_INTR"
set intr_id [string toupper $intr_id]
append testfunc_call "
{
int Status;
print(\"\\r\\n Running Interrupt Test for ${ipname}...\\r\\n\");
Status = ScuWdtIntrExample(&${intcvar}, &${ipname}, \\
${deviceid}, \\
${intr_id});
if (Status == 0) {
print(\"ScuWdtIntrExample PASSED\\r\\n\");
}
}
else {
print(\"ScuWdtIntrExample FAILED\\r\\n\");
}
}"
}
}