Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 268662
b: refs/heads/master
c: 5cd4d03
h: refs/heads/master
v: v3
  • Loading branch information
K. Y. Srinivasan authored and Greg Kroah-Hartman committed Oct 4, 2011
1 parent 8a36167 commit 05cd15d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 17 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: 0b1f0da005928c1cc761c320e6919b719a090a07
refs/heads/master: 5cd4d0302cc3a53b4fb48006d448f44f666f1569
23 changes: 7 additions & 16 deletions trunk/drivers/staging/hv/hv_mouse.c
Original file line number Diff line number Diff line change
Expand Up @@ -569,7 +569,7 @@ static int mousevsc_connect_to_vsp(struct hv_device *device)

if (!input_dev) {
pr_err("unable to get input device...device being destroyed?");
return -1;
return -ENODEV;
}


Expand Down Expand Up @@ -612,7 +612,7 @@ static int mousevsc_connect_to_vsp(struct hv_device *device)
if (!response->response.approved) {
pr_err("synthhid protocol request failed (version %d)",
SYNTHHID_INPUT_VERSION);
ret = -1;
ret = -ENODEV;
goto cleanup;
}

Expand All @@ -629,7 +629,7 @@ static int mousevsc_connect_to_vsp(struct hv_device *device)
if (!input_dev->dev_info_status)
pr_info("**** input channel up and running!! ****");
else
ret = -1;
ret = -ENOMEM;

cleanup:
put_input_device(device);
Expand Down Expand Up @@ -694,10 +694,8 @@ static int mousevsc_on_device_add(struct hv_device *device,

input_dev = alloc_input_device(device);

if (!input_dev) {
ret = -1;
goto cleanup;
}
if (!input_dev)
return -ENOMEM;

input_dev->init_complete = false;

Expand All @@ -714,7 +712,7 @@ static int mousevsc_on_device_add(struct hv_device *device,
if (ret != 0) {
pr_err("unable to open channel: %d", ret);
free_input_device(input_dev);
return -1;
return ret;
}

pr_info("InputVsc channel open: %d", ret);
Expand Down Expand Up @@ -743,7 +741,6 @@ static int mousevsc_on_device_add(struct hv_device *device,

input_dev->init_complete = true;

cleanup:
return ret;
}

Expand Down Expand Up @@ -789,16 +786,10 @@ static int mousevsc_on_device_remove(struct hv_device *device)
static int mousevsc_probe(struct hv_device *dev,
const struct hv_vmbus_device_id *dev_id)
{
int ret = 0;


/* Call to the vsc driver to add the device */
ret = mousevsc_on_device_add(dev, NULL);
return mousevsc_on_device_add(dev, NULL);

if (ret != 0)
return -1;

return 0;
}

static int mousevsc_remove(struct hv_device *dev)
Expand Down

0 comments on commit 05cd15d

Please sign in to comment.