Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 211496
b: refs/heads/master
c: f1ee89d
h: refs/heads/master
v: v3
  • Loading branch information
Jiri Slaby authored and David S. Miller committed Oct 11, 2010
1 parent a0829fb commit 030f534
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 03c698c93fc15d976738a853a7ccb6ea26396003
refs/heads/master: f1ee89d5b007620353fb7dec1d34db4baa1a5571
8 changes: 5 additions & 3 deletions trunk/drivers/atm/solos-pci.c
Original file line number Diff line number Diff line change
Expand Up @@ -444,18 +444,20 @@ static ssize_t console_show(struct device *dev, struct device_attribute *attr,
struct atm_dev *atmdev = container_of(dev, struct atm_dev, class_dev);
struct solos_card *card = atmdev->dev_data;
struct sk_buff *skb;
unsigned int len;

spin_lock(&card->cli_queue_lock);
skb = skb_dequeue(&card->cli_queue[SOLOS_CHAN(atmdev)]);
spin_unlock(&card->cli_queue_lock);
if(skb == NULL)
return sprintf(buf, "No data.\n");

memcpy(buf, skb->data, skb->len);
dev_dbg(&card->dev->dev, "len: %d\n", skb->len);
len = skb->len;
memcpy(buf, skb->data, len);
dev_dbg(&card->dev->dev, "len: %d\n", len);

kfree_skb(skb);
return skb->len;
return len;
}

static int send_command(struct solos_card *card, int dev, const char *buf, size_t size)
Expand Down

0 comments on commit 030f534

Please sign in to comment.