summaryrefslogtreecommitdiffstats
path: root/src/drivers/net
diff options
context:
space:
mode:
authorMarty Connor2006-09-26 23:33:12 +0200
committerMarty Connor2006-09-26 23:33:12 +0200
commitcf8460527171e4d026ba8747e4e702346c810369 (patch)
tree6683b40f370a584c4767d6cc84a0310d2041cbb5 /src/drivers/net
parenteth_ntoa fixes (diff)
downloadipxe-cf8460527171e4d026ba8747e4e702346c810369.tar.gz
ipxe-cf8460527171e4d026ba8747e4e702346c810369.tar.xz
ipxe-cf8460527171e4d026ba8747e4e702346c810369.zip
eth_ntoa and compilation warnings fixes
Diffstat (limited to 'src/drivers/net')
-rw-r--r--src/drivers/net/prism2.c11
-rw-r--r--src/drivers/net/prism2_pci.c5
-rw-r--r--src/drivers/net/prism2_plx.c7
3 files changed, 11 insertions, 12 deletions
diff --git a/src/drivers/net/prism2.c b/src/drivers/net/prism2.c
index 7ad390ff..52bc77b8 100644
--- a/src/drivers/net/prism2.c
+++ b/src/drivers/net/prism2.c
@@ -13,12 +13,10 @@ $Id$
* your option) any later version.
*/
-/* to get some global routines like printf */
#include "etherboot.h"
-/* to get the interface to the body of the program */
#include "nic.h"
-/* to get the PCI support functions, if this is a PCI NIC */
#include <gpxe/pci.h>
+#include <gpxe/ethernet.h>
/*
* Hard-coded SSID
@@ -770,9 +768,10 @@ static int prism2_probe ( struct nic *nic, hfa384x_t *hw ) {
hfa384x_setreg(hw, 0, HFA384x_INTEN); /* Disable interrupts */
hfa384x_setreg(hw, 0xffff, HFA384x_EVACK); /* Acknowledge any spurious events */
+ DBG ( "MAC address %s\n", eth_ntoa ( nic->node_addr ) );
+
/* Retrieve MAC address (and fill out nic->node_addr) */
hfa384x_drvr_getconfig ( hw, HFA384x_RID_CNFOWNMACADDR, nic->node_addr, HFA384x_RID_CNFOWNMACADDR_LEN );
- printf ( "MAC address %!\n", nic->node_addr );
/* Prepare card for autojoin */
/* This procedure is reverse-engineered from a register-level trace of the Linux driver's join process */
@@ -841,7 +840,9 @@ static int prism2_probe ( struct nic *nic, hfa384x_t *hw ) {
/* Retrieve BSSID and print Connected message */
result = hfa384x_drvr_getconfig(hw, HFA384x_RID_CURRENTBSSID, hw->bssid, WLAN_BSSID_LEN);
- printf ( "Link connected (BSSID %! - MAC address %!)\n", hw->bssid, nic->node_addr );
+
+ DBG ( "Link connected (BSSID %s - ", eth_ntoa ( hw->bssid ) );
+ DBG ( " MAC address %s)\n", eth_ntoa (nic->node_addr ) );
/* point to NIC specific routines */
nic->nic_op = &prism2_operations;
diff --git a/src/drivers/net/prism2_pci.c b/src/drivers/net/prism2_pci.c
index 90295cde..20350db5 100644
--- a/src/drivers/net/prism2_pci.c
+++ b/src/drivers/net/prism2_pci.c
@@ -28,14 +28,13 @@ static int prism2_pci_probe ( struct nic *nic, struct pci_device *pci ) {
pci_read_config_dword( pci, PRISM2_PCI_MEM_BASE, &membase);
membase &= PCI_BASE_ADDRESS_MEM_MASK;
hw->membase = (uint32_t) phys_to_virt(membase);
- printf ( "Prism2.5 has registers at %#x\n", hw->membase );
+ printf ( "Prism2.5 has registers at %#lx\n", hw->membase );
nic->ioaddr = hw->membase;
return prism2_probe ( nic, hw );
}
-static void prism2_pci_disable ( struct nic *nic,
- struct pci_device *pci __unused ) {
+static void prism2_pci_disable ( struct nic *nic ) {
prism2_disable ( nic );
}
diff --git a/src/drivers/net/prism2_plx.c b/src/drivers/net/prism2_plx.c
index 616903cf..afd1c6f0 100644
--- a/src/drivers/net/prism2_plx.c
+++ b/src/drivers/net/prism2_plx.c
@@ -50,8 +50,8 @@ static int prism2_find_plx ( hfa384x_t *hw, struct pci_device *p )
/* Fill out hw structure */
hw->membase = attr_mem;
hw->iobase = iobase;
- printf ( "PLX9052 has local config registers at %#hx\n", plx_lcr );
- printf ( "Prism2 has attribute memory at %#x and I/O base at %#hx\n", attr_mem, iobase );
+ printf ( "PLX9052 has local config registers at %#lx\n", plx_lcr );
+ printf ( "Prism2 has attribute memory at %#lx and I/O base at %#lx\n", attr_mem, iobase );
/* Search for CIS strings */
printf ( "Searching for PCMCIA card...\n" );
@@ -90,8 +90,7 @@ static int prism2_plx_probe ( struct nic *nic, struct pci_device *pci ) {
return prism2_probe ( nic, hw );
}
-static void prism2_plx_disable ( struct nic *nic,
- struct pci_device *pci __unused ) {
+static void prism2_plx_disable ( struct nic *nic ) {
prism2_disable ( nic );
}