aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/sh/rcar/src.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc/sh/rcar/src.c')
-rw-r--r--sound/soc/sh/rcar/src.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/sound/soc/sh/rcar/src.c b/sound/soc/sh/rcar/src.c
index e39f916d0f2f..969a5169de25 100644
--- a/sound/soc/sh/rcar/src.c
+++ b/sound/soc/sh/rcar/src.c
@@ -226,8 +226,12 @@ static void rsnd_src_set_convert_rate(struct rsnd_dai_stream *io,
226 ifscr = 0; 226 ifscr = 0;
227 fsrate = 0; 227 fsrate = 0;
228 if (fin != fout) { 228 if (fin != fout) {
229 u64 n;
230
229 ifscr = 1; 231 ifscr = 1;
230 fsrate = 0x0400000 / fout * fin; 232 n = (u64)0x0400000 * fin;
233 do_div(n, fout);
234 fsrate = n;
231 } 235 }
232 236
233 /* 237 /*