]> err.no Git - linux-2.6/log
linux-2.6
16 years agodlm: change error message to debug
David Teigland [Wed, 16 Jan 2008 17:03:41 +0000 (11:03 -0600)]
dlm: change error message to debug

The invalid lockspace messages are normal and can appear relatively
often.  They should be suppressed without debugging enabled.

Signed-off-by: David Teigland <teigland@redhat.com>
16 years agodlm: fix possible use-after-free
David Teigland [Mon, 14 Jan 2008 21:48:58 +0000 (15:48 -0600)]
dlm: fix possible use-after-free

The dlm_put_lkb() can free the lkb and its associated ua structure,
so we can't depend on using the ua struct after the put.

Signed-off-by: David Teigland <teigland@redhat.com>
16 years agodlm: limit dir lookup loop
David Teigland [Wed, 9 Jan 2008 16:37:39 +0000 (10:37 -0600)]
dlm: limit dir lookup loop

In a rare case we may need to repeat a local resource directory lookup
due to a race with removing the rsb and removing the resdir record.
We'll never need to do more than a single additional lookup, though,
so the infinite loop around the lookup can be removed.  In addition
to being unnecessary, the infinite loop is dangerous since some other
unknown condition may appear causing the loop to never break.

Signed-off-by: David Teigland <teigland@redhat.com>
16 years agodlm: reject normal unlock when lock is waiting for lookup
David Teigland [Wed, 9 Jan 2008 16:30:45 +0000 (10:30 -0600)]
dlm: reject normal unlock when lock is waiting for lookup

Non-forced unlocks should be rejected if the lock is waiting on the
rsb_lookup list for another lock to establish the master node.

Signed-off-by: David Teigland <teigland@redhat.com>
16 years agodlm: validate messages before processing
David Teigland [Wed, 9 Jan 2008 15:59:41 +0000 (09:59 -0600)]
dlm: validate messages before processing

There was some hit and miss validation of messages that has now been
cleaned up and unified.  Before processing a message, the new
validate_message() function checks that the lkb is the appropriate type,
process-copy or master-copy, and that the message is from the correct
nodeid for the the given lkb.  Other checks and assertions on the
lkb type and nodeid have been removed.  The assertions were particularly
bad since they would panic the machine instead of just ignoring the bad
message.

Although other recent patches have made processing old message unlikely,
it still may be possible for an old message to be processed and caught
by these checks.

Signed-off-by: David Teigland <teigland@redhat.com>
16 years agodlm: reject messages from non-members
David Teigland [Tue, 8 Jan 2008 22:24:00 +0000 (16:24 -0600)]
dlm: reject messages from non-members

Messages from nodes that are no longer members of the lockspace should be
ignored.  When nodes are removed from the lockspace, recovery can
sometimes complete quickly enough that messages arrive from a removed node
after recovery has completed.  When processed, these messages would often
cause an error message, and could in some cases change some state, causing
problems.

Signed-off-by: David Teigland <teigland@redhat.com>
16 years agodlm: another call to confirm_master in receive_request_reply
David Teigland [Tue, 8 Jan 2008 21:37:47 +0000 (15:37 -0600)]
dlm: another call to confirm_master in receive_request_reply

When a failed request (EBADR or ENOTBLK) is unlocked/canceled instead of
retried, there may be other lkb's waiting on the rsb_lookup list for it
to complete.  A call to confirm_master() is needed to move on to the next
waiting lkb since the current one won't be retried.

Signed-off-by: David Teigland <teigland@redhat.com>
16 years agodlm: recover locks waiting for overlap replies
David Teigland [Mon, 7 Jan 2008 22:15:05 +0000 (16:15 -0600)]
dlm: recover locks waiting for overlap replies

When recovery looks at locks waiting for replies, it fails to consider
locks that have already received a reply for their first remote operation,
but not received a reply for secondary, overlapping unlock/cancel.  The
appropriate stub reply needs to be called for these waiters.

Appears when we start doing recovery in the presence of a many overlapping
unlock/cancel ops.

Signed-off-by: David Teigland <teigland@redhat.com>
16 years agodlm: clear ast_type when removing from astqueue
David Teigland [Mon, 7 Jan 2008 21:55:18 +0000 (15:55 -0600)]
dlm: clear ast_type when removing from astqueue

The lkb_ast_type field indicates whether the lkb is on the astqueue list.
When clearing locks for a process, lkb's were being removed from the astqueue
list without clearing the field.  If release_lockspace then happened
immediately afterward, it could try to remove the lkb from the list a second
time.

Appears when process calls libdlm dlm_release_lockspace() which first
closes the ls dev triggering clear_proc_locks, and then removes the ls
(a write to control dev) causing release_lockspace().

Signed-off-by: David Teigland <teigland@redhat.com>
16 years agodlm: use fixed errno values in messages
David Teigland [Tue, 15 Jan 2008 21:43:24 +0000 (15:43 -0600)]
dlm: use fixed errno values in messages

Some errno values differ across platforms. So if we return things like
-EINPROGRESS from one node it can get misinterpreted or rejected on
another one.

This patch fixes up the errno values passed on the wire so that they
match the x86 ones (so as not to break the protocol), and re-instates
the platform-specific ones at the other end.

Many thanks to Fabio for testing this patch.
Initial patch from Patrick.

Signed-off-by: Patrick Caulfield <pcaulfie@redhat.com>
Signed-off-by: Fabio M. Di Nitto <fabbione@ubuntu.com>
Signed-off-by: David Teigland <teigland@redhat.com>
16 years agodlm: swap bytes for rcom lock reply
Fabio M. Di Nitto [Tue, 15 Jan 2008 21:13:36 +0000 (15:13 -0600)]
dlm: swap bytes for rcom lock reply

DLM_RCOM_LOCK_REPLY messages need byte swapping.

Signed-off-by: Fabio M. Di Nitto <fabbione@ubuntu.com>
Signed-off-by: David Teigland <teigland@redhat.com>
16 years agodlm: align midcomms message buffer
Fabio M. Di Nitto [Wed, 30 Jan 2008 16:56:42 +0000 (10:56 -0600)]
dlm: align midcomms message buffer

gcc does not guarantee that an auto buffer is 64bit aligned.
This change allows sparc64 to work.

Signed-off-by: Fabio M. Di Nitto <fabbione@ubuntu.com>
Signed-off-by: David Teigland <teigland@redhat.com>
16 years agodlm: close othercons
Patrick Caulfeld [Wed, 9 Jan 2008 15:06:27 +0000 (15:06 +0000)]
dlm: close othercons

This patch addresses a problem introduced with the last round of
lowcomms patches where the 'othercon' connections do not get freed when
the DLM shuts down.

This results in the error message
"slab error in kmem_cache_destroy(): cache `dlm_conn': Can't free all
objects"

and the DLM cannot be restarted without a system reboot.

See bz#428119

Signed-off-by: Patrick Caulfield <pcaulfie@redhat.com>
Signed-off-by: Fabio M. Di Nitto <fabbione@ubuntu.com>
Signed-off-by: David Teigland <teigland@redhat.com>
16 years agodlm: use dlm prefix on alloc and free functions
David Teigland [Wed, 7 Nov 2007 15:06:49 +0000 (09:06 -0600)]
dlm: use dlm prefix on alloc and free functions

The dlm functions in memory.c should use the dlm_ prefix.  Also, use
kzalloc/kfree directly for dlm_direntry's, removing the wrapper functions.

Signed-off-by: David Teigland <teigland@redhat.com>
16 years agodlm: don't print common non-errors
David Teigland [Wed, 7 Nov 2007 15:06:06 +0000 (09:06 -0600)]
dlm: don't print common non-errors

Change log_error() to log_debug() for conditions that can occur in
large number in normal operation.

Signed-off-by: David Teigland <teigland@redhat.com>
16 years agodlm: proper prototypes
Adrian Bunk [Sat, 3 Nov 2007 00:04:30 +0000 (01:04 +0100)]
dlm: proper prototypes

This patch adds a proper prototype for some functions in
fs/dlm/dlm_internal.h

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: David Teigland <teigland@redhat.com>
16 years agodlm: bind connections from known local address when using TCP
Lon Hohberger [Thu, 25 Oct 2007 22:51:54 +0000 (18:51 -0400)]
dlm: bind connections from known local address when using TCP

A common problem occurs when multiple IP addresses within the same
subnet are assigned to the same NIC.  If we make a connection attempt to
another address on the same subnet as one of those addresses, the
connection attempt will not necessarily be routed from the address we
want.

In the case of the DLM, the other nodes will quickly drop the connection
attempt, causing problems.

This patch makes the DLM bind to the local address it acquired from the
cluster manager when using TCP prior to making a connection, obviating
the need for administrators to "fix" their systems or use clever routing
tricks.

Signed-off-by: Lon Hohberger <lhh@redhat.com>
Signed-off-by: Patrick Caulfield <pcaulfie@redhat.com>
Signed-off-by: David Teigland <teigland@redhat.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.kernel.org/pub/scm/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/pub/scm/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.kernel.org/pub/scm/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.kernel.org/pub/scm/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.kernel.org/pub/scm/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>