summaryrefslogtreecommitdiff
path: root/src/southbridge
diff options
context:
space:
mode:
Diffstat (limited to 'src/southbridge')
-rw-r--r--src/southbridge/nvidia/mcp55/mcp55_aza.c33
-rw-r--r--src/southbridge/nvidia/mcp55/mcp55_nic.c15
2 files changed, 24 insertions, 24 deletions
diff --git a/src/southbridge/nvidia/mcp55/mcp55_aza.c b/src/southbridge/nvidia/mcp55/mcp55_aza.c
index d4b0e8f2fb..ca002b7eb2 100644
--- a/src/southbridge/nvidia/mcp55/mcp55_aza.c
+++ b/src/southbridge/nvidia/mcp55/mcp55_aza.c
@@ -30,9 +30,9 @@
#include <delay.h>
#include "mcp55.h"
-static int set_bits(uint8_t *port, uint32_t mask, uint32_t val)
+static int set_bits(u32 port, u32 mask, u32 val)
{
- uint32_t dword;
+ u32 dword;
int count;
val &= mask;
@@ -55,9 +55,9 @@ static int set_bits(uint8_t *port, uint32_t mask, uint32_t val)
}
-static int codec_detect(uint8_t *base)
+static int codec_detect(u32 base)
{
- uint32_t dword;
+ u32 dword;
/* 1 */
set_bits(base + 0x08, 1, 1);
@@ -87,7 +87,8 @@ static int codec_detect(uint8_t *base)
}
-static uint32_t verb_data[] = {
+/* FIXME this should go to the mainboard code */
+static u32 verb_data[] = {
#if 0
0x00172001,
0x001721e6,
@@ -156,18 +157,18 @@ static uint32_t verb_data[] = {
0x01f71f01,
};
-static unsigned find_verb(uint32_t viddid, uint32_t **verb)
+static unsigned find_verb(u32 viddid, u32 **verb)
{
if(viddid != 0x10ec0880) return 0;
- *verb = (uint32_t *)verb_data;
- return sizeof(verb_data)/sizeof(uint32_t);
+ *verb = (u32 *)verb_data;
+ return sizeof(verb_data)/sizeof(u32);
}
-static void codec_init(uint8_t *base, int addr)
+static void codec_init(u32 base, int addr)
{
- uint32_t dword;
- uint32_t *verb;
+ u32 dword;
+ u32 *verb;
unsigned verb_size;
int i;
@@ -210,7 +211,7 @@ static void codec_init(uint8_t *base, int addr)
printk(BIOS_DEBUG, "verb loaded!\n");
}
-static void codecs_init(uint8_t *base, uint32_t codec_mask)
+static void codecs_init(u32 base, u32 codec_mask)
{
int i;
for(i=2; i>=0; i--) {
@@ -221,16 +222,16 @@ static void codecs_init(uint8_t *base, uint32_t codec_mask)
static void aza_init(struct device *dev)
{
- uint8_t *base;
+ u32 base;
struct resource *res;
- uint32_t codec_mask;
+ u32 codec_mask;
res = find_resource(dev, 0x10);
if(!res)
return;
- base =(uint8_t *) res->base;
- printk(BIOS_DEBUG, "base = %p\n", base);
+ base = res->base;
+ printk(BIOS_DEBUG, "base = 0x%08x\n", base);
codec_mask = codec_detect(base);
diff --git a/src/southbridge/nvidia/mcp55/mcp55_nic.c b/src/southbridge/nvidia/mcp55/mcp55_nic.c
index 92ea633a20..4a9b003384 100644
--- a/src/southbridge/nvidia/mcp55/mcp55_nic.c
+++ b/src/southbridge/nvidia/mcp55/mcp55_nic.c
@@ -31,9 +31,9 @@
#include <delay.h>
#include "mcp55.h"
-static int phy_read(uint8_t *base, unsigned phy_addr, unsigned phy_reg)
+static int phy_read(u32 base, unsigned phy_addr, unsigned phy_reg)
{
- uint32_t dword;
+ u32 dword;
unsigned loop = 0x100;
write32(base+0x190, 0x8000); //Clear MDIO lock bit
mdelay(1);
@@ -56,9 +56,9 @@ static int phy_read(uint8_t *base, unsigned phy_addr, unsigned phy_reg)
}
-static void phy_detect(uint8_t *base)
+static void phy_detect(u32 base)
{
- uint32_t dword;
+ u32 dword;
int i;
int val;
unsigned id;
@@ -95,14 +95,13 @@ static void phy_detect(uint8_t *base)
static void nic_init(struct device *dev)
{
- uint32_t dword, old;
- uint32_t mac_h, mac_l;
+ u32 mac_h, mac_l;
int eeprom_valid = 0;
struct southbridge_nvidia_mcp55_config *conf;
- static uint32_t nic_index = 0;
+ static u32 nic_index = 0;
- uint8_t *base;
+ u32 base;
struct resource *res;
res = find_resource(dev, 0x10);