public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@osdl.org>
To: Kirill Korotaev <dev@sw.ru>
Cc: linux-kernel@vger.kernel.org, torvalds@osdl.org
Subject: Re: [PATCH] replace hack with dget/mntget usage in fs/dcookies.c
Date: Thu, 1 Sep 2005 01:38:36 -0700	[thread overview]
Message-ID: <20050901013836.731e63e1.akpm@osdl.org> (raw)
In-Reply-To: <4316B61B.9070305@sw.ru>

Kirill Korotaev <dev@sw.ru> wrote:
>
> This patch replaces manual incrementing of refcounters on dentry/mnt in 
>  fs/dcookie.c with calls to dget()/mntget().
>
> ...
>
>  --- linux-2.6.8.1-t032/fs/dcookies.c.dget	2004-08-14 14:54:46.000000000 +0400
>  +++ linux-2.6.8.1-t032/fs/dcookies.c	2005-08-23 14:09:00.000000000 +0400

Whoa.  Medieval kernel.

>  @@ -93,12 +93,10 @@ static struct dcookie_struct * alloc_dco
>   	if (!dcs)
>   		return NULL;
>   
>  -	atomic_inc(&dentry->d_count);
>  -	atomic_inc(&vfsmnt->mnt_count);
>   	dentry->d_cookie = dcs;
>   
>  -	dcs->dentry = dentry;
>  -	dcs->vfsmnt = vfsmnt;
>  +	dcs->dentry = dget(dentry);
>  +	dcs->vfsmnt = mntget(vfsmnt);
>   	hash_dcookie(dcs);
>   
>   	return dcs;

That's already there.

      reply	other threads:[~2005-09-01  8:40 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-09-01  8:04 [PATCH] replace hack with dget/mntget usage in fs/dcookies.c Kirill Korotaev
2005-09-01  8:38 ` Andrew Morton [this message]

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=20050901013836.731e63e1.akpm@osdl.org \
    --to=akpm@osdl.org \
    --cc=dev@sw.ru \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@osdl.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