Commit Graph

2409 Commits

Author SHA1 Message Date
Stephen Rothwell
c6d2ea92d1 powerpc: move iSeries/HvCallPci.h to platforms/iseries/call_pci.h
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-10-14 17:16:17 +10:00
Stephen Rothwell
0e29bb1a4e powerpc: move iSeries/HvCallHpt.h to platforms/iseries/call_hpt.h
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-10-14 17:09:16 +10:00
Stephen Rothwell
20f48ccfa0 powerpc: eliminate DsaAddr from pci_dn
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-10-14 16:49:58 +10:00
Stephen Rothwell
426c1a11a6 powerpc: move iSeries/iSeries_pci.h to platforms/iseries
The only real user of this file outside platforms/iseries was
drivers/net/iseries_veth.c but all it wanted was ISERIES_HV_ADDR()
so we move that to abs_addr.h (and lowercase it).

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-10-14 14:51:42 +10:00
Stephen Rothwell
7062018687 powerpc: create 32 bit LOADADDR macro
and use it in misc_32.S

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-10-13 09:49:51 +10:00
Stephen Rothwell
4920960f57 powerpc: consolidate cputable.c
Also simplify arch/ppc64/kernel/Makefile

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
2005-10-13 09:49:45 +10:00
Paul Mackerras
7e130edf71 ppc64: Remove duplicate versions of some headers
This removes three headers from include/asm-ppc64 that are now in
include/asm-powerpc and are sufficiently similar that they can be
used with ARCH=ppc64.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-12 17:03:36 +10:00
Paul Mackerras
5629d41d5c powerpc: Bring in some changes made to arch/ppc and include/asm-ppc64
Recent commits upstream have changed files which are currently
duplicated in arch/powerpc and include/asm-powerpc.  This updates
them with the corresponding changes.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-12 17:01:50 +10:00
Paul Mackerras
b6ec995a21 Merge from Linus' tree 2005-10-12 14:43:32 +10:00
Paul Mackerras
3abec857a0 ppc64: Use merged versions of init_task.c and process.c.
These two files are now built in arch/powerpc/kernel instead of
arch/ppc64/kernel.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-11 22:09:48 +10:00
Paul Mackerras
fd582ec88e ppc: Various minor compile fixes
This fixes up a variety of minor problems in compiling with ARCH=ppc
arising from using the merged versions of various header files.
A lot of the changes are just adding #include <asm/machdep.h> to
files that use ppc_md or smp_ops_t.

This also arranges for us to use semaphore.c, vecemu.c, vector.S and
fpu.S from arch/powerpc/kernel when compiling with ARCH=ppc.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-11 22:08:12 +10:00
Paul Mackerras
60a3d74178 powerpc: Merged asm/xmon.h
Xmon itself isn't merged yet, though.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-11 10:00:00 +10:00
Paul Mackerras
3b341c1c41 powerpc: Merged asm/i8259.h
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-11 09:59:44 +10:00
Paul Mackerras
508c40227c powerpc: Merged asm/backlight.h
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-11 09:59:38 +10:00
Andi Kleen
421c7ce6d0 [PATCH] x86_64: Allocate cpu local data for all possible CPUs
CPU hotplug fills up the possible map to NR_CPUs, but it did that after
setting up per CPU data. This lead to CPU data not getting allocated
for all possible CPUs, which lead to various side effects.

Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-10 16:33:25 -07:00
Harald Welte
46113830a1 [PATCH] Fix signal sending in usbdevio on async URB completion
If a process issues an URB from userspace and (starts to) terminate
before the URB comes back, we run into the issue described above.  This
is because the urb saves a pointer to "current" when it is posted to the
device, but there's no guarantee that this pointer is still valid
afterwards.

In fact, there are three separate issues:

1) the pointer to "current" can become invalid, since the task could be
   completely gone when the URB completion comes back from the device.

2) Even if the saved task pointer is still pointing to a valid task_struct,
   task_struct->sighand could have gone meanwhile.

3) Even if the process is perfectly fine, permissions may have changed,
   and we can no longer send it a signal.

So what we do instead, is to save the PID and uid's of the process, and
introduce a new kill_proc_info_as_uid() function.

Signed-off-by: Harald Welte <laforge@gnumonks.org>
[ Fixed up types and added symbol exports ]
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-10 16:16:33 -07:00
Linus Torvalds
eb1b74e097 Merge master.kernel.org:/home/rmk/linux-2.6-arm 2005-10-10 08:38:52 -07:00
Rafael J. Wysocki
3dd083255d [PATCH] x86_64: Set up safe page tables during resume
The following patch makes swsusp avoid the possible temporary corruption
of page translation tables during resume on x86-64.  This is achieved by
creating a copy of the relevant page tables that will not be modified by
swsusp and can be safely used by it on resume.

The problem is that during resume on x86-64 swsusp may temporarily
corrupt the page tables used for the direct mapping of RAM.  If that
happens, a page fault occurs and cannot be handled properly, which leads
to the solid hang of the affected system.  This leads to the loss of the
system's state from before suspend and may result in the loss of data or
the corruption of filesystems, so it is a serious issue.  Also, it
appears to happen quite often (for me, as often as 50% of the time).

The problem is related to the fact that (at least) one of the PMD
entries used in the direct memory mapping (starting at PAGE_OFFSET)
points to a page table the physical address of which is much greater
than the physical address of the PMD entry itself.  Moreover,
unfortunately, the physical address of the page table before suspend
(i.e.  the one stored in the suspend image) happens to be different to
the physical address of the corresponding page table used during resume
(i.e.  the one that is valid right before swsusp_arch_resume() in
arch/x86_64/kernel/suspend_asm.S is executed).  Thus while the image is
restored, the "offending" PMD entry gets overwritten, so it does not
point to the right physical address any more (i.e.  there's no page
table at the address pointed to by it, because it points to the address
the page table has been at during suspend).  Consequently, if the PMD
entry is used later on, and it _is_ used in the process of copying the
image pages, a page fault occurs, but it cannot be handled in the normal
way and the system hangs.

In principle we can call create_resume_mapping() from
swsusp_arch_resume() (ie.  from suspend_asm.S), but then the memory
allocations in create_resume_mapping(), resume_pud_mapping(), and
resume_pmd_mapping() must be made carefully so that we use _only_
NosaveFree pages in them (the other pages are overwritten by the loop in
swsusp_arch_resume()).  Additionally, we are in atomic context at that
time, so we cannot use GFP_KERNEL.  Moreover, if one of the allocations
fails, we should free all of the allocated pages, so we need to trace
them somehow.

All of this is done in the appended patch, except that the functions
populating the page tables are located in arch/x86_64/kernel/suspend.c
rather than in init.c.  It may be done in a more elegan way in the
future, with the help of some swsusp patches that are in the works now.

[AK: move some externs into headers, renamed a function]

Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-10 08:36:46 -07:00
Paul Mackerras
e574d238ab powerpc: Fix compilation for 32-bit configs
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-10 22:58:10 +10:00
Paul Mackerras
eef289f79c powerpc: Merge asm/unistd.h
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-10 22:56:11 +10:00
Paul Mackerras
1b92313d5b powerpc: Merge asm/irq.h
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-10 22:54:57 +10:00
Paul Mackerras
76f9f87fa5 powerpc: Get iseries to compile with ARCH=powerpc
This moves the Device_List member from struct device_node to
struct pci_dn, which cleans up the device_node and makes the code
a little simpler.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-10 22:52:26 +10:00
Paul Mackerras
40ef8cbc6d powerpc: Get 64-bit configs to compile with ARCH=powerpc
This is a bunch of mostly small fixes that are needed to get
ARCH=powerpc to compile for 64-bit.  This adds setup_64.c from
arch/ppc64/kernel/setup.c and locks.c from arch/ppc64/lib/locks.c.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-10 22:50:37 +10:00
Paul Mackerras
06d67d5474 powerpc: make process.c suitable for both 32-bit and 64-bit
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-10 22:29:05 +10:00
Paul Mackerras
a432403a89 ppc64: Use the merged lmb routines
The only real change here is that lmb_enforce_memory_limit now takes
the memory_limit as a parameter instead of as a global variable.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-10 20:49:07 +10:00
Richard Purdie
7c3989885c [ARM] 2962/1: scoop: Allow GPIO pin suspend state to be specified
Patch from Richard Purdie

Allow the GPIO pin suspend states to be specified for SCOOP devices.
This is needed for correct operation on the spitz platform.

Signed-off-by: Richard Purdie <rpurdie@rpsys.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-10-10 10:20:06 +01:00
Sascha Hauer
79d13b62ef [ARM] 2958/1: fix definition in imx-regs.h
Patch from Sascha Hauer

Fix PD7_AF_UART2_DTR definition

Signed-off-by: Giancarlo Formicuccia <gformicuccia@atinno.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2005-10-10 10:17:43 +01:00
Paul Mackerras
9f04b9e327 powerpc: Merged processor.h.
This adds register definitions from the ppc64 processor.h to reg.h,
and makes a single merged processor.h.  I moved __is_processor from
the ppc64 system.h to the merged reg.h along with the PVR register
constants.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-10 14:19:43 +10:00
Al Viro
dd0fc66fb3 [PATCH] gfp flags annotations - part 1
- added typedef unsigned int __nocast gfp_t;

 - replaced __nocast uses for gfp flags with gfp_t - it gives exactly
   the same warnings as far as sparse is concerned, doesn't change
   generated code (from gcc point of view we replaced unsigned int with
   typedef) and documents what's going on far better.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-08 15:00:57 -07:00
Linus Torvalds
8aa19ad84c Merge master.kernel.org:/pub/scm/linux/kernel/git/perex/alsa 2005-10-08 14:59:13 -07:00
Linus Torvalds
dcbd39a1f1 Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6 2005-10-08 14:57:46 -07:00
David Howells
468ed2b0c8 [PATCH] Keys: Split key permissions checking into a .c file
The attached patch splits key permissions checking out of key-ui.h and
moves it into a .c file.  It's quite large and called quite a lot, and
it's about to get bigger with the addition of LSM support for keys...

key_any_permission() is also discarded as it's no longer used.

Signed-Off-By: David Howells <dhowells@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-08 14:53:31 -07:00
Takashi Iwai
f12aa40c9d [ALSA] emu10k1 - Fix loading of SBLive Game board
EMU10K1/EMU10K2 driver
Fixed the error at loading SBLive Game board (and possible other models).
The PCI SSIDs of this board conflicts with SB Live 5.1 Platinum, which has
no AC97 chip.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2005-10-07 14:46:26 +02:00
Nicolas Pitre
72e75de2df [ALSA] remove redundent assignment to the ac97 device structure
AC97 Codec
Don't use dev.platform_data to store a reference to the containing
ac97_t structure.  Such assignment is redundent since we can deduce the
ac97_t structure location from the contained device structure.  This
sets platform_data free for other purposes.

Signed-off-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2005-10-07 14:45:44 +02:00
Eric Kinzie
0f21ba7cc3 [ATM]: add support for LECS addresses learned from network
From: Eric Kinzie <ekinzie@cmf.nrl.navy.mil>
Signed-off-by: Chas Williams <chas@cmf.nrl.navy.mil>
Signed-off-by: David S. Miller <davem@davemloft.net>
2005-10-06 22:19:28 -07:00
Sridhar Samudrala
20c9c825b1 [SCTP] Fix SCTP socket options to work with 32-bit apps on 64-bit kernels.
Adds alignment attribute to a few structures used with SCTP socket
options so that the sizes and offsets remain the same when built using
either 32 or 64 bit tools.

Signed-off-by: Sridhar Samudrala <sri@us.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2005-10-06 21:37:01 -07:00
Ivan Skytte Jørgensen
5fe467ee97 [SCTP] Fix sctp_get{pl}addrs() API to work with 32-bit apps on 64-bit kernels.
The old socket options are marked with a _OLD suffix so that the
existing 32-bit apps on 32-bit kernels do not break.

Signed-off-by: Ivan Skytte Jørgensen <isj-sctp@i1.dk>
Signed-off-by: Sridhar Samudrala <sri@us.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2005-10-06 21:36:17 -07:00
Linus Torvalds
9aec247d3b Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6 2005-10-06 14:16:19 -07:00
Paul Mackerras
2e686bc3bf powerpc: Merge of_device.c and of_device.h
Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-06 13:22:17 +10:00
Paul Mackerras
7c8c6b9776 powerpc: Merge lmb.c and make MM initialization use it.
This also creates merged versions of do_init_bootmem, paging_init
and mem_init and moves them to arch/powerpc/mm/mem.c.  It gets rid
of the mem_pieces stuff.

I made memory_limit a parameter to lmb_enforce_memory_limit rather
than a global referenced by that function.  This will require some
small changes to ppc64 if we want to continue building ARCH=ppc64
using the merged lmb.c.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-06 12:23:33 +10:00
Paul Mackerras
9b6b563c0d powerpc: Merge in the ppc64 version of the prom code.
This brings in the ppc64 version of prom_init.c, prom.c and btext.c
and makes them work for ppc32.  This also brings in the new calling
convention, where the first entry to the kernel (with r5 != 0) goes
to the prom_init code, which then restarts from the beginning (with
r5 == 0) after it has done its stuff.

For now this also brings in the ppc32 version of setup.c.  It also
merges lmb.h.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-06 12:06:20 +10:00
Paul Mackerras
b85a046af3 powerpc: Define 32/64 bit asm macros and use them in fpu.S
These macros help in writing assembly code that works for both ppc32
and ppc64.  With this we now have a common fpu.S.  This takes out
load_up_fpu from head_64.S.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2005-10-06 10:59:19 +10:00
Herbert Xu
77d8d7a684 [IPSEC]: Document that policy direction is derived from the index.
Here is a patch that adds a helper called xfrm_policy_id2dir to
document the fact that the policy direction can be and is derived
from the index.

This is based on a patch by YOSHIFUJI Hideaki and 210313105@suda.edu.cn.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
2005-10-05 12:15:12 -07:00
Al Viro
329d4dd72e [PATCH] fix the breakage in sparc headers
If we switch extern inline to static inline, we'd better switch the
pre-declarations we use to say that these puppies have
__attribute_const__ on them.

Otherwise we get extern declaration followed by static inline one.
Which makes gcc unhappy, and for a good reason...

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-05 07:33:42 -07:00
Randy Dunlap
83fa3400eb [XFRM]: fix sparse gfp nocast warnings
Fix implicit nocast warnings in xfrm code:
net/xfrm/xfrm_policy.c:232:47: warning: implicit cast to nocast type

Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
2005-10-04 22:45:35 -07:00
Randy Dunlap
3d2aef6689 [TEXTSEARCH]: fix sparse gfp nocast warnings
Fix nocast sparse warnings:
include/linux/textsearch.h:165:57: warning: implicit cast to nocast type

Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
2005-10-04 22:45:14 -07:00
Randy Dunlap
dd13a285b7 [RPC]: fix sparse gfp nocast warnings
Fix nocast sparse warnings:
net/rxrpc/call.c:2013:25: warning: implicit cast to nocast type
net/rxrpc/connection.c:538:46: warning: implicit cast to nocast type
net/sunrpc/sched.c:730:36: warning: implicit cast to nocast type
net/sunrpc/sched.c:734:56: warning: implicit cast to nocast type

Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
2005-10-04 22:44:45 -07:00
Randy Dunlap
8eea00a44d [IPVS]: fix sparse gfp nocast warnings
From: Randy Dunlap <rdunlap@xenotime.net>

Fix implicit nocast warnings in ip_vs code:
net/ipv4/ipvs/ip_vs_app.c:631:54: warning: implicit cast to nocast type

Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
2005-10-04 22:42:15 -07:00
Randy Dunlap
f4a19a56e3 [DECNET]: fix sparse gfp nocast warnings
Fix implicit nocast warnings in decnet code:
net/decnet/af_decnet.c:458:40: warning: implicit cast to nocast type
net/decnet/dn_nsp_out.c:125:35: warning: implicit cast to nocast type
net/decnet/dn_nsp_out.c:219:29: warning: implicit cast to nocast type

Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
2005-10-04 22:41:48 -07:00
Randy Dunlap
17b6988563 [CONNECTOR]: fix sparse gfp nocast warnings
Fix implicit nocast warnings in connector code:
drivers/connector/connector.c:102:24: warning: implicit cast to nocast type
drivers/connector/connector.c:114:45: warning: implicit cast to nocast type

Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
2005-10-04 22:41:16 -07:00