Skip to content

Commit

Permalink
[ATM]: Suppress some sparse warnings
Browse files Browse the repository at this point in the history
  CHECK   net/atm/br2684.c
net/atm/br2684.c:665:13: warning: context imbalance in 'br2684_seq_start' - wrong count at exit
net/atm/br2684.c:676:13: warning: context imbalance in 'br2684_seq_stop' - unexpected unlock
  CHECK   net/atm/lec.c
net/atm/lec.c:196:23: warning: expensive signed divide
  CHECK   net/atm/proc.c
net/atm/proc.c:151:14: warning: context imbalance in 'vcc_seq_start' - wrong count at exit
net/atm/proc.c:154:13: warning: context imbalance in 'vcc_seq_stop' - unexpected unlock

Signed-off-by: Eric Dumazet <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
Eric Dumazet authored and davem330 committed Jan 28, 2008
1 parent ca629f2 commit 5c17d5f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
2 changes: 2 additions & 0 deletions net/atm/br2684.c
Original file line number Diff line number Diff line change
Expand Up @@ -663,6 +663,7 @@ static struct atm_ioctl br2684_ioctl_ops = {

#ifdef CONFIG_PROC_FS
static void *br2684_seq_start(struct seq_file *seq, loff_t * pos)
__acquires(devs_lock)
{
read_lock(&devs_lock);
return seq_list_start(&br2684_devs, *pos);
Expand All @@ -674,6 +675,7 @@ static void *br2684_seq_next(struct seq_file *seq, void *v, loff_t * pos)
}

static void br2684_seq_stop(struct seq_file *seq, void *v)
__releases(devs_lock)
{
read_unlock(&devs_lock);
}
Expand Down
2 changes: 1 addition & 1 deletion net/atm/lec.c
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ static void lec_handle_bridge(struct sk_buff *skb, struct net_device *dev)
static unsigned char *get_tr_dst(unsigned char *packet, unsigned char *rdesc)
{
struct trh_hdr *trh;
int riflen, num_rdsc;
unsigned int riflen, num_rdsc;

trh = (struct trh_hdr *)packet;
if (trh->daddr[0] & (uint8_t) 0x80)
Expand Down
2 changes: 2 additions & 0 deletions net/atm/proc.c
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@ static int vcc_seq_release(struct inode *inode, struct file *file)
}

static void *vcc_seq_start(struct seq_file *seq, loff_t *pos)
__acquires(vcc_sklist_lock)
{
struct vcc_state *state = seq->private;
loff_t left = *pos;
Expand All @@ -152,6 +153,7 @@ static void *vcc_seq_start(struct seq_file *seq, loff_t *pos)
}

static void vcc_seq_stop(struct seq_file *seq, void *v)
__releases(vcc_sklist_lock)
{
read_unlock(&vcc_sklist_lock);
}
Expand Down

0 comments on commit 5c17d5f

Please sign in to comment.