From patchwork Tue Jul 2 08:01:34 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Zimmermann X-Patchwork-Id: 11027405 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id AE033112C for ; Tue, 2 Jul 2019 08:01:54 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9968F28641 for ; Tue, 2 Jul 2019 08:01:54 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8D7412871A; Tue, 2 Jul 2019 08:01:54 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 4F84328641 for ; Tue, 2 Jul 2019 08:01:54 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id DE16389A5D; Tue, 2 Jul 2019 08:01:49 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mx1.suse.de (mx2.suse.de [195.135.220.15]) by gabe.freedesktop.org (Postfix) with ESMTPS id 17B2889A4A for ; Tue, 2 Jul 2019 08:01:49 +0000 (UTC) X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 5AE05B048; Tue, 2 Jul 2019 08:01:47 +0000 (UTC) From: Thomas Zimmermann To: kraxel@redhat.com, airlied@redhat.com, daniel@ffwll.ch, maarten.lankhorst@linux.intel.com, maxime.ripard@bootlin.com, sean@poorly.run, sam@ravnborg.org, z.liuxinliang@hisilicon.com, zourongrong@gmail.com, kong.kongxinwei@hisilicon.com, puck.chen@hisilicon.com, hdegoede@redhat.com Subject: [PATCH v2 0/5] Convert VRAM helpers to GEM object functions Date: Tue, 2 Jul 2019 10:01:34 +0200 Message-Id: <20190702080139.21814-1-tzimmermann@suse.de> X-Mailer: git-send-email 2.21.0 MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Thomas Zimmermann , dri-devel@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP The PRIME callback functions in struct drm_driver are deprecated in favor of their counterparts in struct drm_gem_object_funcs. This patch set introduces GEM object functions for VRAM helpers and converts over the free and PRIME functions. Drivers affected by this change, namely bochs and hibmc, are adapted accordingly. The patch set's v1 was acked by Daniel Vetter. I only took it for the driver patches, as the VRAM patches have changed significantly in v2. v2: * rename VRAM PRIME functions instead of replacing them * set struct drm_driver.gem_prime_mmap in hibmc * replace vbox driver's empty PRIME implementation Thomas Zimmermann (5): drm/vram: Set GEM object functions for PRIME drm/bochs: Remove PRIME helpers from driver structure drm/hibmc: Update struct drm_driver for GEM object functions drm/vbox: Remove empty PRIME functions drm/vram: Don't export driver callback functions for PRIME Documentation/gpu/todo.rst | 4 +- drivers/gpu/drm/bochs/bochs_drv.c | 1 - drivers/gpu/drm/drm_gem_vram_helper.c | 188 +++++++----------- .../gpu/drm/hisilicon/hibmc/hibmc_drm_drv.c | 3 +- drivers/gpu/drm/vboxvideo/Makefile | 2 +- drivers/gpu/drm/vboxvideo/vbox_drv.c | 9 - drivers/gpu/drm/vboxvideo/vbox_drv.h | 12 -- drivers/gpu/drm/vboxvideo/vbox_prime.c | 56 ------ include/drm/drm_gem_vram_helper.h | 25 +-- 9 files changed, 75 insertions(+), 225 deletions(-) delete mode 100644 drivers/gpu/drm/vboxvideo/vbox_prime.c --- 2.21.0