]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
[media] lmedm04: make lme2510_powerup a little smaller
authorRasmus Villemoes <linux@rasmusvillemoes.dk>
Wed, 30 Nov 2016 21:39:12 +0000 (19:39 -0200)
committerMauro Carvalho Chehab <mchehab@s-opensource.com>
Fri, 3 Feb 2017 09:39:38 +0000 (07:39 -0200)
gcc isn't smart enough to realize it can share most of the argument
buildup and the actual function call between the two branches, so help
it a little.

Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
drivers/media/usb/dvb-usb-v2/lmedm04.c

index 66833b61321a20e5017227d9ccd36ce76f6178b9..924adfdb660da3b7dcdc339a06cd8ec921d2bf8d 100644 (file)
@@ -1173,10 +1173,7 @@ static int lme2510_powerup(struct dvb_usb_device *d, int onoff)
 
        mutex_lock(&d->i2c_mutex);
 
-       if (onoff)
-               ret = lme2510_usb_talk(d, lnb_on, len, rbuf, rlen);
-       else
-               ret = lme2510_usb_talk(d, lnb_off, len, rbuf, rlen);
+       ret = lme2510_usb_talk(d, onoff ? lnb_on : lnb_off, len, rbuf, rlen);
 
        st->i2c_talk_onoff = 1;