[PATCH] libertas: gcc 4.1 compile fix.
Andreas Henriksson
andreas at fjortis.info
Mon Jul 3 20:27:32 EDT 2006
gcc version 4.1.2 20060630 (prerelease) (Debian 4.1.1-7)
CC [M] drivers/net/wireless/libertas/if_usb.o
drivers/net/wireless/libertas/if_usb.c:58: error: initializer element is not constant
drivers/net/wireless/libertas/if_usb.c:58: error: (near initialization for 'if_usb_table[0].driver_info')
drivers/net/wireless/libertas/if_usb.c:60: error: initializer element is not constant
drivers/net/wireless/libertas/if_usb.c:60: error: (near initialization for 'if_usb_table[1].driver_info')
make[1]: *** [drivers/net/wireless/libertas/if_usb.o] Error 1
(I left the device_info-part commented out, since it's probably wrong on
64bit machines. Other drivers uses flags to indicate card. There's also
lots of warnings about using int/u32 and pointers when compiling on x86_64.)
Signed-off-by: Andreas Henriksson <andreas at fjortis.info>
diff --git a/drivers/net/wireless/libertas/if_usb.c b/drivers/net/wireless/libertas/if_usb.c
index 7a2d424..4f5d7b5 100644
--- a/drivers/net/wireless/libertas/if_usb.c
+++ b/drivers/net/wireless/libertas/if_usb.c
@@ -36,10 +36,6 @@ #include "if_usb.h"
#include <linux/firmware.h>
-#define MARVELL_USB_DEVICE(vid, pid, name) \
- USB_DEVICE(vid, pid), \
- .driver_info = (u32)name
-
/* Context definition for Interrupt simulation */
#define TX_SUCCESS 1
#define RX_SUCCESS 2
@@ -55,12 +51,15 @@ static u8 usb_int_cause = 0;
/** struct This structure contains the device signature */
struct usb_device_id if_usb_table[] = {
/* Enter the device signature inside */
- {MARVELL_USB_DEVICE
- (USB8388_VID_1, USB8388_PID_1, "Marvell WLAN USB Adapter")},
- {MARVELL_USB_DEVICE
- (USB8388_VID_2, USB8388_PID_2, "Marvell WLAN USB Adapter")},
- /* Terminating entry */
- {},
+ {
+ USB_DEVICE(USB8388_VID_1, USB8388_PID_1),
+ //.device_info = "Marvell WLAN USB Adapter",
+ },
+ {
+ USB_DEVICE(USB8388_VID_2, USB8388_PID_2),
+ //.device_info = "Marvell WLAN USB Adapter",
+ },
+ {} /* Terminating entry */
};
int if_prog_firmware(wlan_private * priv);
More information about the libertas-dev
mailing list