aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/media/IR/ir-sysfs.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/drivers/media/IR/ir-sysfs.c b/drivers/media/IR/ir-sysfs.c
index 2279d5594b05..36dfe51aad92 100644
--- a/drivers/media/IR/ir-sysfs.c
+++ b/drivers/media/IR/ir-sysfs.c
@@ -22,14 +22,14 @@
22/* bit array to represent IR sysfs device number */ 22/* bit array to represent IR sysfs device number */
23static unsigned long ir_core_dev_number; 23static unsigned long ir_core_dev_number;
24 24
25/* class for /sys/class/irrcv */ 25/* class for /sys/class/rc */
26static char *ir_devnode(struct device *dev, mode_t *mode) 26static char *ir_devnode(struct device *dev, mode_t *mode)
27{ 27{
28 return kasprintf(GFP_KERNEL, "irrcv/%s", dev_name(dev)); 28 return kasprintf(GFP_KERNEL, "rc/%s", dev_name(dev));
29} 29}
30 30
31static struct class ir_input_class = { 31static struct class ir_input_class = {
32 .name = "irrcv", 32 .name = "rc",
33 .devnode = ir_devnode, 33 .devnode = ir_devnode,
34}; 34};
35 35
@@ -40,7 +40,7 @@ static struct class ir_input_class = {
40 * @buf: a pointer to the output buffer 40 * @buf: a pointer to the output buffer
41 * 41 *
42 * This routine is a callback routine for input read the IR protocol type. 42 * This routine is a callback routine for input read the IR protocol type.
43 * it is trigged by reading /sys/class/irrcv/irrcv?/current_protocol. 43 * it is trigged by reading /sys/class/rc/rcrcv?/current_protocol.
44 * It returns the protocol name, as understood by the driver. 44 * It returns the protocol name, as understood by the driver.
45 */ 45 */
46static ssize_t show_protocol(struct device *d, 46static ssize_t show_protocol(struct device *d,
@@ -75,7 +75,7 @@ static ssize_t show_protocol(struct device *d,
75 * @len: length of the input buffer 75 * @len: length of the input buffer
76 * 76 *
77 * This routine is a callback routine for changing the IR protocol type. 77 * This routine is a callback routine for changing the IR protocol type.
78 * it is trigged by reading /sys/class/irrcv/irrcv?/current_protocol. 78 * it is trigged by reading /sys/class/rc/rcrcv?/current_protocol.
79 * It changes the IR the protocol name, if the IR type is recognized 79 * It changes the IR the protocol name, if the IR type is recognized
80 * by the driver. 80 * by the driver.
81 * If an unknown protocol name is used, returns -EINVAL. 81 * If an unknown protocol name is used, returns -EINVAL.
@@ -172,7 +172,7 @@ static struct device_type ir_dev_type = {
172}; 172};
173 173
174/** 174/**
175 * ir_register_class() - creates the sysfs for /sys/class/irrcv/irrcv? 175 * ir_register_class() - creates the sysfs for /sys/class/rc/rcrcv?
176 * @input_dev: the struct input_dev descriptor of the device 176 * @input_dev: the struct input_dev descriptor of the device
177 * 177 *
178 * This routine is used to register the syfs code for IR class 178 * This routine is used to register the syfs code for IR class
@@ -192,7 +192,7 @@ int ir_register_class(struct input_dev *input_dev)
192 ir_dev->dev.type = &ir_dev_type; 192 ir_dev->dev.type = &ir_dev_type;
193 ir_dev->dev.class = &ir_input_class; 193 ir_dev->dev.class = &ir_input_class;
194 ir_dev->dev.parent = input_dev->dev.parent; 194 ir_dev->dev.parent = input_dev->dev.parent;
195 dev_set_name(&ir_dev->dev, "irrcv%d", devno); 195 dev_set_name(&ir_dev->dev, "rcrcv%d", devno);
196 dev_set_drvdata(&ir_dev->dev, ir_dev); 196 dev_set_drvdata(&ir_dev->dev, ir_dev);
197 rc = device_register(&ir_dev->dev); 197 rc = device_register(&ir_dev->dev);
198 if (rc) 198 if (rc)
@@ -223,7 +223,7 @@ int ir_register_class(struct input_dev *input_dev)
223 223
224/** 224/**
225 * ir_unregister_class() - removes the sysfs for sysfs for 225 * ir_unregister_class() - removes the sysfs for sysfs for
226 * /sys/class/irrcv/irrcv? 226 * /sys/class/rc/rcrcv?
227 * @input_dev: the struct input_dev descriptor of the device 227 * @input_dev: the struct input_dev descriptor of the device
228 * 228 *
229 * This routine is used to unregister the syfs code for IR class 229 * This routine is used to unregister the syfs code for IR class
@@ -240,14 +240,14 @@ void ir_unregister_class(struct input_dev *input_dev)
240} 240}
241 241
242/* 242/*
243 * Init/exit code for the module. Basically, creates/removes /sys/class/irrcv 243 * Init/exit code for the module. Basically, creates/removes /sys/class/rc
244 */ 244 */
245 245
246static int __init ir_core_init(void) 246static int __init ir_core_init(void)
247{ 247{
248 int rc = class_register(&ir_input_class); 248 int rc = class_register(&ir_input_class);
249 if (rc) { 249 if (rc) {
250 printk(KERN_ERR "ir_core: unable to register irrcv class\n"); 250 printk(KERN_ERR "ir_core: unable to register rc class\n");
251 return rc; 251 return rc;
252 } 252 }
253 253