Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp3371533pxv; Mon, 26 Jul 2021 02:45:27 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz+TYHiDjYEq2116UYDjA1BEqM3V1OrtK9toYOSUX5xOmJlu2WkMBBcHVX3PM8kldImaOGQ X-Received: by 2002:a05:6402:1d2d:: with SMTP id dh13mr20796360edb.90.1627292727240; Mon, 26 Jul 2021 02:45:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1627292727; cv=none; d=google.com; s=arc-20160816; b=pIKNrglFE5CZVDlyq4TcKGr98+nhF9J159oy+3cdkjnjcO1JYRNVugyefCIwLz9w5h 37ggs6ZLvqxsFSk9DT+aNh7YSRnRogHoLlcGgP2ruAl9SkgVLKfFHdO6xYDFjtA5erI4 5dJfh+VFUfSPqYwEgPiVHI8w64oSxinII5UnAOKJ1TZ6Zt9gqF2hUirlycxijuu84RCX AiBQnoRSW6lvLnShocVgp/TFTfjSO5X54Xsl0++eM/CxrObTt6t947aLyA2eWCeLjZTP fU2rxV9hT1XKSYGIC2RydFlcxPbF0KBEBC4QywmHAqYoV+tTrF98oGaSclsXAfosrxCE 7MQw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:content-id:mime-version:subject :cc:to:references:in-reply-to:from:organization:dkim-signature; bh=kBC7/7n7ieIR+PQocFWGsdEhjsiqMRhY14cESzBGes0=; b=dQmAVqur7cuh//Ym63JLGiS+ma7mKWyENJIG4X6Cf78A86mh+EvU7S+/YWEzdpYgx3 NULhRzFXZbWLJlWXSpY5JJ5fchS26N/jrE4FZrLhaRoGiE0R70XSgtC+Eu3Ek75eXQOK HE2zLBd6RxpbrEFQ4W7OILiMO3PQpLex6C0wBNsfMOo/aVM9o7PPmL3uSKRX5aRrNQ9g 1q4cCM2Nawchf4OgqYQHOsMDoITHAhwo//yvfxcxTaGSQ20PEgfT7sHAuTzKQkx6XJyG Nte5/UWW7pzfVeh7IcDOje2rzXmqXQ8fChZLJNq0P76XFUojv9tLEdgtJ+OFS87yYGuI JY8w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b="Wbg1ZZ/n"; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m22si41195835ejj.666.2021.07.26.02.44.52; Mon, 26 Jul 2021 02:45:27 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-nfs-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=@redhat.com header.s=mimecast20190719 header.b="Wbg1ZZ/n"; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232628AbhGZJEU (ORCPT + 99 others); Mon, 26 Jul 2021 05:04:20 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:54170 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232524AbhGZJET (ORCPT ); Mon, 26 Jul 2021 05:04:19 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1627292688; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=kBC7/7n7ieIR+PQocFWGsdEhjsiqMRhY14cESzBGes0=; b=Wbg1ZZ/nBVA5QPydlyjv+cODt5GnjnN6p4kgEeGgESCTM3tpidvwr/oROn5GPcccnY6Urm W/bP/eyk0ilHQ2u27baIttOq/8jNCESFgc/lVSgzgcmq8eo+Mj3vqS0sZYAkNXqU2I3NEd PmghVWglsw5HuK1qaCK0Jxg70ACE3iw= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-454-brLp6B6MMoKsBE9RNfYfwA-1; Mon, 26 Jul 2021 05:44:47 -0400 X-MC-Unique: brLp6B6MMoKsBE9RNfYfwA-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id A966F8799EF; Mon, 26 Jul 2021 09:44:44 +0000 (UTC) Received: from warthog.procyon.org.uk (unknown [10.22.16.89]) by smtp.corp.redhat.com (Postfix) with ESMTP id 61BB85C1D1; Mon, 26 Jul 2021 09:44:36 +0000 (UTC) Organization: Red Hat UK Ltd. Registered Address: Red Hat UK Ltd, Amberley Place, 107-111 Peascod Street, Windsor, Berkshire, SI4 1TE, United Kingdom. Registered in England and Wales under Company Registration No. 3798903 From: David Howells In-Reply-To: <35ecb577315f486f1636b2316c2051ad004f6f7b.camel@redhat.com> References: <35ecb577315f486f1636b2316c2051ad004f6f7b.camel@redhat.com> <162687506932.276387.14456718890524355509.stgit@warthog.procyon.org.uk> <162687508008.276387.6418924257569297305.stgit@warthog.procyon.org.uk> To: Jeff Layton Cc: dhowells@redhat.com, linux-fsdevel@vger.kernel.org, "Matthew Wilcox (Oracle)" , Anna Schumaker , Steve French , Dominique Martinet , Mike Marshall , David Wysochanski , Shyam Prasad N , Miklos Szeredi , Linus Torvalds , linux-cachefs@redhat.com, linux-afs@lists.infradead.org, linux-nfs@vger.kernel.org, linux-cifs@vger.kernel.org, ceph-devel@vger.kernel.org, v9fs-developer@lists.sourceforge.net, devel@lists.orangefs.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [RFC PATCH 01/12] afs: Sort out symlink reading MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <812199.1627292675.1@warthog.procyon.org.uk> Date: Mon, 26 Jul 2021 10:44:35 +0100 Message-ID: <812200.1627292675@warthog.procyon.org.uk> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org Jeff Layton wrote: > > -static int afs_symlink_readpage(struct page *page) > > +static int afs_symlink_readpage(struct file *file, struct page *page) > > { > > struct afs_vnode *vnode = AFS_FS_I(page->mapping->host); > > struct afs_read *fsreq; > > > I wonder...would you be better served here by not using page_readlink > for symlinks and instead use simple_get_link and roll your own readlink > operation. It seems a bit more direct, and AFS seems to be the only > caller of page_readlink. Maybe. At some point it will need to go through netfs_readpage() so that it will get cached and maybe encrypted. Possibly there should be a netfs_readlink(). AFS directories too will at some point need to go through netfs_readahead() or similar. David