Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
Kernel
提交
5536b235
K
Kernel
项目概览
openeuler
/
Kernel
大约 1 年 前同步成功
通知
5
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
K
Kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
5536b235
编写于
10月 09, 2006
作者:
R
Ralf Baechle
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[MIPS] Alchemy: nuke usbdev; it's useless as is ...
Signed-off-by:
N
Ralf Baechle
<
ralf@linux-mips.org
>
上级
0118c3ca
变更
11
展开全部
隐藏空白更改
内联
并排
Showing
11 changed file
with
9 addition
and
1662 deletion
+9
-1662
arch/mips/Kconfig
arch/mips/Kconfig
+0
-5
arch/mips/au1000/common/Makefile
arch/mips/au1000/common/Makefile
+0
-1
arch/mips/au1000/common/usbdev.c
arch/mips/au1000/common/usbdev.c
+0
-1552
arch/mips/au1000/db1x00/board_setup.c
arch/mips/au1000/db1x00/board_setup.c
+0
-5
arch/mips/au1000/mtx-1/board_setup.c
arch/mips/au1000/mtx-1/board_setup.c
+2
-6
arch/mips/au1000/pb1000/board_setup.c
arch/mips/au1000/pb1000/board_setup.c
+3
-7
arch/mips/au1000/pb1100/board_setup.c
arch/mips/au1000/pb1100/board_setup.c
+2
-4
arch/mips/au1000/pb1500/board_setup.c
arch/mips/au1000/pb1500/board_setup.c
+2
-7
arch/mips/configs/pb1100_defconfig
arch/mips/configs/pb1100_defconfig
+0
-1
arch/mips/configs/pb1500_defconfig
arch/mips/configs/pb1500_defconfig
+0
-1
include/asm-mips/mach-au1x00/au1000_usbdev.h
include/asm-mips/mach-au1x00/au1000_usbdev.h
+0
-73
未找到文件。
arch/mips/Kconfig
浏览文件 @
5536b235
...
...
@@ -1010,11 +1010,6 @@ endchoice
config ARC32
bool
config AU1X00_USB_DEVICE
bool
depends on MIPS_PB1500 || MIPS_PB1100 || MIPS_PB1000
default n
config BOOT_ELF32
bool
...
...
arch/mips/au1000/common/Makefile
浏览文件 @
5536b235
...
...
@@ -10,6 +10,5 @@ obj-y += prom.o irq.o puts.o time.o reset.o \
au1xxx_irqmap.o clocks.o platform.o power.o setup.o
\
sleeper.o cputable.o dma.o dbdma.o gpio.o
obj-$(CONFIG_AU1X00_USB_DEVICE)
+=
usbdev.o
obj-$(CONFIG_KGDB)
+=
dbg_io.o
obj-$(CONFIG_PCI)
+=
pci.o
arch/mips/au1000/common/usbdev.c
已删除
100644 → 0
浏览文件 @
0118c3ca
此差异已折叠。
点击以展开。
arch/mips/au1000/db1x00/board_setup.c
浏览文件 @
5536b235
...
...
@@ -58,11 +58,6 @@ void __init board_setup(void)
pin_func
=
0
;
/* not valid for 1550 */
#ifdef CONFIG_AU1X00_USB_DEVICE
// 2nd USB port is USB device
pin_func
=
au_readl
(
SYS_PINFUNC
)
&
(
u32
)(
~
0x8000
);
au_writel
(
pin_func
,
SYS_PINFUNC
);
#endif
#if defined(CONFIG_IRDA) && (defined(CONFIG_SOC_AU1000) || defined(CONFIG_SOC_AU1100))
/* set IRFIRSEL instead of GPIO15 */
...
...
arch/mips/au1000/mtx-1/board_setup.c
浏览文件 @
5536b235
...
...
@@ -51,15 +51,11 @@ void board_reset (void)
void
__init
board_setup
(
void
)
{
#if defined (CONFIG_USB_OHCI) || defined (CONFIG_AU1X00_USB_DEVICE)
#ifdef CONFIG_AU1X00_USB_DEVICE
// 2nd USB port is USB device
au_writel
(
au_readl
(
SYS_PINFUNC
)
&
(
u32
)(
~
0x8000
),
SYS_PINFUNC
);
#endif
#ifdef CONFIG_USB_OHCI
// enable USB power switch
au_writel
(
au_readl
(
GPIO2_DIR
)
|
0x10
,
GPIO2_DIR
);
au_writel
(
0x100000
,
GPIO2_OUTPUT
);
#endif // defined (CONFIG_USB_OHCI)
|| defined (CONFIG_AU1X00_USB_DEVICE)
#endif // defined (CONFIG_USB_OHCI)
#ifdef CONFIG_PCI
#if defined(__MIPSEB__)
...
...
arch/mips/au1000/pb1000/board_setup.c
浏览文件 @
5536b235
...
...
@@ -54,7 +54,7 @@ void __init board_setup(void)
au_writel
(
0
,
SYS_PINSTATERD
);
udelay
(
100
);
#if
defined (CONFIG_USB_OHCI) || defined (CONFIG_AU1X00_USB_DEVICE)
#if
def CONFIG_USB_OHCI
/* zero and disable FREQ2 */
sys_freqctrl
=
au_readl
(
SYS_FREQCTRL0
);
sys_freqctrl
&=
~
0xFFF00000
;
...
...
@@ -104,23 +104,19 @@ void __init board_setup(void)
*/
#ifdef CONFIG_USB_OHCI
sys_clksrc
|=
((
4
<<
12
)
|
(
0
<<
11
)
|
(
0
<<
10
));
#endif
#ifdef CONFIG_AU1X00_USB_DEVICE
sys_clksrc
|=
((
4
<<
7
)
|
(
0
<<
6
)
|
(
0
<<
5
));
#endif
au_writel
(
sys_clksrc
,
SYS_CLKSRC
);
// configure pins GPIO[14:9] as GPIO
pin_func
=
au_readl
(
SYS_PINFUNC
)
&
(
u32
)(
~
0x8080
);
#ifndef CONFIG_AU1X00_USB_DEVICE
// 2nd USB port is USB host
pin_func
|=
0x8000
;
#endif
au_writel
(
pin_func
,
SYS_PINFUNC
);
au_writel
(
0x2800
,
SYS_TRIOUTCLR
);
au_writel
(
0x0030
,
SYS_OUTPUTCLR
);
#endif // defined (CONFIG_USB_OHCI)
|| defined (CONFIG_AU1X00_USB_DEVICE)
#endif // defined (CONFIG_USB_OHCI)
// make gpio 15 an input (for interrupt line)
pin_func
=
au_readl
(
SYS_PINFUNC
)
&
(
u32
)(
~
0x100
);
...
...
arch/mips/au1000/pb1100/board_setup.c
浏览文件 @
5536b235
...
...
@@ -55,7 +55,7 @@ void __init board_setup(void)
au_writel
(
0
,
SYS_PININPUTEN
);
udelay
(
100
);
#if
defined (CONFIG_USB_OHCI) || defined (CONFIG_AU1X00_USB_DEVICE)
#if
def CONFIG_USB_OHCI
// configure pins GPIO[14:9] as GPIO
pin_func
=
au_readl
(
SYS_PINFUNC
)
&
(
u32
)(
~
0x80
);
...
...
@@ -92,12 +92,10 @@ void __init board_setup(void)
// get USB Functionality pin state (device vs host drive pins)
pin_func
=
au_readl
(
SYS_PINFUNC
)
&
(
u32
)(
~
0x8000
);
#ifndef CONFIG_AU1X00_USB_DEVICE
// 2nd USB port is USB host
pin_func
|=
0x8000
;
#endif
au_writel
(
pin_func
,
SYS_PINFUNC
);
#endif // defined (CONFIG_USB_OHCI)
|| defined (CONFIG_AU1X00_USB_DEVICE)
#endif // defined (CONFIG_USB_OHCI)
/* Enable sys bus clock divider when IDLE state or no bus activity. */
au_writel
(
au_readl
(
SYS_POWERCTRL
)
|
(
0x3
<<
5
),
SYS_POWERCTRL
);
...
...
arch/mips/au1000/pb1500/board_setup.c
浏览文件 @
5536b235
...
...
@@ -56,7 +56,7 @@ void __init board_setup(void)
au_writel
(
0
,
SYS_PINSTATERD
);
udelay
(
100
);
#if
defined (CONFIG_USB_OHCI) || defined (CONFIG_AU1X00_USB_DEVICE)
#if
def CONFIG_USB_OHCI
/* GPIO201 is input for PCMCIA card detect */
/* GPIO203 is input for PCMCIA interrupt request */
...
...
@@ -87,20 +87,15 @@ void __init board_setup(void)
*/
#ifdef CONFIG_USB_OHCI
sys_clksrc
|=
((
4
<<
12
)
|
(
0
<<
11
)
|
(
0
<<
10
));
#endif
#ifdef CONFIG_AU1X00_USB_DEVICE
sys_clksrc
|=
((
4
<<
7
)
|
(
0
<<
6
)
|
(
0
<<
5
));
#endif
au_writel
(
sys_clksrc
,
SYS_CLKSRC
);
pin_func
=
au_readl
(
SYS_PINFUNC
)
&
(
u32
)(
~
0x8000
);
#ifndef CONFIG_AU1X00_USB_DEVICE
// 2nd USB port is USB host
pin_func
|=
0x8000
;
#endif
au_writel
(
pin_func
,
SYS_PINFUNC
);
#endif // defined (CONFIG_USB_OHCI)
|| defined (CONFIG_AU1X00_USB_DEVICE)
#endif // defined (CONFIG_USB_OHCI)
...
...
arch/mips/configs/pb1100_defconfig
浏览文件 @
5536b235
...
...
@@ -76,7 +76,6 @@ CONFIG_SYS_SUPPORTS_LITTLE_ENDIAN=y
CONFIG_SOC_AU1100=y
CONFIG_SOC_AU1X00=y
CONFIG_SWAP_IO_SPACE=y
# CONFIG_AU1X00_USB_DEVICE is not set
CONFIG_MIPS_L1_CACHE_SHIFT=5
#
...
...
arch/mips/configs/pb1500_defconfig
浏览文件 @
5536b235
...
...
@@ -75,7 +75,6 @@ CONFIG_CPU_LITTLE_ENDIAN=y
CONFIG_SYS_SUPPORTS_LITTLE_ENDIAN=y
CONFIG_SOC_AU1500=y
CONFIG_SOC_AU1X00=y
# CONFIG_AU1X00_USB_DEVICE is not set
CONFIG_MIPS_L1_CACHE_SHIFT=5
#
...
...
include/asm-mips/mach-au1x00/au1000_usbdev.h
已删除
100644 → 0
浏览文件 @
0118c3ca
/*
* BRIEF MODULE DESCRIPTION
* Au1000 USB Device-Side Driver
*
* Copyright 2001 MontaVista Software Inc.
* Author: MontaVista Software, Inc.
* stevel@mvista.com or source@mvista.com
*
* 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.
*
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN
* NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
* NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
* USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* You should have received a copy of the GNU General Public License along
* with this program; if not, write to the Free Software Foundation, Inc.,
* 675 Mass Ave, Cambridge, MA 02139, USA.
*/
#define USBDEV_REV 0x0110 // BCD
#define USBDEV_EP0_MAX_PACKET_SIZE 64
typedef
enum
{
ATTACHED
=
0
,
POWERED
,
DEFAULT
,
ADDRESS
,
CONFIGURED
}
usbdev_state_t
;
typedef
enum
{
CB_NEW_STATE
=
0
,
CB_PKT_COMPLETE
}
usbdev_cb_type_t
;
typedef
struct
usbdev_pkt
{
int
ep_addr
;
// ep addr this packet routed to
int
size
;
// size of payload in bytes
unsigned
status
;
// packet status
struct
usbdev_pkt
*
next
;
// function layer can't touch this
u8
payload
[
0
];
// the payload
}
usbdev_pkt_t
;
#define PKT_STATUS_ACK (1<<0)
#define PKT_STATUS_NAK (1<<1)
#define PKT_STATUS_SU (1<<2)
extern
int
usbdev_init
(
struct
usb_device_descriptor
*
dev_desc
,
struct
usb_config_descriptor
*
config_desc
,
struct
usb_interface_descriptor
*
if_desc
,
struct
usb_endpoint_descriptor
*
ep_desc
,
struct
usb_string_descriptor
*
str_desc
[],
void
(
*
cb
)(
usbdev_cb_type_t
,
unsigned
long
,
void
*
),
void
*
cb_data
);
extern
void
usbdev_exit
(
void
);
extern
int
usbdev_alloc_packet
(
int
ep_addr
,
int
data_size
,
usbdev_pkt_t
**
pkt
);
extern
int
usbdev_send_packet
(
int
ep_addr
,
usbdev_pkt_t
*
pkt
);
extern
int
usbdev_receive_packet
(
int
ep_addr
,
usbdev_pkt_t
**
pkt
);
extern
int
usbdev_get_byte_count
(
int
ep_addr
);
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录