[media] dvb-core: fix 32-bit overflow during bandwidth calculation
Frontend bandwidth calculation overflows on very high DVB-S/S2 symbol rates. Use mult_frac() macro in order to keep calculation correct. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
This commit is contained in:
parent
13b019bbd1
commit
2a80f29642
|
@ -2216,7 +2216,7 @@ static int dtv_set_frontend(struct dvb_frontend *fe)
|
|||
break;
|
||||
}
|
||||
if (rolloff)
|
||||
c->bandwidth_hz = (c->symbol_rate * rolloff) / 100;
|
||||
c->bandwidth_hz = mult_frac(c->symbol_rate, rolloff, 100);
|
||||
|
||||
/* force auto frequency inversion if requested */
|
||||
if (dvb_force_auto_inversion)
|
||||
|
|
Loading…
Reference in New Issue