Fixed build issue when CODEC_MASTER defined (BUG #15162)

This commit is contained in:
Ross Owen
2014-01-16 17:31:28 +00:00
parent 7c5811e36a
commit 1022f7d5c6

View File

@@ -79,6 +79,8 @@ extern void device_reboot(void);
#define MAX_DIVIDE (MAX_DIVIDE_48)
#endif
#ifndef CODEC_MASTER
#error
static inline void doI2SClocks(unsigned divide)
{
switch (divide)
@@ -139,6 +141,7 @@ static inline void doI2SClocks(unsigned divide)
#endif
}
}
#endif
/* I2S delivery thread */
#pragma unsafe arrays
@@ -193,7 +196,7 @@ static inline void doI2SClocks(unsigned divide)
if(testct(c_out))
{
unsigned command = inct(c_out);
#ifndef CODEC_MASTER
// Set clocks low
p_lrclk <: 0;
p_bclk <: 0;
@@ -201,6 +204,7 @@ static inline void doI2SClocks(unsigned divide)
/* DSD Clock might not be shared with lrclk or bclk... */
p_dsd_clk <: 0;
#endif
#endif
#if (DSD_CHANS_DAC > 0)
if(dsdMode == DSD_MODE_DOP)
dsdMode = DSD_MODE_OFF;
@@ -384,13 +388,14 @@ static inline void doI2SClocks(unsigned divide)
if(testct(c_out))
{
unsigned command;
#ifndef CODEC_MASTER
// Set clocks low
p_lrclk <: 0;
p_bclk <: 0;
#if(DSD_CHANS_DAC != 0)
/* DSD Clock might not be shared with lrclk or bclk... */
p_dsd_clk <: 0;
#endif
#endif
command = inct(c_out);