linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff Layton <jlayton@samba.org>
To: linux-cifs-client@lists.samba.org
Cc: linux-fsdevel@vger.kernel.org
Subject: [PATCH 06/15] cifs: add tcon field to cifsFileInfo struct
Date: Tue, 30 Mar 2010 15:51:08 -0400	[thread overview]
Message-ID: <1269978677-6817-7-git-send-email-jlayton@samba.org> (raw)
In-Reply-To: <1269978677-6817-1-git-send-email-jlayton@samba.org>

From: Jeff Layton <jlayton@redhat.com>

With more than one tcon per mount, we need to know which one is
associated with a particular fid.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
---
 fs/cifs/cifsglob.h |    1 +
 fs/cifs/dir.c      |    1 +
 2 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/fs/cifs/cifsglob.h b/fs/cifs/cifsglob.h
index 35bd90c..1aa8418 100644
--- a/fs/cifs/cifsglob.h
+++ b/fs/cifs/cifsglob.h
@@ -349,6 +349,7 @@ struct cifsFileInfo {
 	struct file *pfile; /* needed for writepage */
 	struct inode *pInode; /* needed for oplock break */
 	struct vfsmount *mnt;
+	struct cifsTconInfo *tcon;
 	struct mutex lock_mutex;
 	struct list_head llist; /* list of byte range locks we have. */
 	bool closePend:1;	/* file is marked to close */
diff --git a/fs/cifs/dir.c b/fs/cifs/dir.c
index 1b3d384..1ade8e1 100644
--- a/fs/cifs/dir.c
+++ b/fs/cifs/dir.c
@@ -153,6 +153,7 @@ cifs_new_fileinfo(struct inode *newinode, __u16 fileHandle,
 	pCifsFile->pfile = file;
 	pCifsFile->invalidHandle = false;
 	pCifsFile->closePend = false;
+	pCifsFile->tcon = cifs_sb_tcon(cifs_sb);
 	mutex_init(&pCifsFile->fh_mutex);
 	mutex_init(&pCifsFile->lock_mutex);
 	INIT_LIST_HEAD(&pCifsFile->llist);
-- 
1.6.6.1

  parent reply	other threads:[~2010-03-30 19:51 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-03-30 19:51 [PATCH 00/15] cifs: implement multisession mounts (RFC) Jeff Layton
2010-03-30 19:51 ` [PATCH 01/15] cifs: remove unused list_head from cifs_sb_info Jeff Layton
2010-03-30 19:51 ` [PATCH 02/15] cifs: add function to get a tcon from cifs_sb Jeff Layton
2010-03-30 19:51 ` [PATCH 03/15] cifs: track local_nls in volume info Jeff Layton
2010-03-30 19:51 ` [PATCH 04/15] cifs: move SMB session creation code into separate function Jeff Layton
2010-03-30 19:51 ` [PATCH 05/15] cifs: move tcon find/create " Jeff Layton
2010-03-30 19:51 ` Jeff Layton [this message]
2010-03-30 19:51 ` [PATCH 07/15] cifs: make various routines use the cifsFileInfo->tcon pointer Jeff Layton
2010-03-30 19:51 ` [PATCH 08/15] cifs: have find_readable/writable_file filter by fsuid Jeff Layton
2010-03-30 19:51 ` [PATCH 09/15] cifs: fix cifs_show_options to show "username=" or "multises" Jeff Layton
2010-03-30 19:51 ` [PATCH 10/15] cifs: move secType to the SMB session Jeff Layton
2010-03-30 19:51 ` [PATCH 11/15] cifs: have cifs_new_fileinfo take a tcon arg Jeff Layton
2010-03-30 19:51 ` [PATCH 12/15] cifs: build sessions and tcons on the fly Jeff Layton
2010-03-30 19:51 ` [PATCH 13/15] cifs: on multises mount, set ownership to current_fsuid/current_fsgid Jeff Layton
2010-03-30 19:51 ` [PATCH 14/15] cifs: add "multises" mount option Jeff Layton
2010-03-30 19:51 ` [PATCH 15/15] cifs: temporary hack -- set secType to Kerberos Jeff Layton
2010-03-31 12:18 ` [PATCH 00/15] cifs: implement multisession mounts (RFC) Jamie Lokier
2010-03-31 13:42   ` Jeff Layton
2010-03-31 16:43   ` Jeremy Allison

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1269978677-6817-7-git-send-email-jlayton@samba.org \
    --to=jlayton@samba.org \
    --cc=linux-cifs-client@lists.samba.org \
    --cc=linux-fsdevel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).