Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 208146
b: refs/heads/master
c: da48db6
h: refs/heads/master
v: v3
  • Loading branch information
Jarod Wilson authored and Mauro Carvalho Chehab committed Aug 9, 2010
1 parent 9581da4 commit 091aa07
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 16 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: 20cd19597238723237d214dbab18c0b7c68c5814
refs/heads/master: da48db669f50d47c208da3648dca7cac7ea6dcca
15 changes: 0 additions & 15 deletions trunk/drivers/media/IR/imon.c
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,6 @@ static ssize_t lcd_write(struct file *file, const char *buf,
struct imon_context {
struct device *dev;
struct ir_dev_props *props;
struct ir_input_dev *ir;
/* Newer devices have two interfaces */
struct usb_device *usbdev_intf0;
struct usb_device *usbdev_intf1;
Expand Down Expand Up @@ -1656,7 +1655,6 @@ static struct input_dev *imon_init_idev(struct imon_context *ictx)
{
struct input_dev *idev;
struct ir_dev_props *props;
struct ir_input_dev *ir;
int ret, i;

idev = input_allocate_device();
Expand All @@ -1671,12 +1669,6 @@ static struct input_dev *imon_init_idev(struct imon_context *ictx)
goto props_alloc_failed;
}

ir = kzalloc(sizeof(struct ir_input_dev), GFP_KERNEL);
if (!ir) {
dev_err(ictx->dev, "remote ir input dev allocation failed\n");
goto ir_dev_alloc_failed;
}

snprintf(ictx->name_idev, sizeof(ictx->name_idev),
"iMON Remote (%04x:%04x)", ictx->vendor, ictx->product);
idev->name = ictx->name_idev;
Expand Down Expand Up @@ -1706,14 +1698,9 @@ static struct input_dev *imon_init_idev(struct imon_context *ictx)
props->change_protocol = imon_ir_change_protocol;
ictx->props = props;

ictx->ir = ir;
memcpy(&ir->dev, ictx->dev, sizeof(struct device));

usb_to_input_id(ictx->usbdev_intf0, &idev->id);
idev->dev.parent = ictx->dev;

input_set_drvdata(idev, ir);

ret = ir_input_register(idev, RC_MAP_IMON_PAD, props, MOD_NAME);
if (ret < 0) {
dev_err(ictx->dev, "remote input dev register failed\n");
Expand All @@ -1723,8 +1710,6 @@ static struct input_dev *imon_init_idev(struct imon_context *ictx)
return idev;

idev_register_failed:
kfree(ir);
ir_dev_alloc_failed:
kfree(props);
props_alloc_failed:
input_free_device(idev);
Expand Down

0 comments on commit 091aa07

Please sign in to comment.