From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_PASS,USER_AGENT_NEOMUTT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 560D9C004C9 for ; Tue, 7 May 2019 07:56:18 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 293082087F for ; Tue, 7 May 2019 07:56:18 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 293082087F Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Received: from localhost ([127.0.0.1]:41729 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hNuxV-0007r8-F3 for qemu-devel@archiver.kernel.org; Tue, 07 May 2019 03:56:17 -0400 Received: from eggs.gnu.org ([209.51.188.92]:52601) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hNuvi-0006pX-BJ for qemu-devel@nongnu.org; Tue, 07 May 2019 03:54:27 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hNuvh-0005cm-HF for qemu-devel@nongnu.org; Tue, 07 May 2019 03:54:26 -0400 Received: from mx1.redhat.com ([209.132.183.28]:60981) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hNuvh-0005cB-Bn for qemu-devel@nongnu.org; Tue, 07 May 2019 03:54:25 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 6CD3730832C3; Tue, 7 May 2019 07:54:24 +0000 (UTC) Received: from sirius.home.kraxel.org (ovpn-116-45.ams2.redhat.com [10.36.116.45]) by smtp.corp.redhat.com (Postfix) with ESMTP id 14E104C47E; Tue, 7 May 2019 07:54:21 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id 4565E11AA3; Tue, 7 May 2019 09:54:15 +0200 (CEST) Date: Tue, 7 May 2019 09:54:15 +0200 From: Gerd Hoffmann To: Daniel =?utf-8?B?UC4gQmVycmFuZ8Op?= Message-ID: <20190507075415.fsngpdrgnh2e5vch@sirius.home.kraxel.org> References: <20190412121626.19829-1-berrange@redhat.com> <20190412121626.19829-6-berrange@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline In-Reply-To: <20190412121626.19829-6-berrange@redhat.com> User-Agent: NeoMutt/20180716 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.44]); Tue, 07 May 2019 07:54:24 +0000 (UTC) Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.132.183.28 Subject: Re: [Qemu-devel] [PATCH v2 5/5] qxl: avoid unaligned pointer reads/writes X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Riku Voipio , qemu-devel@nongnu.org, Laurent Vivier Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" On Fri, Apr 12, 2019 at 01:16:26PM +0100, Daniel P. Berrang=E9 wrote: > The SPICE_RING_PROD_ITEM() macro is initializing a local > 'uint64_t *' variable to point to the 'el' field inside > the QXLReleaseRing struct. This uint64_t field is not > guaranteed aligned as the struct is packed. >=20 > Code should not take the address of fields within a > packed struct. Changing the SPICE_RING_PROD_ITEM() > macro to avoid taking the address of the field is > impractical. It is clearer to just remove the macro > and inline its functionality in the three call sites > that need it. Added patch to vga queue. thanks, Gerd