dect
/
linux-2.6
Archived
13
0
Fork 0
Commit Graph

3411 Commits

Author SHA1 Message Date
Kyungmin Park a41371eb6d [MTD] OneNAND: Power Management (PM) support
Add suspend/resume

Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2005-11-06 22:42:28 +01:00
Kyungmin Park 87590e26ff [MTD] OneNAND: Add missing files
Simple bad block table source and header files

Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2005-11-06 22:39:23 +01:00
Ferenc Havasi 2bc9764c48 [JFFS2] Rename jffs2_summary_node to jffs2_raw_summary
Signed-off-by: Ferenc Havasi <havasi@inf.u-szeged.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2005-11-06 22:32:45 +01:00
Artem B. Bityutskiy 733802d974 [JFFS2] Debug code simplification, update TODO
Simplify the debugging code further.
Update the TODO list

Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2005-11-06 22:20:33 +01:00
Vitaly Wool 962034f439 [MTD] NAND: Add suspend/resume functionality
The changes introduced allow to suspend/resume NAND flash.
A new state (FL_PM_SUSPENDED) is introduced, as well as
routines for mtd->suspend and mtd->resume to put the flash in
suspended state from software pov.

Signed-off-by: Vitaly Wool <vwool@ru.mvista.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2005-11-06 21:43:45 +01:00
Ferenc Havasi e631ddba58 [JFFS2] Add erase block summary support (mount time improvement)
The goal of summary is to speed up the mount time. Erase block summary (EBS)
stores summary information at the end of every (closed) erase block. It is
no longer necessary to scan all nodes separetly (and read all pages of them)
just read this "small" summary, where every information is stored which is
needed at mount time.

This summary information is stored in a JFFS2_FEATURE_RWCOMPAT_DELETE. During
the mount process if there is no summary info the orignal scan process will
be executed. EBS works with NAND and NOR flashes, too.

There is a user space tool called sumtool to generate this summary
information for a JFFS2 image.

Signed-off-by: Ferenc Havasi <havasi@inf.u-szeged.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2005-11-06 21:29:48 +01:00
Kyungmin Park d36d63d404 [PATCH] OneNAND: Fix bug in write verify
- Remove unused block, page parameters
- Add constant instead of runtime value

Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2005-11-06 21:24:51 +01:00
Kyungmin Park fcc31470c4 [PATCH] OneNAND: Update OMAP OneNAND mapping using device driver model
- Update OMAP OneNAND mapping file using device driver model
- Remove board specific macro and values.

Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2005-11-06 21:22:01 +01:00
Kyungmin Park cdc001305d [PATCH] OneNAND: Simple Bad Block handling support
Based on NAND memory bad block table code

Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2005-11-06 21:20:53 +01:00
Kyungmin Park 52b0eea73d [PATCH] OneNAND: Sync. Burst Read support
Add OneNAND Sync. Burst Read support
Tested with OMAP platform

Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2005-11-06 21:19:37 +01:00
Kyungmin Park cd5f6346bc [MTD] Add initial support for OneNAND flash chips
OneNAND is a new flash technology from Samsung with integrated SRAM
buffers and logic interface.

Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2005-11-06 21:17:24 +01:00
Russell King 4fe15ba08f [ARM] Fix second missing declaration of cache_is_vivt()
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-06 19:47:04 +00:00
Nicolas Pitre 638d983840 {MTD] add support for Intel's "Sibley" flash
This updates the Primary Vendor-Specific Extended Query parsing to
version 1.4 in order to get the information about the Configurable
Programming Mode regions implemented in the Sibley flash, as well as
selecting the appropriate write command code.

This flash does not behave like traditional NOR flash when writing data.
While mtdblock should just work, further changes are needed for JFFS2 use.

Signed-off-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2005-11-06 20:12:17 +01:00
Ferenc Havasi 2227c0ba4b [jffs2] Remove compressor lzo and lzari
Remove unused compressor code

Signed-off-by: Ferenc Havasi <havasi@inf.u-szeged.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2005-11-06 17:31:24 +01:00
Artem B. Bityutskiy f302cd028c [JFFS2] Namespace clean up
Rename functions to a name matching the functionality.
Remove stall debug code

Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2005-11-06 17:17:32 +01:00
Russell King d3997abf69 [ARM] Fix another use of // as a comment
// disagrees with ld's script parsing ability.  Don't use it.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-06 15:45:00 +00:00
Artem B. Bityutskiy 2b79adcca1 [JFFS2] Use f->target instead of f->dents for symlink target
JFFS2 uses f->dents to store the pointer to the symlink target string (in case
the inode is symlink). This is somewhat ugly to use the same field for
different reasons. Introduce distinct field f->target for this purpose.
Note, f->fragtree, f->dents, f->target may probably be put in a union.

Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2005-11-06 16:25:55 +01:00
Richard Purdie 756c7b7489 [ARM] 3113/1: PXA: Allow machines to override (and also reuse) pxa pm functions
Patch from Richard Purdie

Update the PXA pm.c file to allow machines (such as the Sharp
Zaurus) to override the standard pm functions but reuse/wrap them
where needed.

The init call is made slightly earlier to give machine code an init
level to override them in removing any race.

Signed-off-by: Richard Purdie
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-06 15:03:23 +00:00
Dirk Opfer 8459c159f7 [ARM] 3088/1: PXA: Add machine support for the Sharp SL-6000x series of PDAs
Patch from Dirk Opfer

This patch adds basic machine support for the Sharp SL-6000x (Tosa) PDAs.

Signed-off-by: Dirk Opfer
Signed-off-by: Richard Purdie <rpurdie@rpsys.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-06 14:27:52 +00:00
Russell King 2dd34b488a [PATCH] kbuild: permanently fix kernel configuration include mess
Include autoconf.h into every kernel compilation via the gcc command line
using -imacros.  This ensures that we have the kernel configuration
included from the start, rather than relying on each file having #include
<linux/config.h> as appropriate.  History has shown that this is something
which is difficult to get right.

Since we now include the kernel configuration automatically, make
configcheck becomes meaningless, so remove it.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
2005-11-06 10:22:04 +01:00
Pantelis Antoniou 21c614a789 [SERIAL] Support Au1x00 8250 UARTs using the generic 8250 driver.
The offsets of the registers are in a different place, and
some parts cannot handle a full set of modem control signals.

Signed-off-by: Pantelis Antoniou <pantelis@embeddedalley.ocm>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-06 09:07:03 +00:00
Michael Chan 5b0c76ad94 [PATCH] bnx2: add 5708 support
Add 5708 copper and serdes basic support, including 2.5 Gbps support
on 5708 serdes. SPEED_2500 is also added to ethtool.h

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2005-11-05 21:00:02 -05:00
Arnaldo Carvalho de Melo 2d43f1128a Merge branch 'red' of 84.73.165.173:/home/tgr/repos/net-2.6 2005-11-05 22:30:29 -02:00
Stephen Hemminger 6df716340d [TCP/DCCP]: Randomize port selection
This patch randomizes the port selected on bind() for connections
to help with possible security attacks. It should also be faster
in most cases because there is no need for a global lock.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
2005-11-05 21:23:15 -02:00
Stephen Hemminger 300ce174eb [NETEM]: Support time based reordering
Change netem to support packets getting reordered because of variations in
delay. Introduce a special case version of FIFO that queues packets in order
based on the netem delay.

Since netem is classful, those users that don't want jitter based reordering
can just insert a pfifo instead of the default.

This required changes to generic skbuff code to allow finer grain manipulation
of sk_buff_head.  Insertion into the middle and reverse walk.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
2005-11-05 20:56:41 -02:00
Russell King 37c12e7497 [DRIVER MODEL] Improved dynamically allocated platform_device interface
Re-jig the simple platform device support to allow private data
to be attached to a platform device, as well as allowing the
parent device to be set.

Example usage:

	pdev = platform_device_alloc("mydev", id);
	if (pdev) {
		err = platform_device_add_resources(pdev, &resources,
						    ARRAY_SIZE(resources));
		if (err == 0)
			err = platform_device_add_data(pdev, &platform_data,
						       sizeof(platform_data));
		if (err == 0)
			err = platform_device_add(pdev);
	} else {
		err = -ENOMEM;
	}
	if (err)
		platform_device_put(pdev);

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
2005-11-05 21:19:33 +00:00
Thomas Graf bdc450a0bb [PKT_SCHED]: (G)RED: Introduce hard dropping
Introduces a new flag TC_RED_HARDDROP which specifies that if ECN
marking is enabled packets should still be dropped once the
average queue length exceeds the maximum threshold.

This _may_ help to avoid global synchronisation during small
bursts of peers advertising but not caring about ECN. Use this
option very carefully, it does more harm than good if
(qth_max - qth_min) does not cover at least two average burst
cycles.

The difference to the current behaviour, in which we'd run into
the hard queue limit, is that due to the low pass filter of RED
short bursts are less likely to cause a global synchronisation.

Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
2005-11-05 22:02:29 +01:00
Thomas Graf b38c7eef7e [PKT_SCHED]: GRED: Support ECN marking
Adds a new u8 flags in a unused padding area of the netlink
message. Adds ECN marking support to be used instead of dropping
packets immediately.

Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
2005-11-05 22:02:29 +01:00
Thomas Graf 1e4dfaf9b9 [PKT_SCHED]: GRED: Cleanup and remove unnecessary code
Removes unnecessary includes, initializers, and simplifies
the code a bit.

Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
2005-11-05 22:02:28 +01:00
Thomas Graf 2566a509ca [NET]: Introduce INET_ECN_set_ce() function
Changes IP_ECN_set_ce() and IP6_ECN_set_ce() to return 0 if the CE
bits could not bet set because none of the ECT bits are set or 1
if the CE bits are already set or have been successfully set.

Introduces INET_ECN_set_ce(skb) to enable CE bits for all supported
protocols.

Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
2005-11-05 22:02:24 +01:00
Thomas Graf a783474591 [PKT_SCHED]: Generic RED layer
Extracts the RED algorithm from sch_red.c and puts it into include/net/red.h
for use by other RED based modules. The statistics are extended to be more
fine grained in order to differ between probability/forced marks/drops.
We now reset the average queue length when setting new parameters, leaving
it might result in an unreasonable qavg for a while depending on the value of W.

Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
2005-11-05 22:02:24 +01:00
Matt Porter f896424cbc [PATCH] phy address mask support for generic phy layer
Adds a phy_mask field to struct mii_bus and uses it.  This field
indicates each phy address to be ignored when probing the mdio bus.

This support is needed for the fs_enet and ibm_emac drivers to be
converted to the generic phy layer among other drivers. Many systems
lock up on probing certain phy addresses or probing doesn't return
0xffff when nothing is found at the address. A new driver I'm
working on also makes use of this mask.

Signed-off-by: Matt Porter <mporter@kernel.crashing.org>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
2005-11-05 14:40:55 -05:00
Linus Torvalds fecb4a0c87 Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-for-linus-2.6 2005-11-05 10:31:35 -08:00
James Bottomley 849a8924a6 Merge by Hand
Conflicts in dec_esp.c (Thanks Bacchus), scsi_transport_iscsi.c and
scsi_transport_fc.h

Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2005-11-04 22:29:52 -06:00
Jeff Garzik 6037d6bbdf [libata] ATAPI pad allocation fixes/cleanup
Use ata_pad_{alloc,free} in two drivers, to factor out common code.

Add ata_pad_{alloc,free} to two other drivers, which needed the padding
but had not been updated.
2005-11-04 22:08:00 -05:00
Jeff Garzik c2cc87ca95 Merge branch 'master' 2005-11-04 21:39:31 -05:00
Calin A. Culianu 7015faa7df [PATCH] nvidiafb: Geforce 7800 series support added
This adds support for the Nvidia Geforce 7800 series of cards to the
nvidiafb framebuffer driver.  All it does is add the PCI device id for
the 7800, 7800 GTX, 7800 GO, and 7800 GTX GO cards to the module device
table for the nvidiafb.ko driver, so that nvidiafb.ko will actually work
on these cards.

I also added the relevant PCI device ids to linux/pci_ids.h

I tested it on my 7800 GTX here and it works like a charm.  I now can
get framebuffer support on this card! Woo hoo!! Nothing like 200x75 text
mode to make your eyes BLEED.  ;)

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-04 18:01:34 -08:00
Linus Torvalds 127f2fa31a Merge branch 'srp' of master.kernel.org:/pub/scm/linux/kernel/git/roland/infiniband 2005-11-04 16:32:36 -08:00
Linus Torvalds ba77df570c Merge branch 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/roland/infiniband 2005-11-04 16:31:54 -08:00
Linus Torvalds 602d4a7e2f Merge master.kernel.org:/pub/scm/linux/kernel/git/paulus/powerpc-merge 2005-11-04 16:27:50 -08:00
Paul Mackerras 5ad5707861 powerpc: Merge smp.c and smp.h
This also moves setup_cpu_maps to setup-common.c (calling it
smp_setup_cpu_maps) and uses it on both 32-bit and 64-bit.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-05 10:33:55 +11:00
Trond Myklebust d530838bfa NFSv4: Fix problem with OPEN_DOWNGRADE
RFC 3530 states that for OPEN_DOWNGRADE "The share_access and share_deny
 bits specified must be exactly equal to the union of the share_access and
 share_deny bits specified for some subset of the OPENs in effect for
 current openowner on the current file.

 Setattr is currently violating the NFSv4 rules for OPEN_DOWNGRADE in that
 it may cause a downgrade from OPEN4_SHARE_ACCESS_BOTH to
 OPEN4_SHARE_ACCESS_WRITE despite the fact that there exists no open file
 with O_WRONLY access mode.

 Fix the problem by replacing nfs4_find_state() with a modified version of
 nfs_find_open_context().

 Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
2005-11-04 15:33:38 -05:00
Linus Torvalds 0676fc122e Merge master.kernel.org:/home/rmk/linux-2.6-arm 2005-11-04 10:40:11 -08:00
Linus Torvalds 912cbe3c5b Merge master.kernel.org:/pub/scm/linux/kernel/git/acme/net-2.6 2005-11-04 10:39:28 -08:00
Russell King d56c524afa [PATCH] ARM: Reverted 2918/1: [update] Base port of Comdial MP1000 platfrom
No longer maintained
2005-11-04 17:28:34 +00:00
Dave Jiang 7866f64928 [ARM] 3086/1: ixp2xxx error irq handling
Patch from Dave Jiang

This provides support for IXP2xxx error interrupt handling. Previously there was a patch to remove this (although the original stuff was broken). Well, now the error bits are needed again. These are used extensively by the micro-engine drivers according to Deepak and also we will need it for the new EDAC code that Alan Cox is trying to push into the main kernel.

Re-submit of 3072/1, generated against git tree pulled today. AFAICT, this git tree pulled in all the ARM changes that's in arm.diff. Please let me know if there are additional changes. Thx!

Signed-off-by: Dave Jiang <djiang@mvista.com>
Signed-off-by: Deepak Saxena <dsaxena@plexity.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-04 17:15:44 +00:00
Lee Revell 9529a5bae1 [ALSA] emu10k1 - Use 31 bit DMA mask for Audigy
Modules: EMU10K1/EMU10K2 driver

It appears that either the Audigy DMA engine or the Linux kernel cannot
handle 32 bit DMA with this device.  Problem manifests as noise when
using more than 2GB of RAM, possibly only on 64 bit machines.

The OSS driver actually uses a 29 bit DMA mask for both devices, this
seems like overkill for now.

Signed-off-by: Lee Revell <rlrevell@joe-job.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2005-11-04 13:20:22 +01:00
Clemens Ladisch f190286016 [ALSA] fix improper CONFIG_SND_MAJOR usage
Modules: HWDEP Midlevel,PCM Midlevel,RawMidi Midlevel,ALSA Core

Replace usage of CONFIG_SND_MAJOR with snd_major, where appropriate.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2005-11-04 13:20:08 +01:00
Clemens Ladisch 3939e7142d [ALSA] clean up device types symbols
Modules: ALSA Core,ALSA Minor Numbers

Remove the unused and undefined symbols SNDRV_DEVICE_TYPE_{MIXER,
PCM_PLOOP,PCM_CLOOP}, and introduce a new symbol SNDRV_MINOR_GLOBAL
for non-card-specific devices like the sequencer or the timer.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2005-11-04 13:19:58 +01:00
Clemens Ladisch de24214d0c [ALSA] timers: add module refcounting for global timers
Modules: RTC timer driver,Timer Midlevel

Add a module pointer to the timer structure and use it for refcounting
instead of the card's module pointer to prevent the global timer
modules (rtctimer and hpetimer) from being removed while in use.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2005-11-04 13:18:43 +01:00
Takashi Iwai b709e57440 [ALSA] Add the missing forward declration
Modules: ALSA Core

Added the missing forward declaration before function prototypes.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2005-11-04 13:18:34 +01:00
Takashi Iwai e38e0cfa48 [ALSA] Remove kmalloc wrappers
Modules: ALSA Core

Remove kmalloc wrappers.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2005-11-04 13:18:08 +01:00
Takashi Iwai b1d5776d86 [ALSA] Remove vmalloc wrapper, kfree_nocheck()
- Remove vmalloc wrapper
- Add release_and_free_resource() to remove kfree_nocheck() from each driver
  and simplify the code

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2005-11-04 13:18:00 +01:00
Takashi Iwai 93f2e37840 [ALSA] Make snd_task_name() module local
Modules: ALSA Core,ALSA<-OSS emulation

Remove a global function snd_task_name(), and move it local
to snd-pcm-oss module.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2005-11-04 13:17:54 +01:00
Takashi Iwai 07799e756c [ALSA] Use getnstimeofday()
Modules: Documentation,PCM Midlevel,Timer Midlevel,ALSA Core

Use the standard getnstimeofday() function instead of ALSA's own one.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2005-11-04 13:17:47 +01:00
Takashi Iwai 7c22f1aaa2 [ALSA] Remove snd_runtime_check() macro
Remove snd_runtime_check() macro.
This macro worsens the readability of codes.  They should be either
normal if() or removable asserts.

Also, the assert displays stack-dump, instead of only the last caller
pointer.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2005-11-04 13:17:42 +01:00
Sasha Khapyorsky 2ba71978c0 [ALSA] Removing obsolete AC97_SHARED_TYPES
This patch cleans last ac97 audio/modem codec interception in
initialization procedures (ac97_mixer_new()) and removes obsolete
SHARED_TYPE 'locking' which prevents from AMC codecs to function
correctly.

Signed-off-by: Sasha Khapyorsky <sashak@smlink.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2005-11-04 13:16:59 +01:00
Paul Mackerras c3df69cd85 Merge git://oak/home/sfr/kernels/iseries/work 2005-11-04 17:03:39 +11:00
Stephen Rothwell 1970282f3b powerpc: merge tlbflush.h
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-11-04 16:58:59 +11:00
Michael Ellerman dc3a9efb5e Merge with Paulus 2005-11-04 12:12:52 +11:00
Michael Ellerman 30415f6a63 powerpc: Fix random memory corruption in merged elf.h
The merged verison of ELF_CORE_COPY_REGS is basically the PPC64 version, with
a memset that came from PPC and a few types abstracted out into #defines. But
it's not _quite_ right.

The first problem is we calculate the number of registers with:
        nregs = sizeof(struct pt_regs) / sizeof(ELF_GREG_TYPE)

For a 32-bit process on a 64-bit kernel that's bogus because the registers are
64 bits, but ELF_GREG_TYPE is u32, so nregs == 88 which is wrong.

The other problem is the memset, which assumes a struct pt_regs is smaller
than a struct elf_regs. For a 32-bit process on a 64-bit kernel that's false.

The fix is to calculate the number of regs using sizeof(unsigned long), which
should always be right, and just memset the whole damn thing _before_ copying
the registers in.

Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
2005-11-04 12:10:51 +11:00
Michael Ellerman b8f510219e powerpc: Implement smp_release_cpus() in C not asm
There's no reason for smp_release_cpus() to be asm, and most people can make
more sense of C code. Add an extern declaration to smp.h and remove the custom
one in machine_kexec.c

Signed-off-by: Michael Ellerman <michael@ellerman.id.au>

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-11-04 12:09:42 +11:00
Linus Torvalds 0f3278d14f Merge git://oss.sgi.com:8090/oss/git/xfs-2.6 2005-11-03 16:25:58 -08:00
Stephen Rothwell 9a0f78f63b powerpc: merge tlb.h
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-11-04 10:20:27 +11:00
Russell King 5f8b1178e2 [ARM] Merge SMP tree 2005-11-03 21:02:39 +00:00
Russell King 7e5e6e9a50 [ARM SMP] Do not clear cpu_vm_mask for VIPT caches
Since we do not invalidate TLBs/caches on MM switches, we should not
clear the cpu_vm_mask for the CPU.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-03 20:32:45 +00:00
Tony Luck 55725495f2 Auto-update from upstream 2005-11-03 09:09:08 -08:00
Russell King 089311e117 [ARM] Fix another build error with IOP3xx platforms
ld doesn't like comments starting with // in its scripts

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-03 11:04:53 +00:00
Michael Ellerman 40765d2b8b powerpc: Cleanup vpa code
register_vpa() doesn't actually do a VPA register call it just uses the flags
you pass it, so rename it to vpa_call() to be clearer.

We can then define register_vpa() and unregister_vpa() which are both simple
wrappers around vpa_call(). (we'll need unregister_vpa() for kexec soon)

We can then cleanup vpa_init(), and because vpa_init() is only called from
platforms/pseries we remove the definition in asm-ppc64/smp.h.

Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
2005-11-03 19:34:38 +11:00
Michael Ellerman c87ef1171d powerpc: Add helper functions for synthesising instructions at runtime
There's a few places already, and soon will be more, where we synthesise
branch instructions at runtime. Rather than doing it by hand in each case,
it would make sense to have one implementation.

Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
2005-11-03 17:57:53 +11:00
Paul Mackerras d3ab57ebdc Merge git://oak/home/sfr/kernels/iseries/work 2005-11-03 17:04:08 +11:00
Stephen Rothwell 5adb83c2fa powerpc: merge ucontext.h
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-11-03 16:59:17 +11:00
David Gibson 7f23292d5a [PATCH] powerpc: Keep fixing merged ipcbuf.h
Oops, replacing the two u64s in struct ipc64_perm with __u32s changed
the alignment of that structure, which could mess up userspace.
Revert to using two unsigned long longs (which is what ppc32 had
originally).  ppc64 orignally had two unsigned longs, but long long is
the same size on 64 bit, so this should be ok there too.

Signed-off-by: David Gibson <dwg@au1.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-03 16:58:17 +11:00
Marcelo Tosatti 38dc161864 [PATCH] ppc32 8xx: Fix harmless warning in 8xx_io/commproc.c
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-03 16:57:07 +11:00
Stephen Rothwell 608f8b3cf3 powerpc: merge sigcontext.h
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-11-03 16:24:25 +11:00
Stephen Rothwell 879168ee51 powerpc: move include/asm-ppc64/ppc32.h to arch/powerpc/kernel
It is only included by signal_32.c

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-11-03 16:03:28 +11:00
Stephen Rothwell da80d460bf powerpc: merge ptrace.h
Move struct ptregs32 into asm-ppc64/ppc32.h

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-11-03 16:03:07 +11:00
Stephen Rothwell c5a1ebd245 powerpc: merge stat.h
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-11-03 16:02:23 +11:00
Michael Ellerman e1df870d54 powerpc: Merge asm-ppc/kexec.h and asm-ppc64/kexec.h
Merge include/asm-ppc/kexec.h and include/asm-ppc64/kexec.h.

The only thing that's really changed is that we now allocate crash_notes
properly on PPC32. It's address is exported via sysfs, so it's not correct
for it to be a pointer.

I've also removed some of the "we don't use this" comments, because they're
wrong (or perhaps were referring only to arch code).

Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
2005-11-03 15:35:45 +11:00
Michael Ellerman a121872032 powerpc: Move plpar_wrappers.h into arch/powerpc/platforms/pseries
Move plpar_wrappers.h into arch/powerpc/platforms/pseries, fixup white space,
and update callers.

Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
2005-11-03 15:33:31 +11:00
Michael Ellerman cab0af98df powerpc: Make set_dabr() a ppc_md function
Move pSeries specific code in set_dabr() into a ppc_md function, this will
allow us to keep plpar_wrappers.h private to platforms/pseries.

Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
2005-11-03 15:30:49 +11:00
Dmitry Torokhov 5f94548982 Input: do not register statically allocated devices
Do not register statically allocated input devices to prevent
OOPS when attaching input interfaces since it requires class
device to be properly initialized.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2005-11-02 22:51:46 -05:00
Paul Mackerras f4fcbbe9a7 powerpc: Merge remaining RTAS code
This moves rtas-proc.c and rtas_flash.c into arch/powerpc/kernel, since
cell wants them as well as pseries (and chrp can use rtas-proc.c too,
at least in principle).  rtas_fw.c is gone, with its bits moved into
rtas_flash.c and rtas.c.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-03 14:41:19 +11:00
Nathan Scott de69e5f44e [XFS] Add a mechanism for XFS to use the generic quota sync method.
This is now used to issue a delayed allocation flush before reporting
quota, which allows the used space quota report to match reality.

Signed-off-by: Nathan Scott <nathans@sgi.com>
2005-11-03 13:53:34 +11:00
Nathan Scott a2f8e178ad [XFS] Add the project quota type into the XFS quota header.
Signed-off-by: Nathan Scott <nathans@sgi.com>
2005-11-03 13:51:23 +11:00
Nathan Scott 436d7d3060 [XFS] Update XFS quota header license to match the SGI boilerplate.
Signed-off-by: Nathan Scott <nathans@sgi.com>
2005-11-03 13:50:05 +11:00
Linus Torvalds cfa024f4e4 Merge master.kernel.org:/home/rmk/linux-2.6-arm 2005-11-02 18:38:22 -08:00
Linus Torvalds 3a7142371e Merge branch 'swiotlb' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux-2.6 2005-11-02 18:36:15 -08:00
Stephen Hemminger c2da8acaf4 [ETHERNET]: Add ether stuff to docbook
Fix up etherdevice docbook comments and make them (and other networking stuff)
get dragged into the kernel-api. Delete the old 8390 stuff, it really isn't
interesting anymore.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
2005-11-02 22:08:52 -02:00
Stephen Hemminger 2407534f8b [ETHERNET]: Optimize is_broadcast_ether_addr
Optimize the match for broadcast address by using bit operations instead
of comparison. This saves a number of conditional branches, and generates
smaller code.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
2005-11-02 21:54:07 -02:00
Russell King a054a81159 [ARM SMP] Add hotplug CPU infrastructure
This patch adds the infrastructure to support hotplug CPU on ARM
platforms.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-02 22:24:33 +00:00
Roland Dreier aef9ec39c4 IB: Add SCSI RDMA Protocol (SRP) initiator
Add an InfiniBand SCSI RDMA Protocol (SRP) initiator.  This driver is
used to talk talk to InfiniBand SRP targets (storage devices).

Signed-off-by: Roland Dreier <rolandd@cisco.com>
2005-11-02 14:07:13 -08:00
Russell King 71f512e897 [ARM SMP] Track CPU idle threads
Track the idle thread task_struct for each CPU.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-02 21:51:40 +00:00
Linus Torvalds ec1890c5df Merge git://brick.kernel.dk/data/git/linux-2.6-block 2005-11-02 08:06:02 -08:00
Russell King 7e86df2732 [ARM] Fix ARM rwlock implementations
fb1c8f93d8 broke the ARM rwlock code since
it only partially updated the rwlock implementation.  Properly update it.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-02 15:09:31 +00:00
John Bowler bfca94590b [ARM] 3083/1: include/asm-arm/arch-ixp4xx/io.h: eliminate warnings for pointer passed to integral function argument
Patch from John Bowler

Fix for a compiler warning, this wasn't apparent in 2.6.12, I
believe the compiler options have been changed (somewhere) so
that passing a (void*) to a (u32) argument is now warned.

This accounts for the majority of the warnings in my builds of
the 2.6.14 kernel for NSLU2.

The patch changes pointer parameters declared as u32 to be
declared as either, for read parameters:

const volatile void __iomem *

and for write parameters:

volatile void __iomem *

Signed-off-by: John Bowler <jbowler@acm.org>
Signed-off-by: Deepak Saxena <dsaxena@plexity.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-02 11:55:12 +00:00
Russell King 9dc2d0f55f [ARM] Fix realview machine type for patch 3060/1
Realview was missed in this cleanup...

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-02 11:51:15 +00:00
Stephen Rothwell 2be7a90675 Merge Paulus' tree 2005-11-02 18:15:43 +11:00
Al Viro bbc5b21284 [PATCH] missing platform_device.h includes
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-01 21:50:01 -08:00
Greg Ungerer 01824853b1 [PATCH] m68knommu: add 5208 ColdFire reset/reboot support
Add reset/reboot code to support the ColdFire 5208 family.
Patch originally from Matt Wadell (from code originally written by
Mike Lavender).

Signed-off-by: Greg Ungerer <gerg@uclinux.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-01 21:41:20 -08:00
Greg Ungerer 06227039b5 [PATCH] m68knommu: add 5208 ColdFire UART support
Add support for the UARTs on the ColdFire 5208 family.
Patch originally from Matt Wadell (from code originally written by
Mike Lavender).

Signed-off-by: Greg Ungerer <gerg@uclinux.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-01 21:41:20 -08:00
Greg Ungerer 4a1cc1ab40 [PATCH] m68knommu: add 5208 ColdFire pit interrupt support
The PIT timer in the 5208 ColdFire has slightly different interrupt
bit definitions than the PIT timer used on other ColdFire parts.
Define the commonly used bit and mask numbers here, and let
part specific defines take precedence if they are defined.

Patch originally from Matt Wadell (from code originally written by
Mike Lavender).

Signed-off-by: Greg Ungerer <gerg@uclinux.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-01 21:41:20 -08:00
Greg Ungerer c9b68714b6 [PATCH] m68knommu: add 5208 ColdFire pit timer support
Add support for the PIT timer used in the 5208 ColdFire fmaily.
Patch originally from Matt Wadell (from code originally modified by
Mike Lavender).

Signed-off-by: Greg Ungerer <gerg@uclinux.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-01 21:41:20 -08:00
Greg Ungerer 95dad9b351 [PATCH] m68knommu: use board defines to distinguish boards
Use board name defines to distinguish boards, instead of combinations
of more generic defines.

Signed-off-by: Greg Ungerer <gerg@uclinux.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-01 21:41:20 -08:00
Greg Ungerer 4f4ef2967e [PATCH] m68knommu: add 5208 ColdFire cache support
Add support for the cpu cache of the 5208 ColdFire fmaily.
Patch originally from Matt Wadell (from code originally written by
Mike Lavender).

Signed-off-by: Greg Ungerer <gerg@uclinux.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-01 21:41:20 -08:00
Greg Ungerer 7354b62cf7 [PATCH] m68knommu: add 5208 ColdFire support defines
Add support for the internal register map of the 5208 ColdFire fmaily.
Patch originally from Matt Wadell (from code originally written by
Mike Lavender).

Signed-off-by: Greg Ungerer <gerg@uclinux.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-01 21:41:20 -08:00
Greg Ungerer 7ee2cf5f43 [PATCH] m68knommu: add 5208 ColdFire support defines for its internal map
Define the register space of the new 5208 ColdFire family (which includes
to 5207). It is mostly similar to the other ColdFire parts.

Signed-off-by: Greg Ungerer <gerg@uclinux.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-01 21:41:19 -08:00
Greg Ungerer ed65fa16d5 [PATCH] m68knommu: use board name defines to differentiate board definitions
Use board name define to differentiate boards, not combination
of more generic defines.

Signed-off-by: Greg Ungerer <gerg@uclinux.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-01 21:41:19 -08:00
Greg Ungerer 4569ff8843 [PATCH] m68knommu: remove unmaintained asm-m68knommu/ide.h
Remove unmaintained asm-m68knommu/ide.h. It is completely out of
date - and there is no underlying support for it.

Signed-off-by: Greg Ungerer <gerg@uclinux.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-01 21:41:19 -08:00
Greg Ungerer 0c347e47e4 [PATCH] m68knommu: remove auto-generated asm-offsets.h
Remove auto-generated file from source base.

Signed-off-by: Greg Ungerer <gerg@uclinux.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-01 21:41:19 -08:00
Greg Ungerer c514b8be7a [PATCH] m68knommu: change use of extern inline to static inline in headers
"extern inline" doesn't make much sense here.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Greg Ungerer <gerg@uclinux.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-01 21:41:19 -08:00
Linus Torvalds f98e85691b Merge master.kernel.org:/pub/scm/linux/kernel/git/acme/net-2.6 2005-11-01 21:33:06 -08:00
Linus Torvalds ec33b30910 Merge master.kernel.org:/home/rmk/linux-2.6-serial 2005-11-01 21:32:46 -08:00
Linus Torvalds 7f36b1e958 Merge master.kernel.org:/home/rmk/linux-2.6-arm 2005-11-01 21:32:14 -08:00
Stephen Rothwell aaf8a7a294 Merge iSeries include file move 2005-11-02 16:06:03 +11:00
David Gibson f11b7bd88f [PATCH] powerpc: Move naca.h to platforms/iseries
These days, the NACA only exists on iSeries.  Therefore, this patch
moves naca.h from include/asm-ppc64 to arch/powerpc/platforms/iseries.
There was one file including naca.h outside of platforms/iseries -
arch/ppc64/kernel/udbg_scc.c.  However, that's obviously a hangover
from older days.  The include is not necessary, so this patch simply
removes it.

Built and booted on iSeries, built for G5 (which uses udbg_scc.o).

Signed-off-by: David Gibson <dwg@au1.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-02 16:05:53 +11:00
Kelly Daly ecb3ca2783 modify defines according to _ASM_POWERPC_ISERIES_
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-02 15:53:01 +11:00
David Gibson 9933f299d0 [PATCH] powerpc: Move dart.h
asm-ppc64/dart.h is included in exactly one place -
arch/powerpc/sysdev/u3_iommu.c.  This patch, therefore, moves it into
arch/powerpc/sysdev.  While we're at it, update the #ifndef/#define
protecting the include, and the filename in the comments of
u3_iommu.c.

Built and booted on pSeries and G5, built for ppc32 powermac.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-02 15:25:51 +11:00
David Gibson 1fc8b4ef4e [PATCH] powerpc: Merge (move) numnodes.h and sparsemem.h
The ppc64 versions of numnodes.h and sparsemem.h can be safely moved
to asm-powerpc with no changes apart from changing the #define to the
standard _ASM_POWERPC_ form.  There are no ppc32 versions of these
files, because they only have any effect if CONFIG_SPARSEMEM is
enabled, which it never can be on ppc32.

Built and booted on pSeries (POWER5), built for 32-bit powermac.

Signed-off-by: David Gibson <dwg@au1.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-02 15:25:42 +11:00
Kelly Daly 10e8805716 fix incorrect dir
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-02 15:22:37 +11:00
Paul Mackerras de2d3dbd17 Merge ../linux-2.6 2005-11-02 15:20:55 +11:00
Paul Mackerras 104dd65fef powerpc: clean up bug.h further
This simplifies the macros which are different between 32-bit and
64-bit.  It also fixes a couple of printks on the bug->line element,
which is now a long.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-02 15:19:47 +11:00
Paul Mackerras b5ca71a58b Merge git://oak/home/sfr/kernels/iseries/work 2005-11-02 15:14:44 +11:00
Kelly Daly b420677870 merge filename and modify references to iseries/vio.h
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-02 15:13:57 +11:00
Kelly Daly bbc8b628b0 merge filename and modify references to iSeries/mf.h
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-02 15:10:38 +11:00
Kelly Daly 6cbbdabb01 merge filename and modify references to iseries/iseries_io.h
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-02 15:07:51 +11:00
Kelly Daly c43a55ff4e merge filename and modify references to iseries/lpar_map.h
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-02 15:02:47 +11:00
Al Viro f2cad7a8cd [PATCH] ppc bug.h namespace pollution
DATA_TYPE is really not a good thing to put into header that
gets included all over the tree...

Just make the cast always (long) and get rid of DATA_TYPE altogether.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-02 15:01:30 +11:00
Kelly Daly 59ce20bb34 merge filename and modify references to iseries/it_lp_reg_save.h
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-02 14:49:47 +11:00
David Gibson 2ff2ae7a0d [PATCH] powerpc: Merge futex.h
This patch merges the ppc32 and ppc64 versions of futex.h, essentially
by taking the ppc64 version as the powerpc version.  The old ppc32
version did not implement the futex_atomic_op_inuser() callback (it
always returned -ENOSYS), so FUTEX_WAKE_OP would not work on ppc32.
In fact the ppc64 version of this function is almost suitable for
ppc32 as well - the only change needed is to extend ppc_asm.h with a
macro expanding to to the right pseudo-op to store a pointer (either
".long" or ".llong").

Built and booted on pSeries.  Built for 32-bit powermac.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-02 14:48:18 +11:00
David Gibson 847aeb6bad [PATCH] powerpc: Fix merged ipcbuf.h
Oops, when merging ipcbuf.h, I forgot that 'u64' can't be used in
user-visible headers.  This patch corrects the problem, replacing the
unused fields with an array of four __u32s.

Signed-off-by: David Gibson <dwg@au1.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-02 14:48:05 +11:00
Kelly Daly 8875ccfb7a merge filename and modify references to iseries/it_lp_queue.h
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-02 14:13:34 +11:00
Kelly Daly f218aab5cf merge filename and modify references to iseries/it_lp_naca.h
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-02 13:51:41 +11:00
Kelly Daly 7b487bb801 merge filename and modify references to iseries/it_exp_vpd_panel.h
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-02 13:48:25 +11:00
Kelly Daly 1ec65d76f3 merge filename and modify references to iseries/hv_types.h
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-02 13:46:07 +11:00
Kelly Daly e45423eac2 merge filename and modify references to iseries/hv_lp_event.h
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-02 12:08:31 +11:00
Kelly Daly 15b1718948 merge filename and modify reference to iseries/hv_lp_config.h
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-02 11:55:28 +11:00
Kelly Daly 8021b8a776 merge filename and modify references to iseries/hv_call_xm.h
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-02 11:41:12 +11:00
Kelly Daly 50592f5d2a merge filename and modify references to iseries/hv_call_sc.h
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-02 11:37:22 +11:00
Kelly Daly c0a8d05c8a merge filename and modify references to iseries/hv_call_event.h
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-02 11:11:11 +11:00
Sean Hefty 7b28b0d000 [IB] ucm: 32/64 compatibility fixes
Fix structure layouts to ensure same size on 32-bit and 64-bit architectures.
This permits 32-bit userspace apps on a 64-bit kernel.

Signed-off-by: Sean Hefty <sean.hefty@intel.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2005-11-01 13:18:54 -08:00
Lennert Buytenhek d01e8897fc [ARM] 3052/1: add ixp2000 microcode loader
Patch from Lennert Buytenhek

This patch adds a microcode loader for the ixp2000 architecture.

The ixp2000 is an xscale-based CPU with a number of additional small
CPUs ('microengines') on die that can be programmed to do various
things.  Depending on the ixp2000 model, there are between 2 and 16
microengines.

This code provides an API that allows configuring the microengines,
loading code into them, and starting and stopping them and reading
out a number of status registers, and is used by the microengine
network driver that was recently announced to netdev.

Signed-off-by: Lennert Buytenhek <buytenh@wantstofly.org>
Signed-off-by: Deepak Saxena <dsaxena@plexity.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-01 19:53:50 +00:00
Ben Dooks 4ebc3364de [ARM] 3077/1: S3C2410 - regs-iis.h missing mask for IISMOD_FS
Patch from Ben Dooks

Add definition for S3C2410_IISMOD_FS_MASK

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-01 19:44:30 +00:00
Lennert Buytenhek fa87cedd4e [ARM] 3065/1: ixp2000 typo and whitespace fixes
Patch from Lennert Buytenhek

Misc ixp2000 typo and whitespace fixes.

Signed-off-by: Lennert Buytenhek <buytenh@wantstofly.org>
Signed-off-by: Deepak Saxena <dsaxena@plexity.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-01 19:44:27 +00:00
Lennert Buytenhek e9b72e43d9 [ARM] 3064/1: start using ixp2000_reg_wrb
Patch from Lennert Buytenhek

Switch the users of ixp2000_reg_write that depend on writes being
flushed out of the write buffer by the time that function returns
over to ixp2000_reg_wrb.

When using XCB=101, writes to the same functional unit are still
guaranteed to complete in order, so we only need to protect against:
- reordering of writes to different functional units
- masking an interrupt and then reenabling the IRQ bit in CPSR

Signed-off-by: Lennert Buytenhek <buytenh@wantstofly.org>
Signed-off-by: Deepak Saxena <dsaxena@plexity.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-01 19:44:26 +00:00
Lennert Buytenhek 69a857610a [ARM] 3063/1: allow slave ixp2000 cpu reset
Patch from Lennert Buytenhek

On the ixdp2x00, the slave CPU is currently not allowed to reset itself
for fear that it will do something 'funky' on the PCI bus.  This fear is
ungrounded -- the slave CPU is wired up such that a CPU reset will not
cause a PCI bus reset to be done.  This patch changes arch_reset() so
that the slave CPU also executes the reset sequence, allowing it to
reboot itself using /sbin/reboot.

Signed-off-by: Lennert Buytenhek <buytenh@wantstofly.org>
Signed-off-by: Deepak Saxena <dsaxena@plexity.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-01 19:44:25 +00:00
Lennert Buytenhek a6f1063b38 [ARM] 3062/1: map in various enp2611 peripherals for the ixp2000 netdev driver
Patch from Lennert Buytenhek

The enp2611 version of the ixp2000 netdev driver needs to be able to
access a number of on-board peripherals.  ioremap() is not suitable
for this, as that will cause XCB=000 mappings to be done, which will
make the cpu susceptible to crashing on ixp2400 erratum #66.  Properly
aligned iotable mappings with MT_IXP2000_DEVICE will cause section
mappings with XCB=101 to be done, which is safe.

Signed-off-by: Lennert Buytenhek <buytenh@wantstofly.org>
Signed-off-by: Deepak Saxena <dsaxena@plexity.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-11-01 19:44:24 +00:00
Paul Mackerras 89003ebf9e powerpc: Fix BUG/WARN macros for 64-bit
The bug_entry struct had an int in the middle of pointers and unsigned
longs, and the inline asm that generated the bug table entries didn't
insert the necessary padding, so the fields following it didn't get
initialized properly and an oops resulted.  This changes the int field
(the line number) to a long so that all the fields are the same size
and no padding is required.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-01 21:54:38 +11:00
David Gibson a0e60b2033 [PATCH] powerpc: Merge bitops.h
Here's a revised version.  This re-introduces the set_bits() function
from ppc64, which I removed because I thought it was unused (it exists
on no other arch).  In fact it is used in the powermac interrupt code
(but not on pSeries).

- We use LARXL/STCXL macros to generate the right (32 or 64 bit)
  instructions, similar to LDL/STL from ppc_asm.h, used in fpu.S

- ppc32 previously used a full "sync" barrier at the end of
  test_and_*_bit(), whereas ppc64 used an "isync".  The merged version
  uses "isync", since I believe that's sufficient.

- The ppc64 versions of then minix_*() bitmap functions have changed
  semantics.  Previously on ppc64, these functions were big-endian
  (that is bit 0 was the LSB in the first 64-bit, big-endian word).
  On ppc32 (and x86, for that matter, they were little-endian.  As far
  as I can tell, the big-endian usage was simply wrong - I guess
  no-one ever tried to use minixfs on ppc64.

- On ppc32 find_next_bit() and find_next_zero_bit() are no longer
  inline (they were already out-of-line on ppc64).

- For ppc64, sched_find_first_bit() has moved from mmu_context.h to
  the merged bitops.  What it was doing in mmu_context.h in the first
  place, I have no idea.

- The fls() function is now implemented using the cntlzw instruction
  on ppc64, instead of generic_fls(), as it already was on ppc32.

- For ARCH=ppc, this patch requires adding arch/powerpc/lib to the
  arch/ppc/Makefile.  This in turn requires some changes to
  arch/powerpc/lib/Makefile which didn't correctly handle ARCH=ppc.

Built and running on G5.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-01 21:49:02 +11:00
David Gibson 031ef0a72a [PATCH] powerpc: Merge ipcbuf.h
This patch merges ppc32 and ppc64 versions of ipcbuf.h.  The merge is
essentially trivial, since the structure defined in each version was
already identical.  Only wrinkle is that the merged version now
includes linux/types.h in order to get the fixed width integer types.
In fact, the old versions probably should have been including that
anyway, since the file uses various __kernel_*_t types.

Built and booted on G5, built for 32-bit pmac, but not booted, since
the merge tree currently doesn't boot there.

Signed-off-by: David Gibson <dwg@au1.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-01 21:03:26 +11:00
Arnd Bergmann e9add2eeb1 [PATCH] powerpc: move rtas_fw.c out of platforms/pseries
Cell uses the same code as pSeries for flashing the firmware
through rtas, so the implementation should not be part of
platforms/pseries.

Put it into arch/powerpc/kernel instead.

Signed-off-by: Arnd Bergmann <arndb@de.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-01 21:02:59 +11:00
Arnd Bergmann 19fe04755a [PATCH] powerpc: create a new arch/powerpc/platforms/cell/smp.c
During the conversion to the merge tree, the Cell specific
SMP initialization was removed from the pSeries code.

This creates a new Cell specific SMP implementation file.

Signed-off-by: Arnd Bergmann <arndb@de.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-01 21:02:53 +11:00
Arnd Bergmann f3f66f599d [PATCH] powerpc: Rename BPA to Cell
The official name for BPA is now CBEA (Cell Broadband
Engine Architecture). This patch renames all occurences
of the term BPA to 'Cell' for easier recognition.

Signed-off-by: Arnd Bergmann <arndb@de.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-11-01 21:02:44 +11:00
Jens Axboe a362357b6c [BLOCK] Unify the seperate read/write io stat fields into arrays
Instead of having ->read_sectors and ->write_sectors, combine the two
into ->sectors[2] and similar for the other fields. This saves a branch
several places in the io path, since we don't have to care for what the
actual io direction is. On my x86-64 box, that's 200 bytes less text in
just the core (not counting the various drivers).

Signed-off-by: Jens Axboe <axboe@suse.de>
2005-11-01 09:26:16 +01:00
Kelly Daly 1da4403788 merge filename and modify references to iseries/hv_call.h
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
2005-11-01 16:59:20 +11:00
Stephen Rothwell 48fe487156 powerpc: clean up uaccess.h
Use the best from each architecture.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-11-01 15:53:19 +11:00
Stephen Rothwell 3c4cf5ee5a powerpc: use asm-generic/termios.h
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-11-01 14:36:55 +11:00
Stephen Rothwell 870c6ff2ac powerpc: remove duplicate ioctl definitions
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-11-01 14:36:30 +11:00
Stephen Rothwell 5015b49448 powerpc: fix __strnlen_user in merge tree
Change USER/KERNEL_DS so that the merged version of
__strnlen_user can be used which allows us to complete the
removal of arch/ppc64/lib/.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-11-01 14:34:17 +11:00
Stephen Rothwell 2df5e8bcca powerpc: merge uaccess.h
There is still a bug to be fixed and more merging to be done.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-11-01 14:34:03 +11:00
Linus Torvalds 1e4c85f97f Revert "i386: move apic init in init_IRQs"
Commit f2b36db692 causes a bootup hang on
at least one machine.  Revert for now until we understand why.  The old
code may be ugly, but it works.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-31 19:16:17 -08:00
James Courtier-Dutton d83c671fb7 [PATCH] Creative Audigy 2 cardbus: Add IO window wakeup magic
This adds the magic IO wakeup code for the CardBus version of the
Creative Labs Audigy 2 to the snd-emu10k1 driver.

Without the magic IO enable sequence, reading from the IO region of the
card will fail spectacularly, and the machine will hang.

My next task will be getting the driver to actually play sound without
distortion.

Signed-off-by: James Courtier-Dutton <James@superbug.co.uk>

[ This is a work-in-progress, but since it avoids a total lockup
  if the emu10k module is loaded on a machine with the cardbus
  card inserted, we're better off with it than without it, even
  if sound quality is bad right now ]

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-31 16:09:39 -08:00
Bob Picco 631bb0e74e [IA64] Recent SPARSEMEM and DISCONTIG changes break some builds
My only objection to pfn_to_kaddr, which was introduced for HotPlug memory,
is that all arches have an identical implementation. I haven't had a chance
to pursue why yet.  There is probably some arch issue I'm unaware of.

Signed-off-by: Bob Picco <bob.picco@hp.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
2005-10-31 11:33:53 -08:00
Tony Luck c7fb577e2a manual update from upstream:
Applied Al's change 06a544971f
to new location of swiotlb.c

Signed-off-by: Tony Luck <tony.luck@intel.com>
2005-10-31 10:51:57 -08:00
Harald Welte 6b7d31fcdd [NETFILTER]: Add "revision" support to arp_tables and ip6_tables
Like ip_tables already has it for some time, this adds support for
having multiple revisions for each match/target.  We steal one byte from
the name in order to accomodate a 8 bit version number.

Signed-off-by: Harald Welte <laforge@netfilter.org>
Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
2005-10-31 16:36:08 -02:00
Linus Torvalds 4fd5f8267d Merge master.kernel.org:/home/rmk/linux-2.6-drvmodel
Manual #include fixups for clashes - there may be some unnecessary
2005-10-31 07:32:56 -08:00
Catalin Marinas 8ad68bbf7a [ARM] Add support for ARM RealView board
Support for RealView EB.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-10-31 14:25:02 +00:00
Russell King 913ade51ec [SERIAL] Fix port numbering
The PORT_* macros must be uniquely numbered.  This fixes the
definitions.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-10-31 13:53:26 +00:00
Paul Mackerras 23fd07750a Merge ../linux-2.6 by hand 2005-10-31 13:37:12 +11:00
Paul Mackerras cf00a8d18b powerpc: Fix bug arising from having multiple memory_limit variables
We had a static memory_limit in prom.c, and then another one defined
in setup_64.c and used in numa.c, which resulted in the kernel crashing
when mem=xxx was given on the command line.  This puts the declaration
in system.h and the definition in mem.c.  This also moves the
definition of tce_alloc_start/end out of setup_64.c.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-31 13:07:02 +11:00
Linus Torvalds 1480d0a31d Merge master.kernel.org:/home/rmk/linux-2.6-arm 2005-10-30 17:48:00 -08:00
OGAWA Hirofumi 451cbaa1c3 [PATCH] fat: cleanup and optimization of checksum
Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:32 -08:00
Tim Schmielau 4e57b68178 [PATCH] fix missing includes
I recently picked up my older work to remove unnecessary #includes of
sched.h, starting from a patch by Dave Jones to not include sched.h
from module.h. This reduces the number of indirect includes of sched.h
by ~300. Another ~400 pointless direct includes can be removed after
this disentangling (patch to follow later).
However, quite a few indirect includes need to be fixed up for this.

In order to feed the patches through -mm with as little disturbance as
possible, I've split out the fixes I accumulated up to now (complete for
i386 and x86_64, more archs to follow later) and post them before the real
patch.  This way this large part of the patch is kept simple with only
adding #includes, and all hunks are independent of each other.  So if any
hunk rejects or gets in the way of other patches, just drop it.  My scripts
will pick it up again in the next round.

Signed-off-by: Tim Schmielau <tim@physik3.uni-rostock.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:32 -08:00
Oleg Nesterov 621d31219d [PATCH] cleanup the usage of SEND_SIG_xxx constants
This patch simplifies some checks for magic siginfo values.  It should not
change the behaviour in any way.

Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:31 -08:00
Paul Jackson 4098f9918e [PATCH] sched: hardcode non-smp set_cpus_allowed
Simplify the UP (1 CPU) implementatin of set_cpus_allowed.

The one CPU is hardcoded to be cpu 0 - so just test for that bit, and avoid
having to pick up the cpu_online_map.

Also, unexport cpu_online_map: it was only needed for set_cpus_allowed().

Signed-off-by: Paul Jackson <pj@sgi.com>
Acked-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:28 -08:00
Arthur Othieno 727a53bd53 [PATCH] semaphore: Remove __MUTEX_INITIALIZER()
__MUTEX_INITIALIZER() has no users, and equates to the more commonly used
DECLARE_MUTEX(), thus making it pretty much redundant.  Remove it for good.

Signed-off-by: Arthur Othieno <a.othieno@bluewin.ch>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:27 -08:00
Paul E. McKenney a241ec65ae [PATCH] RCU torture-testing kernel module
This patch is a rewrite of the one submitted on October 1st, using modules
(http://marc.theaimsgroup.com/?l=linux-kernel&m=112819093522998&w=2).

This rewrite adds a tristate CONFIG_RCU_TORTURE_TEST, which enables an
intense torture test of the RCU infratructure.  This is needed due to the
continued changes to the RCU infrastructure to accommodate dynamic ticks,
CPU hotplug, realtime, and so on.  Most of the code is in a separate file
that is compiled only if the CONFIG variable is set.  Documentation on how
to run the test and interpret the output is also included.

This code has been tested on i386 and ppc64, and an earlier version of the
code has received extensive testing on a number of architectures as part of
the PREEMPT_RT patchset.

Signed-off-by: "Paul E. McKenney" <paulmck@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:27 -08:00
Nikita Danilov c0398ee6c2 [PATCH] include/linux/kernel.h:BUILD_BUG_ON(): fix a comment
Fix comment describing BUILD_BUG_ON: BUG_ON is not an assertion
(unfortunately).

Signed-off-by: Nikita Danilov <nikita@clusterfs.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:26 -08:00
Pavel Roskin 52303e8b5f [PATCH] modules: fix sparse warning for every MODULE_PARM
sparse complains about every MODULE_PARM used in a module: warning: symbol
'__parm_foo' was not declared.  Should it be static?

The fix is to split declaration and initialization.  While MODULE_PARM is
obsolete, it's not something sparse should report.

Signed-off-by: Pavel Roskin <proski@gnu.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:26 -08:00
Miklos Szeredi 6ea05db06f [PATCH] fuse: remove unused define
Setting ctime is implicit in all setattr cases, so the FATTR_CTIME
definition is unnecessary.

It is used by neither the kernel nor by userspace.

Signed-off-by: Miklos Szeredi <miklos@szeredi.hu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:24 -08:00
David Howells 29db919063 [PATCH] Keys: Add LSM hooks for key management [try #3]
The attached patch adds LSM hooks for key management facilities. The notable
changes are:

 (1) The key struct now supports a security pointer for the use of security
     modules. This will permit key labelling and restrictions on which
     programs may access a key.

 (2) Security modules get a chance to note (or abort) the allocation of a key.

 (3) The key permission checking can now be enhanced by the security modules;
     the permissions check consults LSM if all other checks bear out.

 (4) The key permissions checking functions now return an error code rather
     than a boolean value.

 (5) An extra permission has been added to govern the modification of
     attributes (UID, GID, permissions).

Note that there isn't an LSM hook specifically for each keyctl() operation,
but rather the permissions hook allows control of individual operations based
on the permission request bits.

Key management access control through LSM is enabled by automatically if both
CONFIG_KEYS and CONFIG_SECURITY are enabled.

This should be applied on top of the patch ensubjected:

	[PATCH] Keys: Possessor permissions should be additive

Signed-Off-By: David Howells <dhowells@redhat.com>
Signed-off-by: Chris Wright <chrisw@osdl.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:23 -08:00
David Howells 2aa349f6e3 [PATCH] Keys: Export user-defined keyring operations
Export user-defined key operations so that those who wish to define their
own key type based on the user-defined key operations may do so (as has
been requested).

The header file created has been placed into include/keys/user-type.h, thus
creating a directory where other key types may also be placed.  Any
objections to doing this?

Signed-Off-By: David Howells <dhowells@redhat.com>
Signed-Off-By: Arjan van de Ven <arjan@infradead.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:22 -08:00
Tejun Heo 1426d7a81d [PATCH] vm: remove unused/broken page_pte[_prot] macros
This patch removes page_pte_prot and page_pte macros from all
architectures.  Some architectures define both, some only page_pte (broken)
and others none.  These macros are not used anywhere.

page_pte_prot(page, prot) is identical to mk_pte(page, prot) and
page_pte(page) is identical to page_pte_prot(page, __pgprot(0)).

* The following architectures define both page_pte_prot and page_pte

  arm, arm26, ia64, sh64, sparc, sparc64

* The following architectures define only page_pte (broken)

  frv, i386, m32r, mips, sh, x86-64

* All other architectures define neither

Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:22 -08:00
Paul Jackson 68860ec10b [PATCH] cpusets: automatic numa mempolicy rebinding
This patch automatically updates a tasks NUMA mempolicy when its cpuset
memory placement changes.  It does so within the context of the task,
without any need to support low level external mempolicy manipulation.

If a system is not using cpusets, or if running on a system with just the
root (all-encompassing) cpuset, then this remap is a no-op.  Only when a
task is moved between cpusets, or a cpusets memory placement is changed
does the following apply.  Otherwise, the main routine below,
rebind_policy() is not even called.

When mixing cpusets, scheduler affinity, and NUMA mempolicies, the
essential role of cpusets is to place jobs (several related tasks) on a set
of CPUs and Memory Nodes, the essential role of sched_setaffinity is to
manage a jobs processor placement within its allowed cpuset, and the
essential role of NUMA mempolicy (mbind, set_mempolicy) is to manage a jobs
memory placement within its allowed cpuset.

However, CPU affinity and NUMA memory placement are managed within the
kernel using absolute system wide numbering, not cpuset relative numbering.

This is ok until a job is migrated to a different cpuset, or what's the
same, a jobs cpuset is moved to different CPUs and Memory Nodes.

Then the CPU affinity and NUMA memory placement of the tasks in the job
need to be updated, to preserve their cpuset-relative position.  This can
be done for CPU affinity using sched_setaffinity() from user code, as one
task can modify anothers CPU affinity.  This cannot be done from an
external task for NUMA memory placement, as that can only be modified in
the context of the task using it.

However, it easy enough to remap a tasks NUMA mempolicy automatically when
a task is migrated, using the existing cpuset mechanism to trigger a
refresh of a tasks memory placement after its cpuset has changed.  All that
is needed is the old and new nodemask, and notice to the task that it needs
to rebind its mempolicy.  The tasks mems_allowed has the old mask, the
tasks cpuset has the new mask, and the existing
cpuset_update_current_mems_allowed() mechanism provides the notice.  The
bitmap/cpumask/nodemask remap operators provide the cpuset relative
calculations.

This patch leaves open a couple of issues:

 1) Updating vma and shmfs/tmpfs/hugetlbfs memory policies:

    These mempolicies may reference nodes outside of those allowed to
    the current task by its cpuset.  Tasks are migrated as part of jobs,
    which reside on what might be several cpusets in a subtree.  When such
    a job is migrated, all NUMA memory policy references to nodes within
    that cpuset subtree should be translated, and references to any nodes
    outside that subtree should be left untouched.  A future patch will
    provide the cpuset mechanism needed to mark such subtrees.  With that
    patch, we will be able to correctly migrate these other memory policies
    across a job migration.

 2) Updating cpuset, affinity and memory policies in user space:

    This is harder.  Any placement state stored in user space using
    system-wide numbering will be invalidated across a migration.  More
    work will be required to provide user code with a migration-safe means
    to manage its cpuset relative placement, while preserving the current
    API's that pass system wide numbers, not cpuset relative numbers across
    the kernel-user boundary.

Signed-off-by: Paul Jackson <pj@sgi.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:22 -08:00
Paul Jackson fb5eeeee44 [PATCH] cpusets: bitmap and mask remap operators
In the forthcoming task migration support, a key calculation will be
mapping cpu and node numbers from the old set to the new set while
preserving cpuset-relative offset.

For example, if a task and its pages on nodes 8-11 are being migrated to
nodes 24-27, then pages on node 9 (the 2nd node in the old set) should be
moved to node 25 (the 2nd node in the new set.)

As with other bitmap operations, the proper way to code this is to provide
the underlying calculation in lib/bitmap.c, and then to provide the usual
cpumask and nodemask wrappers.

This patch provides that.  These operations are termed 'remap' operations.
Both remapping a single bit and a set of bits is supported.

Signed-off-by: Paul Jackson <pj@sgi.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:21 -08:00
Paul Jackson 053199edf5 [PATCH] cpusets: dual semaphore locking overhaul
Overhaul cpuset locking.  Replace single semaphore with two semaphores.

The suggestion to use two locks was made by Roman Zippel.

Both locks are global.  Code that wants to modify cpusets must first
acquire the exclusive manage_sem, which allows them read-only access to
cpusets, and holds off other would-be modifiers.  Before making actual
changes, the second semaphore, callback_sem must be acquired as well.  Code
that needs only to query cpusets must acquire callback_sem, which is also a
global exclusive lock.

The earlier problems with double tripping are avoided, because it is
allowed for holders of manage_sem to nest the second callback_sem lock, and
only callback_sem is needed by code called from within __alloc_pages(),
where the double tripping had been possible.

This is not quite the same as a normal read/write semaphore, because
obtaining read-only access with intent to change must hold off other such
attempts, while allowing read-only access w/o such intention.  Changing
cpusets involves several related checks and changes, which must be done
while allowing read-only queries (to avoid the double trip), but while
ensuring nothing changes (holding off other would be modifiers.)

This overhaul of cpuset locking also makes careful use of task_lock() to
guard access to the task->cpuset pointer, closing a couple of race
conditions noticed while reading this code (thanks, Roman).  I've never
seen these races fail in any use or test.

See further the comments in the code.

Signed-off-by: Paul Jackson <pj@sgi.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:21 -08:00
Andrew Morton 15d2bace5e [PATCH] add_timer() of a pending timer is illegal
In the recent timer rework we lost the check for an add_timer() of an
already-pending timer.  That check was useful for networking, so put it back.

Cc: "David S. Miller" <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:21 -08:00
Christoph Hellwig dfb7dac3af [PATCH] unify sys_ptrace prototype
Make sure we always return, as all syscalls should.  Also move the common
prototype to <linux/syscalls.h>

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Miklos Szeredi <miklos@szeredi.hu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:20 -08:00
Christoph Hellwig 7024a9b884 [PATCH] adjust parisc sys_ptrace prototype
Make the pid argument a long as on every other arcihtecture.  Despite pid_t
beeing a 32bit type even on 64bit parisc this is not an ABI change due to
the parisc calling conventions.  And even if it did it wouldn't matter too
much because 64bit userspace on parisc is in an embrionic stage.

Acked-by: Matthew Wilcox <matthew@wil.cx>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:20 -08:00
Oleg Nesterov 19a4fcb531 [PATCH] kill sigqueue->lock
This lock is used in sigqueue_free(), but it is always equal to
current->sighand->siglock, so we don't need to keep it in the struct
sigqueue.

Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:19 -08:00
Eric Dumazet 2f51201662 [PATCH] reduce sizeof(struct file)
Now that RCU applied on 'struct file' seems stable, we can place f_rcuhead
in a memory location that is not anymore used at call_rcu(&f->f_rcuhead,
file_free_rcu) time, to reduce the size of this critical kernel object.

The trick I used is to move f_rcuhead and f_list in an union called f_u

The callers are changed so that f_rcuhead becomes f_u.fu_rcuhead and f_list
becomes f_u.f_list

Signed-off-by: Eric Dumazet <dada1@cosmosbay.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:19 -08:00
Andrew Morton dfc4f94d2f [PATCH] remove timer debug field
Remove timer_list.magic and associated debugging code.

I originally added this when a spinlock was added to timer_list - this meant
that an all-zeroes timer became illegal and init_timer() was required.

That spinlock isn't even there any more, although timer.base must now be
initialised.

I'll keep this debugging code in -mm.

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:18 -08:00
Jeff Garzik d61780c0d3 [PATCH] remove some more check_region stuff
Removed some more references to check_region().

I checked these changes into the 'checkreg' branch of
rsync://rsync.kernel.org/pub/scm/linux/kernel/git/jgarzik/misc-2.6.git

The only valid references remaining are in:
drivers/scsi/advansys.c
drivers/scsi/BusLogic.c
drivers/cdrom/sbpcd.c
sound/oss/pss.c

  Remove last vestiges of ide_check_region()
  drivers/char/specialix: trim trailing whitespace
  drivers/char/specialix: eliminate use of check_region()
  Remove outdated and unused references to check_region()
  [sound oss] remove check_region() usage from cs4232, wavfront
  [netdrvr eepro] trim trailing whitespace
  [netdrvr eepro] remove check_region() usage

Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:18 -08:00
john stultz 1bb34a4127 [PATCH] NTP shift_right cleanup
Create a macro shift_right() that avoids the numerous ugly conditionals in the
NTP code that look like:

        if(a < 0)
                b = -(-a >> shift);
        else
                b = a >> shift;

Replacing it with:

        b = shift_right(a, shift);

This should have zero effect on the logic, however it should probably have
a bit of testing just to be sure.

Also replace open-coded min/max with the macros.

Signed-off-by : John Stultz <johnstul@us.ibm.com>

Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:18 -08:00
Alan Stern 61e1a9ea4b [PATCH] Add kthread_stop_sem()
Enhance the kthread API by adding kthread_stop_sem, for use in stopping
threads that spend their idle time waiting on a semaphore.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:17 -08:00
Oleg Nesterov a8db2db1e6 [PATCH] introduce setup_timer() helper
Every user of init_timer() also needs to initialize ->function and ->data
fields.  This patch adds a simple setup_timer() helper for that.

The schedule_timeout() is patched as an example of usage.

Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:17 -08:00
Jan Kara aaa4059bc2 [PATCH] ext3: Fix unmapped buffers in transaction's lists
Fix the problem (BUG 4964) with unmapped buffers in transaction's
t_sync_data list.  The problem is we need to call filesystem's own
invalidatepage() from block_write_full_page().

block_write_full_page() must call filesystem's invalidatepage().  Otherwise
following nasty race can happen:

   proc 1                                        proc 2
   ------                                        ------
- write some new data to 'offset'
  => bh gets to the transactions data list
                                              - starts truncate
                                                => i_size set to new size
- mpage_writepages()
  - ext3_ordered_writepage() to 'offset'
    - block_write_full_page()
      - page->index > end_index+1
        - block_invalidatepage()
          - discard_buffer()
            - clear_buffer_mapped()

- commit triggers and finds unmapped buffer - BOOM!

Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:17 -08:00
Heiko Carstens 1e8e338325 [PATCH] s390: export ipl device parameters
Sysfs interface to export ipl device parameters.  Dependent on the ipl type
the interface will look like this:

- ccw ipl:

/sys/firmware/ipl/device
		 /ipl_type

- fcp ipl:

/sys/firmware/ipl/binary_parameter
		 /bootprog
		 /br_lba
		 /device
		 /ipl_type
		 /lun
		 /scp_data
		 /wwpn

- otherwise (unknown that is):

/sys/firmware/ipl/ipl_type

Acked-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Greg KH <greg@kroah.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:16 -08:00
Paolo 'Blaisorblade' Giarrusso 6a351cfead [PATCH] uml: remove old UM_FASTCALL, and make the thing work again
This was used in the old dark age of 2.4, ARCH_CFLAGS doesn't work any more
since some time, and UM_FASTCALL was never used in 2.6.

Instead, reintroduce the thing more properly now, directly in
include/asm-um/linkage.h.

Signed-off-by: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:16 -08:00
Paolo 'Blaisorblade' Giarrusso 96d55b882b [PATCH] uml: reuse i386 cpu-specific tuning
Make UML share the underlying cpu-specific tuning done on i386.

Actually, for now many config options aren't used a lot - but that can be done
later.  Also, UML relies on GCC optimization for things like memcpy and such
more than i386, so specifying the correct -march and -mtune should be enough.
Later, we may want to correct some other stuff.

For instance, since FPU context switching, for us, is done (at least
partially, i.e.  between our kernelspace and userspace) by the host, we may
allow usage of FPU operations by GCC.  This doesn't hold for kernelspace vs.
kernelspace, but we don't support preemption.

Signed-off-by: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:16 -08:00