diff options
author | henryk <henryk@6dc7ffe9-61d6-0310-9af1-9938baff3ed1> | 2008-03-12 17:32:45 +0000 |
---|---|---|
committer | henryk <henryk@6dc7ffe9-61d6-0310-9af1-9938baff3ed1> | 2008-03-12 17:32:45 +0000 |
commit | c319d646a7961442b94ee798d5a3b3bf62d8a720 (patch) | |
tree | cf01b5e6606ee4f6031cc6b09032ef78b5a85097 /openpicc/application/ssc.c | |
parent | 274518e5d989ff2ba83493825ee2531c947d04e3 (diff) |
Remove SSC DMA Rx buffers that are not going to be used for now and take up precious RAM
git-svn-id: https://svn.openpcd.org:2342/trunk@450 6dc7ffe9-61d6-0310-9af1-9938baff3ed1
Diffstat (limited to 'openpicc/application/ssc.c')
-rw-r--r-- | openpicc/application/ssc.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/openpicc/application/ssc.c b/openpicc/application/ssc.c index d1d4e48..6c53ebd 100644 --- a/openpicc/application/ssc.c +++ b/openpicc/application/ssc.c @@ -478,6 +478,7 @@ out: taskEXIT_CRITICAL(); } +#if SSC_DMA_BUFFER_COUNT > 0 static inline int _init_ssc_rx(ssc_handle_t *sh) { tc_cdiv_sync_init(); @@ -524,6 +525,7 @@ static inline int _init_ssc_rx(ssc_handle_t *sh) out_fail_queue: return 0; } +#endif static inline int _init_ssc_tx(ssc_handle_t *sh) { @@ -602,11 +604,16 @@ ssc_handle_t* ssc_open(u_int8_t init_rx, u_int8_t init_tx, enum ssc_mode mode, s } if(init_rx) { +#if SSC_DMA_BUFFER_COUNT > 0 sh->rx_enabled = _init_ssc_rx(sh); if(!sh->rx_enabled) { ssc_close(sh); return NULL; } +#else + ssc_close(sh); + return NULL; +#endif } if(sh->rx_enabled || sh->tx_enabled) { |