###############################################################################
##
## Copyright (c) 2003 Xilinx, Inc. All Rights Reserved.
## DO NOT COPY OR MODIFY THIS FILE. 
## THIS IS IN AN EXPERIMENTAL STAGE AND MIGHT CHANGE IN FUTURE RELEASE.
##
## opb_sysace_v2_1_0.tcl
##
###############################################################################


#***--------------------------------***------------------------------------***
#
#			     IPLEVEL_DRC_PROC
#
#***--------------------------------***------------------------------------***

#
# check C_BASEADDR != 0xFFFFFFFF
#       C_HIGHADDR != 0x00000000
#

proc check_iplevel_settings {mhsinst} {

    set base_param "C_BASEADDR"
    set high_param "C_HIGHADDR"
    set base_addr [xget_value $mhsinst "parameter" $base_param]
    set high_addr [xget_value $mhsinst "parameter" $high_param]

    if {[compare_unsigned_addr_strings $base_addr $base_param $high_addr $high_param] == 1} {

	set instname [xget_value $mhsinst "parameter" "INSTANCE"]
        error "Invalid $instname parameter:\nYou must set the value for $base_param and $high_param" "" "libgen_error"

    }

}
