Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
0d7e0daa
Commit
0d7e0daa
authored
Jan 14, 2005
by
Linus Torvalds
Browse files
Options
Browse Files
Download
Plain Diff
Merge
bk://linux-dj.bkbits.net/cpufreq
into ppc970.osdl.org:/home/torvalds/v2.6/linux
parents
a93e105a
5ed500c5
Changes
68
Hide whitespace changes
Inline
Side-by-side
Showing
68 changed files
with
556 additions
and
380 deletions
+556
-380
Documentation/serial/driver
Documentation/serial/driver
+9
-2
MAINTAINERS
MAINTAINERS
+7
-0
arch/arm/mach-s3c2410/clock.c
arch/arm/mach-s3c2410/clock.c
+30
-30
arch/arm/mach-s3c2410/clock.h
arch/arm/mach-s3c2410/clock.h
+3
-3
arch/arm/mach-s3c2410/cpu.c
arch/arm/mach-s3c2410/cpu.c
+30
-1
arch/arm/mach-s3c2410/cpu.h
arch/arm/mach-s3c2410/cpu.h
+3
-0
arch/arm/mach-s3c2410/mach-bast.c
arch/arm/mach-s3c2410/mach-bast.c
+1
-0
arch/arm/mach-s3c2410/mach-h1940.c
arch/arm/mach-s3c2410/mach-h1940.c
+2
-0
arch/arm/mach-s3c2410/mach-rx3715.c
arch/arm/mach-s3c2410/mach-rx3715.c
+2
-2
arch/arm/mach-s3c2410/mach-smdk2410.c
arch/arm/mach-s3c2410/mach-smdk2410.c
+1
-0
arch/arm/mach-s3c2410/mach-vr1000.c
arch/arm/mach-s3c2410/mach-vr1000.c
+2
-0
arch/arm/mach-s3c2410/s3c2410.c
arch/arm/mach-s3c2410/s3c2410.c
+6
-6
arch/arm/mach-s3c2410/s3c2410.h
arch/arm/mach-s3c2410/s3c2410.h
+4
-0
arch/arm/mach-s3c2410/s3c2440.c
arch/arm/mach-s3c2410/s3c2440.c
+18
-17
arch/arm/mach-s3c2410/s3c2440.h
arch/arm/mach-s3c2410/s3c2440.h
+4
-0
arch/arm/mm/ioremap.c
arch/arm/mm/ioremap.c
+1
-1
arch/arm/mm/proc-v6.S
arch/arm/mm/proc-v6.S
+1
-0
arch/arm/vfp/entry.S
arch/arm/vfp/entry.S
+1
-1
arch/ia64/ia32/ia32_entry.S
arch/ia64/ia32/ia32_entry.S
+1
-1
arch/mips/kernel/scall64-n32.S
arch/mips/kernel/scall64-n32.S
+1
-1
arch/mips/kernel/scall64-o32.S
arch/mips/kernel/scall64-o32.S
+1
-1
arch/parisc/kernel/syscall_table.S
arch/parisc/kernel/syscall_table.S
+1
-1
arch/ppc64/kernel/misc.S
arch/ppc64/kernel/misc.S
+1
-1
arch/s390/kernel/compat_wrapper.S
arch/s390/kernel/compat_wrapper.S
+3
-3
arch/s390/kernel/syscalls.S
arch/s390/kernel/syscalls.S
+1
-1
arch/sparc64/kernel/systbls.S
arch/sparc64/kernel/systbls.S
+1
-1
arch/x86_64/ia32/ia32entry.S
arch/x86_64/ia32/ia32entry.S
+1
-1
drivers/ide/arm/icside.c
drivers/ide/arm/icside.c
+1
-30
drivers/ide/cris/ide-v10.c
drivers/ide/cris/ide-v10.c
+1
-18
drivers/ide/ide-cd.c
drivers/ide/ide-cd.c
+1
-14
drivers/ide/ide-default.c
drivers/ide/ide-default.c
+1
-0
drivers/ide/ide-dma.c
drivers/ide/ide-dma.c
+1
-1
drivers/ide/ide-io.c
drivers/ide/ide-io.c
+1
-10
drivers/ide/ide-lib.c
drivers/ide/ide-lib.c
+6
-8
drivers/ide/ide-probe.c
drivers/ide/ide-probe.c
+1
-1
drivers/ide/ide.c
drivers/ide/ide.c
+3
-33
drivers/ide/pci/atiixp.c
drivers/ide/pci/atiixp.c
+3
-2
drivers/ide/pci/piix.c
drivers/ide/pci/piix.c
+3
-0
drivers/ide/pci/piix.h
drivers/ide/pci/piix.h
+1
-0
drivers/mmc/mmc_block.c
drivers/mmc/mmc_block.c
+12
-0
drivers/pci/pci.ids
drivers/pci/pci.ids
+1
-0
drivers/pcmcia/Makefile
drivers/pcmcia/Makefile
+1
-0
drivers/pcmcia/pxa2xx_sharpsl.c
drivers/pcmcia/pxa2xx_sharpsl.c
+264
-0
drivers/serial/serial_core.c
drivers/serial/serial_core.c
+15
-1
include/linux/ide.h
include/linux/ide.h
+1
-4
include/linux/in6.h
include/linux/in6.h
+2
-0
include/linux/ipv6.h
include/linux/ipv6.h
+1
-2
include/linux/pci_ids.h
include/linux/pci_ids.h
+4
-2
include/linux/udp.h
include/linux/udp.h
+9
-13
include/net/addrconf.h
include/net/addrconf.h
+0
-1
include/net/icmp.h
include/net/icmp.h
+7
-8
include/net/ipv6.h
include/net/ipv6.h
+0
-2
kernel/compat.c
kernel/compat.c
+1
-1
kernel/spinlock.c
kernel/spinlock.c
+8
-6
net/core/dv.c
net/core/dv.c
+9
-16
net/ipv4/raw.c
net/ipv4/raw.c
+6
-5
net/ipv4/tcp.c
net/ipv4/tcp.c
+12
-6
net/ipv4/udp.c
net/ipv4/udp.c
+8
-8
net/ipv6/addrconf.c
net/ipv6/addrconf.c
+2
-7
net/ipv6/anycast.c
net/ipv6/anycast.c
+3
-1
net/ipv6/exthdrs.c
net/ipv6/exthdrs.c
+0
-77
net/ipv6/icmp.c
net/ipv6/icmp.c
+1
-1
net/ipv6/ip6_output.c
net/ipv6/ip6_output.c
+4
-4
net/ipv6/ipv6_syms.c
net/ipv6/ipv6_syms.c
+0
-2
net/ipv6/mcast.c
net/ipv6/mcast.c
+18
-14
net/ipv6/route.c
net/ipv6/route.c
+2
-2
net/ipv6/sysctl_net_ipv6.c
net/ipv6/sysctl_net_ipv6.c
+1
-1
net/ipv6/udp.c
net/ipv6/udp.c
+5
-5
No files found.
Documentation/serial/driver
View file @
0d7e0daa
...
@@ -211,18 +211,25 @@ hardware.
...
@@ -211,18 +211,25 @@ hardware.
Yes 1 1 character received, marked as
Yes 1 1 character received, marked as
TTY_PARITY
TTY_PARITY
Other flags may be used (eg, xon/xoff characters) if your
hardware supports hardware "soft" flow control.
Locking: none.
Locking: none.
Interrupts: caller dependent.
Interrupts: caller dependent.
This call must not sleep
This call must not sleep
pm(port,state,oldstate)
pm(port,state,oldstate)
p
erform any power management related activities on the specified
P
erform any power management related activities on the specified
port.
s
tate indicates the new state (defined by ACPI D0-D3),
port.
S
tate indicates the new state (defined by ACPI D0-D3),
oldstate indicates the previous state. Essentially, D0 means
oldstate indicates the previous state. Essentially, D0 means
fully on, D3 means powered down.
fully on, D3 means powered down.
This function should not be used to grab any resources.
This function should not be used to grab any resources.
This will be called when the port is initially opened and finally
closed, except when the port is also the system console. This
will occur even if CONFIG_PM is not set.
Locking: none.
Locking: none.
Interrupts: caller dependent.
Interrupts: caller dependent.
...
...
MAINTAINERS
View file @
0d7e0daa
...
@@ -2093,6 +2093,13 @@ L: sparclinux@vger.kernel.org
...
@@ -2093,6 +2093,13 @@ L: sparclinux@vger.kernel.org
L: ultralinux@vger.kernel.org
L: ultralinux@vger.kernel.org
S: Maintained
S: Maintained
SHARP LH SUPPORT (LH7952X & LH7A40X)
P: Marc Singer
M: elf@buici.com
W: http://projects.buici.com/arm
L: linux-arm-kernel@lists.arm.linux.org.uk
S: Maintained
SPARC (sparc32):
SPARC (sparc32):
P: William L. Irwin
P: William L. Irwin
M: wli@holomorphy.com
M: wli@holomorphy.com
...
...
arch/arm/mach-s3c2410/clock.c
View file @
0d7e0daa
...
@@ -60,7 +60,7 @@ static DECLARE_MUTEX(clocks_sem);
...
@@ -60,7 +60,7 @@ static DECLARE_MUTEX(clocks_sem);
/* old functions */
/* old functions */
void
inline
s3c24
10
_clk_enable
(
unsigned
int
clocks
,
unsigned
int
enable
)
void
inline
s3c24
xx
_clk_enable
(
unsigned
int
clocks
,
unsigned
int
enable
)
{
{
unsigned
long
clkcon
;
unsigned
long
clkcon
;
unsigned
long
flags
;
unsigned
long
flags
;
...
@@ -88,9 +88,9 @@ static int clk_null_enable(struct clk *clk, int enable)
...
@@ -88,9 +88,9 @@ static int clk_null_enable(struct clk *clk, int enable)
return
0
;
return
0
;
}
}
int
s3c24
10
_clkcon_enable
(
struct
clk
*
clk
,
int
enable
)
int
s3c24
xx
_clkcon_enable
(
struct
clk
*
clk
,
int
enable
)
{
{
s3c24
10
_clk_enable
(
clk
->
ctrlbit
,
enable
);
s3c24
xx
_clk_enable
(
clk
->
ctrlbit
,
enable
);
return
0
;
return
0
;
}
}
...
@@ -264,90 +264,90 @@ static struct clk init_clocks[] = {
...
@@ -264,90 +264,90 @@ static struct clk init_clocks[] = {
{
.
name
=
"nand"
,
{
.
name
=
"nand"
,
.
id
=
-
1
,
.
id
=
-
1
,
.
parent
=
&
clk_h
,
.
parent
=
&
clk_h
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2410_CLKCON_NAND
.
ctrlbit
=
S3C2410_CLKCON_NAND
},
},
{
.
name
=
"lcd"
,
{
.
name
=
"lcd"
,
.
id
=
-
1
,
.
id
=
-
1
,
.
parent
=
&
clk_h
,
.
parent
=
&
clk_h
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2410_CLKCON_LCDC
.
ctrlbit
=
S3C2410_CLKCON_LCDC
},
},
{
.
name
=
"usb-host"
,
{
.
name
=
"usb-host"
,
.
id
=
-
1
,
.
id
=
-
1
,
.
parent
=
&
clk_h
,
.
parent
=
&
clk_h
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2410_CLKCON_USBH
.
ctrlbit
=
S3C2410_CLKCON_USBH
},
},
{
.
name
=
"usb-device"
,
{
.
name
=
"usb-device"
,
.
id
=
-
1
,
.
id
=
-
1
,
.
parent
=
&
clk_h
,
.
parent
=
&
clk_h
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2410_CLKCON_USBD
.
ctrlbit
=
S3C2410_CLKCON_USBD
},
},
{
.
name
=
"timers"
,
{
.
name
=
"timers"
,
.
parent
=
&
clk_p
,
.
parent
=
&
clk_p
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2410_CLKCON_PWMT
.
ctrlbit
=
S3C2410_CLKCON_PWMT
},
},
{
.
name
=
"sdi"
,
{
.
name
=
"sdi"
,
.
id
=
-
1
,
.
id
=
-
1
,
.
parent
=
&
clk_p
,
.
parent
=
&
clk_p
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2410_CLKCON_SDI
.
ctrlbit
=
S3C2410_CLKCON_SDI
},
},
{
.
name
=
"uart"
,
{
.
name
=
"uart"
,
.
id
=
0
,
.
id
=
0
,
.
parent
=
&
clk_p
,
.
parent
=
&
clk_p
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2410_CLKCON_UART0
.
ctrlbit
=
S3C2410_CLKCON_UART0
},
},
{
.
name
=
"uart"
,
{
.
name
=
"uart"
,
.
id
=
1
,
.
id
=
1
,
.
parent
=
&
clk_p
,
.
parent
=
&
clk_p
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2410_CLKCON_UART1
.
ctrlbit
=
S3C2410_CLKCON_UART1
},
},
{
.
name
=
"uart"
,
{
.
name
=
"uart"
,
.
id
=
2
,
.
id
=
2
,
.
parent
=
&
clk_p
,
.
parent
=
&
clk_p
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2410_CLKCON_UART2
.
ctrlbit
=
S3C2410_CLKCON_UART2
},
},
{
.
name
=
"gpio"
,
{
.
name
=
"gpio"
,
.
id
=
-
1
,
.
id
=
-
1
,
.
parent
=
&
clk_p
,
.
parent
=
&
clk_p
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2410_CLKCON_GPIO
.
ctrlbit
=
S3C2410_CLKCON_GPIO
},
},
{
.
name
=
"rtc"
,
{
.
name
=
"rtc"
,
.
id
=
-
1
,
.
id
=
-
1
,
.
parent
=
&
clk_p
,
.
parent
=
&
clk_p
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2410_CLKCON_RTC
.
ctrlbit
=
S3C2410_CLKCON_RTC
},
},
{
.
name
=
"adc"
,
{
.
name
=
"adc"
,
.
id
=
-
1
,
.
id
=
-
1
,
.
parent
=
&
clk_p
,
.
parent
=
&
clk_p
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2410_CLKCON_ADC
.
ctrlbit
=
S3C2410_CLKCON_ADC
},
},
{
.
name
=
"i2c"
,
{
.
name
=
"i2c"
,
.
id
=
-
1
,
.
id
=
-
1
,
.
parent
=
&
clk_p
,
.
parent
=
&
clk_p
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2410_CLKCON_IIC
.
ctrlbit
=
S3C2410_CLKCON_IIC
},
},
{
.
name
=
"iis"
,
{
.
name
=
"iis"
,
.
id
=
-
1
,
.
id
=
-
1
,
.
parent
=
&
clk_p
,
.
parent
=
&
clk_p
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2410_CLKCON_IIS
.
ctrlbit
=
S3C2410_CLKCON_IIS
},
},
{
.
name
=
"spi"
,
{
.
name
=
"spi"
,
.
id
=
-
1
,
.
id
=
-
1
,
.
parent
=
&
clk_p
,
.
parent
=
&
clk_p
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2410_CLKCON_SPI
.
ctrlbit
=
S3C2410_CLKCON_SPI
},
},
{
.
name
=
"watchdog"
,
{
.
name
=
"watchdog"
,
...
@@ -359,7 +359,7 @@ static struct clk init_clocks[] = {
...
@@ -359,7 +359,7 @@ static struct clk init_clocks[] = {
/* initialise the clock system */
/* initialise the clock system */
int
s3c24
10
_register_clock
(
struct
clk
*
clk
)
int
s3c24
xx
_register_clock
(
struct
clk
*
clk
)
{
{
clk
->
owner
=
THIS_MODULE
;
clk
->
owner
=
THIS_MODULE
;
atomic_set
(
&
clk
->
used
,
0
);
atomic_set
(
&
clk
->
used
,
0
);
...
@@ -378,7 +378,7 @@ int s3c2410_register_clock(struct clk *clk)
...
@@ -378,7 +378,7 @@ int s3c2410_register_clock(struct clk *clk)
/* initalise all the clocks */
/* initalise all the clocks */
int
__init
s3c24
10_init
_clocks
(
void
)
int
__init
s3c24
xx_setup
_clocks
(
void
)
{
{
struct
clk
*
clkp
=
init_clocks
;
struct
clk
*
clkp
=
init_clocks
;
int
ptr
;
int
ptr
;
...
@@ -403,28 +403,28 @@ int __init s3c2410_init_clocks(void)
...
@@ -403,28 +403,28 @@ int __init s3c2410_init_clocks(void)
* and of course, this looks neater
* and of course, this looks neater
*/
*/
s3c24
10
_clk_enable
(
S3C2410_CLKCON_NAND
,
0
);
s3c24
xx
_clk_enable
(
S3C2410_CLKCON_NAND
,
0
);
s3c24
10
_clk_enable
(
S3C2410_CLKCON_USBH
,
0
);
s3c24
xx
_clk_enable
(
S3C2410_CLKCON_USBH
,
0
);
s3c24
10
_clk_enable
(
S3C2410_CLKCON_USBD
,
0
);
s3c24
xx
_clk_enable
(
S3C2410_CLKCON_USBD
,
0
);
s3c24
10
_clk_enable
(
S3C2410_CLKCON_ADC
,
0
);
s3c24
xx
_clk_enable
(
S3C2410_CLKCON_ADC
,
0
);
s3c24
10
_clk_enable
(
S3C2410_CLKCON_IIC
,
0
);
s3c24
xx
_clk_enable
(
S3C2410_CLKCON_IIC
,
0
);
s3c24
10
_clk_enable
(
S3C2410_CLKCON_SPI
,
0
);
s3c24
xx
_clk_enable
(
S3C2410_CLKCON_SPI
,
0
);
/* assume uart clocks are correctly setup */
/* assume uart clocks are correctly setup */
/* register our clocks */
/* register our clocks */
if
(
s3c24
10
_register_clock
(
&
clk_f
)
<
0
)
if
(
s3c24
xx
_register_clock
(
&
clk_f
)
<
0
)
printk
(
KERN_ERR
"failed to register cpu fclk
\n
"
);
printk
(
KERN_ERR
"failed to register cpu fclk
\n
"
);
if
(
s3c24
10
_register_clock
(
&
clk_h
)
<
0
)
if
(
s3c24
xx
_register_clock
(
&
clk_h
)
<
0
)
printk
(
KERN_ERR
"failed to register cpu hclk
\n
"
);
printk
(
KERN_ERR
"failed to register cpu hclk
\n
"
);
if
(
s3c24
10
_register_clock
(
&
clk_p
)
<
0
)
if
(
s3c24
xx
_register_clock
(
&
clk_p
)
<
0
)
printk
(
KERN_ERR
"failed to register cpu pclk
\n
"
);
printk
(
KERN_ERR
"failed to register cpu pclk
\n
"
);
for
(
ptr
=
0
;
ptr
<
ARRAY_SIZE
(
init_clocks
);
ptr
++
,
clkp
++
)
{
for
(
ptr
=
0
;
ptr
<
ARRAY_SIZE
(
init_clocks
);
ptr
++
,
clkp
++
)
{
ret
=
s3c24
10
_register_clock
(
clkp
);
ret
=
s3c24
xx
_register_clock
(
clkp
);
if
(
ret
<
0
)
{
if
(
ret
<
0
)
{
printk
(
KERN_ERR
"Failed to register clock %s (%d)
\n
"
,
printk
(
KERN_ERR
"Failed to register clock %s (%d)
\n
"
,
clkp
->
name
,
ret
);
clkp
->
name
,
ret
);
...
...
arch/arm/mach-s3c2410/clock.h
View file @
0d7e0daa
...
@@ -41,7 +41,7 @@ extern unsigned long s3c24xx_fclk;
...
@@ -41,7 +41,7 @@ extern unsigned long s3c24xx_fclk;
* Please DO NOT use these outside of arch/arm/mach-s3c2410
* Please DO NOT use these outside of arch/arm/mach-s3c2410
*/
*/
extern
int
s3c2410_clkcon_enable
(
struct
clk
*
clk
,
int
enable
);
extern
int
s3c24xx_clkcon_enable
(
struct
clk
*
clk
,
int
enable
);
extern
int
s3c2410_register_clock
(
struct
clk
*
clk
);
extern
int
s3c24xx_register_clock
(
struct
clk
*
clk
);
extern
int
s3c2410_init_clocks
(
void
);
extern
int
s3c24xx_setup_clocks
(
void
);
arch/arm/mach-s3c2410/cpu.c
View file @
0d7e0daa
...
@@ -47,6 +47,7 @@ struct cpu_table {
...
@@ -47,6 +47,7 @@ struct cpu_table {
unsigned
long
idmask
;
unsigned
long
idmask
;
void
(
*
map_io
)(
struct
map_desc
*
mach_desc
,
int
size
);
void
(
*
map_io
)(
struct
map_desc
*
mach_desc
,
int
size
);
void
(
*
init_uarts
)(
struct
s3c2410_uartcfg
*
cfg
,
int
no
);
void
(
*
init_uarts
)(
struct
s3c2410_uartcfg
*
cfg
,
int
no
);
void
(
*
init_clocks
)(
int
xtal
);
int
(
*
init
)(
void
);
int
(
*
init
)(
void
);
const
char
*
name
;
const
char
*
name
;
};
};
...
@@ -63,6 +64,7 @@ static struct cpu_table cpu_ids[] __initdata = {
...
@@ -63,6 +64,7 @@ static struct cpu_table cpu_ids[] __initdata = {
.
idcode
=
0x32410000
,
.
idcode
=
0x32410000
,
.
idmask
=
0xffffffff
,
.
idmask
=
0xffffffff
,
.
map_io
=
s3c2410_map_io
,
.
map_io
=
s3c2410_map_io
,
.
init_clocks
=
s3c2410_init_clocks
,
.
init_uarts
=
s3c2410_init_uarts
,
.
init_uarts
=
s3c2410_init_uarts
,
.
init
=
s3c2410_init
,
.
init
=
s3c2410_init
,
.
name
=
name_s3c2410
.
name
=
name_s3c2410
...
@@ -71,6 +73,7 @@ static struct cpu_table cpu_ids[] __initdata = {
...
@@ -71,6 +73,7 @@ static struct cpu_table cpu_ids[] __initdata = {
.
idcode
=
0x32410002
,
.
idcode
=
0x32410002
,
.
idmask
=
0xffffffff
,
.
idmask
=
0xffffffff
,
.
map_io
=
s3c2410_map_io
,
.
map_io
=
s3c2410_map_io
,
.
init_clocks
=
s3c2410_init_clocks
,
.
init_uarts
=
s3c2410_init_uarts
,
.
init_uarts
=
s3c2410_init_uarts
,
.
init
=
s3c2410_init
,
.
init
=
s3c2410_init
,
.
name
=
name_s3c2410a
.
name
=
name_s3c2410a
...
@@ -79,6 +82,7 @@ static struct cpu_table cpu_ids[] __initdata = {
...
@@ -79,6 +82,7 @@ static struct cpu_table cpu_ids[] __initdata = {
.
idcode
=
0x32440000
,
.
idcode
=
0x32440000
,
.
idmask
=
0xffffffff
,
.
idmask
=
0xffffffff
,
.
map_io
=
s3c2440_map_io
,
.
map_io
=
s3c2440_map_io
,
.
init_clocks
=
s3c2440_init_clocks
,
.
init_uarts
=
s3c2440_init_uarts
,
.
init_uarts
=
s3c2440_init_uarts
,
.
init
=
s3c2440_init
,
.
init
=
s3c2440_init
,
.
name
=
name_s3c2440
.
name
=
name_s3c2440
...
@@ -87,6 +91,7 @@ static struct cpu_table cpu_ids[] __initdata = {
...
@@ -87,6 +91,7 @@ static struct cpu_table cpu_ids[] __initdata = {
.
idcode
=
0x32440001
,
.
idcode
=
0x32440001
,
.
idmask
=
0xffffffff
,
.
idmask
=
0xffffffff
,
.
map_io
=
s3c2440_map_io
,
.
map_io
=
s3c2440_map_io
,
.
init_clocks
=
s3c2440_init_clocks
,
.
init_uarts
=
s3c2440_init_uarts
,
.
init_uarts
=
s3c2440_init_uarts
,
.
init
=
s3c2440_init
,
.
init
=
s3c2440_init
,
.
name
=
name_s3c2440a
.
name
=
name_s3c2440a
...
@@ -132,7 +137,7 @@ void s3c24xx_set_board(struct s3c24xx_board *b)
...
@@ -132,7 +137,7 @@ void s3c24xx_set_board(struct s3c24xx_board *b)
struct
clk
**
ptr
=
b
->
clocks
;;
struct
clk
**
ptr
=
b
->
clocks
;;
for
(
i
=
b
->
clocks_count
;
i
>
0
;
i
--
,
ptr
++
)
for
(
i
=
b
->
clocks_count
;
i
>
0
;
i
--
,
ptr
++
)
s3c24
10
_register_clock
(
*
ptr
);
s3c24
xx
_register_clock
(
*
ptr
);
}
}
}
}
...
@@ -165,6 +170,29 @@ void __init s3c24xx_init_io(struct map_desc *mach_desc, int size)
...
@@ -165,6 +170,29 @@ void __init s3c24xx_init_io(struct map_desc *mach_desc, int size)
(
cpu
->
map_io
)(
mach_desc
,
size
);
(
cpu
->
map_io
)(
mach_desc
,
size
);
}
}
/* s3c24xx_init_clocks
*
* Initialise the clock subsystem and associated information from the
* given master crystal value.
*
* xtal = 0 -> use default PLL crystal value (normally 12MHz)
* != 0 -> PLL crystal value in Hz
*/
void
__init
s3c24xx_init_clocks
(
int
xtal
)
{
if
(
xtal
!=
0
)
s3c24xx_xtal
=
xtal
;
if
(
cpu
==
NULL
)
panic
(
"s3c24xx_init_clocks: no cpu setup?
\n
"
);
if
(
cpu
->
init_clocks
==
NULL
)
panic
(
"s3c24xx_init_clocks: cpu has no clock init
\n
"
);
else
(
cpu
->
init_clocks
)(
xtal
);
}
void
__init
s3c24xx_init_uarts
(
struct
s3c2410_uartcfg
*
cfg
,
int
no
)
void
__init
s3c24xx_init_uarts
(
struct
s3c2410_uartcfg
*
cfg
,
int
no
)
{
{
if
(
cpu
==
NULL
)
if
(
cpu
==
NULL
)
...
@@ -175,6 +203,7 @@ void __init s3c24xx_init_uarts(struct s3c2410_uartcfg *cfg, int no)
...
@@ -175,6 +203,7 @@ void __init s3c24xx_init_uarts(struct s3c2410_uartcfg *cfg, int no)
}
else
}
else
(
cpu
->
init_uarts
)(
cfg
,
no
);
(
cpu
->
init_uarts
)(
cfg
,
no
);
}
}
static
int
__init
s3c_arch_init
(
void
)
static
int
__init
s3c_arch_init
(
void
)
{
{
int
ret
;
int
ret
;
...
...
arch/arm/mach-s3c2410/cpu.h
View file @
0d7e0daa
...
@@ -14,6 +14,7 @@
...
@@ -14,6 +14,7 @@
* 18-Oct-2004 BJD Moved board struct into this file
* 18-Oct-2004 BJD Moved board struct into this file
* 04-Jan-2005 BJD New uart initialisation
* 04-Jan-2005 BJD New uart initialisation
* 10-Jan-2005 BJD Moved generic init here, specific to cpu headers
* 10-Jan-2005 BJD Moved generic init here, specific to cpu headers
* 14-Jan-2005 BJD Added s3c24xx_init_clocks() call
*/
*/
#define IODESC_ENT(x) { S3C2410_VA_##x, S3C2410_PA_##x, S3C2410_SZ_##x, MT_DEVICE }
#define IODESC_ENT(x) { S3C2410_VA_##x, S3C2410_PA_##x, S3C2410_SZ_##x, MT_DEVICE }
...
@@ -35,6 +36,8 @@ extern void s3c24xx_init_io(struct map_desc *mach_desc, int size);
...
@@ -35,6 +36,8 @@ extern void s3c24xx_init_io(struct map_desc *mach_desc, int size);
extern
void
s3c24xx_init_uarts
(
struct
s3c2410_uartcfg
*
cfg
,
int
no
);
extern
void
s3c24xx_init_uarts
(
struct
s3c2410_uartcfg
*
cfg
,
int
no
);
extern
void
s3c24xx_init_clocks
(
int
xtal
);
/* the board structure is used at first initialsation time
/* the board structure is used at first initialsation time
* to get info such as the devices to register for this
* to get info such as the devices to register for this
* board. This is done because platfrom_add_devices() cannot
* board. This is done because platfrom_add_devices() cannot
...
...
arch/arm/mach-s3c2410/mach-bast.c
View file @
0d7e0daa
...
@@ -263,6 +263,7 @@ void __init bast_map_io(void)
...
@@ -263,6 +263,7 @@ void __init bast_map_io(void)
s3c24xx_uclk
.
parent
=
&
s3c24xx_clkout1
;
s3c24xx_uclk
.
parent
=
&
s3c24xx_clkout1
;
s3c24xx_init_io
(
bast_iodesc
,
ARRAY_SIZE
(
bast_iodesc
));
s3c24xx_init_io
(
bast_iodesc
,
ARRAY_SIZE
(
bast_iodesc
));
s3c24xx_init_clocks
(
0
);
s3c24xx_init_uarts
(
bast_uartcfgs
,
ARRAY_SIZE
(
bast_uartcfgs
));
s3c24xx_init_uarts
(
bast_uartcfgs
,
ARRAY_SIZE
(
bast_uartcfgs
));
s3c24xx_set_board
(
&
bast_board
);
s3c24xx_set_board
(
&
bast_board
);
usb_simtec_init
();
usb_simtec_init
();
...
...
arch/arm/mach-s3c2410/mach-h1940.c
View file @
0d7e0daa
...
@@ -22,6 +22,7 @@
...
@@ -22,6 +22,7 @@
* 04-Nov-2004 BJD Change for new serial clock
* 04-Nov-2004 BJD Change for new serial clock
* 04-Jan-2005 BJD Updated uart init call
* 04-Jan-2005 BJD Updated uart init call
* 10-Jan-2005 BJD Removed include of s3c2410.h
* 10-Jan-2005 BJD Removed include of s3c2410.h
* 14-Jan-2005 BJD Added clock init
*/
*/
#include <linux/kernel.h>
#include <linux/kernel.h>
...
@@ -103,6 +104,7 @@ static struct s3c24xx_board h1940_board __initdata = {
...
@@ -103,6 +104,7 @@ static struct s3c24xx_board h1940_board __initdata = {
void
__init
h1940_map_io
(
void
)
void
__init
h1940_map_io
(
void
)
{
{
s3c24xx_init_io
(
h1940_iodesc
,
ARRAY_SIZE
(
h1940_iodesc
));
s3c24xx_init_io
(
h1940_iodesc
,
ARRAY_SIZE
(
h1940_iodesc
));
s3c24xx_init_clocks
(
0
);
s3c24xx_init_uarts
(
h1940_uartcfgs
,
ARRAY_SIZE
(
h1940_uartcfgs
));
s3c24xx_init_uarts
(
h1940_uartcfgs
,
ARRAY_SIZE
(
h1940_uartcfgs
));
s3c24xx_set_board
(
&
h1940_board
);
s3c24xx_set_board
(
&
h1940_board
);
}
}
...
...
arch/arm/mach-s3c2410/mach-rx3715.c
View file @
0d7e0daa
...
@@ -13,6 +13,7 @@
...
@@ -13,6 +13,7 @@
* 16-Sep-2004 BJD Copied from mach-h1940.c
* 16-Sep-2004 BJD Copied from mach-h1940.c
* 25-Oct-2004 BJD Updates for 2.6.10-rc1
* 25-Oct-2004 BJD Updates for 2.6.10-rc1
* 10-Jan-2005 BJD Removed include of s3c2410.h s3c2440.h
* 10-Jan-2005 BJD Removed include of s3c2410.h s3c2440.h
* 14-Jan-2005 BJD Added new clock init
*/
*/
#include <linux/kernel.h>
#include <linux/kernel.h>
...
@@ -91,9 +92,8 @@ static struct s3c24xx_board rx3715_board __initdata = {
...
@@ -91,9 +92,8 @@ static struct s3c24xx_board rx3715_board __initdata = {
void
__init
rx3715_map_io
(
void
)
void
__init
rx3715_map_io
(
void
)
{
{
s3c24xx_xtal
=
16934000
;
s3c24xx_init_io
(
rx3715_iodesc
,
ARRAY_SIZE
(
rx3715_iodesc
));
s3c24xx_init_io
(
rx3715_iodesc
,
ARRAY_SIZE
(
rx3715_iodesc
));
s3c24xx_init_clocks
(
16934000
);
s3c24xx_init_uarts
(
rx3715_uartcfgs
,
ARRAY_SIZE
(
rx3715_uartcfgs
));
s3c24xx_init_uarts
(
rx3715_uartcfgs
,
ARRAY_SIZE
(
rx3715_uartcfgs
));
s3c24xx_set_board
(
&
rx3715_board
);
s3c24xx_set_board
(
&
rx3715_board
);
}
}
...
...
arch/arm/mach-s3c2410/mach-smdk2410.c
View file @
0d7e0daa
...
@@ -97,6 +97,7 @@ static struct s3c24xx_board smdk2410_board __initdata = {
...
@@ -97,6 +97,7 @@ static struct s3c24xx_board smdk2410_board __initdata = {
void
__init
smdk2410_map_io
(
void
)
void
__init
smdk2410_map_io
(
void
)
{
{
s3c24xx_init_io
(
smdk2410_iodesc
,
ARRAY_SIZE
(
smdk2410_iodesc
));
s3c24xx_init_io
(
smdk2410_iodesc
,
ARRAY_SIZE
(
smdk2410_iodesc
));
s3c24xx_init_clocks
(
0
);
s3c24xx_init_uarts
(
smdk2410_uartcfgs
,
ARRAY_SIZE
(
smdk2410_uartcfgs
));
s3c24xx_init_uarts
(
smdk2410_uartcfgs
,
ARRAY_SIZE
(
smdk2410_uartcfgs
));
s3c24xx_set_board
(
&
smdk2410_board
);
s3c24xx_set_board
(
&
smdk2410_board
);
}
}
...
...
arch/arm/mach-s3c2410/mach-vr1000.c
View file @
0d7e0daa
...
@@ -20,6 +20,7 @@
...
@@ -20,6 +20,7 @@
* 04-Nov-2004 BJD Clock and serial configuration update
* 04-Nov-2004 BJD Clock and serial configuration update
* 04-Jan-2005 BJD Updated uart init call
* 04-Jan-2005 BJD Updated uart init call
* 10-Jan-2005 BJD Removed include of s3c2410.h
* 10-Jan-2005 BJD Removed include of s3c2410.h
* 14-Jan-2005 BJD Added clock init
*/
*/
#include <linux/kernel.h>
#include <linux/kernel.h>
...
@@ -205,6 +206,7 @@ void __init vr1000_map_io(void)
...
@@ -205,6 +206,7 @@ void __init vr1000_map_io(void)
s3c24xx_uclk
.
parent
=
&
s3c24xx_clkout1
;
s3c24xx_uclk
.
parent
=
&
s3c24xx_clkout1
;
s3c24xx_init_io
(
vr1000_iodesc
,
ARRAY_SIZE
(
vr1000_iodesc
));
s3c24xx_init_io
(
vr1000_iodesc
,
ARRAY_SIZE
(
vr1000_iodesc
));
s3c24xx_init_clocks
(
0
);
s3c24xx_init_uarts
(
vr1000_uartcfgs
,
ARRAY_SIZE
(
vr1000_uartcfgs
));
s3c24xx_init_uarts
(
vr1000_uartcfgs
,
ARRAY_SIZE
(
vr1000_uartcfgs
));
s3c24xx_set_board
(
&
vr1000_board
);
s3c24xx_set_board
(
&
vr1000_board
);
usb_simtec_init
();
usb_simtec_init
();
...
...
arch/arm/mach-s3c2410/s3c2410.c
View file @
0d7e0daa
...
@@ -151,19 +151,19 @@ void __init s3c2410_init_uarts(struct s3c2410_uartcfg *cfg, int no)
...
@@ -151,19 +151,19 @@ void __init s3c2410_init_uarts(struct s3c2410_uartcfg *cfg, int no)
*
*
* register the standard cpu IO areas, and any passed in from the
* register the standard cpu IO areas, and any passed in from the
* machine specific initialisation.
* machine specific initialisation.
*
* this function also sets the initial clock frequencies from the
* settings passed in
*/
*/
void
__init
s3c2410_map_io
(
struct
map_desc
*
mach_desc
,
int
mach_size
)
void
__init
s3c2410_map_io
(
struct
map_desc
*
mach_desc
,
int
mach_size
)
{
{
unsigned
long
tmp
;
/* register our io-tables */
/* register our io-tables */
iotable_init
(
s3c2410_iodesc
,
ARRAY_SIZE
(
s3c2410_iodesc
));
iotable_init
(
s3c2410_iodesc
,
ARRAY_SIZE
(
s3c2410_iodesc
));
iotable_init
(
mach_desc
,
mach_size
);
iotable_init
(
mach_desc
,
mach_size
);
}
void
__init
s3c2410_init_clocks
(
int
xtal
)
{
unsigned
long
tmp
;
/* now we've got our machine bits initialised, work out what
/* now we've got our machine bits initialised, work out what
* clocks we've got */
* clocks we've got */
...
@@ -188,7 +188,7 @@ void __init s3c2410_map_io(struct map_desc *mach_desc, int mach_size)
...
@@ -188,7 +188,7 @@ void __init s3c2410_map_io(struct map_desc *mach_desc, int mach_size)
* console to use them
* console to use them
*/
*/
s3c24
10_init
_clocks
();
s3c24
xx_setup
_clocks
();
}
}
int
__init
s3c2410_init
(
void
)
int
__init
s3c2410_init
(
void
)
...
...
arch/arm/mach-s3c2410/s3c2410.h
View file @
0d7e0daa
...
@@ -16,6 +16,7 @@
...
@@ -16,6 +16,7 @@
* 17-Oct-2004 BJD Moved board out to cpu
* 17-Oct-2004 BJD Moved board out to cpu
* 04-Jan-2005 BJD Changed uart init
* 04-Jan-2005 BJD Changed uart init
* 10-Jan-2005 BJD Removed timer to cpu.h, moved 2410 specific bits here
* 10-Jan-2005 BJD Removed timer to cpu.h, moved 2410 specific bits here
* 14-Jan-2005 BJD Added s3c2410_init_clocks call
*/
*/
#ifdef CONFIG_CPU_S3C2410
#ifdef CONFIG_CPU_S3C2410
...
@@ -26,7 +27,10 @@ extern void s3c2410_map_io(struct map_desc *mach_desc, int size);
...
@@ -26,7 +27,10 @@ extern void s3c2410_map_io(struct map_desc *mach_desc, int size);
extern
void
s3c2410_init_uarts
(
struct
s3c2410_uartcfg
*
cfg
,
int
no
);
extern
void
s3c2410_init_uarts
(
struct
s3c2410_uartcfg
*
cfg
,
int
no
);
extern
void
s3c2410_init_clocks
(
int
xtal
);
#else
#else
#define s3c2410_init_clocks NULL
#define s3c2410_init_uarts NULL
#define s3c2410_init_uarts NULL
#define s3c2410_map_io NULL
#define s3c2410_map_io NULL
#define s3c2410_init NULL
#define s3c2410_init NULL
...
...
arch/arm/mach-s3c2410/s3c2440.c
View file @
0d7e0daa
/* linux/arch/arm/mach-s3c2410/s3c2440.c
/* linux/arch/arm/mach-s3c2410/s3c2440.c
*
*
* Copyright (c) 2004 Simtec Electronics
* Copyright (c) 2004
-2005
Simtec Electronics
* Ben Dooks <ben@simtec.co.uk>
* Ben Dooks <ben@simtec.co.uk>
*
*
* Samsung S3C2440 Mobile CPU support
* Samsung S3C2440 Mobile CPU support
...
@@ -16,6 +16,8 @@
...
@@ -16,6 +16,8 @@
* 09-Nov-2004 BJD Added sysdev for power management
* 09-Nov-2004 BJD Added sysdev for power management
* 04-Nov-2004 BJD New serial registration
* 04-Nov-2004 BJD New serial registration
* 15-Nov-2004 BJD Rename the i2c device for the s3c2440
* 15-Nov-2004 BJD Rename the i2c device for the s3c2440
* 14-Jan-2005 BJD Moved clock init code into seperate function
* 14-Jan-2005 BJD Removed un-used clock bits
*/
*/
#include <linux/kernel.h>
#include <linux/kernel.h>
...
@@ -48,10 +50,6 @@
...
@@ -48,10 +50,6 @@
#include "cpu.h"
#include "cpu.h"
#include "pm.h"
#include "pm.h"
int
s3c2440_clock_tick_rate
=
12
*
1000
*
1000
;
/* current timers at 12MHz */
/* clock info */
unsigned
long
s3c2440_hdiv
;
static
struct
map_desc
s3c2440_iodesc
[]
__initdata
=
{
static
struct
map_desc
s3c2440_iodesc
[]
__initdata
=
{
IODESC_ENT
(
USBHOST
),
IODESC_ENT
(
USBHOST
),
...
@@ -155,13 +153,13 @@ void __init s3c2440_init_uarts(struct s3c2410_uartcfg *cfg, int no)
...
@@ -155,13 +153,13 @@ void __init s3c2440_init_uarts(struct s3c2410_uartcfg *cfg, int no)
static
struct
clk
s3c2440_clk_cam
=
{
static
struct
clk
s3c2440_clk_cam
=
{
.
name
=
"camera"
,
.
name
=
"camera"
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2440_CLKCON_CAMERA
.
ctrlbit
=
S3C2440_CLKCON_CAMERA
};
};
static
struct
clk
s3c2440_clk_ac97
=
{
static
struct
clk
s3c2440_clk_ac97
=
{
.
name
=
"ac97"
,
.
name
=
"ac97"
,
.
enable
=
s3c24
10
_clkcon_enable
,
.
enable
=
s3c24
xx
_clkcon_enable
,
.
ctrlbit
=
S3C2440_CLKCON_CAMERA
.
ctrlbit
=
S3C2440_CLKCON_CAMERA
};
};
...
@@ -204,13 +202,20 @@ static struct sys_device s3c2440_sysdev = {
...
@@ -204,13 +202,20 @@ static struct sys_device s3c2440_sysdev = {
void
__init
s3c2440_map_io
(
struct
map_desc
*
mach_desc
,
int
size
)
void
__init
s3c2440_map_io
(
struct
map_desc
*
mach_desc
,
int
size
)
{
{
unsigned
long
clkdiv
;
unsigned
long
camdiv
;
/* register our io-tables */
/* register our io-tables */
iotable_init
(
s3c2440_iodesc
,
ARRAY_SIZE
(
s3c2440_iodesc
));
iotable_init
(
s3c2440_iodesc
,
ARRAY_SIZE
(
s3c2440_iodesc
));
iotable_init
(
mach_desc
,
size
);
iotable_init
(
mach_desc
,
size
);
/* rename any peripherals used differing from the s3c2410 */
s3c_device_i2c
.
name
=
"s3c2440-i2c"
;
}
void
__init
s3c2440_init_clocks
(
int
xtal
)
{
unsigned
long
clkdiv
;
unsigned
long
camdiv
;
int
s3c2440_hdiv
=
1
;
/* now we've got our machine bits initialised, work out what
/* now we've got our machine bits initialised, work out what
* clocks we've got */
* clocks we've got */
...
@@ -254,22 +259,18 @@ void __init s3c2440_map_io(struct map_desc *mach_desc, int size)
...
@@ -254,22 +259,18 @@ void __init s3c2440_map_io(struct map_desc *mach_desc, int size)
* console to use them, and to add new ones after the initialisation
* console to use them, and to add new ones after the initialisation
*/
*/
s3c24
10_init
_clocks
();
s3c24
xx_setup
_clocks
();
/* add s3c2440 specific clocks */
/* add s3c2440 specific clocks */
s3c2440_clk_cam
.
parent
=
clk_get
(
NULL
,
"hclk"
);
s3c2440_clk_cam
.
parent
=
clk_get
(
NULL
,
"hclk"
);
s3c2440_clk_ac97
.
parent
=
clk_get
(
NULL
,
"pclk"
);
s3c2440_clk_ac97
.
parent
=
clk_get
(
NULL
,
"pclk"
);
s3c24
10
_register_clock
(
&
s3c2440_clk_ac97
);
s3c24
xx
_register_clock
(
&
s3c2440_clk_ac97
);
s3c24
10
_register_clock
(
&
s3c2440_clk_cam
);
s3c24
xx
_register_clock
(
&
s3c2440_clk_cam
);
clk_disable
(
&
s3c2440_clk_ac97
);
clk_disable
(
&
s3c2440_clk_ac97
);
clk_disable
(
&
s3c2440_clk_cam
);
clk_disable
(
&
s3c2440_clk_cam
);
/* rename any peripherals used differing from the s3c2410 */
s3c_device_i2c
.
name
=
"s3c2440-i2c"
;
}
}
int
__init
s3c2440_init
(
void
)
int
__init
s3c2440_init
(
void
)
...
...
arch/arm/mach-s3c2410/s3c2440.h
View file @
0d7e0daa
...
@@ -14,6 +14,7 @@
...
@@ -14,6 +14,7 @@
* 04-Nov-2004 BJD Added s3c2440_init_uarts()
* 04-Nov-2004 BJD Added s3c2440_init_uarts()
* 04-Jan-2005 BJD Moved uart init to cpu code
* 04-Jan-2005 BJD Moved uart init to cpu code
* 10-Jan-2005 BJD Moved 2440 specific init here
* 10-Jan-2005 BJD Moved 2440 specific init here
* 14-Jan-2005 BJD Split the clock initialisation code
*/
*/
#ifdef CONFIG_CPU_S3C2440
#ifdef CONFIG_CPU_S3C2440
...
@@ -24,7 +25,10 @@ extern void s3c2440_map_io(struct map_desc *mach_desc, int size);
...
@@ -24,7 +25,10 @@ extern void s3c2440_map_io(struct map_desc *mach_desc, int size);
extern
void
s3c2440_init_uarts
(
struct
s3c2410_uartcfg
*
cfg
,
int
no
);
extern
void
s3c2440_init_uarts
(
struct
s3c2410_uartcfg
*
cfg
,
int
no
);
extern
void
s3c2440_init_clocks
(
int
xtal
);
#else
#else
#define s3c2440_init_clocks NULL
#define s3c2440_init_uarts NULL
#define s3c2440_init_uarts NULL
#define s3c2440_map_io NULL
#define s3c2440_map_io NULL
#define s3c2440_init NULL
#define s3c2440_init NULL
...
...
arch/arm/mm/ioremap.c
View file @
0d7e0daa
...
@@ -148,7 +148,7 @@ __ioremap(unsigned long phys_addr, size_t size, unsigned long flags,
...
@@ -148,7 +148,7 @@ __ioremap(unsigned long phys_addr, size_t size, unsigned long flags,
*/
*/
offset
=
phys_addr
&
~
PAGE_MASK
;
offset
=
phys_addr
&
~
PAGE_MASK
;
phys_addr
&=
PAGE_MASK
;
phys_addr
&=
PAGE_MASK
;
size
=
PAGE_ALIGN
(
last_addr
)
-
phys_addr
;
size
=
PAGE_ALIGN
(
last_addr
+
1
)
-
phys_addr
;
/*
/*
* Ok, go for it..
* Ok, go for it..
...
...
arch/arm/mm/proc-v6.S
View file @
0d7e0daa
...
@@ -105,6 +105,7 @@ ENTRY(cpu_v6_dcache_clean_area)
...
@@ -105,6 +105,7 @@ ENTRY(cpu_v6_dcache_clean_area)
ENTRY
(
cpu_v6_switch_mm
)
ENTRY
(
cpu_v6_switch_mm
)
mov
r2
,
#
0
mov
r2
,
#
0
ldr
r1
,
[
r1
,
#
MM_CONTEXT_ID
]
@
get
mm
->
context
.
id
ldr
r1
,
[
r1
,
#
MM_CONTEXT_ID
]
@
get
mm
->
context
.
id
mcr
p15
,
0
,
r2
,
c7
,
c5
,
6
@
flush
BTAC
/
BTB
mcr
p15
,
0
,
r2
,
c7
,
c10
,
4
@
drain
write
buffer
mcr
p15
,
0
,
r2
,
c7
,
c10
,
4
@
drain
write
buffer
mcr
p15
,
0
,
r0
,
c2
,
c0
,
0
@
set
TTB
0
mcr
p15
,
0
,
r0
,
c2
,
c0
,
0
@
set
TTB
0
mcr
p15
,
0
,
r1
,
c13
,
c0
,
1
@
set
context
ID
mcr
p15
,
0
,
r1
,
c13
,
c0
,
1
@
set
context
ID
...
...
arch/arm/vfp/entry.S
View file @
0d7e0daa
...
@@ -17,7 +17,7 @@
...
@@ -17,7 +17,7 @@
*/
*/
#include <linux/linkage.h>
#include <linux/linkage.h>
#include <linux/init.h>
#include <linux/init.h>
#include <asm/
thread_info
.h>
#include <asm/
constants
.h>
#include <asm/vfpmacros.h>
#include <asm/vfpmacros.h>
.
globl
do_vfp
.
globl
do_vfp
...
...
arch/ia64/ia32/ia32_entry.S
View file @
0d7e0daa
...
@@ -387,7 +387,7 @@ ia32_syscall_table:
...
@@ -387,7 +387,7 @@ ia32_syscall_table:
data8
sys32_rt_sigaction
data8
sys32_rt_sigaction
data8
sys32_rt_sigprocmask
/*
175
*/
data8
sys32_rt_sigprocmask
/*
175
*/
data8
sys_rt_sigpending
data8
sys_rt_sigpending
data8
compat_rt_sigtimedwait
data8
compat_
sys_
rt_sigtimedwait
data8
sys32_rt_sigqueueinfo
data8
sys32_rt_sigqueueinfo
data8
sys32_rt_sigsuspend
data8
sys32_rt_sigsuspend
data8
sys32_pread
/*
180
*/
data8
sys32_pread
/*
180
*/
...
...
arch/mips/kernel/scall64-n32.S
View file @
0d7e0daa
...
@@ -243,7 +243,7 @@ EXPORT(sysn32_call_table)
...
@@ -243,7 +243,7 @@ EXPORT(sysn32_call_table)
PTR
sys_capget
PTR
sys_capget
PTR
sys_capset
PTR
sys_capset
PTR
sys32_rt_sigpending
/*
6125
*/
PTR
sys32_rt_sigpending
/*
6125
*/
PTR
compat_rt_sigtimedwait
PTR
compat_
sys_
rt_sigtimedwait
PTR
sys32_rt_sigqueueinfo
PTR
sys32_rt_sigqueueinfo
PTR
sys32_rt_sigsuspend
PTR
sys32_rt_sigsuspend
PTR
sys32_sigaltstack
PTR
sys32_sigaltstack
...
...
arch/mips/kernel/scall64-o32.S
View file @
0d7e0daa
...
@@ -420,7 +420,7 @@ sys_call_table:
...
@@ -420,7 +420,7 @@ sys_call_table:
PTR
sys32_rt_sigaction
PTR
sys32_rt_sigaction
PTR
sys32_rt_sigprocmask
/*
4195
*/
PTR
sys32_rt_sigprocmask
/*
4195
*/
PTR
sys32_rt_sigpending
PTR
sys32_rt_sigpending
PTR
compat_rt_sigtimedwait
PTR
compat_
sys_
rt_sigtimedwait
PTR
sys32_rt_sigqueueinfo
PTR
sys32_rt_sigqueueinfo
PTR
sys32_rt_sigsuspend
PTR
sys32_rt_sigsuspend
PTR
sys32_pread
/*
4200
*/
PTR
sys32_pread
/*
4200
*/
...
...
arch/parisc/kernel/syscall_table.S
View file @
0d7e0daa
...
@@ -275,7 +275,7 @@
...
@@ -275,7 +275,7 @@
ENTRY_DIFF
(
rt_sigaction
)
ENTRY_DIFF
(
rt_sigaction
)
ENTRY_DIFF
(
rt_sigprocmask
)
/*
175
*/
ENTRY_DIFF
(
rt_sigprocmask
)
/*
175
*/
ENTRY_DIFF
(
rt_sigpending
)
ENTRY_DIFF
(
rt_sigpending
)
ENTRY_
UHOH
(
rt_sigtimedwait
)
ENTRY_
COMP
(
rt_sigtimedwait
)
/
*
even
though
the
struct
siginfo_t
is
different
,
it
appears
like
/
*
even
though
the
struct
siginfo_t
is
different
,
it
appears
like
*
all
the
paths
use
values
which
should
be
same
wide
and
narrow
.
*
all
the
paths
use
values
which
should
be
same
wide
and
narrow
.
*
Also
the
struct
is
padded
to
128
bytes
which
means
we
don
't have
*
Also
the
struct
is
padded
to
128
bytes
which
means
we
don
't have
...
...
arch/ppc64/kernel/misc.S
View file @
0d7e0daa
...
@@ -843,7 +843,7 @@ _GLOBAL(sys_call_table32)
...
@@ -843,7 +843,7 @@ _GLOBAL(sys_call_table32)
.
llong
.
sys32_rt_sigaction
.
llong
.
sys32_rt_sigaction
.
llong
.
sys32_rt_sigprocmask
.
llong
.
sys32_rt_sigprocmask
.
llong
.
sys32_rt_sigpending
/*
175
*/
.
llong
.
sys32_rt_sigpending
/*
175
*/
.
llong
.
compat_rt_sigtimedwait
.
llong
.
compat_
sys_
rt_sigtimedwait
.
llong
.
sys32_rt_sigqueueinfo
.
llong
.
sys32_rt_sigqueueinfo
.
llong
.
ppc32_rt_sigsuspend
.
llong
.
ppc32_rt_sigsuspend
.
llong
.
sys32_pread64
.
llong
.
sys32_pread64
...
...
arch/s390/kernel/compat_wrapper.S
View file @
0d7e0daa
...
@@ -840,13 +840,13 @@ sys32_rt_sigpending_wrapper:
...
@@ -840,13 +840,13 @@ sys32_rt_sigpending_wrapper:
llgfr
%
r3
,%
r3
#
size_t
llgfr
%
r3
,%
r3
#
size_t
jg
sys32_rt_sigpending
#
branch
to
system
call
jg
sys32_rt_sigpending
#
branch
to
system
call
.
globl
compat_rt_sigtimedwait_wrapper
.
globl
compat_
sys_
rt_sigtimedwait_wrapper
compat_rt_sigtimedwait_wrapper
:
compat_
sys_
rt_sigtimedwait_wrapper
:
llgtr
%
r2
,%
r2
#
const
sigset_emu31_t
*
llgtr
%
r2
,%
r2
#
const
sigset_emu31_t
*
llgtr
%
r3
,%
r3
#
siginfo_emu31_t
*
llgtr
%
r3
,%
r3
#
siginfo_emu31_t
*
llgtr
%
r4
,%
r4
#
const
struct
compat_timespec
*
llgtr
%
r4
,%
r4
#
const
struct
compat_timespec
*
llgfr
%
r5
,%
r5
#
size_t
llgfr
%
r5
,%
r5
#
size_t
jg
compat_rt_sigtimedwait
#
branch
to
system
call
jg
compat_
sys_
rt_sigtimedwait
#
branch
to
system
call
.
globl
sys32_rt_sigqueueinfo_wrapper
.
globl
sys32_rt_sigqueueinfo_wrapper
sys32_rt_sigqueueinfo_wrapper
:
sys32_rt_sigqueueinfo_wrapper
:
...
...
arch/s390/kernel/syscalls.S
View file @
0d7e0daa
...
@@ -185,7 +185,7 @@ SYSCALL(sys_rt_sigreturn_glue,sys_rt_sigreturn_glue,sys32_rt_sigreturn_glue)
...
@@ -185,7 +185,7 @@ SYSCALL(sys_rt_sigreturn_glue,sys_rt_sigreturn_glue,sys32_rt_sigreturn_glue)
SYSCALL
(
sys_rt_sigaction
,
sys_rt_sigaction
,
sys32_rt_sigaction_wrapper
)
SYSCALL
(
sys_rt_sigaction
,
sys_rt_sigaction
,
sys32_rt_sigaction_wrapper
)
SYSCALL
(
sys_rt_sigprocmask
,
sys_rt_sigprocmask
,
sys32_rt_sigprocmask_wrapper
)
/
*
175
*/
SYSCALL
(
sys_rt_sigprocmask
,
sys_rt_sigprocmask
,
sys32_rt_sigprocmask_wrapper
)
/
*
175
*/
SYSCALL
(
sys_rt_sigpending
,
sys_rt_sigpending
,
sys32_rt_sigpending_wrapper
)
SYSCALL
(
sys_rt_sigpending
,
sys_rt_sigpending
,
sys32_rt_sigpending_wrapper
)
SYSCALL
(
sys_rt_sigtimedwait
,
sys_rt_sigtimedwait
,
compat_rt_sigtimedwait_wrapper
)
SYSCALL
(
sys_rt_sigtimedwait
,
sys_rt_sigtimedwait
,
compat_
sys_
rt_sigtimedwait_wrapper
)
SYSCALL
(
sys_rt_sigqueueinfo
,
sys_rt_sigqueueinfo
,
sys32_rt_sigqueueinfo_wrapper
)
SYSCALL
(
sys_rt_sigqueueinfo
,
sys_rt_sigqueueinfo
,
sys32_rt_sigqueueinfo_wrapper
)
SYSCALL
(
sys_rt_sigsuspend_glue
,
sys_rt_sigsuspend_glue
,
sys32_rt_sigsuspend_glue
)
SYSCALL
(
sys_rt_sigsuspend_glue
,
sys_rt_sigsuspend_glue
,
sys32_rt_sigsuspend_glue
)
SYSCALL
(
sys_pread64
,
sys_pread64
,
sys32_pread64_wrapper
)
/
*
180
*/
SYSCALL
(
sys_pread64
,
sys_pread64
,
sys32_pread64_wrapper
)
/
*
180
*/
...
...
arch/sparc64/kernel/systbls.S
View file @
0d7e0daa
...
@@ -41,7 +41,7 @@ sys_call_table32:
...
@@ -41,7 +41,7 @@ sys_call_table32:
/*
90
*/
.
word
sys_dup2
,
sys_setfsuid
,
compat_sys_fcntl
,
sys32_select
,
sys_setfsgid
/*
90
*/
.
word
sys_dup2
,
sys_setfsuid
,
compat_sys_fcntl
,
sys32_select
,
sys_setfsgid
.
word
sys_fsync
,
sys32_setpriority
,
sys_nis_syscall
,
sys_nis_syscall
,
sys_nis_syscall
.
word
sys_fsync
,
sys32_setpriority
,
sys_nis_syscall
,
sys_nis_syscall
,
sys_nis_syscall
/*
100
*/
.
word
sys32_getpriority
,
sys32_rt_sigreturn
,
sys32_rt_sigaction
,
sys32_rt_sigprocmask
,
sys32_rt_sigpending
/*
100
*/
.
word
sys32_getpriority
,
sys32_rt_sigreturn
,
sys32_rt_sigaction
,
sys32_rt_sigprocmask
,
sys32_rt_sigpending
.
word
compat_rt_sigtimedwait
,
sys32_rt_sigqueueinfo
,
sys32_rt_sigsuspend
,
sys_setresuid
,
sys_getresuid
.
word
compat_
sys_
rt_sigtimedwait
,
sys32_rt_sigqueueinfo
,
sys32_rt_sigsuspend
,
sys_setresuid
,
sys_getresuid
/*
110
*/
.
word
sys_setresgid
,
sys_getresgid
,
sys_setregid
,
sys_nis_syscall
,
sys_nis_syscall
/*
110
*/
.
word
sys_setresgid
,
sys_getresgid
,
sys_setregid
,
sys_nis_syscall
,
sys_nis_syscall
.
word
sys32_getgroups
,
sys32_gettimeofday
,
sys32_getrusage
,
sys_nis_syscall
,
sys_getcwd
.
word
sys32_getgroups
,
sys32_gettimeofday
,
sys32_getrusage
,
sys_nis_syscall
,
sys_getcwd
/*
120
*/
.
word
compat_sys_readv
,
compat_sys_writev
,
sys32_settimeofday
,
sys32_fchown16
,
sys_fchmod
/*
120
*/
.
word
compat_sys_readv
,
compat_sys_writev
,
sys32_settimeofday
,
sys32_fchown16
,
sys_fchmod
...
...
arch/x86_64/ia32/ia32entry.S
View file @
0d7e0daa
...
@@ -479,7 +479,7 @@ ia32_sys_call_table:
...
@@ -479,7 +479,7 @@ ia32_sys_call_table:
.
quad
sys32_rt_sigaction
.
quad
sys32_rt_sigaction
.
quad
sys32_rt_sigprocmask
/*
175
*/
.
quad
sys32_rt_sigprocmask
/*
175
*/
.
quad
sys32_rt_sigpending
.
quad
sys32_rt_sigpending
.
quad
compat_rt_sigtimedwait
.
quad
compat_
sys_
rt_sigtimedwait
.
quad
sys32_rt_sigqueueinfo
.
quad
sys32_rt_sigqueueinfo
.
quad
stub32_rt_sigsuspend
.
quad
stub32_rt_sigsuspend
.
quad
sys32_pread
/*
180
*/
.
quad
sys32_pread
/*
180
*/
...
...
drivers/ide/arm/icside.c
View file @
0d7e0daa
...
@@ -397,35 +397,6 @@ static void icside_dma_start(ide_drive_t *drive)
...
@@ -397,35 +397,6 @@ static void icside_dma_start(ide_drive_t *drive)
enable_dma
(
hwif
->
hw
.
dma
);
enable_dma
(
hwif
->
hw
.
dma
);
}
}
/*
* dma_intr() is the handler for disk read/write DMA interrupts
*/
static
ide_startstop_t
icside_dmaintr
(
ide_drive_t
*
drive
)
{
unsigned
int
stat
;
int
dma_stat
;
dma_stat
=
icside_dma_end
(
drive
);
stat
=
HWIF
(
drive
)
->
INB
(
IDE_STATUS_REG
);
if
(
OK_STAT
(
stat
,
DRIVE_READY
,
drive
->
bad_wstat
|
DRQ_STAT
))
{
if
(
!
dma_stat
)
{
struct
request
*
rq
=
HWGROUP
(
drive
)
->
rq
;
int
i
;
for
(
i
=
rq
->
nr_sectors
;
i
>
0
;
)
{
i
-=
rq
->
current_nr_sectors
;
DRIVER
(
drive
)
->
end_request
(
drive
,
1
,
rq
->
nr_sectors
);
}
return
ide_stopped
;
}
printk
(
KERN_ERR
"%s: bad DMA status (dma_stat=%x)
\n
"
,
drive
->
name
,
dma_stat
);
}
return
ide_error
(
drive
,
__FUNCTION__
,
stat
);
}
static
int
icside_dma_setup
(
ide_drive_t
*
drive
)
static
int
icside_dma_setup
(
ide_drive_t
*
drive
)
{
{
ide_hwif_t
*
hwif
=
HWIF
(
drive
);
ide_hwif_t
*
hwif
=
HWIF
(
drive
);
...
@@ -474,7 +445,7 @@ static int icside_dma_setup(ide_drive_t *drive)
...
@@ -474,7 +445,7 @@ static int icside_dma_setup(ide_drive_t *drive)
static
void
icside_dma_exec_cmd
(
ide_drive_t
*
drive
,
u8
cmd
)
static
void
icside_dma_exec_cmd
(
ide_drive_t
*
drive
,
u8
cmd
)
{
{
/* issue cmd to drive */
/* issue cmd to drive */
ide_execute_command
(
drive
,
cmd
,
i
cside_dmaintr
,
2
*
WAIT_CMD
,
NULL
);
ide_execute_command
(
drive
,
cmd
,
i
de_dma_intr
,
2
*
WAIT_CMD
,
NULL
);
}
}
static
int
icside_dma_test_irq
(
ide_drive_t
*
drive
)
static
int
icside_dma_test_irq
(
ide_drive_t
*
drive
)
...
...
drivers/ide/cris/ide-v10.c
View file @
0d7e0daa
...
@@ -753,27 +753,10 @@ static int config_drive_for_dma (ide_drive_t *drive)
...
@@ -753,27 +753,10 @@ static int config_drive_for_dma (ide_drive_t *drive)
*/
*/
static
ide_startstop_t
etrax_dma_intr
(
ide_drive_t
*
drive
)
static
ide_startstop_t
etrax_dma_intr
(
ide_drive_t
*
drive
)
{
{
int
i
,
dma_stat
;
byte
stat
;
LED_DISK_READ
(
0
);
LED_DISK_READ
(
0
);
LED_DISK_WRITE
(
0
);
LED_DISK_WRITE
(
0
);
dma_stat
=
HWIF
(
drive
)
->
ide_dma_end
(
drive
);
return
ide_dma_intr
(
drive
);
stat
=
HWIF
(
drive
)
->
INB
(
IDE_STATUS_REG
);
/* get drive status */
if
(
OK_STAT
(
stat
,
DRIVE_READY
,
drive
->
bad_wstat
|
DRQ_STAT
))
{
if
(
!
dma_stat
)
{
struct
request
*
rq
;
rq
=
HWGROUP
(
drive
)
->
rq
;
for
(
i
=
rq
->
nr_sectors
;
i
>
0
;)
{
i
-=
rq
->
current_nr_sectors
;
DRIVER
(
drive
)
->
end_request
(
drive
,
1
,
rq
->
nr_sectors
);
}
return
ide_stopped
;
}
printk
(
"%s: bad DMA status
\n
"
,
drive
->
name
);
}
return
ide_error
(
drive
,
"dma_intr"
,
stat
);
}
}
/*
/*
...
...
drivers/ide/ide-cd.c
View file @
0d7e0daa
...
@@ -1464,19 +1464,6 @@ static ide_startstop_t cdrom_do_packet_command (ide_drive_t *drive)
...
@@ -1464,19 +1464,6 @@ static ide_startstop_t cdrom_do_packet_command (ide_drive_t *drive)
}
}
/* Sleep for TIME jiffies.
Not to be called from an interrupt handler. */
static
void
cdrom_sleep
(
int
time
)
{
int
sleep
=
time
;
do
{
set_current_state
(
TASK_INTERRUPTIBLE
);
sleep
=
schedule_timeout
(
sleep
);
}
while
(
sleep
);
}
static
static
int
cdrom_queue_packet_command
(
ide_drive_t
*
drive
,
struct
request
*
rq
)
int
cdrom_queue_packet_command
(
ide_drive_t
*
drive
,
struct
request
*
rq
)
{
{
...
@@ -1511,7 +1498,7 @@ int cdrom_queue_packet_command(ide_drive_t *drive, struct request *rq)
...
@@ -1511,7 +1498,7 @@ int cdrom_queue_packet_command(ide_drive_t *drive, struct request *rq)
/* The drive is in the process of loading
/* The drive is in the process of loading
a disk. Retry, but wait a little to give
a disk. Retry, but wait a little to give
the drive time to complete the load. */
the drive time to complete the load. */
cdrom_sleep
(
2
*
HZ
);
ssleep
(
2
);
}
else
{
}
else
{
/* Otherwise, don't retry. */
/* Otherwise, don't retry. */
retries
=
0
;
retries
=
0
;
...
...
drivers/ide/ide-default.c
View file @
0d7e0daa
...
@@ -46,6 +46,7 @@ ide_driver_t idedefault_driver = {
...
@@ -46,6 +46,7 @@ ide_driver_t idedefault_driver = {
.
name
=
"ide-default"
,
.
name
=
"ide-default"
,
.
version
=
IDEDEFAULT_VERSION
,
.
version
=
IDEDEFAULT_VERSION
,
.
attach
=
idedefault_attach
,
.
attach
=
idedefault_attach
,
.
cleanup
=
ide_unregister_subdriver
,
.
drives
=
LIST_HEAD_INIT
(
idedefault_driver
.
drives
)
.
drives
=
LIST_HEAD_INIT
(
idedefault_driver
.
drives
)
};
};
...
...
drivers/ide/ide-dma.c
View file @
0d7e0daa
...
@@ -158,7 +158,6 @@ static int in_drive_list(struct hd_driveid *id, const struct drive_list_entry *d
...
@@ -158,7 +158,6 @@ static int in_drive_list(struct hd_driveid *id, const struct drive_list_entry *d
return
0
;
return
0
;
}
}
#ifdef CONFIG_BLK_DEV_IDEDMA_PCI
/**
/**
* ide_dma_intr - IDE DMA interrupt handler
* ide_dma_intr - IDE DMA interrupt handler
* @drive: the drive the interrupt is for
* @drive: the drive the interrupt is for
...
@@ -188,6 +187,7 @@ ide_startstop_t ide_dma_intr (ide_drive_t *drive)
...
@@ -188,6 +187,7 @@ ide_startstop_t ide_dma_intr (ide_drive_t *drive)
EXPORT_SYMBOL_GPL
(
ide_dma_intr
);
EXPORT_SYMBOL_GPL
(
ide_dma_intr
);
#ifdef CONFIG_BLK_DEV_IDEDMA_PCI
/**
/**
* ide_build_sglist - map IDE scatter gather for DMA I/O
* ide_build_sglist - map IDE scatter gather for DMA I/O
* @drive: the drive to build the DMA table for
* @drive: the drive to build the DMA table for
...
...
drivers/ide/ide-io.c
View file @
0d7e0daa
...
@@ -437,7 +437,7 @@ EXPORT_SYMBOL(ide_end_drive_cmd);
...
@@ -437,7 +437,7 @@ EXPORT_SYMBOL(ide_end_drive_cmd);
* by read a sector's worth of data from the drive. Of course,
* by read a sector's worth of data from the drive. Of course,
* this may not help if the drive is *waiting* for data from *us*.
* this may not help if the drive is *waiting* for data from *us*.
*/
*/
void
try_to_flush_leftover_data
(
ide_drive_t
*
drive
)
static
void
try_to_flush_leftover_data
(
ide_drive_t
*
drive
)
{
{
int
i
=
(
drive
->
mult_count
?
drive
->
mult_count
:
1
)
*
SECTOR_WORDS
;
int
i
=
(
drive
->
mult_count
?
drive
->
mult_count
:
1
)
*
SECTOR_WORDS
;
...
@@ -452,8 +452,6 @@ void try_to_flush_leftover_data (ide_drive_t *drive)
...
@@ -452,8 +452,6 @@ void try_to_flush_leftover_data (ide_drive_t *drive)
}
}
}
}
EXPORT_SYMBOL
(
try_to_flush_leftover_data
);
static
ide_startstop_t
ide_ata_error
(
ide_drive_t
*
drive
,
struct
request
*
rq
,
u8
stat
,
u8
err
)
static
ide_startstop_t
ide_ata_error
(
ide_drive_t
*
drive
,
struct
request
*
rq
,
u8
stat
,
u8
err
)
{
{
ide_hwif_t
*
hwif
=
drive
->
hwif
;
ide_hwif_t
*
hwif
=
drive
->
hwif
;
...
@@ -854,13 +852,6 @@ static ide_startstop_t start_request (ide_drive_t *drive, struct request *rq)
...
@@ -854,13 +852,6 @@ static ide_startstop_t start_request (ide_drive_t *drive, struct request *rq)
goto
kill_rq
;
goto
kill_rq
;
}
}
/*
* bail early if we've sent a device to sleep, however how to wake
* this needs to be a masked flag. FIXME for proper operations.
*/
if
(
drive
->
suspend_reset
)
goto
kill_rq
;
block
=
rq
->
sector
;
block
=
rq
->
sector
;
if
(
blk_fs_request
(
rq
)
&&
if
(
blk_fs_request
(
rq
)
&&
(
drive
->
media
==
ide_disk
||
drive
->
media
==
ide_floppy
))
{
(
drive
->
media
==
ide_disk
||
drive
->
media
==
ide_floppy
))
{
...
...
drivers/ide/ide-lib.c
View file @
0d7e0daa
...
@@ -571,8 +571,7 @@ static u8 ide_dump_atapi_status(ide_drive_t *drive, const char *msg, u8 stat)
...
@@ -571,8 +571,7 @@ static u8 ide_dump_atapi_status(ide_drive_t *drive, const char *msg, u8 stat)
status
.
all
=
stat
;
status
.
all
=
stat
;
local_irq_set
(
flags
);
local_irq_set
(
flags
);
printk
(
"%s: %s: status=0x%02x"
,
drive
->
name
,
msg
,
stat
);
printk
(
"%s: %s: status=0x%02x { "
,
drive
->
name
,
msg
,
stat
);
printk
(
" { "
);
if
(
status
.
b
.
bsy
)
if
(
status
.
b
.
bsy
)
printk
(
"Busy "
);
printk
(
"Busy "
);
else
{
else
{
...
@@ -584,18 +583,17 @@ static u8 ide_dump_atapi_status(ide_drive_t *drive, const char *msg, u8 stat)
...
@@ -584,18 +583,17 @@ static u8 ide_dump_atapi_status(ide_drive_t *drive, const char *msg, u8 stat)
if
(
status
.
b
.
idx
)
printk
(
"Index "
);
if
(
status
.
b
.
idx
)
printk
(
"Index "
);
if
(
status
.
b
.
check
)
printk
(
"Error "
);
if
(
status
.
b
.
check
)
printk
(
"Error "
);
}
}
printk
(
"}"
);
printk
(
"}
\n
"
);
printk
(
"
\n
"
);
if
((
status
.
all
&
(
status
.
b
.
bsy
|
status
.
b
.
check
))
==
status
.
b
.
check
)
{
if
((
status
.
all
&
(
status
.
b
.
bsy
|
status
.
b
.
check
))
==
status
.
b
.
check
)
{
error
.
all
=
HWIF
(
drive
)
->
INB
(
IDE_ERROR_REG
);
error
.
all
=
HWIF
(
drive
)
->
INB
(
IDE_ERROR_REG
);
printk
(
"%s: %s: error=0x%02x"
,
drive
->
name
,
msg
,
error
.
all
);
printk
(
"%s: %s: error=0x%02x
{
"
,
drive
->
name
,
msg
,
error
.
all
);
if
(
error
.
b
.
ili
)
printk
(
"IllegalLengthIndication "
);
if
(
error
.
b
.
ili
)
printk
(
"IllegalLengthIndication "
);
if
(
error
.
b
.
eom
)
printk
(
"EndOfMedia "
);
if
(
error
.
b
.
eom
)
printk
(
"EndOfMedia "
);
if
(
error
.
b
.
abrt
)
printk
(
"Aborted
Command "
);
if
(
error
.
b
.
abrt
)
printk
(
"AbortedCommand "
);
if
(
error
.
b
.
mcr
)
printk
(
"MediaChangeRequested "
);
if
(
error
.
b
.
mcr
)
printk
(
"MediaChangeRequested "
);
if
(
error
.
b
.
sense_key
)
printk
(
"LastFailedSense
0x%02x "
,
if
(
error
.
b
.
sense_key
)
printk
(
"LastFailedSense
=
0x%02x "
,
error
.
b
.
sense_key
);
error
.
b
.
sense_key
);
printk
(
"
\n
"
);
printk
(
"
}
\n
"
);
}
}
ide_dump_opcode
(
drive
);
ide_dump_opcode
(
drive
);
local_irq_restore
(
flags
);
local_irq_restore
(
flags
);
...
...
drivers/ide/ide-probe.c
View file @
0d7e0daa
...
@@ -749,7 +749,7 @@ static void probe_hwif(ide_hwif_t *hwif)
...
@@ -749,7 +749,7 @@ static void probe_hwif(ide_hwif_t *hwif)
*
*
* BenH.
* BenH.
*/
*/
if
(
wait_hwif_ready
(
hwif
))
if
(
wait_hwif_ready
(
hwif
)
==
-
EBUSY
)
printk
(
KERN_DEBUG
"%s: Wait for ready failed before probe !
\n
"
,
hwif
->
name
);
printk
(
KERN_DEBUG
"%s: Wait for ready failed before probe !
\n
"
,
hwif
->
name
);
/*
/*
...
...
drivers/ide/ide.c
View file @
0d7e0daa
...
@@ -1554,18 +1554,7 @@ int generic_ide_ioctl(struct file *file, struct block_device *bdev,
...
@@ -1554,18 +1554,7 @@ int generic_ide_ioctl(struct file *file, struct block_device *bdev,
HWGROUP
(
drive
)
->
busy
=
1
;
HWGROUP
(
drive
)
->
busy
=
1
;
spin_unlock_irqrestore
(
&
ide_lock
,
flags
);
spin_unlock_irqrestore
(
&
ide_lock
,
flags
);
(
void
)
ide_do_reset
(
drive
);
(
void
)
ide_do_reset
(
drive
);
if
(
drive
->
suspend_reset
)
{
/*
* APM WAKE UP todo !!
* int nogoodpower = 1;
* while(nogoodpower) {
* check_power1() or check_power2()
* nogoodpower = 0;
* }
* HWIF(drive)->multiproc(drive);
*/
return
ioctl_by_bdev
(
bdev
,
BLKRRPART
,
0
);
}
return
0
;
return
0
;
}
}
...
@@ -2029,16 +2018,6 @@ static void __init probe_for_hwifs (void)
...
@@ -2029,16 +2018,6 @@ static void __init probe_for_hwifs (void)
#endif
#endif
}
}
/*
* Actually unregister the subdriver. Called with the
* request lock dropped.
*/
static
int
default_cleanup
(
ide_drive_t
*
drive
)
{
return
ide_unregister_subdriver
(
drive
);
}
static
ide_startstop_t
default_do_request
(
ide_drive_t
*
drive
,
struct
request
*
rq
,
sector_t
block
)
static
ide_startstop_t
default_do_request
(
ide_drive_t
*
drive
,
struct
request
*
rq
,
sector_t
block
)
{
{
ide_end_request
(
drive
,
0
,
0
);
ide_end_request
(
drive
,
0
,
0
);
...
@@ -2074,14 +2053,6 @@ static ide_startstop_t default_special (ide_drive_t *drive)
...
@@ -2074,14 +2053,6 @@ static ide_startstop_t default_special (ide_drive_t *drive)
return
ide_stopped
;
return
ide_stopped
;
}
}
static
int
default_attach
(
ide_drive_t
*
drive
)
{
printk
(
KERN_ERR
"%s: does not support hotswap of device class !
\n
"
,
drive
->
name
);
return
0
;
}
static
ide_startstop_t
default_abort
(
ide_drive_t
*
drive
,
struct
request
*
rq
)
static
ide_startstop_t
default_abort
(
ide_drive_t
*
drive
,
struct
request
*
rq
)
{
{
return
__ide_abort
(
drive
,
rq
);
return
__ide_abort
(
drive
,
rq
);
...
@@ -2096,7 +2067,8 @@ static ide_startstop_t default_start_power_step(ide_drive_t *drive,
...
@@ -2096,7 +2067,8 @@ static ide_startstop_t default_start_power_step(ide_drive_t *drive,
static
void
setup_driver_defaults
(
ide_driver_t
*
d
)
static
void
setup_driver_defaults
(
ide_driver_t
*
d
)
{
{
if
(
d
->
cleanup
==
NULL
)
d
->
cleanup
=
default_cleanup
;
BUG_ON
(
d
->
attach
==
NULL
||
d
->
cleanup
==
NULL
);
if
(
d
->
do_request
==
NULL
)
d
->
do_request
=
default_do_request
;
if
(
d
->
do_request
==
NULL
)
d
->
do_request
=
default_do_request
;
if
(
d
->
end_request
==
NULL
)
d
->
end_request
=
default_end_request
;
if
(
d
->
end_request
==
NULL
)
d
->
end_request
=
default_end_request
;
if
(
d
->
error
==
NULL
)
d
->
error
=
default_error
;
if
(
d
->
error
==
NULL
)
d
->
error
=
default_error
;
...
@@ -2104,7 +2076,6 @@ static void setup_driver_defaults (ide_driver_t *d)
...
@@ -2104,7 +2076,6 @@ static void setup_driver_defaults (ide_driver_t *d)
if
(
d
->
pre_reset
==
NULL
)
d
->
pre_reset
=
default_pre_reset
;
if
(
d
->
pre_reset
==
NULL
)
d
->
pre_reset
=
default_pre_reset
;
if
(
d
->
capacity
==
NULL
)
d
->
capacity
=
default_capacity
;
if
(
d
->
capacity
==
NULL
)
d
->
capacity
=
default_capacity
;
if
(
d
->
special
==
NULL
)
d
->
special
=
default_special
;
if
(
d
->
special
==
NULL
)
d
->
special
=
default_special
;
if
(
d
->
attach
==
NULL
)
d
->
attach
=
default_attach
;
if
(
d
->
start_power_step
==
NULL
)
if
(
d
->
start_power_step
==
NULL
)
d
->
start_power_step
=
default_start_power_step
;
d
->
start_power_step
=
default_start_power_step
;
}
}
...
@@ -2133,7 +2104,6 @@ int ide_register_subdriver(ide_drive_t *drive, ide_driver_t *driver)
...
@@ -2133,7 +2104,6 @@ int ide_register_subdriver(ide_drive_t *drive, ide_driver_t *driver)
drive
->
dsc_overlap
=
(
drive
->
next
!=
drive
&&
driver
->
supports_dsc_overlap
);
drive
->
dsc_overlap
=
(
drive
->
next
!=
drive
&&
driver
->
supports_dsc_overlap
);
drive
->
nice1
=
1
;
drive
->
nice1
=
1
;
}
}
drive
->
suspend_reset
=
0
;
#ifdef CONFIG_PROC_FS
#ifdef CONFIG_PROC_FS
if
(
drive
->
driver
!=
&
idedefault_driver
)
{
if
(
drive
->
driver
!=
&
idedefault_driver
)
{
ide_add_proc_entries
(
drive
->
proc
,
generic_subdriver_entries
,
drive
);
ide_add_proc_entries
(
drive
->
proc
,
generic_subdriver_entries
,
drive
);
...
...
drivers/ide/pci/atiixp.c
View file @
0d7e0daa
...
@@ -345,8 +345,9 @@ static int __devinit atiixp_init_one(struct pci_dev *dev, const struct pci_devic
...
@@ -345,8 +345,9 @@ static int __devinit atiixp_init_one(struct pci_dev *dev, const struct pci_devic
}
}
static
struct
pci_device_id
atiixp_pci_tbl
[]
=
{
static
struct
pci_device_id
atiixp_pci_tbl
[]
=
{
{
PCI_VENDOR_ID_ATI
,
PCI_DEVICE_ID_ATI_IXP_IDE
,
PCI_ANY_ID
,
PCI_ANY_ID
,
0
,
0
,
0
},
{
PCI_VENDOR_ID_ATI
,
PCI_DEVICE_ID_ATI_IXP200_IDE
,
PCI_ANY_ID
,
PCI_ANY_ID
,
0
,
0
,
0
},
{
PCI_VENDOR_ID_ATI
,
PCI_DEVICE_ID_ATI_IXP2_IDE
,
PCI_ANY_ID
,
PCI_ANY_ID
,
0
,
0
,
0
},
{
PCI_VENDOR_ID_ATI
,
PCI_DEVICE_ID_ATI_IXP300_IDE
,
PCI_ANY_ID
,
PCI_ANY_ID
,
0
,
0
,
0
},
{
PCI_VENDOR_ID_ATI
,
PCI_DEVICE_ID_ATI_IXP400_IDE
,
PCI_ANY_ID
,
PCI_ANY_ID
,
0
,
0
,
0
},
{
0
,
},
{
0
,
},
};
};
MODULE_DEVICE_TABLE
(
pci
,
atiixp_pci_tbl
);
MODULE_DEVICE_TABLE
(
pci
,
atiixp_pci_tbl
);
...
...
drivers/ide/pci/piix.c
View file @
0d7e0daa
...
@@ -129,6 +129,7 @@ static u8 piix_ratemask (ide_drive_t *drive)
...
@@ -129,6 +129,7 @@ static u8 piix_ratemask (ide_drive_t *drive)
case
PCI_DEVICE_ID_INTEL_82801CA_10
:
case
PCI_DEVICE_ID_INTEL_82801CA_10
:
case
PCI_DEVICE_ID_INTEL_82801CA_11
:
case
PCI_DEVICE_ID_INTEL_82801CA_11
:
case
PCI_DEVICE_ID_INTEL_82801E_11
:
case
PCI_DEVICE_ID_INTEL_82801E_11
:
case
PCI_DEVICE_ID_INTEL_82801DB_1
:
case
PCI_DEVICE_ID_INTEL_82801DB_10
:
case
PCI_DEVICE_ID_INTEL_82801DB_10
:
case
PCI_DEVICE_ID_INTEL_82801DB_11
:
case
PCI_DEVICE_ID_INTEL_82801DB_11
:
case
PCI_DEVICE_ID_INTEL_82801EB_11
:
case
PCI_DEVICE_ID_INTEL_82801EB_11
:
...
@@ -440,6 +441,7 @@ static unsigned int __devinit init_chipset_piix (struct pci_dev *dev, const char
...
@@ -440,6 +441,7 @@ static unsigned int __devinit init_chipset_piix (struct pci_dev *dev, const char
case
PCI_DEVICE_ID_INTEL_82801BA_9
:
case
PCI_DEVICE_ID_INTEL_82801BA_9
:
case
PCI_DEVICE_ID_INTEL_82801CA_10
:
case
PCI_DEVICE_ID_INTEL_82801CA_10
:
case
PCI_DEVICE_ID_INTEL_82801CA_11
:
case
PCI_DEVICE_ID_INTEL_82801CA_11
:
case
PCI_DEVICE_ID_INTEL_82801DB_1
:
case
PCI_DEVICE_ID_INTEL_82801DB_10
:
case
PCI_DEVICE_ID_INTEL_82801DB_10
:
case
PCI_DEVICE_ID_INTEL_82801DB_11
:
case
PCI_DEVICE_ID_INTEL_82801DB_11
:
case
PCI_DEVICE_ID_INTEL_82801EB_11
:
case
PCI_DEVICE_ID_INTEL_82801EB_11
:
...
@@ -614,6 +616,7 @@ static struct pci_device_id piix_pci_tbl[] = {
...
@@ -614,6 +616,7 @@ static struct pci_device_id piix_pci_tbl[] = {
{
PCI_VENDOR_ID_INTEL
,
PCI_DEVICE_ID_INTEL_ESB_2
,
PCI_ANY_ID
,
PCI_ANY_ID
,
0
,
0
,
19
},
{
PCI_VENDOR_ID_INTEL
,
PCI_DEVICE_ID_INTEL_ESB_2
,
PCI_ANY_ID
,
PCI_ANY_ID
,
0
,
0
,
19
},
{
PCI_VENDOR_ID_INTEL
,
PCI_DEVICE_ID_INTEL_ICH6_19
,
PCI_ANY_ID
,
PCI_ANY_ID
,
0
,
0
,
20
},
{
PCI_VENDOR_ID_INTEL
,
PCI_DEVICE_ID_INTEL_ICH6_19
,
PCI_ANY_ID
,
PCI_ANY_ID
,
0
,
0
,
20
},
{
PCI_VENDOR_ID_INTEL
,
PCI_DEVICE_ID_INTEL_ICH7_21
,
PCI_ANY_ID
,
PCI_ANY_ID
,
0
,
0
,
21
},
{
PCI_VENDOR_ID_INTEL
,
PCI_DEVICE_ID_INTEL_ICH7_21
,
PCI_ANY_ID
,
PCI_ANY_ID
,
0
,
0
,
21
},
{
PCI_VENDOR_ID_INTEL
,
PCI_DEVICE_ID_INTEL_82801DB_1
,
PCI_ANY_ID
,
PCI_ANY_ID
,
0
,
0
,
22
},
{
0
,
},
{
0
,
},
};
};
MODULE_DEVICE_TABLE
(
pci
,
piix_pci_tbl
);
MODULE_DEVICE_TABLE
(
pci
,
piix_pci_tbl
);
...
...
drivers/ide/pci/piix.h
View file @
0d7e0daa
...
@@ -59,6 +59,7 @@ static ide_pci_device_t piix_pci_info[] __devinitdata = {
...
@@ -59,6 +59,7 @@ static ide_pci_device_t piix_pci_info[] __devinitdata = {
/* 19 */
DECLARE_PIIX_DEV
(
"ICH5"
),
/* 19 */
DECLARE_PIIX_DEV
(
"ICH5"
),
/* 20 */
DECLARE_PIIX_DEV
(
"ICH6"
),
/* 20 */
DECLARE_PIIX_DEV
(
"ICH6"
),
/* 21 */
DECLARE_PIIX_DEV
(
"ICH7"
),
/* 21 */
DECLARE_PIIX_DEV
(
"ICH7"
),
/* 22 */
DECLARE_PIIX_DEV
(
"ICH4"
),
};
};
#endif
/* PIIX_H */
#endif
/* PIIX_H */
drivers/mmc/mmc_block.c
View file @
0d7e0daa
...
@@ -332,6 +332,18 @@ static struct mmc_blk_data *mmc_blk_alloc(struct mmc_card *card)
...
@@ -332,6 +332,18 @@ static struct mmc_blk_data *mmc_blk_alloc(struct mmc_card *card)
md
->
disk
->
queue
=
md
->
queue
.
queue
;
md
->
disk
->
queue
=
md
->
queue
.
queue
;
md
->
disk
->
driverfs_dev
=
&
card
->
dev
;
md
->
disk
->
driverfs_dev
=
&
card
->
dev
;
/*
* As discussed on lkml, GENHD_FL_REMOVABLE should:
*
* - be set for removable media with permanent block devices
* - be unset for removable block devices with permanent media
*
* Since MMC block devices clearly fall under the second
* case, we do not set GENHD_FL_REMOVABLE. Userspace
* should use the block device creation/destruction hotplug
* messages to tell when the card is present.
*/
sprintf
(
md
->
disk
->
disk_name
,
"mmcblk%d"
,
devidx
);
sprintf
(
md
->
disk
->
disk_name
,
"mmcblk%d"
,
devidx
);
sprintf
(
md
->
disk
->
devfs_name
,
"mmc/blk%d"
,
devidx
);
sprintf
(
md
->
disk
->
devfs_name
,
"mmc/blk%d"
,
devidx
);
...
...
drivers/pci/pci.ids
View file @
0d7e0daa
...
@@ -8088,6 +8088,7 @@
...
@@ -8088,6 +8088,7 @@
24c0 82801DB/DBL (ICH4/ICH4-L) LPC Bridge
24c0 82801DB/DBL (ICH4/ICH4-L) LPC Bridge
1014 0267 NetVista A30p
1014 0267 NetVista A30p
1462 5800 845PE Max (MS-6580)
1462 5800 845PE Max (MS-6580)
24c1 82801DBL (ICH4-L) IDE Controller
24c2 82801DB/DBL/DBM (ICH4/ICH4-L/ICH4-M) USB UHCI Controller #1
24c2 82801DB/DBL/DBM (ICH4/ICH4-L/ICH4-M) USB UHCI Controller #1
1014 0267 NetVista A30p
1014 0267 NetVista A30p
1071 8160 MIM2000
1071 8160 MIM2000
...
...
drivers/pcmcia/Makefile
View file @
0d7e0daa
...
@@ -48,4 +48,5 @@ sa1100_cs-$(CONFIG_SA1100_SIMPAD) += sa1100_simpad.o
...
@@ -48,4 +48,5 @@ sa1100_cs-$(CONFIG_SA1100_SIMPAD) += sa1100_simpad.o
pxa2xx_cs-$(CONFIG_ARCH_LUBBOCK)
+=
pxa2xx_lubbock.o sa1111_generic.o
pxa2xx_cs-$(CONFIG_ARCH_LUBBOCK)
+=
pxa2xx_lubbock.o sa1111_generic.o
pxa2xx_cs-$(CONFIG_MACH_MAINSTONE)
+=
pxa2xx_mainstone.o
pxa2xx_cs-$(CONFIG_MACH_MAINSTONE)
+=
pxa2xx_mainstone.o
pxa2xx_cs-$(CONFIG_PXA_SHARPSL)
+=
pxa2xx_sharpsl.o
drivers/pcmcia/pxa2xx_sharpsl.c
0 → 100644
View file @
0d7e0daa
/*
* Sharp SL-C7xx Series PCMCIA routines
*
* Copyright (c) 2004-2005 Richard Purdie
*
* Based on Sharp's 2.4 kernel patches and pxa2xx_mainstone.c
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*
*/
#include <linux/module.h>
#include <linux/init.h>
#include <linux/kernel.h>
#include <linux/errno.h>
#include <linux/interrupt.h>
#include <linux/device.h>
#include <asm/hardware.h>
#include <asm/irq.h>
#include <asm/hardware/scoop.h>
#include <asm/arch/corgi.h>
#include <asm/arch/pxa-regs.h>
#include "soc_common.h"
#define NO_KEEP_VS 0x0001
static
unsigned
char
keep_vs
;
static
unsigned
char
keep_rd
;
static
struct
pcmcia_irqs
irqs
[]
=
{
{
0
,
CORGI_IRQ_GPIO_CF_CD
,
"PCMCIA0 CD"
},
};
static
void
sharpsl_pcmcia_init_reset
(
void
)
{
reset_scoop
();
keep_vs
=
NO_KEEP_VS
;
keep_rd
=
0
;
}
static
int
sharpsl_pcmcia_hw_init
(
struct
soc_pcmcia_socket
*
skt
)
{
int
ret
;
/*
* Setup default state of GPIO outputs
* before we enable them as outputs.
*/
GPSR
(
GPIO48_nPOE
)
=
GPIO_bit
(
GPIO48_nPOE
)
|
GPIO_bit
(
GPIO49_nPWE
)
|
GPIO_bit
(
GPIO50_nPIOR
)
|
GPIO_bit
(
GPIO51_nPIOW
)
|
GPIO_bit
(
GPIO52_nPCE_1
)
|
GPIO_bit
(
GPIO53_nPCE_2
);
pxa_gpio_mode
(
GPIO48_nPOE_MD
);
pxa_gpio_mode
(
GPIO49_nPWE_MD
);
pxa_gpio_mode
(
GPIO50_nPIOR_MD
);
pxa_gpio_mode
(
GPIO51_nPIOW_MD
);
pxa_gpio_mode
(
GPIO52_nPCE_1_MD
);
pxa_gpio_mode
(
GPIO53_nPCE_2_MD
);
pxa_gpio_mode
(
GPIO54_pSKTSEL_MD
);
pxa_gpio_mode
(
GPIO55_nPREG_MD
);
pxa_gpio_mode
(
GPIO56_nPWAIT_MD
);
pxa_gpio_mode
(
GPIO57_nIOIS16_MD
);
/* Register interrupts */
ret
=
soc_pcmcia_request_irqs
(
skt
,
irqs
,
ARRAY_SIZE
(
irqs
));
if
(
ret
)
{
printk
(
KERN_ERR
"Request for Compact Flash IRQ failed
\n
"
);
return
ret
;
}
/* Enable interrupt */
write_scoop_reg
(
SCOOP_IMR
,
0x00C0
);
write_scoop_reg
(
SCOOP_MCR
,
0x0101
);
keep_vs
=
NO_KEEP_VS
;
skt
->
irq
=
CORGI_IRQ_GPIO_CF_IRQ
;
return
0
;
}
static
void
sharpsl_pcmcia_hw_shutdown
(
struct
soc_pcmcia_socket
*
skt
)
{
soc_pcmcia_free_irqs
(
skt
,
irqs
,
ARRAY_SIZE
(
irqs
));
/* CF_BUS_OFF */
sharpsl_pcmcia_init_reset
();
}
static
void
sharpsl_pcmcia_socket_state
(
struct
soc_pcmcia_socket
*
skt
,
struct
pcmcia_state
*
state
)
{
unsigned
short
cpr
,
csr
;
cpr
=
read_scoop_reg
(
SCOOP_CPR
);
write_scoop_reg
(
SCOOP_IRM
,
0x00FF
);
write_scoop_reg
(
SCOOP_ISR
,
0x0000
);
write_scoop_reg
(
SCOOP_IRM
,
0x0000
);
csr
=
read_scoop_reg
(
SCOOP_CSR
);
if
(
csr
&
0x0004
)
{
/* card eject */
write_scoop_reg
(
SCOOP_CDR
,
0x0000
);
keep_vs
=
NO_KEEP_VS
;
}
else
if
(
!
(
keep_vs
&
NO_KEEP_VS
))
{
/* keep vs1,vs2 */
write_scoop_reg
(
SCOOP_CDR
,
0x0000
);
csr
|=
keep_vs
;
}
else
if
(
cpr
&
0x0003
)
{
/* power on */
write_scoop_reg
(
SCOOP_CDR
,
0x0000
);
keep_vs
=
(
csr
&
0x00C0
);
}
else
{
/* card detect */
write_scoop_reg
(
SCOOP_CDR
,
0x0002
);
}
state
->
detect
=
(
csr
&
0x0004
)
?
0
:
1
;
state
->
ready
=
(
csr
&
0x0002
)
?
1
:
0
;
state
->
bvd1
=
(
csr
&
0x0010
)
?
1
:
0
;
state
->
bvd2
=
(
csr
&
0x0020
)
?
1
:
0
;
state
->
wrprot
=
(
csr
&
0x0008
)
?
1
:
0
;
state
->
vs_3v
=
(
csr
&
0x0040
)
?
0
:
1
;
state
->
vs_Xv
=
(
csr
&
0x0080
)
?
0
:
1
;
if
((
cpr
&
0x0080
)
&&
((
cpr
&
0x8040
)
!=
0x8040
))
{
printk
(
KERN_ERR
"sharpsl_pcmcia_socket_state(): CPR=%04X, Low voltage!
\n
"
,
cpr
);
}
}
static
int
sharpsl_pcmcia_configure_socket
(
struct
soc_pcmcia_socket
*
skt
,
const
socket_state_t
*
state
)
{
unsigned
long
flags
;
unsigned
short
cpr
,
ncpr
,
ccr
,
nccr
,
mcr
,
nmcr
,
imr
,
nimr
;
switch
(
state
->
Vcc
)
{
case
0
:
break
;
case
33
:
break
;
case
50
:
break
;
default:
printk
(
KERN_ERR
"sharpsl_pcmcia_configure_socket(): bad Vcc %u
\n
"
,
state
->
Vcc
);
return
-
1
;
}
if
((
state
->
Vpp
!=
state
->
Vcc
)
&&
(
state
->
Vpp
!=
0
))
{
printk
(
KERN_ERR
"CF slot cannot support Vpp %u
\n
"
,
state
->
Vpp
);
return
-
1
;
}
local_irq_save
(
flags
);
nmcr
=
(
mcr
=
read_scoop_reg
(
SCOOP_MCR
))
&
~
0x0010
;
ncpr
=
(
cpr
=
read_scoop_reg
(
SCOOP_CPR
))
&
~
0x0083
;
nccr
=
(
ccr
=
read_scoop_reg
(
SCOOP_CCR
))
&
~
0x0080
;
nimr
=
(
imr
=
read_scoop_reg
(
SCOOP_IMR
))
&
~
0x003E
;
ncpr
|=
(
state
->
Vcc
==
33
)
?
0x0001
:
(
state
->
Vcc
==
50
)
?
0x0002
:
0
;
nmcr
|=
(
state
->
flags
&
SS_IOCARD
)
?
0x0010
:
0
;
ncpr
|=
(
state
->
flags
&
SS_OUTPUT_ENA
)
?
0x0080
:
0
;
nccr
|=
(
state
->
flags
&
SS_RESET
)
?
0x0080
:
0
;
nimr
|=
((
skt
->
status
&
SS_DETECT
)
?
0x0004
:
0
)
|
((
skt
->
status
&
SS_READY
)
?
0x0002
:
0
)
|
((
skt
->
status
&
SS_BATDEAD
)
?
0x0010
:
0
)
|
((
skt
->
status
&
SS_BATWARN
)
?
0x0020
:
0
)
|
((
skt
->
status
&
SS_STSCHG
)
?
0x0010
:
0
)
|
((
skt
->
status
&
SS_WRPROT
)
?
0x0008
:
0
);
if
(
!
(
ncpr
&
0x0003
))
{
keep_rd
=
0
;
}
else
if
(
!
keep_rd
)
{
if
(
nccr
&
0x0080
)
keep_rd
=
1
;
else
nccr
|=
0x0080
;
}
if
(
mcr
!=
nmcr
)
write_scoop_reg
(
SCOOP_MCR
,
nmcr
);
if
(
cpr
!=
ncpr
)
write_scoop_reg
(
SCOOP_CPR
,
ncpr
);
if
(
ccr
!=
nccr
)
write_scoop_reg
(
SCOOP_CCR
,
nccr
);
if
(
imr
!=
nimr
)
write_scoop_reg
(
SCOOP_IMR
,
nimr
);
local_irq_restore
(
flags
);
return
0
;
}
static
void
sharpsl_pcmcia_socket_init
(
struct
soc_pcmcia_socket
*
skt
)
{
}
static
void
sharpsl_pcmcia_socket_suspend
(
struct
soc_pcmcia_socket
*
skt
)
{
}
static
struct
pcmcia_low_level
sharpsl_pcmcia_ops
=
{
.
owner
=
THIS_MODULE
,
.
hw_init
=
sharpsl_pcmcia_hw_init
,
.
hw_shutdown
=
sharpsl_pcmcia_hw_shutdown
,
.
socket_state
=
sharpsl_pcmcia_socket_state
,
.
configure_socket
=
sharpsl_pcmcia_configure_socket
,
.
socket_init
=
sharpsl_pcmcia_socket_init
,
.
socket_suspend
=
sharpsl_pcmcia_socket_suspend
,
.
first
=
0
,
.
nr
=
1
,
};
static
struct
platform_device
*
sharpsl_pcmcia_device
;
static
int
__init
sharpsl_pcmcia_init
(
void
)
{
int
ret
;
sharpsl_pcmcia_device
=
kmalloc
(
sizeof
(
*
sharpsl_pcmcia_device
),
GFP_KERNEL
);
if
(
!
sharpsl_pcmcia_device
)
return
-
ENOMEM
;
memset
(
sharpsl_pcmcia_device
,
0
,
sizeof
(
*
sharpsl_pcmcia_device
));
sharpsl_pcmcia_device
->
name
=
"pxa2xx-pcmcia"
;
sharpsl_pcmcia_device
->
dev
.
platform_data
=
&
sharpsl_pcmcia_ops
;
ret
=
platform_device_register
(
sharpsl_pcmcia_device
);
if
(
ret
)
kfree
(
sharpsl_pcmcia_device
);
return
ret
;
}
static
void
__exit
sharpsl_pcmcia_exit
(
void
)
{
/*
* This call is supposed to free our sharpsl_pcmcia_device.
* Unfortunately platform_device don't have a free method, and
* we can't assume it's free of any reference at this point so we
* can't free it either.
*/
platform_device_unregister
(
sharpsl_pcmcia_device
);
}
module_init
(
sharpsl_pcmcia_init
);
module_exit
(
sharpsl_pcmcia_exit
);
MODULE_DESCRIPTION
(
"Sharp SL Series PCMCIA Support"
);
MODULE_LICENSE
(
"GPL"
);
drivers/serial/serial_core.c
View file @
0d7e0daa
...
@@ -1877,7 +1877,21 @@ int uart_resume_port(struct uart_driver *drv, struct uart_port *port)
...
@@ -1877,7 +1877,21 @@ int uart_resume_port(struct uart_driver *drv, struct uart_port *port)
* Re-enable the console device after suspending.
* Re-enable the console device after suspending.
*/
*/
if
(
uart_console
(
port
))
{
if
(
uart_console
(
port
))
{
uart_change_speed
(
state
,
NULL
);
struct
termios
termios
;
/*
* First try to use the console cflag setting.
*/
memset
(
&
termios
,
0
,
sizeof
(
struct
termios
));
termios
.
c_cflag
=
port
->
cons
->
cflag
;
/*
* If that's unset, use the tty termios setting.
*/
if
(
state
->
info
&&
state
->
info
->
tty
&&
termios
.
c_cflag
==
0
)
termios
=
*
state
->
info
->
tty
->
termios
;
port
->
ops
->
set_termios
(
port
,
&
termios
,
NULL
);
console_start
(
port
->
cons
);
console_start
(
port
->
cons
);
}
}
...
...
include/linux/ide.h
View file @
0d7e0daa
...
@@ -723,7 +723,6 @@ typedef struct ide_drive_s {
...
@@ -723,7 +723,6 @@ typedef struct ide_drive_s {
unsigned
scsi
:
1
;
/* 0=default, 1=ide-scsi emulation */
unsigned
scsi
:
1
;
/* 0=default, 1=ide-scsi emulation */
u8
quirk_list
;
/* considered quirky, set for a specific host */
u8
quirk_list
;
/* considered quirky, set for a specific host */
u8
suspend_reset
;
/* drive suspend mode flag, soft-reset recovers */
u8
init_speed
;
/* transfer rate set at boot */
u8
init_speed
;
/* transfer rate set at boot */
u8
pio_speed
;
/* unused by core, used by some drivers for fallback from DMA */
u8
pio_speed
;
/* unused by core, used by some drivers for fallback from DMA */
u8
current_speed
;
/* current transfer rate set */
u8
current_speed
;
/* current transfer rate set */
...
@@ -1250,8 +1249,6 @@ extern int ide_do_drive_cmd(ide_drive_t *, struct request *, ide_action_t);
...
@@ -1250,8 +1249,6 @@ extern int ide_do_drive_cmd(ide_drive_t *, struct request *, ide_action_t);
*/
*/
extern
void
ide_end_drive_cmd
(
ide_drive_t
*
,
u8
,
u8
);
extern
void
ide_end_drive_cmd
(
ide_drive_t
*
,
u8
,
u8
);
extern
void
try_to_flush_leftover_data
(
ide_drive_t
*
);
/*
/*
* Issue ATA command and wait for completion.
* Issue ATA command and wait for completion.
* Use for implementing commands in kernel
* Use for implementing commands in kernel
...
@@ -1444,12 +1441,12 @@ int __ide_dma_good_drive(ide_drive_t *);
...
@@ -1444,12 +1441,12 @@ int __ide_dma_good_drive(ide_drive_t *);
int
ide_use_dma
(
ide_drive_t
*
);
int
ide_use_dma
(
ide_drive_t
*
);
int
__ide_dma_off
(
ide_drive_t
*
);
int
__ide_dma_off
(
ide_drive_t
*
);
void
ide_dma_verbose
(
ide_drive_t
*
);
void
ide_dma_verbose
(
ide_drive_t
*
);
ide_startstop_t
ide_dma_intr
(
ide_drive_t
*
);
#ifdef CONFIG_BLK_DEV_IDEDMA_PCI
#ifdef CONFIG_BLK_DEV_IDEDMA_PCI
extern
int
ide_build_sglist
(
ide_drive_t
*
,
struct
request
*
);
extern
int
ide_build_sglist
(
ide_drive_t
*
,
struct
request
*
);
extern
int
ide_build_dmatable
(
ide_drive_t
*
,
struct
request
*
);
extern
int
ide_build_dmatable
(
ide_drive_t
*
,
struct
request
*
);
extern
void
ide_destroy_dmatable
(
ide_drive_t
*
);
extern
void
ide_destroy_dmatable
(
ide_drive_t
*
);
extern
ide_startstop_t
ide_dma_intr
(
ide_drive_t
*
);
extern
int
ide_release_dma
(
ide_hwif_t
*
);
extern
int
ide_release_dma
(
ide_hwif_t
*
);
extern
void
ide_setup_dma
(
ide_hwif_t
*
,
unsigned
long
,
unsigned
int
);
extern
void
ide_setup_dma
(
ide_hwif_t
*
,
unsigned
long
,
unsigned
int
);
...
...
include/linux/in6.h
View file @
0d7e0daa
...
@@ -44,8 +44,10 @@ struct in6_addr
...
@@ -44,8 +44,10 @@ struct in6_addr
* NOTE: Be aware the IN6ADDR_* constants and in6addr_* externals are defined
* NOTE: Be aware the IN6ADDR_* constants and in6addr_* externals are defined
* in network byte order, not in host byte order as are the IPv4 equivalents
* in network byte order, not in host byte order as are the IPv4 equivalents
*/
*/
#if 0
extern const struct in6_addr in6addr_any;
extern const struct in6_addr in6addr_any;
#define IN6ADDR_ANY_INIT { { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 } } }
#define IN6ADDR_ANY_INIT { { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 } } }
#endif
extern
const
struct
in6_addr
in6addr_loopback
;
extern
const
struct
in6_addr
in6addr_loopback
;
#define IN6ADDR_LOOPBACK_INIT { { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 } } }
#define IN6ADDR_LOOPBACK_INIT { { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 } } }
...
...
include/linux/ipv6.h
View file @
0d7e0daa
...
@@ -262,8 +262,7 @@ struct raw6_sock {
...
@@ -262,8 +262,7 @@ struct raw6_sock {
};
};
struct
udp6_sock
{
struct
udp6_sock
{
struct
inet_sock
inet
;
struct
udp_sock
udp
;
struct
udp_opt
udp
;
struct
ipv6_pinfo
inet6
;
struct
ipv6_pinfo
inet6
;
};
};
...
...
include/linux/pci_ids.h
View file @
0d7e0daa
...
@@ -353,8 +353,9 @@
...
@@ -353,8 +353,9 @@
#define PCI_DEVICE_ID_ATI_RS300_166 0x5832
#define PCI_DEVICE_ID_ATI_RS300_166 0x5832
#define PCI_DEVICE_ID_ATI_RS300_200 0x5833
#define PCI_DEVICE_ID_ATI_RS300_200 0x5833
/* ATI IXP Chipset */
/* ATI IXP Chipset */
#define PCI_DEVICE_ID_ATI_IXP_IDE 0x4349
#define PCI_DEVICE_ID_ATI_IXP200_IDE 0x4349
#define PCI_DEVICE_ID_ATI_IXP2_IDE 0x4369
/* True name not yet sure */
#define PCI_DEVICE_ID_ATI_IXP300_IDE 0x4369
#define PCI_DEVICE_ID_ATI_IXP400_IDE 0x4376
#define PCI_VENDOR_ID_VLSI 0x1004
#define PCI_VENDOR_ID_VLSI 0x1004
#define PCI_DEVICE_ID_VLSI_82C592 0x0005
#define PCI_DEVICE_ID_VLSI_82C592 0x0005
...
@@ -2178,6 +2179,7 @@
...
@@ -2178,6 +2179,7 @@
#define PCI_DEVICE_ID_INTEL_82801CA_11 0x248b
#define PCI_DEVICE_ID_INTEL_82801CA_11 0x248b
#define PCI_DEVICE_ID_INTEL_82801CA_12 0x248c
#define PCI_DEVICE_ID_INTEL_82801CA_12 0x248c
#define PCI_DEVICE_ID_INTEL_82801DB_0 0x24c0
#define PCI_DEVICE_ID_INTEL_82801DB_0 0x24c0
#define PCI_DEVICE_ID_INTEL_82801DB_1 0x24c1
#define PCI_DEVICE_ID_INTEL_82801DB_2 0x24c2
#define PCI_DEVICE_ID_INTEL_82801DB_2 0x24c2
#define PCI_DEVICE_ID_INTEL_82801DB_3 0x24c3
#define PCI_DEVICE_ID_INTEL_82801DB_3 0x24c3
#define PCI_DEVICE_ID_INTEL_82801DB_4 0x24c4
#define PCI_DEVICE_ID_INTEL_82801DB_4 0x24c4
...
...
include/linux/udp.h
View file @
0d7e0daa
...
@@ -40,26 +40,22 @@ struct udphdr {
...
@@ -40,26 +40,22 @@ struct udphdr {
#include <net/sock.h>
#include <net/sock.h>
#include <linux/ip.h>
#include <linux/ip.h>
struct
udp_opt
{
struct
udp_sock
{
int
pending
;
/* Any pending frames ? */
/* inet_sock has to be the first member */
unsigned
int
corkflag
;
/* Cork is required */
struct
inet_sock
inet
;
__u16
encap_type
;
/* Is this an Encapsulation socket? */
int
pending
;
/* Any pending frames ? */
unsigned
int
corkflag
;
/* Cork is required */
__u16
encap_type
;
/* Is this an Encapsulation socket? */
/*
/*
* Following member retains the infomation to create a UDP header
* Following member retains the infomation to create a UDP header
* when the socket is uncorked.
* when the socket is uncorked.
*/
*/
__u16
len
;
/* total length of pending frames */
__u16
len
;
/* total length of pending frames */
};
/* WARNING: don't change the layout of the members in udp_sock! */
struct
udp_sock
{
struct
inet_sock
inet
;
struct
udp_opt
udp
;
};
};
static
inline
struct
udp_
opt
*
udp_sk
(
const
struct
sock
*
__
sk
)
static
inline
struct
udp_
sock
*
udp_sk
(
const
struct
sock
*
sk
)
{
{
return
&
((
struct
udp_sock
*
)
__sk
)
->
udp
;
return
(
struct
udp_sock
*
)
sk
;
}
}
#endif
#endif
...
...
include/net/addrconf.h
View file @
0d7e0daa
...
@@ -112,7 +112,6 @@ extern int inet6_ac_check(struct sock *sk, struct in6_addr *addr, int ifindex);
...
@@ -112,7 +112,6 @@ extern int inet6_ac_check(struct sock *sk, struct in6_addr *addr, int ifindex);
extern
int
ipv6_dev_ac_inc
(
struct
net_device
*
dev
,
struct
in6_addr
*
addr
);
extern
int
ipv6_dev_ac_inc
(
struct
net_device
*
dev
,
struct
in6_addr
*
addr
);
extern
int
__ipv6_dev_ac_dec
(
struct
inet6_dev
*
idev
,
struct
in6_addr
*
addr
);
extern
int
__ipv6_dev_ac_dec
(
struct
inet6_dev
*
idev
,
struct
in6_addr
*
addr
);
extern
int
ipv6_dev_ac_dec
(
struct
net_device
*
dev
,
struct
in6_addr
*
addr
);
extern
int
ipv6_chk_acast_addr
(
struct
net_device
*
dev
,
struct
in6_addr
*
addr
);
extern
int
ipv6_chk_acast_addr
(
struct
net_device
*
dev
,
struct
in6_addr
*
addr
);
...
...
include/net/icmp.h
View file @
0d7e0daa
...
@@ -46,16 +46,15 @@ extern void icmp_init(struct net_proto_family *ops);
...
@@ -46,16 +46,15 @@ extern void icmp_init(struct net_proto_family *ops);
/* Move into dst.h ? */
/* Move into dst.h ? */
extern
int
xrlim_allow
(
struct
dst_entry
*
dst
,
int
timeout
);
extern
int
xrlim_allow
(
struct
dst_entry
*
dst
,
int
timeout
);
struct
raw_opt
{
struct
icmp_filter
filter
;
};
/* WARNING: don't change the layout of the members in raw_sock! */
struct
raw_sock
{
struct
raw_sock
{
struct
inet_sock
inet
;
/* inet_sock has to be the first member */
struct
raw_opt
raw4
;
struct
inet_sock
inet
;
struct
icmp_filter
filter
;
};
};
#define raw4_sk(__sk) (&((struct raw_sock *)__sk)->raw4)
static
inline
struct
raw_sock
*
raw_sk
(
const
struct
sock
*
sk
)
{
return
(
struct
raw_sock
*
)
sk
;
}
#endif
/* _ICMP_H */
#endif
/* _ICMP_H */
include/net/ipv6.h
View file @
0d7e0daa
...
@@ -229,8 +229,6 @@ extern int ip6_ra_control(struct sock *sk, int sel,
...
@@ -229,8 +229,6 @@ extern int ip6_ra_control(struct sock *sk, int sel,
void
(
*
destructor
)(
struct
sock
*
));
void
(
*
destructor
)(
struct
sock
*
));
extern
int
ip6_call_ra_chain
(
struct
sk_buff
*
skb
,
int
sel
);
extern
int
ipv6_parse_hopopts
(
struct
sk_buff
*
skb
,
int
);
extern
int
ipv6_parse_hopopts
(
struct
sk_buff
*
skb
,
int
);
extern
struct
ipv6_txoptions
*
ipv6_dup_options
(
struct
sock
*
sk
,
struct
ipv6_txoptions
*
opt
);
extern
struct
ipv6_txoptions
*
ipv6_dup_options
(
struct
sock
*
sk
,
struct
ipv6_txoptions
*
opt
);
...
...
kernel/compat.c
View file @
0d7e0daa
...
@@ -701,7 +701,7 @@ sigset_from_compat (sigset_t *set, compat_sigset_t *compat)
...
@@ -701,7 +701,7 @@ sigset_from_compat (sigset_t *set, compat_sigset_t *compat)
}
}
asmlinkage
long
asmlinkage
long
compat_rt_sigtimedwait
(
compat_sigset_t
__user
*
uthese
,
compat_
sys_
rt_sigtimedwait
(
compat_sigset_t
__user
*
uthese
,
struct
compat_siginfo
__user
*
uinfo
,
struct
compat_siginfo
__user
*
uinfo
,
struct
compat_timespec
__user
*
uts
,
compat_size_t
sigsetsize
)
struct
compat_timespec
__user
*
uts
,
compat_size_t
sigsetsize
)
{
{
...
...
kernel/spinlock.c
View file @
0d7e0daa
...
@@ -173,7 +173,7 @@ EXPORT_SYMBOL(_write_lock);
...
@@ -173,7 +173,7 @@ EXPORT_SYMBOL(_write_lock);
* (We do this in a function because inlining it would be excessive.)
* (We do this in a function because inlining it would be excessive.)
*/
*/
#define BUILD_LOCK_OPS(op, locktype
)
\
#define BUILD_LOCK_OPS(op, locktype
, is_locked_fn)
\
void __lockfunc _##op##_lock(locktype *lock) \
void __lockfunc _##op##_lock(locktype *lock) \
{ \
{ \
preempt_disable(); \
preempt_disable(); \
...
@@ -183,7 +183,8 @@ void __lockfunc _##op##_lock(locktype *lock) \
...
@@ -183,7 +183,8 @@ void __lockfunc _##op##_lock(locktype *lock) \
preempt_enable(); \
preempt_enable(); \
if (!(lock)->break_lock) \
if (!(lock)->break_lock) \
(lock)->break_lock = 1; \
(lock)->break_lock = 1; \
cpu_relax(); \
while (is_locked_fn(lock) && (lock)->break_lock) \
cpu_relax(); \
preempt_disable(); \
preempt_disable(); \
} \
} \
} \
} \
...
@@ -204,7 +205,8 @@ unsigned long __lockfunc _##op##_lock_irqsave(locktype *lock) \
...
@@ -204,7 +205,8 @@ unsigned long __lockfunc _##op##_lock_irqsave(locktype *lock) \
preempt_enable(); \
preempt_enable(); \
if (!(lock)->break_lock) \
if (!(lock)->break_lock) \
(lock)->break_lock = 1; \
(lock)->break_lock = 1; \
cpu_relax(); \
while (is_locked_fn(lock) && (lock)->break_lock) \
cpu_relax(); \
preempt_disable(); \
preempt_disable(); \
} \
} \
return flags; \
return flags; \
...
@@ -244,9 +246,9 @@ EXPORT_SYMBOL(_##op##_lock_bh)
...
@@ -244,9 +246,9 @@ EXPORT_SYMBOL(_##op##_lock_bh)
* _[spin|read|write]_lock_irqsave()
* _[spin|read|write]_lock_irqsave()
* _[spin|read|write]_lock_bh()
* _[spin|read|write]_lock_bh()
*/
*/
BUILD_LOCK_OPS
(
spin
,
spinlock_t
);
BUILD_LOCK_OPS
(
spin
,
spinlock_t
,
spin_is_locked
);
BUILD_LOCK_OPS
(
read
,
rwlock_t
);
BUILD_LOCK_OPS
(
read
,
rwlock_t
,
rwlock_is_locked
);
BUILD_LOCK_OPS
(
write
,
rwlock_t
);
BUILD_LOCK_OPS
(
write
,
rwlock_t
,
spin_is_locked
);
#endif
/* CONFIG_PREEMPT */
#endif
/* CONFIG_PREEMPT */
...
...
net/core/dv.c
View file @
0d7e0daa
...
@@ -52,26 +52,20 @@ int alloc_divert_blk(struct net_device *dev)
...
@@ -52,26 +52,20 @@ int alloc_divert_blk(struct net_device *dev)
{
{
int
alloc_size
=
(
sizeof
(
struct
divert_blk
)
+
3
)
&
~
3
;
int
alloc_size
=
(
sizeof
(
struct
divert_blk
)
+
3
)
&
~
3
;
dev
->
divert
=
NULL
;
if
(
dev
->
type
==
ARPHRD_ETHER
)
{
if
(
dev
->
type
==
ARPHRD_ETHER
)
{
printk
(
KERN_DEBUG
"divert: allocating divert_blk for %s
\n
"
,
dev
->
name
);
dev
->
divert
=
(
struct
divert_blk
*
)
dev
->
divert
=
(
struct
divert_blk
*
)
kmalloc
(
alloc_size
,
GFP_KERNEL
);
kmalloc
(
alloc_size
,
GFP_KERNEL
);
if
(
dev
->
divert
==
NULL
)
{
if
(
dev
->
divert
==
NULL
)
{
printk
(
KERN_
DEBUG
"divert: unable to allocate divert_blk for %s
\n
"
,
printk
(
KERN_
INFO
"divert: unable to allocate divert_blk for %s
\n
"
,
dev
->
name
);
dev
->
name
);
return
-
ENOMEM
;
return
-
ENOMEM
;
}
else
{
memset
(
dev
->
divert
,
0
,
sizeof
(
struct
divert_blk
));
}
}
dev_hold
(
dev
);
}
else
{
printk
(
KERN_DEBUG
"divert: not allocating divert_blk for non-ethernet device %s
\n
"
,
dev
->
name
);
dev
->
divert
=
NULL
;
memset
(
dev
->
divert
,
0
,
sizeof
(
struct
divert_blk
));
dev_hold
(
dev
);
}
}
return
0
;
return
0
;
}
}
...
@@ -85,11 +79,6 @@ void free_divert_blk(struct net_device *dev)
...
@@ -85,11 +79,6 @@ void free_divert_blk(struct net_device *dev)
kfree
(
dev
->
divert
);
kfree
(
dev
->
divert
);
dev
->
divert
=
NULL
;
dev
->
divert
=
NULL
;
dev_put
(
dev
);
dev_put
(
dev
);
printk
(
KERN_DEBUG
"divert: freeing divert_blk for %s
\n
"
,
dev
->
name
);
}
else
{
printk
(
KERN_DEBUG
"divert: no divert_blk to free, %s not ethernet
\n
"
,
dev
->
name
);
}
}
}
}
...
@@ -192,8 +181,12 @@ static int check_args(struct divert_cf *div_cf, struct net_device **dev)
...
@@ -192,8 +181,12 @@ static int check_args(struct divert_cf *div_cf, struct net_device **dev)
/*
/*
* control function of the diverter
* control function of the diverter
*/
*/
#if 0
#define DVDBG(a) \
#define DVDBG(a) \
printk(KERN_DEBUG "divert_ioctl() line %d %s\n", __LINE__, (a))
printk(KERN_DEBUG "divert_ioctl() line %d %s\n", __LINE__, (a))
#else
#define DVDBG(a)
#endif
int
divert_ioctl
(
unsigned
int
cmd
,
struct
divert_cf
__user
*
arg
)
int
divert_ioctl
(
unsigned
int
cmd
,
struct
divert_cf
__user
*
arg
)
{
{
...
...
net/ipv4/raw.c
View file @
0d7e0daa
...
@@ -135,7 +135,7 @@ static __inline__ int icmp_filter(struct sock *sk, struct sk_buff *skb)
...
@@ -135,7 +135,7 @@ static __inline__ int icmp_filter(struct sock *sk, struct sk_buff *skb)
type
=
skb
->
h
.
icmph
->
type
;
type
=
skb
->
h
.
icmph
->
type
;
if
(
type
<
32
)
{
if
(
type
<
32
)
{
__u32
data
=
raw
4
_sk
(
sk
)
->
filter
.
data
;
__u32
data
=
raw_sk
(
sk
)
->
filter
.
data
;
return
((
1
<<
type
)
&
data
)
!=
0
;
return
((
1
<<
type
)
&
data
)
!=
0
;
}
}
...
@@ -615,9 +615,10 @@ out: return err ? err : copied;
...
@@ -615,9 +615,10 @@ out: return err ? err : copied;
static
int
raw_init
(
struct
sock
*
sk
)
static
int
raw_init
(
struct
sock
*
sk
)
{
{
struct
raw_opt
*
tp
=
raw4_sk
(
sk
);
struct
raw_sock
*
rp
=
raw_sk
(
sk
);
if
(
inet_sk
(
sk
)
->
num
==
IPPROTO_ICMP
)
if
(
inet_sk
(
sk
)
->
num
==
IPPROTO_ICMP
)
memset
(
&
tp
->
filter
,
0
,
sizeof
(
t
p
->
filter
));
memset
(
&
rp
->
filter
,
0
,
sizeof
(
r
p
->
filter
));
return
0
;
return
0
;
}
}
...
@@ -625,7 +626,7 @@ static int raw_seticmpfilter(struct sock *sk, char __user *optval, int optlen)
...
@@ -625,7 +626,7 @@ static int raw_seticmpfilter(struct sock *sk, char __user *optval, int optlen)
{
{
if
(
optlen
>
sizeof
(
struct
icmp_filter
))
if
(
optlen
>
sizeof
(
struct
icmp_filter
))
optlen
=
sizeof
(
struct
icmp_filter
);
optlen
=
sizeof
(
struct
icmp_filter
);
if
(
copy_from_user
(
&
raw
4
_sk
(
sk
)
->
filter
,
optval
,
optlen
))
if
(
copy_from_user
(
&
raw_sk
(
sk
)
->
filter
,
optval
,
optlen
))
return
-
EFAULT
;
return
-
EFAULT
;
return
0
;
return
0
;
}
}
...
@@ -643,7 +644,7 @@ static int raw_geticmpfilter(struct sock *sk, char __user *optval, int __user *o
...
@@ -643,7 +644,7 @@ static int raw_geticmpfilter(struct sock *sk, char __user *optval, int __user *o
len
=
sizeof
(
struct
icmp_filter
);
len
=
sizeof
(
struct
icmp_filter
);
ret
=
-
EFAULT
;
ret
=
-
EFAULT
;
if
(
put_user
(
len
,
optlen
)
||
if
(
put_user
(
len
,
optlen
)
||
copy_to_user
(
optval
,
&
raw
4
_sk
(
sk
)
->
filter
,
len
))
copy_to_user
(
optval
,
&
raw_sk
(
sk
)
->
filter
,
len
))
goto
out
;
goto
out
;
ret
=
0
;
ret
=
0
;
out:
return
ret
;
out:
return
ret
;
...
...
net/ipv4/tcp.c
View file @
0d7e0daa
...
@@ -655,7 +655,7 @@ static ssize_t do_tcp_sendpages(struct sock *sk, struct page **pages, int poffse
...
@@ -655,7 +655,7 @@ static ssize_t do_tcp_sendpages(struct sock *sk, struct page **pages, int poffse
while
(
psize
>
0
)
{
while
(
psize
>
0
)
{
struct
sk_buff
*
skb
=
sk
->
sk_write_queue
.
prev
;
struct
sk_buff
*
skb
=
sk
->
sk_write_queue
.
prev
;
struct
page
*
page
=
pages
[
poffset
/
PAGE_SIZE
];
struct
page
*
page
=
pages
[
poffset
/
PAGE_SIZE
];
int
copy
,
i
;
int
copy
,
i
,
can_coalesce
;
int
offset
=
poffset
%
PAGE_SIZE
;
int
offset
=
poffset
%
PAGE_SIZE
;
int
size
=
min_t
(
size_t
,
psize
,
PAGE_SIZE
-
offset
);
int
size
=
min_t
(
size_t
,
psize
,
PAGE_SIZE
-
offset
);
...
@@ -677,14 +677,20 @@ static ssize_t do_tcp_sendpages(struct sock *sk, struct page **pages, int poffse
...
@@ -677,14 +677,20 @@ static ssize_t do_tcp_sendpages(struct sock *sk, struct page **pages, int poffse
copy
=
size
;
copy
=
size
;
i
=
skb_shinfo
(
skb
)
->
nr_frags
;
i
=
skb_shinfo
(
skb
)
->
nr_frags
;
if
(
skb_can_coalesce
(
skb
,
i
,
page
,
offset
))
{
can_coalesce
=
skb_can_coalesce
(
skb
,
i
,
page
,
offset
);
if
(
!
can_coalesce
&&
i
>=
MAX_SKB_FRAGS
)
{
tcp_mark_push
(
tp
,
skb
);
goto
new_segment
;
}
if
(
sk
->
sk_forward_alloc
<
copy
&&
!
sk_stream_mem_schedule
(
sk
,
copy
,
0
))
goto
wait_for_memory
;
if
(
can_coalesce
)
{
skb_shinfo
(
skb
)
->
frags
[
i
-
1
].
size
+=
copy
;
skb_shinfo
(
skb
)
->
frags
[
i
-
1
].
size
+=
copy
;
}
else
if
(
i
<
MAX_SKB_FRAGS
)
{
}
else
{
get_page
(
page
);
get_page
(
page
);
skb_fill_page_desc
(
skb
,
i
,
page
,
offset
,
copy
);
skb_fill_page_desc
(
skb
,
i
,
page
,
offset
,
copy
);
}
else
{
tcp_mark_push
(
tp
,
skb
);
goto
new_segment
;
}
}
skb
->
len
+=
copy
;
skb
->
len
+=
copy
;
...
...
net/ipv4/udp.c
View file @
0d7e0daa
...
@@ -386,7 +386,7 @@ void udp_err(struct sk_buff *skb, u32 info)
...
@@ -386,7 +386,7 @@ void udp_err(struct sk_buff *skb, u32 info)
*/
*/
static
void
udp_flush_pending_frames
(
struct
sock
*
sk
)
static
void
udp_flush_pending_frames
(
struct
sock
*
sk
)
{
{
struct
udp_
opt
*
up
=
udp_sk
(
sk
);
struct
udp_
sock
*
up
=
udp_sk
(
sk
);
if
(
up
->
pending
)
{
if
(
up
->
pending
)
{
up
->
len
=
0
;
up
->
len
=
0
;
...
@@ -398,7 +398,7 @@ static void udp_flush_pending_frames(struct sock *sk)
...
@@ -398,7 +398,7 @@ static void udp_flush_pending_frames(struct sock *sk)
/*
/*
* Push out all pending data as one UDP datagram. Socket is locked.
* Push out all pending data as one UDP datagram. Socket is locked.
*/
*/
static
int
udp_push_pending_frames
(
struct
sock
*
sk
,
struct
udp_
opt
*
up
)
static
int
udp_push_pending_frames
(
struct
sock
*
sk
,
struct
udp_
sock
*
up
)
{
{
struct
inet_sock
*
inet
=
inet_sk
(
sk
);
struct
inet_sock
*
inet
=
inet_sk
(
sk
);
struct
flowi
*
fl
=
&
inet
->
cork
.
fl
;
struct
flowi
*
fl
=
&
inet
->
cork
.
fl
;
...
@@ -483,7 +483,7 @@ int udp_sendmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,
...
@@ -483,7 +483,7 @@ int udp_sendmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,
size_t
len
)
size_t
len
)
{
{
struct
inet_sock
*
inet
=
inet_sk
(
sk
);
struct
inet_sock
*
inet
=
inet_sk
(
sk
);
struct
udp_
opt
*
up
=
udp_sk
(
sk
);
struct
udp_
sock
*
up
=
udp_sk
(
sk
);
int
ulen
=
len
;
int
ulen
=
len
;
struct
ipcm_cookie
ipc
;
struct
ipcm_cookie
ipc
;
struct
rtable
*
rt
=
NULL
;
struct
rtable
*
rt
=
NULL
;
...
@@ -672,7 +672,7 @@ int udp_sendmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,
...
@@ -672,7 +672,7 @@ int udp_sendmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,
static
int
udp_sendpage
(
struct
sock
*
sk
,
struct
page
*
page
,
int
offset
,
static
int
udp_sendpage
(
struct
sock
*
sk
,
struct
page
*
page
,
int
offset
,
size_t
size
,
int
flags
)
size_t
size
,
int
flags
)
{
{
struct
udp_
opt
*
up
=
udp_sk
(
sk
);
struct
udp_
sock
*
up
=
udp_sk
(
sk
);
int
ret
;
int
ret
;
if
(
!
up
->
pending
)
{
if
(
!
up
->
pending
)
{
...
@@ -902,7 +902,7 @@ static int udp_encap_rcv(struct sock * sk, struct sk_buff *skb)
...
@@ -902,7 +902,7 @@ static int udp_encap_rcv(struct sock * sk, struct sk_buff *skb)
#ifndef CONFIG_XFRM
#ifndef CONFIG_XFRM
return
1
;
return
1
;
#else
#else
struct
udp_
opt
*
up
=
udp_sk
(
sk
);
struct
udp_
sock
*
up
=
udp_sk
(
sk
);
struct
udphdr
*
uh
=
skb
->
h
.
uh
;
struct
udphdr
*
uh
=
skb
->
h
.
uh
;
struct
iphdr
*
iph
;
struct
iphdr
*
iph
;
int
iphlen
,
len
;
int
iphlen
,
len
;
...
@@ -988,7 +988,7 @@ static int udp_encap_rcv(struct sock * sk, struct sk_buff *skb)
...
@@ -988,7 +988,7 @@ static int udp_encap_rcv(struct sock * sk, struct sk_buff *skb)
*/
*/
static
int
udp_queue_rcv_skb
(
struct
sock
*
sk
,
struct
sk_buff
*
skb
)
static
int
udp_queue_rcv_skb
(
struct
sock
*
sk
,
struct
sk_buff
*
skb
)
{
{
struct
udp_
opt
*
up
=
udp_sk
(
sk
);
struct
udp_
sock
*
up
=
udp_sk
(
sk
);
/*
/*
* Charge it to the socket, dropping if the queue is full.
* Charge it to the socket, dropping if the queue is full.
...
@@ -1223,7 +1223,7 @@ static int udp_destroy_sock(struct sock *sk)
...
@@ -1223,7 +1223,7 @@ static int udp_destroy_sock(struct sock *sk)
static
int
udp_setsockopt
(
struct
sock
*
sk
,
int
level
,
int
optname
,
static
int
udp_setsockopt
(
struct
sock
*
sk
,
int
level
,
int
optname
,
char
__user
*
optval
,
int
optlen
)
char
__user
*
optval
,
int
optlen
)
{
{
struct
udp_
opt
*
up
=
udp_sk
(
sk
);
struct
udp_
sock
*
up
=
udp_sk
(
sk
);
int
val
;
int
val
;
int
err
=
0
;
int
err
=
0
;
...
@@ -1272,7 +1272,7 @@ static int udp_setsockopt(struct sock *sk, int level, int optname,
...
@@ -1272,7 +1272,7 @@ static int udp_setsockopt(struct sock *sk, int level, int optname,
static
int
udp_getsockopt
(
struct
sock
*
sk
,
int
level
,
int
optname
,
static
int
udp_getsockopt
(
struct
sock
*
sk
,
int
level
,
int
optname
,
char
__user
*
optval
,
int
__user
*
optlen
)
char
__user
*
optval
,
int
__user
*
optlen
)
{
{
struct
udp_
opt
*
up
=
udp_sk
(
sk
);
struct
udp_
sock
*
up
=
udp_sk
(
sk
);
int
val
,
len
;
int
val
,
len
;
if
(
level
!=
SOL_UDP
)
if
(
level
!=
SOL_UDP
)
...
...
net/ipv6/addrconf.c
View file @
0d7e0daa
...
@@ -99,9 +99,6 @@ static void addrconf_sysctl_register(struct inet6_dev *idev, struct ipv6_devconf
...
@@ -99,9 +99,6 @@ static void addrconf_sysctl_register(struct inet6_dev *idev, struct ipv6_devconf
static
void
addrconf_sysctl_unregister
(
struct
ipv6_devconf
*
p
);
static
void
addrconf_sysctl_unregister
(
struct
ipv6_devconf
*
p
);
#endif
#endif
int
inet6_dev_count
;
int
inet6_ifa_count
;
#ifdef CONFIG_IPV6_PRIVACY
#ifdef CONFIG_IPV6_PRIVACY
static
int
__ipv6_regen_rndid
(
struct
inet6_dev
*
idev
);
static
int
__ipv6_regen_rndid
(
struct
inet6_dev
*
idev
);
static
int
__ipv6_try_regen_rndid
(
struct
inet6_dev
*
idev
,
struct
in6_addr
*
tmpaddr
);
static
int
__ipv6_try_regen_rndid
(
struct
inet6_dev
*
idev
,
struct
in6_addr
*
tmpaddr
);
...
@@ -191,7 +188,9 @@ static struct ipv6_devconf ipv6_devconf_dflt = {
...
@@ -191,7 +188,9 @@ static struct ipv6_devconf ipv6_devconf_dflt = {
};
};
/* IPv6 Wildcard Address and Loopback Address defined by RFC2553 */
/* IPv6 Wildcard Address and Loopback Address defined by RFC2553 */
#if 0
const struct in6_addr in6addr_any = IN6ADDR_ANY_INIT;
const struct in6_addr in6addr_any = IN6ADDR_ANY_INIT;
#endif
const
struct
in6_addr
in6addr_loopback
=
IN6ADDR_LOOPBACK_INIT
;
const
struct
in6_addr
in6addr_loopback
=
IN6ADDR_LOOPBACK_INIT
;
int
ipv6_addr_type
(
const
struct
in6_addr
*
addr
)
int
ipv6_addr_type
(
const
struct
in6_addr
*
addr
)
...
@@ -310,7 +309,6 @@ void in6_dev_finish_destroy(struct inet6_dev *idev)
...
@@ -310,7 +309,6 @@ void in6_dev_finish_destroy(struct inet6_dev *idev)
return
;
return
;
}
}
snmp6_unregister_dev
(
idev
);
snmp6_unregister_dev
(
idev
);
inet6_dev_count
--
;
kfree
(
idev
);
kfree
(
idev
);
}
}
...
@@ -338,7 +336,6 @@ static struct inet6_dev * ipv6_add_dev(struct net_device *dev)
...
@@ -338,7 +336,6 @@ static struct inet6_dev * ipv6_add_dev(struct net_device *dev)
kfree
(
ndev
);
kfree
(
ndev
);
return
NULL
;
return
NULL
;
}
}
inet6_dev_count
++
;
/* We refer to the device */
/* We refer to the device */
dev_hold
(
dev
);
dev_hold
(
dev
);
...
@@ -475,7 +472,6 @@ void inet6_ifa_finish_destroy(struct inet6_ifaddr *ifp)
...
@@ -475,7 +472,6 @@ void inet6_ifa_finish_destroy(struct inet6_ifaddr *ifp)
}
}
dst_release
(
&
ifp
->
rt
->
u
.
dst
);
dst_release
(
&
ifp
->
rt
->
u
.
dst
);
inet6_ifa_count
--
;
kfree
(
ifp
);
kfree
(
ifp
);
}
}
...
@@ -530,7 +526,6 @@ ipv6_add_addr(struct inet6_dev *idev, const struct in6_addr *addr, int pfxlen,
...
@@ -530,7 +526,6 @@ ipv6_add_addr(struct inet6_dev *idev, const struct in6_addr *addr, int pfxlen,
ifa
->
flags
=
flags
|
IFA_F_TENTATIVE
;
ifa
->
flags
=
flags
|
IFA_F_TENTATIVE
;
ifa
->
cstamp
=
ifa
->
tstamp
=
jiffies
;
ifa
->
cstamp
=
ifa
->
tstamp
=
jiffies
;
inet6_ifa_count
++
;
ifa
->
idev
=
idev
;
ifa
->
idev
=
idev
;
in6_dev_hold
(
idev
);
in6_dev_hold
(
idev
);
/* For caller */
/* For caller */
...
...
net/ipv6/anycast.c
View file @
0d7e0daa
...
@@ -43,6 +43,8 @@
...
@@ -43,6 +43,8 @@
#include <net/checksum.h>
#include <net/checksum.h>
static
int
ipv6_dev_ac_dec
(
struct
net_device
*
dev
,
struct
in6_addr
*
addr
);
/* Big ac list lock for all the sockets */
/* Big ac list lock for all the sockets */
static
DEFINE_RWLOCK
(
ipv6_sk_ac_lock
);
static
DEFINE_RWLOCK
(
ipv6_sk_ac_lock
);
...
@@ -413,7 +415,7 @@ int __ipv6_dev_ac_dec(struct inet6_dev *idev, struct in6_addr *addr)
...
@@ -413,7 +415,7 @@ int __ipv6_dev_ac_dec(struct inet6_dev *idev, struct in6_addr *addr)
return
0
;
return
0
;
}
}
int
ipv6_dev_ac_dec
(
struct
net_device
*
dev
,
struct
in6_addr
*
addr
)
static
int
ipv6_dev_ac_dec
(
struct
net_device
*
dev
,
struct
in6_addr
*
addr
)
{
{
int
ret
;
int
ret
;
struct
inet6_dev
*
idev
=
in6_dev_get
(
dev
);
struct
inet6_dev
*
idev
=
in6_dev_get
(
dev
);
...
...
net/ipv6/exthdrs.c
View file @
0d7e0daa
...
@@ -501,83 +501,6 @@ int ipv6_parse_hopopts(struct sk_buff *skb, int nhoff)
...
@@ -501,83 +501,6 @@ int ipv6_parse_hopopts(struct sk_buff *skb, int nhoff)
* for headers.
* for headers.
*/
*/
static
u8
*
ipv6_build_rthdr
(
struct
sk_buff
*
skb
,
u8
*
prev_hdr
,
struct
ipv6_rt_hdr
*
opt
,
struct
in6_addr
*
addr
)
{
struct
rt0_hdr
*
phdr
,
*
ihdr
;
int
hops
;
ihdr
=
(
struct
rt0_hdr
*
)
opt
;
phdr
=
(
struct
rt0_hdr
*
)
skb_put
(
skb
,
(
ihdr
->
rt_hdr
.
hdrlen
+
1
)
<<
3
);
memcpy
(
phdr
,
ihdr
,
sizeof
(
struct
rt0_hdr
));
hops
=
ihdr
->
rt_hdr
.
hdrlen
>>
1
;
if
(
hops
>
1
)
memcpy
(
phdr
->
addr
,
ihdr
->
addr
+
1
,
(
hops
-
1
)
*
sizeof
(
struct
in6_addr
));
ipv6_addr_copy
(
phdr
->
addr
+
(
hops
-
1
),
addr
);
phdr
->
rt_hdr
.
nexthdr
=
*
prev_hdr
;
*
prev_hdr
=
NEXTHDR_ROUTING
;
return
&
phdr
->
rt_hdr
.
nexthdr
;
}
static
u8
*
ipv6_build_exthdr
(
struct
sk_buff
*
skb
,
u8
*
prev_hdr
,
u8
type
,
struct
ipv6_opt_hdr
*
opt
)
{
struct
ipv6_opt_hdr
*
h
=
(
struct
ipv6_opt_hdr
*
)
skb_put
(
skb
,
ipv6_optlen
(
opt
));
memcpy
(
h
,
opt
,
ipv6_optlen
(
opt
));
h
->
nexthdr
=
*
prev_hdr
;
*
prev_hdr
=
type
;
return
&
h
->
nexthdr
;
}
u8
*
ipv6_build_nfrag_opts
(
struct
sk_buff
*
skb
,
u8
*
prev_hdr
,
struct
ipv6_txoptions
*
opt
,
struct
in6_addr
*
daddr
,
u32
jumbolen
)
{
struct
ipv6_opt_hdr
*
h
=
(
struct
ipv6_opt_hdr
*
)
skb
->
data
;
if
(
opt
&&
opt
->
hopopt
)
prev_hdr
=
ipv6_build_exthdr
(
skb
,
prev_hdr
,
NEXTHDR_HOP
,
opt
->
hopopt
);
if
(
jumbolen
)
{
u8
*
jumboopt
=
(
u8
*
)
skb_put
(
skb
,
8
);
if
(
opt
&&
opt
->
hopopt
)
{
*
jumboopt
++
=
IPV6_TLV_PADN
;
*
jumboopt
++
=
0
;
h
->
hdrlen
++
;
}
else
{
h
=
(
struct
ipv6_opt_hdr
*
)
jumboopt
;
h
->
nexthdr
=
*
prev_hdr
;
h
->
hdrlen
=
0
;
jumboopt
+=
2
;
*
prev_hdr
=
NEXTHDR_HOP
;
prev_hdr
=
&
h
->
nexthdr
;
}
jumboopt
[
0
]
=
IPV6_TLV_JUMBO
;
jumboopt
[
1
]
=
4
;
*
(
u32
*
)(
jumboopt
+
2
)
=
htonl
(
jumbolen
);
}
if
(
opt
)
{
if
(
opt
->
dst0opt
)
prev_hdr
=
ipv6_build_exthdr
(
skb
,
prev_hdr
,
NEXTHDR_DEST
,
opt
->
dst0opt
);
if
(
opt
->
srcrt
)
prev_hdr
=
ipv6_build_rthdr
(
skb
,
prev_hdr
,
opt
->
srcrt
,
daddr
);
}
return
prev_hdr
;
}
u8
*
ipv6_build_frag_opts
(
struct
sk_buff
*
skb
,
u8
*
prev_hdr
,
struct
ipv6_txoptions
*
opt
)
{
if
(
opt
->
dst1opt
)
prev_hdr
=
ipv6_build_exthdr
(
skb
,
prev_hdr
,
NEXTHDR_DEST
,
opt
->
dst1opt
);
return
prev_hdr
;
}
static
void
ipv6_push_rthdr
(
struct
sk_buff
*
skb
,
u8
*
proto
,
static
void
ipv6_push_rthdr
(
struct
sk_buff
*
skb
,
u8
*
proto
,
struct
ipv6_rt_hdr
*
opt
,
struct
ipv6_rt_hdr
*
opt
,
struct
in6_addr
**
addr_p
)
struct
in6_addr
**
addr_p
)
...
...
net/ipv6/icmp.c
View file @
0d7e0daa
...
@@ -211,7 +211,7 @@ static __inline__ int opt_unrec(struct sk_buff *skb, __u32 offset)
...
@@ -211,7 +211,7 @@ static __inline__ int opt_unrec(struct sk_buff *skb, __u32 offset)
return
(
*
op
&
0xC0
)
==
0x80
;
return
(
*
op
&
0xC0
)
==
0x80
;
}
}
int
icmpv6_push_pending_frames
(
struct
sock
*
sk
,
struct
flowi
*
fl
,
struct
icmp6hdr
*
thdr
,
int
len
)
static
int
icmpv6_push_pending_frames
(
struct
sock
*
sk
,
struct
flowi
*
fl
,
struct
icmp6hdr
*
thdr
,
int
len
)
{
{
struct
sk_buff
*
skb
;
struct
sk_buff
*
skb
;
struct
icmp6hdr
*
icmp6h
;
struct
icmp6hdr
*
icmp6h
;
...
...
net/ipv6/ip6_output.c
View file @
0d7e0daa
...
@@ -311,7 +311,7 @@ int ip6_nd_hdr(struct sock *sk, struct sk_buff *skb, struct net_device *dev,
...
@@ -311,7 +311,7 @@ int ip6_nd_hdr(struct sock *sk, struct sk_buff *skb, struct net_device *dev,
return
0
;
return
0
;
}
}
int
ip6_call_ra_chain
(
struct
sk_buff
*
skb
,
int
sel
)
static
int
ip6_call_ra_chain
(
struct
sk_buff
*
skb
,
int
sel
)
{
{
struct
ip6_ra_chain
*
ra
;
struct
ip6_ra_chain
*
ra
;
struct
sock
*
last
=
NULL
;
struct
sock
*
last
=
NULL
;
...
@@ -745,7 +745,7 @@ int ip6_dst_lookup(struct sock *sk, struct dst_entry **dst, struct flowi *fl)
...
@@ -745,7 +745,7 @@ int ip6_dst_lookup(struct sock *sk, struct dst_entry **dst, struct flowi *fl)
if
(
sk
)
{
if
(
sk
)
{
struct
ipv6_pinfo
*
np
=
inet6_sk
(
sk
);
struct
ipv6_pinfo
*
np
=
inet6_sk
(
sk
);
*
dst
=
__
sk_dst_check
(
sk
,
np
->
dst_cookie
);
*
dst
=
sk_dst_check
(
sk
,
np
->
dst_cookie
);
if
(
*
dst
)
{
if
(
*
dst
)
{
struct
rt6_info
*
rt
=
(
struct
rt6_info
*
)
*
dst
;
struct
rt6_info
*
rt
=
(
struct
rt6_info
*
)
*
dst
;
...
@@ -772,9 +772,9 @@ int ip6_dst_lookup(struct sock *sk, struct dst_entry **dst, struct flowi *fl)
...
@@ -772,9 +772,9 @@ int ip6_dst_lookup(struct sock *sk, struct dst_entry **dst, struct flowi *fl)
&&
(
np
->
daddr_cache
==
NULL
||
&&
(
np
->
daddr_cache
==
NULL
||
!
ipv6_addr_equal
(
&
fl
->
fl6_dst
,
np
->
daddr_cache
)))
!
ipv6_addr_equal
(
&
fl
->
fl6_dst
,
np
->
daddr_cache
)))
||
(
fl
->
oif
&&
fl
->
oif
!=
(
*
dst
)
->
dev
->
ifindex
))
{
||
(
fl
->
oif
&&
fl
->
oif
!=
(
*
dst
)
->
dev
->
ifindex
))
{
dst_release
(
*
dst
);
*
dst
=
NULL
;
*
dst
=
NULL
;
}
else
}
dst_hold
(
*
dst
);
}
}
}
}
...
...
net/ipv6/ipv6_syms.c
View file @
0d7e0daa
...
@@ -32,8 +32,6 @@ EXPORT_SYMBOL(inet6_getname);
...
@@ -32,8 +32,6 @@ EXPORT_SYMBOL(inet6_getname);
EXPORT_SYMBOL
(
inet6_ioctl
);
EXPORT_SYMBOL
(
inet6_ioctl
);
EXPORT_SYMBOL
(
ipv6_get_saddr
);
EXPORT_SYMBOL
(
ipv6_get_saddr
);
EXPORT_SYMBOL
(
ipv6_chk_addr
);
EXPORT_SYMBOL
(
ipv6_chk_addr
);
EXPORT_SYMBOL
(
in6addr_any
);
EXPORT_SYMBOL
(
in6addr_loopback
);
EXPORT_SYMBOL
(
in6_dev_finish_destroy
);
EXPORT_SYMBOL
(
in6_dev_finish_destroy
);
#ifdef CONFIG_XFRM
#ifdef CONFIG_XFRM
EXPORT_SYMBOL
(
xfrm6_rcv
);
EXPORT_SYMBOL
(
xfrm6_rcv
);
...
...
net/ipv6/mcast.c
View file @
0d7e0daa
...
@@ -121,7 +121,7 @@ struct mld2_query {
...
@@ -121,7 +121,7 @@ struct mld2_query {
struct
in6_addr
srcs
[
0
];
struct
in6_addr
srcs
[
0
];
};
};
struct
in6_addr
mld2_all_mcr
=
MLD2_ALL_MCR_INIT
;
st
atic
st
ruct
in6_addr
mld2_all_mcr
=
MLD2_ALL_MCR_INIT
;
/* Big mc list lock for all the sockets */
/* Big mc list lock for all the sockets */
static
DEFINE_RWLOCK
(
ipv6_sk_mc_lock
);
static
DEFINE_RWLOCK
(
ipv6_sk_mc_lock
);
...
@@ -143,12 +143,14 @@ static void mld_clear_delrec(struct inet6_dev *idev);
...
@@ -143,12 +143,14 @@ static void mld_clear_delrec(struct inet6_dev *idev);
static
int
sf_setstate
(
struct
ifmcaddr6
*
pmc
);
static
int
sf_setstate
(
struct
ifmcaddr6
*
pmc
);
static
void
sf_markstate
(
struct
ifmcaddr6
*
pmc
);
static
void
sf_markstate
(
struct
ifmcaddr6
*
pmc
);
static
void
ip6_mc_clear_src
(
struct
ifmcaddr6
*
pmc
);
static
void
ip6_mc_clear_src
(
struct
ifmcaddr6
*
pmc
);
int
ip6_mc_del_src
(
struct
inet6_dev
*
idev
,
struct
in6_addr
*
pmca
,
int
sfmode
,
static
int
ip6_mc_del_src
(
struct
inet6_dev
*
idev
,
struct
in6_addr
*
pmca
,
int
sfcount
,
struct
in6_addr
*
psfsrc
,
int
delta
);
int
sfmode
,
int
sfcount
,
struct
in6_addr
*
psfsrc
,
int
ip6_mc_add_src
(
struct
inet6_dev
*
idev
,
struct
in6_addr
*
pmca
,
int
sfmode
,
int
delta
);
int
sfcount
,
struct
in6_addr
*
psfsrc
,
int
delta
);
static
int
ip6_mc_add_src
(
struct
inet6_dev
*
idev
,
struct
in6_addr
*
pmca
,
int
ip6_mc_leave_src
(
struct
sock
*
sk
,
struct
ipv6_mc_socklist
*
iml
,
int
sfmode
,
int
sfcount
,
struct
in6_addr
*
psfsrc
,
struct
inet6_dev
*
idev
);
int
delta
);
static
int
ip6_mc_leave_src
(
struct
sock
*
sk
,
struct
ipv6_mc_socklist
*
iml
,
struct
inet6_dev
*
idev
);
#define IGMP6_UNSOLICITED_IVAL (10*HZ)
#define IGMP6_UNSOLICITED_IVAL (10*HZ)
...
@@ -272,7 +274,7 @@ int ipv6_sock_mc_drop(struct sock *sk, int ifindex, struct in6_addr *addr)
...
@@ -272,7 +274,7 @@ int ipv6_sock_mc_drop(struct sock *sk, int ifindex, struct in6_addr *addr)
return
-
ENOENT
;
return
-
ENOENT
;
}
}
struct
inet6_dev
*
ip6_mc_find_dev
(
struct
in6_addr
*
group
,
int
ifindex
)
st
atic
st
ruct
inet6_dev
*
ip6_mc_find_dev
(
struct
in6_addr
*
group
,
int
ifindex
)
{
{
struct
net_device
*
dev
=
NULL
;
struct
net_device
*
dev
=
NULL
;
struct
inet6_dev
*
idev
=
NULL
;
struct
inet6_dev
*
idev
=
NULL
;
...
@@ -1723,8 +1725,9 @@ static int ip6_mc_del1_src(struct ifmcaddr6 *pmc, int sfmode,
...
@@ -1723,8 +1725,9 @@ static int ip6_mc_del1_src(struct ifmcaddr6 *pmc, int sfmode,
return
rv
;
return
rv
;
}
}
int
ip6_mc_del_src
(
struct
inet6_dev
*
idev
,
struct
in6_addr
*
pmca
,
int
sfmode
,
static
int
ip6_mc_del_src
(
struct
inet6_dev
*
idev
,
struct
in6_addr
*
pmca
,
int
sfcount
,
struct
in6_addr
*
psfsrc
,
int
delta
)
int
sfmode
,
int
sfcount
,
struct
in6_addr
*
psfsrc
,
int
delta
)
{
{
struct
ifmcaddr6
*
pmc
;
struct
ifmcaddr6
*
pmc
;
int
changerec
=
0
;
int
changerec
=
0
;
...
@@ -1847,8 +1850,9 @@ static int sf_setstate(struct ifmcaddr6 *pmc)
...
@@ -1847,8 +1850,9 @@ static int sf_setstate(struct ifmcaddr6 *pmc)
/*
/*
* Add multicast source filter list to the interface list
* Add multicast source filter list to the interface list
*/
*/
int
ip6_mc_add_src
(
struct
inet6_dev
*
idev
,
struct
in6_addr
*
pmca
,
int
sfmode
,
static
int
ip6_mc_add_src
(
struct
inet6_dev
*
idev
,
struct
in6_addr
*
pmca
,
int
sfcount
,
struct
in6_addr
*
psfsrc
,
int
delta
)
int
sfmode
,
int
sfcount
,
struct
in6_addr
*
psfsrc
,
int
delta
)
{
{
struct
ifmcaddr6
*
pmc
;
struct
ifmcaddr6
*
pmc
;
int
isexclude
;
int
isexclude
;
...
@@ -1951,8 +1955,8 @@ static void igmp6_join_group(struct ifmcaddr6 *ma)
...
@@ -1951,8 +1955,8 @@ static void igmp6_join_group(struct ifmcaddr6 *ma)
spin_unlock_bh
(
&
ma
->
mca_lock
);
spin_unlock_bh
(
&
ma
->
mca_lock
);
}
}
int
ip6_mc_leave_src
(
struct
sock
*
sk
,
struct
ipv6_mc_socklist
*
iml
,
static
int
ip6_mc_leave_src
(
struct
sock
*
sk
,
struct
ipv6_mc_socklist
*
iml
,
struct
inet6_dev
*
idev
)
struct
inet6_dev
*
idev
)
{
{
int
err
;
int
err
;
...
...
net/ipv6/route.c
View file @
0d7e0daa
...
@@ -208,8 +208,8 @@ static __inline__ struct rt6_info *rt6_device_match(struct rt6_info *rt,
...
@@ -208,8 +208,8 @@ static __inline__ struct rt6_info *rt6_device_match(struct rt6_info *rt,
/*
/*
* pointer to the last default router chosen. BH is disabled locally.
* pointer to the last default router chosen. BH is disabled locally.
*/
*/
struct
rt6_info
*
rt6_dflt_pointer
;
st
atic
st
ruct
rt6_info
*
rt6_dflt_pointer
;
DEFINE_SPINLOCK
(
rt6_dflt_lock
);
static
DEFINE_SPINLOCK
(
rt6_dflt_lock
);
void
rt6_reset_dflt_pointer
(
struct
rt6_info
*
rt
)
void
rt6_reset_dflt_pointer
(
struct
rt6_info
*
rt
)
{
{
...
...
net/ipv6/sysctl_net_ipv6.c
View file @
0d7e0daa
...
@@ -19,7 +19,7 @@ extern ctl_table ipv6_icmp_table[];
...
@@ -19,7 +19,7 @@ extern ctl_table ipv6_icmp_table[];
#ifdef CONFIG_SYSCTL
#ifdef CONFIG_SYSCTL
ctl_table
ipv6_table
[]
=
{
static
ctl_table
ipv6_table
[]
=
{
{
{
.
ctl_name
=
NET_IPV6_ROUTE
,
.
ctl_name
=
NET_IPV6_ROUTE
,
.
procname
=
"route"
,
.
procname
=
"route"
,
...
...
net/ipv6/udp.c
View file @
0d7e0daa
...
@@ -549,7 +549,7 @@ static int udpv6_rcv(struct sk_buff **pskb, unsigned int *nhoffp)
...
@@ -549,7 +549,7 @@ static int udpv6_rcv(struct sk_buff **pskb, unsigned int *nhoffp)
*/
*/
static
void
udp_v6_flush_pending_frames
(
struct
sock
*
sk
)
static
void
udp_v6_flush_pending_frames
(
struct
sock
*
sk
)
{
{
struct
udp_
opt
*
up
=
udp_sk
(
sk
);
struct
udp_
sock
*
up
=
udp_sk
(
sk
);
if
(
up
->
pending
)
{
if
(
up
->
pending
)
{
up
->
len
=
0
;
up
->
len
=
0
;
...
@@ -562,7 +562,7 @@ static void udp_v6_flush_pending_frames(struct sock *sk)
...
@@ -562,7 +562,7 @@ static void udp_v6_flush_pending_frames(struct sock *sk)
* Sending
* Sending
*/
*/
static
int
udp_v6_push_pending_frames
(
struct
sock
*
sk
,
struct
udp_
opt
*
up
)
static
int
udp_v6_push_pending_frames
(
struct
sock
*
sk
,
struct
udp_
sock
*
up
)
{
{
struct
sk_buff
*
skb
;
struct
sk_buff
*
skb
;
struct
udphdr
*
uh
;
struct
udphdr
*
uh
;
...
@@ -623,7 +623,7 @@ static int udpv6_sendmsg(struct kiocb *iocb, struct sock *sk,
...
@@ -623,7 +623,7 @@ static int udpv6_sendmsg(struct kiocb *iocb, struct sock *sk,
struct
msghdr
*
msg
,
size_t
len
)
struct
msghdr
*
msg
,
size_t
len
)
{
{
struct
ipv6_txoptions
opt_space
;
struct
ipv6_txoptions
opt_space
;
struct
udp_
opt
*
up
=
udp_sk
(
sk
);
struct
udp_
sock
*
up
=
udp_sk
(
sk
);
struct
inet_sock
*
inet
=
inet_sk
(
sk
);
struct
inet_sock
*
inet
=
inet_sk
(
sk
);
struct
ipv6_pinfo
*
np
=
inet6_sk
(
sk
);
struct
ipv6_pinfo
*
np
=
inet6_sk
(
sk
);
struct
sockaddr_in6
*
sin6
=
(
struct
sockaddr_in6
*
)
msg
->
msg_name
;
struct
sockaddr_in6
*
sin6
=
(
struct
sockaddr_in6
*
)
msg
->
msg_name
;
...
@@ -878,7 +878,7 @@ static int udpv6_destroy_sock(struct sock *sk)
...
@@ -878,7 +878,7 @@ static int udpv6_destroy_sock(struct sock *sk)
static
int
udpv6_setsockopt
(
struct
sock
*
sk
,
int
level
,
int
optname
,
static
int
udpv6_setsockopt
(
struct
sock
*
sk
,
int
level
,
int
optname
,
char
__user
*
optval
,
int
optlen
)
char
__user
*
optval
,
int
optlen
)
{
{
struct
udp_
opt
*
up
=
udp_sk
(
sk
);
struct
udp_
sock
*
up
=
udp_sk
(
sk
);
int
val
;
int
val
;
int
err
=
0
;
int
err
=
0
;
...
@@ -925,7 +925,7 @@ static int udpv6_setsockopt(struct sock *sk, int level, int optname,
...
@@ -925,7 +925,7 @@ static int udpv6_setsockopt(struct sock *sk, int level, int optname,
static
int
udpv6_getsockopt
(
struct
sock
*
sk
,
int
level
,
int
optname
,
static
int
udpv6_getsockopt
(
struct
sock
*
sk
,
int
level
,
int
optname
,
char
__user
*
optval
,
int
__user
*
optlen
)
char
__user
*
optval
,
int
__user
*
optlen
)
{
{
struct
udp_
opt
*
up
=
udp_sk
(
sk
);
struct
udp_
sock
*
up
=
udp_sk
(
sk
);
int
val
,
len
;
int
val
,
len
;
if
(
level
!=
SOL_UDP
)
if
(
level
!=
SOL_UDP
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment