openwrt/staging/blogic.git
17 years agodrivers/ misc __iomem annotations
Al Viro [Thu, 26 Jul 2007 16:36:09 +0000 (17:36 +0100)]
drivers/ misc __iomem annotations

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoxfs ioctl __user annotations
Al Viro [Thu, 26 Jul 2007 16:35:59 +0000 (17:35 +0100)]
xfs ioctl __user annotations

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agomake powerpc BUG_ON() OK with pointers and bitwise
Al Viro [Thu, 26 Jul 2007 16:35:49 +0000 (17:35 +0100)]
make powerpc BUG_ON() OK with pointers and bitwise

Since powerpc insists on printing the _value_ of condition
and on casting it to long...  At least let's make it a force-cast.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoamd64: fix get_user() on bitwise
Al Viro [Thu, 26 Jul 2007 16:35:39 +0000 (17:35 +0100)]
amd64: fix get_user() on bitwise

We really need force-cast when converting to final result type;
unsigned long can be silently converted to integer types and
to pointers, but not to bitwise.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agomake __chk_{user,io}_ptr() accept pointers to volatile
Al Viro [Thu, 26 Jul 2007 16:35:29 +0000 (17:35 +0100)]
make __chk_{user,io}_ptr() accept pointers to volatile

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agocxgb3 gfp_t annotations
Al Viro [Thu, 26 Jul 2007 16:35:19 +0000 (17:35 +0100)]
cxgb3 gfp_t annotations

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Acked-by: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agomisannotation in pppol2tp
Al Viro [Thu, 26 Jul 2007 16:35:09 +0000 (17:35 +0100)]
misannotation in pppol2tp

Address of auto variable is not a userland pointer.  A good thing, too,
since if pppol2tp_tunnel_getsockopt() would _really_ get a userland pointer
as argument, it would be an instant roothole...

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agocyclone.c: silly use of volatile, __iomem fixes
Al Viro [Thu, 26 Jul 2007 16:34:59 +0000 (17:34 +0100)]
cyclone.c: silly use of volatile, __iomem fixes

u32* volatile cyclone_timer means volatile auto pointer to u32,
which is clearly not what had been intended (we never even take
the address of that variable, let alone pass it to something that
could change it behind our back).  u32 volatile * is what the
authors apparently wanted to say, but in reality we don't need that
qualifier there at all - it's (properly) only passed to iomem helpers
which takes care of that stuff just fine.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agouse CLOCKSOURCE_MASK() instead of too large constant
Al Viro [Thu, 26 Jul 2007 16:34:49 +0000 (17:34 +0100)]
use CLOCKSOURCE_MASK() instead of too large constant

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoalpha: long constant
Al Viro [Thu, 26 Jul 2007 16:34:39 +0000 (17:34 +0100)]
alpha: long constant

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoia64 time.c: ANSIfy
Al Viro [Thu, 26 Jul 2007 16:34:29 +0000 (17:34 +0100)]
ia64 time.c: ANSIfy

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agodeal with alpha section warnings
Al Viro [Thu, 26 Jul 2007 16:34:19 +0000 (17:34 +0100)]
deal with alpha section warnings

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoviohs: extern on function definition
Al Viro [Thu, 26 Jul 2007 16:34:09 +0000 (17:34 +0100)]
viohs: extern on function definition

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoinitramfs: missing __init
Al Viro [Thu, 26 Jul 2007 16:33:59 +0000 (17:33 +0100)]
initramfs: missing __init

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agolockd and nfsd endianness annotation fixes
Al Viro [Thu, 26 Jul 2007 16:33:49 +0000 (17:33 +0100)]
lockd and nfsd endianness annotation fixes

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agonet/* misc endianness annotations
Al Viro [Thu, 26 Jul 2007 16:33:39 +0000 (17:33 +0100)]
net/* misc endianness annotations

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoip6_tunnel - endianness annotations
Al Viro [Thu, 26 Jul 2007 16:33:29 +0000 (17:33 +0100)]
ip6_tunnel - endianness annotations

Convert rel_info to host-endian before calling ip6_tnl_err().
The things become much more straightforward that way.
The key observation (and the reason why that code actually
worked) is that after ip6_tnl_err() we either immediately
bailed out or had rel_info set to 0 or had it set to host-endian
and guaranteed to hit
(rel_type == ICMP_DEST_UNREACH && rel_code == ICMP_FRAG_NEEDED)
case.  So inconsistent endianness didn't really lead to bugs,
but it had been subtle and prone to breakage.  New variant is
saner and obviously safe.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agonetfilter endian regressions
Al Viro [Thu, 26 Jul 2007 16:33:19 +0000 (17:33 +0100)]
netfilter endian regressions

no real bugs, just misannotations cropping up

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agosun userflash is PCI-dependent
Al Viro [Thu, 26 Jul 2007 16:33:09 +0000 (17:33 +0100)]
sun userflash is PCI-dependent

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agomore VIRT_TO_BUS dependencies
Al Viro [Thu, 26 Jul 2007 16:32:59 +0000 (17:32 +0100)]
more VIRT_TO_BUS dependencies

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agofix missing arguments in drivers/rtc/rtc-stk17ta8.c
Al Viro [Thu, 26 Jul 2007 16:32:49 +0000 (17:32 +0100)]
fix missing arguments in drivers/rtc/rtc-stk17ta8.c

struct bin_attribute * is needed in bin_attribute ->read()/->write()
now.  Incidentally, could people please run the fscking compiler
before and after applying their patch and compare the build logs?
That (and many, many other) would be caught immediately.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: use setup_irq() in 68328 timer code
Greg Ungerer [Thu, 26 Jul 2007 15:09:00 +0000 (01:09 +1000)]
m68knommu: use setup_irq() in 68328 timer code

Use setup_irq() instead of request_irq() to set up system timer
in 68328 timer code. With the old m68knommu irq code this
was safe, but it is not now within the generic irq framework.

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: use setup_irq() in ColdFire PIT timer
Greg Ungerer [Thu, 26 Jul 2007 15:09:00 +0000 (01:09 +1000)]
m68knommu: use setup_irq() in ColdFire PIT timer

Use setup_irq() instead of request_irq() to set up system timer
in ColdFire PIT timer code. With the old m68knommu irq code this
was safe, but it is not now within the generic irq framework.

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: remove unused mach_trap_init
Greg Ungerer [Thu, 26 Jul 2007 15:09:00 +0000 (01:09 +1000)]
m68knommu: remove unused mach_trap_init

Remove the unused mach_trap_init function pointer. All use of it
removed with change to using generic irq framework.

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: use setup_irq() in ColdFire simple timer
Greg Ungerer [Thu, 26 Jul 2007 15:09:00 +0000 (01:09 +1000)]
m68knommu: use setup_irq() in ColdFire simple timer

Use setup_irq() instead of request_irq() to set up system timer
in ColdFire simple timer code. With the old m68knommu irq code this
was safe, but it is not now within the generic irq framework.

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: remove use of colfire_trap_init
Greg Ungerer [Thu, 26 Jul 2007 15:09:00 +0000 (01:09 +1000)]
m68knommu: remove use of colfire_trap_init

The switch to using the generic irq framework removed the
coldfire_trap_init() code, so remove all references to it.

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: use setup_irq() in 68360 timer code
Greg Ungerer [Thu, 26 Jul 2007 15:09:00 +0000 (01:09 +1000)]
m68knommu: use setup_irq() in 68360 timer code

Use setup_irq() instead of request_irq() to set up system timer
in 68360 timer code. With the old m68knommu irq code this
was safe, but it is not now within the generic irq framework.

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: add prototype for ack_bad_irq
Greg Ungerer [Thu, 26 Jul 2007 15:09:00 +0000 (01:09 +1000)]
m68knommu: add prototype for ack_bad_irq

Create prototype for ack_bad_irq() for m68knommu.
Compilation of kernel/irq/handle.c fails without it.

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoMerge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux-2.6
Linus Torvalds [Wed, 25 Jul 2007 22:50:20 +0000 (15:50 -0700)]
Merge branch 'release' of git://git./linux/kernel/git/aegl/linux-2.6

* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux-2.6:
  [IA64] Nail two more simple section mismatch errors
  [IA64] fix section mismatch warnings
  [IA64] rename partial_page
  [IA64] Ensure that machvec is set up takes place before serial console
  [IA64] vector-domain - fix vector_table
  [IA64] vector-domain - handle assign_irq_vector(AUTO_ASSIGN)

17 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild
Linus Torvalds [Wed, 25 Jul 2007 22:49:59 +0000 (15:49 -0700)]
Merge git://git./linux/kernel/git/sam/kbuild

* git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild:
  kbuild: fix modpost warnings for xtensa
  kbuild: be more foregiving on init section naming
  kbuild: rearrange a few function in modpost
  kbuild: use LDFLAGS_MODULE only for .ko links
  kconfig: remove unused members from struct symbol
  kconfig: attach help text to menus
  kbuild: fix up printing of Linux C Library version in scripts/ver_linux
  kbuild: do not do section mismatch checks on vmlinux in 2nd pass

17 years agokbuild: fix modpost warnings for xtensa
Sam Ravnborg [Wed, 25 Jul 2007 20:24:52 +0000 (22:24 +0200)]
kbuild: fix modpost warnings for xtensa

The Xtensa architecture places literal pools in sections separate
from the instructions. The corresponsing text sections, therefore,
reference the .literal section, and we have to suppress those
warnings.

The naming convention defines the name for a literal
section as .SECTION.literal, unless .SECTION is .text. In that case
the name is only .literal. Using strncmp() instead of strcmp()
to compare the from-section with .SECTION.init.refok in pattern 0
should not cause any regressions for other architectures.

We also need to suppress warnings for two informational
sections (.xt.lit and .xt.prop) used by the Xtensa architecture.

Signed-off-by: Chris Zankel <chris@zankel.net>
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years ago[IA64] Nail two more simple section mismatch errors
Tony Luck [Fri, 20 Jul 2007 23:14:28 +0000 (16:14 -0700)]
[IA64] Nail two more simple section mismatch errors

pcibios_setup (between 'pci_setup' and 'quirk_mellanox_tavor')
setup_profiling_timer (between 'write_profile' and 'delayed_put_task_struct')

Signed-off-by: Tony Luck <tony.luck@intel.com>
17 years ago[IA64] fix section mismatch warnings
Tony Luck [Fri, 20 Jul 2007 21:39:24 +0000 (14:39 -0700)]
[IA64] fix section mismatch warnings

In 741f98fe298a73c9d47ed53703c1279a29718581 Sam added full
checking across the entire vmlinux image.  This flushed out
a dozen new section mismatch warnings.  Start the whack-a-mole
game again to stomp them out.

Signed-off-by: Tony Luck <tony.luck@intel.com>
17 years ago[IA64] rename partial_page
akpm@linux-foundation.org [Wed, 25 Jul 2007 02:44:55 +0000 (19:44 -0700)]
[IA64] rename partial_page

Jens has added a partial_page thing in splice whcih conflicts with the ia64
one.  Rename ia64 out of the way.  (ia64 chose poorly).

Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Tony Luck <tony.luck@intel.com>
17 years agokbuild: be more foregiving on init section naming
Sam Ravnborg [Wed, 25 Jul 2007 19:52:31 +0000 (21:52 +0200)]
kbuild: be more foregiving on init section naming

In the whitelist function of modpost now use the same
check to identify init_section as in other places of modpost.
This has the effect that we now recognize sections named
.init.text.19 as init sections and we no longer warn
when we see these.

At the same time make surrounding code readable by dropping
use of temporary flags.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agokbuild: rearrange a few function in modpost
Sam Ravnborg [Wed, 25 Jul 2007 19:46:40 +0000 (21:46 +0200)]
kbuild: rearrange a few function in modpost

This is a preparational patch that just move
two functions and add one (for now unused) function.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agokbuild: use LDFLAGS_MODULE only for .ko links
Roland McGrath [Mon, 23 Jul 2007 08:12:08 +0000 (01:12 -0700)]
kbuild: use LDFLAGS_MODULE only for .ko links

Sam Ravnborg pointed out that Documentation/kbuild/makefiles.txt already
says this is what it's for.  This patch makes the reality live up to the
documentation.  This fixes the problem of LDFLAGS_BUILD_ID getting into too
many places.

Signed-off-by: Roland McGrath <roland@redhat.com>
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agokconfig: remove unused members from struct symbol
Sam Ravnborg [Fri, 20 Jul 2007 22:05:26 +0000 (00:05 +0200)]
kconfig: remove unused members from struct symbol

dep and dep2 in struct symbol was unused - remove them.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Cc: Roman Zippel <zippel@linux-m68k.org>
17 years agokconfig: attach help text to menus
Sam Ravnborg [Fri, 20 Jul 2007 22:00:36 +0000 (00:00 +0200)]
kconfig: attach help text to menus

Roman Zippel wrote:
> A simple example would be
> help texts, right now they are per symbol, but they should really be per
> menu, so archs can provide different help texts for something.

This patch does this and at the same time introduce a few API
funtions used to access the help text.

The relevant api functions are introduced in the various frontends.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Cc: Roman Zippel <zippel@linux-m68k.org>
17 years agokbuild: fix up printing of Linux C Library version in scripts/ver_linux
Jesper Juhl [Fri, 20 Jul 2007 00:49:23 +0000 (02:49 +0200)]
kbuild: fix up printing of Linux C Library version in scripts/ver_linux

I noticed, when running scripts/ver_linux on both a Gentoo system
and a Slackware system, that the line printing the C library
version looked a little odd. So I fixed it up to be in line with
all the rest.

  Old output:
    Linux C Library        > libc.2.5
  New output:
    Linux C Library        2.5

Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com>
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agokbuild: do not do section mismatch checks on vmlinux in 2nd pass
Sam Ravnborg [Fri, 20 Jul 2007 20:36:56 +0000 (22:36 +0200)]
kbuild: do not do section mismatch checks on vmlinux in 2nd pass

We already check and warn about section mismatches from vmlinux
(build as vmlinux.o) during first pass so skip the checks
during the 2nd pass where we process modules.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years ago[x86 setup] Make struct apm_bios_info cross-architecture
H. Peter Anvin [Wed, 25 Jul 2007 18:06:02 +0000 (11:06 -0700)]
[x86 setup] Make struct apm_bios_info cross-architecture

struct apm_bios_info uses "unsigned short" and "unsigned long"
to mean u16 and u32 respectively.  Correct.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
17 years ago[x86 setup] Make struct ist_info cross-architecture, and use in setup code
H. Peter Anvin [Thu, 19 Jul 2007 00:19:30 +0000 (17:19 -0700)]
[x86 setup] Make struct ist_info cross-architecture, and use in setup code

Make "struct ist_info" valid on both i386 and x86-64, and use the
structure by name in the setup code.  Additionally, "Intel SpeedStep
IST" is redundant, refer to it as IST consistently.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
17 years ago[x86 setup] Fix typos in struct efi_info
H. Peter Anvin [Thu, 19 Jul 2007 00:16:19 +0000 (17:16 -0700)]
[x86 setup] Fix typos in struct efi_info

Fix missing letters in the structure members of struct efi_info.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
17 years ago[x86 setup] APM: BX should be zero when disconnecting
H. Peter Anvin [Mon, 23 Jul 2007 22:37:14 +0000 (15:37 -0700)]
[x86 setup] APM: BX should be zero when disconnecting

For APM calls, BX contains the device index, which is zero for
the system BIOS.  Disconnect requres BX = 0.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
17 years ago[x86 setup] APM detection logic bug fix
Mikael Pettersson [Mon, 23 Jul 2007 22:25:59 +0000 (00:25 +0200)]
[x86 setup] APM detection logic bug fix

Starting with kernel 2.6.23-rc1, the i386 APM driver fails
on several of my machines with the message:

apm: BIOS not found

This happens because of a bug in the i386 boot code rewrite
from assembler to C. The original assembly code had the
following code in its APM BIOS presence test (boot/setup.S):

andw $0x02, %cx # Is 32 bit supported?
je done_apm_bios # No 32-bit, no (good) APM BIOS

That is, the code bails out if bit 2 is zero.

In the new C version, this is coded as (boot/apm.c):

if (cx & 0x02) /* 32 bits supported? */
return -1;

Here we see that the test has been accidentally inverted.

The fix is to negate the test. I've verified that this
allows the APM driver to work again on my affected machines.

Signed-off-by: Mikael Pettersson <mikpe@it.uu.se>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
17 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris...
Linus Torvalds [Wed, 25 Jul 2007 18:28:19 +0000 (11:28 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/jmorris/selinux-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/selinux-2.6:
  SELinux: null-terminate context string in selinux_xfrm_sec_ctx_alloc

17 years agoMerge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux...
Linus Torvalds [Wed, 25 Jul 2007 18:28:00 +0000 (11:28 -0700)]
Merge branch 'release' of git://git./linux/kernel/git/lenb/linux-acpi-2.6

* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6:
  ACPI: Kconfig: remove CONFIG_ACPI_SLEEP from source
  ACPI: quiet ACPI Exceptions due to no _PTC or _TSS
  ACPI: Remove references to ACPI_STATE_S2 from acpi_pm_enter
  ACPI: Kconfig: always enable CONFIG_ACPI_SLEEP on X86
  ACPI: Kconfig: fold /proc/acpi/sleep under CONFIG_ACPI_PROCFS
  ACPI: Kconfig: CONFIG_ACPI_PROCFS now defaults to N
  ACPI: autoload modules - Create __mod_acpi_device_table symbol for all ACPI drivers
  ACPI: autoload modules - Create ACPI alias interface
  ACPI: autoload modules - ACPICA modifications
  ACPI: asus-laptop: Fix failure exits
  ACPI: fix oops due to typo in new throttling code
  ACPI: ignore _PSx method for hotplugable PCI devices
  ACPI: Use ACPI methods to select PCI device suspend state
  ACPI, PNP: hook ACPI D-state to PNP suspend/resume
  ACPI: Add acpi_pm_device_sleep_state helper routine
  ACPI: Implement the set_target() callback from pm_ops

17 years ago[IA64] Ensure that machvec is set up takes place before serial console
Horms [Wed, 25 Jul 2007 07:06:25 +0000 (16:06 +0900)]
[IA64] Ensure that machvec is set up takes place before serial console

Parse the machvec command line option outside of the early_param()
so that ia64_mv is set before any console intialisation that
may result from early_param parsing.

Signed-off-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Tony Luck <tony.luck@intel.com>
17 years ago[IA64] vector-domain - fix vector_table
Kenji Kaneshige [Wed, 25 Jul 2007 08:59:22 +0000 (17:59 +0900)]
[IA64] vector-domain - fix vector_table

Fix wrong access to vector_table[].

Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
17 years ago[IA64] vector-domain - handle assign_irq_vector(AUTO_ASSIGN)
Yasuaki Ishimatsu [Tue, 24 Jul 2007 13:09:09 +0000 (22:09 +0900)]
[IA64] vector-domain - handle assign_irq_vector(AUTO_ASSIGN)

This change fixes a panic when assign_irq_vector(irq) is called with
irq = AUTO_ASSIGN.

Signed-off-by: Yasuaki Ishimatsu <isimatu.yasuaki@jp.fujitsu.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
17 years agom68knommu: make BOOTPARAM setup common
Greg Ungerer [Wed, 25 Jul 2007 12:07:20 +0000 (22:07 +1000)]
m68knommu: make BOOTPARAM setup common

Currently most of the m68knommu cpu/board setup files are handling
the setup of fixed boot parameters (via CONFIG_BOOTPARAM) themselves.
Move all this into the common setup code.

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: fix reset register address casting
Greg Ungerer [Wed, 25 Jul 2007 12:07:20 +0000 (22:07 +1000)]
m68knommu: fix reset register address casting

Fix types used for reset register address setup.

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: add configure support for Intec boards
Greg Ungerer [Wed, 25 Jul 2007 12:07:20 +0000 (22:07 +1000)]
m68knommu: add configure support for Intec boards

Add configure support for the Intec Wildfire and WildFireMod boards.

Signed-Off-By: Steve Bennett <steveb@workware.net.au>
Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: simplify ColdFire resume code
Greg Ungerer [Wed, 25 Jul 2007 12:07:20 +0000 (22:07 +1000)]
m68knommu: simplify ColdFire resume code

It is useless to preserve THREAD_SR in `resume'.  The real user's sr
is actually in the stack.  We also don't need to disable interrupts :
we'll never be in an invalid state, the sp switch is atomic.

Signed-off-by: Philippe De Muyter <phdm@macqel.be>
Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: create hw_irq.h
Greg Ungerer [Wed, 25 Jul 2007 12:07:20 +0000 (22:07 +1000)]
m68knommu: create hw_irq.h

Need an include/asm-m68knommu/hw_irq.h for kernel/hrtimer.c

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: fix definition of MCFDMA_DIR_INV
Philippe De Muyter [Wed, 25 Jul 2007 12:07:20 +0000 (22:07 +1000)]
m68knommu: fix definition of MCFDMA_DIR_INV

Fix a small typo in the definition of MCFDMA_DIR_INV (MCF5272 specific).

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: add build support for more Arcturus boards
Greg Ungerer [Wed, 25 Jul 2007 12:07:20 +0000 (22:07 +1000)]
m68knommu: add build support for more Arcturus boards

Add build support for the new Arcturus boards.

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: need to include linux/device.h in dma.c
Greg Ungerer [Wed, 25 Jul 2007 12:07:20 +0000 (22:07 +1000)]
m68knommu: need to include linux/device.h in dma.c

Need to explicitly include linux/device.h.

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: fix tick timer definition for coldfire
Greg Ungerer [Wed, 25 Jul 2007 12:07:20 +0000 (22:07 +1000)]
m68knommu: fix tick timer definition for coldfire

CLOCK_TICK_RATE should give the underlying frequency of the tick timer,
to make ntp happy.  For Coldfires, that's the main clock.

Signed-off-by: Philippe De Muyter <phdm@macqel.be>
Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: add configure support for more Arcturus boards
David Wu [Wed, 25 Jul 2007 12:07:20 +0000 (22:07 +1000)]
m68knommu: add configure support for more Arcturus boards

Add configure support for the Arcturus UC5272 and UC5282 boards.

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: fix workqueues in 68328 serial driver
Greg Ungerer [Wed, 25 Jul 2007 12:07:20 +0000 (22:07 +1000)]
m68knommu: fix workqueues in 68328 serial driver

Fix workqueues in 68328 serial driver.

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agom68knommu: remove legacy power managament from 68328 serial driver
Greg Ungerer [Wed, 25 Jul 2007 12:07:20 +0000 (22:07 +1000)]
m68knommu: remove legacy power managament from 68328 serial driver

Remove the legacy power management code from the 68328 serial driver.
It is not used, and there is no current kernel support for power
management on the 68328.

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/avi/kvm
Linus Torvalds [Wed, 25 Jul 2007 18:01:10 +0000 (11:01 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/avi/kvm

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/avi/kvm:
  KVM: disable writeback for 0x0f 0x01 instructions.
  KVM: Fix removal of nx capability from guest cpuid
  Revert "KVM: Avoid useless memory write when possible"
  KVM: Fix unlikely kvm_create vs decache_vcpus_on_cpu race
  KVM: Correctly handle writes crossing a page boundary

17 years agoCache xtime every call to update_wall_time
john stultz [Wed, 25 Jul 2007 01:38:34 +0000 (18:38 -0700)]
Cache xtime every call to update_wall_time

This avoids xtime lag seen with dynticks, because while 'xtime' itself
is still not updated often, we keep a 'xtime_cache' variable around that
contains the approximate real-time that _is_ updated each time we do a
'update_wall_time()', and is thus never off by more than one tick.

IOW, this restores the original semantics for 'xtime' users, as long as
you use the proper abstraction functions (ie 'current_kernel_time()' or
'get_seconds()' depending on whether you want a timespec or just the
seconds field).

[ Updated Patch.  As penance for my sins I've also yanked another #ifdef
  that was added to avoid the xtime lag w/ hrtimers.  ]

Signed-off-by: John Stultz <johnstul@us.ibm.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoCleanup non-arch xtime uses, use get_seconds() or current_kernel_time().
john stultz [Wed, 25 Jul 2007 00:47:43 +0000 (17:47 -0700)]
Cleanup non-arch xtime uses, use get_seconds() or current_kernel_time().

This avoids use of the kernel-internal "xtime" variable directly outside
of the actual time-related functions.  Instead, use the helper functions
that we already have available to us.

This doesn't actually change any behaviour, but this will allow us to
fix the fact that "xtime" isn't updated very often with CONFIG_NO_HZ
(because much of the realtime information is maintained as separate
offsets to 'xtime'), which has caused interfaces that use xtime directly
to get a time that is out of sync with the real-time clock by up to a
third of a second or so.

Signed-off-by: John Stultz <johnstul@us.ibm.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoSELinux: null-terminate context string in selinux_xfrm_sec_ctx_alloc
Venkat Yekkirala [Tue, 24 Jul 2007 14:53:23 +0000 (09:53 -0500)]
SELinux: null-terminate context string in selinux_xfrm_sec_ctx_alloc

xfrm_audit_log() expects the context string to be null-terminated
which currently doesn't happen with user-supplied contexts.

Signed-off-by: Venkat Yekkirala <vyekkirala@TrustedCS.com>
Acked-by: Stephen Smalley <sds@tycho.nsa.gov>
Signed-off-by: James Morris <jmorris@namei.org>
17 years agoKVM: disable writeback for 0x0f 0x01 instructions.
Aurelien Jarno [Wed, 25 Jul 2007 08:19:54 +0000 (10:19 +0200)]
KVM: disable writeback for 0x0f 0x01 instructions.

0x0f 0x01 instructions (ie lgdt, lidt, smsw, lmsw and invlpg) does
not use writeback. This patch set no_wb=1 when emulating those
instructions.

This fixes a regression booting the FreeBSD kernel on AMD.

Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Signed-off-by: Avi Kivity <avi@qumranet.com>
17 years agoKVM: Fix removal of nx capability from guest cpuid
Avi Kivity [Wed, 25 Jul 2007 06:22:12 +0000 (09:22 +0300)]
KVM: Fix removal of nx capability from guest cpuid

Testing the wrong bit caused kvm not to disable nx on the guest when it is
disabled on the host (an mmu optimization relies on the nx bits being the
same in the guest and host).

This allows Windows to boot when nx is disabled on te host (e.g. when
host pae is disabled).

Signed-off-by: Avi Kivity <avi@qumranet.com>
17 years agoRevert "KVM: Avoid useless memory write when possible"
Avi Kivity [Mon, 23 Jul 2007 15:33:14 +0000 (18:33 +0300)]
Revert "KVM: Avoid useless memory write when possible"

This reverts commit a3c870bdce4d34332ebdba7eb9969592c4c6b243.  While it
does save useless updates, it (probably) defeats the fork detector, causing
a massive performance loss.

Signed-off-by: Avi Kivity <avi@qumranet.com>
17 years agoKVM: Fix unlikely kvm_create vs decache_vcpus_on_cpu race
Rusty Russell [Mon, 23 Jul 2007 07:08:21 +0000 (17:08 +1000)]
KVM: Fix unlikely kvm_create vs decache_vcpus_on_cpu race

We add the kvm to the vm_list before initializing the vcpu mutexes,
which can be mutex_trylock()'ed by decache_vcpus_on_cpu().

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Avi Kivity <avi@qumranet.com>
17 years agoKVM: Correctly handle writes crossing a page boundary
Avi Kivity [Sun, 22 Jul 2007 15:48:54 +0000 (18:48 +0300)]
KVM: Correctly handle writes crossing a page boundary

Writes that are contiguous in virtual memory may not be contiguous in
physical memory; so split writes that straddle a page boundary.

Thanks to Aurelien for reporting the bug, patient testing, and a fix
to this very patch.

Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Signed-off-by: Avi Kivity <avi@qumranet.com>
17 years agoPull auto-load-modules into release branch
Len Brown [Wed, 25 Jul 2007 05:36:53 +0000 (01:36 -0400)]
Pull auto-load-modules into release branch

17 years agoPull d-states into release branch
Len Brown [Wed, 25 Jul 2007 05:36:31 +0000 (01:36 -0400)]
Pull d-states into release branch

Conflicts:

drivers/acpi/sleep/main.c

Signed-off-by: Len Brown <len.brown@intel.com>
17 years agoPull kconfig into release branch
Len Brown [Wed, 25 Jul 2007 05:35:25 +0000 (01:35 -0400)]
Pull kconfig into release branch

17 years agoACPI: Kconfig: remove CONFIG_ACPI_SLEEP from source
Len Brown [Wed, 25 Jul 2007 02:26:33 +0000 (22:26 -0400)]
ACPI: Kconfig: remove CONFIG_ACPI_SLEEP from source

As it was a synonym for (CONFIG_ACPI && CONFIG_X86),
the ifdefs for it were more clutter than they were worth.

For ia64, just add a few stubs in anticipation of future
S3 or S4 support.

Signed-off-by: Len Brown <len.brown@intel.com>
17 years agoACPI: quiet ACPI Exceptions due to no _PTC or _TSS
Len Brown [Wed, 25 Jul 2007 04:57:46 +0000 (00:57 -0400)]
ACPI: quiet ACPI Exceptions due to no _PTC or _TSS

ACPI Exception (processor_throttling-0084): AE_NOT_FOUND, Evaluating _PTC [20070126]
ACPI Exception (processor_throttling-0147): AE_NOT_FOUND, Evaluating _TSS [20070126]

These methods are optional, so Linux should not
alarm users when they are not found.

http://bugzilla.kernel.org/show_bug.cgi?id=8802

Signed-off-by: Len Brown <len.brown@intel.com>
Acked-by: Luming Yu <luming.yu@intel.com>
17 years agoMerge branch 'for_paulus' of master.kernel.org:/pub/scm/linux/kernel/git/galak/powerpc
Linus Torvalds [Wed, 25 Jul 2007 03:26:25 +0000 (20:26 -0700)]
Merge branch 'for_paulus' of /linux/kernel/git/galak/powerpc

* 'for_paulus' of master.kernel.org:/pub/scm/linux/kernel/git/galak/powerpc: (25 commits)
  [POWERPC] 85xx: Added needed MPC85xx PCI device IDs
  [POWERPC] Add Freescale PCI VENDOR ID and 8641 device IDs
  [POWERPC] 85xxCDS: MPC8548 DTS cleanup.
  [POWERPC] 85xxCDS: Misc 8548 PCI Corrections.
  [POWERPC] 85xxCDS: Delay 8259 cascade hookup.
  [POWERPC] 85xxCDS: Make sure restart resets the PCI bus.
  [POWERPC] 85xxCDS: Allow 8259 cascade to share an MPIC interrupt line.
  [POWERPC] FSL: Add support for PCI-X controllers
  [POWERPC] Make sure virtual P2P bridge registers are setup on PCIe PHB
  [POWERPC] Provide ability to setup P2P bridge registers from struct resource
  [POWERPC] Add basic PCI/PCI Express support for 8544DS board
  [POWERPC] Make endianess of cfg_addr for indirect pci ops runtime
  [POWERPC] Removed setup_indirect_pci_nomap
  [POWERPC] 85xx: Add quirk to ignore bogus FPGA on CDS
  [POWERPC] 85xx: Added 8568 PCIe support
  [POWERPC] Fixup resources on pci_bus for PCIe PHB when no device is connected
  [POWERPC] Add basic PCI node for mpc8568mds board
  [POWERPC] Use Freescale pci/pcie common code for 85xx boards
  [POWERPC] Update PCI nodes in the 83xx/85xx boards device tree
  [POWERPC] Add 8548 CDS PCI express controller node and PCI-X device node
  ...

17 years agoocfs2: bad kunmap_atomic()
Jens Axboe [Tue, 24 Jul 2007 08:17:50 +0000 (10:17 +0200)]
ocfs2: bad kunmap_atomic()

kunmap_atomic() takes the virtual address, not the mapped page as
argument.

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Cc: Mark Fasheh <mark.fasheh@oracle.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoMerge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus
Linus Torvalds [Tue, 24 Jul 2007 23:00:26 +0000 (16:00 -0700)]
Merge branch 'upstream' of git://ftp.linux-mips.org/upstream-linus

* 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus:
  [MIPS] Fix marge error due to conflict in arch/mips/kernel/head.S
  [MIPS] ARC: Remove unused arch/mips/arc/console.c
  [MIPS] SNI: sniprom
  [MIPS] Jazz: remove unneeded reset functions
  [MIPS] Whitespace cleanup.
  [MIPS] Make resources for ds1742 "static __initdata"
  [MIPS] Replace __attribute_used__ with __used
  [MIPS] Jazz: Remove unused arch/mips/jazz/io.c
  [MIPS] Mark prom_free_prom_memory as __init_refok
  [MIPS] MIPSsim: Fix cflags

17 years agoMerge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik...
Linus Torvalds [Tue, 24 Jul 2007 22:58:51 +0000 (15:58 -0700)]
Merge branch 'upstream-linus' of /linux/kernel/git/jgarzik/libata-dev

* 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/libata-dev:
  pata_hpt37x: Fix 2.6.22 clock PLL regression
  pata_ali: Correct HP detect
  ata_piix: fix suspend/resume for some TOSHIBA laptops
  PCI: export __pci_reenable_device()

17 years agoMerge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik...
Linus Torvalds [Tue, 24 Jul 2007 22:58:15 +0000 (15:58 -0700)]
Merge branch 'upstream-linus' of /linux/kernel/git/jgarzik/netdev-2.6

* 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6: (26 commits)
  netdev: i82596 Ethernet needs <asm/cacheflush.h>
  forcedeth: mcp73 device addition
  forcedeth: new device ids in pci_ids.h
  atl1: make atl1_init_ring_ptrs static
  eHEA: net_poll support
  drivers/net/acenic.c: fix check-after-use
  defxx: Use __maybe_unused rather than a local hack
  Fix error checking in Vitesse IRQ config
  ps3: reduce allocation size of rx skb buffers
  atl1: use kernel provided ethernet length constants
  atl1: fix typo in dma_req_block
  atl1: change cmb write threshold
  atl1: fix typo in DMA engine setup
  atl1: change tpd_avail function name
  ps3: fix rare issue that reenabling rx DMA fails
  ps3: removed calling netif_poll_enable() in open()
  ps3: use ethX as the name of irq
  ps3: use net_device_stats of net_device structure
  ps3: removed conditional ethtool support
  ps3: removed defines no longer used
  ...

17 years agoMerge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6
Linus Torvalds [Tue, 24 Jul 2007 22:57:43 +0000 (15:57 -0700)]
Merge branch 'master' of /linux/kernel/git/davem/sparc-2.6

* 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6:
  [SPARC64]: Mark most of initial bootup asm as .text.init.ref_ok
  [SPARC32]: Fix bug in sparc optimized memset.
  [SPARC64]: Update defconfig.
  [SPARC]: Add missing NOTES section.
  [SPARC32]: missing exports
  [SPARC32]: Deal with rtc/sun_mostek_rtc conflict.

17 years agoMerge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Linus Torvalds [Tue, 24 Jul 2007 22:57:12 +0000 (15:57 -0700)]
Merge branch 'master' of /linux/kernel/git/davem/net-2.6

* 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6:
  [8021Q]: vlan_ioctl_handler: fix return value
  [GENETLINK]: Correctly report errors while registering a multicast group
  [GENETLINK]: Fix adjustment of number of multicast groups
  [GENETLINK]: Fix race in genl_unregister_mc_groups()
  [NETFILTER]: Clean up duplicate includes in net/netfilter/
  [NETFILTER]: Clean up duplicate includes in net/bridge/
  [NETFILTER]: Fix logging regression
  [TCPv6] MD5SIG: Ensure to reset allocation count to avoid panic.

17 years ago[8021Q]: vlan_ioctl_handler: fix return value
Andrew Morton [Tue, 24 Jul 2007 22:37:11 +0000 (15:37 -0700)]
[8021Q]: vlan_ioctl_handler: fix return value

net/8021q/vlan.c: In function 'vlan_ioctl_handler':
net/8021q/vlan.c:700: warning: 'err' may be used uninitialized in this function

The warning is incorrect, but from my reading this ioctl will return -EINVAL
on success.

Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years ago[GENETLINK]: Correctly report errors while registering a multicast group
Thomas Graf [Tue, 24 Jul 2007 22:34:53 +0000 (15:34 -0700)]
[GENETLINK]: Correctly report errors while registering a multicast group

Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years ago[GENETLINK]: Fix adjustment of number of multicast groups
Thomas Graf [Tue, 24 Jul 2007 22:33:51 +0000 (15:33 -0700)]
[GENETLINK]: Fix adjustment of number of multicast groups

The current calculation of the maximum number of genetlink
multicast groups seems odd, fix it.

Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years ago[GENETLINK]: Fix race in genl_unregister_mc_groups()
Thomas Graf [Tue, 24 Jul 2007 22:32:46 +0000 (15:32 -0700)]
[GENETLINK]: Fix race in genl_unregister_mc_groups()

family->mcast_groups is protected by genl_lock so it must
be held while accessing the list in genl_unregister_mc_groups().
Requires adding a non-locking variant of genl_unregister_mc_group().

Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years ago[NETFILTER]: Clean up duplicate includes in net/netfilter/
Jesper Juhl [Tue, 24 Jul 2007 22:31:05 +0000 (15:31 -0700)]
[NETFILTER]: Clean up duplicate includes in net/netfilter/

This patch cleans up duplicate includes in
net/netfilter/

Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years ago[NETFILTER]: Clean up duplicate includes in net/bridge/
Jesper Juhl [Tue, 24 Jul 2007 22:30:30 +0000 (15:30 -0700)]
[NETFILTER]: Clean up duplicate includes in net/bridge/

This patch cleans up duplicate includes in
net/bridge/

Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years ago[NETFILTER]: Fix logging regression
Patrick McHardy [Tue, 24 Jul 2007 22:29:55 +0000 (15:29 -0700)]
[NETFILTER]: Fix logging regression

Loading one of the LOG target fails if a different target has already
registered itself as backend for the same family. This can affect the
ipt_LOG and ipt_ULOG modules when both are loaded.

Reported and tested by: <t.artem@mailcity.com>

Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years ago[TCPv6] MD5SIG: Ensure to reset allocation count to avoid panic.
YOSHIFUJI Hideaki [Tue, 24 Jul 2007 22:27:30 +0000 (15:27 -0700)]
[TCPv6] MD5SIG: Ensure to reset allocation count to avoid panic.

After clearing all passwords for IPv6 peers, we need to
set allocation count to zero as well as we free the storage.
Otherwise, we panic when a user trys to (re)add a password.

Discovered and fixed by MIYAJIMA Mitsuharu <miyajima.mitsuharu@anchor.jp>.

Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years ago[SPARC64]: Mark most of initial bootup asm as .text.init.ref_ok
David S. Miller [Tue, 24 Jul 2007 22:17:33 +0000 (15:17 -0700)]
[SPARC64]: Mark most of initial bootup asm as .text.init.ref_ok

We can't mark the whole thing init because there are dependencies
in bootloaders that assume that _start, or whatever the image
entry value, is 2 instructions before the "HdrS" signature.

In fact, TILO assumes this entry is always at 0x4000, yikes!

Also, right after the bootloader info area there are OBP strings and
values that get used later in the boot process, and those are not all
provably .init yet.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopata_hpt37x: Fix 2.6.22 clock PLL regression
Alan Cox [Tue, 24 Jul 2007 14:17:48 +0000 (15:17 +0100)]
pata_hpt37x: Fix 2.6.22 clock PLL regression

Just one version of Linux ago
The PLL code broke - oh no!
But set the right mode
And fix up the code
Makes the PLL timing sync go

[whatever happened to the sailor from Nantucket, hero of many limericks?  -jg]

Closes-bug: #8791
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
17 years agopata_ali: Correct HP detect
Alan Cox [Fri, 20 Jul 2007 14:34:49 +0000 (15:34 +0100)]
pata_ali: Correct HP detect

Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
17 years agoata_piix: fix suspend/resume for some TOSHIBA laptops
Tejun Heo [Tue, 10 Jul 2007 06:55:43 +0000 (15:55 +0900)]
ata_piix: fix suspend/resume for some TOSHIBA laptops

ACPI implementations in several TOSHIBA laptops are weird and burn cpu
cycles for tens of seconds while trying to suspend if the PCI device
for the ATA controller is disabled when the ACPI suspend is called.

This patch uses DMI to match those machines and bypass device disable
on those machines during suspend.  As the device needs to be put into
enabled state on resume without affecting PCI enable count, matching
resume callback uses __pci_reenable_device().

This bug is reported in bugzilla bug 7780.

  http://bugzilla.kernel.org/show_bug.cgi?id=7780

Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
17 years agoPCI: export __pci_reenable_device()
Tejun Heo [Tue, 10 Jul 2007 06:36:05 +0000 (15:36 +0900)]
PCI: export __pci_reenable_device()

Some odd ACPI implementations choke if certain controller is disabled
when ACPI suspend is invoked but we still need to make sure the PCI
device is enabled during resume.  Simply using pci_enable_device()
unbalances device enable count.  Export __pci_reenable_device().

Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
17 years ago[SPARC32]: Fix bug in sparc optimized memset.
Alexander Shmelev [Tue, 24 Jul 2007 20:41:44 +0000 (13:41 -0700)]
[SPARC32]: Fix bug in sparc optimized memset.

Sparc optimized memset (arch/sparc/lib/memset.S) does not fill last
byte of the memory area, if area size is less than 8 bytes and start
address is not word (4-bytes) aligned.

Here is code chunk where bug located:
/* %o0 - memory address, %o1 - size, %g3 - value */
8:
     add    %o0, 1, %o0
    subcc    %o1, 1, %o1
    bne,a    8b
     stb %g3, [%o0 - 1]

This code should write byte every loop iteration, but last time delay
instruction stb is not executed because branch instruction sets
"annul" bit.

Patch replaces bne,a by bne instruction.

Error can be reproduced by simple kernel module:

--------------------
#include <linux/module.h>
#include <linux/config.h>
#include <linux/kernel.h>
#include <linux/errno.h>
#include <string.h>

static void do_memset(void **p, int size)
{
        memset(p, 0x00, size);
}

static int __init memset_test_init(void)
{
    char fooc[8];
    int *fooi;
    memset(fooc, 0xba, sizeof(fooc));

    do_memset((void**)(fooc + 3), 1);

    fooi = (int*) fooc;
    printk("%08X %08X\n", fooi[0], fooi[1]);

    return -1;
}

static void __exit memset_test_cleanup(void)
{
    return;
}

module_init(memset_test_init);
module_exit(memset_test_cleanup);

MODULE_LICENSE("GPL");
EXPORT_NO_SYMBOLS;
--------------------

Signed-off-by: Alexander Shmelev <ashmelev@task.sun.mcst.ru>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agonetdev: i82596 Ethernet needs <asm/cacheflush.h>
Geert Uytterhoeven [Fri, 20 Jul 2007 16:40:45 +0000 (18:40 +0200)]
netdev: i82596 Ethernet needs <asm/cacheflush.h>

netdev: i82596 Ethernet needs <asm/cacheflush.h> on m68k

drivers/net/82596.c: In function 'init_rx_bufs':
drivers/net/82596.c:552: error: implicit declaration of function 'cache_clear'
drivers/net/82596.c: In function 'i596_start_xmit':
drivers/net/82596.c:1104: error: implicit declaration of function 'cache_push'

The driver still compiles on ia32 (CONFIG_APRICOT=y)

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
17 years agoforcedeth: mcp73 device addition
Ayaz Abdulla [Mon, 23 Jul 2007 00:43:26 +0000 (20:43 -0400)]
forcedeth: mcp73 device addition

This patch contains new device settings for MCP73 chipset.

Signed-Off-By: Ayaz Abdulla <aabdulla@nvidia.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>