diff options
author | Mauro Carvalho Chehab <mchehab@infradead.org> | 2008-04-25 02:43:23 +0200 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2008-07-23 13:09:11 +0200 |
commit | 29e031d5b09ae60d0ecdb6a1d869d591d63e893a (patch) | |
tree | 9f1a516ffa0380b1e4ac2191a985602925d058e6 /drivers/media/dvb | |
parent | V4L/DVB (7736): This patch adds support for the Micronas DRX3975D/DRX3977D DV... (diff) | |
download | linux-29e031d5b09ae60d0ecdb6a1d869d591d63e893a.tar.xz linux-29e031d5b09ae60d0ecdb6a1d869d591d63e893a.zip |
V4L/DVB (7737): drx397xD: fix math usage
The previous code were using a div64 math specific to i386. Replace for an
asm-generic one.
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/dvb')
-rw-r--r-- | drivers/media/dvb/frontends/drx397xD.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/drivers/media/dvb/frontends/drx397xD.c b/drivers/media/dvb/frontends/drx397xD.c index b0ff77ffc88b..af4354662124 100644 --- a/drivers/media/dvb/frontends/drx397xD.c +++ b/drivers/media/dvb/frontends/drx397xD.c @@ -26,6 +26,7 @@ #include <linux/delay.h> #include <linux/string.h> #include <linux/firmware.h> +#include <asm/div64.h> #include "dvb_frontend.h" #include "drx397xD.h" @@ -1024,17 +1025,15 @@ static int drx_tune(struct drx397xD_state *s, rc = WR16(s, 0x0820050, rc); { - long dummy; - /* Configure bandwidth specific factor */ - ebx = div_ll_X_l_rem(((u64) (s->f_osc) << 21) + (ebx >> 1), - ebx, &dummy) - 0x800000; + ebx = div64_64(((u64) (s->f_osc) << 21) + (ebx >> 1), + (u64)ebx) - 0x800000; EXIT_RC(WR16(s, 0x0c50010, ebx & 0xffff)); EXIT_RC(WR16(s, 0x0c50011, ebx >> 16)); /* drx397xD oscillator calibration */ - ebx = div_ll_X_l_rem(((u64) (s->config.f_if + df_tuner) << 28) + - (s->f_osc >> 1), s->f_osc, &dummy); + ebx = div64_64(((u64) (s->config.f_if + df_tuner) << 28) + + (s->f_osc >> 1), (u64)s->f_osc); } ebx &= 0xfffffff; if (fep->inversion == INVERSION_ON) |