Skip to contentSkip to conversation

put_last_free() defined, but not used

PATCH In review Coywolf Qi Hunt 6 participants 15 messages Jan 25, 2004 – Mar 3, 2004

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 put_last_free() defined, but not used

Hello,

In 2.0.39, the function put_last_free() in fs/file_table.c is defined, but no longer get used. Should it be removed?

thanks

file_table.c 2004-01-26 03:10:38.000000000 +0800 renamed from file_table.c.orig 1994-10-21 07:39:36.000000000 +0800 +0 -0
@@ -52,20 +52,6 @@
    prev->f_next = next;

}

-/*
- * Insert a file structure at the end of the list of available ones.
- */
-static inline void put_last_free(struct file *file)
-{
- struct file *next, *prev;
-

-    next = first_file;
-    file->f_next = next;
-    prev = next->f_prev;
-    next->f_prev = file;
-    file->f_prev = prev;
-    prev->f_next = file;

-}

/*
* Allocate a new memory page for file structures and

#1 lore raw
Quoted 5 lines · Coywolf Qi Hunt

Hello,

In 2.0.39, the function put_last_free() in fs/file_table.c is defined, but no longer get used.
Should it be removed?

I might consider this for 2.0.41, not for 2.0.40. Indeed it doesn't seem to be used, but it might be used in some external file system.

Regards: David Weinehall

Signature · 3 lines
 /) David Weinehall <[email protected]> /) Northern lights wander      (\
//  Maintainer of the v2.0 kernel   //  Dance across the winter sky //
\)  http://www.acc.umu.se/~tao/    (/   Full colour fire           (/
#2 lore raw
Quoted 9 lines · David Weinehall
Quoted 5 lines · Coywolf Qi Hunt

Hello,

In 2.0.39, the function put_last_free() in fs/file_table.c is defined, but no longer get used.
Should it be removed?

I might consider this for 2.0.41, not for 2.0.40. Indeed it doesn't seem to be used, but it might be used in some external file system.

The function was static.

Signature · 1 line
Jens Axboe
#3 lore raw
Quoted 4 lines · Jens Axboe
Quoted 3 lines · David Weinehall
Quoted 2 lines · Coywolf Qi Hunt

Hello,

Quoted 8 lines
Quoted 6 lines
Quoted 3 lines

In 2.0.39, the function put_last_free() in fs/file_table.c is defined, but no longer get used.
Should it be removed?

I might consider this for 2.0.41, not for 2.0.40. Indeed it doesn't seem to be used, but it might be used in some external file system.

The function was static.

Ohhh, failed to spot that. Bummer, since I just uploaded 2.0.40-rc8. Then again, with the quality my -rc's have been of lately, there will probably be a 2.0.40-rc9 anyway. Sigh.

Regards: David Weinehall

Signature · 3 lines
 /) David Weinehall <[email protected]> /) Northern lights wander      (\
//  Maintainer of the v2.0 kernel   //  Dance across the winter sky //
\)  http://www.acc.umu.se/~tao/    (/   Full colour fire           (/
#4 lore raw

[2.0.40-rc8] Works well

In reply to David Weinehall

Hey David,
I just mail to tell you that 2.0.40-rc8 seems to work really well, no problems compiling (except a few warnings :) and absolutely no problem running. Great work!

Markus

#5 lore raw

Re: [2.0.40-rc8] Works well

Quoted 4 lines · Markus Hästbacka

Hey David,
I just mail to tell you that 2.0.40-rc8 seems to work really well, no problems compiling (except a few warnings :) and absolutely no problem running. Great work!

Most of the compile-time warning I got was from using a newer binutils, but I'll try to fix all warnings (that are fixable without causing bugs) in 2.0.41.

Regards: David Weinehall

Signature · 3 lines
 /) David Weinehall <[email protected]> /) Northern lights wander      (\
//  Maintainer of the v2.0 kernel   //  Dance across the winter sky //
\)  http://www.acc.umu.se/~tao/    (/   Full colour fire           (/
#6 lore raw

Re: [2.0.40-rc8] Works well

In reply to Markus Hästbacka
Quoted 8 lines · Markus Hästbacka

Hey David,
I just mail to tell you that 2.0.40-rc8 seems to work really well, no problems compiling (except a few warnings :) and absolutely no problem running. Great work!

Markus

Hello all 2.0 hackers,

Recently I just have such an idea that is to port the 2.0.39 to let it be compiled with my gcc 2.95.4 or any other latest gcc. At the same time, also make it remain compliant to gcc 2.7.2.1. ( I can't find 2.7.2.1, only 2.7.2.3 on the ftp) Is this work worth while?

Coywolf

#7 lore raw

Re: [2.0.40-rc8] Works well

Quoted 11 lines · Coywolf Qi Hunt
Quoted 8 lines · Markus Hästbacka

Hey David,
I just mail to tell you that 2.0.40-rc8 seems to work really well, no problems compiling (except a few warnings :) and absolutely no problem running. Great work!

Markus

Hello all 2.0 hackers,

There aren't a lot, I suspect you can count us using one hand nowadays...

Quoted 5 lines

Recently I just have such an idea that is to port the 2.0.39 to let it be compiled with my gcc 2.95.4 or any
other latest gcc. At the same time, also make it remain compliant to gcc 2.7.2.1. ( I can't find 2.7.2.1, only 2.7.2.3
on the ftp) Is this work worth while?

Well, for sure it's quite a demanding task, since, if I remember correctly, the module-code uses some nasty internal gcc-knowledge to generate code, that simply doesn't work with later versions of gcc. It might be that I remember this incorrectly though.

It would be interesting, yes, but only if it can be proved to some degree that no new bugs are introduced.

My aim for 2.0.41 is to make it a cleanup-release; remove warnings, tidy up a little source-code mess, kill dead code, fix typos etc.

Regards: David Weinehall

Signature · 3 lines
 /) David Weinehall <[email protected]> /) Northern lights wander      (\
//  Maintainer of the v2.0 kernel   //  Dance across the winter sky //
\)  http://www.acc.umu.se/~tao/    (/   Full colour fire           (/
#8 lore raw

Re: [2.0.40-rc8] Works well

Quoted 8 lines · David Weinehall

On Wed, Jan 28, 2004 at 03:28:30AM +0000, Coywolf Qi Hunt wrote:
...

Quoted 5 lines

Recently I just have such an idea that is to port the 2.0.39 to let it be compiled with my gcc 2.95.4 or any
other latest gcc. At the same time, also make it remain compliant to gcc 2.7.2.1. ( I can't find 2.7.2.1, only 2.7.2.3
on the ftp) Is this work worth while?

Quoted 5 lines

Well, for sure it's quite a demanding task, since, if I remember correctly, the module-code uses some nasty internal gcc-knowledge to generate code, that simply doesn't work with later versions of gcc. It might be that I remember this incorrectly though.

only the module-code? :)

Quoted 3 lines

It would be interesting, yes, but only if it can be proved to some degree that no new bugs are introduced.

That would probably be impossible to do without introducing any bugs..

Quoted 3 lines

My aim for 2.0.41 is to make it a cleanup-release; remove warnings, tidy up a little source-code mess, kill dead code, fix typos etc.

Sounds great, a bit amazing that 2.0 is alive again :)

Markus

#9 lore raw

Re: [2.0.40-rc8] Works well

Quoted 10 lines · Markus Hästbacka
Quoted 8 lines · David Weinehall

On Wed, Jan 28, 2004 at 03:28:30AM +0000, Coywolf Qi Hunt wrote:
...

Quoted 5 lines

Recently I just have such an idea that is to port the 2.0.39 to let it be compiled with my gcc 2.95.4 or any
other latest gcc. At the same time, also make it remain compliant to gcc 2.7.2.1. ( I can't find 2.7.2.1, only 2.7.2.3
on the ftp) Is this work worth while?

Quoted 6 lines
Quoted 5 lines

Well, for sure it's quite a demanding task, since, if I remember correctly, the module-code uses some nasty internal gcc-knowledge to generate code, that simply doesn't work with later versions of gcc. It might be that I remember this incorrectly though.

only the module-code? :)

Well, I do remember that I did spend a few weeks getting the 2.0-tree to compile with gcc-3.2, and most problems arose when dealing with the module-code. I think I gave up there.

Quoted 4 lines
Quoted 3 lines

It would be interesting, yes, but only if it can be proved to some degree that no new bugs are introduced.

That would probably be impossible to do without introducing any bugs..

Mmmm.

Quoted 4 lines
Quoted 3 lines

My aim for 2.0.41 is to make it a cleanup-release; remove warnings, tidy up a little source-code mess, kill dead code, fix typos etc.

Sounds great, a bit amazing that 2.0 is alive again :)

Oh, it's not been dead, as much as laying dormant.

Regards: David

Signature · 3 lines
 /) David Weinehall <[email protected]> /) Northern lights wander      (\
//  Maintainer of the v2.0 kernel   //  Dance across the winter sky //
\)  http://www.acc.umu.se/~tao/    (/   Full colour fire           (/
#10 lore raw

Re: [2.0.40-rc8] Works well

Btw - Are you going to announce the release of 2.0.40 (whenever it's coming) or just put it on kernel.org?

Markus

#11 lore raw

Re: [2.0.40-rc8] Works well

Quoted 2 lines · Markus Hästbacka

Btw - Are you going to announce the release of 2.0.40 (whenever it's coming) or just put it on kernel.org?

I will announce it. It won't have any differences from 2.0.40-rc8 though (unless someone uncovers a flaw in -rc8 of course, which would cause me to release an -rc9.)

Regards: David Weinehall

Signature · 3 lines
 /) David Weinehall <[email protected]> /) Northern lights wander      (\
//  Maintainer of the v2.0 kernel   //  Dance across the winter sky //
\)  http://www.acc.umu.se/~tao/    (/   Full colour fire           (/
#12 lore raw

about 2.0 cleanup or adaption

In reply to David Weinehall
Quoted 11 lines · David Weinehall
Quoted 3 lines · Coywolf Qi Hunt

Recently I just have such an idea that is to port the 2.0.39 to let it be compiled with my gcc 2.95.4 or any other latest gcc. At the same time, also make it remain compliant to gcc 2.7.2.1. ( I can't find 2.7.2.1, only 2.7.2.3 on the ftp) Is this work worth while?

Well, for sure it's quite a demanding task, since, if I remember correctly, the module-code uses some nasty internal gcc-knowledge to generate code, that simply doesn't work with later versions of gcc. It might be that I remember this incorrectly though.

I think the first problem is to adapt the some inline assembly code to new style for the strict clobber list issue in recent gcc. If it is worthwhile, I'd like to do the work.

Quoted 9 lines

It would be interesting, yes, but only if it can be proved to some degree that no new bugs are introduced.

My aim for 2.0.41 is to make it a cleanup-release; remove warnings, tidy up a little source-code mess, kill dead code, fix typos etc.

Regards: David Weinehall

I'm not sure of the defined but never used code. There's a lot. How to deal with them?

Coywolf

Signature · 2 lines
Coywolf Qi Hunt
Admin of http://GreatCN.org and http://LoveCN.org
#13 lore raw

PATCH 1/1 Fix comment error of prepare_binprm() in exec.c

In reply to David Weinehall
Quoted 5 lines · David Weinehall

My aim for 2.0.41 is to make it a cleanup-release; remove warnings, tidy up a little source-code mess, kill dead code, fix typos etc.

Regards: David Weinehall

Hello, David

In the comment of prepare_binprm() in fs/exec.c, 512 bytes should be 128 bytes.

Coywolf

Signature · 2 lines
Coywolf Qi Hunt
Admin of http://GreatCN.org and http://LoveCN.org
fs/exec.c +1 -1
@@ -528,7 +528,7 @@
 
 /* 
  * Fill the binprm structure from the inode. 
- * Check permissions, then read the first 512 bytes
+ * Check permissions, then read the first 128 bytes
  */
 int prepare_binprm(struct linux_binprm *bprm)
 {
#14 lore raw

Re: [PATCH 2.0.40] Fix comment error of prepare_binprm() in exec.c

Quoted 6 lines · Coywolf Qi Hunt
Quoted 4 lines · David Weinehall

My aim for 2.0.41 is to make it a cleanup-release; remove warnings, tidy up a little source-code mess, kill dead code, fix typos etc.

Quoted 6 lines
Quoted 1 line

Regards: David Weinehall

Hello, David

In the comment of prepare_binprm() in fs/exec.c, 512 bytes should be 128 bytes.

Thanks.

Regards: David Weinehall

Signature · 3 lines
 /) David Weinehall <[email protected]> /) Northern lights wander      (\
//  Maintainer of the v2.0 kernel   //  Dance across the winter sky //
\)  http://www.acc.umu.se/~tao/    (/   Full colour fire           (/