|
@@ -107,7 +107,7 @@ const unsigned int amdtp_syt_intervals[CIP_SFC_COUNT] = {
|
|
};
|
|
};
|
|
EXPORT_SYMBOL(amdtp_syt_intervals);
|
|
EXPORT_SYMBOL(amdtp_syt_intervals);
|
|
|
|
|
|
-const unsigned int amdtp_rate_table[] = {
|
|
|
|
|
|
+const unsigned int amdtp_rate_table[CIP_SFC_COUNT] = {
|
|
[CIP_SFC_32000] = 32000,
|
|
[CIP_SFC_32000] = 32000,
|
|
[CIP_SFC_44100] = 44100,
|
|
[CIP_SFC_44100] = 44100,
|
|
[CIP_SFC_48000] = 48000,
|
|
[CIP_SFC_48000] = 48000,
|
|
@@ -198,7 +198,7 @@ void amdtp_stream_set_parameters(struct amdtp_stream *s,
|
|
WARN_ON(midi_channels > AMDTP_MAX_CHANNELS_FOR_MIDI))
|
|
WARN_ON(midi_channels > AMDTP_MAX_CHANNELS_FOR_MIDI))
|
|
return;
|
|
return;
|
|
|
|
|
|
- for (sfc = 0; sfc < sizeof(amdtp_rate_table); ++sfc)
|
|
|
|
|
|
+ for (sfc = 0; sfc < ARRAY_SIZE(amdtp_rate_table); ++sfc)
|
|
if (amdtp_rate_table[sfc] == rate)
|
|
if (amdtp_rate_table[sfc] == rate)
|
|
goto sfc_found;
|
|
goto sfc_found;
|
|
WARN_ON(1);
|
|
WARN_ON(1);
|