From patchwork Fri Sep 25 14:55:40 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Christian_K=C3=B6nig?= X-Patchwork-Id: 11799959 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id D5C6D92C for ; Fri, 25 Sep 2020 14:55:56 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id A4606206CA for ; Fri, 25 Sep 2020 14:55:56 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="KNli49Ln" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A4606206CA Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 660636ED1A; Fri, 25 Sep 2020 14:55:54 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-ej1-x642.google.com (mail-ej1-x642.google.com [IPv6:2a00:1450:4864:20::642]) by gabe.freedesktop.org (Postfix) with ESMTPS id 7489F6ED08 for ; Fri, 25 Sep 2020 14:55:47 +0000 (UTC) Received: by mail-ej1-x642.google.com with SMTP id r7so3993567ejs.11 for ; Fri, 25 Sep 2020 07:55:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=Z7XU+yP/bsBujqhXnfycnuQH2YIpNZad/xq6b1YCXms=; b=KNli49Ln1KnsYE3G1lc4MItVdHzB3s4PEZPzSm2hM6qZNSGYrt8iXLkilUM22GuJ2V 2crT8LIyzt2FybSyc/VWFVHRbaGLEXhFy8KjWrKL8bO3vcuzcVj3BZAEykP3HDLu7p4Y 9STplIIolY46Zexn2ZlC1e2nZxuKmXW7UuYXRKB+0+typgvPyBjcnAOlt/72SYw+97j8 uTuFNaQDv6mu2l8XFuxUYz2KV+Mwx2xthuujhow1Z+2YmC9EI3JGwnTwZQrAEJMd2vna Oa65YnqfwQzc0bOcBW2nfWf5azSpH/GLNToVi4J6VhqeCcbW3JCpmvns27akV0IHoR8r hE4A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=Z7XU+yP/bsBujqhXnfycnuQH2YIpNZad/xq6b1YCXms=; b=Mw4owPhomUBdwBpQETaY4+niVaBAyLVF8uL+qY+hIQXx/KDrsvtuLfh5JX1XldkMrQ lfWeEtX1GqAvi2Qjz4wfWVPubifKPNYg8fY7xR0LxZp/IYeRgHALAS7VEcORXvMe0y7y XQCmvoGx38FWA72mUE3cmClyKcYOdVD+y708wnuoBW90ZBjl8uFnXWPg//ME1KVOqxvY d887XG3QErYFTP+W8heiBJ01iPtHpI9uaxZVPk2G3lnDAEUNOkkW5WG6DqPiKtWDMAJh 3oawzKHjHVQhCvfjM+3xwWNRjkyTqSFle/I0A1ci2xCvtnSmT8LgI4+pIopQ90rD7neM 9IrQ== X-Gm-Message-State: AOAM533BKa+aSLkfruldbh5WdshfLgGsA+jjKtp7wZQ7vi9pS4iOj3ko EW1nqataXsWHhl59ACDRVmAxqwvbj+A= X-Google-Smtp-Source: ABdhPJzyqbCSY7OD3g4ksLeRgQrmB7rDS7Rp/nCh3vNv0ftZzif2KhzWmPM0jOblEoORrFtmNF+78g== X-Received: by 2002:a17:906:194b:: with SMTP id b11mr2991700eje.159.1601045745915; Fri, 25 Sep 2020 07:55:45 -0700 (PDT) Received: from abel.fritz.box ([2a02:908:1252:fb60:c75e:403f:87d4:6d00]) by smtp.gmail.com with ESMTPSA id lo25sm2029990ejb.53.2020.09.25.07.55.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Sep 2020 07:55:44 -0700 (PDT) From: " =?utf-8?q?Christian_K=C3=B6nig?= " X-Google-Original-From: =?utf-8?q?Christian_K=C3=B6nig?= To: dri-devel@lists.freedesktop.org, ray.huang@amd.com, airlied@redhat.com Subject: [PATCH 5/5] drm/ttm: remove fault callback Date: Fri, 25 Sep 2020 16:55:40 +0200 Message-Id: <20200925145540.1214-5-christian.koenig@amd.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200925145540.1214-1-christian.koenig@amd.com> References: <20200925145540.1214-1-christian.koenig@amd.com> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Another one bites the dust. Signed-off-by: Christian König --- drivers/gpu/drm/ttm/ttm_bo_vm.c | 22 ---------------------- include/drm/ttm/ttm_bo_driver.h | 3 --- 2 files changed, 25 deletions(-) diff --git a/drivers/gpu/drm/ttm/ttm_bo_vm.c b/drivers/gpu/drm/ttm/ttm_bo_vm.c index 991ef132e108..87ee8f0ca08e 100644 --- a/drivers/gpu/drm/ttm/ttm_bo_vm.c +++ b/drivers/gpu/drm/ttm/ttm_bo_vm.c @@ -290,28 +290,6 @@ vm_fault_t ttm_bo_vm_fault_reserved(struct vm_fault *vmf, vm_fault_t ret = VM_FAULT_NOPAGE; unsigned long address = vmf->address; - if (bdev->driver->fault_reserve_notify) { - struct dma_fence *moving = dma_fence_get(bo->moving); - - err = bdev->driver->fault_reserve_notify(bo); - switch (err) { - case 0: - break; - case -EBUSY: - case -ERESTARTSYS: - dma_fence_put(moving); - return VM_FAULT_NOPAGE; - default: - dma_fence_put(moving); - return VM_FAULT_SIGBUS; - } - - if (bo->moving != moving) { - ttm_bo_move_to_lru_tail_unlocked(bo); - } - dma_fence_put(moving); - } - /* * Wait for buffer data in transit, due to a pipelined * move. diff --git a/include/drm/ttm/ttm_bo_driver.h b/include/drm/ttm/ttm_bo_driver.h index 864afa8f6f18..9897a16c0a9d 100644 --- a/include/drm/ttm/ttm_bo_driver.h +++ b/include/drm/ttm/ttm_bo_driver.h @@ -190,9 +190,6 @@ struct ttm_bo_driver { void (*move_notify)(struct ttm_buffer_object *bo, bool evict, struct ttm_resource *new_mem); - /* notify the driver we are taking a fault on this BO - * and have reserved it */ - int (*fault_reserve_notify)(struct ttm_buffer_object *bo); /** * notify the driver that we're about to swap out this bo