]> pilppa.org Git - linux-2.6-omap-h63xx.git/log
linux-2.6-omap-h63xx.git
17 years agomib: put udplite statistics on struct net
Pavel Emelyanov [Fri, 18 Jul 2008 11:03:45 +0000 (04:03 -0700)]
mib: put udplite statistics on struct net

Signed-off-by: Pavel Emelyanov <xemul@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agomib: put udp statistics on struct net
Pavel Emelyanov [Fri, 18 Jul 2008 11:03:27 +0000 (04:03 -0700)]
mib: put udp statistics on struct net

Similar to... ouch, I repeat myself.

Signed-off-by: Pavel Emelyanov <xemul@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agomib: put net statistics on struct net
Pavel Emelyanov [Fri, 18 Jul 2008 11:03:08 +0000 (04:03 -0700)]
mib: put net statistics on struct net

Similar to ip and tcp ones :)

Signed-off-by: Pavel Emelyanov <xemul@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agomib: put ip statistics on struct net
Pavel Emelyanov [Fri, 18 Jul 2008 11:02:42 +0000 (04:02 -0700)]
mib: put ip statistics on struct net

Similar to tcp one.

Signed-off-by: Pavel Emelyanov <xemul@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agomib: put tcp statistics on struct net
Pavel Emelyanov [Fri, 18 Jul 2008 11:02:08 +0000 (04:02 -0700)]
mib: put tcp statistics on struct net

Proc temporary uses stats from init_net.

BTW, TCP_XXX_STATS are beautiful (w/o do { } while (0) facing) again :)

Signed-off-by: Pavel Emelyanov <xemul@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agoipv4: add pernet mib operations
Pavel Emelyanov [Fri, 18 Jul 2008 11:01:44 +0000 (04:01 -0700)]
ipv4: add pernet mib operations

These ones are currently empty, but stuff from init_ipv4_mibs will
sequentially migrate there.

Signed-off-by: Pavel Emelyanov <xemul@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agomib: add netns/mib.h file
Pavel Emelyanov [Fri, 18 Jul 2008 11:01:24 +0000 (04:01 -0700)]
mib: add netns/mib.h file

The only structure declared within is the netns_mib, which will
carry all our mibs within. I didn't put the mibs in the existing
netns_xxx structures to make it possible to mark this one as
properly aligned and get in a separate "read-mostly" cache-line.

Signed-off-by: Pavel Emelyanov <xemul@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agoRevert "remove the strip driver"
David S. Miller [Fri, 18 Jul 2008 10:58:52 +0000 (03:58 -0700)]
Revert "remove the strip driver"

This reverts commit 94d9842403f770239a656586442454b7a8f2df29.

Alan says it's not appropriate to remove this driver,
Adrian Bunk also agrees with this revert.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agosched: rework of "prioritize non-migratable tasks over migratable ones"
Dmitry Adamushko [Tue, 1 Jul 2008 21:32:15 +0000 (23:32 +0200)]
sched: rework of "prioritize non-migratable tasks over migratable ones"

(1) handle in a generic way all cases when a newly woken-up task is
not migratable (not just a corner case when "rt_se->nr_cpus_allowed ==
1")

(2) if current is to be preempted, then make sure "p" will be picked
up by pick_next_task_rt().
i.e. move task's group at the head of its list as well.

currently, it's not a case for the group-scheduling case as described
here: http://www.ussg.iu.edu/hypermail/linux/kernel/0807.0/0134.html

Signed-off-by: Dmitry Adamushko <dmitry.adamushko@gmail.com>
Cc: Steven Rostedt <rostedt@goodmis.org>
Cc: Gregory Haskins <ghaskins@novell.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
17 years agox86: APIC: remove apic_write_around(); use alternatives
Maciej W. Rozycki [Wed, 16 Jul 2008 18:15:30 +0000 (19:15 +0100)]
x86: APIC: remove apic_write_around(); use alternatives

Use alternatives to select the workaround for the 11AP Pentium erratum
for the affected steppings on the fly rather than build time.  Remove the
X86_GOOD_APIC configuration option and replace all the calls to
apic_write_around() with plain apic_write(), protecting accesses to the
ESR as appropriate due to the 3AP Pentium erratum.  Remove
apic_read_around() and all its invocations altogether as not needed.
Remove apic_write_atomic() and all its implementing backends.  The use of
ASM_OUTPUT2() is not strictly needed for input constraints, but I have
used it for readability's sake.

I had the feeling no one else was brave enough to do it, so I went ahead
and here it is.  Verified by checking the generated assembly and tested
with both a 32-bit and a 64-bit configuration, also with the 11AP
"feature" forced on and verified with gdb on /proc/kcore to work as
expected (as an 11AP machines are quite hard to get hands on these days).
Some script complained about the use of "volatile", but apic_write() needs
it for the same reason and is effectively a replacement for writel(), so I
have disregarded it.

I am not sure what the policy wrt defconfig files is, they are generated
and there is risk of a conflict resulting from an unrelated change, so I
have left changes to them out.  The option will get removed from them at
the next run.

Some testing with machines other than mine will be needed to avoid some
stupid mistake, but despite its volume, the change is not really that
intrusive, so I am fairly confident that because it works for me, it will
everywhere.

Signed-off-by: Maciej W. Rozycki <macro@linux-mips.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
17 years agoALSA: hda - Add support of ASUS Eeepc P90*
Kailang Yang [Fri, 18 Jul 2008 10:36:43 +0000 (12:36 +0200)]
ALSA: hda - Add support of ASUS Eeepc P90*

- Support ASUS_P900A = P703
- Support ASUS_P901

Signed-off-by: Kailang Yang <kailang@realtek.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
17 years agox86: use cpu_clear in remove_cpu_from_maps
Yinghai Lu [Fri, 18 Jul 2008 04:50:23 +0000 (21:50 -0700)]
x86: use cpu_clear in remove_cpu_from_maps

Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
17 years agoMerge branch 'linus' into x86/urgent
Ingo Molnar [Fri, 18 Jul 2008 10:20:23 +0000 (12:20 +0200)]
Merge branch 'linus' into x86/urgent

17 years agoALSA: opti9xx: no isapnp param for !CONFIG_PNP
Rene Herman [Fri, 18 Jul 2008 09:15:12 +0000 (11:15 +0200)]
ALSA: opti9xx: no isapnp param for !CONFIG_PNP

"isapnp" needs CONFIG_PNP to be useful.

Signed-off-by: Rene Herman <rene.herman@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
17 years agoALSA: opti93x - Fix NULL dereference
Takashi Iwai [Thu, 17 Jul 2008 21:37:20 +0000 (23:37 +0200)]
ALSA: opti93x - Fix NULL dereference

Probing non-existing device causes Oops with snd-opti93x driver
due to NULL access in the destructor of the error path.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Tested-by: Rene Herman <rene.herman@gmail.com>
Acked-by: Rene Herman <rene.herman@gmail.com>
Tested-by: Ingo Molnar <mingo@elte.hu>
Acked-by: Ingo Molnar <mingo@elte.hu>
17 years agosched: reduce stack size in isolated_cpu_setup()
Mike Travis [Tue, 1 Jul 2008 17:32:50 +0000 (10:32 -0700)]
sched: reduce stack size in isolated_cpu_setup()

  * Remove 16k stack requirements in isolated_cpu_setup when NR_CPUS=4096.

Signed-off-by: Mike Travis <travis@sgi.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
17 years agoMerge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/torvalds/linux-2.6
David S. Miller [Fri, 18 Jul 2008 09:39:39 +0000 (02:39 -0700)]
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/torvalds/linux-2.6

Conflicts:

Documentation/powerpc/booting-without-of.txt
drivers/atm/Makefile
drivers/net/fs_enet/fs_enet-main.c
drivers/pci/pci-acpi.c
net/8021q/vlan.c
net/iucv/iucv.c

17 years agoavr32: clean up mci platform code
Ben Nizette [Fri, 18 Jul 2008 06:48:09 +0000 (16:48 +1000)]
avr32: clean up mci platform code

This patch does a few small cleanups around the atmel mci platform code
and in the atmel-mci driver.  The platform changes simply removes an
unused variable, uses the fact that by the end we always have some form
of platform data and notes that GPIO_PIN_NONE != 0.  This last point
could cause the incorrect attempt to twice reserve pin PA0.

While we've got the hood up, add linux/err.h to the atmel-mci.c include
list.  It needs it and generally pulls it by voodoo but I did once
stumble across a config which don't build.

This is against Linus' latest git.

Signed-off-by: Ben Nizette <bn@niasdigital.com>
Signed-off-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com>
17 years agosparc64: Update defconfig.
David S. Miller [Fri, 18 Jul 2008 08:49:06 +0000 (01:49 -0700)]
sparc64: Update defconfig.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agoMerge branch 'linus' into x86/step
Ingo Molnar [Fri, 18 Jul 2008 08:14:56 +0000 (10:14 +0200)]
Merge branch 'linus' into x86/step

17 years agolinux-next: pci tree build failure
Stephen Rothwell [Thu, 17 Jul 2008 03:09:24 +0000 (13:09 +1000)]
linux-next: pci tree build failure

Today's linux-next build (x86_64 allmodconfig) failed like this:

 drivers/xen/manage.c: In function 'xen_suspend':
 drivers/xen/manage.c:66: error: too few arguments to function 'device_power_up'
 drivers/xen/manage.c: In function 'do_suspend':
 drivers/xen/manage.c:117: error: too few arguments to function 'device_resume'

Caused by commit 1eede070a59e1cc73da51e1aaa00d9ab86572cfc ("Introduce new
top level suspend and hibernation callbacks") interacting with new
usages ...

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: Jeremy Fitzhardinge <jeremy@goop.org>
Acked-by: Rafael J. Wysocki <rjw@sisk.pl>
Cc: Jesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
17 years agosparc64: Add Niagara2 RNG driver.
David S. Miller [Tue, 3 Jun 2008 22:56:11 +0000 (15:56 -0700)]
sparc64: Add Niagara2 RNG driver.

With feedback and suggestions from Sam Ravnborg.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agosparc64: Add missing hypervisor service group numbers.
David S. Miller [Fri, 18 Jul 2008 07:43:52 +0000 (00:43 -0700)]
sparc64: Add missing hypervisor service group numbers.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agoRevert "ACPI: don't walk tables if ACPI was disabled"
Andi Kleen [Fri, 18 Jul 2008 07:12:49 +0000 (09:12 +0200)]
Revert "ACPI: don't walk tables if ACPI was disabled"

This reverts commit d1857056904d5f313f11184fcfa624652ff9620a.

Double commit, noticed by Thomas Gleixner.

Signed-off-by: Andi Kleen <ak@linux.intel.com>
17 years agoRevert parts of "ftrace: do not trace scheduler functions"
Ingo Molnar [Fri, 18 Jul 2008 06:59:24 +0000 (08:59 +0200)]
Revert parts of "ftrace: do not trace scheduler functions"

the removal of -mno-spe in the !ftrace case was not intended.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
17 years agosparc64: Remove 4MB and 512K base page size options.
David S. Miller [Fri, 18 Jul 2008 06:43:55 +0000 (23:43 -0700)]
sparc64: Remove 4MB and 512K base page size options.

Adrian Bunk reported that enabling 4MB page size breaks the build.
The problem is that MAX_ORDER combined with the page shift exceeds the
SECTION_SIZE_BITS we use in asm-sparc64/sparsemem.h

There are several ways I suppose we could work around this.  For one
we could define a CONFIG_FORCE_MAX_ZONEORDER to decrease MAX_ORDER in
these higher page size cases.

But I also know that these page size cases are broken wrt. TLB miss
handling especially on pre-hypervisor systems, and there isn't an easy
way to fix that.

These options were meant to be fun experimental hacks anyways, and
only 8K and 64K make any sense to support.

So remove 512K and 4M base page size support.  Of course, we still
support these page sizes for huge pages.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agosparc64: Convert to generic helpers for IPI function calls.
David S. Miller [Fri, 18 Jul 2008 06:44:50 +0000 (23:44 -0700)]
sparc64: Convert to generic helpers for IPI function calls.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agosparc: Use new '%pS' infrastructure to print symbols.
David S. Miller [Fri, 18 Jul 2008 05:11:32 +0000 (22:11 -0700)]
sparc: Use new '%pS' infrastructure to print symbols.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agosparc32: fix init.c allnoconfig build error
Robert Reif [Tue, 15 Jul 2008 05:57:29 +0000 (22:57 -0700)]
sparc32: fix init.c allnoconfig build error

Fix allnoconfig build error.

Signed-off-by: Robert Reif <reif@earthlink.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agosparc64: Config category "Processor type and features" absent
Randy Dunlap [Tue, 15 Jul 2008 05:46:33 +0000 (22:46 -0700)]
sparc64: Config category "Processor type and features" absent

kernel bugzilla #11059:

sparc64 config menu is missing "Processor type and features",
so add that and move General Setup before Processor menu.

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agosparc: arch/sparc/kernel/apc.c to unlocked_ioctl
Stoyan Gaydarov [Tue, 15 Jul 2008 05:12:29 +0000 (22:12 -0700)]
sparc: arch/sparc/kernel/apc.c to unlocked_ioctl

This changes arch/sparc/kernel/apc.c to use unlocked_ioctl

Signed-off-by: Stoyan Gaydarov <stoyboyker@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agosparc: join the remaining header files
Sam Ravnborg [Fri, 18 Jul 2008 04:55:51 +0000 (21:55 -0700)]
sparc: join the remaining header files

With this commit all sparc64 header files are moved to asm-sparc.
The remaining files (71 files) were too different to be trivially
merged so divide them up in a _32.h and a _64.h file which
are both included from the file with no bit size.

The following script were used:
cd include
FILES=`wc -l asm-sparc64/*h | grep -v '^     1' | cut -b 20-`

for FILE in ${FILES}; do
  echo $FILE:
  BASE=`echo $FILE | cut -d '.' -f 1`
  FN32=${BASE}_32.h
  FN64=${BASE}_64.h
  GUARD=___ASM_SPARC_`echo $BASE | tr '-' '_' | tr [:lower:] [:upper:]`_H
  git mv asm-sparc/$FILE asm-sparc/$FN32
  git mv asm-sparc64/$FILE asm-sparc/$FN64
  echo git mv done
  printf "#ifndef %s\n" $GUARD                             >   asm-sparc/$FILE
  printf "#define %s\n" $GUARD                             >>  asm-sparc/$FILE
  printf "#if defined(__sparc__) && defined(__arch64__)\n" >>  asm-sparc/$FILE
  printf "#include <asm-sparc/%s>\n" $FN64                 >>  asm-sparc/$FILE
  printf "#else\n"                                         >>  asm-sparc/$FILE
  printf "#include <asm-sparc/%s>\n" $FN32                 >>  asm-sparc/$FILE
  printf "#endif\n"                                        >>  asm-sparc/$FILE
  printf "#endif\n"                                        >>  asm-sparc/$FILE
  git add asm-sparc/$FILE
  echo new file done
  printf "#include <asm-sparc/%s>\n" $FILE                 >  asm-sparc64/$FILE
  git add asm-sparc64/$FILE
  echo sparc64 file done
done

The guard contains three '_' to avoid conflict with existing guards.
In additing the two Kbuild files are emptied to avoid breaking
headers_* targets.
We will reintroduce the exported header files when the necessary
kbuild changes are merged.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agosparc: merge header files with trivial differences
Sam Ravnborg [Thu, 19 Jun 2008 20:39:00 +0000 (22:39 +0200)]
sparc: merge header files with trivial differences

A manual inspection revealed that the following headerfiles
contained only trivial differences:
hw_irq.h idprom.h kmap_types.h kvm.h spinlock_types.h sunbpp.h unaligned.h

The only noteworthy change are that sparc64 had a volatile
qualifer that sparc missed in spinlock_types.h.

In addition a few comments were updated.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: when header files are equal use asm-sparc version
Sam Ravnborg [Thu, 19 Jun 2008 18:52:54 +0000 (20:52 +0200)]
sparc: when header files are equal use asm-sparc version

Used the following script to find equal header files:
SPARC64=`ls asm-sparc64`
for FILE in ${SPARC64}; do
cmp -s asm-sparc/$FILE asm-sparc64/$FILE;
if [ $? = 0 ]; then
printf "#include <asm-sparc/%s>\n" $FILE > asm-sparc64/$FILE
fi
done

A few of the equal files are a simple include from
asm-generic, but by including the file from asm-sparc
we know they are equal for sparc and sparc64.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: copy sparc64 specific files to asm-sparc
Sam Ravnborg [Thu, 19 Jun 2008 18:26:19 +0000 (20:26 +0200)]
sparc: copy sparc64 specific files to asm-sparc

Used the following script to copy the files:
cd include
set -e
SPARC64=`ls asm-sparc64`
for FILE in ${SPARC64}; do
if [ -f asm-sparc/$FILE ]; then
echo $FILE exist in asm-sparc
else
git mv asm-sparc64/$FILE asm-sparc/$FILE
printf "#include <asm-sparc/$FILE>\n" > asm-sparc64/$FILE
git add asm-sparc64/$FILE
fi
done

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/asi.h
Sam Ravnborg [Fri, 13 Jun 2008 19:49:07 +0000 (21:49 +0200)]
sparc: Merge asm-sparc{,64}/asi.h

Joined the two files as they contain distinct definitions.
Inspired by patch from: Adrian Bunk <bunk@kernel.org>

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Cc: Adrian Bunk <bunk@kernel.org>
17 years agosparc: export openprom.h to userspace
Sam Ravnborg [Fri, 13 Jun 2008 18:20:54 +0000 (20:20 +0200)]
sparc: export openprom.h to userspace

sparc64 exports openprom.h to userspace so let sparc follow
the example.
As openprom.h pulled in another not-for-export vaddrs.h header
file it required a few changes to fix the build.

The definition af VMALLOC_* were moved to pgtable as this is
where sparc64 has them.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/types.h
Sam Ravnborg [Fri, 6 Jun 2008 19:35:43 +0000 (21:35 +0200)]
sparc: Merge asm-sparc{,64}/types.h

Copy content of sparc64 file to sparc file.
There is only minimal possibilities for further unification.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/termios.h
Sam Ravnborg [Fri, 6 Jun 2008 19:27:54 +0000 (21:27 +0200)]
sparc: Merge asm-sparc{,64}/termios.h

Bring the commit e55c57e0b51c68d78845549505057169c6c3cba6
("[SPARC64]: Report any user access faults in termios accessors")
over to sparc when unifying the two files.
The diff was manually inspected to contain no
other relevant changes.

This unification therefore changes functionality of sparc.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/termbits.h
Sam Ravnborg [Fri, 6 Jun 2008 19:13:45 +0000 (21:13 +0200)]
sparc: Merge asm-sparc{,64}/termbits.h

The type of tcflag_t differs from 32 and 64 bit.
For 32 bit it is long
For 64 bit it is int

Altough these have same size then I was not sure that
it was OK to change the 64 bit version to long as this
is part of the ABI so it was made conditional.

:$ diff -u include/asm-sparc/termbits.h include/asm-sparc64/termbits.h
:-- include/asm-sparc/termbits.h 2008-06-13 06:42:07.000000000 +0200
:++ include/asm-sparc64/termbits.h 2008-06-13 06:42:07.000000000 +0200
:@@ -1,11 +1,11 @@
:-#ifndef _SPARC_TERMBITS_H
:-#define _SPARC_TERMBITS_H
:+#ifndef _SPARC64_TERMBITS_H
:+#define _SPARC64_TERMBITS_H
:
: #include <linux/posix_types.h>
:
: typedef unsigned char   cc_t;
: typedef unsigned int    speed_t;
:-typedef unsigned long   tcflag_t;
:+typedef unsigned int    tcflag_t;
:
: #define NCC 8
: struct termio {
:@@ -102,7 +102,7 @@
: #define IXANY 0x00000800
: #define IXOFF 0x00001000
: #define IMAXBEL 0x00002000
:-#define IUTF8   0x00004000
:+#define IUTF8 0x00004000
:
: /* c_oflag bits */
: #define OPOST 0x00000001
:@@ -171,7 +171,6 @@
: #define HUPCL   0x00000400
: #define CLOCAL   0x00000800
: #define CBAUDEX   0x00001000
:-/* We'll never see these speeds with the Zilogs, but for completeness... */
: #define  BOTHER   0x00001000
: #define  B57600   0x00001001
: #define  B115200  0x00001002
:@@ -199,7 +198,7 @@
: #define B3500000  0x00001012
: #define B4000000  0x00001013  */
: #define CIBAUD   0x100f0000  /* input baud rate (not used) */
:-#define CMSPAR   0x40000000  /* mark or space (stick) parity */
:+#define CMSPAR    0x40000000  /* mark or space (stick) parity */
: #define CRTSCTS   0x80000000  /* flow control */
:
: #define IBSHIFT   16 /* Shift from CBAUD to CIBAUD */
:@@ -258,4 +257,4 @@
: #define TCSADRAIN 1
: #define TCSAFLUSH 2
:
:-#endif /* !(_SPARC_TERMBITS_H) */
:+#endif /* !(_SPARC64_TERMBITS_H) */

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/setup.h
Sam Ravnborg [Fri, 6 Jun 2008 19:06:11 +0000 (21:06 +0200)]
sparc: Merge asm-sparc{,64}/setup.h

COMMAND_LINE_SIZE differ for 32 and 64 bit.
256 versus 2048

:$ diff -u include/asm-sparc/setup.h include/asm-sparc64/setup.h
:-- include/asm-sparc/setup.h 2008-06-13 06:42:07.000000000 +0200
:++ include/asm-sparc64/setup.h 2008-06-13 06:42:07.000000000 +0200
:@@ -2,9 +2,9 @@
:  * Just a place holder.
:  */
:
:-#ifndef _SPARC_SETUP_H
:-#define _SPARC_SETUP_H
:+#ifndef _SPARC64_SETUP_H
:+#define _SPARC64_SETUP_H
:
:-#define COMMAND_LINE_SIZE 256
:+#define COMMAND_LINE_SIZE 2048
:
:-#endif /* _SPARC_SETUP_H */
:+#endif /* _SPARC64_SETUP_H */

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/resource.h
Sam Ravnborg [Fri, 6 Jun 2008 19:02:38 +0000 (21:02 +0200)]
sparc: Merge asm-sparc{,64}/resource.h

RLIM_INFINITY differ from 32 and 64 bit.
The rest is equal.

:$ diff -u include/asm-sparc/resource.h include/asm-sparc64/resource.h
:-- include/asm-sparc/resource.h 2008-06-13 06:46:39.000000000 +0200
:++ include/asm-sparc64/resource.h 2008-06-13 06:46:39.000000000 +0200
:@@ -1,11 +1,11 @@
: /*
:  * resource.h: Resource definitions.
:  *
:- * Copyright (C) 1995 David S. Miller (davem@caip.rutgers.edu)
:+ * Copyright (C) 1996 David S. Miller (davem@caip.rutgers.edu)
:  */
:
:-#ifndef _SPARC_RESOURCE_H
:-#define _SPARC_RESOURCE_H
:+#ifndef _SPARC64_RESOURCE_H
:+#define _SPARC64_RESOURCE_H
:
: /*
:  * These two resource limit IDs have a Sparc/Linux-specific ordering,
:@@ -14,13 +14,6 @@
: #define RLIMIT_NOFILE 6 /* max number of open files */
: #define RLIMIT_NPROC 7 /* max number of processes */
:
:-/*
:- * SuS says limits have to be unsigned.
:- * We make this unsigned, but keep the
:- * old value for compatibility:
:- */
:-#define RLIM_INFINITY 0x7fffffff
:-
: #include <asm-generic/resource.h>
:
:-#endif /* !(_SPARC_RESOURCE_H) */
:+#endif /* !(_SPARC64_RESOURCE_H) */

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/fbio.h
Sam Ravnborg [Thu, 5 Jun 2008 19:57:01 +0000 (21:57 +0200)]
sparc: Merge asm-sparc{,64}/fbio.h

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: copy asm-sparc64/fbio.h to asm-sparc
Sam Ravnborg [Thu, 5 Jun 2008 19:54:03 +0000 (21:54 +0200)]
sparc: copy asm-sparc64/fbio.h to asm-sparc

There were only a few trivial changes and a few additions
in the sparc64 variant of this file.
This patch copies the sparc64 specific bits to the sparc version
of fbio.h so they are equal. A later patch will merge the two.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/mman.h
Sam Ravnborg [Fri, 6 Jun 2008 18:51:20 +0000 (20:51 +0200)]
sparc: Merge asm-sparc{,64}/mman.h

Renaming the function sparc64_mmap_check() to
sparc_mmap_check() was enough to make the two
header files identical.

:$ diff -u include/asm-sparc/mman.h include/asm-sparc64/mman.h
:-- include/asm-sparc/mman.h 2008-06-13 06:46:39.000000000 +0200
:++ include/asm-sparc64/mman.h 2008-06-13 06:46:39.000000000 +0200
:@@ -1,5 +1,5 @@
:-#ifndef __SPARC_MMAN_H__
:-#define __SPARC_MMAN_H__
:+#ifndef __SPARC64_MMAN_H__
:+#define __SPARC64_MMAN_H__
:
: #include <asm-generic/mman.h>
:
:@@ -23,9 +23,9 @@
:
: #ifdef __KERNEL__
: #ifndef __ASSEMBLY__
:-#define arch_mmap_check(addr,len,flags) sparc_mmap_check(addr,len)
:-int sparc_mmap_check(unsigned long addr, unsigned long len);
:+#define arch_mmap_check(addr,len,flags) sparc64_mmap_check(addr,len)
:+int sparc64_mmap_check(unsigned long addr, unsigned long len);
: #endif
: #endif
:
:-#endif /* __SPARC_MMAN_H__ */
:+#endif /* __SPARC64_MMAN_H__ */

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/shmbuf.h
Sam Ravnborg [Thu, 5 Jun 2008 21:46:22 +0000 (23:46 +0200)]
sparc: Merge asm-sparc{,64}/shmbuf.h

Padding in the shmbuf structure made conditional
as only 32 bit sparc did so.

:$ diff -u include/asm-sparc/shmbuf.h include/asm-sparc64/shmbuf.h
:-- include/asm-sparc/shmbuf.h 2008-06-13 06:42:07.000000000 +0200
:++ include/asm-sparc64/shmbuf.h 2008-06-13 06:42:07.000000000 +0200
:@@ -1,23 +1,19 @@
:-#ifndef _SPARC_SHMBUF_H
:-#define _SPARC_SHMBUF_H
:+#ifndef _SPARC64_SHMBUF_H
:+#define _SPARC64_SHMBUF_H
:
: /*
:- * The shmid64_ds structure for sparc architecture.
:+ * The shmid64_ds structure for sparc64 architecture.
:  * Note extra padding because this structure is passed back and forth
:  * between kernel and user space.
:  *
:  * Pad space is left for:
:- * - 64-bit time_t to solve y2038 problem
:- * - 2 miscellaneous 32-bit values
:+ * - 2 miscellaneous 64-bit values
:  */
:
: struct shmid64_ds {
:  struct ipc64_perm shm_perm; /* operation perms */
:- unsigned int __pad1;
:  __kernel_time_t shm_atime; /* last attach time */
:- unsigned int __pad2;
:  __kernel_time_t shm_dtime; /* last detach time */
:- unsigned int __pad3;
:  __kernel_time_t shm_ctime; /* last change time */
:  size_t shm_segsz; /* size of segment (bytes) */
:  __kernel_pid_t shm_cpid; /* pid of creator */
:@@ -39,4 +35,4 @@
:  unsigned long __unused4;
: };
:
:-#endif /* _SPARC_SHMBUF_H */
:+#endif /* _SPARC64_SHMBUF_H */

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/sembuf.h
Sam Ravnborg [Thu, 5 Jun 2008 21:39:32 +0000 (23:39 +0200)]
sparc: Merge asm-sparc{,64}/sembuf.h

Padding in the sembuf structure made conditional
as only 32 bit sparc did so.

:$ diff -u include/asm-sparc/sembuf.h include/asm-sparc64/sembuf.h
:-- include/asm-sparc/sembuf.h 2008-06-13 06:42:07.000000000 +0200
:++ include/asm-sparc64/sembuf.h 2008-06-13 06:42:07.000000000 +0200
:@@ -1,21 +1,18 @@
:-#ifndef _SPARC_SEMBUF_H
:-#define _SPARC_SEMBUF_H
:+#ifndef _SPARC64_SEMBUF_H
:+#define _SPARC64_SEMBUF_H
:
: /*
:- * The semid64_ds structure for sparc architecture.
:+ * The semid64_ds structure for sparc64 architecture.
:  * Note extra padding because this structure is passed back and forth
:  * between kernel and user space.
:  *
:  * Pad space is left for:
:- * - 64-bit time_t to solve y2038 problem
:- * - 2 miscellaneous 32-bit values
:+ * - 2 miscellaneous 64-bit values
:  */
:
: struct semid64_ds {
:  struct ipc64_perm sem_perm; /* permissions .. see ipc.h */
:- unsigned int __pad1;
:  __kernel_time_t sem_otime; /* last semop time */
:- unsigned int __pad2;
:  __kernel_time_t sem_ctime; /* last change time */
:  unsigned long sem_nsems; /* no. of semaphores in array */
:  unsigned long __unused1;

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/msgbuf.h
Sam Ravnborg [Thu, 5 Jun 2008 21:04:06 +0000 (23:04 +0200)]
sparc: Merge asm-sparc{,64}/msgbuf.h

Padding from 32 bit sparc kept using preprocessor magic

:$ diff -u include/asm-sparc/msgbuf.h include/asm-sparc64/msgbuf.h
:-- include/asm-sparc/msgbuf.h 2008-06-13 06:42:07.000000000 +0200
:++ include/asm-sparc64/msgbuf.h 2008-06-13 06:42:07.000000000 +0200
:@@ -7,17 +7,13 @@
:  * between kernel and user space.
:  *
:  * Pad space is left for:
:- * - 64-bit time_t to solve y2038 problem
:- * - 2 miscellaneous 32-bit values
:+ * - 2 miscellaneous 64-bit values
:  */
:
: struct msqid64_ds {
:  struct ipc64_perm msg_perm;
:- unsigned int   __pad1;
:  __kernel_time_t msg_stime; /* last msgsnd time */
:- unsigned int   __pad2;
:  __kernel_time_t msg_rtime; /* last msgrcv time */
:- unsigned int   __pad3;
:  __kernel_time_t msg_ctime; /* last change time */
:  unsigned long  msg_cbytes; /* current number of bytes on queue */

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/fcntl.h
Sam Ravnborg [Thu, 5 Jun 2008 20:37:04 +0000 (22:37 +0200)]
sparc: Merge asm-sparc{,64}/fcntl.h

The definition of O_NDELAY differed - the rest was equal

:$ diff -u include/asm-sparc/fcntl.h include/asm-sparc64/fcntl.h
:-- include/asm-sparc/fcntl.h 2008-06-13 06:46:39.000000000 +0200
:++ include/asm-sparc64/fcntl.h 2008-06-13 06:46:39.000000000 +0200
:@@ -1,8 +1,9 @@
:-#ifndef _SPARC_FCNTL_H
:-#define _SPARC_FCNTL_H
:+#ifndef _SPARC64_FCNTL_H
:+#define _SPARC64_FCNTL_H
:
: /* open/fcntl - O_SYNC is only implemented on blocks devices and on files
:    located on an ext2 file system */
:+#define O_NDELAY 0x0004
: #define O_APPEND 0x0008
: #define FASYNC 0x0040 /* fcntl, for BSD compatibility */
: #define O_CREAT 0x0200 /* not fcntl */
:@@ -10,7 +11,6 @@
: #define O_EXCL 0x0800 /* not fcntl */
: #define O_SYNC 0x2000
: #define O_NONBLOCK 0x4000
:-#define O_NDELAY (0x0004 | O_NONBLOCK)
: #define O_NOCTTY 0x8000 /* not fcntl */
: #define O_LARGEFILE 0x40000
: #define O_DIRECT        0x100000 /* direct disk access hint */
:@@ -29,8 +29,7 @@
: #define F_UNLCK 3
:
: #define __ARCH_FLOCK_PAD short __unused;
:-#define __ARCH_FLOCK64_PAD short __unused;
:
: #include <asm-generic/fcntl.h>
:
:-#endif
:+#endif /* !(_SPARC64_FCNTL_H) */

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/sockios.h
Sam Ravnborg [Thu, 5 Jun 2008 21:50:10 +0000 (23:50 +0200)]
sparc: Merge asm-sparc{,64}/sockios.h

:$ diff -u include/asm-sparc/sockios.h include/asm-sparc64/sockios.h
:-- include/asm-sparc/sockios.h 2008-06-13 06:42:07.000000000 +0200
:++ include/asm-sparc64/sockios.h 2008-06-13 06:42:07.000000000 +0200
:@@ -1,5 +1,5 @@
:-#ifndef _ASM_SPARC_SOCKIOS_H
:-#define _ASM_SPARC_SOCKIOS_H
:+#ifndef _ASM_SPARC64_SOCKIOS_H
:+#define _ASM_SPARC64_SOCKIOS_H
:
: /* Socket-level I/O control calls. */
: #define FIOSETOWN  0x8901
:@@ -10,5 +10,5 @@
: #define SIOCGSTAMP 0x8906 /* Get stamp (timeval) */
: #define SIOCGSTAMPNS 0x8907 /* Get stamp (timespec) */
:
:-#endif /* !(_ASM_SPARC_SOCKIOS_H) */
:+#endif /* !(_ASM_SPARC64_SOCKIOS_H) */

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/socket.h
Sam Ravnborg [Thu, 5 Jun 2008 21:49:02 +0000 (23:49 +0200)]
sparc: Merge asm-sparc{,64}/socket.h

:$ diff -u include/asm-sparc/socket.h include/asm-sparc64/socket.h
:-- include/asm-sparc/socket.h 2008-06-13 06:46:39.000000000 +0200
:++ include/asm-sparc64/socket.h 2008-06-13 06:46:39.000000000 +0200
:@@ -48,11 +48,10 @@
: #define SO_TIMESTAMPNS 0x0021
: #define SCM_TIMESTAMPNS SO_TIMESTAMPNS
:
:-#define SO_MARK 0x0022
:-
: /* Security levels - as per NRL IPv6 - don't actually do anything */
: #define SO_SECURITY_AUTHENTICATION 0x5001
: #define SO_SECURITY_ENCRYPTION_TRANSPORT 0x5002
: #define SO_SECURITY_ENCRYPTION_NETWORK 0x5004
:
:+#define SO_MARK 0x0022
: #endif /* _ASM_SOCKET_H */

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/poll.h
Sam Ravnborg [Thu, 5 Jun 2008 21:08:51 +0000 (23:08 +0200)]
sparc: Merge asm-sparc{,64}/poll.h

:$ diff -u include/asm-sparc/poll.h include/asm-sparc64/poll.h
:-- include/asm-sparc/poll.h 2008-06-13 06:42:07.000000000 +0200
:++ include/asm-sparc64/poll.h 2008-06-13 06:42:07.000000000 +0200
:@@ -1,5 +1,5 @@
:-#ifndef __SPARC_POLL_H
:-#define __SPARC_POLL_H
:+#ifndef __SPARC64_POLL_H
:+#define __SPARC64_POLL_H
:
: #define POLLWRNORM POLLOUT
: #define POLLWRBAND 256

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/param.h
Sam Ravnborg [Thu, 5 Jun 2008 21:07:26 +0000 (23:07 +0200)]
sparc: Merge asm-sparc{,64}/param.h

:$ diff -u include/asm-sparc/param.h include/asm-sparc64/param.h
:-- include/asm-sparc/param.h 2008-06-13 06:46:39.000000000 +0200
:++ include/asm-sparc64/param.h 2008-06-13 06:42:07.000000000 +0200
:@@ -1,5 +1,6 @@
:-#ifndef _ASMSPARC_PARAM_H
:-#define _ASMSPARC_PARAM_H
:+#ifndef _ASMSPARC64_PARAM_H
:+#define _ASMSPARC64_PARAM_H
:+
:
: #ifdef __KERNEL__
: # define HZ CONFIG_HZ /* Internal kernel timer frequency */
:@@ -19,4 +20,4 @@
:
: #define MAXHOSTNAMELEN 64 /* max length of hostname */
:
:-#endif
:+#endif /* _ASMSPARC64_PARAM_H */

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/ioctls.h
Sam Ravnborg [Thu, 5 Jun 2008 20:45:50 +0000 (22:45 +0200)]
sparc: Merge asm-sparc{,64}/ioctls.h

Trivial differenses in comments - used the version from sparc64

:$ diff -u include/asm-sparc/ioctls.h include/asm-sparc64/ioctls.h
:-- include/asm-sparc/ioctls.h 2008-06-13 08:46:29.000000000 +0200
:++ include/asm-sparc64/ioctls.h 2008-06-13 08:46:29.000000000 +0200
:@@ -1,5 +1,5 @@
:-#ifndef _ASM_SPARC_IOCTLS_H
:-#define _ASM_SPARC_IOCTLS_H
:+#ifndef _ASM_SPARC64_IOCTLS_H
:+#define _ASM_SPARC64_IOCTLS_H
:
: #include <asm/ioctl.h>
:
:@@ -22,7 +22,7 @@
:
: /* Note that all the ioctls that are not available in Linux have a
:  * double underscore on the front to: a) avoid some programs to
:- * thing we support some ioctls under Linux (autoconfiguration stuff)
:+ * think we support some ioctls under Linux (autoconfiguration stuff)
:  */
: /* Little t */
: #define TIOCGETD _IOR('t', 0, int)
:@@ -110,7 +110,7 @@
: #define TIOCSERGETLSR   0x5459 /* Get line status register */
: #define TIOCSERGETMULTI 0x545A /* Get multiport config  */
: #define TIOCSERSETMULTI 0x545B /* Set multiport config */
:-#define TIOCMIWAIT 0x545C /* Wait input */
:+#define TIOCMIWAIT 0x545C /* Wait for change on serial input line(s) */
: #define TIOCGICOUNT 0x545D /* Read serial port inline interrupt counts */
:
: /* Kernel definitions */
:@@ -133,4 +133,4 @@
: #define TIOCPKT_NOSTOP 16
: #define TIOCPKT_DOSTOP 32
:
:-#endif /* !(_ASM_SPARC_IOCTLS_H) */
:+#endif /* !(_ASM_SPARC64_IOCTLS_H) */

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: Merge asm-sparc{,64}/ioctl.h
Sam Ravnborg [Thu, 5 Jun 2008 20:44:29 +0000 (22:44 +0200)]
sparc: Merge asm-sparc{,64}/ioctl.h

:$ diff -u include/asm-sparc/ioctl.h include/asm-sparc64/ioctl.h
:-- include/asm-sparc/ioctl.h 2008-06-13 06:46:39.000000000 +0200
:++ include/asm-sparc64/ioctl.h 2008-06-13 08:46:29.000000000 +0200
:@@ -1,5 +1,5 @@
:-#ifndef _SPARC_IOCTL_H
:-#define _SPARC_IOCTL_H
:+#ifndef _SPARC64_IOCTL_H
:+#define _SPARC64_IOCTL_H
:
:/*
:* Our DIR and SIZE overlap in order to simulteneously provide
:@@ -64,4 +64,4 @@
:#define IOCSIZE_MASK    (_IOC_XSIZEMASK << _IOC_SIZESHIFT)
:#define IOCSIZE_SHIFT   (_IOC_SIZESHIFT)
:
:-#endif /* !(_SPARC_IOCTL_H) */
:+#endif /* !(_SPARC64_IOCTL_H) */

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: copy exported sparc64 specific header files to asm-sparc
Sam Ravnborg [Fri, 13 Jun 2008 06:26:32 +0000 (08:26 +0200)]
sparc: copy exported sparc64 specific header files to asm-sparc

Copy was done using the following simple script:

set -e
SPARC64="h display7seg.h envctrl.h psrcompat.h pstate.h uctx.h utrap.h watchdog.h"
for FILE in ${SPARC64}; do
if [ -f asm-sparc/$FILE ]; then
echo $FILE exist in asm-sparc
fi
cat asm-sparc64/$FILE > asm-sparc/$FILE
printf "#include <asm-sparc/$FILE>\n" > asm-sparc64/$FILE
done

The name of the copied files are added to asm-sparc/Kbuild
to keep "make headers_check" functional.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc: add -m64 when building vmlinux.lds
Sam Ravnborg [Mon, 7 Jul 2008 20:30:35 +0000 (22:30 +0200)]
sparc: add -m64 when building vmlinux.lds

David Miller noticed that the build of vmlinux.lds
failed to use the -m64 specifier.
This caused the build to break with a bi-arch gcc with
unified headers.

Add the -m64 option to CPPFLAGS_vmlinux.lds so we
have the correct defines available when building
vmliux.lds.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
17 years agosparc64 Kbuild: apb.h and bbc.h should not be exported to userspace
David S. Miller [Tue, 10 Jun 2008 20:00:12 +0000 (13:00 -0700)]
sparc64 Kbuild: apb.h and bbc.h should not be exported to userspace

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agosparc: Merge include/asm-sparc{,64}/perfctr.h
Sam Ravnborg [Thu, 5 Jun 2008 18:48:20 +0000 (11:48 -0700)]
sparc: Merge include/asm-sparc{,64}/perfctr.h

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agosparc: Merge include/asm-sparc{,64}/openpromio.h
Sam Ravnborg [Thu, 5 Jun 2008 18:47:46 +0000 (11:47 -0700)]
sparc: Merge include/asm-sparc{,64}/openpromio.h

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agosparc: remove PROM_AP1000
Adrian Bunk [Thu, 5 Jun 2008 18:45:42 +0000 (11:45 -0700)]
sparc: remove PROM_AP1000

This seems to be left from the long gone AP1000 support.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agodrivers/sbus/: cleanups
Adrian Bunk [Thu, 5 Jun 2008 18:44:39 +0000 (11:44 -0700)]
drivers/sbus/: cleanups

This patch contains the following cleanups:
- make the following needlessly global code static:
  - char/uctrl.c: uctrl_get_event_status()
  - char/uctrl.c: uctrl_get_external_status()
  - char/vfc_dev.c: struct vfc_dev_lst
  - char/vfc_dev.c: vfc_lock_device()
  - char/vfc_dev.c: vfc_unlock_device()
  - char/vfc_dev.c: vfc_captstat_reset()
  - char/vfc_dev.c: vfc_memptr_reset()
  - char/vfc_dev.c: vfc_csr_init()
  - char/vfc_dev.c: vfc_saa9051_init()
  - char/vfc_dev.c: init_vfc_hw()
  - char/vfc_dev.c: init_vfc_devstruct()
  - char/vfc_dev.c: init_vfc_device()
  - char/vfc_dev.c: vfc_get_dev_ptr()
  - char/vfc_dev.c: vfc_capture_start()
  - char/vfc_dev.c: vfc_capture_poll()
  - char/vfc_dev.c: vfc_port_change_ioctl()
  - char/vfc_dev.c: vfc_set_video_ioctl()
  - char/vfc_dev.c: vfc_get_video_ioctl()
  - char/vfc_i2c.c: vfc_i2c_wait_for_bus()
  - char/vfc_i2c.c: vfc_i2c_wait_for_pin()
  - char/vfc_i2c.c: vfc_i2c_xmit_addr()
  - char/vfc_i2c.c: vfc_i2c_xmit_byte()
  - char/vfc_i2c.c: vfc_i2c_recv_byte()
  - dvma.c: init_one_dvma()
- remove an unused variable from a function:
  - char/uctrl.c: ts102_uctrl_init()
- remove the following unused and empty function:
  - char/uctrl.c: uctrl_set_video()

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agosparc64/kernel/: make code static
Adrian Bunk [Thu, 5 Jun 2008 18:42:40 +0000 (11:42 -0700)]
sparc64/kernel/: make code static

This patch makes the following needlessly global code static:
- central.c: struct central_bus
- central.c: struct fhc_list
- central.c: apply_fhc_ranges()
- central.c: apply_central_ranges()
- ds.c: struct ds_states_template[]
- pci_msi.c: sparc64_setup_msi_irq()
- pci_msi.c: sparc64_teardown_msi_irq()
- pci_sun4v.c: struct sun4v_dma_ops
- sys_sparc32.c: cp_compat_stat64()

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agosparc/mm/: possible cleanups
Adrian Bunk [Thu, 5 Jun 2008 18:41:51 +0000 (11:41 -0700)]
sparc/mm/: possible cleanups

This patch contains the following possible cleanups:
- make the following needlessly global code static:
  - fault.c: force_user_fault()
  - init.c: calc_max_low_pfn()
  - init.c: pgt_cache_water[]
  - init.c: map_high_region()
  - srmmu.c: hwbug_bitmask
  - srmmu.c: srmmu_swapper_pg_dir
  - srmmu.c: srmmu_context_table
  - srmmu.c: is_hypersparc
  - srmmu.c: srmmu_cache_pagetables
  - srmmu.c: srmmu_nocache_size
  - srmmu.c: srmmu_nocache_end
  - srmmu.c: srmmu_get_nocache()
  - srmmu.c: srmmu_free_nocache()
  - srmmu.c: srmmu_early_allocate_ptable_skeleton()
  - srmmu.c: srmmu_nocache_calcsize()
  - srmmu.c: srmmu_nocache_init()
  - srmmu.c: srmmu_alloc_thread_info()
  - srmmu.c: early_pgtable_allocfail()
  - srmmu.c: srmmu_early_allocate_ptable_skeleton()
  - srmmu.c: srmmu_allocate_ptable_skeleton()
  - srmmu.c: srmmu_inherit_prom_mappings()
  - sunami.S: tsunami_copy_1page
- remove the following unused code:
  - init.c: struct sparc_aliases

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agosparc/kernel/: possible cleanups
Adrian Bunk [Thu, 5 Jun 2008 18:40:58 +0000 (11:40 -0700)]
sparc/kernel/: possible cleanups

This patch contains the following possible cleanups:
- make the following needlessly global code static:
  - apc.c: apc_swift_idle()
  - ebus.c: ebus_blacklist_irq()
  - ebus.c: fill_ebus_child()
  - ebus.c: fill_ebus_device()
  - entry.S: syscall_is_too_hard
  - etra: tsetup_sun4c_stackchk
  - head.S: cputyp
  - head.S: prom_vector_p
  - idprom.c: Sun_Machines[]
  - ioport.c: _sparc_find_resource()
  - ioport.c: create_proc_read_entry()
  - irq.c: struct sparc_irq[]
  - rtrap.S: sun4c_rett_stackchk
  - setup.c: prom_sync_me()
  - setup.c: boot_flags
  - sun4c_irq.c: sun4c_sbint_to_irq()
  - sun4d_irq.c: sbus_tid[]
  - sun4d_irq.c: struct sbus_actions
  - sun4d_irq.c: sun4d_sbint_to_irq()
  - sun4m_irq.c: sun4m_sbint_to_irq()
  - sun4m_irq.c: sun4m_get_irqmask()
  - sun4m_irq.c: sun4m_timers
  - sun4m_smp.c: smp4m_cross_call()
  - sun4m_smp.c: smp4m_blackbox_id()
  - sun4m_smp.c: smp4m_blackbox_current()
  - time.c: sp_clock_typ
  - time.c: sbus_time_init()
  - traps.c: instruction_dump()
  - wof.S: spwin_sun4c_stackchk
  - wuf.S: sun4c_fwin_stackchk
- #if 0 the following unused code:
  - process.c: sparc_backtrace_lock
  - process.c: __show_backtrace()
  - process.c: show_backtrace()
  - process.c: smp_show_backtrace_all_cpus()
- remove the following unused code:
  - entry.S: __handle_exception
  - smp.c: smp_num_cpus
  - smp.c: smp_activated
  - smp.c: __cpu_number_map[]
  - smp.c: __cpu_logical_map[]
  - smp.c: bitops_spinlock
  - traps.c: trap_curbuf
  - traps.c: trapbuf[]
  - traps.c: linux_smp_still_initting
  - traps.c: thiscpus_tbr
  - traps.c: thiscpus_mid

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: Make default qdisc nonshared-multiqueue safe.
David S. Miller [Thu, 17 Jul 2008 08:46:06 +0000 (01:46 -0700)]
pkt_sched: Make default qdisc nonshared-multiqueue safe.

Instead of 'pfifo_fast' we have just plain 'fifo_fast'.
No priority queues, just a straight FIFO.

This is necessary in order to legally have a seperate
qdisc per queue in multi-TX-queue setups, and thus get
full parallelization.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: Don't used locked skb_queue_purge() in __qdisc_reset_queue()
David S. Miller [Thu, 17 Jul 2008 11:03:43 +0000 (04:03 -0700)]
pkt_sched: Don't used locked skb_queue_purge() in __qdisc_reset_queue()

We have to have exclusive access to the given qdisc anyways, so
doing even more locking is superfluous.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: Add multiqueue handling to qdisc_graft().
David S. Miller [Thu, 17 Jul 2008 11:54:10 +0000 (04:54 -0700)]
pkt_sched: Add multiqueue handling to qdisc_graft().

Move the destruction of the old queue into qdisc_graft().

When operating on a root qdisc (ie. "parent == NULL"), apply
the operation to all queues.  The caller has grabbed a single
implicit reference for this graft, therefore when we apply the
change to more than one queue we must grab additional qdisc
references.

Otherwise, we are operating on a class of a specific parent qdisc, and
therefore no multiqueue handling is necessary.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: Kill netdev_queue lock.
David S. Miller [Thu, 17 Jul 2008 07:53:03 +0000 (00:53 -0700)]
pkt_sched: Kill netdev_queue lock.

We can simply use the qdisc->q.lock for all of the
qdisc tree synchronization.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: Kill qdisc_lock_tree and qdisc_unlock_tree.
David S. Miller [Wed, 16 Jul 2008 10:22:39 +0000 (03:22 -0700)]
pkt_sched: Kill qdisc_lock_tree and qdisc_unlock_tree.

No longer used.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: Rework {sch,tbf}_tree_lock().
David S. Miller [Wed, 16 Jul 2008 10:12:24 +0000 (03:12 -0700)]
pkt_sched: Rework {sch,tbf}_tree_lock().

Make sch_tree_lock() lock the qdisc's root.  All of the
users hold the RTNL semaphore and the root qdisc is not
changing.

Implement tbf_tree_{lock,unlock}() simply in terms of
sch_tree_{lock,unlock}().

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: Make qdisc grafting locking more specific.
David S. Miller [Wed, 16 Jul 2008 10:00:19 +0000 (03:00 -0700)]
pkt_sched: Make qdisc grafting locking more specific.

Lock the root of the qdisc being operated upon.

All explicit references to qdisc_tree_lock() are now gone.
The only remaining uses are via the sch_tree_{lock,unlock}()
and tcf_tree_{lock,unlock}() macros.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agonetdevice: Move qdisc_list back into net_device proper.
David S. Miller [Thu, 17 Jul 2008 07:50:32 +0000 (00:50 -0700)]
netdevice: Move qdisc_list back into net_device proper.

And give it it's own lock.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: Kill qdisc_lock_tree usage in cls_route.c
David S. Miller [Wed, 16 Jul 2008 09:42:51 +0000 (02:42 -0700)]
pkt_sched: Kill qdisc_lock_tree usage in cls_route.c

It just wants the qdisc tree to be synchronized, so grabbing
qdisc_root_lock() is sufficient.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: Remove qdisc_lock_tree usage in cls_api.c
David S. Miller [Wed, 16 Jul 2008 09:40:45 +0000 (02:40 -0700)]
pkt_sched: Remove qdisc_lock_tree usage in cls_api.c

It just wants the qdisc tree for the filter to be synchronized.
So just BH lock qdisc_root_lock(q) instead.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: Use per-queue locking in shutdown_scheduler_queue.
David S. Miller [Wed, 16 Jul 2008 09:36:04 +0000 (02:36 -0700)]
pkt_sched: Use per-queue locking in shutdown_scheduler_queue.

This eliminates another qdisc_lock_tree user.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: Perform bulk of qdisc destruction in RCU.
David S. Miller [Thu, 17 Jul 2008 07:47:45 +0000 (00:47 -0700)]
pkt_sched: Perform bulk of qdisc destruction in RCU.

This allows less strict control of access to the qdisc attached to a
netdev_queue.  It is even allowed to enqueue into a qdisc which is
in the process of being destroyed.  The RCU handler will toss out
those packets.

We will need this to handle sharing of a qdisc amongst multiple
TX queues.  In such a setup the lock has to be shared, so will
be inside of the qdisc itself.  At which point the netdev_queue
lock cannot be used to hard synchronize access to the ->qdisc
pointer.

One operation we have to keep inside of qdisc_destroy() is the list
deletion.  It is the only piece of state visible after the RCU quiesce
period, so we have to undo it early and under the appropriate locking.

The operations in the RCU handler do not need any looking because the
qdisc tree is no longer visible to anything at that point.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: dev_init_scheduler() does not need to lock qdisc tree.
David S. Miller [Wed, 16 Jul 2008 09:23:17 +0000 (02:23 -0700)]
pkt_sched: dev_init_scheduler() does not need to lock qdisc tree.

We are registering the device, there is no way anyone can get
at this object's qdiscs yet in any meaningful way.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: Schedule qdiscs instead of netdev_queue.
David S. Miller [Wed, 16 Jul 2008 09:15:04 +0000 (02:15 -0700)]
pkt_sched: Schedule qdiscs instead of netdev_queue.

When we have shared qdiscs, packets come out of the qdiscs
for multiple transmit queues.

Therefore it doesn't make any sense to schedule the transmit
queue when logically we cannot know ahead of time the TX
queue of the SKB that the qdisc->dequeue() will give us.

Just for sanity I added a BUG check to make sure we never
get into a state where the noop_qdisc is scheduled.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: Add and use qdisc_root() and qdisc_root_lock().
David S. Miller [Wed, 16 Jul 2008 08:42:40 +0000 (01:42 -0700)]
pkt_sched: Add and use qdisc_root() and qdisc_root_lock().

When code wants to lock the qdisc tree state, the logic
operation it's doing is locking the top-level qdisc that
sits of the root of the netdev_queue.

Add qdisc_root_lock() to represent this and convert the
easiest cases.

In order for this to work out in all cases, we have to
hook up the noop_qdisc to a dummy netdev_queue.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: Make QDISC_RUNNING a qdisc state.
David S. Miller [Wed, 16 Jul 2008 07:56:32 +0000 (00:56 -0700)]
pkt_sched: Make QDISC_RUNNING a qdisc state.

Currently it is associated with a netdev_queue, but when we have
qdisc sharing that no longer makes any sense.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: Move gso_skb into Qdisc.
David S. Miller [Wed, 16 Jul 2008 03:14:35 +0000 (20:14 -0700)]
pkt_sched: Move gso_skb into Qdisc.

We liberate any dangling gso_skb during qdisc destruction.

It really only matters for the root qdisc.  But when qdiscs
can be shared by multiple netdev_queue objects, we can't
have the gso_skb in the netdev_queue any more.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agoniu: Add TX multiqueue support.
David S. Miller [Tue, 15 Jul 2008 10:48:19 +0000 (03:48 -0700)]
niu: Add TX multiqueue support.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agonetdev: Kill plain netif_schedule()
David S. Miller [Tue, 15 Jul 2008 10:48:01 +0000 (03:48 -0700)]
netdev: Kill plain netif_schedule()

No more users.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agonetdev: Convert all drivers away from netif_schedule().
David S. Miller [Tue, 15 Jul 2008 10:47:41 +0000 (03:47 -0700)]
netdev: Convert all drivers away from netif_schedule().

They logically all want to trigger a schedule for all device
TX queues.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agonet: Implement simple sw TX hashing.
David S. Miller [Tue, 15 Jul 2008 10:47:03 +0000 (03:47 -0700)]
net: Implement simple sw TX hashing.

It just xor hashes over IPv4/IPv6 addresses and ports of transport.

The only assumption it makes is that skb_network_header() is set
correctly.

With bug fixes from Eric Dumazet.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agomac80211: Reimplement WME using ->select_queue().
David S. Miller [Tue, 15 Jul 2008 10:34:57 +0000 (03:34 -0700)]
mac80211: Reimplement WME using ->select_queue().

The only behavior change is that we do not drop packets under any
circumstances.  If that is absolutely needed, we could easily add it
back.

With cleanups and help from Johannes Berg.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agonetdev: Add netdev->select_queue() method.
David S. Miller [Tue, 15 Jul 2008 10:03:33 +0000 (03:03 -0700)]
netdev: Add netdev->select_queue() method.

Devices or device layers can set this to control the queue selection
performed by dev_pick_tx().

This function runs under RCU protection, which allows overriding
functions to have some way of synchronizing with things like dynamic
->real_num_tx_queues adjustments.

This makes the spinlock prefetch in dev_queue_xmit() a little bit
less effective, but that's the price right now for correctness.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agonetdev: netdev_priv() can now be sane again.
David S. Miller [Tue, 15 Jul 2008 09:58:39 +0000 (02:58 -0700)]
netdev: netdev_priv() can now be sane again.

The private area of a netdev is now at a fixed offset once more.

Unfortunately, some assumptions that netdev_priv() == netdev->priv
crept back into the tree.  In particular this happened in the
loopback driver.  Make it use netdev->ml_priv.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agonetdev: Kill struct net_device_subqueue and netdev->egress_subqueue*
David S. Miller [Tue, 15 Jul 2008 09:58:10 +0000 (02:58 -0700)]
netdev: Kill struct net_device_subqueue and netdev->egress_subqueue*

No longer used.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agonet: Use queue aware tests throughout.
David S. Miller [Thu, 17 Jul 2008 08:56:23 +0000 (01:56 -0700)]
net: Use queue aware tests throughout.

This effectively "flips the switch" by making the core networking
and multiqueue-aware drivers use the new TX multiqueue structures.

Non-multiqueue drivers need no changes.  The interfaces they use such
as netif_stop_queue() degenerate into an operation on TX queue zero.
So everything "just works" for them.

Code that really wants to do "X" to all TX queues now invokes a
routine that does so, such as netif_tx_wake_all_queues(),
netif_tx_stop_all_queues(), etc.

pktgen and netpoll required a little bit more surgery than the others.

In particular the pktgen changes, whilst functional, could be largely
improved.  The initial check in pktgen_xmit() will sometimes check the
wrong queue, which is mostly harmless.  The thing to do is probably to
invoke fill_packet() earlier.

The bulk of the netpoll changes is to make the code operate solely on
the TX queue indicated by by the SKB queue mapping.

Setting of the SKB queue mapping is entirely confined inside of
net/core/dev.c:dev_pick_tx().  If we end up needing any kind of
special semantics (drops, for example) it will be implemented here.

Finally, we now have a "real_num_tx_queues" which is where the driver
indicates how many TX queues are actually active.

With IGB changes from Jeff Kirsher.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agomac80211: Temporarily mark QoS support BROKEN.
David S. Miller [Tue, 15 Jul 2008 09:53:04 +0000 (02:53 -0700)]
mac80211: Temporarily mark QoS support BROKEN.

We will undo this after a few changsets.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agopkt_sched: Remove RR scheduler.
David S. Miller [Tue, 15 Jul 2008 09:52:19 +0000 (02:52 -0700)]
pkt_sched: Remove RR scheduler.

This actually fixes a bug added by the RR scheduler changes.  The
->bands and ->prio2band parameters were being set outside of the
sch_tree_lock() and thus could result in strange behavior and
inconsistencies.

It might be possible, in the new design (where there will be one qdisc
per device TX queue) to allow similar functionality via a TX hash
algorithm for RR but I really see no reason to export this aspect of
how these multiqueue cards actually implement the scheduling of the
the individual DMA TX rings and the single physical MAC/PHY port.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agonetdev: Kill NETIF_F_MULTI_QUEUE.
David S. Miller [Thu, 17 Jul 2008 08:52:12 +0000 (01:52 -0700)]
netdev: Kill NETIF_F_MULTI_QUEUE.

There is no need for a feature bit for something that
can be tested by simply checking the TX queue count.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agonetdev: Allocate multiple queues for TX.
David S. Miller [Thu, 17 Jul 2008 07:34:19 +0000 (00:34 -0700)]
netdev: Allocate multiple queues for TX.

alloc_netdev_mq() now allocates an array of netdev_queue
structures for TX, based upon the queue_count argument.

Furthermore, all accesses to the TX queues are now vectored
through the netdev_get_tx_queue() and netdev_for_each_tx_queue()
interfaces.  This makes it easy to grep the tree for all
things that want to get to a TX queue of a net device.

Problem spots which are not really multiqueue aware yet, and
only work with one queue, can easily be spotted by grepping
for all netdev_get_tx_queue() calls that pass in a zero index.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agoigb: Kill CONFIG_NETDEVICES_MULTIQUEUE references, no longer exists.
David S. Miller [Thu, 17 Jul 2008 08:50:11 +0000 (01:50 -0700)]
igb: Kill CONFIG_NETDEVICES_MULTIQUEUE references, no longer exists.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agoiop_adma: cleanup iop_chan_xor_slot_count
Dan Williams [Fri, 18 Jul 2008 00:59:56 +0000 (17:59 -0700)]
iop_adma: cleanup iop_chan_xor_slot_count

- use a table for iop13xx, trade text for data
- shrink the iop3xx to a cache line

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
17 years agoiop_adma: document how to calculate the minimum descriptor pool size
Dan Williams [Fri, 18 Jul 2008 00:59:56 +0000 (17:59 -0700)]
iop_adma: document how to calculate the minimum descriptor pool size

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
17 years agoiop_adma: directly reclaim descriptors on allocation failure
Dan Williams [Fri, 18 Jul 2008 00:59:56 +0000 (17:59 -0700)]
iop_adma: directly reclaim descriptors on allocation failure

Force callers that trigger an "out of descriptors" condition to run the
cleanup loop directly.  Alleviates the requirement to have soft-irqs
enabled when polling for a descriptor in async_xor.

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
17 years agoasync_tx: make async_tx_test_ack a boolean routine
Dan Williams [Fri, 18 Jul 2008 00:59:56 +0000 (17:59 -0700)]
async_tx: make async_tx_test_ack a boolean routine

Signed-off-by: Dan Williams <dan.j.williams@intel.com>