iomodule: Updated iomodule if external interrupts are not enabled
This patch updates the iomodule to handle, if external interrupts are not enabled. Signed-off-by: Naga Sureshkumar Relli <nagasure@xilinx.com> Reviewed-by: Kedareswara rao Appana <appanad@xilinx.com>
This commit is contained in:
parent
b85e4c0b2e
commit
ff00dfdd03
2 changed files with 12 additions and 4 deletions
|
@ -44,6 +44,8 @@
|
||||||
# 2.2 nsk 19/08/15 Modified iomodule_defince_vector_table
|
# 2.2 nsk 19/08/15 Modified iomodule_defince_vector_table
|
||||||
# to handle, if iomodule doesn't have interrupts
|
# to handle, if iomodule doesn't have interrupts
|
||||||
# enabled CR#876507.
|
# enabled CR#876507.
|
||||||
|
# 2.2 nsk 02/09/15 Modified iomodule_define_vector_table
|
||||||
|
# when no external interrupts are used.CR#878782.
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -314,13 +316,17 @@ proc iomodule_define_vector_table {periph config_inc config_file} {
|
||||||
set interrupt_pin [hsi::get_pins -of_objects [get_cells -hier $periph] -filter {TYPE==INTERRUPT&&DIRECTION==I}]
|
set interrupt_pin [hsi::get_pins -of_objects [get_cells -hier $periph] -filter {TYPE==INTERRUPT&&DIRECTION==I}]
|
||||||
|
|
||||||
# Get pins/ports that are driving the interrupt
|
# Get pins/ports that are driving the interrupt
|
||||||
lappend source_pins
|
set c_intc_use_ext_intr [common::get_property CONFIG.C_INTC_USE_EXT_INTR $periph]
|
||||||
set source_pins [::hsi::utils::get_source_pins $interrupt_pin]
|
if {$c_intc_use_ext_intr == 0} {
|
||||||
|
set num_intr_inputs 0
|
||||||
|
} else {
|
||||||
set num_intr_inputs [common::get_property CONFIG.C_INTC_INTR_SIZE $periph]
|
set num_intr_inputs [common::get_property CONFIG.C_INTC_INTR_SIZE $periph]
|
||||||
|
}
|
||||||
|
|
||||||
#calculate the total interrupt sources
|
#calculate the total interrupt sources
|
||||||
set total_intr_ports [get_num_intr_internal $periph]
|
set total_intr_ports [get_num_intr_internal $periph]
|
||||||
if {$num_intr_inputs != $total_intr_ports} {
|
if {$num_intr_inputs != $total_intr_ports} {
|
||||||
|
set source_pins [::hsi::utils::get_interrupt_sources $periph]
|
||||||
puts "WARNING: Num intr inputs $num_intr_inputs not the \
|
puts "WARNING: Num intr inputs $num_intr_inputs not the \
|
||||||
same as length of ::hsi::utils::get_interrupt_sources [llength \
|
same as length of ::hsi::utils::get_interrupt_sources [llength \
|
||||||
$source_pins] hsi_warning"
|
$source_pins] hsi_warning"
|
||||||
|
|
|
@ -231,6 +231,8 @@
|
||||||
* 2.2 nsk 08/19/15 Modifed iomodule_define_vector_table in iomodule.tcl
|
* 2.2 nsk 08/19/15 Modifed iomodule_define_vector_table in iomodule.tcl
|
||||||
* to handle,if iomodule doesn't have interrupts enabled
|
* to handle,if iomodule doesn't have interrupts enabled
|
||||||
* (CR #876507).
|
* (CR #876507).
|
||||||
|
* 2.2 nsk 09/02/15 Modified iomodule_define_vector_table in iomodule.tcl
|
||||||
|
* when no external interrupts are used.(CR #878782)
|
||||||
*
|
*
|
||||||
* </pre>
|
* </pre>
|
||||||
*
|
*
|
||||||
|
|
Loading…
Add table
Reference in a new issue