idx int64 | func_before string | Vulnerability Classification string | vul int64 | func_after string | patch string | CWE ID string | lines_before string | lines_after string |
|---|---|---|---|---|---|---|---|---|
19,200 | static int enable_MAC(struct airo_info *ai, int lock)
{
int rc;
Cmd cmd;
Resp rsp;
/* FLAG_RADIO_OFF : Radio disabled via /proc or Wireless Extensions
* FLAG_RADIO_DOWN : Radio disabled via "ifconfig ethX down"
* Note : we could try to use !netif_running(dev) in enable_MAC()
* instead of this flag, but I don... | DoS | 0 | static int enable_MAC(struct airo_info *ai, int lock)
{
int rc;
Cmd cmd;
Resp rsp;
/* FLAG_RADIO_OFF : Radio disabled via /proc or Wireless Extensions
* FLAG_RADIO_DOWN : Radio disabled via "ifconfig ethX down"
* Note : we could try to use !netif_running(dev) in enable_MAC()
* instead of this flag, but I don... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,201 | static void enable_interrupts( struct airo_info *ai ) {
/* Enable the interrupts */
OUT4500( ai, EVINTEN, STATUS_INTS );
}
| DoS | 0 | static void enable_interrupts( struct airo_info *ai ) {
/* Enable the interrupts */
OUT4500( ai, EVINTEN, STATUS_INTS );
}
| @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,202 | static int fast_bap_read(struct airo_info *ai, __le16 *pu16Dst,
int bytelen, int whichbap)
{
bytelen = (bytelen + 1) & (~1); // round up to even value
if ( !do8bitIO )
insw( ai->dev->base_addr+DATA0+whichbap, pu16Dst, bytelen>>1 );
else
insb( ai->dev->base_addr+DATA0+whichbap, pu16Dst, bytelen );
return SUC... | DoS | 0 | static int fast_bap_read(struct airo_info *ai, __le16 *pu16Dst,
int bytelen, int whichbap)
{
bytelen = (bytelen + 1) & (~1); // round up to even value
if ( !do8bitIO )
insw( ai->dev->base_addr+DATA0+whichbap, pu16Dst, bytelen>>1 );
else
insb( ai->dev->base_addr+DATA0+whichbap, pu16Dst, bytelen );
return SUC... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,203 | static int flashgchar(struct airo_info *ai,int matchbyte,int dwelltime){
int rchar;
unsigned char rbyte=0;
do {
rchar = IN4500(ai,SWS1);
if(dwelltime && !(0x8000 & rchar)){
dwelltime -= 10;
mdelay(10);
continue;
}
rbyte = 0xff & rchar;
if( (rbyte == matchbyte) && (0x8000 & rchar) ){
... | DoS | 0 | static int flashgchar(struct airo_info *ai,int matchbyte,int dwelltime){
int rchar;
unsigned char rbyte=0;
do {
rchar = IN4500(ai,SWS1);
if(dwelltime && !(0x8000 & rchar)){
dwelltime -= 10;
mdelay(10);
continue;
}
rbyte = 0xff & rchar;
if( (rbyte == matchbyte) && (0x8000 & rchar) ){
... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,204 | static int flashpchar(struct airo_info *ai,int byte,int dwelltime) {
int echo;
int waittime;
byte |= 0x8000;
if(dwelltime == 0 )
dwelltime = 200;
waittime=dwelltime;
/* Wait for busy bit d15 to go false indicating buffer empty */
while ((IN4500 (ai, SWS0) & 0x8000) && waittime > 0) {
udelay (50);
waitt... | DoS | 0 | static int flashpchar(struct airo_info *ai,int byte,int dwelltime) {
int echo;
int waittime;
byte |= 0x8000;
if(dwelltime == 0 )
dwelltime = 200;
waittime=dwelltime;
/* Wait for busy bit d15 to go false indicating buffer empty */
while ((IN4500 (ai, SWS0) & 0x8000) && waittime > 0) {
udelay (50);
waitt... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,205 | static int flashputbuf(struct airo_info *ai){
int nwords;
/* Write stuff */
if (test_bit(FLAG_MPI,&ai->flags))
memcpy_toio(ai->pciaux + 0x8000, ai->flash, FLASHSIZE);
else {
OUT4500(ai,AUXPAGE,0x100);
OUT4500(ai,AUXOFF,0);
for(nwords=0;nwords != FLASHSIZE / 2;nwords++){
OUT4500(ai,AUXDATA,ai... | DoS | 0 | static int flashputbuf(struct airo_info *ai){
int nwords;
/* Write stuff */
if (test_bit(FLAG_MPI,&ai->flags))
memcpy_toio(ai->pciaux + 0x8000, ai->flash, FLASHSIZE);
else {
OUT4500(ai,AUXPAGE,0x100);
OUT4500(ai,AUXOFF,0);
for(nwords=0;nwords != FLASHSIZE / 2;nwords++){
OUT4500(ai,AUXDATA,ai... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,206 | static int flashrestart(struct airo_info *ai,struct net_device *dev){
int i,status;
ssleep(1); /* Added 12/7/00 */
clear_bit (FLAG_FLASHING, &ai->flags);
if (test_bit(FLAG_MPI, &ai->flags)) {
status = mpi_init_descriptors(ai);
if (status != SUCCESS)
return status;
}
status = setup_card(ai, dev->dev_a... | DoS | 0 | static int flashrestart(struct airo_info *ai,struct net_device *dev){
int i,status;
ssleep(1); /* Added 12/7/00 */
clear_bit (FLAG_FLASHING, &ai->flags);
if (test_bit(FLAG_MPI, &ai->flags)) {
status = mpi_init_descriptors(ai);
if (status != SUCCESS)
return status;
}
status = setup_card(ai, dev->dev_a... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,207 | static int get_dec_u16( char *buffer, int *start, int limit ) {
u16 value;
int valid = 0;
for (value = 0; *start < limit && buffer[*start] >= '0' &&
buffer[*start] <= '9'; (*start)++) {
valid = 1;
value *= 10;
value += buffer[*start] - '0';
}
if ( !valid ) return -1;
return value;
}
| DoS | 0 | static int get_dec_u16( char *buffer, int *start, int limit ) {
u16 value;
int valid = 0;
for (value = 0; *start < limit && buffer[*start] >= '0' &&
buffer[*start] <= '9'; (*start)++) {
valid = 1;
value *= 10;
value += buffer[*start] - '0';
}
if ( !valid ) return -1;
return value;
}
| @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,208 | static const char *get_rmode(__le16 mode)
{
switch(mode & RXMODE_MASK) {
case RXMODE_RFMON: return "rfmon";
case RXMODE_RFMON_ANYBSS: return "yna (any) bss rfmon";
case RXMODE_LANMON: return "lanmon";
}
return "ESS";
}
| DoS | 0 | static const char *get_rmode(__le16 mode)
{
switch(mode & RXMODE_MASK) {
case RXMODE_RFMON: return "rfmon";
case RXMODE_RFMON_ANYBSS: return "yna (any) bss rfmon";
case RXMODE_LANMON: return "lanmon";
}
return "ESS";
}
| @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,209 | static void get_tx_error(struct airo_info *ai, s32 fid)
{
__le16 status;
if (fid < 0)
status = ((WifiCtlHdr *)ai->txfids[0].virtual_host_addr)->ctlhdr.status;
else {
if (bap_setup(ai, ai->fids[fid] & 0xffff, 4, BAP0) != SUCCESS)
return;
bap_read(ai, &status, 2, BAP0);
}
if (le16_to_cpu(status) & 2) /* To... | DoS | 0 | static void get_tx_error(struct airo_info *ai, s32 fid)
{
__le16 status;
if (fid < 0)
status = ((WifiCtlHdr *)ai->txfids[0].virtual_host_addr)->ctlhdr.status;
else {
if (bap_setup(ai, ai->fids[fid] & 0xffff, 4, BAP0) != SUCCESS)
return;
bap_read(ai, &status, 2, BAP0);
}
if (le16_to_cpu(status) & 2) /* To... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,210 | static int get_wep_key(struct airo_info *ai, u16 index, char *buf, u16 buflen)
{
WepKeyRid wkr;
int rc;
__le16 lastindex;
rc = readWepKeyRid(ai, &wkr, 1, 1);
if (rc != SUCCESS)
return -1;
do {
lastindex = wkr.kindex;
if (le16_to_cpu(wkr.kindex) == index) {
int klen = min_t(int, buflen, le16_to_cpu(wkr.k... | DoS | 0 | static int get_wep_key(struct airo_info *ai, u16 index, char *buf, u16 buflen)
{
WepKeyRid wkr;
int rc;
__le16 lastindex;
rc = readWepKeyRid(ai, &wkr, 1, 1);
if (rc != SUCCESS)
return -1;
do {
lastindex = wkr.kindex;
if (le16_to_cpu(wkr.kindex) == index) {
int klen = min_t(int, buflen, le16_to_cpu(wkr.k... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,211 | static int get_wep_tx_idx(struct airo_info *ai)
{
WepKeyRid wkr;
int rc;
__le16 lastindex;
rc = readWepKeyRid(ai, &wkr, 1, 1);
if (rc != SUCCESS)
return -1;
do {
lastindex = wkr.kindex;
if (wkr.kindex == cpu_to_le16(0xffff))
return wkr.mac[0];
rc = readWepKeyRid(ai, &wkr, 0, 1);
if (rc != SUCCESS)
... | DoS | 0 | static int get_wep_tx_idx(struct airo_info *ai)
{
WepKeyRid wkr;
int rc;
__le16 lastindex;
rc = readWepKeyRid(ai, &wkr, 1, 1);
if (rc != SUCCESS)
return -1;
do {
lastindex = wkr.kindex;
if (wkr.kindex == cpu_to_le16(0xffff))
return wkr.mac[0];
rc = readWepKeyRid(ai, &wkr, 0, 1);
if (rc != SUCCESS)
... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,212 | static int header_len(__le16 ctl)
{
u16 fc = le16_to_cpu(ctl);
switch (fc & 0xc) {
case 4:
if ((fc & 0xe0) == 0xc0)
return 10; /* one-address control packet */
return 16; /* two-address control packet */
case 8:
if ((fc & 0x300) == 0x300)
return 30; /* WDS packet */
}
return 24;
}
| DoS | 0 | static int header_len(__le16 ctl)
{
u16 fc = le16_to_cpu(ctl);
switch (fc & 0xc) {
case 4:
if ((fc & 0xe0) == 0xc0)
return 10; /* one-address control packet */
return 16; /* two-address control packet */
case 8:
if ((fc & 0x300) == 0x300)
return 30; /* WDS packet */
}
return 24;
}
| @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,213 | struct net_device *init_airo_card( unsigned short irq, int port, int is_pcmcia,
struct device *dmdev)
{
return _init_airo_card ( irq, port, is_pcmcia, NULL, dmdev);
}
| DoS | 0 | struct net_device *init_airo_card( unsigned short irq, int port, int is_pcmcia,
struct device *dmdev)
{
return _init_airo_card ( irq, port, is_pcmcia, NULL, dmdev);
}
| @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,214 | static u16 issuecommand(struct airo_info *ai, Cmd *pCmd, Resp *pRsp) {
int max_tries = 600000;
if (IN4500(ai, EVSTAT) & EV_CMD)
OUT4500(ai, EVACK, EV_CMD);
OUT4500(ai, PARAM0, pCmd->parm0);
OUT4500(ai, PARAM1, pCmd->parm1);
OUT4500(ai, PARAM2, pCmd->parm2);
OUT4500(ai, COMMAND, pCmd->cmd);
while (max_tries-... | DoS | 0 | static u16 issuecommand(struct airo_info *ai, Cmd *pCmd, Resp *pRsp) {
int max_tries = 600000;
if (IN4500(ai, EVSTAT) & EV_CMD)
OUT4500(ai, EVACK, EV_CMD);
OUT4500(ai, PARAM0, pCmd->parm0);
OUT4500(ai, PARAM1, pCmd->parm1);
OUT4500(ai, PARAM2, pCmd->parm2);
OUT4500(ai, COMMAND, pCmd->cmd);
while (max_tries-... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,215 | static int micsetup(struct airo_info *ai) {
int i;
if (ai->tfm == NULL)
ai->tfm = crypto_alloc_cipher("aes", 0, CRYPTO_ALG_ASYNC);
if (IS_ERR(ai->tfm)) {
airo_print_err(ai->dev->name, "failed to load transform for AES");
ai->tfm = NULL;
return ERROR;
... | DoS | 0 | static int micsetup(struct airo_info *ai) {
int i;
if (ai->tfm == NULL)
ai->tfm = crypto_alloc_cipher("aes", 0, CRYPTO_ALG_ASYNC);
if (IS_ERR(ai->tfm)) {
airo_print_err(ai->dev->name, "failed to load transform for AES");
ai->tfm = NULL;
return ERROR;
... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,216 | static int mpi_init_descriptors (struct airo_info *ai)
{
Cmd cmd;
Resp rsp;
int i;
int rc = SUCCESS;
/* Alloc card RX descriptors */
netif_stop_queue(ai->dev);
memset(&rsp,0,sizeof(rsp));
memset(&cmd,0,sizeof(cmd));
cmd.cmd = CMD_ALLOCATEAUX;
cmd.parm0 = FID_RX;
cmd.parm1 = (ai->rxfids[0].card_ram_off - ... | DoS | 0 | static int mpi_init_descriptors (struct airo_info *ai)
{
Cmd cmd;
Resp rsp;
int i;
int rc = SUCCESS;
/* Alloc card RX descriptors */
netif_stop_queue(ai->dev);
memset(&rsp,0,sizeof(rsp));
memset(&cmd,0,sizeof(cmd));
cmd.cmd = CMD_ALLOCATEAUX;
cmd.parm0 = FID_RX;
cmd.parm1 = (ai->rxfids[0].card_ram_off - ... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,217 | static void mpi_receive_802_11(struct airo_info *ai)
{
RxFid rxd;
struct sk_buff *skb = NULL;
u16 len, hdrlen = 0;
__le16 fc;
struct rx_hdr hdr;
u16 gap;
u16 *buffer;
char *ptr = ai->rxfids[0].virtual_host_addr + 4;
memcpy_fromio(&rxd, ai->rxfids[0].card_ram_off, sizeof(rxd));
memcpy ((char *)&hdr, ptr, size... | DoS | 0 | static void mpi_receive_802_11(struct airo_info *ai)
{
RxFid rxd;
struct sk_buff *skb = NULL;
u16 len, hdrlen = 0;
__le16 fc;
struct rx_hdr hdr;
u16 gap;
u16 *buffer;
char *ptr = ai->rxfids[0].virtual_host_addr + 4;
memcpy_fromio(&rxd, ai->rxfids[0].card_ram_off, sizeof(rxd));
memcpy ((char *)&hdr, ptr, size... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,218 | static void mpi_receive_802_3(struct airo_info *ai)
{
RxFid rxd;
int len = 0;
struct sk_buff *skb;
char *buffer;
int off = 0;
MICBuffer micbuf;
memcpy_fromio(&rxd, ai->rxfids[0].card_ram_off, sizeof(rxd));
/* Make sure we got something */
if (rxd.rdy && rxd.valid == 0) {
len = rxd.len + 12;
if (len < 12 |... | DoS | 0 | static void mpi_receive_802_3(struct airo_info *ai)
{
RxFid rxd;
int len = 0;
struct sk_buff *skb;
char *buffer;
int off = 0;
MICBuffer micbuf;
memcpy_fromio(&rxd, ai->rxfids[0].card_ram_off, sizeof(rxd));
/* Make sure we got something */
if (rxd.rdy && rxd.valid == 0) {
len = rxd.len + 12;
if (len < 12 |... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,219 | static int mpi_send_packet (struct net_device *dev)
{
struct sk_buff *skb;
unsigned char *buffer;
s16 len;
__le16 *payloadLen;
struct airo_info *ai = dev->ml_priv;
u8 *sendbuf;
/* get a packet to send */
if ((skb = skb_dequeue(&ai->txq)) == NULL) {
airo_print_err(dev->name,
"%s: Dequeue'd zero in send_pa... | DoS | 0 | static int mpi_send_packet (struct net_device *dev)
{
struct sk_buff *skb;
unsigned char *buffer;
s16 len;
__le16 *payloadLen;
struct airo_info *ai = dev->ml_priv;
u8 *sendbuf;
/* get a packet to send */
if ((skb = skb_dequeue(&ai->txq)) == NULL) {
airo_print_err(dev->name,
"%s: Dequeue'd zero in send_pa... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,220 | static netdev_tx_t mpi_start_xmit(struct sk_buff *skb,
struct net_device *dev)
{
int npacks, pending;
unsigned long flags;
struct airo_info *ai = dev->ml_priv;
if (!skb) {
airo_print_err(dev->name, "%s: skb == NULL!",__func__);
return NETDEV_TX_OK;
}
npacks = skb_queue_len (&ai->txq);
if (npacks >= MA... | DoS | 0 | static netdev_tx_t mpi_start_xmit(struct sk_buff *skb,
struct net_device *dev)
{
int npacks, pending;
unsigned long flags;
struct airo_info *ai = dev->ml_priv;
if (!skb) {
airo_print_err(dev->name, "%s: skb == NULL!",__func__);
return NETDEV_TX_OK;
}
npacks = skb_queue_len (&ai->txq);
if (npacks >= MA... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,221 | static void proc_APList_on_close( struct inode *inode, struct file *file ) {
struct proc_data *data = file->private_data;
struct proc_dir_entry *dp = PDE(inode);
struct net_device *dev = dp->data;
struct airo_info *ai = dev->ml_priv;
APListRid APList_rid;
int i;
if ( !data->writelen ) return;
memset( &APList_... | DoS | 0 | static void proc_APList_on_close( struct inode *inode, struct file *file ) {
struct proc_data *data = file->private_data;
struct proc_dir_entry *dp = PDE(inode);
struct net_device *dev = dp->data;
struct airo_info *ai = dev->ml_priv;
APListRid APList_rid;
int i;
if ( !data->writelen ) return;
memset( &APList_... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,222 | static int proc_APList_open( struct inode *inode, struct file *file ) {
struct proc_data *data;
struct proc_dir_entry *dp = PDE(inode);
struct net_device *dev = dp->data;
struct airo_info *ai = dev->ml_priv;
int i;
char *ptr;
APListRid APList_rid;
if ((file->private_data = kzalloc(sizeof(struct proc_data ), GF... | DoS | 0 | static int proc_APList_open( struct inode *inode, struct file *file ) {
struct proc_data *data;
struct proc_dir_entry *dp = PDE(inode);
struct net_device *dev = dp->data;
struct airo_info *ai = dev->ml_priv;
int i;
char *ptr;
APListRid APList_rid;
if ((file->private_data = kzalloc(sizeof(struct proc_data ), GF... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,223 | static int proc_BSSList_open( struct inode *inode, struct file *file ) {
struct proc_data *data;
struct proc_dir_entry *dp = PDE(inode);
struct net_device *dev = dp->data;
struct airo_info *ai = dev->ml_priv;
char *ptr;
BSSListRid BSSList_rid;
int rc;
/* If doLoseSync is not 1, we won't do a Lose Sync */
int d... | DoS | 0 | static int proc_BSSList_open( struct inode *inode, struct file *file ) {
struct proc_data *data;
struct proc_dir_entry *dp = PDE(inode);
struct net_device *dev = dp->data;
struct airo_info *ai = dev->ml_priv;
char *ptr;
BSSListRid BSSList_rid;
int rc;
/* If doLoseSync is not 1, we won't do a Lose Sync */
int d... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,224 | static void proc_SSID_on_close(struct inode *inode, struct file *file)
{
struct proc_data *data = file->private_data;
struct proc_dir_entry *dp = PDE(inode);
struct net_device *dev = dp->data;
struct airo_info *ai = dev->ml_priv;
SsidRid SSID_rid;
int i;
char *p = data->wbuffer;
char *end = p + data->writelen;
... | DoS | 0 | static void proc_SSID_on_close(struct inode *inode, struct file *file)
{
struct proc_data *data = file->private_data;
struct proc_dir_entry *dp = PDE(inode);
struct net_device *dev = dp->data;
struct airo_info *ai = dev->ml_priv;
SsidRid SSID_rid;
int i;
char *p = data->wbuffer;
char *end = p + data->writelen;
... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,225 | static int proc_close( struct inode *inode, struct file *file )
{
struct proc_data *data = file->private_data;
if (data->on_close != NULL)
data->on_close(inode, file);
kfree(data->rbuffer);
kfree(data->wbuffer);
kfree(data);
return 0;
}
| DoS | 0 | static int proc_close( struct inode *inode, struct file *file )
{
struct proc_data *data = file->private_data;
if (data->on_close != NULL)
data->on_close(inode, file);
kfree(data->rbuffer);
kfree(data->wbuffer);
kfree(data);
return 0;
}
| @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,226 | static void proc_config_on_close(struct inode *inode, struct file *file)
{
struct proc_data *data = file->private_data;
struct proc_dir_entry *dp = PDE(inode);
struct net_device *dev = dp->data;
struct airo_info *ai = dev->ml_priv;
char *line;
if ( !data->writelen ) return;
readConfigRid(ai, 1);
set_bit (FLAG... | DoS | 0 | static void proc_config_on_close(struct inode *inode, struct file *file)
{
struct proc_data *data = file->private_data;
struct proc_dir_entry *dp = PDE(inode);
struct net_device *dev = dp->data;
struct airo_info *ai = dev->ml_priv;
char *line;
if ( !data->writelen ) return;
readConfigRid(ai, 1);
set_bit (FLAG... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,227 | static int proc_config_open(struct inode *inode, struct file *file)
{
struct proc_data *data;
struct proc_dir_entry *dp = PDE(inode);
struct net_device *dev = dp->data;
struct airo_info *ai = dev->ml_priv;
int i;
__le16 mode;
if ((file->private_data = kzalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL)
r... | DoS | 0 | static int proc_config_open(struct inode *inode, struct file *file)
{
struct proc_data *data;
struct proc_dir_entry *dp = PDE(inode);
struct net_device *dev = dp->data;
struct airo_info *ai = dev->ml_priv;
int i;
__le16 mode;
if ((file->private_data = kzalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL)
r... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,228 | static ssize_t proc_read( struct file *file,
char __user *buffer,
size_t len,
loff_t *offset )
{
struct proc_data *priv = file->private_data;
if (!priv->rbuffer)
return -EINVAL;
return simple_read_from_buffer(buffer, len, offset, priv->rbuffer,
priv->readlen);
}
| DoS | 0 | static ssize_t proc_read( struct file *file,
char __user *buffer,
size_t len,
loff_t *offset )
{
struct proc_data *priv = file->private_data;
if (!priv->rbuffer)
return -EINVAL;
return simple_read_from_buffer(buffer, len, offset, priv->rbuffer,
priv->readlen);
}
| @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,229 | static int proc_stats_open( struct inode *inode, struct file *file ) {
return proc_stats_rid_open(inode, file, RID_STATS);
}
| DoS | 0 | static int proc_stats_open( struct inode *inode, struct file *file ) {
return proc_stats_rid_open(inode, file, RID_STATS);
}
| @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,230 | static int proc_stats_rid_open( struct inode *inode,
struct file *file,
u16 rid )
{
struct proc_data *data;
struct proc_dir_entry *dp = PDE(inode);
struct net_device *dev = dp->data;
struct airo_info *apriv = dev->ml_priv;
StatsRid stats;
int i, j;
__le32 *vals = stats.vals;
int len;
if ((file->privat... | DoS | 0 | static int proc_stats_rid_open( struct inode *inode,
struct file *file,
u16 rid )
{
struct proc_data *data;
struct proc_dir_entry *dp = PDE(inode);
struct net_device *dev = dp->data;
struct airo_info *apriv = dev->ml_priv;
StatsRid stats;
int i, j;
__le32 *vals = stats.vals;
int len;
if ((file->privat... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,231 | static int proc_statsdelta_open( struct inode *inode,
struct file *file ) {
if (file->f_mode&FMODE_WRITE) {
return proc_stats_rid_open(inode, file, RID_STATSDELTACLEAR);
}
return proc_stats_rid_open(inode, file, RID_STATSDELTA);
}
| DoS | 0 | static int proc_statsdelta_open( struct inode *inode,
struct file *file ) {
if (file->f_mode&FMODE_WRITE) {
return proc_stats_rid_open(inode, file, RID_STATSDELTACLEAR);
}
return proc_stats_rid_open(inode, file, RID_STATSDELTA);
}
| @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,232 | static int proc_status_open(struct inode *inode, struct file *file)
{
struct proc_data *data;
struct proc_dir_entry *dp = PDE(inode);
struct net_device *dev = dp->data;
struct airo_info *apriv = dev->ml_priv;
CapabilityRid cap_rid;
StatusRid status_rid;
u16 mode;
int i;
if ((file->private_data = kzalloc(sizeo... | DoS | 0 | static int proc_status_open(struct inode *inode, struct file *file)
{
struct proc_data *data;
struct proc_dir_entry *dp = PDE(inode);
struct net_device *dev = dp->data;
struct airo_info *apriv = dev->ml_priv;
CapabilityRid cap_rid;
StatusRid status_rid;
u16 mode;
int i;
if ((file->private_data = kzalloc(sizeo... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,233 | static ssize_t proc_write( struct file *file,
const char __user *buffer,
size_t len,
loff_t *offset )
{
ssize_t ret;
struct proc_data *priv = file->private_data;
if (!priv->wbuffer)
return -EINVAL;
ret = simple_write_to_buffer(priv->wbuffer, priv->maxwritelen, offset,
buffer, len);
if (r... | DoS | 0 | static ssize_t proc_write( struct file *file,
const char __user *buffer,
size_t len,
loff_t *offset )
{
ssize_t ret;
struct proc_data *priv = file->private_data;
if (!priv->wbuffer)
return -EINVAL;
ret = simple_write_to_buffer(priv->wbuffer, priv->maxwritelen, offset,
buffer, len);
if (r... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,234 | static int readCapabilityRid(struct airo_info *ai, CapabilityRid *capr, int lock)
{
return PC4500_readrid(ai, RID_CAPABILITIES, capr, sizeof(*capr), lock);
}
| DoS | 0 | static int readCapabilityRid(struct airo_info *ai, CapabilityRid *capr, int lock)
{
return PC4500_readrid(ai, RID_CAPABILITIES, capr, sizeof(*capr), lock);
}
| @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,235 | static int readSsidRid(struct airo_info*ai, SsidRid *ssidr)
{
return PC4500_readrid(ai, RID_SSID, ssidr, sizeof(*ssidr), 1);
}
| DoS | 0 | static int readSsidRid(struct airo_info*ai, SsidRid *ssidr)
{
return PC4500_readrid(ai, RID_SSID, ssidr, sizeof(*ssidr), 1);
}
| @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,236 | static int readWepKeyRid(struct airo_info *ai, WepKeyRid *wkr, int temp, int lock)
{
return PC4500_readrid(ai, temp ? RID_WEP_TEMP : RID_WEP_PERM,
wkr, sizeof(*wkr), lock);
}
| DoS | 0 | static int readWepKeyRid(struct airo_info *ai, WepKeyRid *wkr, int temp, int lock)
{
return PC4500_readrid(ai, temp ? RID_WEP_TEMP : RID_WEP_PERM,
wkr, sizeof(*wkr), lock);
}
| @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,237 | static int readrids(struct net_device *dev, aironet_ioctl *comp) {
unsigned short ridcode;
unsigned char *iobuf;
int len;
struct airo_info *ai = dev->ml_priv;
if (test_bit(FLAG_FLASHING, &ai->flags))
return -EIO;
switch(comp->command)
{
case AIROGCAP: ridcode = RID_CAPABILITIES; break;
case AIROGCFG: ... | DoS | 0 | static int readrids(struct net_device *dev, aironet_ioctl *comp) {
unsigned short ridcode;
unsigned char *iobuf;
int len;
struct airo_info *ai = dev->ml_priv;
if (test_bit(FLAG_FLASHING, &ai->flags))
return -EIO;
switch(comp->command)
{
case AIROGCAP: ridcode = RID_CAPABILITIES; break;
case AIROGCFG: ... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,238 | static int reset_card( struct net_device *dev , int lock) {
struct airo_info *ai = dev->ml_priv;
if (lock && down_interruptible(&ai->sem))
return -1;
waitbusy (ai);
OUT4500(ai,COMMAND,CMD_SOFTRESET);
msleep(200);
waitbusy (ai);
msleep(200);
if (lock)
up(&ai->sem);
return 0;
}
| DoS | 0 | static int reset_card( struct net_device *dev , int lock) {
struct airo_info *ai = dev->ml_priv;
if (lock && down_interruptible(&ai->sem))
return -1;
waitbusy (ai);
OUT4500(ai,COMMAND,CMD_SOFTRESET);
msleep(200);
waitbusy (ai);
msleep(200);
if (lock)
up(&ai->sem);
return 0;
}
| @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,239 | static int set_wep_key(struct airo_info *ai, u16 index, const char *key,
u16 keylen, int perm, int lock)
{
static const unsigned char macaddr[ETH_ALEN] = { 0x01, 0, 0, 0, 0, 0 };
WepKeyRid wkr;
int rc;
if (WARN_ON(keylen == 0))
return -1;
memset(&wkr, 0, sizeof(wkr));
wkr.len = cpu_to_le16(sizeof(wkr... | DoS | 0 | static int set_wep_key(struct airo_info *ai, u16 index, const char *key,
u16 keylen, int perm, int lock)
{
static const unsigned char macaddr[ETH_ALEN] = { 0x01, 0, 0, 0, 0, 0 };
WepKeyRid wkr;
int rc;
if (WARN_ON(keylen == 0))
return -1;
memset(&wkr, 0, sizeof(wkr));
wkr.len = cpu_to_le16(sizeof(wkr... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,240 | static int set_wep_tx_idx(struct airo_info *ai, u16 index, int perm, int lock)
{
WepKeyRid wkr;
int rc;
memset(&wkr, 0, sizeof(wkr));
wkr.len = cpu_to_le16(sizeof(wkr));
wkr.kindex = cpu_to_le16(0xffff);
wkr.mac[0] = (char)index;
if (perm) {
ai->defindex = (char)index;
disable_MAC(ai, lock);
}
rc = writ... | DoS | 0 | static int set_wep_tx_idx(struct airo_info *ai, u16 index, int perm, int lock)
{
WepKeyRid wkr;
int rc;
memset(&wkr, 0, sizeof(wkr));
wkr.len = cpu_to_le16(sizeof(wkr));
wkr.kindex = cpu_to_le16(0xffff);
wkr.mac[0] = (char)index;
if (perm) {
ai->defindex = (char)index;
disable_MAC(ai, lock);
}
rc = writ... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,241 | static int setflashmode (struct airo_info *ai) {
set_bit (FLAG_FLASHING, &ai->flags);
OUT4500(ai, SWS0, FLASH_COMMAND);
OUT4500(ai, SWS1, FLASH_COMMAND);
if (probe) {
OUT4500(ai, SWS0, FLASH_COMMAND);
OUT4500(ai, COMMAND,0x10);
} else {
OUT4500(ai, SWS2, FLASH_COMMAND);
OUT4500(ai, SWS3, FLASH_COMMAND);
... | DoS | 0 | static int setflashmode (struct airo_info *ai) {
set_bit (FLAG_FLASHING, &ai->flags);
OUT4500(ai, SWS0, FLASH_COMMAND);
OUT4500(ai, SWS1, FLASH_COMMAND);
if (probe) {
OUT4500(ai, SWS0, FLASH_COMMAND);
OUT4500(ai, COMMAND,0x10);
} else {
OUT4500(ai, SWS2, FLASH_COMMAND);
OUT4500(ai, SWS3, FLASH_COMMAND);
... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,242 | static u16 setup_card(struct airo_info *ai, u8 *mac, int lock)
{
Cmd cmd;
Resp rsp;
int status;
SsidRid mySsid;
__le16 lastindex;
WepKeyRid wkr;
int rc;
memset( &mySsid, 0, sizeof( mySsid ) );
kfree (ai->flash);
ai->flash = NULL;
/* The NOP is the first step in getting the card going */
cmd.cmd = NOP;
cm... | DoS | 0 | static u16 setup_card(struct airo_info *ai, u8 *mac, int lock)
{
Cmd cmd;
Resp rsp;
int status;
SsidRid mySsid;
__le16 lastindex;
WepKeyRid wkr;
int rc;
memset( &mySsid, 0, sizeof( mySsid ) );
kfree (ai->flash);
ai->flash = NULL;
/* The NOP is the first step in getting the card going */
cmd.cmd = NOP;
cm... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,243 | static int setup_proc_entry( struct net_device *dev,
struct airo_info *apriv ) {
struct proc_dir_entry *entry;
/* First setup the device directory */
strcpy(apriv->proc_name,dev->name);
apriv->proc_entry = proc_mkdir_mode(apriv->proc_name, airo_perm,
airo_entry);
if (!apriv->proc_entry)
goto fai... | DoS | 0 | static int setup_proc_entry( struct net_device *dev,
struct airo_info *apriv ) {
struct proc_dir_entry *entry;
/* First setup the device directory */
strcpy(apriv->proc_name,dev->name);
apriv->proc_entry = proc_mkdir_mode(apriv->proc_name, airo_perm,
airo_entry);
if (!apriv->proc_entry)
goto fai... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,244 | static inline int sniffing_mode(struct airo_info *ai)
{
return (le16_to_cpu(ai->config.rmode) & le16_to_cpu(RXMODE_MASK)) >=
le16_to_cpu(RXMODE_RFMON);
}
| DoS | 0 | static inline int sniffing_mode(struct airo_info *ai)
{
return (le16_to_cpu(ai->config.rmode) & le16_to_cpu(RXMODE_MASK)) >=
le16_to_cpu(RXMODE_RFMON);
}
| @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,245 | void stop_airo_card( struct net_device *dev, int freeres )
{
struct airo_info *ai = dev->ml_priv;
set_bit(FLAG_RADIO_DOWN, &ai->flags);
disable_MAC(ai, 1);
disable_interrupts(ai);
takedown_proc_entry( dev, ai );
if (test_bit(FLAG_REGISTERED, &ai->flags)) {
unregister_netdev( dev );
if (ai->wifidev) {
unre... | DoS | 0 | void stop_airo_card( struct net_device *dev, int freeres )
{
struct airo_info *ai = dev->ml_priv;
set_bit(FLAG_RADIO_DOWN, &ai->flags);
disable_MAC(ai, 1);
disable_interrupts(ai);
takedown_proc_entry( dev, ai );
if (test_bit(FLAG_REGISTERED, &ai->flags)) {
unregister_netdev( dev );
if (ai->wifidev) {
unre... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,246 | static int takedown_proc_entry( struct net_device *dev,
struct airo_info *apriv ) {
if ( !apriv->proc_entry->namelen ) return 0;
remove_proc_entry("Stats",apriv->proc_entry);
remove_proc_entry("StatsDelta",apriv->proc_entry);
remove_proc_entry("Status",apriv->proc_entry);
remove_proc_entry("Config",apriv->proc... | DoS | 0 | static int takedown_proc_entry( struct net_device *dev,
struct airo_info *apriv ) {
if ( !apriv->proc_entry->namelen ) return 0;
remove_proc_entry("Stats",apriv->proc_entry);
remove_proc_entry("StatsDelta",apriv->proc_entry);
remove_proc_entry("Status",apriv->proc_entry);
remove_proc_entry("Config",apriv->proc... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,247 | static void timer_func( struct net_device *dev ) {
struct airo_info *apriv = dev->ml_priv;
/* We don't have a link so try changing the authtype */
readConfigRid(apriv, 0);
disable_MAC(apriv, 0);
switch(apriv->config.authType) {
case AUTH_ENCRYPT:
/* So drop to OPEN */
apriv->config.authType = AUTH_OPEN;
br... | DoS | 0 | static void timer_func( struct net_device *dev ) {
struct airo_info *apriv = dev->ml_priv;
/* We don't have a link so try changing the authtype */
readConfigRid(apriv, 0);
disable_MAC(apriv, 0);
switch(apriv->config.authType) {
case AUTH_ENCRYPT:
/* So drop to OPEN */
apriv->config.authType = AUTH_OPEN;
br... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,248 | static int transmit_802_3_packet(struct airo_info *ai, int len, char *pPacket)
{
__le16 payloadLen;
Cmd cmd;
Resp rsp;
int miclen = 0;
u16 txFid = len;
MICBuffer pMic;
len >>= 16;
if (len <= ETH_ALEN * 2) {
airo_print_warn(ai->dev->name, "Short packet %d", len);
return ERROR;
}
len -= ETH_ALEN * 2;
if... | DoS | 0 | static int transmit_802_3_packet(struct airo_info *ai, int len, char *pPacket)
{
__le16 payloadLen;
Cmd cmd;
Resp rsp;
int miclen = 0;
u16 txFid = len;
MICBuffer pMic;
len >>= 16;
if (len <= ETH_ALEN * 2) {
airo_print_warn(ai->dev->name, "Short packet %d", len);
return ERROR;
}
len -= ETH_ALEN * 2;
if... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,249 | static u16 transmit_allocate(struct airo_info *ai, int lenPayload, int raw)
{
unsigned int loop = 3000;
Cmd cmd;
Resp rsp;
u16 txFid;
__le16 txControl;
cmd.cmd = CMD_ALLOCATETX;
cmd.parm0 = lenPayload;
if (down_interruptible(&ai->sem))
return ERROR;
if (issuecommand(ai, &cmd, &rsp) != SUCCESS) {
txFid = E... | DoS | 0 | static u16 transmit_allocate(struct airo_info *ai, int lenPayload, int raw)
{
unsigned int loop = 3000;
Cmd cmd;
Resp rsp;
u16 txFid;
__le16 txControl;
cmd.cmd = CMD_ALLOCATETX;
cmd.parm0 = lenPayload;
if (down_interruptible(&ai->sem))
return ERROR;
if (issuecommand(ai, &cmd, &rsp) != SUCCESS) {
txFid = E... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,250 | static void try_auto_wep(struct airo_info *ai)
{
if (auto_wep && !(ai->flags & FLAG_RADIO_DOWN)) {
ai->expires = RUN_AT(3*HZ);
wake_up_interruptible(&ai->thr_wait);
}
}
| DoS | 0 | static void try_auto_wep(struct airo_info *ai)
{
if (auto_wep && !(ai->flags & FLAG_RADIO_DOWN)) {
ai->expires = RUN_AT(3*HZ);
wake_up_interruptible(&ai->thr_wait);
}
}
| @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,251 | static void wifi_setup(struct net_device *dev)
{
dev->netdev_ops = &airo11_netdev_ops;
dev->header_ops = &airo_header_ops;
dev->wireless_handlers = &airo_handler_def;
dev->type = ARPHRD_IEEE80211;
dev->hard_header_len = ETH_HLEN;
dev->mtu = AIRO_DEF_MTU;
dev->addr_len =... | DoS | 0 | static void wifi_setup(struct net_device *dev)
{
dev->netdev_ops = &airo11_netdev_ops;
dev->header_ops = &airo_header_ops;
dev->wireless_handlers = &airo_handler_def;
dev->type = ARPHRD_IEEE80211;
dev->hard_header_len = ETH_HLEN;
dev->mtu = AIRO_DEF_MTU;
dev->addr_len =... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,252 | static int writeConfigRid(struct airo_info *ai, int lock)
{
ConfigRid cfgr;
if (!test_bit (FLAG_COMMIT, &ai->flags))
return SUCCESS;
clear_bit (FLAG_COMMIT, &ai->flags);
clear_bit (FLAG_RESET, &ai->flags);
checkThrottle(ai);
cfgr = ai->config;
if ((cfgr.opmode & MODE_CFG_MASK) == MODE_STA_IBSS)
set_bit(FL... | DoS | 0 | static int writeConfigRid(struct airo_info *ai, int lock)
{
ConfigRid cfgr;
if (!test_bit (FLAG_COMMIT, &ai->flags))
return SUCCESS;
clear_bit (FLAG_COMMIT, &ai->flags);
clear_bit (FLAG_RESET, &ai->flags);
checkThrottle(ai);
cfgr = ai->config;
if ((cfgr.opmode & MODE_CFG_MASK) == MODE_STA_IBSS)
set_bit(FL... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,253 | static int writeSsidRid(struct airo_info*ai, SsidRid *pssidr, int lock)
{
return PC4500_writerid(ai, RID_SSID, pssidr, sizeof(*pssidr), lock);
}
| DoS | 0 | static int writeSsidRid(struct airo_info*ai, SsidRid *pssidr, int lock)
{
return PC4500_writerid(ai, RID_SSID, pssidr, sizeof(*pssidr), lock);
}
| @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,254 | static int writeWepKeyRid(struct airo_info *ai, WepKeyRid *wkr, int perm, int lock)
{
int rc;
rc = PC4500_writerid(ai, RID_WEP_TEMP, wkr, sizeof(*wkr), lock);
if (rc!=SUCCESS)
airo_print_err(ai->dev->name, "WEP_TEMP set %x", rc);
if (perm) {
rc = PC4500_writerid(ai, RID_WEP_PERM, wkr, sizeof(*wkr), lock);
if ... | DoS | 0 | static int writeWepKeyRid(struct airo_info *ai, WepKeyRid *wkr, int perm, int lock)
{
int rc;
rc = PC4500_writerid(ai, RID_WEP_TEMP, wkr, sizeof(*wkr), lock);
if (rc!=SUCCESS)
airo_print_err(ai->dev->name, "WEP_TEMP set %x", rc);
if (perm) {
rc = PC4500_writerid(ai, RID_WEP_PERM, wkr, sizeof(*wkr), lock);
if ... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,255 | static int writerids(struct net_device *dev, aironet_ioctl *comp) {
struct airo_info *ai = dev->ml_priv;
int ridcode;
int enabled;
static int (* writer)(struct airo_info *, u16 rid, const void *, int, int);
unsigned char *iobuf;
/* Only super-user can write RIDs */
if (!capable(CAP_NET_ADMIN))
return... | DoS | 0 | static int writerids(struct net_device *dev, aironet_ioctl *comp) {
struct airo_info *ai = dev->ml_priv;
int ridcode;
int enabled;
static int (* writer)(struct airo_info *, u16 rid, const void *, int, int);
unsigned char *iobuf;
/* Only super-user can write RIDs */
if (!capable(CAP_NET_ADMIN))
return... | @@ -2823,6 +2823,7 @@ static struct net_device *_init_airo_card( unsigned short irq, int port,
dev->wireless_data = &ai->wireless_data;
dev->irq = irq;
dev->base_addr = port;
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
SET_NETDEV_DEV(dev, dmdev);
| CWE-264 | null | null |
19,256 | int hostap_80211_get_hdrlen(__le16 fc)
{
if (ieee80211_is_data(fc) && ieee80211_has_a4 (fc))
return 30; /* Addr4 */
else if (ieee80211_is_cts(fc) || ieee80211_is_ack(fc))
return 10;
else if (ieee80211_is_ctl(fc))
return 16;
return 24;
}
| DoS | 0 | int hostap_80211_get_hdrlen(__le16 fc)
{
if (ieee80211_is_data(fc) && ieee80211_has_a4 (fc))
return 30; /* Addr4 */
else if (ieee80211_is_cts(fc) || ieee80211_is_ack(fc))
return 10;
else if (ieee80211_is_ctl(fc))
return 16;
return 24;
}
| @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,257 | static int hostap_80211_header_parse(const struct sk_buff *skb,
unsigned char *haddr)
{
memcpy(haddr, skb_mac_header(skb) + 10, ETH_ALEN); /* addr2 */
return ETH_ALEN;
}
| DoS | 0 | static int hostap_80211_header_parse(const struct sk_buff *skb,
unsigned char *haddr)
{
memcpy(haddr, skb_mac_header(skb) + 10, ETH_ALEN); /* addr2 */
return ETH_ALEN;
}
| @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,258 | struct net_device * hostap_add_interface(struct local_info *local,
int type, int rtnl_locked,
const char *prefix,
const char *name)
{
struct net_device *dev, *mdev;
struct hostap_interface *iface;
int ret;
dev = alloc_etherdev(sizeof(struct hostap_interface));
if (dev == NULL)
return NULL;
i... | DoS | 0 | struct net_device * hostap_add_interface(struct local_info *local,
int type, int rtnl_locked,
const char *prefix,
const char *name)
{
struct net_device *dev, *mdev;
struct hostap_interface *iface;
int ret;
dev = alloc_etherdev(sizeof(struct hostap_interface));
if (dev == NULL)
return NULL;
i... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,259 | static int hostap_disable_hostapd_sta(local_info_t *local, int rtnl_locked)
{
struct net_device *dev = local->dev;
printk(KERN_DEBUG "%s: disabling hostapd mode\n", dev->name);
hostap_remove_interface(local->stadev, rtnl_locked, 1);
local->stadev = NULL;
return 0;
}
| DoS | 0 | static int hostap_disable_hostapd_sta(local_info_t *local, int rtnl_locked)
{
struct net_device *dev = local->dev;
printk(KERN_DEBUG "%s: disabling hostapd mode\n", dev->name);
hostap_remove_interface(local->stadev, rtnl_locked, 1);
local->stadev = NULL;
return 0;
}
| @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,260 | void hostap_dump_rx_header(const char *name, const struct hfa384x_rx_frame *rx)
{
u16 status, fc;
status = __le16_to_cpu(rx->status);
printk(KERN_DEBUG "%s: RX status=0x%04x (port=%d, type=%d, "
"fcserr=%d) silence=%d signal=%d rate=%d rxflow=%d; "
"jiffies=%ld\n",
name, status, (status >> ... | DoS | 0 | void hostap_dump_rx_header(const char *name, const struct hfa384x_rx_frame *rx)
{
u16 status, fc;
status = __le16_to_cpu(rx->status);
printk(KERN_DEBUG "%s: RX status=0x%04x (port=%d, type=%d, "
"fcserr=%d) silence=%d signal=%d rate=%d rxflow=%d; "
"jiffies=%ld\n",
name, status, (status >> ... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,261 | static int hostap_enable_hostapd(local_info_t *local, int rtnl_locked)
{
struct net_device *dev = local->dev;
if (local->apdev)
return -EEXIST;
printk(KERN_DEBUG "%s: enabling hostapd mode\n", dev->name);
local->apdev = hostap_add_interface(local, HOSTAP_INTERFACE_AP,
rtnl_locked, local->ddev->name,
... | DoS | 0 | static int hostap_enable_hostapd(local_info_t *local, int rtnl_locked)
{
struct net_device *dev = local->dev;
if (local->apdev)
return -EEXIST;
printk(KERN_DEBUG "%s: enabling hostapd mode\n", dev->name);
local->apdev = hostap_add_interface(local, HOSTAP_INTERFACE_AP,
rtnl_locked, local->ddev->name,
... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,262 | static int hostap_enable_hostapd_sta(local_info_t *local, int rtnl_locked)
{
struct net_device *dev = local->dev;
if (local->stadev)
return -EEXIST;
printk(KERN_DEBUG "%s: enabling hostapd STA mode\n", dev->name);
local->stadev = hostap_add_interface(local, HOSTAP_INTERFACE_STA,
rtnl_locked, local->d... | DoS | 0 | static int hostap_enable_hostapd_sta(local_info_t *local, int rtnl_locked)
{
struct net_device *dev = local->dev;
if (local->stadev)
return -EEXIST;
printk(KERN_DEBUG "%s: enabling hostapd STA mode\n", dev->name);
local->stadev = hostap_add_interface(local, HOSTAP_INTERFACE_STA,
rtnl_locked, local->d... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,263 | u16 hostap_get_porttype(local_info_t *local)
{
if (local->iw_mode == IW_MODE_ADHOC && local->pseudo_adhoc)
return HFA384X_PORTTYPE_PSEUDO_IBSS;
if (local->iw_mode == IW_MODE_ADHOC)
return HFA384X_PORTTYPE_IBSS;
if (local->iw_mode == IW_MODE_INFRA)
return HFA384X_PORTTYPE_BSS;
if (local->iw_mode == IW_MODE_REP... | DoS | 0 | u16 hostap_get_porttype(local_info_t *local)
{
if (local->iw_mode == IW_MODE_ADHOC && local->pseudo_adhoc)
return HFA384X_PORTTYPE_PSEUDO_IBSS;
if (local->iw_mode == IW_MODE_ADHOC)
return HFA384X_PORTTYPE_IBSS;
if (local->iw_mode == IW_MODE_INFRA)
return HFA384X_PORTTYPE_BSS;
if (local->iw_mode == IW_MODE_REP... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,264 | static int __init hostap_init(void)
{
if (init_net.proc_net != NULL) {
hostap_proc = proc_mkdir("hostap", init_net.proc_net);
if (!hostap_proc)
printk(KERN_WARNING "Failed to mkdir "
"/proc/net/hostap\n");
} else
hostap_proc = NULL;
return 0;
}
| DoS | 0 | static int __init hostap_init(void)
{
if (init_net.proc_net != NULL) {
hostap_proc = proc_mkdir("hostap", init_net.proc_net);
if (!hostap_proc)
printk(KERN_WARNING "Failed to mkdir "
"/proc/net/hostap\n");
} else
hostap_proc = NULL;
return 0;
}
| @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,265 | void hostap_remove_interface(struct net_device *dev, int rtnl_locked,
int remove_from_list)
{
struct hostap_interface *iface;
if (!dev)
return;
iface = netdev_priv(dev);
if (remove_from_list) {
list_del(&iface->list);
}
if (dev == iface->local->ddev)
iface->local->ddev = NULL;
else if (dev == i... | DoS | 0 | void hostap_remove_interface(struct net_device *dev, int rtnl_locked,
int remove_from_list)
{
struct hostap_interface *iface;
if (!dev)
return;
iface = netdev_priv(dev);
if (remove_from_list) {
list_del(&iface->list);
}
if (dev == iface->local->ddev)
iface->local->ddev = NULL;
else if (dev == i... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,266 | int hostap_set_auth_algs(local_info_t *local)
{
int val = local->auth_algs;
/* At least STA f/w v0.6.2 seems to have issues with cnfAuthentication
* set to include both Open and Shared Key flags. It tries to use
* Shared Key authentication in that case even if WEP keys are not
* configured.. STA f/w v0.7.6 is a... | DoS | 0 | int hostap_set_auth_algs(local_info_t *local)
{
int val = local->auth_algs;
/* At least STA f/w v0.6.2 seems to have issues with cnfAuthentication
* set to include both Open and Shared Key flags. It tries to use
* Shared Key authentication in that case even if WEP keys are not
* configured.. STA f/w v0.7.6 is a... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,267 | int hostap_set_encryption(local_info_t *local)
{
u16 val, old_val;
int i, keylen, len, idx;
char keybuf[WEP_KEY_LEN + 1];
enum { NONE, WEP, OTHER } encrypt_type;
idx = local->crypt_info.tx_keyidx;
if (local->crypt_info.crypt[idx] == NULL ||
local->crypt_info.crypt[idx]->ops == NULL)
encrypt_type = NONE;
... | DoS | 0 | int hostap_set_encryption(local_info_t *local)
{
u16 val, old_val;
int i, keylen, len, idx;
char keybuf[WEP_KEY_LEN + 1];
enum { NONE, WEP, OTHER } encrypt_type;
idx = local->crypt_info.tx_keyidx;
if (local->crypt_info.crypt[idx] == NULL ||
local->crypt_info.crypt[idx]->ops == NULL)
encrypt_type = NONE;
... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,268 | int hostap_set_hostapd(local_info_t *local, int val, int rtnl_locked)
{
int ret;
if (val < 0 || val > 1)
return -EINVAL;
if (local->hostapd == val)
return 0;
if (val) {
ret = hostap_enable_hostapd(local, rtnl_locked);
if (ret == 0)
local->hostapd = 1;
} else {
local->hostapd = 0;
ret = hostap_dis... | DoS | 0 | int hostap_set_hostapd(local_info_t *local, int val, int rtnl_locked)
{
int ret;
if (val < 0 || val > 1)
return -EINVAL;
if (local->hostapd == val)
return 0;
if (val) {
ret = hostap_enable_hostapd(local, rtnl_locked);
if (ret == 0)
local->hostapd = 1;
} else {
local->hostapd = 0;
ret = hostap_dis... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,269 | int hostap_set_hostapd_sta(local_info_t *local, int val, int rtnl_locked)
{
int ret;
if (val < 0 || val > 1)
return -EINVAL;
if (local->hostapd_sta == val)
return 0;
if (val) {
ret = hostap_enable_hostapd_sta(local, rtnl_locked);
if (ret == 0)
local->hostapd_sta = 1;
} else {
local->hostapd_sta = 0... | DoS | 0 | int hostap_set_hostapd_sta(local_info_t *local, int val, int rtnl_locked)
{
int ret;
if (val < 0 || val > 1)
return -EINVAL;
if (local->hostapd_sta == val)
return 0;
if (val) {
ret = hostap_enable_hostapd_sta(local, rtnl_locked);
if (ret == 0)
local->hostapd_sta = 1;
} else {
local->hostapd_sta = 0... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,270 | void hostap_set_multicast_list_queue(struct work_struct *work)
{
local_info_t *local =
container_of(work, local_info_t, set_multicast_list_queue);
struct net_device *dev = local->dev;
if (hostap_set_word(dev, HFA384X_RID_PROMISCUOUSMODE,
local->is_promisc)) {
printk(KERN_INFO "%s: %sabling promiscuous mo... | DoS | 0 | void hostap_set_multicast_list_queue(struct work_struct *work)
{
local_info_t *local =
container_of(work, local_info_t, set_multicast_list_queue);
struct net_device *dev = local->dev;
if (hostap_set_word(dev, HFA384X_RID_PROMISCUOUSMODE,
local->is_promisc)) {
printk(KERN_INFO "%s: %sabling promiscuous mo... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,271 | int hostap_set_roaming(local_info_t *local)
{
u16 val;
switch (local->host_roaming) {
case 1:
val = HFA384X_ROAMING_HOST;
break;
case 2:
val = HFA384X_ROAMING_DISABLED;
break;
case 0:
default:
val = HFA384X_ROAMING_FIRMWARE;
break;
}
return hostap_set_word(local->dev, HFA384X_RID_CNFROAMINGMODE, v... | DoS | 0 | int hostap_set_roaming(local_info_t *local)
{
u16 val;
switch (local->host_roaming) {
case 1:
val = HFA384X_ROAMING_HOST;
break;
case 2:
val = HFA384X_ROAMING_DISABLED;
break;
case 0:
default:
val = HFA384X_ROAMING_FIRMWARE;
break;
}
return hostap_set_word(local->dev, HFA384X_RID_CNFROAMINGMODE, v... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,272 | int hostap_set_string(struct net_device *dev, int rid, const char *val)
{
struct hostap_interface *iface;
char buf[MAX_SSID_LEN + 2];
int len;
iface = netdev_priv(dev);
len = strlen(val);
if (len > MAX_SSID_LEN)
return -1;
memset(buf, 0, sizeof(buf));
buf[0] = len; /* little endian 16 bit word */
memcpy(buf... | DoS | 0 | int hostap_set_string(struct net_device *dev, int rid, const char *val)
{
struct hostap_interface *iface;
char buf[MAX_SSID_LEN + 2];
int len;
iface = netdev_priv(dev);
len = strlen(val);
if (len > MAX_SSID_LEN)
return -1;
memset(buf, 0, sizeof(buf));
buf[0] = len; /* little endian 16 bit word */
memcpy(buf... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,273 | int hostap_set_word(struct net_device *dev, int rid, u16 val)
{
struct hostap_interface *iface;
__le16 tmp = cpu_to_le16(val);
iface = netdev_priv(dev);
return iface->local->func->set_rid(dev, rid, &tmp, 2);
}
| DoS | 0 | int hostap_set_word(struct net_device *dev, int rid, u16 val)
{
struct hostap_interface *iface;
__le16 tmp = cpu_to_le16(val);
iface = netdev_priv(dev);
return iface->local->func->set_rid(dev, rid, &tmp, 2);
}
| @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,274 | u16 hostap_tx_callback_register(local_info_t *local,
void (*func)(struct sk_buff *, int ok, void *),
void *data)
{
unsigned long flags;
struct hostap_tx_callback_info *entry;
entry = kmalloc(sizeof(*entry),
GFP_ATOMIC);
if (entry == NULL)
return 0;
entry->func = func;
entry->data = data;
s... | DoS | 0 | u16 hostap_tx_callback_register(local_info_t *local,
void (*func)(struct sk_buff *, int ok, void *),
void *data)
{
unsigned long flags;
struct hostap_tx_callback_info *entry;
entry = kmalloc(sizeof(*entry),
GFP_ATOMIC);
if (entry == NULL)
return 0;
entry->func = func;
entry->data = data;
s... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,275 | static int prism2_change_mtu(struct net_device *dev, int new_mtu)
{
if (new_mtu < PRISM2_MIN_MTU || new_mtu > PRISM2_MAX_MTU)
return -EINVAL;
dev->mtu = new_mtu;
return 0;
}
| DoS | 0 | static int prism2_change_mtu(struct net_device *dev, int new_mtu)
{
if (new_mtu < PRISM2_MIN_MTU || new_mtu > PRISM2_MAX_MTU)
return -EINVAL;
dev->mtu = new_mtu;
return 0;
}
| @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,276 | static int prism2_close(struct net_device *dev)
{
struct hostap_interface *iface;
local_info_t *local;
PDEBUG(DEBUG_FLOW, "%s: prism2_close\n", dev->name);
iface = netdev_priv(dev);
local = iface->local;
if (dev == local->ddev) {
prism2_sta_deauth(local, WLAN_REASON_DEAUTH_LEAVING);
}
#ifndef PRISM2_NO_KERN... | DoS | 0 | static int prism2_close(struct net_device *dev)
{
struct hostap_interface *iface;
local_info_t *local;
PDEBUG(DEBUG_FLOW, "%s: prism2_close\n", dev->name);
iface = netdev_priv(dev);
local = iface->local;
if (dev == local->ddev) {
prism2_sta_deauth(local, WLAN_REASON_DEAUTH_LEAVING);
}
#ifndef PRISM2_NO_KERN... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,277 | static int prism2_open(struct net_device *dev)
{
struct hostap_interface *iface;
local_info_t *local;
PDEBUG(DEBUG_FLOW, "%s: prism2_open\n", dev->name);
iface = netdev_priv(dev);
local = iface->local;
if (local->no_pri) {
printk(KERN_DEBUG "%s: could not set interface UP - no PRI "
"f/w\n", dev->na... | DoS | 0 | static int prism2_open(struct net_device *dev)
{
struct hostap_interface *iface;
local_info_t *local;
PDEBUG(DEBUG_FLOW, "%s: prism2_open\n", dev->name);
iface = netdev_priv(dev);
local = iface->local;
if (local->no_pri) {
printk(KERN_DEBUG "%s: could not set interface UP - no PRI "
"f/w\n", dev->na... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,278 | static int prism2_set_mac_address(struct net_device *dev, void *p)
{
struct hostap_interface *iface;
local_info_t *local;
struct list_head *ptr;
struct sockaddr *addr = p;
iface = netdev_priv(dev);
local = iface->local;
if (local->func->set_rid(dev, HFA384X_RID_CNFOWNMACADDR, addr->sa_data,
ETH_ALEN) < 0 ... | DoS | 0 | static int prism2_set_mac_address(struct net_device *dev, void *p)
{
struct hostap_interface *iface;
local_info_t *local;
struct list_head *ptr;
struct sockaddr *addr = p;
iface = netdev_priv(dev);
local = iface->local;
if (local->func->set_rid(dev, HFA384X_RID_CNFOWNMACADDR, addr->sa_data,
ETH_ALEN) < 0 ... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,279 | int prism2_sta_send_mgmt(local_info_t *local, u8 *dst, u16 stype,
u8 *body, size_t bodylen)
{
struct sk_buff *skb;
struct hostap_ieee80211_mgmt *mgmt;
struct hostap_skb_tx_data *meta;
struct net_device *dev = local->dev;
skb = dev_alloc_skb(IEEE80211_MGMT_HDR_LEN + bodylen);
if (skb == NULL)
return -ENOMEM... | DoS | 0 | int prism2_sta_send_mgmt(local_info_t *local, u8 *dst, u16 stype,
u8 *body, size_t bodylen)
{
struct sk_buff *skb;
struct hostap_ieee80211_mgmt *mgmt;
struct hostap_skb_tx_data *meta;
struct net_device *dev = local->dev;
skb = dev_alloc_skb(IEEE80211_MGMT_HDR_LEN + bodylen);
if (skb == NULL)
return -ENOMEM... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,280 | static void prism2_tx_timeout(struct net_device *dev)
{
struct hostap_interface *iface;
local_info_t *local;
struct hfa384x_regs regs;
iface = netdev_priv(dev);
local = iface->local;
printk(KERN_WARNING "%s Tx timed out! Resetting card\n", dev->name);
netif_stop_queue(local->dev);
local->func->read_regs(dev,... | DoS | 0 | static void prism2_tx_timeout(struct net_device *dev)
{
struct hostap_interface *iface;
local_info_t *local;
struct hfa384x_regs regs;
iface = netdev_priv(dev);
local = iface->local;
printk(KERN_WARNING "%s Tx timed out! Resetting card\n", dev->name);
netif_stop_queue(local->dev);
local->func->read_regs(dev,... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,281 | int prism2_wds_add(local_info_t *local, u8 *remote_addr,
int rtnl_locked)
{
struct net_device *dev;
struct list_head *ptr;
struct hostap_interface *iface, *empty, *match;
empty = match = NULL;
read_lock_bh(&local->iface_lock);
list_for_each(ptr, &local->hostap_interfaces) {
iface = list_entry(ptr, struct ... | DoS | 0 | int prism2_wds_add(local_info_t *local, u8 *remote_addr,
int rtnl_locked)
{
struct net_device *dev;
struct list_head *ptr;
struct hostap_interface *iface, *empty, *match;
empty = match = NULL;
read_lock_bh(&local->iface_lock);
list_for_each(ptr, &local->hostap_interfaces) {
iface = list_entry(ptr, struct ... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,282 | int prism2_wds_del(local_info_t *local, u8 *remote_addr,
int rtnl_locked, int do_not_remove)
{
unsigned long flags;
struct list_head *ptr;
struct hostap_interface *iface, *selected = NULL;
write_lock_irqsave(&local->iface_lock, flags);
list_for_each(ptr, &local->hostap_interfaces) {
iface = list_entry(ptr,... | DoS | 0 | int prism2_wds_del(local_info_t *local, u8 *remote_addr,
int rtnl_locked, int do_not_remove)
{
unsigned long flags;
struct list_head *ptr;
struct hostap_interface *iface, *selected = NULL;
write_lock_irqsave(&local->iface_lock, flags);
list_for_each(ptr, &local->hostap_interfaces) {
iface = list_entry(ptr,... | @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,283 | static inline int prism2_wds_special_addr(u8 *addr)
{
if (addr[0] || addr[1] || addr[2] || addr[3] || addr[4] || addr[5])
return 0;
return 1;
}
| DoS | 0 | static inline int prism2_wds_special_addr(u8 *addr)
{
if (addr[0] || addr[1] || addr[2] || addr[3] || addr[4] || addr[5])
return 0;
return 1;
}
| @@ -855,6 +855,7 @@ void hostap_setup_dev(struct net_device *dev, local_info_t *local,
iface = netdev_priv(dev);
ether_setup(dev);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
/* kernel callbacks */
if (iface) { | CWE-264 | null | null |
19,284 | static void DoHTCSendPktsTest(struct ar6_softc *ar, int MapNo, HTC_ENDPOINT_ID eid, struct sk_buff *dupskb)
{
struct ar_cookie *cookie;
struct ar_cookie *cookieArray[HTC_TEST_DUPLICATE];
struct sk_buff *new_skb;
int i;
int pkts = 0;
struct htc_packet_queue pktQueue;
EPPING_HEADER ... | DoS | 0 | static void DoHTCSendPktsTest(struct ar6_softc *ar, int MapNo, HTC_ENDPOINT_ID eid, struct sk_buff *dupskb)
{
struct ar_cookie *cookie;
struct ar_cookie *cookieArray[HTC_TEST_DUPLICATE];
struct sk_buff *new_skb;
int i;
int pkts = 0;
struct htc_packet_queue pktQueue;
EPPING_HEADER ... | @@ -6179,6 +6179,7 @@ int ar6000_create_ap_interface(struct ar6_softc *ar, char *ap_ifname)
ether_setup(dev);
init_netdev(dev, ap_ifname);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
if (register_netdev(dev)) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("ar6000_create_ap_interface: register_netdev ... | CWE-264 | null | null |
19,285 | u32 a_copy_from_user(void *to, const void *from, u32 n)
{
return(copy_from_user(to, from, n));
}
| DoS | 0 | u32 a_copy_from_user(void *to, const void *from, u32 n)
{
return(copy_from_user(to, from, n));
}
| @@ -6179,6 +6179,7 @@ int ar6000_create_ap_interface(struct ar6_softc *ar, char *ap_ifname)
ether_setup(dev);
init_netdev(dev, ap_ifname);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
if (register_netdev(dev)) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("ar6000_create_ap_interface: register_netdev ... | CWE-264 | null | null |
19,286 | u32 a_copy_to_user(void *to, const void *from, u32 n)
{
return(copy_to_user(to, from, n));
}
| DoS | 0 | u32 a_copy_to_user(void *to, const void *from, u32 n)
{
return(copy_to_user(to, from, n));
}
| @@ -6179,6 +6179,7 @@ int ar6000_create_ap_interface(struct ar6_softc *ar, char *ap_ifname)
ether_setup(dev);
init_netdev(dev, ap_ifname);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
if (register_netdev(dev)) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("ar6000_create_ap_interface: register_netdev ... | CWE-264 | null | null |
19,287 | add_new_sta(struct ar6_softc *ar, u8 *mac, u16 aid, u8 *wpaie,
u8 ielen, u8 keymgmt, u8 ucipher, u8 auth)
{
u8 free_slot=aid-1;
memcpy(ar->sta_list[free_slot].mac, mac, ATH_MAC_LEN);
memcpy(ar->sta_list[free_slot].wpa_ie, wpaie, ielen);
ar->sta_list[free_slot].aid = aid;
... | DoS | 0 | add_new_sta(struct ar6_softc *ar, u8 *mac, u16 aid, u8 *wpaie,
u8 ielen, u8 keymgmt, u8 ucipher, u8 auth)
{
u8 free_slot=aid-1;
memcpy(ar->sta_list[free_slot].mac, mac, ATH_MAC_LEN);
memcpy(ar->sta_list[free_slot].wpa_ie, wpaie, ielen);
ar->sta_list[free_slot].aid = aid;
... | @@ -6179,6 +6179,7 @@ int ar6000_create_ap_interface(struct ar6_softc *ar, char *ap_ifname)
ether_setup(dev);
init_netdev(dev, ap_ifname);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
if (register_netdev(dev)) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("ar6000_create_ap_interface: register_netdev ... | CWE-264 | null | null |
19,288 | ap_set_wapi_key(struct ar6_softc *ar, void *ikey)
{
struct ieee80211req_key *ik = (struct ieee80211req_key *)ikey;
KEY_USAGE keyUsage = 0;
int status;
if (memcmp(ik->ik_macaddr, bcast_mac, IEEE80211_ADDR_LEN) == 0) {
keyUsage = GROUP_USAGE;
} else {
keyUsage = PAIRWISE_USAGE;
... | DoS | 0 | ap_set_wapi_key(struct ar6_softc *ar, void *ikey)
{
struct ieee80211req_key *ik = (struct ieee80211req_key *)ikey;
KEY_USAGE keyUsage = 0;
int status;
if (memcmp(ik->ik_macaddr, bcast_mac, IEEE80211_ADDR_LEN) == 0) {
keyUsage = GROUP_USAGE;
} else {
keyUsage = PAIRWISE_USAGE;
... | @@ -6179,6 +6179,7 @@ int ar6000_create_ap_interface(struct ar6_softc *ar, char *ap_ifname)
ether_setup(dev);
init_netdev(dev, ap_ifname);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
if (register_netdev(dev)) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("ar6000_create_ap_interface: register_netdev ... | CWE-264 | null | null |
19,289 | void ap_wapi_rekey_event(struct ar6_softc *ar, u8 type, u8 *mac)
{
union iwreq_data wrqu;
char buf[20];
A_MEMZERO(buf, sizeof(buf));
strcpy(buf, "WAPI_REKEY");
buf[10] = type;
memcpy(&buf[11], mac, ATH_MAC_LEN);
A_MEMZERO(&wrqu, sizeof(wrqu));
wrqu.data.length = 10+1+ATH_MAC_LEN;
... | DoS | 0 | void ap_wapi_rekey_event(struct ar6_softc *ar, u8 type, u8 *mac)
{
union iwreq_data wrqu;
char buf[20];
A_MEMZERO(buf, sizeof(buf));
strcpy(buf, "WAPI_REKEY");
buf[10] = type;
memcpy(&buf[11], mac, ATH_MAC_LEN);
A_MEMZERO(&wrqu, sizeof(wrqu));
wrqu.data.length = 10+1+ATH_MAC_LEN;
... | @@ -6179,6 +6179,7 @@ int ar6000_create_ap_interface(struct ar6_softc *ar, char *ap_ifname)
ether_setup(dev);
init_netdev(dev, ap_ifname);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
if (register_netdev(dev)) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("ar6000_create_ap_interface: register_netdev ... | CWE-264 | null | null |
19,290 | applyAPTCHeuristics(struct ar6_softc *ar)
{
u32 duration;
u32 numbytes;
u32 throughput;
struct timeval ts;
int status;
AR6000_SPIN_LOCK(&ar->arLock, 0);
if ((enableAPTCHeuristics) && (!aptcTR.timerScheduled)) {
do_gettimeofday(&ts);
tvsub(&ts, &aptcTR.samplingTS);
d... | DoS | 0 | applyAPTCHeuristics(struct ar6_softc *ar)
{
u32 duration;
u32 numbytes;
u32 throughput;
struct timeval ts;
int status;
AR6000_SPIN_LOCK(&ar->arLock, 0);
if ((enableAPTCHeuristics) && (!aptcTR.timerScheduled)) {
do_gettimeofday(&ts);
tvsub(&ts, &aptcTR.samplingTS);
d... | @@ -6179,6 +6179,7 @@ int ar6000_create_ap_interface(struct ar6_softc *ar, char *ap_ifname)
ether_setup(dev);
init_netdev(dev, ap_ifname);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
if (register_netdev(dev)) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("ar6000_create_ap_interface: register_netdev ... | CWE-264 | null | null |
19,291 | aptcTimerHandler(unsigned long arg)
{
u32 numbytes;
u32 throughput;
struct ar6_softc *ar;
int status;
ar = (struct ar6_softc *)arg;
A_ASSERT(ar != NULL);
A_ASSERT(!timer_pending(&aptcTimer));
AR6000_SPIN_LOCK(&ar->arLock, 0);
/* Get the number of bytes transferred */
numbytes ... | DoS | 0 | aptcTimerHandler(unsigned long arg)
{
u32 numbytes;
u32 throughput;
struct ar6_softc *ar;
int status;
ar = (struct ar6_softc *)arg;
A_ASSERT(ar != NULL);
A_ASSERT(!timer_pending(&aptcTimer));
AR6000_SPIN_LOCK(&ar->arLock, 0);
/* Get the number of bytes transferred */
numbytes ... | @@ -6179,6 +6179,7 @@ int ar6000_create_ap_interface(struct ar6_softc *ar, char *ap_ifname)
ether_setup(dev);
init_netdev(dev, ap_ifname);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
if (register_netdev(dev)) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("ar6000_create_ap_interface: register_netdev ... | CWE-264 | null | null |
19,292 | ar6000_ac2_endpoint_id ( void * devt, u8 ac)
{
struct ar6_softc *ar = (struct ar6_softc *) devt;
return(arAc2EndpointID(ar, ac));
}
| DoS | 0 | ar6000_ac2_endpoint_id ( void * devt, u8 ac)
{
struct ar6_softc *ar = (struct ar6_softc *) devt;
return(arAc2EndpointID(ar, ac));
}
| @@ -6179,6 +6179,7 @@ int ar6000_create_ap_interface(struct ar6_softc *ar, char *ap_ifname)
ether_setup(dev);
init_netdev(dev, ap_ifname);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
if (register_netdev(dev)) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("ar6000_create_ap_interface: register_netdev ... | CWE-264 | null | null |
19,293 | ar6000_aggr_rcv_addba_req_evt(struct ar6_softc *ar, WMI_ADDBA_REQ_EVENT *evt)
{
if(evt->status == 0) {
aggr_recv_addba_req_evt(ar->aggr_cntxt, evt->tid, evt->st_seq_no, evt->win_sz);
}
}
| DoS | 0 | ar6000_aggr_rcv_addba_req_evt(struct ar6_softc *ar, WMI_ADDBA_REQ_EVENT *evt)
{
if(evt->status == 0) {
aggr_recv_addba_req_evt(ar->aggr_cntxt, evt->tid, evt->st_seq_no, evt->win_sz);
}
}
| @@ -6179,6 +6179,7 @@ int ar6000_create_ap_interface(struct ar6_softc *ar, char *ap_ifname)
ether_setup(dev);
init_netdev(dev, ap_ifname);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
if (register_netdev(dev)) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("ar6000_create_ap_interface: register_netdev ... | CWE-264 | null | null |
19,294 | ar6000_aggr_rcv_delba_req_evt(struct ar6_softc *ar, WMI_DELBA_EVENT *evt)
{
aggr_recv_delba_req_evt(ar->aggr_cntxt, evt->tid);
}
| DoS | 0 | ar6000_aggr_rcv_delba_req_evt(struct ar6_softc *ar, WMI_DELBA_EVENT *evt)
{
aggr_recv_delba_req_evt(ar->aggr_cntxt, evt->tid);
}
| @@ -6179,6 +6179,7 @@ int ar6000_create_ap_interface(struct ar6_softc *ar, char *ap_ifname)
ether_setup(dev);
init_netdev(dev, ap_ifname);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
if (register_netdev(dev)) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("ar6000_create_ap_interface: register_netdev ... | CWE-264 | null | null |
19,295 | static struct htc_packet *ar6000_alloc_amsdu_rxbuf(void *Context, HTC_ENDPOINT_ID Endpoint, int Length)
{
struct htc_packet *pPacket = NULL;
struct ar6_softc *ar = (struct ar6_softc *)Context;
int refillCount = 0;
AR_DEBUG_PRINTF(ATH_DEBUG_WLAN_RX,("ar6000_alloc_amsdu_rxbuf: eid=%d, Length:%d... | DoS | 0 | static struct htc_packet *ar6000_alloc_amsdu_rxbuf(void *Context, HTC_ENDPOINT_ID Endpoint, int Length)
{
struct htc_packet *pPacket = NULL;
struct ar6_softc *ar = (struct ar6_softc *)Context;
int refillCount = 0;
AR_DEBUG_PRINTF(ATH_DEBUG_WLAN_RX,("ar6000_alloc_amsdu_rxbuf: eid=%d, Length:%d... | @@ -6179,6 +6179,7 @@ int ar6000_create_ap_interface(struct ar6_softc *ar, char *ap_ifname)
ether_setup(dev);
init_netdev(dev, ap_ifname);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
if (register_netdev(dev)) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("ar6000_create_ap_interface: register_netdev ... | CWE-264 | null | null |
19,296 | ar6000_alloc_cookie(struct ar6_softc *ar)
{
struct ar_cookie *cookie;
cookie = ar->arCookieList;
if(cookie != NULL)
{
ar->arCookieList = cookie->arc_list_next;
ar->arCookieCount--;
}
return cookie;
}
| DoS | 0 | ar6000_alloc_cookie(struct ar6_softc *ar)
{
struct ar_cookie *cookie;
cookie = ar->arCookieList;
if(cookie != NULL)
{
ar->arCookieList = cookie->arc_list_next;
ar->arCookieCount--;
}
return cookie;
}
| @@ -6179,6 +6179,7 @@ int ar6000_create_ap_interface(struct ar6_softc *ar, char *ap_ifname)
ether_setup(dev);
init_netdev(dev, ap_ifname);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
if (register_netdev(dev)) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("ar6000_create_ap_interface: register_netdev ... | CWE-264 | null | null |
19,297 | ar6000_alloc_netbufs(A_NETBUF_QUEUE_T *q, u16 num)
{
void * osbuf;
while(num) {
if((osbuf = A_NETBUF_ALLOC(AR6000_BUFFER_SIZE))) {
A_NETBUF_ENQUEUE(q, osbuf);
} else {
break;
}
num--;
}
if(num) {
A_PRINTF("%s(), allocation of netbuf faile... | DoS | 0 | ar6000_alloc_netbufs(A_NETBUF_QUEUE_T *q, u16 num)
{
void * osbuf;
while(num) {
if((osbuf = A_NETBUF_ALLOC(AR6000_BUFFER_SIZE))) {
A_NETBUF_ENQUEUE(q, osbuf);
} else {
break;
}
num--;
}
if(num) {
A_PRINTF("%s(), allocation of netbuf faile... | @@ -6179,6 +6179,7 @@ int ar6000_create_ap_interface(struct ar6_softc *ar, char *ap_ifname)
ether_setup(dev);
init_netdev(dev, ap_ifname);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
if (register_netdev(dev)) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("ar6000_create_ap_interface: register_netdev ... | CWE-264 | null | null |
19,298 | ar6000_ap_mode_profile_commit(struct ar6_softc *ar)
{
WMI_CONNECT_CMD p;
unsigned long flags;
/* No change in AP's profile configuration */
if(ar->ap_profile_flag==0) {
A_PRINTF("COMMIT: No change in profile!!!\n");
return -ENODATA;
}
if(!ar->arSsidLen) {
A_PRINTF("SSI... | DoS | 0 | ar6000_ap_mode_profile_commit(struct ar6_softc *ar)
{
WMI_CONNECT_CMD p;
unsigned long flags;
/* No change in AP's profile configuration */
if(ar->ap_profile_flag==0) {
A_PRINTF("COMMIT: No change in profile!!!\n");
return -ENODATA;
}
if(!ar->arSsidLen) {
A_PRINTF("SSI... | @@ -6179,6 +6179,7 @@ int ar6000_create_ap_interface(struct ar6_softc *ar, char *ap_ifname)
ether_setup(dev);
init_netdev(dev, ap_ifname);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
if (register_netdev(dev)) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("ar6000_create_ap_interface: register_netdev ... | CWE-264 | null | null |
19,299 | ar6000_avail_ev(void *context, void *hif_handle)
{
int i;
struct net_device *dev;
void *ar_netif;
struct ar6_softc *ar;
int device_index = 0;
struct htc_init_info htcInfo;
struct wireless_dev *wdev;
int r = 0;
struct hif_device_os_device_info osDevInfo;
memset(&osDevInfo, 0, si... | DoS | 0 | ar6000_avail_ev(void *context, void *hif_handle)
{
int i;
struct net_device *dev;
void *ar_netif;
struct ar6_softc *ar;
int device_index = 0;
struct htc_init_info htcInfo;
struct wireless_dev *wdev;
int r = 0;
struct hif_device_os_device_info osDevInfo;
memset(&osDevInfo, 0, si... | @@ -6179,6 +6179,7 @@ int ar6000_create_ap_interface(struct ar6_softc *ar, char *ap_ifname)
ether_setup(dev);
init_netdev(dev, ap_ifname);
+ dev->priv_flags &= ~IFF_TX_SKB_SHARING;
if (register_netdev(dev)) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("ar6000_create_ap_interface: register_netdev ... | CWE-264 | null | null |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.