Message ID | 20221017104602.142992-1-steven.price@arm.com |
---|---|
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4ac7:0:0:0:0:0 with SMTP id y7csp1379067wrs; Mon, 17 Oct 2022 03:53:34 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5q3Dg5R9t9XIHg6xGy/oO6TvDkFURMxETiExMJbX1gxNzuk9SydvSPN2mIxxqdZBSP/d2E X-Received: by 2002:a05:6a00:4214:b0:562:67d0:77e7 with SMTP id cd20-20020a056a00421400b0056267d077e7mr12374241pfb.62.1666004013701; Mon, 17 Oct 2022 03:53:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666004013; cv=none; d=google.com; s=arc-20160816; b=tPYDAAUKEMPFp6XqnT/OtpSV6v/BKdaTJeEljK6SsAyYzvK4MnW4tphpGN79yG66ZV Hp2n9jg1gRK3sy/ND1wJE1jOD2nqgPHyzZpG9rpnQGHJFAlJi+HbyLVwlNTzm1RXir1A Cf3IhVez66BSXsmNT8E2q7cfMA+PiDi7q72PMBHNGzOh/KfDf88qwObis52lOA2N/95V Y4GULSIkH3GP8eAvNthaeE9QcfAWmrG0flpu1UEc6qDSNG6ZFzVz75QcjoPT45IosaZX VtXpPyoNsrkWa6FsR6gFWE/Ex36zqzbNF6DEF07w1Nt9o4lKJMvqOxTvEm7c97S6boP3 35rQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=jZzPADXvkbVwtWSLL6OPqiE8a3wnp+/1nc9Urmv18BU=; b=O8xiGch6JowIIQbrJ0aCa6EQfRam/LKhs0QM2fgErZ+JZmiKLp7CVA5YyVc0twNfKN 8N0X+yBgsdDnxIRIwwuhnnUbm9klqtkkXLJbTtzuRxd2yH53APuB13HkeORc7608Wfua rmcstKNkeKiLg3hjM+cbT6jpn39FP5+wJ+iqsFBl+zOKfbEi9BtcAMr45wBOR2bkXRoi qV6UGqmCx5mS/ncdt0rq4b+M5zPcmrKw8datJqc/Yvqp+cZ9z225vV4qvVkywV9DNief Iu1poX7QOneb9jwVQzsV25wRVjyxFOMPHvdt895NapNxd+h8RyXpbGHT0SoPas/WYpPr lw3w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id s7-20020a17090302c700b0017532e01e57si11113322plk.200.2022.10.17.03.53.21; Mon, 17 Oct 2022 03:53:33 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230172AbiJQKqR (ORCPT <rfc822;ouuuleilei@gmail.com> + 99 others); Mon, 17 Oct 2022 06:46:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51540 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230199AbiJQKqN (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Mon, 17 Oct 2022 06:46:13 -0400 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 15EBB18B3E for <linux-kernel@vger.kernel.org>; Mon, 17 Oct 2022 03:46:11 -0700 (PDT) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 29F591042; Mon, 17 Oct 2022 03:46:17 -0700 (PDT) Received: from e122027.arm.com (unknown [10.57.1.201]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id B3B293F67D; Mon, 17 Oct 2022 03:46:09 -0700 (PDT) From: Steven Price <steven.price@arm.com> To: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>, =?utf-8?q?Adri?= =?utf-8?q?=C3=A1n_Larumbe?= <adrian.larumbe@collabora.com> Cc: Steven Price <steven.price@arm.com>, Rob Herring <robh@kernel.org>, Tomeu Vizoso <tomeu.vizoso@collabora.com>, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Robin Murphy <robin.murphy@arm.com> Subject: [PATCH v2 0/2] drm/panfrost: Fix UAPI for C++/BSD compatibility Date: Mon, 17 Oct 2022 11:46:00 +0100 Message-Id: <20221017104602.142992-1-steven.price@arm.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW, SPF_HELO_NONE,SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1746931824876414107?= X-GMAIL-MSGID: =?utf-8?q?1746931824876414107?= |
Series |
drm/panfrost: Fix UAPI for C++/BSD compatibility
|
|
Message
Steven Price
Oct. 17, 2022, 10:46 a.m. UTC
The Panfrost DRM interface to user space is uesd in Mesa for targets other than C/Linux. Specifically the header file needs to compile in C++ code and for FreeBSD which shares the same UABI. The first patch fixes the C++ compilation issue by removing the (unnecessary) type name from internal structs which is invalid in C++. The second patch technically changes the UABI by changing the header values in the dump format to be native endian rather than fixed little-endian. Since (a) there are no known big-endian Mali systems, and (b) this has only appeared in -rc1, this shouldn't break user space. Tools can use the 'magic' field to identify the endianness of the dump if they want to support big-endian. This is effectively a 'v2' of Adrián's series here [1]. [1] https://lore.kernel.org/r/20220920211545.1017355-1-adrian.larumbe%40collabora.com Steven Price (2): drm/panfrost: Remove type name from internal structs drm/panfrost: replace endian-specific types with native ones drivers/gpu/drm/panfrost/panfrost_dump.c | 36 ++++++++++++------------ include/uapi/drm/panfrost_drm.h | 36 +++++++++++++----------- 2 files changed, 38 insertions(+), 34 deletions(-)
Comments
Series is Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Thank you for this, please push to the appropriate trees so we can fix the Mesa build. On Mon, Oct 17, 2022 at 11:46:00AM +0100, Steven Price wrote: > The Panfrost DRM interface to user space is uesd in Mesa for targets > other than C/Linux. Specifically the header file needs to compile in C++ > code and for FreeBSD which shares the same UABI. > > The first patch fixes the C++ compilation issue by removing the > (unnecessary) type name from internal structs which is invalid in C++. > > The second patch technically changes the UABI by changing the header > values in the dump format to be native endian rather than fixed > little-endian. Since (a) there are no known big-endian Mali systems, and > (b) this has only appeared in -rc1, this shouldn't break user space. > Tools can use the 'magic' field to identify the endianness of the dump > if they want to support big-endian. > > This is effectively a 'v2' of Adri??n's series here [1]. > > [1] https://lore.kernel.org/r/20220920211545.1017355-1-adrian.larumbe%40collabora.com > > Steven Price (2): > drm/panfrost: Remove type name from internal structs > drm/panfrost: replace endian-specific types with native ones > > drivers/gpu/drm/panfrost/panfrost_dump.c | 36 ++++++++++++------------ > include/uapi/drm/panfrost_drm.h | 36 +++++++++++++----------- > 2 files changed, 38 insertions(+), 34 deletions(-) > > -- > 2.34.1 >
On 17/10/2022 16:44, Alyssa Rosenzweig wrote: > Series is > > Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> > > Thank you for this, please push to the appropriate trees so we can fix > the Mesa build. Thanks! I've pushed the patches to drm-misc-fixes. Steve > On Mon, Oct 17, 2022 at 11:46:00AM +0100, Steven Price wrote: >> The Panfrost DRM interface to user space is uesd in Mesa for targets >> other than C/Linux. Specifically the header file needs to compile in C++ >> code and for FreeBSD which shares the same UABI. >> >> The first patch fixes the C++ compilation issue by removing the >> (unnecessary) type name from internal structs which is invalid in C++. >> >> The second patch technically changes the UABI by changing the header >> values in the dump format to be native endian rather than fixed >> little-endian. Since (a) there are no known big-endian Mali systems, and >> (b) this has only appeared in -rc1, this shouldn't break user space. >> Tools can use the 'magic' field to identify the endianness of the dump >> if they want to support big-endian. >> >> This is effectively a 'v2' of Adri??n's series here [1]. >> >> [1] https://lore.kernel.org/r/20220920211545.1017355-1-adrian.larumbe%40collabora.com >> >> Steven Price (2): >> drm/panfrost: Remove type name from internal structs >> drm/panfrost: replace endian-specific types with native ones >> >> drivers/gpu/drm/panfrost/panfrost_dump.c | 36 ++++++++++++------------ >> include/uapi/drm/panfrost_drm.h | 36 +++++++++++++----------- >> 2 files changed, 38 insertions(+), 34 deletions(-) >> >> -- >> 2.34.1 >>