Matt Fleming [Wed, 29 Oct 2008 07:16:02 +0000 (07:16 +0000)]
Define SCSPTR1 for SH 7751R
After the recent commit to kill off SCI/SCIF special casing SH 7751R
fails to compile with CONFIG_SH_RTS7751R2D set. This is because SCSPTR1
is undefined. Take the value for SCSPTR1 from the SH7751R Group Hardware
Manual.
Signed-off-by: Matt Fleming <mjf@gentoo.org>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Nobuhiro Iwamatsu [Wed, 29 Oct 2008 04:33:45 +0000 (13:33 +0900)]
sh: Add sci_rxd_in of SH4-202
SH4-202 doesn't have SCSXX1. But it is treated so that there is SCSPTR1 in
current code. This patch add sci_rxd_in of SH4-202.
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu.nobuhiro@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Kuninori Morimoto [Thu, 30 Oct 2008 05:49:03 +0000 (14:49 +0900)]
Add support usb setting on sh 7366
This patch add usb setting for sh 7366
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Nobuhiro Iwamatsu [Wed, 29 Oct 2008 04:34:50 +0000 (13:34 +0900)]
sh: Change register name SCSPTR to SCSPTR2
This change a name of SCSPTR used in sci_rxd_in of SH5-101.
SCSPTR is not declared and will become the error.
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu.nobuhiro@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Harvey Harrison [Fri, 31 Oct 2008 07:01:22 +0000 (16:01 +0900)]
sh: use the new byteorder headers.
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Paul Mundt [Fri, 31 Oct 2008 06:58:53 +0000 (15:58 +0900)]
sh: SHmedia ISA tuning fixups.
SH-5 doesn't support any elaborate ISA inheritance schemes (-dsp, -up,
etc.), so only bother with that if we are building an sh32 kernel.
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Paul Mundt [Tue, 28 Oct 2008 11:07:44 +0000 (20:07 +0900)]
sh: Kill off long-dead HD64465 cchip support.
This code has been dead for many years. The last update it received
was in 2003 in order to update it for the driver model changes, though
it had already been in disarray and unused before that point. The only
boards that ever used this chip have not had users in many years either,
so it is finally safe to just kill it off and move on with life.
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Paul Mundt [Tue, 28 Oct 2008 10:45:47 +0000 (19:45 +0900)]
sh: Revert "SH 7366 needs SCIF_ONLY"
This reverts commit
5ca8c4852fcbbc8a8497c4ee8b2a0a7466f3524c.
With the killing off of SCIF_ONLY and its spawn in sh-sci, we no longer
require this change, so just revert it.
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Paul Mundt [Tue, 28 Oct 2008 10:44:15 +0000 (19:44 +0900)]
Merge branches 'sh/serial-rework' and 'sh/oprofile'
Paul Mundt [Tue, 28 Oct 2008 10:37:05 +0000 (19:37 +0900)]
sh: Simplify and lock down the ISA tuning.
The ISA tuning as it is today can not cope with all of the different
variations that are possible, so all we can do is a best attempt based on
the CPU family. The DSP and FPU generation are already at odds with each
other, and the nommu tuning we weren't handling at all. Additionally,
for platforms that never had an FPU, the -nofpu variant never existed,
meaning that we would lose out on family granular tuning completely in
certain cases.
With tat out of the way, we were also using -up versions, allowing for
later instructions that branched off of a particular subset of the ISA,
but are not actually reflected on the hardware being targetted. This
leads to some confusion, and the possibility of bogus instructions on
older parts. Kill that off and lock it down to the family being built
for specifically.
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Paul Mundt [Tue, 28 Oct 2008 09:50:00 +0000 (18:50 +0900)]
sh: sh7785lcr: Select uImage as default image target.
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Paul Mundt [Tue, 28 Oct 2008 09:40:19 +0000 (18:40 +0900)]
sh: Add on-chip RTC support for SH7722.
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Kuninori Morimoto [Tue, 28 Oct 2008 06:33:48 +0000 (15:33 +0900)]
SH 7366 needs SCIF_ONLY
SH 7366 has compile bug.
because there is no SCIF_ONLY for SH 7366.
this patch add it.
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Nobuhiro Iwamatsu [Mon, 27 Oct 2008 02:32:27 +0000 (11:32 +0900)]
gdrom: Fix compile error
Return value and argument of block_device_operations.release of gdrom
was changed.
This patch fix this problem.
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Acked-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Kuninori Morimoto [Tue, 28 Oct 2008 08:36:11 +0000 (17:36 +0900)]
sh: Provide a sample defconfig for the UL2 (SH7366) board.
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Paul Mundt [Tue, 28 Oct 2008 08:19:35 +0000 (17:19 +0900)]
sh: Fix FPU tuning on toolchains with mismatched multilib targets.
Presently there is very little standing in the way of using an SH-4
toolchain for building an SH-2 kernel, and vice versa. Binutils itself
has no limitations whatsoever and supports explicit ISA hinting, which
we already use with varying degrees of success today.
This leaves GCC as the odd one out, due to a rather dubious policy
decision by the GCC folks to not include all of the CPU family variants
in the default list of multilib targets in GCC4. Despite best efforts to
the contrary, libgcc itself already contains awareness of the various CPU
types and remains generally usable, allowing it to safely be referenced
even on a mismatched target (and indeed, explicit ISA tuning by binutils
keeps us honest in terms of ensuring that we do not link incompatible
objects in).
In order to support this, a couple of changes had to be made. Firstly,
the introduction of MAYBE_DECLARE_EXPORT(), which provides a __weak
extern reference for libgcc resident routines when finer-grained
-m<cpu-family> based tuning is not supported by the toolchain. This
fixes up the __sdivsi3_i4i and __udivsi3_i4i references when dealing
with SH-2 kernels linked with an SH-4 libgcc. Secondly, in case where we
are unable to find a suitable match for CPU family tuning but still
have a toolchain that defaults to FP instruction generation, a suitable
nofpu target must be selected. This is accomplished by selecting the
first nofpu multilib target supported by the toolchain, which is
also necessary for selecting the proper libgcc to link against.
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Linus Torvalds [Mon, 27 Oct 2008 18:41:51 +0000 (11:41 -0700)]
Merge branch 'for-linus' of git://git.kernel.dk/linux-2.6-block
* 'for-linus' of git://git.kernel.dk/linux-2.6-block:
libata: fix NCQ devices behind port multipliers
scsi: make sure that scsi_init_shared_tag_map() doesn't overwrite existing map
Jens Axboe [Mon, 27 Oct 2008 18:23:06 +0000 (19:23 +0100)]
libata: fix NCQ devices behind port multipliers
For devices behind sata port multipliers, we have to make sure that
they share a tag map since all tags for that PMP must be unique.
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Jens Axboe [Mon, 27 Oct 2008 18:20:59 +0000 (19:20 +0100)]
scsi: make sure that scsi_init_shared_tag_map() doesn't overwrite existing map
Right now callers have to check whether scsi_host->bqt is already
set up, it's much cleaner to just have scsi_init_shared_tag_map()
does this check on its own.
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Linus Torvalds [Mon, 27 Oct 2008 16:54:23 +0000 (09:54 -0700)]
Merge branch 'upstream' of git://ftp.linux-mips.org/upstream-linus
* 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus: (33 commits)
MIPS: lemote/lm2e: Added io_map_base to pci controller
MIPS: TXx9: Make firmware parameter passing more robust
MIPS: Markeins: Remove unnecessary define and cleanup comments, etc.
MIPS: Markeins: Extract ll_emma2rh_* functions
MIPS: Markeins: Remove runtime debug prints
MIPS: EMMA: Fold arch/mips/emma/{common,markeins}/irq*.c into markeins/irq.c
MIPS: EMMA2RH: Remove emma2rh_gpio_irq_base
MIPS: EMMA2RH: Remove emma2rh_sw_irq_base
MIPS: EMMA2RH: Remove emma2rh_irq_base global variable
MIPS: EMMA2RH: Remove emma2rh_sync on read operation
MIPS: EMMA: Move <asm/emma2rh> to <asm/emma> dir
MIPS: EMMA: Move arch/mips/emma2rh/ into arch/mips/emma/
MIPS: EMMA: Kconfig reorganization
MIPS: Add CONFIG_CPU_R5500 for NEC VR5500 series processors
MIPS: RB532: Disable the right device
MIPS: Add support for NXP PNX833x (STB222/5) into linux kernel
MIPS: TXx9: CONFIG_TOSHIBA_RBTX4939 spelling
MIPS: Fix KGDB build error
INPUT: sgi_btns: Add license specification
MIPS: IP22: ip22-int.c header file weeding.
...
Linus Torvalds [Mon, 27 Oct 2008 16:37:16 +0000 (09:37 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/ieee1394/linux1394-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6:
firewire: fw-sbp2: fix races
firewire: fw-sbp2: delay first login to avoid retries
firewire: fw-ohci: initialization failure path fixes
firewire: fw-ohci: don't leak dma memory on module removal
firewire: fix struct fw_node memory leak
firewire: Survive more than 256 bus resets
Linus Torvalds [Mon, 27 Oct 2008 16:36:33 +0000 (09:36 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/tiwai/sound-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
ALSA: ASoC: Blackfin: update SPORT0 port selector (v2)
ALSA: hda - Restore default pin configs for realtek codecs
sound: use a common working email address
pci: use pci_ioremap_bar() in sound/
Zhang Le [Mon, 27 Oct 2008 23:33:24 +0000 (23:33 +0000)]
MIPS: lemote/lm2e: Added io_map_base to pci controller
Signed-off-by: Zhang Le <r0bertz@gentoo.org>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Geert Uytterhoeven [Mon, 27 Oct 2008 14:25:49 +0000 (15:25 +0100)]
MIPS: TXx9: Make firmware parameter passing more robust
When booting Linux on a txx9 board with VxWorks boot loader, it crashes in
prom_getenv(), as VxWorks doesn't pass firmware parameters in a0-a3 (in my
case, the actual leftover values in these registers were 0x80002000,
0x80001fe0, 0x2000, and 0x20).
Make the parsing of argc, argv, and envp a bit more robust by checking if
argc is a number below CKSEG0, and argv/envp point to CKSEG0.
Signed-off-by: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
Acked-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Shinya Kuribayashi [Thu, 23 Oct 2008 16:36:33 +0000 (01:36 +0900)]
MIPS: Markeins: Remove unnecessary define and cleanup comments, etc.
Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi@necel.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Shinya Kuribayashi [Thu, 23 Oct 2008 16:35:59 +0000 (01:35 +0900)]
MIPS: Markeins: Extract ll_emma2rh_* functions
These functions are completely ineffective.
Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi@necel.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Shinya Kuribayashi [Thu, 23 Oct 2008 16:33:10 +0000 (01:33 +0900)]
MIPS: Markeins: Remove runtime debug prints
Remove runtime db_* macros as we don't need them any more. In general,
such helpers are useful for initial porting, but once approved, they are
not indispensable.
Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi@necel.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Shinya Kuribayashi [Thu, 23 Oct 2008 16:32:40 +0000 (01:32 +0900)]
MIPS: EMMA: Fold arch/mips/emma/{common,markeins}/irq*.c into markeins/irq.c
Current EMMA2RH irq code is mess. Before cleaning it up, gather them
in one place as a first step.
Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi@necel.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Shinya Kuribayashi [Thu, 23 Oct 2008 16:32:11 +0000 (01:32 +0900)]
MIPS: EMMA2RH: Remove emma2rh_gpio_irq_base
Let's use immediate value, instead. This also saves memory footprint,
and probably a little bit faster.
Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi@necel.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Shinya Kuribayashi [Thu, 23 Oct 2008 16:31:43 +0000 (01:31 +0900)]
MIPS: EMMA2RH: Remove emma2rh_sw_irq_base
Let's use immediate value, instead. This also saves memory footprint,
and probably a little bit faster.
Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi@necel.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Shinya Kuribayashi [Thu, 23 Oct 2008 16:31:16 +0000 (01:31 +0900)]
MIPS: EMMA2RH: Remove emma2rh_irq_base global variable
Let's use immediate value, instead. This also saves memory footprint,
and probably a little bit faster.
Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi@necel.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Shinya Kuribayashi [Thu, 23 Oct 2008 16:30:48 +0000 (01:30 +0900)]
MIPS: EMMA2RH: Remove emma2rh_sync on read operation
It's totally a waste of CPU cycles.
Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi@necel.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Shinya Kuribayashi [Thu, 23 Oct 2008 16:30:20 +0000 (01:30 +0900)]
MIPS: EMMA: Move <asm/emma2rh> to <asm/emma> dir
We'll put all EMMA related headers there in the future.
Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi@necel.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Shinya Kuribayashi [Thu, 23 Oct 2008 16:29:16 +0000 (01:29 +0900)]
MIPS: EMMA: Move arch/mips/emma2rh/ into arch/mips/emma/
git mv arch/mips/{emma2rh,emma} and fixups Makefiles. We'll put all NEC
EMMA series based machines there in the future.
Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi@necel.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Shinya Kuribayashi [Thu, 23 Oct 2008 21:00:01 +0000 (06:00 +0900)]
MIPS: EMMA: Kconfig reorganization
- Move EMMA related stuff into arch/mips/emma/Kconfig
- Create CONFIG_SOC_EMMA* to handle more EMMA SoCs effectively
- Rename CONFIG_MARKEINS into CONFIG_NEC_MARKEINS
Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi@necel.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Shinya Kuribayashi [Thu, 23 Oct 2008 16:27:57 +0000 (01:27 +0900)]
MIPS: Add CONFIG_CPU_R5500 for NEC VR5500 series processors
We already have sufficient infrastructure to support VR5500 and VR5500A
series processors. Here's a Makefile support to make it selectable by
ports, and enable it for NEC EMMA2RH Markeins board.
This patch also fixes a confused target help, and adds 1Gb PageMask bits
supported by VR5500 and its variants.
Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi@necel.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Phil Sutter [Mon, 27 Oct 2008 01:29:57 +0000 (02:29 +0100)]
MIPS: RB532: Disable the right device
Signed-off-by: Florian Fainelli <florian@openwrt.org>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Daniel Laird [Mon, 16 Jun 2008 14:49:21 +0000 (15:49 +0100)]
MIPS: Add support for NXP PNX833x (STB222/5) into linux kernel
The following patch add support for the NXP PNX833x SOC. More
specifically it adds support for the STB222/5 variant. It fixes
the vectored interrupt issue.
Signed-off-by: daniel.j.laird <daniel.j.laird@nxp.com>
Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Geert Uytterhoeven [Thu, 23 Oct 2008 14:43:13 +0000 (16:43 +0200)]
MIPS: TXx9: CONFIG_TOSHIBA_RBTX4939 spelling
Fix a typo in the comment for the TOSHIBA_RBTX4939 config option
Signed-off-by: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
Acked-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Yoichi Yuasa [Sat, 25 Oct 2008 08:30:35 +0000 (17:30 +0900)]
MIPS: Fix KGDB build error
In file included from include/linux/ptrace.h:49,
from arch/mips/kernel/kgdb.c:25:
/home/yuasa/src/linux/test/mips/linux/arch/mips/include/asm/ptrace.h:123: error: expected declaration specifiers or '...' before '__s64'
/home/yuasa/src/linux/test/mips/linux/arch/mips/include/asm/ptrace.h:124: error: expected declaration specifiers or '...' before '__s64'
/home/yuasa/src/linux/test/mips/linux/arch/mips/include/asm/ptrace.h:126: error: expected declaration specifiers or '...' before '__u32'
/home/yuasa/src/linux/test/mips/linux/arch/mips/include/asm/ptrace.h:127: error: expected declaration specifiers or '...' before '__u32'
make[1]: *** [arch/mips/kernel/kgdb.o] Error 1
Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Dmitri Vorobiev [Fri, 24 Oct 2008 22:46:57 +0000 (01:46 +0300)]
INPUT: sgi_btns: Add license specification
The SGI Volume Button interface driver uses GPL-only symbols
platform_driver_unregister and platform_driver_register, but
lacks license specification. Thus, when compiled as a module,
this driver cannot be installed. This patch fixes this by
adding the MODULE_LICENSE() specification.
Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@movial.fi>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Ralf Baechle [Sat, 25 Oct 2008 14:51:48 +0000 (15:51 +0100)]
MIPS: IP22: ip22-int.c header file weeding.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Dmitri Vorobiev [Fri, 24 Oct 2008 22:46:56 +0000 (01:46 +0300)]
MIPS: IP22: Small cleanups
The following functions
disable_local1_irq()
disable_local2_irq()
disable_local3_irq()
are needlessly defined global, so make them static. While at it, fix a
whitespace error in the same file.
Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@movial.fi>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Atsushi Nemoto [Mon, 20 Oct 2008 15:01:06 +0000 (00:01 +0900)]
MIPS: RBTX4939: Add smc91x support
Add smc91x platform device to RBTX4939 board and some hacks for big endian.
Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Atsushi Nemoto [Mon, 20 Oct 2008 14:28:50 +0000 (23:28 +0900)]
MIPS: TXx9: 7 segment LED support
Add sysfs interface for 7 segment LED and implement access routine for
RBTX4939.
Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Manuel Lauss [Tue, 21 Oct 2008 06:59:14 +0000 (08:59 +0200)]
MIPS: Alchemy: Wire up SD controller on DB/PB1200 boards.
Add au1xmmc platform data for PB1200/DB1200 boards and wire up the 2 SD
controllers for them.
Signed-off-by: Manuel Lauss <mano@roarinelk.homelinux.net>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Florian Fainelli [Fri, 24 Oct 2008 17:53:55 +0000 (19:53 +0200)]
MIPS: RB532: Set gpio interrupt status and level for CompactFlash
This patch sets the correct interrupt status and level
in order to get the CompactFlash adapter working.
Signed-off-by: Florian Fainelli <florian@openwrt.org>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Adrian Bunk [Sun, 12 Oct 2008 13:01:35 +0000 (16:01 +0300)]
MIPS: RB532: Fix build error
mips/pci/fixup-rc32434.c must #include <asm/mach-rc32434/irq.h>
This patch fixes the following compile error caused by
commit
606a083b1e1a357cb66454e4581b80f1a67d8368
(MIPS: RB532: Cleanup the headers again):
<-- snip -->
...
CC arch/mips/pci/fixup-rc32434.o
arch/mips/pci/fixup-rc32434.c: In function 'pcibios_map_irq':
arch/mips/pci/fixup-rc32434.c:46: error: 'GROUP4_IRQ_BASE' undeclared (first use in this function)
arch/mips/pci/fixup-rc32434.c:46: error: (Each undeclared identifier is reported only once
arch/mips/pci/fixup-rc32434.c:46: error: for each function it appears in.)
make[2]: *** [arch/mips/pci/fixup-rc32434.o] Error 1
<-- snip -->
A virtually identical patch was also submitted by Yoichi Yuasa
<yoichi_yuasa@tripeaks.co.jp>.
Signed-off-by: Adrian Bunk <bunk@kernel.org>
Acked-by: Florian Fainelli <florian@openwrt.org>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
David Daney [Fri, 24 Oct 2008 16:31:13 +0000 (09:31 -0700)]
MIPS: Fix KGDB build error
<asm/ptrace.h> is exported to userland so can't include <linux/ptrace.h>,
so replace the C99 types with their basic C type equivalents.
Bug originally reported and initial patch by Yoichi Yuasa
<yoichi_yuasa@tripeaks.co.jp>.
Signed-off-by: David Daney <ddaney@caviumnetworks.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Atsushi Nemoto [Fri, 24 Oct 2008 16:17:23 +0000 (01:17 +0900)]
MIPS: Set ENOSYS to errno on illegal system call number for syscall(2)
Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Atsushi Nemoto [Fri, 24 Oct 2008 16:17:22 +0000 (01:17 +0900)]
MIPS: Set positive error number to errno on illegal_syscall
Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Ralf Baechle [Sat, 18 Oct 2008 12:23:10 +0000 (13:23 +0100)]
MIPS: SMP: Don't reenable interrupts in stop_this_cpu; use WAIT instruction.
Noticed by Anirban Sinha <ASinha@zeugmasystems.com>; patch by me.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
David Daney [Sat, 18 Oct 2008 00:48:53 +0000 (17:48 -0700)]
MIPS: Don't unmap the memory for dma_sync*.
We were getting away with this for so long only because the only platform
with a non-empty plat_unmap_dma_mem() doesn't call dma_sync_sg_for_cpu()
and dma_sync_sg_for_device() from its commonly used drivers.
Signed-off-by: David Daney <ddaney@caviumnetworks.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Zhaolei [Fri, 17 Oct 2008 11:12:35 +0000 (19:12 +0800)]
MIPS: Fix debugfs_create_*'s error checking method for mips/kernel/
debugfs_create_*() returns NULL on error. Make its callers return -ENODEV
on error.
Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com>
Acked-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Zhaolei [Fri, 17 Oct 2008 11:12:30 +0000 (19:12 +0800)]
MIPS: Fix debugfs_create_*'s error checking method for arch/mips/math-emu/
debugfs_create_*() returns NULL on error. Make its caller debugfs_fpuemu
return -ENODEV on error.
Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Takashi Iwai [Mon, 27 Oct 2008 16:08:11 +0000 (17:08 +0100)]
Merge branches 'topic/fix/asoc', 'topic/fix/hda', 'topic/fix/misc' and 'topic/pci-ioremap-bar' into for-linus
Cliff Cai [Mon, 27 Oct 2008 09:09:25 +0000 (17:09 +0800)]
ALSA: ASoC: Blackfin: update SPORT0 port selector (v2)
- Setting the TFS pin selector for SPORT 0 based on whether the selected
port id F or G. If the port is F then no conflict should exist for the
TFS. When Port G is selected and EMAC then there is a conflict between
the PHY interrupt line and TFS. Current settings prevent the conflict
by ignoring the TFS pin when Port G is selected. This allows both
ssm2602 using Port G and EMAC concurrently.
- some code cleanup
Signed-off-by: Cliff Cai <cliff.cai@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Mon, 27 Oct 2008 15:56:24 +0000 (16:56 +0100)]
ALSA: hda - Restore default pin configs for realtek codecs
Some machines have broken BIOS resume that doesn't restore the default
pin configuration properly, which results in a wrong detection of HP
pin. This causes a silent speaker output due to missing HP detection.
Related bug: Novell bug#406101
https://bugzilla.novell.com/show_bug.cgi?id=406101
This patch fixes the issue by saving/restoring the default pin configs
by the driver itself.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Linus Torvalds [Mon, 27 Oct 2008 15:41:13 +0000 (08:41 -0700)]
Merge git://git./linux/kernel/git/davem/net-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6:
syncookies: fix inclusion of tcp options in syn-ack
libertas: free sk_buff with kfree_skb
btsdio: free sk_buff with kfree_skb
Phonet: do not reply to indication reset packets
Phonet: include generic link-layer header size in MAX_PHONET_HEADER
Alan Cox [Mon, 27 Oct 2008 15:19:48 +0000 (15:19 +0000)]
Switch to a valid email address...
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Alan Cox [Mon, 27 Oct 2008 15:10:23 +0000 (15:10 +0000)]
Tidy up addresses in random drivers
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Eric Miao [Mon, 27 Oct 2008 09:48:50 +0000 (17:48 +0800)]
leds: da903x: fix the building failure of incomplete type of 'work'
The leds-da903x LED driver was missing the proper #include of
linux/workqueue.h, but happened to compile on ARM due to implied
includes through other header files.
We do need the explict include on other architectures (reported at least
for x86-64).
Reported-tested-and-acked-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Alan Cox [Mon, 27 Oct 2008 15:21:19 +0000 (15:21 +0000)]
sound: use a common working email address
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Florian Westphal [Mon, 27 Oct 2008 06:10:12 +0000 (23:10 -0700)]
syncookies: fix inclusion of tcp options in syn-ack
David Miller noticed that commit
33ad798c924b4a1afad3593f2796d465040aadd5 '(tcp: options clean up')
did not move the req->cookie_ts check.
This essentially disabled commit
4dfc2817025965a2fc78a18c50f540736a6b5c24
'[Syncookies]: Add support for TCP options via timestamps.'.
This restores the original logic.
Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
Sergio Luis [Mon, 27 Oct 2008 06:09:27 +0000 (23:09 -0700)]
libertas: free sk_buff with kfree_skb
free sk_buff with kfree_skb, instead of kree
Signed-off-by: Sergio Luis <sergio@larces.uece.br>
Signed-off-by: David S. Miller <davem@davemloft.net>
Sergio Luis [Mon, 27 Oct 2008 06:08:48 +0000 (23:08 -0700)]
btsdio: free sk_buff with kfree_skb
free sk_buff with kfree_skb, instead of kree
Signed-off-by: Sergio Luis <sergio@larces.uece.br>
Signed-off-by: David S. Miller <davem@davemloft.net>
Remi Denis-Courmont [Mon, 27 Oct 2008 06:07:25 +0000 (23:07 -0700)]
Phonet: do not reply to indication reset packets
This fixes a potential error packet loop.
Signed-off-by: Remi Denis-Courmont <remi.denis-courmont@nokia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Remi Denis-Courmont [Mon, 27 Oct 2008 06:06:31 +0000 (23:06 -0700)]
Phonet: include generic link-layer header size in MAX_PHONET_HEADER
This fixes an OOPS in hard_header if a Phonet address is assigned to a
non-Phonet network interface.
Signed-off-by: Remi Denis-Courmont <remi.denis-courmont@nokia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Paul Mundt [Fri, 24 Oct 2008 05:30:51 +0000 (14:30 +0900)]
sh: oprofile: Fix up the SH7750 performance counter name.
Rather than varying this on a subtype level, we use the counter type as a
generic identifier. This simplifies logic in the userspace tools where no
fundamental difference exists across the various subtypes.
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Linus Torvalds [Sun, 26 Oct 2008 23:42:18 +0000 (16:42 -0700)]
Merge branch 'for-linus' of git://neil.brown.name/md
* 'for-linus' of git://neil.brown.name/md:
md: allow extended partitions on md devices.
md: use sysfs_notify_dirent to notify changes to md/dev-xxx/state
md: use sysfs_notify_dirent to notify changes to md/array_state
Linus Torvalds [Sun, 26 Oct 2008 23:40:59 +0000 (16:40 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/dtor/input
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
Input: psmouse - add support for Elantech touchpads
Input: i8042 - add Blue FB5601 to noloop exception table
Linus Torvalds [Sun, 26 Oct 2008 23:37:37 +0000 (16:37 -0700)]
Merge branch 'for-linus' of git://git.o-hand.com/linux-mfd
* 'for-linus' of git://git.o-hand.com/linux-mfd:
mfd: Make WM8400 depend on I2C until SPI is submitted
mfd: add missing Kconfig entry for da903x
Linus Torvalds [Sun, 26 Oct 2008 23:35:41 +0000 (16:35 -0700)]
Merge branch 'for-upstream' of git://git./linux/kernel/git/dvrabel/uwb
* 'for-upstream' of git://git.kernel.org/pub/scm/linux/kernel/git/dvrabel/uwb:
uwb: build UWB before USB/WUSB
Linus Torvalds [Sun, 26 Oct 2008 23:34:14 +0000 (16:34 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/jikos/hid
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid:
HID: Add support for Sony Vaio VGX-TP1E
HID: fix lock imbalance in hiddev
HID: fix lock imbalance in hidraw
HID: fix hidbus/appletouch device binding regression
HID: add hid_type to general hid struct
HID: quirk for OLED devices present in ASUS G50/G70/G71
HID: Remove "default m" for Thrustmaster and Zeroplus
HID: fix hidraw_exit section mismatch
HID: add support for another Gyration remote control
Revert "HID: Invert HWHEEL mappings for some Logitech mice"
Randy Dunlap [Sun, 26 Oct 2008 00:24:36 +0000 (17:24 -0700)]
docbooks: fix fatal filename errors
Fix docbook fatal errors (file location changed):
docproc: lin2628-rc1/include/asm-x86/io_32.h: No such file or directory
make[1]: *** [Documentation/DocBook/deviceiobook.xml] Error 1
docproc: lin2628-rc1/include/asm-x86/atomic_32.h: No such file or directory
make[1]: *** [Documentation/DocBook/kernel-api.xml] Error 1
docproc: lin2628-rc1/include/asm-x86/mca_dma.h: No such file or directory
make[1]: *** [Documentation/DocBook/mcabook.xml] Error 1
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Randy Dunlap [Sun, 26 Oct 2008 00:06:43 +0000 (17:06 -0700)]
kernel-doc: allow more whitespace in macros
Allow macros that are annotated with kernel-doc to contain whitespace
between the '#' and "define". It's valid and being used, so allow it.
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Linus Torvalds [Sun, 26 Oct 2008 23:29:12 +0000 (16:29 -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:
leds-hp-disk: fix build warning
ACPI: Oops in ACPI with git latest
ACPI suspend: build fix for ACPI_SLEEP=n && XEN_SAVE_RESTORE=y.
toshiba_acpi: always call input_sync() after input_report_switch()
ACPI: Always report a sync event after a lid state change
ACPI: cpufreq, processor: fix compile error in drivers/acpi/processor_perflib.c
i7300_idle: Fix compile warning CONFIG_I7300_IDLE_IOAT_CHANNEL not defined
i7300_idle: Cleanup based review comments
i7300_idle: Disable ioat channel only on platforms where ile driver can load
Linus Torvalds [Sun, 26 Oct 2008 19:13:29 +0000 (12:13 -0700)]
Linux 2.6.28-rc2
.. fix all the worst problems in -rc1
Geert Uytterhoeven [Sun, 26 Oct 2008 18:51:14 +0000 (19:51 +0100)]
m68k: Disable Amiga serial console support if modular
If CONFIG_AMIGA_BUILTIN_SERIAL=m, I get the following warnings:
| drivers/char/amiserial.c: At top level:
| drivers/char/amiserial.c:2138: warning: data definition has no type or storage class
| drivers/char/amiserial.c:2138: warning: type defaults to 'int' in declaration of 'console_initcall'
| drivers/char/amiserial.c:2138: warning: parameter names (without types) in function declaration
| drivers/char/amiserial.c:2134: warning: 'amiserial_console_init' defined but not used
because console_initcall() is not defined (nor really sensible) in the
modular case.
So disable serial console support if the driver is modular.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Davide Libenzi [Fri, 17 Oct 2008 23:17:40 +0000 (16:17 -0700)]
epoll: avoid double-inserts in case of EFAULT
In commit
f337b9c58332bdecde965b436e47ea4c94d30da0 ("epoll: drop
unnecessary test") Thomas found that there is an unnecessary (always
true) test in ep_send_events(). The callback never inserts into
->rdllink while the send loop is performed, and also does the
~EP_PRIVATE_BITS test. Given we're holding the mutex during this time,
the conditions tested inside the loop are always true.
HOWEVER.
The test "!ep_is_linked(&epi->rdllink)" wasn't there because we insert
into ->rdllink, but because the send-events loop might terminate before
the whole list is scanned (-EFAULT).
In such cases, when the loop terminates early, and when a (leftover)
file received an event while we're performing the lockless loop, we need
such test to avoid to double insert the epoll items. The list_splice()
done a few steps below, will correctly re-insert the ones that were left
on "txlist".
This should fix the kenrel.org bugzilla entry 11831.
Signed-off-by: Davide Libenzi <davidel@xmailserver.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Arjan van de Ven [Sat, 25 Oct 2008 19:41:41 +0000 (12:41 -0700)]
select: deal with math overflow from borderline valid userland data
Some userland apps seem to pass in a "0" for the seconds, and several
seconds worth of usecs to select(). The old kernels accepted this just
fine, so the new kernels must too.
However, due to the upscaling of the microseconds to nanoseconds we had
some cases where we got math overflow, and depending on the GCC version
(due to inlining decisions) that actually resulted in an -EINVAL return.
This patch fixes this by adding the excess microseconds to the seconds
field.
Also with thanks to Marcin Slusarz for spotting some implementation bugs
in the diagnostics patches.
Reported-by: Carlos R. Mafra <crmafra2@gmail.com>
Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Arjan van de Ven [Sun, 26 Oct 2008 17:25:30 +0000 (10:25 -0700)]
wireless: fix regression caused by regulatory config option
The default for the regulatory compatibility option is wrong;
if you picked the default you ended up with a non-functional wifi
system (at least I did on Fedora 9 with iwl4965).
I don't think even the October 2008 releases of the various distros
has the new userland so clearly the default is wrong, and also
we can't just go about deleting this in 2.6.29...
Change the default to "y" and also adjust the config text a little to
reflect this.
This patch fixes regression #11859
With thanks to Johannes Berg for the diagnostics
Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Stephen Rothwell [Tue, 21 Oct 2008 05:11:20 +0000 (16:11 +1100)]
cgroup: remove unused variable
/scratch/sfr/next/kernel/cgroup.c: In function 'cgroup_tasks_start':
/scratch/sfr/next/kernel/cgroup.c:2107: warning: unused variable 'i'
Introduced in commit
cc31edceee04a7b87f2be48f9489ebb72d264844 "cgroups:
convert tasks file to use a seq_file with shared pid array".
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Linus Torvalds [Sun, 26 Oct 2008 16:36:19 +0000 (09:36 -0700)]
Merge branch 'hwmon-for-linus' of git://jdelvare.pck.nerim.net/jdelvare-2.6
* 'hwmon-for-linus' of git://jdelvare.pck.nerim.net/jdelvare-2.6:
hwmon: (abituguru3) enable DMI probing feature on AW9D-MAX
hwmon: (abituguru3) Cosmetic whitespace fixes
hwmon: (adt7473) Fix voltage conversion routines
hwmon: (lm90) Add support for the LM99 16 degree offset
hwmon: (lm90) Fix handling of hysteresis value
hwmon-vid: Add support for AMD family 10h CPUs
hwmon: (w83781d) Fix linking when built-in
Francois Romieu [Sun, 26 Oct 2008 16:02:49 +0000 (17:02 +0100)]
r8169: revert "read MAC address from EEPROM on init"
This reverts commit
7bf6bf4803df1adc927f585168d2135fb019c698.
The code has both a short existence and an increasing track of failures
despite some work to amend it for -rc1. It is not just a matter of
reading the eeprom: sometimes the eeprom is read correctly, then the mac
address is not written correctly back into the mac registers.
Some chipsets seem to work reliably but it is not clear at this point if
the code can simply be made to work on a per-chipset basis and post -rc1
is not the place where I want to experiment these things.
Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Al Viro [Sun, 26 Oct 2008 05:40:26 +0000 (05:40 +0000)]
arm ide breakage
a) semicolon before the function body is a bad idea
b) it's const struct foo, not struct const foo
c) incidentally, it's ecard_remove_driver(), not ecard_unregister_driver()
d) compiling is occasionally useful.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Al Viro [Sun, 26 Oct 2008 05:12:34 +0000 (05:12 +0000)]
fix allmodconfig breakage
If you use KCONFIG_ALLCONFIG (even with empty file) you get broken
allmodconfig/allyesconfig; CONFIG_MODULES gets turned off, with obvious
massive fallout.
Breakage had been introduced when conf_set_all_new_symbols() got used
for allmodconfig et.al.
What happens is that sym_calc_value(modules_sym) done in
conf_read_simple() sets SYMBOL_VALID on both modules_sym and MODULES.
When we get to conf_set_all_new_symbols(), we set sym->def[S_DEF_USER]
on everything, but it has no effect on sym->curr for the symbols that
already have SYMBOL_VALID - these are stuck.
Solution: use sym_clear_all_valid() in there. Note that it makes
reevaluation of modules_sym redundant - sym_clear_all_valid() will do
that itself.
[ Fixes http://bugzilla.kernel.org/show_bug.cgi?id=11512, says Alexey ]
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Cc: Sam Ravnborg <sam@ravnborg.org>
Cc: Roman Zippel <zippel@linux-m68k.org>
Cc: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Alistair John Strachan [Sun, 26 Oct 2008 16:04:40 +0000 (17:04 +0100)]
hwmon: (abituguru3) enable DMI probing feature on AW9D-MAX
Switch the AW9D-MAX over from port probing to the preferred DMI
probe method.
Signed-off-by: Alistair John Strachan <alistair@devzero.co.uk>
Tested-by: Justin Piszcz <jpiszcz@lucidpixels.com>
Acked-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Alistair John Strachan [Sun, 26 Oct 2008 16:04:40 +0000 (17:04 +0100)]
hwmon: (abituguru3) Cosmetic whitespace fixes
As the probable result of zealous copy/pasting, many supported boards
contain sensor names with trailing whitespace. Though this is not a
huge problem, it is inconsistent with other sensor names, and with
other similar hwmon drivers.
Additionally, the DMI nag message added in 2.6.27 was missing a
space between two sentence fragments -- might as well clean that up
too.
Doesn't alter any kernel text, just data.
Signed-off-by: Alistair John Strachan <alistair@devzero.co.uk>
Reported-by: Justin Piszcz <jpiszcz@lucidpixels.com>
Acked-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Jean Delvare [Sun, 26 Oct 2008 16:04:40 +0000 (17:04 +0100)]
hwmon: (adt7473) Fix voltage conversion routines
Fix voltage conversion routines. Based on an earlier patch from
Paulius Zaleckas.
According to the datasheet voltage is scaled with resistors and
value 192 is nominal voltage. 0 is 0V.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Paulius Zaleckas <paulius.zaleckas@teltonika.lt>
Cc: Darrick J. Wong <djwong@us.ibm.com>
Jean Delvare [Sun, 26 Oct 2008 16:04:39 +0000 (17:04 +0100)]
hwmon: (lm90) Add support for the LM99 16 degree offset
The LM99 differs from the LM86, LM89 and LM90 in that it reports
remote temperatures (temp2) 16 degrees lower than they really are. So
far we have been cheating and handled this in userspace but it really
should be handled by the driver directly.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Matthew Garrett <mjg59@srcf.ucam.org>
Jean Delvare [Sun, 26 Oct 2008 16:04:39 +0000 (17:04 +0100)]
hwmon: (lm90) Fix handling of hysteresis value
There are several problems in the way the hysteresis value is handled
by the lm90 driver:
* In show_temphyst(), specific handling of the MAX6646 is missing, so
the hysteresis is reported incorrectly if the critical temperature
is over 127 degrees C.
* In set_temphyst(), the new hysteresis register value is written to
the chip but data->temp_hyst isn't updated accordingly, so there is
a short period of time (up to 2 seconds) where the old hystereris
value will be returned while the new one is already active.
* In set_temphyst(), the critical temperature which is used as a base
to compute the value of the hysteresis register lacks
device-specific handling. As a result, the value of the hysteresis
register might be incorrect for the ADT7461 and MAX6646 chips.
Fix these 3 bugs.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Ben Hutchings <bhutchings@solarflare.com>
Cc: Nate Case <ncase@xes-inc.com>
Jean Delvare [Sun, 26 Oct 2008 16:04:39 +0000 (17:04 +0100)]
hwmon-vid: Add support for AMD family 10h CPUs
The AMD family 10h CPUs use the same VID decoding table as the family
0Fh CPUs.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Rudolf Marek <r.marek@assembler.cz>
Geert Uytterhoeven [Sun, 26 Oct 2008 16:04:38 +0000 (17:04 +0100)]
hwmon: (w83781d) Fix linking when built-in
When w83781d is built-in, the final links fails with the following vague error
message:
`.exit.text' referenced in section `.init.text' of drivers/built-in.o: defined
in discarded section `.exit.text' of drivers/built-in.o
w83781d_isa_unregister() cannot be marked __exit, as it's also called from
sensors_w83781d_init(), which is marked __init.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Wolfgang Grandegger <wg@grandegger.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Jay Fenlason [Fri, 24 Oct 2008 19:26:20 +0000 (15:26 -0400)]
firewire: fw-sbp2: fix races
1: There is a small race between queue_delayed_work() and its
corresponding kref_get(). Do the kref_get first, and _put it again
if the queue_delayed_work() failed, so there is no chance of the
kref going to zero while the work is scheduled.
2: An SBP2_LOGOUT_REQUEST could be sent out with a login_id full of
garbage. Initialize it to an invalid value so we can tell if we
ever got a valid login_id.
3: The node ID and generation may have changed but the new values may
not yet have been recorded in lu and tgt when the final logout is
attempted. Use the latest values from the device in
sbp2_release_target().
Signed-off-by: Jay Fenlason <fenlason@redhat.com>
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Stefan Richter [Tue, 21 Oct 2008 22:28:36 +0000 (00:28 +0200)]
firewire: fw-sbp2: delay first login to avoid retries
This optimizes firewire-sbp2's device probe for the case that the local
node and the SBP-2 node were discovered at the same time. In this case,
fw-core's bus management work and fw-sbp2's login and SCSI probe work
are scheduled in parallel (in the globally shared workqueue and in
fw-sbp2's workqueue, respectively). The bus reset from fw-core may then
disturb and extremely delay the login and SCSI probe because the latter
fails with several command timeouts and retries and has to be retried
from scratch.
We avoid this particular situation of sbp2_login() and fw_card_bm_work()
running in parallel by delaying the first sbp2_login() a little bit.
This is meant to be a short-term fix for
https://bugzilla.redhat.com/show_bug.cgi?id=466679. In the long run,
the SCSI probe, i.e. fw-sbp2's call of __scsi_add_device(), should be
parallelized with sbp2_reconnect().
Problem reported and fix tested and confirmed by Alex Kanavin.
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Stefan Richter [Sun, 26 Oct 2008 08:50:31 +0000 (09:50 +0100)]
firewire: fw-ohci: initialization failure path fixes
Fix leaks when pci_probe fails. Simplify error log strings.
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Jay Fenlason [Wed, 22 Oct 2008 19:59:42 +0000 (15:59 -0400)]
firewire: fw-ohci: don't leak dma memory on module removal
The transmit and receive context dma memory was not being freed on
module removal. Neither was the config rom memory. Fix that.
The ab->next assignment is pure paranoia.
Signed-off-by: Jay Fenlason <fenlason@redhat.com>
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Jay Fenlason [Thu, 16 Oct 2008 22:00:15 +0000 (18:00 -0400)]
firewire: fix struct fw_node memory leak
With the bus_resets patch applied, it is easy to see this memory leak
by repeatedly resetting the firewire bus while running slabtop in
another window. Just watch kmalloc-32 grow and grow...
Signed-off-by: Jay Fenlason <fenlason@redhat.com>
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Jay Fenlason [Thu, 16 Oct 2008 19:51:59 +0000 (15:51 -0400)]
firewire: Survive more than 256 bus resets
The "color" is used during the topology building after a bus reset,
hovever in "struct fw_node"s it is stored in a u8, but in struct fw_card
it is stored in an int. When the value wraps in one struct, but not
the other, disaster strikes.
Signed-off-by: Jay Fenlason <fenlason@redhat.com>
Fixes http://bugzilla.kernel.org/show_bug.cgi?id=10922.
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>