diff options
-rw-r--r-- | drivers/staging/bcm/InterfaceInit.c | 3 | ||||
-rw-r--r-- | drivers/staging/bcm/Macros.h | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/drivers/staging/bcm/InterfaceInit.c b/drivers/staging/bcm/InterfaceInit.c index dddf34bb7c8..801ba65e978 100644 --- a/drivers/staging/bcm/InterfaceInit.c +++ b/drivers/staging/bcm/InterfaceInit.c @@ -188,7 +188,8 @@ usbbcm_device_probe(struct usb_interface *intf, const struct usb_device_id *id) PS_INTERFACE_ADAPTER psIntfAdapter; struct net_device *ndev; - ndev = alloc_etherdev_mq(sizeof(MINI_ADAPTER), NO_OF_QUEUES); + /* Reserve one extra queue for the bit-bucket */ + ndev = alloc_etherdev_mq(sizeof(MINI_ADAPTER), NO_OF_QUEUES+1); if(ndev == NULL) { dev_err(&udev->dev, DRV_NAME ": no memory for device\n"); return -ENOMEM; diff --git a/drivers/staging/bcm/Macros.h b/drivers/staging/bcm/Macros.h index 14df2f86b14..f2fd60286a4 100644 --- a/drivers/staging/bcm/Macros.h +++ b/drivers/staging/bcm/Macros.h @@ -261,7 +261,7 @@ typedef enum _E_PHS_DSC_ACTION #define FIRMWARE_BEGIN_ADDR 0xBFC00000 -#define INVALID_QUEUE_INDEX (USHORT)-1 +#define INVALID_QUEUE_INDEX (NO_OF_QUEUES+1) #define INVALID_PID (pid_t)-1 #define DDR_80_MHZ 0 |