]> git.hungrycats.org Git - linux/log
linux
23 years agoLinux v2.5.25 v2.5.25
Linus Torvalds [Fri, 5 Jul 2002 09:29:59 +0000 (02:29 -0700)]
Linux v2.5.25

23 years ago[PATCH] drivers/ide/probe.c leaks memory
Petr Vandrovec [Fri, 5 Jul 2002 09:27:11 +0000 (02:27 -0700)]
[PATCH] drivers/ide/probe.c leaks memory

  drivers/ide/probe.c initializes gd->de_arr and gd->flags twice. Except that
it is unnecessary it also leaks memory.

23 years ago[PATCH] Fix note sections in ELF core dumps
Mark Kettenis [Fri, 5 Jul 2002 09:26:57 +0000 (02:26 -0700)]
[PATCH] Fix note sections in ELF core dumps

Edition 4.1 of the System V Application Binary Interface says that
"The first namesz bytes in name contains a null-terminated
representation of the entry's owner or originator".  This implies that
the terminating null is included in namesz, which is corroborated by
the example that follows the description.  However, this is not what
the Linux kernel does when it writes its notes into an ELF core dump.
The attached patch fixes this.

23 years agoDisable ReiserFS bh usage count testing for now.
Linus Torvalds [Fri, 5 Jul 2002 09:13:45 +0000 (02:13 -0700)]
Disable ReiserFS bh usage count testing for now.

HACK ALERT! This needs to be fixed to do what reiserfs
actually thinks it _should_ do.

23 years agox86 "make clean" missed some new targets
Linus Torvalds [Fri, 5 Jul 2002 09:12:24 +0000 (02:12 -0700)]
x86 "make clean" missed some new targets

23 years agoUSB: bluetty.c allocation bug fix
Orjan Friberg [Fri, 5 Jul 2002 07:38:16 +0000 (00:38 -0700)]
USB: bluetty.c allocation bug fix

In usb_bluetooth_probe, the transfer buffers for the write pool urbs
are allocated with size 0, because bluetooth->bulk_out_buffer_size isn't set
until after the loop.

23 years agoUSB: Fixups due to the changes in struct usb_device for file_operations and minor...
Greg Kroah-Hartman [Fri, 5 Jul 2002 07:33:17 +0000 (00:33 -0700)]
USB: Fixups due to the changes in struct usb_device for file_operations and minor number handling

23 years agoUSB: added drivers/usb/core/file.c to the kernel-api documentation
Greg Kroah-Hartman [Fri, 5 Jul 2002 07:31:37 +0000 (00:31 -0700)]
USB: added drivers/usb/core/file.c to the kernel-api documentation

23 years agoUSB: removed file ops from usb device structure
Greg Kroah-Hartman [Fri, 5 Jul 2002 07:30:41 +0000 (00:30 -0700)]
USB: removed file ops from usb device structure
Moved the file ops and minor number stuff out of the usb structure,
Now usb_register_dev() and usb_deregister_dev() must be called if
you want to use the USB major number.

23 years agoMerge kroah.com:/home/linux/linux/BK/bleeding-2.5
Greg Kroah-Hartman [Fri, 5 Jul 2002 06:18:51 +0000 (23:18 -0700)]
Merge kroah.com:/home/linux/linux/BK/bleeding-2.5
into kroah.com:/home/linux/linux/BK/gregkh-2.5

23 years agoMerge
Linus Torvalds [Fri, 5 Jul 2002 04:15:28 +0000 (21:15 -0700)]
Merge

23 years ago[PATCH] Shift BKL into ->statfs()
Paul Menage [Fri, 5 Jul 2002 04:11:23 +0000 (21:11 -0700)]
[PATCH] Shift BKL into ->statfs()

This patch removes BKL protection from the invocation of the
super_operations ->statfs() method, and shifts it into the filesystems
where necessary. Any out-of-tree filesystems may need to take the BKL in
their statfs() methods if they were relying on it for synchronisation.

All ->statfs() implementations have been modified to take the BKL,
except for those that don't reference any external mutable data or that
already have their own locking.

Additionally, capifs is changed to use simple_statfs rather than its
own home-grown version.

The BKL change has been flagged at the end of
Documentation/filesystems/porting, along with the recent change to
->permission BKL usage.

23 years agoMerge http://linux-ntfs.bkbits.net/ntfs-tng-2.5
Linus Torvalds [Fri, 5 Jul 2002 04:10:21 +0000 (21:10 -0700)]
Merge http://linux-ntfs.bkbits.net/ntfs-tng-2.5
into home.transmeta.com:/home/torvalds/v2.5/linux

23 years agoMerge bk://linux-input.bkbits.net/linux-input
Linus Torvalds [Fri, 5 Jul 2002 04:05:52 +0000 (21:05 -0700)]
Merge bk://linux-input.bkbits.net/linux-input
into home.transmeta.com:/home/torvalds/v2.5/linux

23 years agoMerge linux-isdn@linux-isdn.bkbits.net:linux-2.5.make
Kai Germaschewski [Fri, 5 Jul 2002 01:47:03 +0000 (20:47 -0500)]
Merge linux-isdn@linux-isdn.bkbits.net:linux-2.5.make
into tp1.ruhr-uni-bochum.de:/home/kai/kernel/v2.5/linux-2.5.make

23 years ago[PATCH] pegasus & rtl8150
Petko Manolov [Thu, 4 Jul 2002 16:46:47 +0000 (09:46 -0700)]
[PATCH] pegasus & rtl8150

I chose a little bit more restrictive license for my drivers.
Rx skb pool introduced in pegasus driver and the pool locking in rtl8150
is refined.

23 years agoMerge home.transmeta.com:/home/torvalds/v2.5/viro
Linus Torvalds [Thu, 4 Jul 2002 15:54:40 +0000 (08:54 -0700)]
Merge home.transmeta.com:/home/torvalds/v2.5/viro
into home.transmeta.com:/home/torvalds/v2.5/linux

23 years ago[PATCH] ->i_dev switched to dev_t
Alexander Viro [Thu, 4 Jul 2002 15:54:08 +0000 (08:54 -0700)]
[PATCH] ->i_dev switched to dev_t

* ->i_dev followed the example of ->s_dev - it's dev_t now.  All
remaining uses of ->i_dev either outright want dev_t (stat()) or couldn't
care less (printing major:minor in /proc/<pid>/maps, etc.)

23 years ago[PATCH] assorted kdev_t cleanups in filesystems
Alexander Viro [Thu, 4 Jul 2002 15:54:03 +0000 (08:54 -0700)]
[PATCH] assorted kdev_t cleanups in filesystems

* JFS uses its ->logdev only twice - one of the places assigns
it to_kdev_t(le32_to_cpu(...)), another uses kdev_t_to_nr() of it.
Switched to u32 - it's just a place where we store device number we'd got
from superblock.
* several reiserfs_fs.h function prototypes removed - functions
in question don't exist anymore.
* smbfs doesn't support device nodes; ->f_rdev removed.

23 years ago[PATCH] ex_dev switched to dev_t
Alexander Viro [Thu, 4 Jul 2002 15:53:58 +0000 (08:53 -0700)]
[PATCH] ex_dev switched to dev_t

* svc_export ->ex_dev turned into dev_t.  It's a pure search
key and all places that set it actually do to_kdev_t(some_dev_t_expression).

23 years ago[PATCH] raid kdev_t cleanups - part 3
Alexander Viro [Thu, 4 Jul 2002 15:53:54 +0000 (08:53 -0700)]
[PATCH] raid kdev_t cleanups - part 3

* ->dev killed for md/linear.c (same as previous parts)

23 years ago[PATCH] md_import_device() cleanup
Alexander Viro [Thu, 4 Jul 2002 15:53:49 +0000 (08:53 -0700)]
[PATCH] md_import_device() cleanup

* md_import_device() returns resulting rdev or ERR_PTR(error)
instead of returning 0 or error an letting caller find rdev.

23 years ago[PATCH] raid kdev_t cleanups - part 2
Alexander Viro [Thu, 4 Jul 2002 15:53:44 +0000 (08:53 -0700)]
[PATCH] raid kdev_t cleanups - part 2

* a bunch of callers of partition_name() are calling
bdev_partition_name(),
* the last users of raid1 and multipath ->dev are gone; so are
the fields in question.

23 years ago[PATCH] raid ->diskop() splitup
Alexander Viro [Thu, 4 Jul 2002 15:53:39 +0000 (08:53 -0700)]
[PATCH] raid ->diskop() splitup

* ->diskop() split into individual methods; prototypes cleaned
up.  In particular, handling of hot_add_disk() gets mdk_rdev_t * of
the component we are adding as an argument instead of playing the games
with major/minor.  Code cleaned up.

23 years ago[PATCH] raid kdev_t cleanups (part 1)
Alexander Viro [Thu, 4 Jul 2002 15:53:33 +0000 (08:53 -0700)]
[PATCH] raid kdev_t cleanups (part 1)

* ->error_handler() switched to struct block_device *.
* md_sync_acct() switched to struct block_device *.
* raid5 struct disk_info ->dev is gone - we use ->bdev everywhere.
* bunch of kdev_same() when we have corresponding struct block_device *
and can simply compare them is removed from drivers/md/*.c

23 years ago[PATCH] kdev_t crapectomy
Alexander Viro [Thu, 4 Jul 2002 15:53:28 +0000 (08:53 -0700)]
[PATCH] kdev_t crapectomy

* since the last caller of is_read_only() is gone, the function
itself is removed.
* destroy_buffers() is not used anymore; gone.
* fsync_dev() is gone; the only user is (broken) lvm.c and first
step in fixing lvm.c will consist of propagating struct block_device *
anyway; at that point we'll just use fsync_bdev() in there.
* prototype of bio_ioctl() removed - function doesn't exist
anymore.

23 years ago[PATCH] cdrom.c cleanups
Alexander Viro [Thu, 4 Jul 2002 15:53:22 +0000 (08:53 -0700)]
[PATCH] cdrom.c cleanups

* Bunch of functions in cdrom.c used to get kdev_t and use it
only to do cdrom_find_device(dev), even though their callers already
had struct cdrom_device_info * in question.  Switched to passing
said pointer directly.
* useless exports removed; stuff not used outside of cdrom.c
made static.

23 years ago[PATCH] (md.c) block device size cleanups
Alexander Viro [Thu, 4 Jul 2002 15:53:17 +0000 (08:53 -0700)]
[PATCH] (md.c) block device size cleanups

* calc_dev_sboffset() and calc_dev_size() in md.c are getting
mk_rdev_t instead of kdev_t.  Callers updated.
* calls of blkdev_size_in_bytes() in md.c replaced with use
of rdev->bdev->bd_inode->i_size.

23 years ago[PATCH] devpts cleanup
Alexander Viro [Thu, 4 Jul 2002 15:53:12 +0000 (08:53 -0700)]
[PATCH] devpts cleanup

* devpts "upcalls" eliminated.
* instead of playing games with revalidation we simply use
ramfs-style tree and kill dentries upon devpts_pty_kill().  That
allows to get rid of a lot of code in fs/devpts/*.c.
* devpts_fs.h cleaned up.
* devpts/root.c and devpts/devpts_i.h removed.
* array of pointers to devpts inodes killed; with ramfs-style tree
it's not needed anymore.
* devpts/inode.c cleaned up.
* devpts_pty_new() used to get mk_kdev() only to convert it to
dev_t (hardly a surprise, since it's mknod() in disguise).  Now it gets
dev_t as an argument.

23 years agoMerge home.transmeta.com:/home/torvalds/v2.5/akpm
Linus Torvalds [Thu, 4 Jul 2002 15:33:28 +0000 (08:33 -0700)]
Merge home.transmeta.com:/home/torvalds/v2.5/akpm
into home.transmeta.com:/home/torvalds/v2.5/linux

23 years ago[PATCH] Use names, not numbers for pagefault types
Andrew Morton [Thu, 4 Jul 2002 15:32:11 +0000 (08:32 -0700)]
[PATCH] Use names, not numbers for pagefault types

This is Bill Irwin's cleanup patch which gives symbolic names to the
fault types:

#define VM_FAULT_OOM (-1)
#define VM_FAULT_SIGBUS 0
#define VM_FAULT_MINOR 1
#define VM_FAULT_MAJOR 2

Only arch/i386 has been updated - other architectures can do this too.

23 years ago[PATCH] reduce lock contention in try_to_free_buffers()
Andrew Morton [Thu, 4 Jul 2002 15:32:06 +0000 (08:32 -0700)]
[PATCH] reduce lock contention in try_to_free_buffers()

The blockdev mapping's private_lock is fairly contended.  The buffer
LRU cache fixed a lot of that, but under page replacement load,
try_to_free_buffers is still showing up.

Moving the freeing of buffer_heads outside the lock reduces contention
in there by 30%.

23 years ago[PATCH] debug: check page refcount in __free_pages_ok()
Andrew Morton [Thu, 4 Jul 2002 15:32:00 +0000 (08:32 -0700)]
[PATCH] debug: check page refcount in __free_pages_ok()

Add a BUG() check to __free_pages_ok() - to catch someone freeing a
page which has a non-zero refcount.  Actually, this check is mainly to
catch someone (ie: shrink_cache()) incrementing a page's refcount
shortly after it has been freed

Also clean up __free_pages_ok() a bit and convert lots of BUGs to BUG_ON.

23 years ago[PATCH] fix invalidate_inode_pages2() race
Andrew Morton [Thu, 4 Jul 2002 15:31:56 +0000 (08:31 -0700)]
[PATCH] fix invalidate_inode_pages2() race

Fix a buglet in invalidate_list_pages2(): there is a small window in
which writeback could start against the page before this function locks
it.

The patch closes the race by performing the PageWriteback test inside
PageLocked.

Testing PageWriteback inside PageLocked is "definitive" - when a page
is locked, writeback cannot start against it.

23 years ago[PATCH] JBD commit callback capability
Andrew Morton [Thu, 4 Jul 2002 15:31:50 +0000 (08:31 -0700)]
[PATCH] JBD commit callback capability

This is a patch which Stephen has applied to ext3's 2.4 repository.
Originally written by Andreas, generalised somewhat by Stephen.

Add jbd callback mechanism, requested for InterMezzo.  We allow the jbd's
client to request notification when a given handle's IO finally commits to
disk, so that clients can manage their own writeback state asynchronously.

23 years ago[PATCH] ext3 truncate fix
Andrew Morton [Thu, 4 Jul 2002 15:31:45 +0000 (08:31 -0700)]
[PATCH] ext3 truncate fix

Forward-port of a fix which Stephen has applied to ext3's 2.4 CVS tree.

Fix for a rare problem seen under stress in data=journal mode: if we
have to restart a truncate transaction while traversing the inode's
direct blocks, we need to deal with bh==NULL in ext3_clear_blocks.

23 years ago[PATCH] combine generic_writepages() and mpage_writepages()
Andrew Morton [Thu, 4 Jul 2002 15:31:40 +0000 (08:31 -0700)]
[PATCH] combine generic_writepages() and mpage_writepages()

generic_writepages and mpage_writepages are basically identical,
except one calls ->writepage() and the other calls mpage_writepage().
This duplication is irritating.

The patch folds generic_writepage() into mpage_writepages().  It does
this rather kludgily: if the get_block argument to mpage_writepages()
is NULL then use ->writepage().

Can't think of a better way, really - we could go for a fully-blown
write_actor_t thing, but that would be overly elaborate and would not
allow mpage_writepage() to be inlined inside mpage_writepages(), which
is rather desirable.

23 years ago[PATCH] fix a writeback race
Andrew Morton [Thu, 4 Jul 2002 15:31:36 +0000 (08:31 -0700)]
[PATCH] fix a writeback race

Fixes a bug in generic_writepages() and its cut-n-paste-cousin,
mpage_writepages().

The code was clearing PageDirty and then baling out if it discovered
the page was nder writeback.  Which would cause the dirty bit to be
lost.

It's a very small window, but reversing the order so PageDirty is only
cleared when we know for-sure that IO will be started fixes it up.

23 years ago[PATCH] suppress more allocation failure warnings
Andrew Morton [Thu, 4 Jul 2002 15:31:30 +0000 (08:31 -0700)]
[PATCH] suppress more allocation failure warnings

The `page allocation failure' warning in __alloc_pages() is being a
pain.  But I'm persisting with it...

The patch renames PF_RADIX_TREE to PF_NOWARN, and uses it in a few
places where allocations failures are known to happen.  These code
paths are well-tested now and suppressing the warning is OK.

23 years ago[PATCH] always update page->flags atomically
Andrew Morton [Thu, 4 Jul 2002 15:31:25 +0000 (08:31 -0700)]
[PATCH] always update page->flags atomically

move_from_swap_cache() and move_to_swap_cache() are playing with
page->flags nonatomically.  The page is on the LRU at the time and
another CPU could be altering page->flags concurrently.

The patch converts those functions to use atomic operations.

It also rationalises the number of bits which are cleared.  It's not
really clear to me what page flags we really want to set to a known
state in there.

It had no right to go clearing PG_arch_1.  I'm now clearing PG_arch_1
inside rmqueue() which is still a bit presumptious.

btw: shmem uses PAGE_CACHE_SIZE and swapper_space uses PAGE_SIZE.  I've
been carefully maintaining the distinction, but it looks like shmem
will break if we ever do make these values different.

Also, __add_to_page_cache() was performing a non-atomic RMW against
page->flags, under the assumption that it was a newly allocated page
which no other CPU would look at.  Not true - this function is used for
moving anon pages into swapcache.  Those anon pages are on the LRU -
other CPUs can be performing operations against page->flags while
__add_to_swap_cache is stomping on them.  This had me running around in
circles for two days.

So let's move the initialisation of the page state into rmqueue(),
where the page really is new (could do it in page_cache_alloc,
perhaps).

The SetPageLocked() in __add_to_page_cache() is also rather curious.
Seems OK for both pagecache and swapcache so I covered that with a
comment.

2.4 has the same problem.  Basically, add_to_swap_cache() can stomp on
another CPU's manipulation of page->flags.  After a quick review of the
code there, it is barely conceivable that a concurrent refill_inactve()
could get its PG_referenced and PG_active bits scribbled on.  Rather
unlikely because swap_out() will probably see PageActive() and bale
out.

Also, mark_dirty_kiobuf() could have its PG_dirty bit accidentally
cleared (but try_to_swap_out() sets it again later).

But there may be other code paths.  Really, I think this needs fixing
in 2.4 - it's horrid.

23 years ago[PATCH] Use __GFP_HIGH in mpage_writepages()
Andrew Morton [Thu, 4 Jul 2002 15:31:20 +0000 (08:31 -0700)]
[PATCH] Use __GFP_HIGH in mpage_writepages()

In mpage_writepage(), use __GFP_HIGH when allocating the BIO: writeback
is a memory reclaim function and is entitle to dip into the page
reserves to get its IO underway.

23 years ago[PATCH] resurrect __GFP_HIGH
Andrew Morton [Thu, 4 Jul 2002 15:31:15 +0000 (08:31 -0700)]
[PATCH] resurrect __GFP_HIGH

This patch reinstates __GFP_HIGH functionality.

__GFP_HIGH means "able to dip into the emergency pools".  However,
somewhere along the line this got broken.  __GFP_HIGH ceased to do
anything.  Instead, !__GFP_WAIT is used to tell the page allocator to
try harder.

__GFP_HIGH makes sense.  The concepts of "unable to sleep" and "should
try harder" are quite separate, and overloading !__GFP_WAIT to mean
"should access emergency pools" seems wrong.

This patch fixes a problem in mempool_alloc().  mempool_alloc() tries
the first allocation with __GFP_WAIT cleared.  If that fails, it tries
again with __GFP_WAIT enabled (if the caller can support __GFP_WAIT).
So it is currently performing an atomic allocation first, even though
the caller said that they're prepared to go in and call the page
stealer.

I thought this was a mempool bug, but Ingo said:

> no, it's not GFP_ATOMIC. The important difference is __GFP_HIGH, which
> triggers the intrusive highprio allocation mode. Otherwise gfp_nowait is
> just a nonblocking allocation of the same type as the original gfp_mask.
> ...
> what i've added is a bit more subtle allocation method, with both
> performance and balancing-correctness in mind:
>
> 1. allocate via gfp_mask, but nonblocking
> 2. if failure => try to get from the pool if the pool is 'full enough'.
> 3. if failure => allocate with gfp_mask [which might block]
>
> there is performance data that this method improves bounce-IO performance
> significantly, because even under VM pressure (when gfp_mask would block)
> we can still use up to 50% of the memory pool without blocking (and
> without endangering deadlock-free allocation). Ie. the memory pool is also
> a fast 'frontside cache' of memory elements.

Ingo was assuming that __GFP_HIGH was still functional.  It isn't, and the
mempool design wants it.

23 years ago[PATCH] set_page_dirty() in mark_dirty_kiobuf()
Andrew Morton [Thu, 4 Jul 2002 15:31:10 +0000 (08:31 -0700)]
[PATCH] set_page_dirty() in mark_dirty_kiobuf()

Yet another SetPageDirty/set_page_dirty bugfix: mark_dirty_kiobuf needs
to run set_page_dirty() so the page goes onto its mapping's dirty_pages
list.

23 years ago[PATCH] check for O_DIRECT capability in open(), not write()
Andrew Morton [Thu, 4 Jul 2002 15:31:05 +0000 (08:31 -0700)]
[PATCH] check for O_DIRECT capability in open(), not write()

For O_DIRECT opens we're currently checking that the fs supports
O_DIRECT at write(2)-time.

This is a forward-port of Andrea's patch which moves the check to
open() time.  Seems more sensible.

23 years ago[PATCH] set TASK_RUNNING in yield()
Andrew Morton [Thu, 4 Jul 2002 15:31:00 +0000 (08:31 -0700)]
[PATCH] set TASK_RUNNING in yield()

It seems that the yield() macro requires state TASK_RUNNING, but
practically none of the callers remember to do that.

The patch turns yield() into a real function which sets state
TASK_RUNNING before scheduling.

23 years ago[PATCH] set TASK_RUNNING in cond_resched()
Andrew Morton [Thu, 4 Jul 2002 15:30:54 +0000 (08:30 -0700)]
[PATCH] set TASK_RUNNING in cond_resched()

do_select() does set_current_state(TASK_INTERRUPTIBLE) then calls
__pollwait() which calls __get_free_page() and the cond_resched() which
I added to the pagecache reclaim code never returns.

The patch makes cond_resched() more useful by setting current->state to
TASK_RUNNING before scheduling.

23 years ago[PATCH] add new list_splice_init()
Andrew Morton [Thu, 4 Jul 2002 15:30:49 +0000 (08:30 -0700)]
[PATCH] add new list_splice_init()

A little cleanup: Most callers of list_splice() immediately
reinitialise the source list_head after calling list_splice().

So create a new list_splice_init() which does all that.

23 years ago[PATCH] shmem fixes
Andrew Morton [Thu, 4 Jul 2002 15:30:44 +0000 (08:30 -0700)]
[PATCH] shmem fixes

A shmem cleanup/bugfix patch from Hugh Dickins.

- Minor: in try_to_unuse(), only wait on writeout if we actually
  started new writeout.  Otherwise, there is no need because a
  wait_on_page_writeback() has already been executed against this page.
  And it's locked, so no new writeback can start.

- Minor: in shmem_unuse_inode(): remove all the
  wait_on_page_writeback() logic.  We already did that in
  try_to_unuse(), adn the page is locked so no new writeback can start.

- Less minor: add a missing a page_cache_release() to
  shmem_get_page_locked() in the uncommon case where the page was found
  to be under writeout.

23 years ago[PATCH] remove swap_get_block()
Andrew Morton [Thu, 4 Jul 2002 15:30:39 +0000 (08:30 -0700)]
[PATCH] remove swap_get_block()

Patch from Christoph Hellwig removes swap_get_block().

I was sort-of hanging onto this function because it is a standard
get_block function, and maybe perhaps it could be used to make swap use
the regular filesystem I/O functions.  We don't want to do that, so
kill it.

23 years ago[PATCH] pdflush cleanup
Andrew Morton [Thu, 4 Jul 2002 15:30:34 +0000 (08:30 -0700)]
[PATCH] pdflush cleanup

Writeback/pdflush cleanup patch from Steven Augart

* Exposes nr_pdflush_threads as /proc/sys/vm/nr_pdflush_threads, read-only.

  (I like this - I expect that management of the pdflush thread pool
  will be important for many-spindle machines, and this is a neat way
  of getting at the info).

* Adds minimum and maximum checking to the five writable pdflush
  and fs-writeback  parameters.

* Minor indentation fix in sysctl.c

* mm/pdflush.c now includes linux/writeback.h, which prototypes
  pdflush_operation.  This is so that the compiler can
  automatically check that the prototype matches the definition.

* Adds a few comments to existing code.

23 years ago[PATCH] misc cleanups and fixes
Andrew Morton [Thu, 4 Jul 2002 15:30:30 +0000 (08:30 -0700)]
[PATCH] misc cleanups and fixes

- Comment and documentation fixlets

- Remove some unneeded fields from swapper_inode (these are a
  leftover from when I had swap using the filesystem IO functions).

- fix a printk bug in pci/pool.c: when dma_addr_t is 64 bit it
  generates a compile warning, and will print out garbage.  Cast it to
  unsigned long long.

- Convert some writeback #defines into enums (Steven Augart)

23 years ago[PATCH] debug check for leaked blockdev buffers
Andrew Morton [Thu, 4 Jul 2002 15:30:25 +0000 (08:30 -0700)]
[PATCH] debug check for leaked blockdev buffers

Having just fiddled with the refcounts of blockdev buffers, I want some
way of assuring that the code is correct and is not leaking
buffer_heads.

There's no easy way to do this: if a blockdev page has pinned buffers
then truncate_complete_page just cuts it loose and we leak memory.

The patch adds a bit of debug code to catch these leaks.  This code,
PF_RADIX_TREE and buffer_error() need to be removed later on.

23 years ago[PATCH] Remove ext3's buffer_head cache
Andrew Morton [Thu, 4 Jul 2002 15:30:20 +0000 (08:30 -0700)]
[PATCH] Remove ext3's buffer_head cache

Removes ext3's open-coded inode and allocation bitmap LRUs.

This patch includes a cleanup to ext3_new_block().  The local variables
`bh', `bh2', `i', `j', `k' and `tmp' have been renamed to something
more palatable.

23 years ago[PATCH] Remove ext2's buffer_head cache
Andrew Morton [Thu, 4 Jul 2002 15:30:15 +0000 (08:30 -0700)]
[PATCH] Remove ext2's buffer_head cache

Remove ext2's open-coded bitmap LRUs.  Core kernel does this for it now.

23 years ago[PATCH] per-cpu buffer_head cache
Andrew Morton [Thu, 4 Jul 2002 15:30:10 +0000 (08:30 -0700)]
[PATCH] per-cpu buffer_head cache

ext2 and ext3 implement a custom LRU cache of buffer_heads - the eight
most-recently-used inode bitmap buffers and the eight MRU block bitmap
buffers.

I don't like them, for a number of reasons:

- The code is duplicated between filesystems

- The functionality is unavailable to other filesystems

- The LRU only applies to bitmap buffers.  And not, say, indirects.

- The LRUs are subtly dependent upon lock_super() for protection:
  without lock_super protection a bitmap could be evicted and freed
  while in use.

  And removing this dependence on lock_super() gets us one step on
  the way toward getting that semaphore out of the ext2 block allocator -
  it causes significant contention under some loads and should be a
  spinlock.

- The LRUs pin 64 kbytes per mounted filesystem.

Now, we could just delete those LRUs and rely on the VM to manage the
memory.  But that would introduce significant lock contention in
__find_get_block - the blockdev mapping's private_lock and page_lock
are heavily used.

So this patch introduces a transparent per-CPU bh lru which is hidden
inside __find_get_block(), __getblk() and __bread().  It is designed to
shorten code paths and to reduce lock contention.  It uses a seven-slot
LRU.  It achieves a 99% hit rate in `dbench 64'.  It provides benefit
to all filesystems.

The next patches remove the open-coded LRUs from ext2 and ext3.

Taken together, these patches are a code cleanup (300-400 lines gone),
and they reduce lock contention.  Anton tested these patches on the
32-way and demonstrated a throughput improvement of up to 15% on
RAM-only dbench runs.  See http://samba.org/~anton/linux/2.5.24/dbench/

Most of this benefit is from avoiding find_get_page() on the blockdev
mapping.  Because the generic LRU copes with indirect blocks as well as
bitmaps.

23 years ago[PATCH] Fix 3c59x driver for some 3c566B's
Andrew Morton [Thu, 4 Jul 2002 15:30:04 +0000 (08:30 -0700)]
[PATCH] Fix 3c59x driver for some 3c566B's

Fix from Rahul Karnik and Donald Becker - some new 3c566B mini-PCI NICs
refuse to power up the transceiver unless we tickle an undocumented bit
in an undocumented register.  They worked this out by before-and-after
diffing of the register contents when it was set up by the Windows
driver.

23 years ago[PATCH] handle BIO allocation failures in swap_writepage()
Andrew Morton [Thu, 4 Jul 2002 15:29:59 +0000 (08:29 -0700)]
[PATCH] handle BIO allocation failures in swap_writepage()

If allocation of a BIO for swap writeout fails, mark the page dirty
again to save it from eviction.

23 years agokbuild: Fix warnings and other buglets
Kai Germaschewski [Thu, 4 Jul 2002 13:32:25 +0000 (15:32 +0200)]
kbuild: Fix warnings and other buglets

o Add a + to $(MAKEBOOT), so that make knows that it's a recursive make
  invocation.
o For files which are generated like .map -> .c -> .o,
  add an explicit dependency for .c -> .o.
  Otherwise, make sees the .c as an intermediate object and removes it,
  causing an unnecessary recompilation at next invocation.

23 years agoMerge chaos.tp1.ruhr-uni-bochum.de:/Home/kai/linux/kernel/v2.5/linux-2.5
Kai Germaschewski [Thu, 4 Jul 2002 13:16:10 +0000 (15:16 +0200)]
Merge chaos.tp1.ruhr-uni-bochum.de:/Home/kai/linux/kernel/v2.5/linux-2.5
into chaos.tp1.ruhr-uni-bochum.de:/Home/kai/linux/kernel/v2.5/linux-2.5.make

23 years ago[PATCH] usb-storage: remove timer
Matthew Dharm [Thu, 4 Jul 2002 11:21:24 +0000 (04:21 -0700)]
[PATCH] usb-storage: remove timer

This removes the timer usage in usb-storage.  This cleans up quite a bit
of the state machine and eliminates quite a few potential races.

Initialization commands and other non-data-path mechanisms use the USB core
timeout mechanism.  Anything in the data path uses the SCSI mid-layer
mechanism.

23 years ago[PATCH] usb-storage: Code consolidation of error paths
Matthew Dharm [Thu, 4 Jul 2002 11:21:18 +0000 (04:21 -0700)]
[PATCH] usb-storage: Code consolidation of error paths

This patch consolidates quite of bit of code in the control thread to
place all the cleanup/error handling into one place.

23 years ago[PATCH] usb-storage: code cleanup, small fixes
Matthew Dharm [Thu, 4 Jul 2002 11:21:08 +0000 (04:21 -0700)]
[PATCH] usb-storage: code cleanup, small fixes

This patch consolidates quite a bit of code for allocation/deallocation of
URBs, and removes a kmalloc() from a command path.

23 years ago[PATCH] fix SCSI driverfs for IDE panic on boot.
James Bottomley [Thu, 4 Jul 2002 05:40:19 +0000 (22:40 -0700)]
[PATCH] fix SCSI driverfs for IDE panic on boot.

This panic was reported to lkml by Anton Altaparmakov.  The code added to
partitions/check.c to add partitions to driverfs requires preparation by the
calling entity.  There's a NULL pointer check to see if the calling entity
actually did the preparation, but IDE forgets to clear the area it kmalloc's
for struct genhd so the pointer contains junk.

The fix is just to clear the struct genhd before IDE uses it.

23 years agoRadeon DRI merge
Linus Torvalds [Thu, 4 Jul 2002 05:40:01 +0000 (22:40 -0700)]
Radeon DRI merge

23 years agoUSB: removed unused Config.help entries from the host controller file.
Greg Kroah-Hartman [Thu, 4 Jul 2002 04:04:13 +0000 (21:04 -0700)]
USB:  removed unused Config.help entries from the host controller file.

23 years agoUSB: picked a uhci driver to go forward with.
Greg Kroah-Hartman [Thu, 4 Jul 2002 04:03:26 +0000 (21:03 -0700)]
USB:  picked a uhci driver to go forward with.

Removed usb-uhci-hcd.o from the list of UHCI drivers.
This allowed the logic to be cleaned up.
Removed CONFIG_EXPERIMENTAL dependancy, as it's no longer needed.

23 years agoNTFS: 2.0.14 - Run list merging code cleanup, minor locking changes, typo fixes.
Anton Altaparmakov [Wed, 3 Jul 2002 23:55:23 +0000 (00:55 +0100)]
NTFS: 2.0.14 - Run list merging code cleanup, minor locking changes, typo fixes.
- Change fs/ntfs/super.c::ntfs_statfs() to not rely on BKL by moving
  the locking out of super.c::get_nr_free_mft_records() and taking and
  dropping the mftbmp_lock rw_semaphore in ntfs_statfs() itself.
- Bring attribute run list merging code (fs/ntfs/attrib.c) in sync with
  current userspace ntfs library code. This means that if a merge
  fails the original run lists are always left unmodified instead of
  being silently corrupted.
- Misc typo fixes.

23 years agoFix psmouse.c - it needs tqueue.h
Vojtech Pavlik [Wed, 3 Jul 2002 23:39:54 +0000 (01:39 +0200)]
Fix psmouse.c - it needs tqueue.h

23 years agoAdd vortex anf fm801 gameport drivers, remove obsolete pcigame driver.
Vojtech Pavlik [Wed, 3 Jul 2002 23:39:19 +0000 (01:39 +0200)]
Add vortex anf fm801 gameport drivers, remove obsolete pcigame driver.

23 years agoMinor fixes to make the whole thing compile on latest 2.5 and kbuild2
Vojtech Pavlik [Wed, 3 Jul 2002 23:38:31 +0000 (01:38 +0200)]
Minor fixes to make the whole thing compile on latest 2.5 and kbuild2

23 years agoMinor cleanup in evdev.c
Vojtech Pavlik [Wed, 3 Jul 2002 23:28:47 +0000 (01:28 +0200)]
Minor cleanup in evdev.c

23 years agoMerge http://linux.bkbits.net:8080/linux-2.5
Vojtech Pavlik [Wed, 3 Jul 2002 22:41:08 +0000 (00:41 +0200)]
Merge http://linux.bkbits.net:8080/linux-2.5
into twilight.ucw.cz:/home/vojtech/bk/linux-input

23 years agoMerge samba.org:/home/paulus/kernel/linux-2.5
Paul Mackerras [Wed, 3 Jul 2002 20:33:39 +0000 (16:33 -0400)]
Merge samba.org:/home/paulus/kernel/linux-2.5
into samba.org:/home/paulus/kernel/for-linus-ppc

23 years agoUse time_after() where applicable.
Vojtech Pavlik [Wed, 3 Jul 2002 18:32:10 +0000 (20:32 +0200)]
Use time_after() where applicable.

23 years agoHandle slowly responding PS/2 mice.
Vojtech Pavlik [Wed, 3 Jul 2002 18:31:19 +0000 (20:31 +0200)]
Handle slowly responding PS/2 mice.

23 years agoHandle input-only keyboard interfaces.
Vojtech Pavlik [Wed, 3 Jul 2002 18:30:14 +0000 (20:30 +0200)]
Handle input-only keyboard interfaces.
Handle slowly responding keyboards.

23 years agoFix button assignments for Saturn and PSX pads.
Vojtech Pavlik [Wed, 3 Jul 2002 18:28:39 +0000 (20:28 +0200)]
Fix button assignments for Saturn and PSX pads.

23 years agoMakefile/config.in changes to reflect the new drivers.
Vojtech Pavlik [Wed, 3 Jul 2002 17:48:13 +0000 (19:48 +0200)]
Makefile/config.in changes to reflect the new drivers.

23 years agoUpdate the input handler modules to latest versions.
Vojtech Pavlik [Wed, 3 Jul 2002 17:26:19 +0000 (19:26 +0200)]
Update the input handler modules to latest versions.

23 years agoAdd keyboard, mouse and touchscreen drivers.
Vojtech Pavlik [Wed, 3 Jul 2002 17:08:45 +0000 (19:08 +0200)]
Add keyboard, mouse and touchscreen drivers.
Add tsdev, power and evbug event handlers.

23 years agoAdd new serio modules for PS/2 AUX/KBD.
Vojtech Pavlik [Wed, 3 Jul 2002 16:56:19 +0000 (18:56 +0200)]
Add new serio modules for PS/2 AUX/KBD.

23 years agoUpdate the iforce driver to the latest revision (it now lives in a
Vojtech Pavlik [Wed, 3 Jul 2002 16:49:42 +0000 (18:49 +0200)]
Update the iforce driver to the latest revision (it now lives in a
separate directory), add twiddler and guillemot drivers.

23 years agoUpdate the gameport drivers to Dave Jones's tree.
Vojtech Pavlik [Wed, 3 Jul 2002 16:36:11 +0000 (18:36 +0200)]
Update the gameport drivers to Dave Jones's tree.

23 years agoPPC32: fix compile error by removing extraneous declarations (ppc_ksyms.c)
Paul Mackerras [Tue, 2 Jul 2002 14:00:39 +0000 (10:00 -0400)]
PPC32: fix compile error by removing extraneous declarations (ppc_ksyms.c)

23 years agoPPC32: define USER_HZ to be 100 (HZ is still 100 for now)
Paul Mackerras [Tue, 2 Jul 2002 13:18:00 +0000 (09:18 -0400)]
PPC32: define USER_HZ to be 100 (HZ is still 100 for now)

23 years agoMerge samba.org:/home/paulus/kernel/linux-2.5
Paul Mackerras [Tue, 2 Jul 2002 12:29:55 +0000 (08:29 -0400)]
Merge samba.org:/home/paulus/kernel/linux-2.5
into samba.org:/home/paulus/kernel/for-linus-ppc

23 years ago[PATCH] suspend-to-disk documentation updates
Pavel Machek [Tue, 2 Jul 2002 10:03:27 +0000 (03:03 -0700)]
[PATCH] suspend-to-disk documentation updates

23 years agoFix more places where we exported our internal time
Linus Torvalds [Tue, 2 Jul 2002 09:46:34 +0000 (02:46 -0700)]
Fix more places where we exported our internal time
to user space. Convert to standard clock_t.

23 years agoMake ramfs/driverfs maintain directory nlink counts.
Linus Torvalds [Tue, 2 Jul 2002 08:37:41 +0000 (01:37 -0700)]
Make ramfs/driverfs maintain directory nlink counts.

Make dcache filesystems export directory entry types
to readdir.

23 years ago[PATCH] rewrite find_vma_prev
Matthew Wilcox [Tue, 2 Jul 2002 04:58:30 +0000 (21:58 -0700)]
[PATCH] rewrite find_vma_prev

For PA-RISC, we need find_vma_prev to return `prev', even if vma is NULL.
Our stack is at the top of memory, growing upwards, so when we page fault
we need to see prev.  For added bonus points, the code becomes simpler,
less indented, shorter and (for me, anyway) easier to understand.  The
code is well-tested, even on x86.  For PA and ia64 this code is called in
the page fault handler path so it is exercised frequently.

23 years agoMerge http://linux-scsi.bkbits.net/scsi-for-linus-2.5
Linus Torvalds [Tue, 2 Jul 2002 04:56:22 +0000 (21:56 -0700)]
Merge http://linux-scsi.bkbits.net/scsi-for-linus-2.5
into home.transmeta.com:/home/torvalds/v2.5/linux

23 years agoMerge
James Bottomley [Tue, 2 Jul 2002 06:50:45 +0000 (02:50 -0400)]
Merge

23 years agoMerge
James Bottomley [Tue, 2 Jul 2002 06:48:59 +0000 (02:48 -0400)]
Merge

23 years agoMerge mulgrave.(none):/home/jejb/BK/53c700-new-tag-2.5
James Bottomley [Tue, 2 Jul 2002 06:45:39 +0000 (02:45 -0400)]
Merge mulgrave.(none):/home/jejb/BK/53c700-new-tag-2.5
into mulgrave.(none):/home/jejb/BK/scsi-for-linus-2.5

23 years agoMerge mulgrave.(none):/home/jejb/BK/scsi-new-tag-2.5
James Bottomley [Tue, 2 Jul 2002 06:44:28 +0000 (02:44 -0400)]
Merge mulgrave.(none):/home/jejb/BK/scsi-new-tag-2.5
into mulgrave.(none):/home/jejb/BK/scsi-for-linus-2.5

23 years agoexport open_softirq
James Bottomley [Tue, 2 Jul 2002 06:40:12 +0000 (02:40 -0400)]
export open_softirq

23 years agolinux-2.5.22-driverfs.patch
Mike Sullivan [Tue, 2 Jul 2002 06:38:32 +0000 (02:38 -0400)]
linux-2.5.22-driverfs.patch

23 years ago[PATCH] APM compile fix, "stime" update broke it
Brad Heilbrun [Tue, 2 Jul 2002 04:54:32 +0000 (21:54 -0700)]
[PATCH] APM compile fix, "stime" update broke it

Fix APM that got broken by getting rid of "struct tms" and clock_t.

23 years ago[PATCH] softscsi patch
Matthew Wilcox [Mon, 1 Jul 2002 08:36:58 +0000 (04:36 -0400)]
[PATCH] softscsi patch

Doug Gilbert and James Bottomley hassled me all through KernelSummit &
OLS to explain about softirqs, tasklets and bottom halves.  In the end,
it was easier to write the code myself.  Thanks to James for pointing
out that the pointer handling in my original code was completely broken
and helping me debug.

I've booted this patch on a 4-way system at OSDL with two Adaptec SCSI
cards.  I haven't tried stressing it (not quite sure which discs I can
use ;-), and I don't understand the locking in the scsi subsystem at all.

The main effect of applying this patch is that scsi_softirq() [was
scsi_tasklet_func, and before that scsi_bottom_half_handler()] can now be
run on multiple CPUs at the same time.  We _seem_ to do enough locking
elsewhere in the SCSI stack that this is safe.  But someone who really
understands the SCSI stack should audit this.

This work shows up a hole in the current softirq API -- there's no support
for unregistering a softirq (close_softirq or similar).  We should do
this in scsi_exit -- make sure no softirqs are running while we unload.
This probably isn't a problem in practice, but it'd be nice to fix it.

23 years agoMake in-kernel HZ be 1000 on x86, retaining user-level 100 HZ clock_t.
Linus Torvalds [Mon, 1 Jul 2002 07:41:38 +0000 (00:41 -0700)]
Make in-kernel HZ be 1000 on x86, retaining user-level 100 HZ clock_t.

Stop using "struct tms" internally - always use timer ticks (or one of
the sane timeval/timespec types) instead.

Explicitly convert to clock_t when copying to user space for the old
broken interfaces that still use "clock_t".

Clean up and unify jiffies<->timeval conversion.