From: Adrian Bunk <bunk@stusta.de>
To: Telemaque Ndizihiwe <telendiz@eircom.net>
Cc: axboe@suse.de, Ingo.Wilken@informatik.uni-oldenburg.de,
marcelo.tosatti@cyclades.com, torvalds@osdl.org, akpm@osdl.org,
trivial@rustcorp.com.au, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Removes unnecessary if statement from /drivers/block/z2ram.c
Date: Tue, 1 Mar 2005 21:08:58 +0100 [thread overview]
Message-ID: <20050301200858.GE4845@stusta.de> (raw)
In-Reply-To: <Pine.LNX.4.62.0503011907001.5142@localhost.localdomain>
On Tue, Mar 01, 2005 at 07:27:27PM +0000, Telemaque Ndizihiwe wrote:
>
> This Patch removes unnecessary if statement from a function that has no
> implementation (in kernel 2.6.x and 2.4.x); the function returns 0 with
> or without the if statement:
>
> static int z2_release(struct inode *inode, struct file *filp)
> {
> if(current_device==-1)
> return 0;
>
> return 0;
> }
>
>
> Signed-off-by: Telemaque Ndizihiwe <telendiz@eircom.net>
>
>
> --- linux-2.6.10/drivers/block/z2ram.c.orig 2005-02-23
> 18:02:51.011967584 +0000
> +++ linux-2.6.10/drivers/block/z2ram.c 2005-02-23 18:05:31.617551824 +0000
> @@ -304,9 +304,6 @@ err_out:
> static int
> z2_release( struct inode *inode, struct file *filp )
> {
> - if ( current_device == -1 )
> - return 0;
> -
> /*
> * FIXME: unmap memory
> */
For what gain?
The real issue is that this function isn't really implemented.
cu
Adrian
--
"Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
"Only a promise," Lao Er said.
Pearl S. Buck - Dragon Seed
prev parent reply other threads:[~2005-03-01 20:09 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-03-01 19:27 [PATCH] Removes unnecessary if statement from /drivers/block/z2ram.c Telemaque Ndizihiwe
2005-03-01 20:08 ` Adrian Bunk [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=20050301200858.GE4845@stusta.de \
--to=bunk@stusta.de \
--cc=Ingo.Wilken@informatik.uni-oldenburg.de \
--cc=akpm@osdl.org \
--cc=axboe@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=marcelo.tosatti@cyclades.com \
--cc=telendiz@eircom.net \
--cc=torvalds@osdl.org \
--cc=trivial@rustcorp.com.au \
/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