Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 192902
b: refs/heads/master
c: e202c15
h: refs/heads/master
v: v3
  • Loading branch information
Mauro Carvalho Chehab committed May 18, 2010
1 parent 94239b2 commit 19c3205
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 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: d89b4bd2b47395339d5b5b6a7e28f91dd0d21b7b
refs/heads/master: e202c15b4209f05fe109dd396463a524f4c2d3d8
20 changes: 10 additions & 10 deletions trunk/drivers/media/IR/ir-sysfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,14 @@
/* bit array to represent IR sysfs device number */
static unsigned long ir_core_dev_number;

/* class for /sys/class/irrcv */
/* class for /sys/class/rc */
static char *ir_devnode(struct device *dev, mode_t *mode)
{
return kasprintf(GFP_KERNEL, "irrcv/%s", dev_name(dev));
return kasprintf(GFP_KERNEL, "rc/%s", dev_name(dev));
}

static struct class ir_input_class = {
.name = "irrcv",
.name = "rc",
.devnode = ir_devnode,
};

Expand All @@ -40,7 +40,7 @@ static struct class ir_input_class = {
* @buf: a pointer to the output buffer
*
* This routine is a callback routine for input read the IR protocol type.
* it is trigged by reading /sys/class/irrcv/irrcv?/current_protocol.
* it is trigged by reading /sys/class/rc/rcrcv?/current_protocol.
* It returns the protocol name, as understood by the driver.
*/
static ssize_t show_protocol(struct device *d,
Expand Down Expand Up @@ -75,7 +75,7 @@ static ssize_t show_protocol(struct device *d,
* @len: length of the input buffer
*
* This routine is a callback routine for changing the IR protocol type.
* it is trigged by reading /sys/class/irrcv/irrcv?/current_protocol.
* it is trigged by reading /sys/class/rc/rcrcv?/current_protocol.
* It changes the IR the protocol name, if the IR type is recognized
* by the driver.
* If an unknown protocol name is used, returns -EINVAL.
Expand Down Expand Up @@ -172,7 +172,7 @@ static struct device_type ir_dev_type = {
};

/**
* ir_register_class() - creates the sysfs for /sys/class/irrcv/irrcv?
* ir_register_class() - creates the sysfs for /sys/class/rc/rcrcv?
* @input_dev: the struct input_dev descriptor of the device
*
* This routine is used to register the syfs code for IR class
Expand All @@ -192,7 +192,7 @@ int ir_register_class(struct input_dev *input_dev)
ir_dev->dev.type = &ir_dev_type;
ir_dev->dev.class = &ir_input_class;
ir_dev->dev.parent = input_dev->dev.parent;
dev_set_name(&ir_dev->dev, "irrcv%d", devno);
dev_set_name(&ir_dev->dev, "rcrcv%d", devno);
dev_set_drvdata(&ir_dev->dev, ir_dev);
rc = device_register(&ir_dev->dev);
if (rc)
Expand Down Expand Up @@ -223,7 +223,7 @@ int ir_register_class(struct input_dev *input_dev)

/**
* ir_unregister_class() - removes the sysfs for sysfs for
* /sys/class/irrcv/irrcv?
* /sys/class/rc/rcrcv?
* @input_dev: the struct input_dev descriptor of the device
*
* This routine is used to unregister the syfs code for IR class
Expand All @@ -240,14 +240,14 @@ void ir_unregister_class(struct input_dev *input_dev)
}

/*
* Init/exit code for the module. Basically, creates/removes /sys/class/irrcv
* Init/exit code for the module. Basically, creates/removes /sys/class/rc
*/

static int __init ir_core_init(void)
{
int rc = class_register(&ir_input_class);
if (rc) {
printk(KERN_ERR "ir_core: unable to register irrcv class\n");
printk(KERN_ERR "ir_core: unable to register rc class\n");
return rc;
}

Expand Down

0 comments on commit 19c3205

Please sign in to comment.