Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp9204025ybi; Tue, 23 Jul 2019 23:54:30 -0700 (PDT) X-Google-Smtp-Source: APXvYqwYk04fcyATSBz9vKTX2TIelUUK9h2y64KFM3QbTvschVX4l82FazZMxOghozaKxZRwyFzR X-Received: by 2002:a17:902:a514:: with SMTP id s20mr79941228plq.162.1563951270512; Tue, 23 Jul 2019 23:54:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1563951270; cv=none; d=google.com; s=arc-20160816; b=P/zGjkQs04waFgZG19ZlUVwTAyr1L2ySV9wRPqVVMU70YnzqV0jLokXRNh3wD06bGV qIF+wlzoxe3RUwy3wUAtU58JKuJVNqY1tW2hWan+j54brQnM4v16jgk3fuCfY02+1sXD Vsjx9HdbwvXMb6PbTDiyaP7NEN6AL97V7yMYYBJfHEQl8EpPgHLPVH5bsaFEuACkluti RkHIt99eSbvIGs7qYLzCJRnR6kxC8W6ToTIkANdxNKkSN2RqBKVW/dKbifv57wiQfkPS C2WdnO8bI0PFxRV93dPWd+Q5n0UadqFRGwZHTLFIqQ4pw6kIMeGkRKq5TzfCfXrVRkzm mS2Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=igXh/3abv0ooQdkv/Vfc/WSfVB4lkdoSYebCAR1TL48=; b=oY3zWq/Fvmhd1ZCrV/0V1Se5dQlvYRI3AJKcq2e/7UjpQYF+CrTZgbSdcBTWHPYYIK Yk7hboXZKeB3cCg77Tj6+52e4nehLqgHrUi+LmrpDrJXwzejaPG69Ltgalj+L8BGDNkc Q98+C+RTkw+SW+QE2xesYfGNmzG5KlF0gz59VzHILXKHb/BMlM9Dz427EX6eD9lXkEJW HIkvXcozPj6T99ow67c3Wn6LiELDgcb0vuyyWX2bykwnOCmK9Uqo4XRel02BigscOmlu YdUiyJgc4yrIOkaEUDzCarE+5QBfNU6WMy8quXZrLfmbtLfR2sqJyxU2LM0t+/VgAAf+ gyNQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=IDkGONdX; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u7si2860785pgc.460.2019.07.23.23.54.16; Tue, 23 Jul 2019 23:54:30 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=IDkGONdX; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726543AbfGXGxW (ORCPT + 99 others); Wed, 24 Jul 2019 02:53:22 -0400 Received: from bombadil.infradead.org ([198.137.202.133]:39332 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725909AbfGXGxU (ORCPT ); Wed, 24 Jul 2019 02:53:20 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From :Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help: List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=igXh/3abv0ooQdkv/Vfc/WSfVB4lkdoSYebCAR1TL48=; b=IDkGONdXpH3tW1oxhx++LkR9Lr WtaFZ+boWB9F31gk5CqaFbhNeFfrtl5YLLAPAezcvPdlRxacMmzCyuUcbJkfsIU6ge7zEVv6VK3Lp BVN8c2sSrD9gXy2zzFgQNQxPeES0fjs+kwg6uO+b6FRTGfvZoI4LaBGXq5SxfAg1diq5NAYBrGEmT LgBCFZZp8wWhbrk+FwzSlyBkPvD4HtkVG7f4VC7cE6HJ/umGb0LSiSUT67UWqJ0MlfM/eAnG+yM66 VhwUGjcVxt/otVXADUHsEEIdhJYMPPs8S9yngWBDr8DsSJQqvQUpJqMoQJQ2kuAdZG+rSN7e5CHvH SlT6wdaA==; Received: from 089144207240.atnat0016.highway.bob.at ([89.144.207.240] helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.92 #3 (Red Hat Linux)) id 1hqB9J-0004Ko-0z; Wed, 24 Jul 2019 06:53:17 +0000 From: Christoph Hellwig To: =?UTF-8?q?J=C3=A9r=C3=B4me=20Glisse?= , Jason Gunthorpe , Ben Skeggs Cc: Ralph Campbell , linux-mm@kvack.org, nouveau@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: [PATCH 5/7] nouveau: return -EBUSY when hmm_range_wait_until_valid fails Date: Wed, 24 Jul 2019 08:52:56 +0200 Message-Id: <20190724065258.16603-6-hch@lst.de> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190724065258.16603-1-hch@lst.de> References: <20190724065258.16603-1-hch@lst.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org -EAGAIN has a magic meaning for non-blocking faults, so don't overload it. Given that the caller doesn't check for specific error codes this change is purely cosmetic. Signed-off-by: Christoph Hellwig Reviewed-by: Jason Gunthorpe --- drivers/gpu/drm/nouveau/nouveau_svm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/nouveau/nouveau_svm.c b/drivers/gpu/drm/nouveau/nouveau_svm.c index a835cebb6d90..545100f7c594 100644 --- a/drivers/gpu/drm/nouveau/nouveau_svm.c +++ b/drivers/gpu/drm/nouveau/nouveau_svm.c @@ -502,7 +502,7 @@ nouveau_range_fault(struct hmm_mirror *mirror, struct hmm_range *range) if (!hmm_range_wait_until_valid(range, HMM_RANGE_DEFAULT_TIMEOUT)) { up_read(&range->vma->vm_mm->mmap_sem); - return -EAGAIN; + return -EBUSY; } ret = hmm_range_fault(range, true); -- 2.20.1