Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 57919
b: refs/heads/master
c: dc5bc0c
h: refs/heads/master
i:
  57917: f447e14
  57915: 88ba2c9
  57911: 452327b
  57903: 62104d4
  57887: d65249b
  57855: 67805f9
v: v3
  • Loading branch information
Cornelia Huck authored and Jeff Garzik committed Jun 20, 2007
1 parent bd3e2c7 commit 1c32185
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 15 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: cd3e76ebcb41c48ef6e706006b793d45030bae75
refs/heads/master: dc5bc0cabd1003b4fa358f0d54dfdc46585efb57
13 changes: 8 additions & 5 deletions trunk/drivers/s390/net/claw.c
Original file line number Diff line number Diff line change
Expand Up @@ -3912,6 +3912,7 @@ static int
add_channel(struct ccw_device *cdev,int i,struct claw_privbk *privptr)
{
struct chbk *p_ch;
struct ccw_dev_id dev_id;

#ifdef FUNCTRACE
printk(KERN_INFO "%s:%s Enter\n",cdev->dev.bus_id,__FUNCTION__);
Expand All @@ -3921,7 +3922,8 @@ add_channel(struct ccw_device *cdev,int i,struct claw_privbk *privptr)
p_ch = &privptr->channel[i];
p_ch->cdev = cdev;
snprintf(p_ch->id, CLAW_ID_SIZE, "cl-%s", cdev->dev.bus_id);
sscanf(cdev->dev.bus_id+4,"%x",&p_ch->devno);
ccw_device_get_id(cdev, &dev_id);
p_ch->devno = dev_id.devno;
if ((p_ch->irb = kmalloc(sizeof (struct irb),GFP_KERNEL)) == NULL) {
printk(KERN_WARNING "%s Out of memory in %s for irb\n",
p_ch->id,__FUNCTION__);
Expand Down Expand Up @@ -3955,6 +3957,7 @@ claw_new_device(struct ccwgroup_device *cgdev)
struct claw_env *p_env;
struct net_device *dev;
int ret;
struct ccw_dev_id dev_id;

pr_debug("%s() called\n", __FUNCTION__);
printk(KERN_INFO "claw: add for %s\n",cgdev->cdev[READ]->dev.bus_id);
Expand All @@ -3965,10 +3968,10 @@ claw_new_device(struct ccwgroup_device *cgdev)
if (!privptr)
return -ENODEV;
p_env = privptr->p_env;
sscanf(cgdev->cdev[READ]->dev.bus_id+4,"%x",
&p_env->devno[READ]);
sscanf(cgdev->cdev[WRITE]->dev.bus_id+4,"%x",
&p_env->devno[WRITE]);
ccw_device_get_id(cgdev->cdev[READ], &dev_id);
p_env->devno[READ] = dev_id.devno;
ccw_device_get_id(cgdev->cdev[WRITE], &dev_id);
p_env->devno[WRITE] = dev_id.devno;
ret = add_channel(cgdev->cdev[0],0,privptr);
if (ret == 0)
ret = add_channel(cgdev->cdev[1],1,privptr);
Expand Down
12 changes: 3 additions & 9 deletions trunk/drivers/s390/net/qeth_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -2176,13 +2176,6 @@ qeth_ulp_enable(struct qeth_card *card)

}

static inline __u16
__raw_devno_from_bus_id(char *id)
{
id += (strlen(id) - 4);
return (__u16) simple_strtoul(id, &id, 16);
}

static int
qeth_ulp_setup_cb(struct qeth_card *card, struct qeth_reply *reply,
unsigned long data)
Expand All @@ -2205,6 +2198,7 @@ qeth_ulp_setup(struct qeth_card *card)
int rc;
__u16 temp;
struct qeth_cmd_buffer *iob;
struct ccw_dev_id dev_id;

QETH_DBF_TEXT(setup,2,"ulpsetup");

Expand All @@ -2218,8 +2212,8 @@ qeth_ulp_setup(struct qeth_card *card)
memcpy(QETH_ULP_SETUP_FILTER_TOKEN(iob->data),
&card->token.ulp_filter_r, QETH_MPC_TOKEN_LENGTH);

temp = __raw_devno_from_bus_id(CARD_DDEV_ID(card));
memcpy(QETH_ULP_SETUP_CUA(iob->data), &temp, 2);
ccw_device_get_id(CARD_DDEV(card), &dev_id);
memcpy(QETH_ULP_SETUP_CUA(iob->data), &dev_id.devno, 2);
temp = (card->info.cula << 8) + card->info.unit_addr2;
memcpy(QETH_ULP_SETUP_REAL_DEVADDR(iob->data), &temp, 2);
rc = qeth_send_control_data(card, ULP_SETUP_SIZE, iob,
Expand Down

0 comments on commit 1c32185

Please sign in to comment.