Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OS
U-Boot.Mirror
提交
dcb2f95a
U
U-Boot.Mirror
项目概览
OS
/
U-Boot.Mirror
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
U
U-Boot.Mirror
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
dcb2f95a
编写于
5月 03, 2005
作者:
S
stroese
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
* Patch by Stefan Roese, 03 May 2005:
Update for P3G4 Fix problems in cmd_universe.c
上级
9f709b6c
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
77 addition
and
25 deletion
+77
-25
board/evb64260/pci.c
board/evb64260/pci.c
+10
-0
common/cmd_universe.c
common/cmd_universe.c
+19
-8
include/configs/P3G4.h
include/configs/P3G4.h
+48
-17
未找到文件。
board/evb64260/pci.c
浏览文件 @
dcb2f95a
...
@@ -629,6 +629,7 @@ static void gt_setup_ide (struct pci_controller *hose,
...
@@ -629,6 +629,7 @@ static void gt_setup_ide (struct pci_controller *hose,
}
}
}
}
#ifndef CONFIG_P3G4
static
void
gt_fixup_irq
(
struct
pci_controller
*
hose
,
pci_dev_t
dev
)
static
void
gt_fixup_irq
(
struct
pci_controller
*
hose
,
pci_dev_t
dev
)
{
{
unsigned
char
pin
,
irq
;
unsigned
char
pin
,
irq
;
...
@@ -642,6 +643,7 @@ static void gt_fixup_irq (struct pci_controller *hose, pci_dev_t dev)
...
@@ -642,6 +643,7 @@ static void gt_fixup_irq (struct pci_controller *hose, pci_dev_t dev)
pci_write_config_byte
(
dev
,
PCI_INTERRUPT_LINE
,
irq
);
pci_write_config_byte
(
dev
,
PCI_INTERRUPT_LINE
,
irq
);
}
}
}
}
#endif
struct
pci_config_table
gt_config_table
[]
=
{
struct
pci_config_table
gt_config_table
[]
=
{
{
PCI_ANY_ID
,
PCI_ANY_ID
,
PCI_CLASS_STORAGE_IDE
,
{
PCI_ANY_ID
,
PCI_ANY_ID
,
PCI_CLASS_STORAGE_IDE
,
...
@@ -651,12 +653,16 @@ struct pci_config_table gt_config_table[] = {
...
@@ -651,12 +653,16 @@ struct pci_config_table gt_config_table[] = {
};
};
struct
pci_controller
pci0_hose
=
{
struct
pci_controller
pci0_hose
=
{
#ifndef CONFIG_P3G4
fixup_irq:
gt_fixup_irq
,
fixup_irq:
gt_fixup_irq
,
#endif
config_table:
gt_config_table
,
config_table:
gt_config_table
,
};
};
struct
pci_controller
pci1_hose
=
{
struct
pci_controller
pci1_hose
=
{
#ifndef CONFIG_P3G4
fixup_irq:
gt_fixup_irq
,
fixup_irq:
gt_fixup_irq
,
#endif
config_table:
gt_config_table
,
config_table:
gt_config_table
,
};
};
...
@@ -692,8 +698,10 @@ void pci_init_board (void)
...
@@ -692,8 +698,10 @@ void pci_init_board (void)
pci_register_hose
(
&
pci0_hose
);
pci_register_hose
(
&
pci0_hose
);
#ifndef CONFIG_P3G4
pciArbiterEnable
(
PCI_HOST0
);
pciArbiterEnable
(
PCI_HOST0
);
pciParkingDisable
(
PCI_HOST0
,
1
,
1
,
1
,
1
,
1
,
1
,
1
);
pciParkingDisable
(
PCI_HOST0
,
1
,
1
,
1
,
1
,
1
,
1
,
1
);
#endif
command
=
pciReadConfigReg
(
PCI_HOST0
,
PCI_COMMAND
,
SELF
);
command
=
pciReadConfigReg
(
PCI_HOST0
,
PCI_COMMAND
,
SELF
);
command
|=
PCI_COMMAND_MASTER
;
command
|=
PCI_COMMAND_MASTER
;
...
@@ -735,8 +743,10 @@ void pci_init_board (void)
...
@@ -735,8 +743,10 @@ void pci_init_board (void)
pci_register_hose
(
&
pci1_hose
);
pci_register_hose
(
&
pci1_hose
);
#ifndef CONFIG_P3G4
pciArbiterEnable
(
PCI_HOST1
);
pciArbiterEnable
(
PCI_HOST1
);
pciParkingDisable
(
PCI_HOST1
,
1
,
1
,
1
,
1
,
1
,
1
,
1
);
pciParkingDisable
(
PCI_HOST1
,
1
,
1
,
1
,
1
,
1
,
1
,
1
);
#endif
command
=
pciReadConfigReg
(
PCI_HOST1
,
PCI_COMMAND
,
SELF
);
command
=
pciReadConfigReg
(
PCI_HOST1
,
PCI_COMMAND
,
SELF
);
command
|=
PCI_COMMAND_MASTER
;
command
|=
PCI_COMMAND_MASTER
;
...
...
common/cmd_universe.c
浏览文件 @
dcb2f95a
...
@@ -72,6 +72,9 @@ int universe_init(void)
...
@@ -72,6 +72,9 @@ int universe_init(void)
dev
->
busdevfn
=
busdevfn
;
dev
->
busdevfn
=
busdevfn
;
pci_read_config_dword
(
busdevfn
,
PCI_BASE_ADDRESS_1
,
&
val
);
pci_read_config_dword
(
busdevfn
,
PCI_BASE_ADDRESS_1
,
&
val
);
if
(
val
&
1
)
{
pci_read_config_dword
(
busdevfn
,
PCI_BASE_ADDRESS_0
,
&
val
);
}
val
&=
~
0xf
;
val
&=
~
0xf
;
dev
->
uregs
=
(
UNIVERSE
*
)
val
;
dev
->
uregs
=
(
UNIVERSE
*
)
val
;
...
@@ -102,7 +105,13 @@ int universe_init(void)
...
@@ -102,7 +105,13 @@ int universe_init(void)
* Arbitration Mode
* Arbitration Mode
* DTACK Enable
* DTACK Enable
*/
*/
writel
(
0x15060000
,
&
dev
->
uregs
->
misc_ctl
);
writel
(
0x15040000
|
(
readl
(
&
dev
->
uregs
->
misc_ctl
)
&
0x00020000
),
&
dev
->
uregs
->
misc_ctl
);
if
(
readl
(
&
dev
->
uregs
->
misc_ctl
)
&
0x00020000
)
{
debug
(
"System Controller!
\n
"
);
/* test-only */
}
else
{
debug
(
"Not System Controller!
\n
"
);
/* test-only */
}
/*
/*
* Lets turn off interrupts
* Lets turn off interrupts
...
@@ -114,12 +123,14 @@ int universe_init(void)
...
@@ -114,12 +123,14 @@ int universe_init(void)
writel
(
0x0000
,
&
dev
->
uregs
->
lint_map1
);
/* Map all ints to 0 */
writel
(
0x0000
,
&
dev
->
uregs
->
lint_map1
);
/* Map all ints to 0 */
eieio
();
eieio
();
return
0
;
break_30:
break_30:
free
(
dev
);
free
(
dev
);
break_20:
break_20:
lastError
=
result
;
lastError
=
result
;
return
0
;
return
result
;
}
}
...
@@ -193,13 +204,13 @@ int universe_pci_slave_window(unsigned int pciAddr, unsigned int vmeAddr, int si
...
@@ -193,13 +204,13 @@ int universe_pci_slave_window(unsigned int pciAddr, unsigned int vmeAddr, int si
switch
(
pms
&
PCI_MS_Mxx
)
{
switch
(
pms
&
PCI_MS_Mxx
)
{
case
PCI_MS_MEM
:
case
PCI_MS_MEM
:
ctl
=
0x00000000
;
ctl
|
=
0x00000000
;
break
;
break
;
case
PCI_MS_IO
:
case
PCI_MS_IO
:
ctl
=
0x00000001
;
ctl
|
=
0x00000001
;
break
;
break
;
case
PCI_MS_CONFIG
:
case
PCI_MS_CONFIG
:
ctl
=
0x00000002
;
ctl
|
=
0x00000002
;
break
;
break
;
}
}
...
@@ -278,13 +289,13 @@ int universe_vme_slave_window(unsigned int vmeAddr, unsigned int pciAddr, int si
...
@@ -278,13 +289,13 @@ int universe_vme_slave_window(unsigned int vmeAddr, unsigned int pciAddr, int si
switch
(
pms
&
PCI_MS_Mxx
)
{
switch
(
pms
&
PCI_MS_Mxx
)
{
case
PCI_MS_MEM
:
case
PCI_MS_MEM
:
ctl
=
0x00000000
;
ctl
|
=
0x00000000
;
break
;
break
;
case
PCI_MS_IO
:
case
PCI_MS_IO
:
ctl
=
0x00000001
;
ctl
|
=
0x00000001
;
break
;
break
;
case
PCI_MS_CONFIG
:
case
PCI_MS_CONFIG
:
ctl
=
0x00000002
;
ctl
|
=
0x00000002
;
break
;
break
;
}
}
...
...
include/configs/P3G4.h
浏览文件 @
dcb2f95a
...
@@ -28,8 +28,6 @@
...
@@ -28,8 +28,6 @@
#ifndef __CONFIG_H
#ifndef __CONFIG_H
#define __CONFIG_H
#define __CONFIG_H
#include <asm/processor.h>
#ifndef __ASSEMBLY__
#ifndef __ASSEMBLY__
#include <galileo/core.h>
#include <galileo/core.h>
#endif
#endif
...
@@ -66,7 +64,7 @@
...
@@ -66,7 +64,7 @@
* mpsc channel, change CONFIG_MPSC_PORT to the desired value.
* mpsc channel, change CONFIG_MPSC_PORT to the desired value.
*/
*/
#define CONFIG_MPSC
#define CONFIG_MPSC
#define CONFIG_MPSC_PORT
1
#define CONFIG_MPSC_PORT
0
#define CONFIG_NET_MULTI
/* attempt all available adapters */
#define CONFIG_NET_MULTI
/* attempt all available adapters */
...
@@ -75,20 +73,46 @@
...
@@ -75,20 +73,46 @@
#undef CONFIG_ETHER_PORT_MII
/* use RMII */
#undef CONFIG_ETHER_PORT_MII
/* use RMII */
#if
1
#if
0
#define CONFIG_BOOTDELAY -1 /* autoboot disabled */
#define CONFIG_BOOTDELAY -1 /* autoboot disabled */
#else
#else
#define CONFIG_BOOTDELAY 5
/* autoboot after 5 seconds */
#define CONFIG_BOOTDELAY 5
/* autoboot after 5 seconds */
#endif
#endif
#define CONFIG_ZERO_BOOTDELAY_CHECK
#define CONFIG_ZERO_BOOTDELAY_CHECK
#define CONFIG_PREBOOT "echo;" \
"echo Type \"run flash_nfs\" to mount root filesystem over NFS;" \
"echo"
#undef CONFIG_BOOTARGS
#undef CONFIG_BOOTARGS
#define CONFIG_BOOTCOMMAND \
"bootp;" \
#define CONFIG_EXTRA_ENV_SETTINGS \
"setenv bootargs root=/dev/nfs rw nfsroot=$serverip:$rootpath " \
"netdev=eth0\0" \
"ip=$ipaddr:$serverip:$gatewayip:" \
"hostname=p3g4\0" \
"$netmask:$hostname:eth0:none;" \
"nfsargs=setenv bootargs root=/dev/nfs rw " \
"bootm"
"nfsroot=$(serverip):$(rootpath)\0" \
"ramargs=setenv bootargs root=/dev/ram rw\0" \
"addip=setenv bootargs $(bootargs) " \
"ip=$(ipaddr):$(serverip):$(gatewayip):$(netmask)" \
":$(hostname):$(netdev):off panic=1\0" \
"addtty=setenv bootargs $(bootargs) console=ttyS0,$(baudrate)\0"\
"flash_nfs=run nfsargs addip addtty;" \
"bootm $(kernel_addr)\0" \
"flash_self=run ramargs addip addtty;" \
"bootm $(kernel_addr) $(ramdisk_addr)\0" \
"net_nfs=tftp 200000 $(bootfile);run nfsargs addip addtty;" \
"bootm\0" \
"rootpath=/opt/eldk/ppc_74xx\0" \
"bootfile=/tftpboot/p3g4/uImage\0" \
"kernel_addr=ff000000\0" \
"ramdisk_addr=ff010000\0" \
"load=tftp 100000 /tftpboot/p3g4/u-boot.bin\0" \
"update=protect off fff00000 fff3ffff;era fff00000 fff3ffff;" \
"cp.b 100000 fff00000 $(filesize);" \
"setenv filesize;saveenv\0" \
"upd=run load;run update\0" \
""
#define CONFIG_BOOTCOMMAND "run flash_self"
#define CONFIG_LOADS_ECHO 0
/* echo off for serial download */
#define CONFIG_LOADS_ECHO 0
/* echo off for serial download */
#define CFG_LOADS_BAUD_CHANGE
/* allow baudrate changes */
#define CFG_LOADS_BAUD_CHANGE
/* allow baudrate changes */
...
@@ -101,7 +125,15 @@
...
@@ -101,7 +125,15 @@
#define CONFIG_TIMESTAMP
/* Print image info with timestamp */
#define CONFIG_TIMESTAMP
/* Print image info with timestamp */
#define CONFIG_COMMANDS (CONFIG_CMD_DFL | CFG_CMD_ASKENV)
#define CONFIG_COMMANDS ( CONFIG_CMD_DFL | \
CFG_CMD_ASKENV | \
CFG_CMD_DHCP | \
CFG_CMD_PCI | \
CFG_CMD_ELF | \
CFG_CMD_MII | \
CFG_CMD_PING | \
CFG_CMD_UNIVERSE| \
CFG_CMD_BSP )
/* this must be included AFTER the definition of CONFIG_COMMANDS (if any) */
/* this must be included AFTER the definition of CONFIG_COMMANDS (if any) */
#include <cmd_confdefs.h>
#include <cmd_confdefs.h>
...
@@ -271,21 +303,20 @@
...
@@ -271,21 +303,20 @@
/* PCI MEMORY MAP section */
/* PCI MEMORY MAP section */
#define CFG_PCI0_MEM_BASE 0x80000000
#define CFG_PCI0_MEM_BASE 0x80000000
#define CFG_PCI0_MEM_SIZE _128M
#define CFG_PCI0_MEM_SIZE _128M
#define CFG_PCI0_0_MEM_SPACE (CFG_PCI0_MEM_BASE)
#define CFG_PCI1_MEM_BASE 0x88000000
#define CFG_PCI1_MEM_BASE 0x88000000
#define CFG_PCI1_MEM_SIZE _128M
#define CFG_PCI1_MEM_SIZE _128M
#define CFG_PCI0_0_MEM_SPACE (CFG_PCI0_MEM_BASE)
#define CFG_PCI1_0_MEM_SPACE (CFG_PCI1_MEM_BASE)
#define CFG_PCI1_0_MEM_SPACE (CFG_PCI1_MEM_BASE)
/* PCI I/O MAP section */
/* PCI I/O MAP section */
#define CFG_PCI0_IO_BASE 0xfa000000
#define CFG_PCI0_IO_BASE 0xfa000000
#define CFG_PCI0_IO_SIZE _16M
#define CFG_PCI0_IO_SIZE _16M
#define CFG_PCI1_IO_BASE 0xfb000000
#define CFG_PCI1_IO_SIZE _16M
#define CFG_PCI0_IO_SPACE (CFG_PCI0_IO_BASE)
#define CFG_PCI0_IO_SPACE (CFG_PCI0_IO_BASE)
#define CFG_PCI0_IO_SPACE_PCI 0x00000000
#define CFG_PCI0_IO_SPACE_PCI 0x00000000
#define CFG_PCI1_IO_BASE 0xfb000000
#define CFG_PCI1_IO_SIZE _16M
#define CFG_PCI1_IO_SPACE (CFG_PCI1_IO_BASE)
#define CFG_PCI1_IO_SPACE (CFG_PCI1_IO_BASE)
#define CFG_PCI1_IO_SPACE_PCI 0x00000000
#define CFG_PCI1_IO_SPACE_PCI 0x00000000
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录