GitHub/LineageOS/android_kernel_samsung_universal7580.git
18 years ago[ATM]: atm_pcr_goal() doesn't modify its argument's contents -- mark it as const
Mitchell Blank Jr [Wed, 30 Nov 2005 00:13:55 +0000 (16:13 -0800)]
[ATM]: atm_pcr_goal() doesn't modify its argument's contents -- mark it as const

Signed-off-by: Mitchell Blank Jr <mitch@sfgoth.com>
Signed-off-by: Chas Williams <chas@cmf.nrl.navy.mil>
Signed-off-by: David S. Miller <davem@davemloft.net>
18 years ago[ATM]: always return the first interface for ATM_ITF_ANY
Mitchell Blank Jr [Wed, 30 Nov 2005 00:13:32 +0000 (16:13 -0800)]
[ATM]: always return the first interface for ATM_ITF_ANY

From: Mitchell Blank Jr <mitch@sfgoth.com>
Signed-off-by: Chas Williams <chas@cmf.nrl.navy.mil>
Signed-off-by: David S. Miller <davem@davemloft.net>
18 years ago[IPV4] tcp/route: Another look at hash table sizes
Mike Stroyan [Wed, 30 Nov 2005 00:12:55 +0000 (16:12 -0800)]
[IPV4] tcp/route: Another look at hash table sizes

  The tcp_ehash hash table gets too big on systems with really big memory.
It is worse on systems with pages larger than 4KB.  It wastes memory that
could be better used.  It also makes the netstat command slow because reading
/proc/net/tcp and /proc/net/tcp6 needs to go through the full hash table.

  The default value should not be larger for larger page sizes.  It seems
that the effect of page size is an unintended error dating back a long
time.  I also wonder if the default value really should be a larger
fraction of memory for systems with more memory.  While systems with
really big ram can afford more space for hash tables, it is not clear to
me that they benefit from increasing the allocation ratio for this table.

  The amount of memory allocated is determined by net/ipv4/tcp.c:tcp_init and
mm/page_alloc.c:alloc_large_system_hash.

tcp_init calls alloc_large_system_hash passing parameters-
    bucketsize=sizeof(struct tcp_ehash_bucket)
    numentries=thash_entries
    scale=(num_physpages >= 128 * 1024) ? (25-PAGE_SHIFT) : (27-PAGE_SHIFT)
    limit=0

On i386, PAGE_SHIFT is 12 for a page size of 4K
On ia64, PAGE_SHIFT defaults to 14 for a page size of 16K

The num_physpages test above makes the allocation take a larger fraction
of the total memory on systems with larger memory.  The threshold size
for a i386 system is 512MB.  For an ia64 system with 16KB pages the
threshold is 2GB.

For smaller memory systems-
On i386, scale = (27 - 12) = 15
On ia64, scale = (27 - 14) = 13
For larger memory systems-
On i386, scale = (25 - 12) = 13
On ia64, scale = (25 - 14) = 11

  For the rest of this discussion, I'll just track the larger memory case.

  The default behavior has numentries=thash_entries=0, so the allocated
size is determined by either scale or by the default limit of 1/16 of
total memory.

In alloc_large_system_hash-
| numentries = (flags & HASH_HIGHMEM) ? nr_all_pages : nr_kernel_pages;
| numentries += (1UL << (20 - PAGE_SHIFT)) - 1;
| numentries >>= 20 - PAGE_SHIFT;
| numentries <<= 20 - PAGE_SHIFT;

  At this point, numentries is pages for all of memory, rounded up to the
nearest megabyte boundary.

| /* limit to 1 bucket per 2^scale bytes of low memory */
| if (scale > PAGE_SHIFT)
| numentries >>= (scale - PAGE_SHIFT);
| else
| numentries <<= (PAGE_SHIFT - scale);

On i386, numentries >>= (13 - 12), so numentries is 1/8196 of
bytes of total memory.
On ia64, numentries <<= (14 - 11), so numentries is 1/2048 of
bytes of total memory.

|        log2qty = long_log2(numentries);
|
|        do {
|                size = bucketsize << log2qty;

bucketsize is 16, so size is 16 times numentries, rounded
down to a power of two.

On i386, size is 1/512 of bytes of total memory.
On ia64, size is 1/128 of bytes of total memory.

For smaller systems the results are
On i386, size is 1/2048 of bytes of total memory.
On ia64, size is 1/512 of bytes of total memory.

  The large page effect can be removed by just replacing
the use of PAGE_SHIFT with a constant of 12 in the calls to
alloc_large_system_hash.  That makes them more like the other uses of
that function from fs/inode.c and fs/dcache.c

Signed-off-by: David S. Miller <davem@davemloft.net>
18 years agoMerge master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6
Linus Torvalds [Tue, 29 Nov 2005 22:23:38 +0000 (14:23 -0800)]
Merge /pub/scm/linux/kernel/git/davem/sparc-2.6

18 years agoMerge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux-2.6
Linus Torvalds [Tue, 29 Nov 2005 22:23:21 +0000 (14:23 -0800)]
Merge branch 'release' of git://git./linux/kernel/git/aegl/linux-2.6

18 years agoRevert "[PATCH] drivers/message/fusion/mptbase.c: make code static"
Linus Torvalds [Tue, 29 Nov 2005 22:21:57 +0000 (14:21 -0800)]
Revert "[PATCH] drivers/message/fusion/mptbase.c: make code static"

This reverts commit 252ac865535e1ea9cc2d28be83f477d8d8b961a2.

It impacts the LSI customers using the mptstm target mode drivers
(source tar-ball at

  ftp://ftp.lsil.com/HostAdapterDrivers/linux/Fusion-MPT/mptstm-1.00.13-src.tar.gz

for those who care).

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] pfnmap: do_no_page BUG_ON again
Hugh Dickins [Tue, 29 Nov 2005 16:55:48 +0000 (16:55 +0000)]
[PATCH] pfnmap: do_no_page BUG_ON again

Use copy_user_highpage directly instead of cow_user_page in do_no_page:
in the immediately following page_cache_release, and elsewhere, it is
assuming that new_page is normal.  If any VM_PFNMAP driver can get to
do_no_page, it's just a BUG (but not in the case of do_anonymous_page).

Signed-off-by: Hugh Dickins <hugh@veritas.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] pfnmap: remove src_page from do_wp_page
Hugh Dickins [Tue, 29 Nov 2005 16:54:51 +0000 (16:54 +0000)]
[PATCH] pfnmap: remove src_page from do_wp_page

Clean away do_wp_page's "src_page": cow_user_page makes it unnecessary.

Signed-off-by: Hugh Dickins <hugh@veritas.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years agocow_user_page: fix page alignment
Linus Torvalds [Tue, 29 Nov 2005 22:07:55 +0000 (14:07 -0800)]
cow_user_page: fix page alignment

High Dickins points out that the user virtual address passed to the page
fault handler isn't necessarily page-aligned.

Also, add a comment on why the copy could fail for the user address case.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years agoVM: add common helper function to create the page tables
Linus Torvalds [Tue, 29 Nov 2005 22:03:14 +0000 (14:03 -0800)]
VM: add common helper function to create the page tables

This logic was duplicated four times, for no good reason.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[SPARC64]: Fix >8K I/O mappings.
David S. Miller [Tue, 29 Nov 2005 21:59:03 +0000 (13:59 -0800)]
[SPARC64]: Fix >8K I/O mappings.

Increment the PFN field of the PTE so that the tests
on vm_pfn in mm/memory.c match up.  The TLB ignores these
lower bits for larger page sizes, so it's OK to set things
like this.

Signed-off-by: David S. Miller <davem@davemloft.net>
18 years agoMerge master.kernel.org:/pub/scm/linux/kernel/git/tglx/mtd-2.6
Linus Torvalds [Tue, 29 Nov 2005 21:04:07 +0000 (13:04 -0800)]
Merge /pub/scm/linux/kernel/git/tglx/mtd-2.6

18 years ago[PATCH] fix megaraid.c locking
Christoph Hellwig [Tue, 29 Nov 2005 20:36:16 +0000 (21:36 +0100)]
[PATCH] fix megaraid.c locking

This fixes locking in megaraid.c, namely:

 (1) make sure megaraid_queue release the adapter lock by changing the
     code to have a single return
 (2) remove the errornous scsi_assign_lock call

Testing by Burton Windle.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Acked-by: Burton Windle <bwindle@fint.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years agoSupport strange discontiguous PFN remappings
Linus Torvalds [Tue, 29 Nov 2005 21:01:56 +0000 (13:01 -0800)]
Support strange discontiguous PFN remappings

These get created by some drivers that don't generally even want a pfn
remapping at all, but would really mostly prefer to just map pages
they've allocated individually instead.

For now, create a helper function that turns such an incomplete PFN
remapping call into a loop that does that explicit mapping.  In the long
run we almost certainly want to export a totally different interface for
that, though.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] Fix missing pfn variables caused by vm changes
Ben Collins [Tue, 29 Nov 2005 19:45:26 +0000 (11:45 -0800)]
[PATCH] Fix missing pfn variables caused by vm changes

I image this showed up because of "unused var..." when the changes
occured, because flush_cache_page() is a noop in most places.  This
showed up for me on parisc however, where flush_cache_page() is a real
function.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[MTD] Make functions static, include header files with prototypes
Adrian Bunk [Tue, 29 Nov 2005 14:49:38 +0000 (14:49 +0000)]
[MTD] Make functions static, include header files with prototypes

This patch contains the following possible cleanups:
- every file should #include the headers containing the prototypes for
  it's global functions
- make needlessly global functions static

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
18 years ago[MTD] chips: make sharps driver usable again
Richard Purdie [Tue, 29 Nov 2005 14:28:31 +0000 (14:28 +0000)]
[MTD] chips: make sharps driver usable again

Update the pre-CFI Sharp driver sharps.c so it compiles.  map_read32 /
map_write32 no longer exist in the kernel so the driver is totally broken
as it stands.  The replacement functions use different parameters resulting
in the other changes.

Change collie to use this driver until someone works out why the cfi driver
fails on that machine.

Signed-off-by: Richard Purdie <rpurdie@rpsys.net>
Tested-by: Pavel Machek <pavel@suse.cz>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
18 years ago[MTD] Remove bogus PQ2FADS driver
Thomas Gleixner [Mon, 28 Nov 2005 22:36:12 +0000 (22:36 +0000)]
[MTD] Remove bogus PQ2FADS driver

Remove disfunctional driver, which slipped through the review mechanism

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
18 years ago[MTD] maps: sparse fixup
Luiz Capitulino [Tue, 29 Nov 2005 14:30:03 +0000 (14:30 +0000)]
[MTD] maps: sparse fixup

The patch below fixes the following sparse warning:

drivers/mtd/maps/nettel.c:482:27: warning: Using plain integer as NULL pointer

Signed-off-by: Luiz Capitulino <lcapitulino@mandriva.com.br>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
18 years ago[MTD] cfi_cmdset_0001: relax locking rules for multi hardware partition support
Nicolas Pitre [Wed, 23 Nov 2005 22:07:56 +0000 (22:07 +0000)]
[MTD] cfi_cmdset_0001: relax locking rules for multi hardware partition support

Signed-off-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
18 years ago[MTD] Make some tables 'const' so they can live in .rodata
David Woodhouse [Thu, 17 Nov 2005 08:20:31 +0000 (08:20 +0000)]
[MTD] Make some tables 'const' so they can live in .rodata

arjan: drivers/mtd/maps/sc520cdp.c:167: warning: par_table is never written to and should be declared 'const'
arjan: drivers/mtd/maps/pci.c:105: warning: mtd_pci_map is never written to and should be declared 'const'
arjan: mind fixing those up ?

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
18 years ago[MTD] maps/ixp4xx: half-word boundary and little-endian fixups
John Bowler [Wed, 16 Nov 2005 16:23:25 +0000 (16:23 +0000)]
[MTD] maps/ixp4xx: half-word boundary and little-endian fixups

ixp4xx updates:
  - Handle reads that don't start on a half-word boundary.
  - Make it work when CPU is in little-endian mode.

Signed-off-by: John Bowler <jbowler@acm.org>
Signed-off-by: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: David Vrabel <dvrabel@arcom.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
18 years ago[MTD] CFI: Use 16-bit access to autoselect/read device id data
Todd Poynor [Tue, 15 Nov 2005 23:28:20 +0000 (23:28 +0000)]
[MTD] CFI: Use 16-bit access to autoselect/read device id data

Recent models of Intel/Sharp and Spansion CFI flash now have significant
bits in the upper byte of device ID codes, read via what Spansion calls
"autoselect" and Intel calls "read device identifier".  Currently these
values are truncated to the low 8 bits in the mtd data structures, as
all CFI read query info has previously been read one byte at a time.
Add a new method for reading 16-bit info, currently just manufacturer
and device codes; datasheets hint at future uses for upper bytes in
other fields.

Signed-off-by: Todd Poynor <tpoynor@mvista.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
18 years ago[MTD] devices/ms02-nv: phys/virt address fixups
Maciej W. Rozycki [Mon, 14 Nov 2005 13:41:51 +0000 (13:41 +0000)]
[MTD] devices/ms02-nv: phys/virt address fixups

Merge from linux-mips:
Use physical addresses at the interface level, letting drivers remap
them as appropriate.

Signed-off-by: Maciej W. Rozycki <macro@infradead.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
18 years ago[IA64] Remove getting break_num by decoding instruction
Keshavamurthy Anil S [Tue, 22 Nov 2005 22:15:49 +0000 (14:15 -0800)]
[IA64] Remove getting break_num by decoding instruction

break.b always sets cr.iim to 0 and the current code tries to
get the break_num by decoding instruction. However, their
seems to be a race condition while reading the regs->cr_iip,
as on other cpu the break.b at regs->cr_iip might have been
replaced with the original instruction as a result of
unregister_kprobe() and hence decoding instruction to
obtain break_num will result in wrong value in this case.

Also includes changes to kprobes.c which now has to handle
break number zero.

Signed-off-by: Anil S Keshavamurthy <anil.s.keshavamurthy@intel.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
18 years ago[IA64] - Make pfn_valid more precise for SGI Altix systems
Dean Roe [Wed, 9 Nov 2005 20:25:06 +0000 (14:25 -0600)]
[IA64] - Make pfn_valid more precise for SGI Altix systems

A single SGI Altix system can be divided into multiple partitions,
each running their own instance of the Linux kernel.  pfn_valid()
is currently not optimal for any but the first partition, since it
does not compare the pfn with min_low_pfn before calling the more
costly ia64_pfn_valid().

Signed-off-by: Dean Roe <roe@sgi.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
18 years agoMerge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Linus Torvalds [Tue, 29 Nov 2005 16:06:51 +0000 (08:06 -0800)]
Merge /pub/scm/linux/kernel/git/davem/net-2.6

18 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc-merge
Linus Torvalds [Tue, 29 Nov 2005 16:05:54 +0000 (08:05 -0800)]
Merge git://git./linux/kernel/git/paulus/powerpc-merge

18 years ago[JFFS2] Fix the slab cache constructor of 'struct jffs2_inode_info' objects.
Thomas Gleixner [Tue, 29 Nov 2005 15:57:17 +0000 (16:57 +0100)]
[JFFS2] Fix the slab cache constructor of 'struct jffs2_inode_info' objects.

JFFS2 initialize f->sem mutex as "locked" in the slab constructor which is a
bug. Objects are freed with unlocked f->sem mutex. So, when they allocated
again, f->sem is unlocked because the slab cache constructor is not called for
them. The constructor is called only once when memory pages are allocated for
objects (namely, when the slab layer allocates new slabs). So, sometimes
'struct jffs2_inode_info' are allocated with unlocked f->sem, sometimes with
locked. This is a bug. Instead, initialize f->sem as unlocked in the
constructor. I.e., in the "constructed" state f->sem must be unlocked.

From: Keijiro Yano <keijiro_yano@yahoo.co.jp>
Acked-by: Artem B. Bityutskiy <dedekind@infradead.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
18 years ago[PATCH] Fix vma argument in get_usr_pages() for gate areas
Nick Piggin [Tue, 29 Nov 2005 07:43:17 +0000 (18:43 +1100)]
[PATCH] Fix vma argument in get_usr_pages() for gate areas

The system call gate area handling called vm_normal_page() with the
wrong vma (which was always NULL, and caused an oops).

Signed-off-by: Nick Piggin <npiggin@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[MTD] RFD_FTL: Use lanana assigned major device number
Sean Young [Tue, 29 Nov 2005 11:48:00 +0000 (11:48 +0000)]
[MTD] RFD_FTL: Use lanana assigned major device number

A major block device number is now assigned by lanana.

Signed-off-by: Sean Young <sean@mess.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
18 years ago[IPV6]: Implement appropriate dummy rule 4 in ipv6_dev_get_saddr().
YOSHIFUJI Hideaki [Tue, 29 Nov 2005 06:27:11 +0000 (22:27 -0800)]
[IPV6]: Implement appropriate dummy rule 4 in ipv6_dev_get_saddr().

Ensure to update hiscore.rule in dummy rule 4 in ipv6_dev_get_saddr().
Pointed out by Yan Zheng <yanzheng@21cn.com>.

Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
18 years agopowerpc: Export __flush_icache_range for 32-bit
Paul Mackerras [Tue, 29 Nov 2005 04:50:58 +0000 (15:50 +1100)]
powerpc: Export __flush_icache_range for 32-bit

Both 32-bit and 64-bit use the same inline flush_icache_range definition
now, so both need to export __flush_icache_range, not just 64-bit.

Signed-off-by: Paul Mackerras <paulus@samba.org>
18 years agoLinux v2.6.15-rc3
Linus Torvalds [Tue, 29 Nov 2005 03:51:27 +0000 (19:51 -0800)]
Linux v2.6.15-rc3

18 years ago[PATCH] ppc: Export symbol needed by MOL
Otavio Salvador [Mon, 28 Nov 2005 21:02:24 +0000 (08:02 +1100)]
[PATCH] ppc: Export symbol needed by MOL

Export symbol needed to allow MOL to run. This was changed to be inline
in past and forgot to be change here.

Signed-off-by: Paul Mackerras <paulus@samba.org>
18 years agoMerge master.kernel.org:/home/rmk/linux-2.6-serial
Linus Torvalds [Mon, 28 Nov 2005 23:03:28 +0000 (15:03 -0800)]
Merge master.kernel.org:/home/rmk/linux-2.6-serial

18 years agoMerge master.kernel.org:/home/rmk/linux-2.6-mmc
Linus Torvalds [Mon, 28 Nov 2005 23:02:50 +0000 (15:02 -0800)]
Merge master.kernel.org:/home/rmk/linux-2.6-mmc

18 years agoMerge master.kernel.org:/home/rmk/linux-2.6-arm
Linus Torvalds [Mon, 28 Nov 2005 23:02:30 +0000 (15:02 -0800)]
Merge master.kernel.org:/home/rmk/linux-2.6-arm

18 years ago[PATCH] fuse: check for invalid node ID in fuse_create_open()
Miklos Szeredi [Mon, 28 Nov 2005 21:44:16 +0000 (13:44 -0800)]
[PATCH] fuse: check for invalid node ID in fuse_create_open()

Check for invalid node ID values in the new atomic create+open method.

Signed-off-by: Miklos Szeredi <miklos@szeredi.hu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] fuse: check directory aliasing in mkdir
Miklos Szeredi [Mon, 28 Nov 2005 21:44:16 +0000 (13:44 -0800)]
[PATCH] fuse: check directory aliasing in mkdir

Check the created directory inode for aliases in the mkdir() method.

Signed-off-by: Miklos Szeredi <miklos@szeredi.hu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] shrinker->nr = LONG_MAX means deadlock for icache
Andrea Arcangeli [Mon, 28 Nov 2005 21:44:15 +0000 (13:44 -0800)]
[PATCH] shrinker->nr = LONG_MAX means deadlock for icache

With Andrew Morton <akpm@osdl.org>

The slab scanning code tries to balance the scanning rate of slabs versus the
scanning rate of LRU pages.  To do this, it retains state concerning how many
slabs have been scanned - if a particular slab shrinker didn't scan enough
objects, we remember that for next time, and scan more objects on the next
pass.

The problem with this is that with (say) a huge number of GFP_NOIO
direct-reclaim attempts, the number of objects which are to be scanned when we
finally get a GFP_KERNEL request can be huge.  Because some shrinker handlers
just bail out if !__GFP_FS.

So the patch clamps the number of objects-to-be-scanned to 2* the total number
of objects in the slab cache.

Signed-off-by: Andrea Arcangeli <andrea@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] Fix oops in vfs_quotaon_mount()
Jan Kara [Mon, 28 Nov 2005 21:44:14 +0000 (13:44 -0800)]
[PATCH] Fix oops in vfs_quotaon_mount()

When quota file specified in mount options did not exist, we tried to
dereference NULL pointer later. Fix it.

Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] md: fix --re-add for raid1 and raid6
NeilBrown [Mon, 28 Nov 2005 21:44:13 +0000 (13:44 -0800)]
[PATCH] md: fix --re-add for raid1 and raid6

If you have an array with a write-intent-bitmap, and you remove a device, then
re-add it, a full recovery isn't needed.  We detect a re-add by looking at
saved_raid_disk.  For raid1, it doesn't matter which disk it was, only whether
or not it was an active device.  The old code being removed set a value of
'mirror' which was then ignored, so it can go.  The changed code performs the
correct check.

For raid6, if there are two missing devices, make sure we chose the right slot
on --re-add rather than always the first slot.

Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] md: set default_bitmap_offset properly in set_array_info
NeilBrown [Mon, 28 Nov 2005 21:44:12 +0000 (13:44 -0800)]
[PATCH] md: set default_bitmap_offset properly in set_array_info

If an array is created using set_array_info, default_bitmap_offset isn't set
properly meaning that an internal bitmap cannot be hot-added until the array
is stopped and re-assembled.

Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] md: fix problem with raid6 intent bitmap
NeilBrown [Mon, 28 Nov 2005 21:44:11 +0000 (13:44 -0800)]
[PATCH] md: fix problem with raid6 intent bitmap

When doing a recovery, we need to know whether the array will still be
degraded after the recovery has finished, so we can know whether bits can be
clearred yet or not.  This patch performs the required check.

Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] md: fix locking problem in r5/r6
NeilBrown [Mon, 28 Nov 2005 21:44:10 +0000 (13:44 -0800)]
[PATCH] md: fix locking problem in r5/r6

bitmap_unplug actually writes data (bits) to storage, so we shouldn't be
holding a spinlock...

Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] md: improve read speed to raid10 arrays using 'far copies'
NeilBrown [Mon, 28 Nov 2005 21:44:09 +0000 (13:44 -0800)]
[PATCH] md: improve read speed to raid10 arrays using 'far copies'

raid10 has two different layouts.  One uses near-copies (so multiple
copies of a block are at the same or similar offsets of different
devices) and the other uses far-copies (so multiple copies of a block
are stored a greatly different offsets on different devices).  The point
of far-copies is that it allows the first section (normally first half)
to be layed out in normal raid0 style, and thus provide raid0 sequential
read performance.

Unfortunately, the read balancing in raid10 makes some poor decisions
for far-copies arrays and you don't get the desired performance.  So
turn off that bad bit of read_balance for far-copies arrays.

With this patch, read speed of an 'f2' array is comparable with a raid0
with the same number of devices, though write speed is ofcourse still
very slow.

Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] fix broken hybrid v4l-dvb frontend selection
Michael Krufky [Mon, 28 Nov 2005 21:44:08 +0000 (13:44 -0800)]
[PATCH] fix broken hybrid v4l-dvb frontend selection

Repair broken build configuration for hybrid v4l/dvb card frontend
selection.

Signed-off-by: Michael Krufky <mkrufky@m1k.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] temporarily disable swap token on memory pressure
Rik van Riel [Mon, 28 Nov 2005 21:44:07 +0000 (13:44 -0800)]
[PATCH] temporarily disable swap token on memory pressure

Some users (hi Zwane) have seen a problem when running a workload that
eats nearly all of physical memory - th system does an OOM kill, even
when there is still a lot of swap free.

The problem appears to be a very big task that is holding the swap
token, and the VM has a very hard time finding any other page in the
system that is swappable.

Instead of ignoring the swap token when sc->priority reaches 0, we could
simply take the swap token away from the memory hog and make sure we
don't give it back to the memory hog for a few seconds.

This patch resolves the problem Zwane ran into.

Signed-off-by: Rik van Riel <riel@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] v9fs: fix memory leak in v9fs dentry code
Latchesar Ionkov [Mon, 28 Nov 2005 21:44:05 +0000 (13:44 -0800)]
[PATCH] v9fs: fix memory leak in v9fs dentry code

Assign the appropriate dentry operations to the dentry. Fixes memory leak.

Signed-off-by: Latchesar Ionkov <lucho@ionkov.net>
Cc: Eric Van Hensbergen <ericvh@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] cpuset fork locking fix
Paul Jackson [Mon, 28 Nov 2005 21:44:05 +0000 (13:44 -0800)]
[PATCH] cpuset fork locking fix

Move the cpuset_fork() call below the write_unlock_irq call in
kernel/fork.c copy_process().

Since the cpuset-dual-semaphore-locking-overhaul.patch, the cpuset_fork()
routine acquires task_lock(), so cannot be called while holding the
tasklist_lock for write.

Signed-off-by: Paul Jackson <pj@sgi.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] mm: __alloc_pages cleanup fix
Nick Piggin [Mon, 28 Nov 2005 21:44:03 +0000 (13:44 -0800)]
[PATCH] mm: __alloc_pages cleanup fix

I believe this patch is required to fix breakage in the asynch reclaim
watermark logic introduced by this patch:

http://www.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=7fb1d9fca5c6e3b06773b69165a73f3fb786b8ee

Just some background of the watermark logic in case it isn't clear...
Basically what we have is this:

 ---  pages_high
   |
   | (a)
   |
 ---  pages_low
   |
   | (b)
   |
 ---  pages_min
   |
   | (c)
   |
 ---  0

Now when pages_low is reached, we want to kick asynch reclaim, which gives us
an interval of "b" before we must start synch reclaim, and gives kswapd an
interval of "a" before it need go back to sleep.

When pages_min is reached, normal allocators must enter synch reclaim, but
PF_MEMALLOC, ALLOC_HARDER, and ALLOC_HIGH (ie.  atomic allocations, recursive
allocations, etc.) get access to varying amounts of the reserve "c".

Signed-off-by: Nick Piggin <npiggin@suse.de>
Cc: "Seth, Rohit" <rohit.seth@intel.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] ext3: Wrong return value for EXT3_IOC_GROUP_ADD
Glauber de Oliveira Costa [Mon, 28 Nov 2005 21:44:02 +0000 (13:44 -0800)]
[PATCH] ext3: Wrong return value for EXT3_IOC_GROUP_ADD

This patch corrects the return value for the EXT3_IOC_GROUP_ADD in case it
fails due to the presence of multiple resizers at the filesystem.

The problem is a little bit more serious than a wrong return value in this
case, since the clause err=0 in the exit_journal path will lead to a call
to update_backups which in turns causes a NULL pointer dereference.

Signed-off-by: Glauber de Oliveira Costa <glommer@br.ibm.com>
Cc: "Stephen C. Tweedie" <sct@redhat.com>
Cc: Andreas Dilger <adilger@clusterfs.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] m32r: M3A-2170(Mappi-III) IDE support
Hirokazu Takata [Mon, 28 Nov 2005 21:44:00 +0000 (13:44 -0800)]
[PATCH] m32r: M3A-2170(Mappi-III) IDE support

This patch is for supporting IDE interface for M3A-2170(Mappi-III) board.

Signed-off-by: Mamoru Sakugawa <sakugawa@linux-m32r.org>
Signed-off-by: Hirokazu Takata <takata@linux-m32r.org>
Cc: Bartlomiej Zolnierkiewicz <B.Zolnierkiewicz@elka.pw.edu.pl>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] m32r: Introduce atomic_cmpxchg and atomic_inc_not_zero operations
Hirokazu Takata [Mon, 28 Nov 2005 21:43:59 +0000 (13:43 -0800)]
[PATCH] m32r: Introduce atomic_cmpxchg and atomic_inc_not_zero operations

Introduce atomic_cmpxchg and atomic_inc_not_zero operations for m32r.

Signed-off-by: Hayato Fujiwara <fujiwara@linux-m32r.org>
Signed-off-by: Hirokazu Takata <takata@linux-m32r.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] m32r: Fix sys_tas() syscall
Hirokazu Takata [Mon, 28 Nov 2005 21:43:58 +0000 (13:43 -0800)]
[PATCH] m32r: Fix sys_tas() syscall

This patch fixes a deadlock problem of the m32r SMP kernel.

In the m32r kernel, sys_tas() system call is provided as a test-and-set
function for userspace, for backward compatibility.

In some multi-threading application program, deadlocks were rarely caused
at sys_tas() funcion.  Such a deadlock was caused due to a collision of
__pthread_lock() and __pthread_unlock() operations.

The "tas" syscall is repeatedly called by pthread_mutex_lock() to get a
lock, while a lock variable's value is not 0.  On the other hand,
pthead_mutex_unlock() sets the lock variable to 0 for unlocking.

In the previous implementation of sys_tas() routine, there was a
possibility that a unlock operation was ignored in the following case:

- Assume a lock variable (*addr) was equal to 1 before sys_tas() execution.
- __pthread_unlock() operation is executed by the other processor
  and the lock variable (*addr) is set to 0, between a read operation
  ("oldval = *addr;") and the following write operation ("*addr = 1;")
  during a execution of sys_tas().

In this case, the following write operation ("*addr = 1;") overwrites the
__pthread_unlock() result, and sys_tas() fails to get a lock in the next
turn and after that.

According to the attatched patch, sys_tas() returns 0 value in the next
turn and deadlocks never happen.

Signed-off-by: Hitoshi Yamamoto <Yamamoto.Hitoshi@ap.MitsubishiElectric.co.jp>
Signed-off-by: Hirokazu Takata <takata@linux-m32r.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] Fix hardcoded cpu=0 in workqueue for per_cpu_ptr() calls
Ben Collins [Mon, 28 Nov 2005 21:43:56 +0000 (13:43 -0800)]
[PATCH] Fix hardcoded cpu=0 in workqueue for per_cpu_ptr() calls

Tracked this down on an Ultra Enterprise 3000.  It's a 6-way machine.  Odd
thing about this machine (and it's good for finding bugs like this) is that
the CPU id's are not 0 based.  For instance, on my machine the CPU's are
6/7/10/11/14/15.

This caused some NULL pointer dereference in kernel/workqueue.c because for
single_threaded workqueue's, it hardcoded the cpu to 0.

I changed the 0's to any_online_cpu(cpu_online_mask), which cpumask.h
claims is "First cpu in mask".  So this fits the same usage.

Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] fix 32bit overflow in timespec_to_sample()
Oleg Nesterov [Mon, 28 Nov 2005 21:43:55 +0000 (13:43 -0800)]
[PATCH] fix 32bit overflow in timespec_to_sample()

fix 32bit overflow in timespec_to_sample()

Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] fix broken lib/genalloc.c
Chris Humbert [Mon, 28 Nov 2005 21:43:54 +0000 (13:43 -0800)]
[PATCH] fix broken lib/genalloc.c

genalloc improperly stores the sizes of freed chunks, allocates overlapping
memory regions, and oopses after its in-band data is overwritten.

Signed-off-by: Chris Humbert <mahadri-kernel@drigon.com>
Cc: Jes Sorensen <jes@trained-monkey.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] reiserfs: fix 32-bit overflow in map_block_for_writepage()
Oleg Drokin [Mon, 28 Nov 2005 21:43:53 +0000 (13:43 -0800)]
[PATCH] reiserfs: fix 32-bit overflow in map_block_for_writepage()

I now see another overflow in reiserfs that should lead to data corruptions
with files that are bigger than 4G under certain circumstances when using
mmap.

Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] Console rotation fixes
Benjamin Herrenschmidt [Mon, 28 Nov 2005 21:43:52 +0000 (13:43 -0800)]
[PATCH] Console rotation fixes

Remove bogus usage of test/set_bit() from fbcon rotation code and just
manipulate the bits directly.  This fixes an oops on powerpc among others
and should be faster.  Seems to work fine on the G5 here.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Acked-by: Antonino Daplas <adaplas@pol.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] FRV: Make the FRV arch work again
David Howells [Mon, 28 Nov 2005 21:43:51 +0000 (13:43 -0800)]
[PATCH] FRV: Make the FRV arch work again

The attached patch implements a bunch of small changes to the FRV arch to
make it work again.

It deals with the following problems:

 (1) SEM_DEBUG should be SEMAPHORE_DEBUG.

 (2) The argument list to pcibios_penalize_isa_irq() has changed.

 (3) CONFIG_HIGHMEM can't be used directly in #if as it may not be defined.

 (4) page->private is no longer directly accessible.

 (5) linux/hardirq.h assumes asm/hardirq.h will include linux/irq.h

 (6) The IDE MMIO access functions are given pointers, not integers, and so
     get type casting errors.

 (7) __pa() is passed an explicit u64 type in drivers/char/mem.c, but that
     can't be cast directly to a pointer on a 32-bit platform.

 (8) SEMAPHORE_DEBUG should not be contingent on WAITQUEUE_DEBUG as that no
     longer exists.

 (9) PREEMPT_ACTIVE is too low a value.

Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] fork.c: proc_fork_connector() called under write_lock()
Andrew Morton [Mon, 28 Nov 2005 21:43:48 +0000 (13:43 -0800)]
[PATCH] fork.c: proc_fork_connector() called under write_lock()

Don't do that - it does GFP_KERNEL allocations, for a start.

(Reported by Guillaume Thouvenin <guillaume.thouvenin@bull.net>)

Acked-by: Matt Helsley <matthltc@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] memory_sysdev_class is static
Andrew Morton [Mon, 28 Nov 2005 21:43:47 +0000 (13:43 -0800)]
[PATCH] memory_sysdev_class is static

So don't define it as extern in the header file.

drivers/base/memory.c:28: error: static declaration of 'memory_sysdev_class' follows non-static declaration
include/linux/memory.h:88: error: previous declaration of 'memory_sysdev_class' was here

Cc: Greg KH <greg@kroah.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] clean up lock_cpu_hotplug() in cpufreq
Ashok Raj [Mon, 28 Nov 2005 21:43:46 +0000 (13:43 -0800)]
[PATCH] clean up lock_cpu_hotplug() in cpufreq

There are some callers in cpufreq hotplug notify path that the lowest
function calls lock_cpu_hotplug().  The lock is already held during
cpu_up() and cpu_down() calls when the notify calls are broadcast to
registered clients.

Ideally if possible, we could disable_preempt() at the highest caller and
make sure we dont sleep in the path down in cpufreq->driver_target() calls
but the calls are so intertwined and cumbersome to cleanup.

Hence we consistently use lock_cpu_hotplug() and unlock_cpu_hotplug() in
all places.

 - Removed export of cpucontrol semaphore and made it static.
 - removed explicit uses of up/down with lock_cpu_hotplug()
   so we can keep track of the the callers in same thread context and
   just keep refcounts without calling a down() that causes a deadlock.
 - Removed current_in_hotplug() uses
 - Removed PF_HOTPLUG_CPU in sched.h introduced for the current_in_hotplug()
   temporary workaround.

Tested with insmod of cpufreq_stat.ko, and logical online/offline
to make sure we dont have any hang situations.

Signed-off-by: Ashok Raj <ashok.raj@intel.com>
Cc: Zwane Mwaikambo <zwane@linuxpower.ca>
Cc: Shaohua Li <shaohua.li@intel.com>
Cc: "Siddha, Suresh B" <suresh.b.siddha@intel.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] Workaround for gcc 2.96 (undefined references)
Alan Stern [Mon, 28 Nov 2005 21:43:44 +0000 (13:43 -0800)]
[PATCH] Workaround for gcc 2.96 (undefined references)

  LD      .tmp_vmlinux1
mm/built-in.o(.text+0x100d6): In function `copy_page_range':
: undefined reference to `__pud_alloc'
mm/built-in.o(.text+0x1010b): In function `copy_page_range':
: undefined reference to `__pmd_alloc'
mm/built-in.o(.text+0x11ef4): In function `__handle_mm_fault':
: undefined reference to `__pud_alloc'
fs/built-in.o(.text+0xc930): In function `install_arg_page':
: undefined reference to `__pud_alloc'
make: *** [.tmp_vmlinux1] Error 1

Those missing references in mm/memory.c arise from this code in
include/linux/mm.h, combined with the fact that __PGTABLE_PMD_FOLDED and
__PGTABLE_PUD_FOLDED are both set and __ARCH_HAS_4LEVEL_HACK is not:

/*
 * The following ifdef needed to get the 4level-fixup.h header to work.
 * Remove it when 4level-fixup.h has been removed.
 */
#if defined(CONFIG_MMU) && !defined(__ARCH_HAS_4LEVEL_HACK)
static inline pud_t *pud_alloc(struct mm_struct *mm, pgd_t *pgd, unsigned long address)
{
        return (unlikely(pgd_none(*pgd)) && __pud_alloc(mm, pgd, address))?
                NULL: pud_offset(pgd, address);
}

static inline pmd_t *pmd_alloc(struct mm_struct *mm, pud_t *pud, unsigned long address)
{
        return (unlikely(pud_none(*pud)) && __pmd_alloc(mm, pud, address))?
                NULL: pmd_offset(pud, address);
}
#endif /* CONFIG_MMU && !__ARCH_HAS_4LEVEL_HACK */

With my configuration the pgd_none and pud_none routines are inlines
returning a constant 0.  Apparently the old compiler avoids generating
calls to __pud_alloc and __pmd_alloc but still lists them as undefined
references in the module's symbol table.

I don't know which change caused this problem.  I think it was added
somewhere between 2.6.14 and 2.6.15-rc1, because I remember building
several 2.6.14-rc kernels without difficulty.  However I can't point to an
individual culprit.

Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] sparc: convert IO remapping to VM_PFNMAP
David S. Miller [Mon, 28 Nov 2005 22:02:10 +0000 (14:02 -0800)]
[PATCH] sparc: convert IO remapping to VM_PFNMAP

Here are the Sparc bits.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years agomm: re-architect the VM_UNPAGED logic
Linus Torvalds [Mon, 28 Nov 2005 22:34:23 +0000 (14:34 -0800)]
mm: re-architect the VM_UNPAGED logic

This replaces the (in my opinion horrible) VM_UNMAPPED logic with very
explicit support for a "remapped page range" aka VM_PFNMAP.  It allows a
VM area to contain an arbitrary range of page table entries that the VM
never touches, and never considers to be normal pages.

Any user of "remap_pfn_range()" automatically gets this new
functionality, and doesn't even have to mark the pages reserved or
indeed mark them any other way.  It just works.  As a side effect, doing
mmap() on /dev/mem works for arbitrary ranges.

Sparc update from David in the next commit.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[SERIAL] mark several serial tables const
Arjan van de Ven [Mon, 28 Nov 2005 21:04:11 +0000 (21:04 +0000)]
[SERIAL] mark several serial tables const

This patch marks a few serial data structures const, moving them to
.rodata where they won't false-share cachelines with things that get
written to.

Signed-off-by: Arjan van de Ven <arjan@infradead.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
18 years ago[MMC] Fix protocol errors
Pierre Ossman [Mon, 28 Nov 2005 21:00:29 +0000 (21:00 +0000)]
[MMC] Fix protocol errors

A review against MMC/SD specifications found some errors in the current
implementation.

Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
18 years ago[ARM] 3181/1: add PORT_ identifier for Hilscher netx uart
Sascha Hauer [Mon, 28 Nov 2005 18:09:44 +0000 (18:09 +0000)]
[ARM] 3181/1: add PORT_ identifier for Hilscher netx uart

Patch from Sascha Hauer

This patch adds PORT_NETX for supporting the Hilscher netx embedded
UARTs.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
18 years ago[ARM] 3180/1: Update Zaurus defconfigs
Richard Purdie [Mon, 28 Nov 2005 18:08:45 +0000 (18:08 +0000)]
[ARM] 3180/1: Update Zaurus defconfigs

Patch from Richard Purdie

This updates the Zaurus defconfigs. Poodle gets merged into
corgi_defconfig and support for tosa and akita is enabled.

Signed-off-by: Richard Purdie <rpurdie@rpsys.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
18 years ago[ARM] 3179/1: Update/correct Zaurus Kconfig entries
Richard Purdie [Mon, 28 Nov 2005 18:08:44 +0000 (18:08 +0000)]
[ARM] 3179/1: Update/correct Zaurus Kconfig entries

Patch from Richard Purdie

Add iWMMX Extentions for the pxa27x based Zaurus models and
fix a couple of minor mistakes in the PXA Kconfig file.

Signed-off-by: Richard Purdie <rpurdie@rpsys.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
18 years ago[ARM] 3178/1: S3C2400 - adds GPIO registers definitions to regs-gpio.h
Lucas Correia Villa Real [Mon, 28 Nov 2005 18:08:43 +0000 (18:08 +0000)]
[ARM] 3178/1: S3C2400 - adds GPIO registers definitions to regs-gpio.h

Patch from Lucas Correia Villa Real

This patch adds definitions to GPIO registers for the S3C2400 into
include/asm-arm/arch-s3c2410/regs-gpio.h.

Signed-off-by: Lucas Correia Villa Real <lucasvr@gobolinux.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
18 years ago[PATCH] drivers/scsi/dpt_i2o.c: fix a NULL pointer dereference
Adrian Bunk [Sat, 26 Nov 2005 23:36:37 +0000 (00:36 +0100)]
[PATCH] drivers/scsi/dpt_i2o.c: fix a NULL pointer dereference

The Coverity checker spotted this obvious NULL pointer dereference.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Acked-by: Mark Salyzyn <mark_salyzyn@adaptec.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] drivers/infiniband/core/mad.c: fix use-after-release case
Adrian Bunk [Sat, 26 Nov 2005 23:37:36 +0000 (00:37 +0100)]
[PATCH] drivers/infiniband/core/mad.c: fix use-after-release case

The Coverity checker spotted this obvious use-after-release bug caused
by a wrong order of the cleanups.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years ago[PATCH] drivers/message/i2o/pci.c: fix a NULL pointer dereference
Adrian Bunk [Sat, 26 Nov 2005 23:37:05 +0000 (00:37 +0100)]
[PATCH] drivers/message/i2o/pci.c: fix a NULL pointer dereference

The Coverity checker spotted this obvious NULL pointer dereference.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Acked-by: Markus Lidel <Markus.Lidel@shadowconnect.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
18 years agoMerge branch 'drm-linus' of master.kernel.org:/pub/scm/linux/kernel/git/airlied/drm-2.6
Linus Torvalds [Sat, 26 Nov 2005 00:48:48 +0000 (16:48 -0800)]
Merge branch 'drm-linus' of /linux/kernel/git/airlied/drm-2.6

18 years agoSUNRPC: Funny looking code in __rpc_purge_upcall
Trond Myklebust [Fri, 25 Nov 2005 22:10:11 +0000 (17:10 -0500)]
SUNRPC: Funny looking code in __rpc_purge_upcall

 In __rpc_purge_upcall (net/sunrpc/rpc_pipe.c), the newer code to clean up
 the in_upcall list has a typo.
 Thanks to Vince Busam <vbusam@google.com> for spotting this!

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
18 years agoNFS: Fix a spinlock recursion inside nfs_update_inode()
Trond Myklebust [Fri, 25 Nov 2005 22:10:06 +0000 (17:10 -0500)]
NFS: Fix a spinlock recursion inside nfs_update_inode()

 In cases where the server has gone insane, nfs_update_inode() may end
 up calling nfs_invalidate_inode(), which again calls stuff that takes
 the inode->i_lock that we're already holding.

 In addition, given the sort of things we have in NFS these days that
 need to be cleaned up on inode release, I'm not sure we should ever
 be calling make_bad_inode().

 Fix up spinlock recursion, and limit nfs_invalidate_inode() to clearing
 the caches, and marking the inode as being stale.

 Thanks to Steve Dickson <SteveD@redhat.com> for spotting this.

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
18 years agoNFSv4: Fix typo in lock caching
Trond Myklebust [Fri, 25 Nov 2005 22:10:01 +0000 (17:10 -0500)]
NFSv4: Fix typo in lock caching

 When caching locks due to holding a file delegation, we must always
 check against local locks before sending anything to the server.

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
18 years agoNFSv4: Fix buggy nfs_wait_on_sequence()
Trond Myklebust [Fri, 25 Nov 2005 22:09:57 +0000 (17:09 -0500)]
NFSv4: Fix buggy nfs_wait_on_sequence()

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
18 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc-merge
Linus Torvalds [Fri, 25 Nov 2005 17:42:19 +0000 (09:42 -0800)]
Merge git://git./linux/kernel/git/paulus/powerpc-merge

18 years agoMerge git://oss.sgi.com:8090/oss/git/xfs-2.6
Linus Torvalds [Fri, 25 Nov 2005 17:33:53 +0000 (09:33 -0800)]
Merge git://oss.sgi.com:8090/oss/git/xfs-2.6

18 years ago[ARM] Update mach-types
Russell King [Fri, 25 Nov 2005 15:59:01 +0000 (15:59 +0000)]
[ARM] Update mach-types

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
18 years ago[ARM] Realview core.c does not need mach-types.h
Russell King [Fri, 25 Nov 2005 15:57:21 +0000 (15:57 +0000)]
[ARM] Realview core.c does not need mach-types.h

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
18 years ago[ARM] Do not call flush_tlb_kernel_range() with IRQs disabled.
Russell King [Fri, 25 Nov 2005 15:52:51 +0000 (15:52 +0000)]
[ARM] Do not call flush_tlb_kernel_range() with IRQs disabled.

We must not call TLB maintainence operations with interrupts disabled,
otherwise we risk a lockup in the SMP IPI code.

This means that consistent_free() can not be called from a context with
IRQs disabled.  In addition, we must not hold the lock in consistent_free
when we call flush_tlb_kernel_range().  However, we must continue to
prevent consistent_alloc() from re-using the memory region until we've
finished tearing down the mapping and dealing with the TLB.

Therefore, leave the vm_region entry in the list, but mark it inactive
before dropping the lock and starting the tear-down process.  After the
mapping has been torn down, re-acquire the lock and remove the entry
from the list.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
18 years ago[ARM] Remove mach-types.h from head.S
Russell King [Fri, 25 Nov 2005 15:43:22 +0000 (15:43 +0000)]
[ARM] Remove mach-types.h from head.S

We don't really need to check whether the machine type is Netwinder
or CATS before setting up the PCI IO mapping for debugging.  This
allows us to eliminate asm/mach-types.h from head.S

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
18 years ago[ARM] Remove asm/hardware.h include from SA1100 io.h
Russell King [Fri, 25 Nov 2005 15:33:12 +0000 (15:33 +0000)]
[ARM] Remove asm/hardware.h include from SA1100 io.h

Unfortunately, we have a symbol clash between the SA-1100 header and
some drivers.  Since everywhere which needs SA1100 specifics includes
asm/hardware.h, we don't need to include it in the SA1100 io.h header.

In file included from drivers/net/wireless/wavelan_cs.p.h:459,
                 from drivers/net/wireless/wavelan_cs.c:60:
drivers/net/wireless/wavelan_cs.h:97:1: warning: "LCSR" redefined
In file included from include/asm/arch/hardware.h:56,
                 from include/asm/hardware.h:16,
                 from include/asm/arch/io.h:13,
                 from include/asm/io.h:71,
                 from drivers/net/wireless/wavelan_cs.p.h:433,
                 from drivers/net/wireless/wavelan_cs.c:60:
include/asm/arch/SA-1100.h:1907:1: warning: this is the location of the previous definition

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
18 years ago[PATCH] powerpc: More hugepage boundary case fixes
David Gibson [Thu, 24 Nov 2005 02:34:56 +0000 (13:34 +1100)]
[PATCH] powerpc: More hugepage boundary case fixes

Blah.  The patch [0] I recently sent fixing errors with
in_hugepage_area() and prepare_hugepage_range() for powerpc itself has
an off-by-one bug.  Furthermore, the related functions
touches_hugepage_*_range() and within_hugepage_*_range() are also
buggy.  Some of the bugs, like those addressed in [0] originated with
commit 7d24f0b8a53261709938ffabe3e00f88f6498df9 where we tweaked the
semantics of where hugepages are allowed.  Other bugs have been there
essentially forever, and are due to the undefined behaviour of '<<'
with shift counts greater than the type width (LOW_ESID_MASK could
return non-zero for high ranges with the right congruences).

The good news is that I now have a testsuite which should pick up
things like this if they creep in again.

[0] "powerpc-fix-for-hugepage-areas-straddling-4gb-boundary"

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
18 years agoMerge ../linux-2.6
Paul Mackerras [Fri, 25 Nov 2005 11:12:01 +0000 (22:12 +1100)]
Merge ../linux-2.6

18 years ago[PATCH] powerpc: remove arch/powerpc/include hack for 64 bit
Stephen Rothwell [Tue, 22 Nov 2005 01:05:26 +0000 (12:05 +1100)]
[PATCH] powerpc: remove arch/powerpc/include hack for 64 bit

With the removal of include/asm-powerpc, we no longer need
arch/powerpc/include/asm for the 64 bit build.  We also do not need
-Iarch/powerpc for the 64 bit build either.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
18 years ago[XFS] Resolve the xlog_grant_log_space hang, revert inline to macro.
Nathan Scott [Fri, 25 Nov 2005 05:42:28 +0000 (16:42 +1100)]
[XFS] Resolve the xlog_grant_log_space hang, revert inline to macro.

SGI-PV: 946205
SGI-Modid: xfs-linux-melb:xfs-kern:24567a

Signed-off-by: Nathan Scott <nathans@sgi.com>
18 years ago[XFS] Fix a case where attr2 format was being used unconditionally.
Nathan Scott [Fri, 25 Nov 2005 05:42:22 +0000 (16:42 +1100)]
[XFS] Fix a case where attr2 format was being used unconditionally.

SGI-PV: 941645
SGI-Modid: xfs-linux-melb:xfs-kern:24566a

Signed-off-by: Nathan Scott <nathans@sgi.com>
18 years ago[XFS] Tight loop in xfs_finish_reclaim_all prevented the xfslogd to run
Felix Blyakher [Fri, 25 Nov 2005 05:42:13 +0000 (16:42 +1100)]
[XFS] Tight loop in xfs_finish_reclaim_all prevented the xfslogd to run
its queue of IO completion callbacks, thus creating the deadlock between
umount and xfslogd. Breaking the loop solves the problem.

SGI-PV: 943821
SGI-Modid: xfs-linux-melb:xfs-kern:202363a

Signed-off-by: Felix Blyakher <felixb@sgi.com>
Signed-off-by: Nathan Scott <nathans@sgi.com>
18 years ago[XFS] Fix a 32 bit value wraparound when providing a mapping for a large
Nathan Scott [Fri, 25 Nov 2005 05:41:57 +0000 (16:41 +1100)]
[XFS] Fix a 32 bit value wraparound when providing a mapping for a large
direct write.

SGI-PV: 944820
SGI-Modid: xfs-linux-melb:xfs-kern:24351a

Signed-off-by: Nathan Scott <nathans@sgi.com>
18 years ago[XFS] handle error returns from freeze_bdev
Christoph Hellwig [Fri, 25 Nov 2005 05:41:47 +0000 (16:41 +1100)]
[XFS] handle error returns from freeze_bdev

SGI-PV: 945483
SGI-Modid: xfs-linux-melb:xfs-kern:201884a

Signed-off-by: Christoph Hellwig <hch@sgi.com>
Signed-off-by: Nathan Scott <nathans@sgi.com>
18 years ago[XFS] Fix potential overflow in xfs_iomap_t delta for very large extents
Eric Sandeen [Fri, 25 Nov 2005 05:41:33 +0000 (16:41 +1100)]
[XFS] Fix potential overflow in xfs_iomap_t delta for very large extents

SGI-PV: 945311
SGI-Modid: xfs-linux-melb:xfs-kern:201708a

Signed-off-by: Eric Sandeen <sandeen@sgi.com>
Signed-off-by: Nathan Scott <nathans@sgi.com>
18 years agoMerge master.kernel.org:/home/rmk/linux-2.6-arm
Linus Torvalds [Fri, 25 Nov 2005 02:41:59 +0000 (18:41 -0800)]
Merge master.kernel.org:/home/rmk/linux-2.6-arm

18 years ago[PATCH] fbcon: fix obvious bug in fbcon logo rotation code
Jasper Spaans [Thu, 24 Nov 2005 15:53:36 +0000 (16:53 +0100)]
[PATCH] fbcon: fix obvious bug in fbcon logo rotation code

This code fixes a tiny problem with the recent fbcon rotation changes:
fb_prepare_logo doesn't check the return value of fb_find_logo and that
causes a crash for my while booting.

Obvious & working & tested fix is here.

Signed-off-by: Jasper Spaans <jasper@vs19.net>
Acked-by: Antonino Daplas <adaplas@pol.net>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>