GitHub/mt8127/android_kernel_alcatel_ttab.git
16 years agoNFS: Fix a sillyrename race...
Trond Myklebust [Sat, 26 Jan 2008 22:37:47 +0000 (17:37 -0500)]
NFS: Fix a sillyrename race...

Ensure that readdir revalidates its data cache after blocking on
sillyrename.

Also fix a typo in nfs_do_call_unlink(): swap the ^= for an |=. The result
is the same, since we've already checked that the flag is unset, but it
makes the code more readable.

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
16 years agoMostly revert "e1000/e1000e: Move PCI-Express device IDs over to e1000e"
Linus Torvalds [Tue, 29 Jan 2008 22:54:54 +0000 (09:54 +1100)]
Mostly revert "e1000/e1000e: Move PCI-Express device IDs over to e1000e"

The new e1000e driver is apparently not yet suitable for general use, so
mark it experimental, and re-instate all the PCI-Express device IDs in
the old and stable e1000 driver so that people (namely me) can continue
to use a driver that actually works.

Auke & co have been appraised of the situation.

Cc: Auke Kok <auke-jan.h.kok@intel.com>
Cc: Jeff Garzik <jeff@garzik.org>
Cc: David Miller <davem@davemloft.net>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agosplice: fix problem with atime not being updated
Jens Axboe [Tue, 29 Jan 2008 20:05:57 +0000 (21:05 +0100)]
splice: fix problem with atime not being updated

A bug report on nfsd that states that since it was switched to use
splice instead of sendfile, the atime was no longer being updated
on the input file. do_generic_mapping_read() does this when accessing
the file, make splice do it for the direct splice handler.

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
16 years agoblock: constify function pointer tables
Jan Engelhardt [Tue, 29 Jan 2008 19:57:51 +0000 (20:57 +0100)]
block: constify function pointer tables

Signed-off-by: Jan Engelhardt <jengelh@computergmbh.de>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
16 years agocciss: fix bug in overriding ->data_len before completion
Jens Axboe [Tue, 29 Jan 2008 18:46:02 +0000 (19:46 +0100)]
cciss: fix bug in overriding ->data_len before completion

For BLOCK_PC requests, we need that length for completing the request.
Andrew Vasquez <andrew.vasquez@qlogic.com> reported the following
oops

Hitting a consistent BUG() with recent Linus' linux-2.6.git:

[   12.941428] ------------[ cut here ]------------
[   12.944874] kernel BUG at drivers/block/cciss.c:1260!
[   12.944874] invalid opcode: 0000 [1] SMP
[   12.944874] CPU 0
[   12.944874] Modules linked in:
[   12.944874] Pid: 0, comm: swapper Not tainted 2.6.24 #43
[   12.944874] RIP: 0010:[<ffffffff8039e43d>]  [<ffffffff8039e43d>] cciss_softirq_done+0xbc/0x1bf
[   12.944874] RSP: 0018:ffffffff8063aed0  EFLAGS: 00010202
[   12.944874] RAX: 0000000000000001 RBX: ffff8100cf800010 RCX: ffff81042f1253b0
[   12.944874] RDX: ffff81042de398f0 RSI: ffff81042de398f0 RDI: 0000000000000001
[   12.944874] RBP: ffff81042daa0000 R08: ffff81042f1253b0 R09: 0000000000000001
[   12.944874] R10: 00000000000000fe R11: 0000000000000000 R12: 0000000000000002
[   12.944874] R13: 0000000000000001 R14: ffff8100cf800000 R15: ffff81042de398f0
[   12.944874] FS:  0000000000000000(0000) GS:ffffffff805bb000(0000) knlGS:0000000000000000
[   12.944874] CS:  0010 DS: 0018 ES: 0018 CR0: 000000008005003b
[   12.944874] CR2: 00002afed7eea340 CR3: 000000042dbba000 CR4: 00000000000006e0
[   12.944874] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
[   12.944874] DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
[   12.944874] Process swapper (pid: 0, threadinfo ffffffff805f4000, task ffffffff805624a0)
[   12.944874] Stack:  0000000000000000 ffffffff8063af10 0000000000000001 ffffffff80632d60
[   12.944874]  0000000000000000 000000000000000a ffffffff805bb900 ffffffff8032038f
[   12.944874]  ffffffff8063af10 ffffffff8063af10 ffffffff805bb940 ffffffff802346b4
[   12.944874] Call Trace:
[   12.944874]  <IRQ>  [<ffffffff8032038f>] blk_done_softirq+0x69/0x78
[   12.944874]  [<ffffffff802346b4>] __do_softirq+0x6f/0xd8
[   12.944874]  [<ffffffff8020c45c>] call_softirq+0x1c/0x30
[   12.944874]  [<ffffffff8020e347>] do_softirq+0x30/0x80
[   12.944874]  [<ffffffff8020e409>] do_IRQ+0x72/0xd9
[   12.944874]  [<ffffffff8020a50a>] mwait_idle+0x0/0x46
[   12.944874]  [<ffffffff8020a3da>] default_idle+0x0/0x3d
[   12.944874]  [<ffffffff8020b7e1>] ret_from_intr+0x0/0xa
[   12.944874]  <EOI>  [<ffffffff8020a54c>] mwait_idle+0x42/0x46
[   12.944874]  [<ffffffff8020a481>] cpu_idle+0x6a/0xae
[   12.944874]
[   12.944874]
[   12.944874] Code: 0f 0b eb fe 48 8d 85 d8 c0 00 00 48 89 04 24 48 89 c7 e8 e5
[   12.944874] RIP  [<ffffffff8039e43d>] cciss_softirq_done+0xbc/0x1bf
[   12.944874]  RSP <ffffffff8063aed0>
[   12.944903] ---[ end trace e9c631603f90d22f ]---

which is caused by blk_end_request() returning 'not done' for a request,
since it gets asked to complete zero bytes.

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
16 years agoExpose hardware sector size
Martin K. Petersen [Tue, 29 Jan 2008 18:14:08 +0000 (19:14 +0100)]
Expose hardware sector size

Expose hardware sector size in sysfs queue directory.

Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
16 years agoFix blktrace compile warning
Martin K. Petersen [Tue, 29 Jan 2008 18:12:06 +0000 (19:12 +0100)]
Fix blktrace compile warning

request_queue_t is deprecated

Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
16 years agoblock: fix warning on compile with CONFIG_BLOCK
Jens Axboe [Tue, 29 Jan 2008 13:08:06 +0000 (14:08 +0100)]
block: fix warning on compile with CONFIG_BLOCK

struct io_context was not defined, just add an empty forward decl.

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
16 years agoblock: ll_rw_blk.c split, add blk-merge.c
Jens Axboe [Tue, 29 Jan 2008 13:04:06 +0000 (14:04 +0100)]
block: ll_rw_blk.c split, add blk-merge.c

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
16 years agoblock: remove dated (and wrong) comment in blk-core.c
Jens Axboe [Tue, 29 Jan 2008 12:55:40 +0000 (13:55 +0100)]
block: remove dated (and wrong) comment in blk-core.c

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
16 years agoblock: get rid of unnecessary forward declarations in blk-core.c
Jens Axboe [Tue, 29 Jan 2008 12:54:41 +0000 (13:54 +0100)]
block: get rid of unnecessary forward declarations in blk-core.c

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
16 years agoblock: continue ll_rw_blk.c splitup
Jens Axboe [Tue, 29 Jan 2008 13:53:40 +0000 (14:53 +0100)]
block: continue ll_rw_blk.c splitup

Adds files for barrier handling, rq execution, io context handling,
mapping data to requests, and queue settings.

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
16 years agoblock: split tag and sysfs handling from blk-core.c
Jens Axboe [Tue, 29 Jan 2008 13:51:59 +0000 (14:51 +0100)]
block: split tag and sysfs handling from blk-core.c

Seperates the tag and sysfs handling from ll_rw_blk.

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
16 years agoblock: first step of splitting ll_rw_blk, rename it
Jens Axboe [Tue, 29 Jan 2008 13:49:21 +0000 (14:49 +0100)]
block: first step of splitting ll_rw_blk, rename it

Then we retain history in blk-core.c

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
16 years agoxsysace: end request handling fix
Jens Axboe [Tue, 29 Jan 2008 20:54:53 +0000 (21:54 +0100)]
xsysace: end request handling fix

In ace_fsm_dostate(), the variable 'i' was used only for passing
sector size of the request to end_that_request_first().
So I removed it and changed the code to pass the size in bytes
directly to __blk_end_request()

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
16 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6.25
Linus Torvalds [Tue, 29 Jan 2008 11:54:01 +0000 (22:54 +1100)]
Merge git://git./linux/kernel/git/davem/net-2.6.25

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6.25: (1470 commits)
  [IPV6] ADDRLABEL: Fix double free on label deletion.
  [PPP]: Sparse warning fixes.
  [IPV4] fib_trie: remove unneeded NULL check
  [IPV4] fib_trie: More whitespace cleanup.
  [NET_SCHED]: Use nla_policy for attribute validation in ematches
  [NET_SCHED]: Use nla_policy for attribute validation in actions
  [NET_SCHED]: Use nla_policy for attribute validation in classifiers
  [NET_SCHED]: Use nla_policy for attribute validation in packet schedulers
  [NET_SCHED]: sch_api: introduce constant for rate table size
  [NET_SCHED]: Use typeful attribute parsing helpers
  [NET_SCHED]: Use typeful attribute construction helpers
  [NET_SCHED]: Use NLA_PUT_STRING for string dumping
  [NET_SCHED]: Use nla_nest_start/nla_nest_end
  [NET_SCHED]: Propagate nla_parse return value
  [NET_SCHED]: act_api: use PTR_ERR in tcf_action_init/tcf_action_get
  [NET_SCHED]: act_api: use nlmsg_parse
  [NET_SCHED]: act_api: fix netlink API conversion bug
  [NET_SCHED]: sch_netem: use nla_parse_nested_compat
  [NET_SCHED]: sch_atm: fix format string warning
  [NETNS]: Add namespace for ICMP replying code.
  ...

16 years agoMerge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus
Linus Torvalds [Tue, 29 Jan 2008 11:48:03 +0000 (22:48 +1100)]
Merge branch 'upstream' of git://ftp.linux-mips.org/upstream-linus

* 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus: (68 commits)
  [MIPS] remove Documentation/mips/GT64120.README
  [MIPS] Malta: remaining bits of the board support code cleanup
  [MIPS] Malta: make the helper function static
  [MIPS] Malta: fix braces at single statement blocks
  [MIPS] Malta, Atlas: move an extern function declaration to the header file
  [MIPS] Malta: Use C89 style for comments
  [MIPS] Malta: else should follow close brace in malta_int.c
  [MIPS] Malta: remove a superfluous comment
  [MIPS] Malta: include <linux/cpu.h> instead of <asm/cpu.h>
  [MIPS] Malta, Atlas, Sead: remove an extern from .c files
  [MIPS] Malta: fix oversized lines in malta_int.c
  [MIPS] Malta: remove a dead function declaration
  [MIPS] Malta: use tabs not spaces
  [MIPS] Malta: set up the screen info in a separate function
  [MIPS] Malta: check the PCI clock frequency in a separate function
  [MIPS] Malta: use the KERN_ facility level in printk()
  [MIPS] Malta: use Linux kernel style for structure initialization
  [MIPS]: constify function pointer tables
  [MIPS] compat: handle argument endianess of sys32_(f)truncate64 with merge_64
  [MIPS] Cobalt 64-bits kernels can be safely unmarked experimental
  ...

16 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild
Linus Torvalds [Tue, 29 Jan 2008 11:46:14 +0000 (22:46 +1100)]
Merge git://git./linux/kernel/git/sam/kbuild

* git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild: (79 commits)
  Remove references to "make dep"
  kconfig: document use of HAVE_*
  Introduce new section reference annotations tags: __ref, __refdata, __refconst
  kbuild: warn about ld added unique sections
  kbuild: add verbose option to Section mismatch reporting in modpost
  kconfig: tristate choices with mixed tristate and boolean values
  asm-generic/vmlix.lds.h: simplify __mem{init,exit}* dependencies
  remove __attribute_used__
  kbuild: support ARCH=x86 in buildtar
  kconfig: remove "enable"
  kbuild: simplified warning report in modpost
  kbuild: introduce a few helpers in modpost
  kbuild: use simpler section mismatch warnings in modpost
  kbuild: link vmlinux.o before kallsyms passes
  kbuild: introduce new option to enhance section mismatch analysis
  Use separate sections for __dev/__cpu/__mem code/data
  compiler.h: introduce __section()
  all archs: consolidate init and exit sections in vmlinux.lds.h
  kbuild: check section names consistently in modpost
  kbuild: introduce blacklisting in modpost
  ...

16 years agoMerge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux...
Linus Torvalds [Tue, 29 Jan 2008 11:45:39 +0000 (22:45 +1100)]
Merge branch 'master' of git://git./linux/kernel/git/rusty/linux-2.6-for-linus

* 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus:
  Module: check to see if we have a built in module with the same name
  module: add module taint on ndiswrapper
  module: fix the module name length in param_sysfs_builtin
  module: make module_address_lookup safe
  module: better OOPS and lockdep coverage for loading modules
  module: Fix gratuitous sprintf in module.c
  module: wait for dependent modules doing init.
  module: Don't report discarded init pages as kernel text.

16 years agoMerge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4
Linus Torvalds [Tue, 29 Jan 2008 11:43:38 +0000 (22:43 +1100)]
Merge branch 'for_linus' of git://git./linux/kernel/git/tytso/ext4

* 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4: (50 commits)
  jbd2: sparse pointer use of zero as null
  jbd2: Use round-jiffies() function for the "5 second" ext4/jbd2 wakeup
  jbd2: Mark jbd2 slabs as SLAB_TEMPORARY
  jbd2: add lockdep support
  ext4: Use the ext4_ext_actual_len() helper function
  ext4: fix uniniatilized extent splitting error
  ext4: Check for return value from sb_set_blocksize
  ext4: Add stripe= option to /proc/mounts
  ext4: Enable the multiblock allocator by default
  ext4: Add multi block allocator for ext4
  ext4: Add new functions for searching extent tree
  ext4: Add ext4_find_next_bit()
  ext4: fix up EXT4FS_DEBUG builds
  ext4: Fix ext4_show_options to show the correct mount options.
  ext4: Add EXT4_IOC_MIGRATE ioctl
  ext4: Add inode version support in ext4
  vfs: Add 64 bit i_version support
  ext4: Add the journal checksum feature
  jbd2: jbd2 stats through procfs
  ext4: Take read lock during overwrite case.
  ...

16 years ago[MIPS] remove Documentation/mips/GT64120.README
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:57 +0000 (19:52 +0300)]
[MIPS] remove Documentation/mips/GT64120.README

Based upon the 2.4 kernel, the information presented in the
Documentation/mips/GT64120.README file is outdated. Worse,
the document contents are plain misleading nowadays because
the text mentions files and directories, which have been
deleted, moved or restructured for 2.6.

This patch removes the documentation, which is no more valid.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Malta: remaining bits of the board support code cleanup
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:56 +0000 (19:52 +0300)]
[MIPS] Malta: remaining bits of the board support code cleanup

This patch factors out the code, which handles the Bonito system
controller. The case of not supporting the DMA coherency is handled
separately to make the logic obvious. Besides, a couple of empty
lines added to beautify the code even further.

No functional changes introduced.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Malta: make the helper function static
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:55 +0000 (19:52 +0300)]
[MIPS] Malta: make the helper function static

One helper function can become static. This patch adds the needed
keyword.

No functional changes introduced.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Malta: fix braces at single statement blocks
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:54 +0000 (19:52 +0300)]
[MIPS] Malta: fix braces at single statement blocks

This patch fixes a couple of warnings reported by checkpatch.pl.

No functional changes introduced.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Malta, Atlas: move an extern function declaration to the header file
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:53 +0000 (19:52 +0300)]
[MIPS] Malta, Atlas: move an extern function declaration to the header file

This was compile-tested using default configs for the boards
affected by this change.

This patch does not introduce any functional changes.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Malta: Use C89 style for comments
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:52 +0000 (19:52 +0300)]
[MIPS] Malta: Use C89 style for comments

Remove comments in C99 style and make checkpatch.pl happy.

No functional changes introduced.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Malta: else should follow close brace in malta_int.c
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:51 +0000 (19:52 +0300)]
[MIPS] Malta: else should follow close brace in malta_int.c

This patch fixes two errors reported by checkpatch.pl.

No functional changes introduced.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Malta: remove a superfluous comment
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:50 +0000 (19:52 +0300)]
[MIPS] Malta: remove a superfluous comment

Using the "We die here" comment right before calling the die()
function is an extremely vivid example of overcommenting.

Remove the redundant comment and save one line.

No functional changes introduced.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Malta: include <linux/cpu.h> instead of <asm/cpu.h>
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:49 +0000 (19:52 +0300)]
[MIPS] Malta: include <linux/cpu.h> instead of <asm/cpu.h>

The checkpatch.pl script reported a few warnings about header files.
This patch fixes these warnings.

Compile-tested using the default Malta config.

No functional changes introduced.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Malta, Atlas, Sead: remove an extern from .c files
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:48 +0000 (19:52 +0300)]
[MIPS] Malta, Atlas, Sead: remove an extern from .c files

This patch moves the "extern" declaration for the function
mips_reboot_setup() from the board setup .c files to the
header file include/asm-mips/mips-boards/generic.h.

This fixes a warning produced by the checkpatch.pl script.

No functional changes introduced.

This was compile-tested by building the kernel for all
three boards affected by this change. All builds finished
successfully.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Malta: fix oversized lines in malta_int.c
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:47 +0000 (19:52 +0300)]
[MIPS] Malta: fix oversized lines in malta_int.c

This patch fixes all "line over 80 characters" warnings found
in arch/mips/mips-boards/malta/malta_int.c by the checkpatch.pl
script.

No functional changes introduced.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Malta: remove a dead function declaration
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:46 +0000 (19:52 +0300)]
[MIPS] Malta: remove a dead function declaration

Neither is the mips_rtc_get_time() routine defined anywhere in
the MIPS architecture-specific code, nor does anyone call it any
more. This patch removes the extern declaration of this fossil.

This patch does not introduce any functional changes.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Malta: use tabs not spaces
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:45 +0000 (19:52 +0300)]
[MIPS] Malta: use tabs not spaces

This patch fixes all "use tabs not spaces" warnings reported by
the checkpatch.pl script on the board-specific files.

No functional changes introduced.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Malta: set up the screen info in a separate function
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:44 +0000 (19:52 +0300)]
[MIPS] Malta: set up the screen info in a separate function

This patch adds a separate short and sweet function to initialize
the screen_info global variable.

This improves readability of the Malta board setup code.

No functional changes introduced.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Malta: check the PCI clock frequency in a separate function
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:43 +0000 (19:52 +0300)]
[MIPS] Malta: check the PCI clock frequency in a separate function

This patch adds a separate short and sweet function to check the
PCI clock frequency. This is to improve readability of the Malta
setup code.

Along the way, a couple of coding style violations are fixed.

No functional changes introduced.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Malta: use the KERN_ facility level in printk()
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:42 +0000 (19:52 +0300)]
[MIPS] Malta: use the KERN_ facility level in printk()

This patch adds the KERN_ macros to printk() calls. Where applicable,
spaces are replaced by tabs.

These changes noticeably reduce the number of errors and warnings
reported by the checkpatch.pl script for the malta_int.c file.

Before the patch: total: 47 errors, 20 warnings, 354 lines checked

After the patch: total: 34 errors, 7 warnings, 355 lines checked

No functional changes introduced.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Malta: use Linux kernel style for structure initialization
Dmitri Vorobiev [Thu, 24 Jan 2008 16:52:41 +0000 (19:52 +0300)]
[MIPS] Malta: use Linux kernel style for structure initialization

This patch reformats the structure initialization code thus
making the latter look idiomatic.

No functional changes introduced.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS]: constify function pointer tables
Jan Engelhardt [Tue, 22 Jan 2008 19:42:33 +0000 (20:42 +0100)]
[MIPS]: constify function pointer tables

Signed-off-by: Jan Engelhardt <jengelh@computergmbh.de>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] compat: handle argument endianess of sys32_(f)truncate64 with merge_64
Ralf Baechle [Tue, 29 Jan 2008 10:15:02 +0000 (10:15 +0000)]
[MIPS] compat: handle argument endianess of sys32_(f)truncate64 with merge_64

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Cobalt 64-bits kernels can be safely unmarked experimental
Florian Fainelli [Tue, 15 Jan 2008 18:42:57 +0000 (19:42 +0100)]
[MIPS] Cobalt 64-bits kernels can be safely unmarked experimental

64-bits Cobalt kernels run fine.

Signed-off-by: Florian Fainelli <florian.fainelli@telecomint.eu>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Qemu: Remove platform.
Ralf Baechle [Tue, 29 Jan 2008 10:15:02 +0000 (10:15 +0000)]
[MIPS] Qemu: Remove platform.

The Qemu platform was originally implemented to have an easily supportable
platform until Qemu reaches a state where it emulates a real world system.
Since the latest release Qemu is capable of emulating the MIPSsim and
Malta platforms, so this goal has been reached.  The Qemu plaform is also
rather underfeatured so less useful than a Malta emulation.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] pnx8xxx: clocksource cleanups
Vitaly Wool [Sat, 12 Jan 2008 13:03:40 +0000 (16:03 +0300)]
[MIPS] pnx8xxx: clocksource cleanups

Signed-off-by: Vitaly Wool <vitalywool@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Lasat: Convert pvc_sem semaphore to mutex
Daniel Walker [Fri, 11 Jan 2008 04:53:21 +0000 (20:53 -0800)]
[MIPS] Lasat: Convert pvc_sem semaphore to mutex

I also changed the name to pvc_mutex, and moved the define to the file
it's used in which allows it to be static.

Signed-off-by: Daniel Walker <dwalker@mvista.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] MTX-1: Add GPIO system button
Florian Fainelli [Mon, 7 Jan 2008 18:00:46 +0000 (19:00 +0100)]
[MIPS] MTX-1: Add GPIO system button

This patch adds support for the GPIO connected system button on the MTX-1
boards. Default configuration is updated accordingly.

Signed-off-by: Florian Fainelli <florian.fainelli@telecomint.eu>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Delete CONFIG_MSP_FPGA
Ralf Baechle [Tue, 29 Jan 2008 10:15:01 +0000 (10:15 +0000)]
[MIPS] Delete CONFIG_MSP_FPGA

Originally noticed by Jiri Olsa <olsajiri@gmail.com>.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] move the eXcite local config to excitedirectory
Yoichi Yuasa [Wed, 12 Dec 2007 13:39:54 +0000 (22:39 +0900)]
[MIPS] move the eXcite local config to excitedirectory

Moved the eXcite local config to excite directory.

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] add cpu_wait() to machine_halt()
Yoichi Yuasa [Wed, 12 Dec 2007 13:23:13 +0000 (22:23 +0900)]
[MIPS] add cpu_wait() to machine_halt()

Added cpu_wait() to machine_halt().
For the power reduction in halt.

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] remove unneeded button check for reset
Yoichi Yuasa [Wed, 12 Dec 2007 13:20:19 +0000 (22:20 +0900)]
[MIPS] remove unneeded button check for reset

Removed unneeded button check for reset.
Because, the Cobalt has power switch.

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] move vr41xx_calculate_clock_frequency() to plat_time_init()
Yoichi Yuasa [Wed, 12 Dec 2007 13:11:09 +0000 (22:11 +0900)]
[MIPS] move vr41xx_calculate_clock_frequency() to plat_time_init()

Moved vr41xx_calculate_clock_frequency() to plat_time_init().
This function relates to the timer function.

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] time: remove unused mips_timer_state()
Yoichi Yuasa [Sun, 9 Dec 2007 12:19:36 +0000 (21:19 +0900)]
[MIPS] time: remove unused mips_timer_state()

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Altas, Malta: Switch boot file format to raw.
Ralf Baechle [Tue, 29 Jan 2008 10:15:00 +0000 (10:15 +0000)]
[MIPS] Altas, Malta: Switch boot file format to raw.

A raw binary boots about twice as fast as SREC.

The possibility to generate SREC binaries remains by simply using the
vmlinux.srec target but seems only useful for the probably hypothetical
case where one of these systems is booted over a serial interface.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] fixmap: delete unused __set_fixmap, set_fixmap and set_fixmap_nocache
Ralf Baechle [Tue, 29 Jan 2008 10:15:00 +0000 (10:15 +0000)]
[MIPS] fixmap: delete unused __set_fixmap, set_fixmap and set_fixmap_nocache

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Extend performance counter event field.
Ralf Baechle [Tue, 29 Jan 2008 10:14:59 +0000 (10:14 +0000)]
[MIPS] Extend performance counter event field.

The latest draft version of the MIPS Architecture Specification extends the
6 bit event field by adding a directly adjacent 4-bit EventExt field for a
total of 10 bits.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] RM: Collected changes
Thomas Bogendoerfer [Fri, 4 Jan 2008 22:31:07 +0000 (23:31 +0100)]
[MIPS] RM: Collected changes

- EISA support for non PCI RMs (RM200 and RM400-xxx). The major part
  is the splitting of the EISA and onboard ISA of the RM200, which
  makes the EISA bus on the RM200 look like on other RMs.
- 64bit kernel support
- system type detection is now common for big and little endian
- moved sniprom code to arch/mips/fw
- added call_o32 function to arch/mips/fw/lib, which uses a private
  stack for calling prom functions
- fix problem with ISA interrupts, which makes using PIT clockevent
  possible

Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Alchemy: Au1210/Au1250 CPU support
Manuel Lauss [Thu, 6 Dec 2007 08:07:55 +0000 (09:07 +0100)]
[MIPS] Alchemy: Au1210/Au1250 CPU support

This patch adds IDs for new Au1200 variants: Au1210 and Au1250.
They are essentially identical to the Au1200 except for the Au1210
which has a different SoC-ID in the PRId register [bits 31:24].
The Au1250 is a "Au1200 V0.2".

Signed-off-by: Manuel Lauss <mano@roarinelk.homelinux.net>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Eleminate local symbols from the symbol table.
Ralf Baechle [Tue, 29 Jan 2008 10:14:59 +0000 (10:14 +0000)]
[MIPS] Eleminate local symbols from the symbol table.

These symbols appear in oprofile output, stacktraces and similar but only
make the output harder to read.  Many identical symbol names such as
"both_aligned" were also being used in multiple source files making it
impossible to see which file actually was meant.  So let's get rid of them.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Fulong: don't reinitialize pci_probe_only to it's default value.
Ralf Baechle [Tue, 29 Jan 2008 10:14:59 +0000 (10:14 +0000)]
[MIPS] Fulong: don't reinitialize pci_probe_only to it's default value.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] BCM1480: Use constants instead of magic numbers in PCI code.
Ralf Baechle [Tue, 29 Jan 2008 10:14:59 +0000 (10:14 +0000)]
[MIPS] BCM1480: Use constants instead of magic numbers in PCI code.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] IP28 support
Thomas Bogendoerfer [Sun, 2 Dec 2007 12:00:32 +0000 (13:00 +0100)]
[MIPS] IP28 support

Add support for SGI IP28 machines (Indigo 2 with R10k CPUs)
This work is mainly based on Peter Fuersts work.

Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Remove CONFIG_SIBYTE_PT{1120,1125,SWARM}
Ralf Baechle [Tue, 29 Jan 2008 10:14:58 +0000 (10:14 +0000)]
[MIPS] Remove CONFIG_SIBYTE_PT{1120,1125,SWARM}

According to Broadcom the PT systems are production test systems which
never reached customers so no need to keep the fragmentary support we
currently have.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Use correct dma flushing in dma_cache_sync()
Thomas Bogendoerfer [Tue, 27 Nov 2007 18:31:33 +0000 (19:31 +0100)]
[MIPS] Use correct dma flushing in dma_cache_sync()

Not cache coherent R10k systems (like IP28) need to do real cache
invalidates in dma_cache_sync().

Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] IP28: added cache barrier to assembly routines
Thomas Bogendoerfer [Sun, 25 Nov 2007 10:47:56 +0000 (11:47 +0100)]
[MIPS] IP28: added cache barrier to assembly routines

IP28 needs special treatment to avoid speculative accesses. gcc
takes care for .c code, but for assembly code we need to do it
manually.

This is taken from Peter Fuersts IP28 patches.

Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] TXx9 watchdog support for rbhma3100,rbhma4200,rbhma4500
Atsushi Nemoto [Fri, 23 Nov 2007 16:20:27 +0000 (01:20 +0900)]
[MIPS] TXx9 watchdog support for rbhma3100,rbhma4200,rbhma4500

This patch adds support for txx9wdt driver to rbhma3100, rbhma4200 and
rbhma4500 platform.

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] IP22/IP28: fix extracting board/chip rev
Thomas Bogendoerfer [Sun, 25 Nov 2007 10:27:06 +0000 (11:27 +0100)]
[MIPS] IP22/IP28: fix extracting board/chip rev

Taken from Peter Fuersts IP28 patches

Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Use real cache invalidate
Thomas Bogendoerfer [Mon, 26 Nov 2007 22:40:01 +0000 (23:40 +0100)]
[MIPS] Use real cache invalidate

R10k non coherent machines need a real dma cache invalidate to get rid of
speculative stores in cache.  For other machines this promises a slight
speedup.

Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] SMP: Call platform methods via ops structure.
Ralf Baechle [Mon, 19 Nov 2007 12:23:51 +0000 (12:23 +0000)]
[MIPS] SMP: Call platform methods via ops structure.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Cleanup pcspeaker platform device registration.
Ralf Baechle [Tue, 29 Jan 2008 10:14:57 +0000 (10:14 +0000)]
[MIPS] Cleanup pcspeaker platform device registration.

Move registration into the actual platform code instead of making a
desparate attempt at sharing the hand full of likes of code in pcspeaker.c.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] MT: Scheduler support for SMT
Ralf Baechle [Fri, 2 Mar 2007 20:42:04 +0000 (20:42 +0000)]
[MIPS] MT: Scheduler support for SMT

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] tlbex.c: cleanup debug code
Franck Bui-Huu [Thu, 18 Oct 2007 07:11:17 +0000 (09:11 +0200)]
[MIPS] tlbex.c: cleanup debug code

Signed-off-by: Franck Bui-Huu <fbuihuu@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] tlbex.c: use __cacheline_aligned instead of __tlb_handler_align
Franck Bui-Huu [Thu, 18 Oct 2007 07:11:16 +0000 (09:11 +0200)]
[MIPS] tlbex.c: use __cacheline_aligned instead of __tlb_handler_align

Signed-off-by: Franck Bui-Huu <fbuihuu@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] tlbex.c: cleanup include files
Franck Bui-Huu [Thu, 18 Oct 2007 07:11:15 +0000 (09:11 +0200)]
[MIPS] tlbex.c: cleanup include files

Signed-off-by: Franck Bui-Huu <fbuihuu@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] tlbex.c: Cleanup __init usages.
Franck Bui-Huu [Thu, 18 Oct 2007 07:11:14 +0000 (09:11 +0200)]
[MIPS] tlbex.c: Cleanup __init usages.

Signed-off-by: Franck Bui-Huu <fbuihuu@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Delete now-unreferenced i2c-yosemite.h header file.
Robert P. J. Day [Tue, 6 Nov 2007 06:55:12 +0000 (01:55 -0500)]
[MIPS]  Delete now-unreferenced i2c-yosemite.h header file.

Given that the corresponding source file i2c-yosemite.c file was
removed in commit daa4a68f901c4d6491baa1a01f5c869a553c3f6c, and that
no one else includes this file, it seems safe to delete it.

Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Remove duplicate includes.
Lucas Woods [Mon, 5 Nov 2007 20:13:47 +0000 (07:13 +1100)]
[MIPS] Remove duplicate includes.

Signed-off-by: Lucas Woods <woodzy@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] ARC: Use strchr instead of strstr.
Roel Kluin [Fri, 2 Nov 2007 18:59:05 +0000 (19:59 +0100)]
[MIPS] ARC: Use strchr instead of strstr.

Use strchr instead of strstr when searching for a single character

Signed-off-by: Roel Kluin <12o3l@tiscali.nl>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Remove useless S-cache flushes.
Ralf Baechle [Tue, 29 Jan 2008 10:14:56 +0000 (10:14 +0000)]
[MIPS] Remove useless S-cache flushes.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Use pte_present instead of open coded test for _PAGE_PRESENT.
Ralf Baechle [Tue, 29 Jan 2008 10:14:55 +0000 (10:14 +0000)]
[MIPS] Use pte_present instead of open coded test for _PAGE_PRESENT.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Put cast inside macro instead of all the callers
Andrew Sharp [Wed, 31 Oct 2007 21:11:24 +0000 (14:11 -0700)]
[MIPS] Put cast inside macro instead of all the callers

Since all the callers of the PHYS_TO_XKPHYS macro call with a constant,
put the cast to LL inside the macro where it really should be rather
than in all the callers.  This makes macros like PHYS_TO_XKSEG_UNCACHED
work without gcc whining.

Signed-off-by: Andrew Sharp <andy.sharp@onstor.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] clean up au1xxx_irqmap.c include files
Yoichi Yuasa [Thu, 1 Nov 2007 12:35:39 +0000 (21:35 +0900)]
[MIPS] clean up au1xxx_irqmap.c include files

Clean up au1xxx_irqmap.c include files.

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] remove unused mips_machtype
Yoichi Yuasa [Fri, 26 Oct 2007 13:42:31 +0000 (22:42 +0900)]
[MIPS] remove unused mips_machtype

Removed unused mips_machtype.  These are only set but not used.

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] CFE: Make code remotely resemble Linux code.
Christoph Hellwig [Mon, 29 Oct 2007 14:23:43 +0000 (14:23 +0000)]
[MIPS] CFE: Make code remotely resemble Linux code.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] cleanup tx39/tx49 setup code
Atsushi Nemoto [Wed, 24 Oct 2007 14:16:56 +0000 (23:16 +0900)]
[MIPS] cleanup tx39/tx49 setup code

Remove some unnecessary codes, includes and files.

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] R4000/R4400 daddiu erratum workaround
Maciej W. Rozycki [Tue, 23 Oct 2007 11:43:25 +0000 (12:43 +0100)]
[MIPS] R4000/R4400 daddiu erratum workaround

 This complements the generic R4000/R4400 errata workaround code and adds
bits for the daddiu problem.  In most places it just modifies handwritten
assembly code so that the assembler is allowed to use a temporary register
as daddiu may now be treated as a macro that expands to a sequence of li
and daddu.  It is the AT register or, where AT is unavailable or used
explicitly for another purpose, an explicitly-named register is selected,
using the .set at=<reg> feature added recently to gas.  This feature is
only used if CONFIG_CPU_DADDI_WORKAROUNDS has been set, so if the
workaround remains disabled, the required version of binutils stays
unchanged.

 Similarly, daddiu instructions put in branch delay slots in noreorder
fragments are now taken out of them and the assembler is allowed to
reorder them itself as possible (which it does making the whole idea of
scheduling them into delay slots manually questionable).

 Also in the very few places where such a simple conversion was not
possible, a handcoded longer sequence is implemented.

 Other than that there are changes to code responsible for building the
TLB fault and page clear/copy handlers to avoid daddiu as appropriate.
These are only effective if the erratum is verified to be present at the
run time.

 Finally there is a trivial update to __delay(), because it uses daddiu in
a branch delay slot.

Signed-off-by: Maciej W. Rozycki <macro@linux-mips.org>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] R4000/R4400 errata workarounds
Maciej W. Rozycki [Tue, 23 Oct 2007 11:43:11 +0000 (12:43 +0100)]
[MIPS] R4000/R4400 errata workarounds

 This is the gereric part of R4000/R4400 errata workarounds.  They include
compiler and assembler support as well as some source code modifications
to address the problems with some combinations of multiply/divide+shift
instructions as well as the daddi and daddiu instructions.

 Changes included are as follows:

1. New Kconfig options to select workarounds by platforms as necessary.

2. Arch top-level Makefile to pass necessary options to the compiler; also
   incompatible configurations are detected (-mno-sym32 unsupported as
   horribly intrusive for little gain).

3. Bug detection updated and shuffled -- the multiply/divide+shift problem
   is lethal enough that if not worked around it makes the kernel crash in
   time_init() because of a division by zero; the daddiu erratum might
   also trigger early potentially, though I have not observed it.  On the
   other hand the daddi detection code requires the exception subsystem to
   have been initialised (and is there mainly for information).

4. r4k_daddiu_bug() added so that the existence of the erratum can be
   queried by code at the run time as necessary; useful for generated code
   like TLB fault and copy/clear page handlers.

5. __udelay() updated as it uses multiplication in inline assembly.

 Note that -mdaddi requires modified toolchain (which has been maintained
by myself and available from my site for ~4years now -- versions covered
are GCC 2.95.4 - 4.1.2 and binutils from 2.13 onwards).  The -mfix-r4000
and -mfix-r4400 have been standard for a while though.

Signed-off-by: Maciej W. Rozycki <macro@linux-mips.org>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Converting most array size calculations to use ARRAY_SIZE().
Alejandro Martinez Ruiz [Mon, 22 Oct 2007 19:36:44 +0000 (21:36 +0200)]
[MIPS] Converting most array size calculations to use ARRAY_SIZE().

Signed-off-by: Alejandro Martinez Ruiz <alex@flawedcode.org>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] tlbex: Cleanup handling of R2 hazards in TLB handlers.
Ralf Baechle [Tue, 29 Jan 2008 10:14:54 +0000 (10:14 +0000)]
[MIPS] tlbex: Cleanup handling of R2 hazards in TLB handlers.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Delete unused CONFIG_64BIT_CONTEXT
Ralf Baechle [Tue, 29 Jan 2008 10:14:54 +0000 (10:14 +0000)]
[MIPS] Delete unused CONFIG_64BIT_CONTEXT

The merge of the code to use this was never completed so delete it for the
time being.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Delete unused CONFIG_DMA_IP32.
Ralf Baechle [Tue, 29 Jan 2008 10:14:54 +0000 (10:14 +0000)]
[MIPS] Delete unused CONFIG_DMA_IP32.

The functionality of the former dma-ip32.c has been folded into
dma-default.c.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years agoModule: check to see if we have a built in module with the same name
Greg Kroah-Hartman [Sun, 27 Jan 2008 23:38:40 +0000 (15:38 -0800)]
Module: check to see if we have a built in module with the same name

When trying to load a module with the same name as a built-in one, a
scary kobject backtrace comes up.  Prevent that from checking for this
condition and warning the user as to what exactly is going on.

Cc: Rusty Russell <rusty@rustcorp.com.au>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
16 years agomodule: add module taint on ndiswrapper
Jon Masters [Mon, 21 Jan 2008 20:43:41 +0000 (20:43 +0000)]
module: add module taint on ndiswrapper

The struct module taints member is supposed to store per-module taint
data. The kernel knows about certain specific external modules that will
taint the kernel, such as ndiswrapper. Use of ndiswrapper possibly
should set the per-module taint in addition to the global kernel
taint flag, unless we're arguing not because wrapper module itself
is not what actually causes the kernel to be tainted as such?

Signed-off-by: Jon Masters <jcm@jonmasters.org>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
16 years agomodule: fix the module name length in param_sysfs_builtin
Denis Cheng [Mon, 21 Jan 2008 09:08:25 +0000 (17:08 +0800)]
module: fix the module name length in param_sysfs_builtin

the original code use KOBJ_NAME_LEN for built-in module name length,
that's defined to 20 in linux/kobject.h, but this is not enough appearntly,
many module names are longer than this;
 #define KOBJ_NAME_LEN                   20

another macro is MODULE_NAME_LEN defined in linux/module.h, I think this is
enough for module names:
 #define MODULE_NAME_LEN (64 - sizeof(unsigned long))

Signed-off-by: Denis Cheng <crquan@gmail.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
16 years agomodule: make module_address_lookup safe
Rusty Russell [Tue, 29 Jan 2008 22:13:22 +0000 (17:13 -0500)]
module: make module_address_lookup safe

module_address_lookup releases preemption then returns a pointer into
the module space.  The only user (kallsyms) copies the result, so just
do that under the preempt disable.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
16 years agomodule: better OOPS and lockdep coverage for loading modules
Rusty Russell [Tue, 29 Jan 2008 22:13:21 +0000 (17:13 -0500)]
module: better OOPS and lockdep coverage for loading modules

If we put the module in the linked list *before* calling into to, we
get the module name and functions in the OOPS (is_module_address can
find the module).  It also helps lockdep in a similar way.

Acked-and-tested-by: Joern Engel <joern@lazybastard.org>
Tested-by: Erez Zadok <ezk@cs.sunysb.edu>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
16 years agomodule: Fix gratuitous sprintf in module.c
Rusty Russell [Tue, 29 Jan 2008 22:13:20 +0000 (17:13 -0500)]
module: Fix gratuitous sprintf in module.c

Andrew sent an older version of this patch: we shouldn't use sprintf
to copy a string.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
16 years agomodule: wait for dependent modules doing init.
Rusty Russell [Tue, 29 Jan 2008 22:13:18 +0000 (17:13 -0500)]
module: wait for dependent modules doing init.

There have been reports of modules failing to load because the modules
they depend on are still loading.  This changes the modules to wait
for a reasonable length of time in that case.  We time out eventually,
because there can be module loops or broken modules.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
16 years agomodule: Don't report discarded init pages as kernel text.
Rusty Russell [Tue, 29 Jan 2008 22:13:17 +0000 (17:13 -0500)]
module: Don't report discarded init pages as kernel text.

Current code could cause a bug in symbol_put_addr() if an arch used
kmalloc module text: we might think the symbol belongs to the core
kernel.

The downside is that this might make backtraces through (discarded)
init functions harder to read on some archs, but we already have that
issue for modules and noone has complained.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
16 years agojbd2: sparse pointer use of zero as null
Mingming Cao [Tue, 29 Jan 2008 04:58:27 +0000 (23:58 -0500)]
jbd2: sparse pointer use of zero as null

Get rid of sparse related warnings from places that use integer as NULL
pointer.  (Ported from upstream ext3/jbd changes.)

Signed-off-by: Mingming Cao <cmm@us.ibm.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
16 years agojbd2: Use round-jiffies() function for the "5 second" ext4/jbd2 wakeup
Mingming Cao [Tue, 29 Jan 2008 04:58:27 +0000 (23:58 -0500)]
jbd2: Use round-jiffies() function for the "5 second" ext4/jbd2 wakeup

While "every 5 seconds" doesn't sound as a problem, there can be many
of these (and these timers do add up over all the kernel).  The "5
second" wakeup isn't really timing sensitive; in addition even with
rounding it'll still happen every 5 seconds (with the exception of the
very first time, which is likely to be rounded up to somewhere closer
to 6 seconds)

(Ported from similar JBD patch made by Arjan van de Ven to
fs/jbd/transaction.c)

Cc: Arjan van de Ven <arjan@linux.intel.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Mingming Cao <cmm@us.ibm.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
16 years agojbd2: Mark jbd2 slabs as SLAB_TEMPORARY
Mingming Cao [Tue, 29 Jan 2008 04:58:27 +0000 (23:58 -0500)]
jbd2: Mark jbd2 slabs as SLAB_TEMPORARY

This patch marks slab allocations by jbd2 as short-lived in support of
Mel Gorman's "Group short-lived and reclaimable kernel allocations"
patch.  (Ported from similar changes made to fs/jbd/journal.c and
fs/jbd/revoke.c in Mel's patch.)

Cc: Mel Gorman <mel@csn.ul.ie>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Mingming Cao <cmm@us.ibm.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
16 years agojbd2: add lockdep support
Mingming Cao [Tue, 29 Jan 2008 04:58:27 +0000 (23:58 -0500)]
jbd2: add lockdep support

Ported from similar patch for the jbd layer.

Signed-off-by: Mingming Cao <cmm@us.ibm.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>