video: fbdev: matrox: use swap() in matroxfb_decode_var()
authorFabian Frederick <fabf@skynet.be>
Mon, 18 May 2015 17:31:04 +0000 (19:31 +0200)
committerTomi Valkeinen <tomi.valkeinen@ti.com>
Wed, 27 May 2015 09:54:48 +0000 (12:54 +0300)
Use kernel.h macro definition.

Signed-off-by: Fabian Frederick <fabf@skynet.be>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
drivers/video/fbdev/matrox/matroxfb_base.c

index 62539ca1cfa909e1ffc3e74b4e9b74a60e26be1f..2ba4e54bb59daca36898edb92d4f2752eb8ec679 100644 (file)
@@ -591,12 +591,8 @@ static int matroxfb_decode_var(const struct matrox_fb_info *minfo,
                        unsigned int max_yres;
 
                        while (m1) {
-                               int t;
-
                                while (m2 >= m1) m2 -= m1;
-                               t = m1;
-                               m1 = m2;
-                               m2 = t;
+                               swap(m1, m2);
                        }
                        m2 = linelen * PAGE_SIZE / m2;
                        *ydstorg = m2 = 0x400000 % m2;