From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from kroah.org ([198.145.64.141]:57922 "EHLO coco.kroah.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753211Ab0BIXQI (ORCPT ); Tue, 9 Feb 2010 18:16:08 -0500 Date: Tue, 9 Feb 2010 15:16:03 -0800 From: Greg KH To: Mauro Carvalho Chehab Cc: Matthias Schwarzott , Douglas Schilling Landgraf , Andreas Oberritter , linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, Andreas Gruenbacher Subject: [PATCH] dvb: l64781.ko broken with gcc 4.5 Message-ID: <20100209231603.GA22588@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Sender: linux-media-owner@vger.kernel.org List-ID: From: Richard Guenther I'm trying to fix it on the GCC side (PR43007), but the module is quite stupid in using ULL constants to operate on u32 values: static int apply_frontend_param (struct dvb_frontend* fe, struct dvb_frontend_parameters *param) { ... static const u32 ppm = 8000; u32 spi_bias; ... spi_bias *= 1000ULL; spi_bias /= 1000ULL + ppm/1000; which causes current GCC 4.5 to emit calls to __udivdi3 for i?86 again. This patch fixes this issue. Signed-off-by: Richard Guenther Cc: Andreas Gruenbacher Cc: stable Cc: Mauro Carvalho Chehab Cc: Matthias Schwarzott Cc: Douglas Schilling Landgraf Cc: Andreas Oberritter Signed-off-by: Greg Kroah-Hartman --- drivers/media/dvb/frontends/l64781.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/drivers/media/dvb/frontends/l64781.c +++ b/drivers/media/dvb/frontends/l64781.c @@ -192,8 +192,8 @@ static int apply_frontend_param (struct spi_bias *= qam_tab[p->constellation]; spi_bias /= p->code_rate_HP + 1; spi_bias /= (guard_tab[p->guard_interval] + 32); - spi_bias *= 1000ULL; - spi_bias /= 1000ULL + ppm/1000; + spi_bias *= 1000; + spi_bias /= 1000 + ppm/1000; spi_bias *= p->code_rate_HP; val0x04 = (p->transmission_mode << 2) | p->guard_interval;