Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp2755973pxj; Mon, 31 May 2021 09:57:49 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwstzBfiFPzEY9h+FuTvi26nH+tl3SZbKbcoAEngF+5ot0qLfukI6xMvuc5lo+xyMOhv3ik X-Received: by 2002:aa7:c04e:: with SMTP id k14mr25947127edo.157.1622480269587; Mon, 31 May 2021 09:57:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1622480269; cv=none; d=google.com; s=arc-20160816; b=xBb67exskZ8fIBBgbtJpb6aHiiZyY2M+ikRMAeCjegHdkGsLvu/K02fO2tWaUcDHjA csUxCC5cVzyYb9UDKwzn1TdAKkDZSqw9kevnGIHqJKr5kv02lgE084fLfsZAO5UoEIuM ATvCmtmWoA6eaAljYUCx9gjWY/RcvhM7Z9zHm3Ueei6US/somu+FmRxNSEk/HAdPpUnc TPBe8cxaVrYZB7diYHE6sG5zazLgdLCUBz/RjIfPSGAVvPdPLDq+OgWpKa4tijujn7HR yClgIKOC3BroWpmauRiHm0x/E1R+CHx7dSwj7F2GwUeClyBDFb/e8cFdPK1OD262hjzn CUDQ== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=pNl56AbkS0ZXV3yFnKcVaPLB59P+cq1+GonszjTfXeI=; b=HLCTE2hLvOGFwuTpInqQvqDztF4H/WyD+rf8lUVHSK4D2/PTC47nOQZ8VnwP5IA+3A J6iqyAag6IMU6b7rm8M2G9syk2boiHwO3e6LGBCIcuGJQaKKLUYCg4tzp/GJr3NaYXCY svn4oqznC83iskLzGl5pJ7KKpLFVi/mY2x1C5DZoTh0mCc6jIGQHcCwE3dJ69tCGXjVf Dk4q5EcohwEBDOixMJ7wGqAtd9w2lC2g3kexqSI57FZfEyskNG3pPSLkfG8KfWq0a6JG Ib7jvcEeQauw+t3Jex831bs4+shbuOcb00VK8JPuiBOUi71b462QtjR8S8LMCKoLOj3i KNjw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=PIsuw224; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u21si9405721ejz.696.2021.05.31.09.57.26; Mon, 31 May 2021 09:57:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=PIsuw224; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232339AbhEaQze (ORCPT + 99 others); Mon, 31 May 2021 12:55:34 -0400 Received: from mail.kernel.org ([198.145.29.99]:51034 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234130AbhEaPAj (ORCPT ); Mon, 31 May 2021 11:00:39 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id DD7FD613AD; Mon, 31 May 2021 14:14:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1622470482; bh=zC4OPIc9eEpXm+Ok5oEw0HDZKkn58dj2vDLqSK7D6A0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=PIsuw224qQMxNKjzFD523RCv4MTEXrHnqOWLERqNRoclNUPgeX79IpOIqgxnv3pRk 6feGQj7ZfGfDOqwcmProGxWXiZS+7csq2JfWA/2ISt77tcI2bxPSiyhTuGcjoOCho1 LISVQK6lHTkRyGrQnf3u6v0Oo7Hl8ffoWr6mnclM= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Zhang Xiaoxu , Trond Myklebust Subject: [PATCH 5.12 116/296] NFSv4: Fix v4.0/v4.1 SEEK_DATA return -ENOTSUPP when set NFS_V4_2 config Date: Mon, 31 May 2021 15:12:51 +0200 Message-Id: <20210531130707.823014710@linuxfoundation.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210531130703.762129381@linuxfoundation.org> References: <20210531130703.762129381@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Zhang Xiaoxu commit e67afa7ee4a59584d7253e45d7f63b9528819a13 upstream. Since commit bdcc2cd14e4e ("NFSv4.2: handle NFS-specific llseek errors"), nfs42_proc_llseek would return -EOPNOTSUPP rather than -ENOTSUPP when SEEK_DATA on NFSv4.0/v4.1. This will lead xfstests generic/285 not run on NFSv4.0/v4.1 when set the CONFIG_NFS_V4_2, rather than run failed. Fixes: bdcc2cd14e4e ("NFSv4.2: handle NFS-specific llseek errors") Cc: # 4.2 Signed-off-by: Zhang Xiaoxu Signed-off-by: Trond Myklebust Signed-off-by: Greg Kroah-Hartman --- fs/nfs/nfs4file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/fs/nfs/nfs4file.c +++ b/fs/nfs/nfs4file.c @@ -211,7 +211,7 @@ static loff_t nfs4_file_llseek(struct fi case SEEK_HOLE: case SEEK_DATA: ret = nfs42_proc_llseek(filep, offset, whence); - if (ret != -ENOTSUPP) + if (ret != -EOPNOTSUPP) return ret; fallthrough; default: