Changeset 407 for trunk/hal/tsar_mips32/core/hal_drivers.c
- Timestamp:
- Nov 7, 2017, 3:08:12 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/hal/tsar_mips32/core/hal_drivers.c
r346 r407 49 49 uint32_t impl ) 50 50 { 51 if( impl == IMPL_TXT_TTY ) 52 { 53 soclib_tty_init( txt ); 54 } 55 else 56 { 57 assert( false , __FUNCTION__ , "undefined TXT device implementation" ); 58 } 51 assert( (impl == IMPL_TXT_TTY), __FUNCTION__ , "bad implementation" ); 52 53 soclib_tty_init( txt ); 59 54 } 60 55 … … 67 62 uint32_t impl ) 68 63 { 69 if( impl != IMPL_PIC_SCL ) 70 { 71 assert( false , __FUNCTION__ , "undefined PIC device implementation" ); 72 } 64 assert( (impl == IMPL_PIC_SCL), __FUNCTION__, "bad implementation" ); 73 65 74 66 soclib_pic_init( pic ); … … 81 73 pic->ext.pic.bind_irq = &soclib_pic_bind_irq; 82 74 pic->ext.pic.send_ipi = &soclib_pic_send_ipi; 75 pic->ext.pic.ack_ipi = &soclib_pic_ack_ipi; 83 76 pic->ext.pic.extend_init = &soclib_pic_extend_init; 84 77 } … … 92 85 uint32_t impl ) 93 86 { 94 if (impl != IMPL_IOB_TSR) 95 { 96 assert( false , __FUNCTION__ , "undefined IOB device implementation" ); 97 } 87 assert( (impl == IMPL_IOB_TSR), __FUNCTION__ , "bad implementation" ); 98 88 99 89 soclib_iob_init( iob ); … … 138 128 uint32_t impl ) 139 129 { 140 if( impl == IMPL_MMC_TSR ) 141 { 142 soclib_mmc_init( mmc ); 143 } 144 else 145 { 146 assert( false , __FUNCTION__ , "undefined MMC device implementation" ); 147 } 130 assert( (impl == IMPL_MMC_TSR), __FUNCTION__ , "bad implementation" ); 131 132 soclib_mmc_init( mmc ); 148 133 } 149 134 … … 156 141 uint32_t impl ) 157 142 { 158 if( impl == IMPL_NIC_SOC ) 159 { 160 soclib_nic_init( nic ); 161 } 162 else 163 { 164 assert( false , __FUNCTION__ , "undefined NIC device implementation" ); 165 } 143 assert( (impl == IMPL_NIC_CBF), __FUNCTION__ , "bad implementation" ); 144 145 soclib_nic_init( nic ); 166 146 } 167 147 … … 174 154 uint32_t impl ) 175 155 { 176 if( impl == IMPL_DMA_SCL ) 177 { 178 soclib_dma_init( dma ); 179 } 180 else 181 { 182 assert( false , __FUNCTION__ , "undefined DMA implementation" ); 183 } 156 assert( (impl == IMPL_DMA_SCL), __FUNCTION__ , "bad implementation" ); 157 158 soclib_dma_init( dma ); 184 159 } 185 160
Note: See TracChangeset
for help on using the changeset viewer.