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
Kirill Smelkov
linux
Commits
5d407f44
Commit
5d407f44
authored
Aug 09, 2004
by
Lennert Buytenhek
Committed by
Deepak Saxena
Aug 09, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[ARM] Add support for ENP-2611 platform
Signed-off-by:
Deepak Saxena
<
dsaxena@plexity.net
>
parent
3c9c65e8
Changes
7
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
1043 additions
and
1 deletion
+1043
-1
arch/arm/configs/enp2611_defconfig
arch/arm/configs/enp2611_defconfig
+795
-0
arch/arm/mach-ixp2000/Kconfig
arch/arm/mach-ixp2000/Kconfig
+7
-0
arch/arm/mach-ixp2000/Makefile
arch/arm/mach-ixp2000/Makefile
+1
-0
arch/arm/mach-ixp2000/enp2611.c
arch/arm/mach-ixp2000/enp2611.c
+210
-0
include/asm-arm/arch-ixp2000/enp2611.h
include/asm-arm/arch-ixp2000/enp2611.h
+28
-0
include/asm-arm/arch-ixp2000/hardware.h
include/asm-arm/arch-ixp2000/hardware.h
+1
-0
include/asm-arm/arch-ixp2000/platform.h
include/asm-arm/arch-ixp2000/platform.h
+1
-1
No files found.
arch/arm/configs/enp2611_defconfig
0 → 100644
View file @
5d407f44
This diff is collapsed.
Click to expand it.
arch/arm/mach-ixp2000/Kconfig
View file @
5d407f44
...
...
@@ -9,6 +9,13 @@ menu "Intel IXP2400/2800 Implementation Options"
comment "IXP2400/2800 Platforms"
config ARCH_ENP2611
bool "Support Radisys ENP-2611"
help
Say 'Y' here if you want your kernel to support the Radisys
ENP2611 PCI network processing card. For more information on
this card, see Documentation/arm/ENP2611.
config ARCH_IXDP2400
bool "Support Intel IXDP2400"
help
...
...
arch/arm/mach-ixp2000/Makefile
View file @
5d407f44
...
...
@@ -6,6 +6,7 @@ obj-m :=
obj-n
:=
obj-
:=
obj-$(CONFIG_ARCH_ENP2611)
+=
enp2611.o
obj-$(CONFIG_ARCH_IXDP2400)
+=
ixdp2400.o
obj-$(CONFIG_ARCH_IXDP2800)
+=
ixdp2800.o
obj-$(CONFIG_ARCH_IXDP2X00)
+=
ixdp2x00.o
...
...
arch/arm/mach-ixp2000/enp2611.c
0 → 100644
View file @
5d407f44
/*
* arch/arm/mach-ixp2000/enp2611.c
*
* Radisys ENP-2611 support.
*
* Created 2004 by Lennert Buytenhek from the ixdp2x01 code. The
* original version carries the following notices:
*
* Original Author: Andrzej Mialwoski <andrzej.mialwoski@intel.com>
* Maintainer: Deepak Saxena <dsaxena@plexity.net>
*
* Copyright (C) 2002-2003 Intel Corp.
* Copyright (C) 2003-2004 MontaVista Software, Inc.
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the
* Free Software Foundation; either version 2 of the License, or (at your
* option) any later version.
*/
#include <linux/config.h>
#include <linux/kernel.h>
#include <linux/init.h>
#include <linux/mm.h>
#include <linux/sched.h>
#include <linux/interrupt.h>
#include <linux/bitops.h>
#include <linux/pci.h>
#include <linux/interrupt.h>
#include <linux/mm.h>
#include <linux/init.h>
#include <linux/ioport.h>
#include <linux/slab.h>
#include <linux/delay.h>
#include <linux/serial.h>
#include <linux/tty.h>
#include <linux/serial_core.h>
#include <linux/device.h>
#include <asm/io.h>
#include <asm/irq.h>
#include <asm/pgtable.h>
#include <asm/page.h>
#include <asm/system.h>
#include <asm/hardware.h>
#include <asm/mach-types.h>
#include <asm/mach/pci.h>
#include <asm/mach/map.h>
#include <asm/mach/irq.h>
#include <asm/mach/time.h>
#include <asm/mach/arch.h>
#include <asm/mach/flash.h>
/*************************************************************************
* ENP-2611 timer tick configuration
*************************************************************************/
static
void
__init
enp2611_init_time
(
void
)
{
ixp2000_init_time
(
50
*
1000
*
1000
);
}
/*************************************************************************
* ENP-2611 PCI
*************************************************************************/
static
int
enp2611_pci_setup
(
int
nr
,
struct
pci_sys_data
*
sys
)
{
sys
->
mem_offset
=
0xe0000000
;
ixp2000_pci_setup
(
nr
,
sys
);
return
1
;
}
static
void
__init
enp2611_pci_preinit
(
void
)
{
ixp2000_reg_write
(
IXP2000_PCI_ADDR_EXT
,
0x00100000
);
ixp2000_pci_preinit
();
}
static
inline
int
enp2611_pci_valid_device
(
struct
pci_bus
*
bus
,
unsigned
int
devfn
)
{
/* The 82559 ethernet controller appears at both PCI:1:0:0 and
* PCI:1:2:0, so let's pretend the second one isn't there.
*/
if
(
bus
->
number
==
0x01
&&
devfn
==
0x10
)
return
0
;
return
1
;
}
static
int
enp2611_pci_read_config
(
struct
pci_bus
*
bus
,
unsigned
int
devfn
,
int
where
,
int
size
,
u32
*
value
)
{
if
(
enp2611_pci_valid_device
(
bus
,
devfn
))
return
ixp2000_pci_read_config
(
bus
,
devfn
,
where
,
size
,
value
);
return
PCIBIOS_DEVICE_NOT_FOUND
;
}
static
int
enp2611_pci_write_config
(
struct
pci_bus
*
bus
,
unsigned
int
devfn
,
int
where
,
int
size
,
u32
value
)
{
if
(
enp2611_pci_valid_device
(
bus
,
devfn
))
return
ixp2000_pci_write_config
(
bus
,
devfn
,
where
,
size
,
value
);
return
PCIBIOS_DEVICE_NOT_FOUND
;
}
static
struct
pci_ops
enp2611_pci_ops
=
{
.
read
=
enp2611_pci_read_config
,
.
write
=
enp2611_pci_write_config
};
static
struct
pci_bus
*
__init
enp2611_pci_scan_bus
(
int
nr
,
struct
pci_sys_data
*
sys
)
{
return
pci_scan_bus
(
sys
->
busnr
,
&
enp2611_pci_ops
,
sys
);
}
static
int
__init
enp2611_pci_map_irq
(
struct
pci_dev
*
dev
,
u8
slot
,
u8
pin
)
{
int
irq
;
if
(
dev
->
bus
->
number
==
0x00
&&
PCI_SLOT
(
dev
->
devfn
)
==
0x01
)
{
/* 21555 non-transparent bridge. */
irq
=
IRQ_IXP2000_PCIB
;
}
else
if
(
dev
->
bus
->
number
==
0x01
&&
PCI_SLOT
(
dev
->
devfn
)
==
0x00
)
{
/* 82559 ethernet. */
irq
=
IRQ_IXP2000_PCIA
;
}
else
{
printk
(
KERN_INFO
"enp2611_pci_map_irq for unknown device
\n
"
);
irq
=
IRQ_IXP2000_PCI
;
}
printk
(
KERN_INFO
"Assigned IRQ %d to PCI:%d:%d:%d
\n
"
,
irq
,
dev
->
bus
->
number
,
PCI_SLOT
(
dev
->
devfn
),
PCI_FUNC
(
dev
->
devfn
));
return
irq
;
}
struct
hw_pci
enp2611_pci
__initdata
=
{
.
nr_controllers
=
1
,
.
setup
=
enp2611_pci_setup
,
.
preinit
=
enp2611_pci_preinit
,
.
scan
=
enp2611_pci_scan_bus
,
.
map_irq
=
enp2611_pci_map_irq
,
};
int
__init
enp2611_pci_init
(
void
)
{
pci_common_init
(
&
enp2611_pci
);
return
0
;
}
subsys_initcall
(
enp2611_pci_init
);
/*************************************************************************
* ENP-2611 Machine Intialization
*************************************************************************/
static
struct
flash_platform_data
enp2611_flash_platform_data
=
{
.
map_name
=
"cfi_probe"
,
.
width
=
1
,
};
static
struct
ixp2000_flash_data
enp2611_flash_data
=
{
.
platform_data
=
&
enp2611_flash_platform_data
,
.
nr_banks
=
1
};
static
struct
resource
enp2611_flash_resource
=
{
.
start
=
0xc4000000
,
.
end
=
0xc4000000
+
0x00ffffff
,
.
flags
=
IORESOURCE_MEM
,
};
static
struct
platform_device
enp2611_flash
=
{
.
name
=
"IXP2000-Flash"
,
.
id
=
0
,
.
dev
=
{
.
platform_data
=
&
enp2611_flash_data
,
},
.
num_resources
=
1
,
.
resource
=
&
enp2611_flash_resource
,
};
static
struct
platform_device
*
enp2611_devices
[]
__initdata
=
{
&
enp2611_flash
};
static
void
__init
enp2611_init_machine
(
void
)
{
platform_add_devices
(
enp2611_devices
,
ARRAY_SIZE
(
enp2611_devices
));
}
#ifdef CONFIG_ARCH_ENP2611
MACHINE_START
(
ENP2611
,
"Radisys ENP-2611 PCI network processor board"
)
MAINTAINER
(
"Lennert Buytenhek <buytenh@wantstofly.org>"
)
BOOT_MEM
(
0x00000000
,
IXP2000_UART_PHYS_BASE
,
IXP2000_UART_VIRT_BASE
)
BOOT_PARAMS
(
0x00000100
)
MAPIO
(
ixp2000_map_io
)
INITIRQ
(
ixp2000_init_irq
)
INITTIME
(
enp2611_init_time
)
INIT_MACHINE
(
enp2611_init_machine
)
MACHINE_END
#endif
include/asm-arm/arch-ixp2000/enp2611.h
0 → 100644
View file @
5d407f44
/*
* include/asm-arm/arch-ixp2000/enp2611.h
*
* Register and other defines for Radisys ENP-2611
*
* Created 2004 by Lennert Buytenhek from the ixdp2x01 code. The
* original version carries the following notices:
*
* Original Author: Naeem Afzal <naeem.m.afzal@intel.com>
* Maintainer: Deepak Saxena <dsaxena@plexity.net>
*
* Copyright (C) 2002 Intel Corp.
* Copyright (C) 2003-2004 MontaVista Software, Inc.
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the
* Free Software Foundation; either version 2 of the License, or (at your
* option) any later version.
*/
#ifndef __ENP2611_H
#define __ENP2611_H
#define ENP2611_GPIO_SCL 0x07
#define ENP2611_GPIO_SDA 0x06
#endif
include/asm-arm/arch-ixp2000/hardware.h
View file @
5d407f44
...
...
@@ -37,6 +37,7 @@
/*
* Platform-specific bits
*/
#include "enp2611.h"
/* ENP-2611 */
#include "ixdp2x00.h"
/* IXDP2400/2800 */
#include "ixdp2x01.h"
/* IXDP2401/2801 */
...
...
include/asm-arm/arch-ixp2000/platform.h
View file @
5d407f44
...
...
@@ -27,7 +27,7 @@
* as XCB=101 and then force a read-back from the register.
*
*/
#if defined(CONFIG_ARCH_IXDP2400) || defined(CONFIG_ARCH_IXDP2401)
#if defined(CONFIG_ARCH_
ENP2611) || defined(CONFIG_ARCH_
IXDP2400) || defined(CONFIG_ARCH_IXDP2401)
#include <asm/system.h>
/* Pickup local_irq_ functions */
...
...
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