From patchwork Sun Aug 25 14:59:37 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Maydell X-Patchwork-Id: 19525 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-vc0-f197.google.com (mail-vc0-f197.google.com [209.85.220.197]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 75BFC246F3 for ; Sun, 25 Aug 2013 14:59:50 +0000 (UTC) Received: by mail-vc0-f197.google.com with SMTP id ha11sf2557859vcb.0 for ; Sun, 25 Aug 2013 07:59:50 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-gm-message-state:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=73tciu888jyc+dmGJNxhPXsLBpzm0rxsir9P7PcMnsM=; b=IwgYkhYzM1DMUjF0Cjugu0dyfRs7D1e1My+RJqN2y+qAH1cwaHt3Ph+cu4DJvKkbp4 oAnopHfWI38ZzM+ru3fr3f9Kr7xtn8CWL8XZOyNq1xsuBOS/ujDx1J0FB6zX7XZoOoF5 SsCdORoispSwGaW4xkYqXV0lZ5qpepO/8L67k/1prcU4u6qwOVtOm+J3CYnitjAB3BYi BtnX9yHcP45Wp8TYASEFDU6CuaRficf9CEOjlt8X12SSayJGBo5OZbNyC+vLmuy2g6z4 rik6cMvV52aLzJAd4XRoSYk7yPHLvhV6nQP4kTm663BKBa58O6Q7R+Pb1szOmh6oWn3F BWbw== X-Received: by 10.236.77.135 with SMTP id d7mr3431409yhe.49.1377442790302; Sun, 25 Aug 2013 07:59:50 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.94.165 with SMTP id dd5ls2255602qeb.87.gmail; Sun, 25 Aug 2013 07:59:50 -0700 (PDT) X-Received: by 10.220.140.69 with SMTP id h5mr10046154vcu.0.1377442790193; Sun, 25 Aug 2013 07:59:50 -0700 (PDT) Received: from mail-vc0-f182.google.com (mail-vc0-f182.google.com [209.85.220.182]) by mx.google.com with ESMTPS id o4si2466056vcx.133.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 25 Aug 2013 07:59:50 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.220.182 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.182; Received: by mail-vc0-f182.google.com with SMTP id hf12so1543979vcb.13 for ; Sun, 25 Aug 2013 07:59:50 -0700 (PDT) X-Gm-Message-State: ALoCoQkuFP7uwEeterbQEQsu2LigsfwkYWy7YlkDLnu2Zgg1gGn84VXLGRxB8bd72WnWX34cy34h X-Received: by 10.52.35.171 with SMTP id i11mr8436236vdj.4.1377442790111; Sun, 25 Aug 2013 07:59:50 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.220.174.196 with SMTP id u4csp192687vcz; Sun, 25 Aug 2013 07:59:49 -0700 (PDT) X-Received: by 10.180.189.132 with SMTP id gi4mr4585556wic.19.1377442789147; Sun, 25 Aug 2013 07:59:49 -0700 (PDT) Received: from mnementh.archaic.org.uk (1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.d.1.0.0.b.8.0.1.0.0.2.ip6.arpa. [2001:8b0:1d0::1]) by mx.google.com with ESMTPS id kx10si3497568wjb.51.1969.12.31.16.00.00 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Sun, 25 Aug 2013 07:59:49 -0700 (PDT) Received-SPF: neutral (google.com: 2001:8b0:1d0::1 is neither permitted nor denied by best guess record for domain of pm215@archaic.org.uk) client-ip=2001:8b0:1d0::1; Received: from pm215 by mnementh.archaic.org.uk with local (Exim 4.80) (envelope-from ) id 1VDbn1-0002tX-7t; Sun, 25 Aug 2013 15:59:39 +0100 From: Peter Maydell To: qemu-devel@nongnu.org Cc: patches@linaro.org, Kevin Wolf , Stefan Hajnoczi , "Michael S. Tsirkin" , Richard Henderson , Anthony Liguori Subject: [PATCH 9/9] bswap.h: Remove cpu_to_32wu() Date: Sun, 25 Aug 2013 15:59:37 +0100 Message-Id: <1377442777-11066-10-git-send-email-peter.maydell@linaro.org> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1377442777-11066-1-git-send-email-peter.maydell@linaro.org> References: <1377442777-11066-1-git-send-email-peter.maydell@linaro.org> X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: peter.maydell@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.182 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Replace the legacy cpu_to_32wu() with stl_p(). Signed-off-by: Peter Maydell --- hw/display/vga_template.h | 14 ++++++++------ include/qemu/bswap.h | 7 ------- 2 files changed, 8 insertions(+), 13 deletions(-) diff --git a/hw/display/vga_template.h b/hw/display/vga_template.h index f6f6a01..6cfae56 100644 --- a/hw/display/vga_template.h +++ b/hw/display/vga_template.h @@ -113,20 +113,22 @@ static void glue(vga_draw_glyph9_, DEPTH)(uint8_t *d, int linesize, do { font_data = font_ptr[0]; #if BPP == 1 - cpu_to_32wu((uint32_t *)d, (dmask16[(font_data >> 4)] & xorcol) ^ bgcol); + stl_p((uint32_t *)d, (dmask16[(font_data >> 4)] & xorcol) ^ bgcol); v = (dmask16[(font_data >> 0) & 0xf] & xorcol) ^ bgcol; - cpu_to_32wu(((uint32_t *)d)+1, v); + stl_p(((uint32_t *)d)+1, v); if (dup9) ((uint8_t *)d)[8] = v >> (24 * (1 - BIG)); else ((uint8_t *)d)[8] = bgcol; #elif BPP == 2 - cpu_to_32wu(((uint32_t *)d)+0, (dmask4[(font_data >> 6)] & xorcol) ^ bgcol); - cpu_to_32wu(((uint32_t *)d)+1, (dmask4[(font_data >> 4) & 3] & xorcol) ^ bgcol); - cpu_to_32wu(((uint32_t *)d)+2, (dmask4[(font_data >> 2) & 3] & xorcol) ^ bgcol); + stl_p(((uint32_t *)d)+0, (dmask4[(font_data >> 6)] & xorcol) ^ bgcol); + stl_p(((uint32_t *)d)+1, + (dmask4[(font_data >> 4) & 3] & xorcol) ^ bgcol); + stl_p(((uint32_t *)d)+2, + (dmask4[(font_data >> 2) & 3] & xorcol) ^ bgcol); v = (dmask4[(font_data >> 0) & 3] & xorcol) ^ bgcol; - cpu_to_32wu(((uint32_t *)d)+3, v); + stl_p(((uint32_t *)d)+3, v); if (dup9) ((uint16_t *)d)[8] = v >> (16 * (1 - BIG)); else diff --git a/include/qemu/bswap.h b/include/qemu/bswap.h index 4cbd6e7..437b8e0 100644 --- a/include/qemu/bswap.h +++ b/include/qemu/bswap.h @@ -410,13 +410,6 @@ static inline void stfq_be_p(void *ptr, float64 v) stq_be_p(ptr, u.ll); } -/* Legacy unaligned versions. Note that we never had a complete set. */ - -static inline void cpu_to_32wu(uint32_t *p, uint32_t v) -{ - stl_p(p, v); -} - static inline unsigned long leul_to_cpu(unsigned long v) { /* In order to break an include loop between here and