Commit 754cdd4a authored by Linus Torvalds's avatar Linus Torvalds

Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/blackfin-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/blackfin-2.6:
  Blackfin SPORTS UART Driver: converting BFIN->BLACKFIN
  Blackfin serial driver: add extra IRQ flag for 8250 serial driver
  8250 Serial Driver: Added support for 8250-class UARTs in HV Sistemas H8606 board
  Blackfin arch: Fix bug - USB fails to build for BF524/BF526
  Blackfin arch: update boards defconfig files
  Blackfin arch: IO Port functions to read/write unalligned memory
  Blackfin arch: enable a choice to provide 4M DMA memory
  Blackfin arch: cleanup the icplb/dcplb multiple hit checks
  Blackfin arch: Add workaround to read edge triggered GPIOs
  Blackfin arch: Sync channel defines with struct dma_register dma_io_base_addr.
  Blackfin arch: Check for Anomaly 05000182
  [Blackfin] arch: rename bf5xx-flash to bfin-async-flash
  [Blackfin] arch: Blackfin checksum annotations
parents db07b023 460ed2ea
...@@ -479,16 +479,6 @@ comment "Memory Setup" ...@@ -479,16 +479,6 @@ comment "Memory Setup"
comment "Misc" comment "Misc"
config ENET_FLASH_PIN
int "PF port/pin used for flash and ethernet sharing"
depends on (BFIN533_STAMP)
default 0
help
PF port/pin used for flash and ethernet sharing to allow other PF
pins to be used on other platforms without having to touch common
code.
For example: PF0 --> 0,PF1 --> 1,PF2 --> 2, etc.
choice choice
prompt "Blackfin Exception Scratch Register" prompt "Blackfin Exception Scratch Register"
default BFIN_SCRATCH_REG_RETN default BFIN_SCRATCH_REG_RETN
...@@ -695,6 +685,8 @@ choice ...@@ -695,6 +685,8 @@ choice
prompt "Uncached SDRAM region" prompt "Uncached SDRAM region"
default DMA_UNCACHED_1M default DMA_UNCACHED_1M
depends on BFIN_DMA_5XX depends on BFIN_DMA_5XX
config DMA_UNCACHED_4M
bool "Enable 4M DMA region"
config DMA_UNCACHED_2M config DMA_UNCACHED_2M
bool "Enable 2M DMA region" bool "Enable 2M DMA region"
config DMA_UNCACHED_1M config DMA_UNCACHED_1M
......
This diff is collapsed.
This diff is collapsed.
...@@ -212,7 +212,7 @@ CONFIG_HZ=250 ...@@ -212,7 +212,7 @@ CONFIG_HZ=250
# #
# Memory Setup # Memory Setup
# #
CONFIG_MEM_SIZE=64 CONFIG_MAX_MEM_SIZE=64
CONFIG_MEM_ADD_WIDTH=10 CONFIG_MEM_ADD_WIDTH=10
# #
......
...@@ -90,6 +90,17 @@ int request_dma(unsigned int channel, char *device_id) ...@@ -90,6 +90,17 @@ int request_dma(unsigned int channel, char *device_id)
{ {
pr_debug("request_dma() : BEGIN \n"); pr_debug("request_dma() : BEGIN \n");
#if defined(CONFIG_BF561) && ANOMALY_05000182
if (channel >= CH_IMEM_STREAM0_DEST && channel <= CH_IMEM_STREAM1_DEST) {
if (get_cclk() > 500000000) {
printk(KERN_WARNING
"Request IMDMA failed due to ANOMALY 05000182\n");
return -EFAULT;
}
}
#endif
mutex_lock(&(dma_ch[channel].dmalock)); mutex_lock(&(dma_ch[channel].dmalock));
if ((dma_ch[channel].chan_status == DMA_CHANNEL_REQUESTED) if ((dma_ch[channel].chan_status == DMA_CHANNEL_REQUESTED)
......
...@@ -1130,6 +1130,25 @@ void bfin_gpio_irq_prepare(unsigned gpio) ...@@ -1130,6 +1130,25 @@ void bfin_gpio_irq_prepare(unsigned gpio)
#else #else
int gpio_get_value(unsigned gpio)
{
unsigned long flags;
int ret;
if (unlikely(get_gpio_edge(gpio))) {
local_irq_save(flags);
set_gpio_edge(gpio, 0);
ret = get_gpio_data(gpio);
set_gpio_edge(gpio, 1);
local_irq_restore(flags);
return ret;
} else
return get_gpio_data(gpio);
}
EXPORT_SYMBOL(gpio_get_value);
int gpio_direction_input(unsigned gpio) int gpio_direction_input(unsigned gpio)
{ {
unsigned long flags; unsigned long flags;
......
...@@ -90,7 +90,9 @@ EXPORT_SYMBOL(__umodsi3); ...@@ -90,7 +90,9 @@ EXPORT_SYMBOL(__umodsi3);
EXPORT_SYMBOL(outsb); EXPORT_SYMBOL(outsb);
EXPORT_SYMBOL(insb); EXPORT_SYMBOL(insb);
EXPORT_SYMBOL(outsw); EXPORT_SYMBOL(outsw);
EXPORT_SYMBOL(outsw_8);
EXPORT_SYMBOL(insw); EXPORT_SYMBOL(insw);
EXPORT_SYMBOL(insw_8);
EXPORT_SYMBOL(outsl); EXPORT_SYMBOL(outsl);
EXPORT_SYMBOL(insl); EXPORT_SYMBOL(insl);
EXPORT_SYMBOL(insl_16); EXPORT_SYMBOL(insl_16);
......
...@@ -364,13 +364,13 @@ asmlinkage void trap_c(struct pt_regs *fp) ...@@ -364,13 +364,13 @@ asmlinkage void trap_c(struct pt_regs *fp)
/* 0x27 - Data CPLB Multiple Hits - Linux Trap Zero, handled here */ /* 0x27 - Data CPLB Multiple Hits - Linux Trap Zero, handled here */
case VEC_CPLB_MHIT: case VEC_CPLB_MHIT:
info.si_code = ILL_CPLB_MULHIT; info.si_code = ILL_CPLB_MULHIT;
#ifdef CONFIG_DEBUG_HUNT_FOR_ZERO
sig = SIGSEGV; sig = SIGSEGV;
printk(KERN_NOTICE "NULL pointer access (probably)\n"); #ifdef CONFIG_DEBUG_HUNT_FOR_ZERO
#else if (saved_dcplb_fault_addr < (void *)FIXED_CODE_START)
sig = SIGILL; printk(KERN_NOTICE "NULL pointer access\n");
printk(KERN_NOTICE EXC_0x27(KERN_NOTICE)); else
#endif #endif
printk(KERN_NOTICE EXC_0x27(KERN_NOTICE));
CHK_DEBUGGER_TRAP(); CHK_DEBUGGER_TRAP();
break; break;
/* 0x28 - Emulation Watchpoint, handled here */ /* 0x28 - Emulation Watchpoint, handled here */
...@@ -419,13 +419,13 @@ asmlinkage void trap_c(struct pt_regs *fp) ...@@ -419,13 +419,13 @@ asmlinkage void trap_c(struct pt_regs *fp)
/* 0x2D - Instruction CPLB Multiple Hits, handled here */ /* 0x2D - Instruction CPLB Multiple Hits, handled here */
case VEC_CPLB_I_MHIT: case VEC_CPLB_I_MHIT:
info.si_code = ILL_CPLB_MULHIT; info.si_code = ILL_CPLB_MULHIT;
#ifdef CONFIG_DEBUG_HUNT_FOR_ZERO
sig = SIGSEGV; sig = SIGSEGV;
printk(KERN_NOTICE "Jump to address 0 - 0x0fff\n"); #ifdef CONFIG_DEBUG_HUNT_FOR_ZERO
#else if (saved_icplb_fault_addr < (void *)FIXED_CODE_START)
sig = SIGILL; printk(KERN_NOTICE "Jump to NULL address\n");
printk(KERN_NOTICE EXC_0x2D(KERN_NOTICE)); else
#endif #endif
printk(KERN_NOTICE EXC_0x2D(KERN_NOTICE));
CHK_DEBUGGER_TRAP(); CHK_DEBUGGER_TRAP();
break; break;
/* 0x2E - Illegal use of Supervisor Resource, handled here */ /* 0x2E - Illegal use of Supervisor Resource, handled here */
......
...@@ -72,9 +72,9 @@ static unsigned short do_csum(const unsigned char *buff, int len) ...@@ -72,9 +72,9 @@ static unsigned short do_csum(const unsigned char *buff, int len)
* This is a version of ip_compute_csum() optimized for IP headers, * This is a version of ip_compute_csum() optimized for IP headers,
* which always checksum on 4 octet boundaries. * which always checksum on 4 octet boundaries.
*/ */
unsigned short ip_fast_csum(unsigned char *iph, unsigned int ihl) __sum16 ip_fast_csum(unsigned char *iph, unsigned int ihl)
{ {
return ~do_csum(iph, ihl * 4); return (__force __sum16)~do_csum(iph, ihl * 4);
} }
/* /*
...@@ -89,7 +89,7 @@ unsigned short ip_fast_csum(unsigned char *iph, unsigned int ihl) ...@@ -89,7 +89,7 @@ unsigned short ip_fast_csum(unsigned char *iph, unsigned int ihl)
* *
* it's best to have buff aligned on a 32-bit boundary * it's best to have buff aligned on a 32-bit boundary
*/ */
unsigned int csum_partial(const unsigned char *buff, int len, unsigned int sum) __wsum csum_partial(const void *buff, int len, __wsum sum)
{ {
/* /*
* Just in case we get nasty checksum data... * Just in case we get nasty checksum data...
...@@ -109,22 +109,22 @@ unsigned int csum_partial(const unsigned char *buff, int len, unsigned int sum) ...@@ -109,22 +109,22 @@ unsigned int csum_partial(const unsigned char *buff, int len, unsigned int sum)
* this routine is used for miscellaneous IP-like checksums, mainly * this routine is used for miscellaneous IP-like checksums, mainly
* in icmp.c * in icmp.c
*/ */
unsigned short ip_compute_csum(const unsigned char *buff, int len) __sum16 ip_compute_csum(const void *buff, int len)
{ {
return ~do_csum(buff, len); return (__force __sum16)~do_csum(buff, len);
} }
/* /*
* copy from fs while checksumming, otherwise like csum_partial * copy from fs while checksumming, otherwise like csum_partial
*/ */
unsigned int __wsum
csum_partial_copy_from_user(const unsigned char *src, unsigned char *dst, csum_partial_copy_from_user(const void __user *src, void *dst,
int len, int sum, int *csum_err) int len, __wsum sum, int *csum_err)
{ {
if (csum_err) if (csum_err)
*csum_err = 0; *csum_err = 0;
memcpy(dst, src, len); memcpy(dst, (__force void *)src, len);
return csum_partial(dst, len, sum); return csum_partial(dst, len, sum);
} }
...@@ -132,8 +132,7 @@ csum_partial_copy_from_user(const unsigned char *src, unsigned char *dst, ...@@ -132,8 +132,7 @@ csum_partial_copy_from_user(const unsigned char *src, unsigned char *dst,
* copy from ds while checksumming, otherwise like csum_partial * copy from ds while checksumming, otherwise like csum_partial
*/ */
unsigned int csum_partial_copy(const unsigned char *src, unsigned char *dst, __wsum csum_partial_copy(const void *src, void *dst, int len, __wsum sum)
int len, int sum)
{ {
memcpy(dst, src, len); memcpy(dst, src, len);
return csum_partial(dst, len, sum); return csum_partial(dst, len, sum);
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
* Description: Implementation of ins{bwl} for BlackFin processors using zero overhead loops. * Description: Implementation of ins{bwl} for BlackFin processors using zero overhead loops.
* *
* Modified: * Modified:
* Copyright 2004-2006 Analog Devices Inc. * Copyright 2004-2008 Analog Devices Inc.
* Copyright (C) 2005 Bas Vermeulen, BuyWays BV <bas@buyways.nl> * Copyright (C) 2005 Bas Vermeulen, BuyWays BV <bas@buyways.nl>
* *
* Bugs: Enter bugs at http://blackfin.uclinux.org/ * Bugs: Enter bugs at http://blackfin.uclinux.org/
...@@ -63,6 +63,23 @@ ENTRY(_insw) ...@@ -63,6 +63,23 @@ ENTRY(_insw)
RTS; RTS;
ENDPROC(_insw) ENDPROC(_insw)
ENTRY(_insw_8)
P0 = R0; /* P0 = port */
cli R3;
P1 = R1; /* P1 = address */
P2 = R2; /* P2 = count */
SSYNC;
LSETUP( .Lword8_loop_s, .Lword8_loop_e) LC0 = P2;
.Lword8_loop_s: R0 = W[P0];
B[P1++] = R0;
R0 = R0 >> 8;
B[P1++] = R0;
NOP;
.Lword8_loop_e: NOP;
sti R3;
RTS;
ENDPROC(_insw_8)
ENTRY(_insb) ENTRY(_insb)
P0 = R0; /* P0 = port */ P0 = R0; /* P0 = port */
cli R3; cli R3;
...@@ -78,8 +95,6 @@ ENTRY(_insb) ...@@ -78,8 +95,6 @@ ENTRY(_insb)
RTS; RTS;
ENDPROC(_insb) ENDPROC(_insb)
ENTRY(_insl_16) ENTRY(_insl_16)
P0 = R0; /* P0 = port */ P0 = R0; /* P0 = port */
cli R3; cli R3;
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
* Description: Implementation of outs{bwl} for BlackFin processors using zero overhead loops. * Description: Implementation of outs{bwl} for BlackFin processors using zero overhead loops.
* *
* Modified: Copyright (C) 2005 Bas Vermeulen, BuyWays BV <bas@buyways.nl> * Modified: Copyright (C) 2005 Bas Vermeulen, BuyWays BV <bas@buyways.nl>
* Copyright 2004-2006 Analog Devices Inc. * Copyright 2004-2008 Analog Devices Inc.
* *
* Bugs: Enter bugs at http://blackfin.uclinux.org/ * Bugs: Enter bugs at http://blackfin.uclinux.org/
* *
...@@ -63,3 +63,17 @@ ENTRY(_outsb) ...@@ -63,3 +63,17 @@ ENTRY(_outsb)
.Lbyte_loop_e: B[P0] = R0; .Lbyte_loop_e: B[P0] = R0;
RTS; RTS;
ENDPROC(_outsb) ENDPROC(_outsb)
ENTRY(_outsw_8)
P0 = R0; /* P0 = port */
P1 = R1; /* P1 = address */
P2 = R2; /* P2 = count */
LSETUP( .Lword8_loop_s, .Lword8_loop_e) LC0 = P2;
.Lword8_loop_s: R1 = B[P1++];
R0 = B[P1++];
R0 = R0 << 8;
R0 = R0 + R1;
.Lword8_loop_e: W[P0] = R0;
RTS;
ENDPROC(_outsw)
...@@ -111,7 +111,7 @@ static struct platform_device net2272_bfin_device = { ...@@ -111,7 +111,7 @@ static struct platform_device net2272_bfin_device = {
}; };
#endif #endif
#if defined(CONFIG_MTD_BF5xx) || defined(CONFIG_MTD_BF5xx_MODULE) #if defined(CONFIG_MTD_BFIN_ASYNC) || defined(CONFIG_MTD_BFIN_ASYNC_MODULE)
static struct mtd_partition stamp_partitions[] = { static struct mtd_partition stamp_partitions[] = {
{ {
.name = "Bootloader", .name = "Bootloader",
...@@ -141,13 +141,17 @@ static struct resource stamp_flash_resource[] = { ...@@ -141,13 +141,17 @@ static struct resource stamp_flash_resource[] = {
.end = 0x203fffff, .end = 0x203fffff,
.flags = IORESOURCE_MEM, .flags = IORESOURCE_MEM,
}, { }, {
.start = CONFIG_ENET_FLASH_PIN, .start = 0x7BB07BB0, /* AMBCTL0 setting when accessing flash */
.end = 0x7BB07BB0, /* AMBCTL1 setting when accessing flash */
.flags = IORESOURCE_MEM,
}, {
.start = GPIO_PF0,
.flags = IORESOURCE_IRQ, .flags = IORESOURCE_IRQ,
} }
}; };
static struct platform_device stamp_flash_device = { static struct platform_device stamp_flash_device = {
.name = "BF5xx-Flash", .name = "bfin-async-flash",
.id = 0, .id = 0,
.dev = { .dev = {
.platform_data = &stamp_flash_data, .platform_data = &stamp_flash_data,
...@@ -595,7 +599,7 @@ static struct platform_device *stamp_devices[] __initdata = { ...@@ -595,7 +599,7 @@ static struct platform_device *stamp_devices[] __initdata = {
&bfin_gpios_device, &bfin_gpios_device,
#if defined(CONFIG_MTD_BF5xx) || defined(CONFIG_MTD_BF5xx_MODULE) #if defined(CONFIG_MTD_BFIN_ASYNC) || defined(CONFIG_MTD_BFIN_ASYNC_MODULE)
&stamp_flash_device, &stamp_flash_device,
#endif #endif
}; };
...@@ -617,8 +621,8 @@ static int __init stamp_init(void) ...@@ -617,8 +621,8 @@ static int __init stamp_init(void)
#if defined(CONFIG_SMC91X) || defined(CONFIG_SMC91X_MODULE) #if defined(CONFIG_SMC91X) || defined(CONFIG_SMC91X_MODULE)
/* setup BF533_STAMP CPLD to route AMS3 to Ethernet MAC */ /* setup BF533_STAMP CPLD to route AMS3 to Ethernet MAC */
bfin_write_FIO_DIR(bfin_read_FIO_DIR() | (1 << CONFIG_ENET_FLASH_PIN)); bfin_write_FIO_DIR(bfin_read_FIO_DIR() | PF0);
bfin_write_FIO_FLAG_S(1 << CONFIG_ENET_FLASH_PIN); bfin_write_FIO_FLAG_S(PF0);
SSYNC(); SSYNC();
#endif #endif
...@@ -636,8 +640,8 @@ arch_initcall(stamp_init); ...@@ -636,8 +640,8 @@ arch_initcall(stamp_init);
void native_machine_restart(char *cmd) void native_machine_restart(char *cmd)
{ {
#define BIT_TO_SET (1 << CONFIG_ENET_FLASH_PIN) /* workaround pull up on cpld / flash pin not being strong enough */
bfin_write_FIO_INEN(~BIT_TO_SET); bfin_write_FIO_INEN(~PF0);
bfin_write_FIO_DIR(BIT_TO_SET); bfin_write_FIO_DIR(PF0);
bfin_write_FIO_FLAG_C(BIT_TO_SET); bfin_write_FIO_FLAG_C(PF0);
} }
...@@ -43,6 +43,7 @@ ...@@ -43,6 +43,7 @@
#include <asm/io.h> #include <asm/io.h>
#include <asm/irq.h> #include <asm/irq.h>
#include <asm/serial.h>
#include "8250.h" #include "8250.h"
...@@ -92,8 +93,6 @@ static unsigned int nr_uarts = CONFIG_SERIAL_8250_RUNTIME_UARTS; ...@@ -92,8 +93,6 @@ static unsigned int nr_uarts = CONFIG_SERIAL_8250_RUNTIME_UARTS;
*/ */
#define CONFIG_HUB6 1 #define CONFIG_HUB6 1
#include <asm/serial.h>
/* /*
* SERIAL_PORT_DFNS tells us about built-in ports that have no * SERIAL_PORT_DFNS tells us about built-in ports that have no
* standard enumeration mechanism. Platforms that can find all * standard enumeration mechanism. Platforms that can find all
...@@ -1548,6 +1547,8 @@ static int serial_link_irq_chain(struct uart_8250_port *up) ...@@ -1548,6 +1547,8 @@ static int serial_link_irq_chain(struct uart_8250_port *up)
i->head = &up->list; i->head = &up->list;
spin_unlock_irq(&i->lock); spin_unlock_irq(&i->lock);
irq_flags |= SERIAL_EXTRA_IRQ_FLAGS;
ret = request_irq(up->port.irq, serial8250_interrupt, ret = request_irq(up->port.irq, serial8250_interrupt,
irq_flags, "serial", i); irq_flags, "serial", i);
if (ret < 0) if (ret < 0)
......
...@@ -78,3 +78,8 @@ struct serial8250_config { ...@@ -78,3 +78,8 @@ struct serial8250_config {
#else #else
#define ALPHA_KLUDGE_MCR 0 #define ALPHA_KLUDGE_MCR 0
#endif #endif
#ifndef SERIAL_EXTRA_IRQ_FLAGS
#define SERIAL_EXTRA_IRQ_FLAGS 0
#endif
...@@ -1361,7 +1361,7 @@ config SERIAL_SC26XX_CONSOLE ...@@ -1361,7 +1361,7 @@ config SERIAL_SC26XX_CONSOLE
config SERIAL_BFIN_SPORT config SERIAL_BFIN_SPORT
tristate "Blackfin SPORT emulate UART (EXPERIMENTAL)" tristate "Blackfin SPORT emulate UART (EXPERIMENTAL)"
depends on BFIN && EXPERIMENTAL depends on BLACKFIN && EXPERIMENTAL
select SERIAL_CORE select SERIAL_CORE
help help
Enble support SPORT emulate UART on Blackfin series. Enble support SPORT emulate UART on Blackfin series.
......
...@@ -37,7 +37,9 @@ ...@@ -37,7 +37,9 @@
#include <linux/linkage.h> #include <linux/linkage.h>
#include <linux/types.h> #include <linux/types.h>
#if defined(CONFIG_DMA_UNCACHED_2M) #if defined(CONFIG_DMA_UNCACHED_4M)
# define DMA_UNCACHED_REGION (4 * 1024 * 1024)
#elif defined(CONFIG_DMA_UNCACHED_2M)
# define DMA_UNCACHED_REGION (2 * 1024 * 1024) # define DMA_UNCACHED_REGION (2 * 1024 * 1024)
#elif defined(CONFIG_DMA_UNCACHED_1M) #elif defined(CONFIG_DMA_UNCACHED_1M)
# define DMA_UNCACHED_REGION (1024 * 1024) # define DMA_UNCACHED_REGION (1024 * 1024)
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
* *
* it's best to have buff aligned on a 32-bit boundary * it's best to have buff aligned on a 32-bit boundary
*/ */
unsigned int csum_partial(const unsigned char *buff, int len, unsigned int sum); __wsum csum_partial(const void *buff, int len, __wsum sum);
/* /*
* the same as csum_partial, but copies from src while it * the same as csum_partial, but copies from src while it
...@@ -25,8 +25,8 @@ unsigned int csum_partial(const unsigned char *buff, int len, unsigned int sum); ...@@ -25,8 +25,8 @@ unsigned int csum_partial(const unsigned char *buff, int len, unsigned int sum);
* better 64-bit) boundary * better 64-bit) boundary
*/ */
unsigned int csum_partial_copy(const unsigned char *src, unsigned char *dst, __wsum csum_partial_copy(const void *src, void *dst,
int len, int sum); int len, __wsum sum);
/* /*
* the same as csum_partial_copy, but copies from user space. * the same as csum_partial_copy, but copies from user space.
...@@ -35,20 +35,19 @@ unsigned int csum_partial_copy(const unsigned char *src, unsigned char *dst, ...@@ -35,20 +35,19 @@ unsigned int csum_partial_copy(const unsigned char *src, unsigned char *dst,
* better 64-bit) boundary * better 64-bit) boundary
*/ */
extern unsigned int csum_partial_copy_from_user(const unsigned char *src, extern __wsum csum_partial_copy_from_user(const void __user *src, void *dst,
unsigned char *dst, int len, int len, __wsum sum, int *csum_err);
int sum, int *csum_err);
#define csum_partial_copy_nocheck(src, dst, len, sum) \ #define csum_partial_copy_nocheck(src, dst, len, sum) \
csum_partial_copy((src), (dst), (len), (sum)) csum_partial_copy((src), (dst), (len), (sum))
unsigned short ip_fast_csum(unsigned char *iph, unsigned int ihl); __sum16 ip_fast_csum(unsigned char *iph, unsigned int ihl);
/* /*
* Fold a partial checksum * Fold a partial checksum
*/ */
static inline unsigned int csum_fold(unsigned int sum) static inline __sum16 csum_fold(__wsum sum)
{ {
while (sum >> 16) while (sum >> 16)
sum = (sum & 0xffff) + (sum >> 16); sum = (sum & 0xffff) + (sum >> 16);
...@@ -60,9 +59,9 @@ static inline unsigned int csum_fold(unsigned int sum) ...@@ -60,9 +59,9 @@ static inline unsigned int csum_fold(unsigned int sum)
* returns a 16-bit checksum, already complemented * returns a 16-bit checksum, already complemented
*/ */
static inline unsigned int static inline __wsum
csum_tcpudp_nofold(unsigned long saddr, unsigned long daddr, unsigned short len, csum_tcpudp_nofold(__be32 saddr, __be32 daddr, unsigned short len,
unsigned short proto, unsigned int sum) unsigned short proto, __wsum sum)
{ {
__asm__ ("%0 = %0 + %1;\n\t" __asm__ ("%0 = %0 + %1;\n\t"
...@@ -84,9 +83,9 @@ csum_tcpudp_nofold(unsigned long saddr, unsigned long daddr, unsigned short len, ...@@ -84,9 +83,9 @@ csum_tcpudp_nofold(unsigned long saddr, unsigned long daddr, unsigned short len,
return (sum); return (sum);
} }
static inline unsigned short int static inline __sum16
csum_tcpudp_magic(unsigned long saddr, unsigned long daddr, unsigned short len, csum_tcpudp_magic(__be32 saddr, __be32 daddr, unsigned short len,
unsigned short proto, unsigned int sum) unsigned short proto, __wsum sum)
{ {
return csum_fold(csum_tcpudp_nofold(saddr, daddr, len, proto, sum)); return csum_fold(csum_tcpudp_nofold(saddr, daddr, len, proto, sum));
} }
...@@ -96,6 +95,6 @@ csum_tcpudp_magic(unsigned long saddr, unsigned long daddr, unsigned short len, ...@@ -96,6 +95,6 @@ csum_tcpudp_magic(unsigned long saddr, unsigned long daddr, unsigned short len,
* in icmp.c * in icmp.c
*/ */
extern unsigned short ip_compute_csum(const unsigned char *buff, int len); extern __sum16 ip_compute_csum(const void *buff, int len);
#endif /* _BFIN_CHECKSUM_H */ #endif /* _BFIN_CHECKSUM_H */
...@@ -437,7 +437,6 @@ void gpio_set_value(unsigned gpio, int arg); ...@@ -437,7 +437,6 @@ void gpio_set_value(unsigned gpio, int arg);
int gpio_get_value(unsigned gpio); int gpio_get_value(unsigned gpio);
#ifndef BF548_FAMILY #ifndef BF548_FAMILY
#define gpio_get_value(gpio) get_gpio_data(gpio)
#define gpio_set_value(gpio, value) set_gpio_data(gpio, value) #define gpio_set_value(gpio, value) set_gpio_data(gpio, value)
#endif #endif
......
...@@ -117,10 +117,12 @@ static inline unsigned int readl(const volatile void __iomem *addr) ...@@ -117,10 +117,12 @@ static inline unsigned int readl(const volatile void __iomem *addr)
extern void outsb(unsigned long port, const void *addr, unsigned long count); extern void outsb(unsigned long port, const void *addr, unsigned long count);
extern void outsw(unsigned long port, const void *addr, unsigned long count); extern void outsw(unsigned long port, const void *addr, unsigned long count);
extern void outsw_8(unsigned long port, const void *addr, unsigned long count);
extern void outsl(unsigned long port, const void *addr, unsigned long count); extern void outsl(unsigned long port, const void *addr, unsigned long count);
extern void insb(unsigned long port, void *addr, unsigned long count); extern void insb(unsigned long port, void *addr, unsigned long count);
extern void insw(unsigned long port, void *addr, unsigned long count); extern void insw(unsigned long port, void *addr, unsigned long count);
extern void insw_8(unsigned long port, void *addr, unsigned long count);
extern void insl(unsigned long port, void *addr, unsigned long count); extern void insl(unsigned long port, void *addr, unsigned long count);
extern void insl_16(unsigned long port, void *addr, unsigned long count); extern void insl_16(unsigned long port, void *addr, unsigned long count);
......
...@@ -39,22 +39,22 @@ ...@@ -39,22 +39,22 @@
#include "defBF522.h" #include "defBF522.h"
#include "anomaly.h" #include "anomaly.h"
#if defined(CONFIG_BF527) #if defined(CONFIG_BF527) || defined(CONFIG_BF526)
#include "defBF527.h" #include "defBF527.h"
#endif #endif
#if defined(CONFIG_BF525) #if defined(CONFIG_BF525) || defined(CONFIG_BF524)
#include "defBF525.h" #include "defBF525.h"
#endif #endif
#if !defined(__ASSEMBLY__) #if !defined(__ASSEMBLY__)
#include "cdefBF522.h" #include "cdefBF522.h"
#if defined(CONFIG_BF527) #if defined(CONFIG_BF527) || defined(CONFIG_BF526)
#include "cdefBF527.h" #include "cdefBF527.h"
#endif #endif
#if defined(CONFIG_BF525) #if defined(CONFIG_BF525) || defined(CONFIG_BF524)
#include "cdefBF525.h" #include "cdefBF525.h"
#endif #endif
#endif #endif
......
...@@ -25,11 +25,11 @@ ...@@ -25,11 +25,11 @@
#define CH_MEM_STREAM1_SRC 27 /* RX */ #define CH_MEM_STREAM1_SRC 27 /* RX */
#define CH_MEM_STREAM2_DEST 28 #define CH_MEM_STREAM2_DEST 28
#define CH_MEM_STREAM2_SRC 29 #define CH_MEM_STREAM2_SRC 29
#define CH_MEM_STREAM3_SRC 30 #define CH_MEM_STREAM3_DEST 30
#define CH_MEM_STREAM3_DEST 31 #define CH_MEM_STREAM3_SRC 31
#define CH_IMEM_STREAM0_DEST 32 #define CH_IMEM_STREAM0_DEST 32
#define CH_IMEM_STREAM0_SRC 33 #define CH_IMEM_STREAM0_SRC 33
#define CH_IMEM_STREAM1_SRC 34 #define CH_IMEM_STREAM1_DEST 34
#define CH_IMEM_STREAM1_DEST 35 #define CH_IMEM_STREAM1_SRC 35
#endif #endif
/*
* include/asm-blackfin/serial.h
*/
#define SERIAL_EXTRA_IRQ_FLAGS IRQF_TRIGGER_HIGH
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment