[Spice-commits] server/red-parse-qxl.c

Frediano Ziglio fziglio at kemper.freedesktop.org
Tue Apr 17 19:18:38 UTC 2018


 server/red-parse-qxl.c |   25 ++++---------------------
 1 file changed, 4 insertions(+), 21 deletions(-)

New commits:
commit d8b10988500b8a32d95ceb294d13b7eea74c3bdc
Author: Christophe Fergeau <cfergeau at redhat.com>
Date:   Tue Apr 17 18:19:17 2018 +0200

    qxl: Remove 'blackness' and 'invers' put/get methods
    
    SpiceWhiteness/SpiceBlackness/SpiceInvers are 3 typedef for the same
    type, no need to have 3 identical red_put_xxx/red_get_xxx methods.
    
    Signed-off-by: Christophe Fergeau <cfergeau at redhat.com>
    Acked-by: Frediano Ziglio <fziglio at redhat.com>

diff --git a/server/red-parse-qxl.c b/server/red-parse-qxl.c
index b766e993..4a45c0f7 100644
--- a/server/red-parse-qxl.c
+++ b/server/red-parse-qxl.c
@@ -986,27 +986,10 @@ static void red_put_whiteness(SpiceWhiteness *red)
     red_put_qmask(&red->mask);
 }
 
-static void red_get_blackness_ptr(RedMemSlotInfo *slots, int group_id,
-                                  SpiceBlackness *red, QXLBlackness *qxl, uint32_t flags)
-{
-    red_get_qmask_ptr(slots, group_id, &red->mask, &qxl->mask, flags);
-}
-
-static void red_put_blackness(SpiceWhiteness *red)
-{
-    red_put_qmask(&red->mask);
-}
-
-static void red_get_invers_ptr(RedMemSlotInfo *slots, int group_id,
-                               SpiceInvers *red, QXLInvers *qxl, uint32_t flags)
-{
-    red_get_qmask_ptr(slots, group_id, &red->mask, &qxl->mask, flags);
-}
-
-static void red_put_invers(SpiceWhiteness *red)
-{
-    red_put_qmask(&red->mask);
-}
+#define red_get_invers_ptr red_get_whiteness_ptr
+#define red_get_blackness_ptr red_get_whiteness_ptr
+#define red_put_invers red_put_whiteness
+#define red_put_blackness red_put_whiteness
 
 static void red_get_clip_ptr(RedMemSlotInfo *slots, int group_id,
                              SpiceClip *red, QXLClip *qxl)


More information about the Spice-commits mailing list