| Age | Commit message (Collapse) | Author |
|
expand_files() cleanup: Make expand_files() common code for
fork.c:fork/copy_files(), open.c:open/get_unused_fd() and
fcntl.c:dup/locate_fd().
expand_files() does both expand_fd_array and expand_fd_set based on the
need. This is used in dup(). open() and fork() duplicates the work of
expand files. At all places we check for expanding fd array, we also check
for expanding fdset. There is no need of checking and calling them
seperately.
This change also moves the expand_files to file.c from fcntl.c, and makes
the expand_fd_array and expand_fd_set local to that file.
Signed-off-by: Prasanna Meda <pmeda@akamai.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
|
|
From: Russell King <rmk@arm.linux.org.uk>
Cleanup the 4 duplicate "get_files_struct" implementations into one
get_files_struct() function to compliment put_files_struct().
|
|
From: Dipankar Sarma <dipankar@in.ibm.com>
fget() shows up on profiles, especially on SMP. Dipankar's patch
special-cases the situation wherein there are no sharers of current->files.
In this situation we know that no other process can close this file, so it
is not necessary to increment the file's refcount.
It's ugly as sin, but makes a substantial difference.
The test is
dd if=/dev/zero of=foo bs=1 count=1M
On 4CPU P3 xeon with 1MB L2 cache and 512MB ram:
kernel sys time std-dev
------------ -------- -------
UP - vanilla 2.104 0.028
UP - file 1.867 0.019
SMP - vanilla 2.976 0.023
SMP - file 2.719 0.026
|
|
Time to write a 2M file, one byte at a time:
Before:
1.09s user 4.92s system 99% cpu 6.014 total
0.74s user 5.28s system 99% cpu 6.023 total
1.03s user 4.97s system 100% cpu 5.991 total
After:
0.79s user 5.17s system 99% cpu 5.993 total
0.79s user 5.17s system 100% cpu 5.957 total
0.84s user 5.11s system 100% cpu 5.942 total
|
|
Patch from Manfred Spraul <manfred@colorfullife.com>
Fixes the lock contention over file_list_lock by simply removing the unneeded
anon_list. So filp allocation does not need to take a global lock any more.
The use of a spinlock to protect files_stat.nr_files is a bit awkward, but
the alternative is a custom sysctl handler, and isn't much more efficient
anyway.
|
|
A minor removal of 6 function definitions from sched.h. They clearly
fit better in file.h. All users of these functions already include file.h.
And none of them included sched.h directly...
|
|
This patch splits fput into fput and __fput. __fput is needed by aio to
construct a mechanism for performing a deferred fput during io
completion, which typically occurs during interrupt context.
|
|
Big bits first, I'll redo the smaller bits tomorrow after some sleep.
Same as last time, rediffed against pre5
|
|
- David Howells: abtract out "current->need_resched" as "need_resched()"
- Frank Davis: ide-tape update for bio
- various: header file fixups
- Jens Axboe: fix up bio/ide/highmem issues
- Kai Germaschewski: ISDN update
- Tim Waugh: parport update
- Patrik Mochel: initcall update
- Greg KH: USB and Compaq PCI hotplug updates
|
|
- Al Viro: fix up silly problem in swapfile filp cleanups in 2.5.2
- Tachino Nobuhiro: fix another error return for swapfile filp code
- Robert Love: merge some of Ingo's scheduler fixes
- David Miller: networking, sparc and some scsi driver fixes
- Tim Waugh: parport update
- OGAWA Hirofumi: fatfs cleanups and bugfixes
- Roland Dreier: fix vsscanf buglets.
- Ben LaHaise: include file cleanup
- Andre Hedrick: IDE taskfile update
|
|
- Jens Axboe: more bio updates, fix some request list bogosity under load
- Al Viro: export seq_xxx functions
- Manfred Spraul: include file cleanups, pc110pad compile fix
- David Woodhouse: fix JFFS2 write error handling
- Dave Jones: start merging up with 2.4.x patches
- Manfred Spraul: coredump fixes, FS event counter cleanups
- me: fix SCSI CD-ROM sectorsize BIO breakage
|
|
|