You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
media: rc-core: rename input_name to device_name
When an ir-spi is registered, you get this message. rc rc0: Unspecified device as /devices/platform/soc/3f215080.spi/spi_master/spi32766/spi32766.128/rc/rc0 "Unspecified device" refers to input_name, which makes no sense for IR TX only devices. So, rename to device_name. Also make driver_name const char* so that no casts are needed anywhere. Now ir-spi reports: rc rc0: IR SPI as /devices/platform/soc/3f215080.spi/spi_master/spi32766/spi32766.128/rc/rc0 Signed-off-by: Sean Young <sean@mess.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
This commit is contained in:
committed by
Mauro Carvalho Chehab
parent
db68102c8d
commit
518f4b26be
@@ -116,7 +116,7 @@ int picolcd_init_cir(struct picolcd_data *data, struct hid_report *report)
|
||||
rdev->allowed_protocols = RC_BIT_ALL_IR_DECODER;
|
||||
rdev->open = picolcd_cir_open;
|
||||
rdev->close = picolcd_cir_close;
|
||||
rdev->input_name = data->hdev->name;
|
||||
rdev->device_name = data->hdev->name;
|
||||
rdev->input_phys = data->hdev->phys;
|
||||
rdev->input_id.bustype = data->hdev->bus;
|
||||
rdev->input_id.vendor = data->hdev->vendor;
|
||||
|
||||
@@ -263,12 +263,12 @@ struct cec_adapter *cec_allocate_adapter(const struct cec_adap_ops *ops,
|
||||
return ERR_PTR(-ENOMEM);
|
||||
}
|
||||
|
||||
snprintf(adap->input_name, sizeof(adap->input_name),
|
||||
snprintf(adap->device_name, sizeof(adap->device_name),
|
||||
"RC for %s", name);
|
||||
snprintf(adap->input_phys, sizeof(adap->input_phys),
|
||||
"%s/input0", name);
|
||||
|
||||
adap->rc->input_name = adap->input_name;
|
||||
adap->rc->device_name = adap->device_name;
|
||||
adap->rc->input_phys = adap->input_phys;
|
||||
adap->rc->input_id.bustype = BUS_CEC;
|
||||
adap->rc->input_id.vendor = 0;
|
||||
|
||||
@@ -73,7 +73,7 @@ int sms_ir_init(struct smscore_device_t *coredev)
|
||||
strlcpy(coredev->ir.phys, coredev->devpath, sizeof(coredev->ir.phys));
|
||||
strlcat(coredev->ir.phys, "/ir0", sizeof(coredev->ir.phys));
|
||||
|
||||
dev->input_name = coredev->ir.name;
|
||||
dev->device_name = coredev->ir.name;
|
||||
dev->input_phys = coredev->ir.phys;
|
||||
dev->dev.parent = coredev->device;
|
||||
|
||||
@@ -91,7 +91,7 @@ int sms_ir_init(struct smscore_device_t *coredev)
|
||||
dev->driver_name = MODULE_NAME;
|
||||
|
||||
pr_debug("Input device (IR) %s is set for key events\n",
|
||||
dev->input_name);
|
||||
dev->device_name);
|
||||
|
||||
err = rc_register_device(dev);
|
||||
if (err < 0) {
|
||||
|
||||
@@ -452,7 +452,7 @@ static int ir_probe(struct i2c_client *client, const struct i2c_device_id *id)
|
||||
*/
|
||||
rc->input_id.bustype = BUS_I2C;
|
||||
rc->input_phys = ir->phys;
|
||||
rc->input_name = ir->name;
|
||||
rc->device_name = ir->name;
|
||||
|
||||
/*
|
||||
* Initialize the other fields of rc_dev
|
||||
|
||||
@@ -535,7 +535,7 @@ int bttv_input_init(struct bttv *btv)
|
||||
snprintf(ir->phys, sizeof(ir->phys), "pci-%s/ir0",
|
||||
pci_name(btv->c.pci));
|
||||
|
||||
rc->input_name = ir->name;
|
||||
rc->device_name = ir->name;
|
||||
rc->input_phys = ir->phys;
|
||||
rc->input_id.bustype = BUS_PCI;
|
||||
rc->input_id.version = 1;
|
||||
|
||||
@@ -351,7 +351,7 @@ int cx23885_input_init(struct cx23885_dev *dev)
|
||||
}
|
||||
|
||||
kernel_ir->rc = rc;
|
||||
rc->input_name = kernel_ir->name;
|
||||
rc->device_name = kernel_ir->name;
|
||||
rc->input_phys = kernel_ir->phys;
|
||||
rc->input_id.bustype = BUS_PCI;
|
||||
rc->input_id.version = 1;
|
||||
|
||||
@@ -464,7 +464,7 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
|
||||
snprintf(ir->name, sizeof(ir->name), "cx88 IR (%s)", core->board.name);
|
||||
snprintf(ir->phys, sizeof(ir->phys), "pci-%s/ir0", pci_name(pci));
|
||||
|
||||
dev->input_name = ir->name;
|
||||
dev->device_name = ir->name;
|
||||
dev->input_phys = ir->phys;
|
||||
dev->input_id.bustype = BUS_PCI;
|
||||
dev->input_id.version = 1;
|
||||
|
||||
@@ -748,7 +748,7 @@ static int dm1105_ir_init(struct dm1105_dev *dm1105)
|
||||
|
||||
dev->driver_name = MODULE_NAME;
|
||||
dev->map_name = RC_MAP_DM1105_NEC;
|
||||
dev->input_name = "DVB on-card IR receiver";
|
||||
dev->device_name = "DVB on-card IR receiver";
|
||||
dev->input_phys = dm1105->ir.input_phys;
|
||||
dev->input_id.bustype = BUS_PCI;
|
||||
dev->input_id.version = 1;
|
||||
|
||||
@@ -176,7 +176,7 @@ struct mantis_pci {
|
||||
struct work_struct uart_work;
|
||||
|
||||
struct rc_dev *rc;
|
||||
char input_name[80];
|
||||
char device_name[80];
|
||||
char input_phys[80];
|
||||
char *rc_map_name;
|
||||
};
|
||||
|
||||
@@ -46,12 +46,12 @@ int mantis_input_init(struct mantis_pci *mantis)
|
||||
goto out;
|
||||
}
|
||||
|
||||
snprintf(mantis->input_name, sizeof(mantis->input_name),
|
||||
snprintf(mantis->device_name, sizeof(mantis->device_name),
|
||||
"Mantis %s IR receiver", mantis->hwconfig->model_name);
|
||||
snprintf(mantis->input_phys, sizeof(mantis->input_phys),
|
||||
"pci-%s/ir0", pci_name(mantis->pdev));
|
||||
|
||||
dev->input_name = mantis->input_name;
|
||||
dev->device_name = mantis->device_name;
|
||||
dev->input_phys = mantis->input_phys;
|
||||
dev->input_id.bustype = BUS_PCI;
|
||||
dev->input_id.vendor = mantis->vendor_id;
|
||||
|
||||
@@ -870,7 +870,7 @@ int saa7134_input_init1(struct saa7134_dev *dev)
|
||||
if (raw_decode)
|
||||
rc->driver_type = RC_DRIVER_IR_RAW;
|
||||
|
||||
rc->input_name = ir->name;
|
||||
rc->device_name = ir->name;
|
||||
rc->input_phys = ir->phys;
|
||||
rc->input_id.bustype = BUS_PCI;
|
||||
rc->input_id.version = 1;
|
||||
|
||||
@@ -188,14 +188,14 @@ int smi_ir_init(struct smi_dev *dev)
|
||||
return -ENOMEM;
|
||||
|
||||
/* init input device */
|
||||
snprintf(ir->input_name, sizeof(ir->input_name), "IR (%s)",
|
||||
snprintf(ir->device_name, sizeof(ir->device_name), "IR (%s)",
|
||||
dev->info->name);
|
||||
snprintf(ir->input_phys, sizeof(ir->input_phys), "pci-%s/ir0",
|
||||
pci_name(dev->pci_dev));
|
||||
|
||||
rc_dev->driver_name = "SMI_PCIe";
|
||||
rc_dev->input_phys = ir->input_phys;
|
||||
rc_dev->input_name = ir->input_name;
|
||||
rc_dev->device_name = ir->device_name;
|
||||
rc_dev->input_id.bustype = BUS_PCI;
|
||||
rc_dev->input_id.version = 1;
|
||||
rc_dev->input_id.vendor = dev->pci_dev->subsystem_vendor;
|
||||
|
||||
@@ -240,7 +240,7 @@ struct smi_rc {
|
||||
struct smi_dev *dev;
|
||||
struct rc_dev *rc_dev;
|
||||
char input_phys[64];
|
||||
char input_name[64];
|
||||
char device_name[64];
|
||||
struct work_struct work;
|
||||
u8 irData[256];
|
||||
|
||||
|
||||
@@ -186,7 +186,7 @@ static int msp430_ir_init(struct budget_ci *budget_ci)
|
||||
"pci-%s/ir0", pci_name(saa->pci));
|
||||
|
||||
dev->driver_name = MODULE_NAME;
|
||||
dev->input_name = budget_ci->ir.name;
|
||||
dev->device_name = budget_ci->ir.name;
|
||||
dev->input_phys = budget_ci->ir.phys;
|
||||
dev->input_id.bustype = BUS_PCI;
|
||||
dev->input_id.version = 1;
|
||||
|
||||
@@ -766,7 +766,7 @@ static void ati_remote_rc_init(struct ati_remote *ati_remote)
|
||||
rdev->open = ati_remote_rc_open;
|
||||
rdev->close = ati_remote_rc_close;
|
||||
|
||||
rdev->input_name = ati_remote->rc_name;
|
||||
rdev->device_name = ati_remote->rc_name;
|
||||
rdev->input_phys = ati_remote->rc_phys;
|
||||
|
||||
usb_to_input_id(ati_remote->udev, &rdev->input_id);
|
||||
|
||||
@@ -1060,7 +1060,7 @@ static int ene_probe(struct pnp_dev *pnp_dev, const struct pnp_device_id *id)
|
||||
rdev->s_idle = ene_set_idle;
|
||||
rdev->driver_name = ENE_DRIVER_NAME;
|
||||
rdev->map_name = RC_MAP_RC6_MCE;
|
||||
rdev->input_name = "ENE eHome Infrared Remote Receiver";
|
||||
rdev->device_name = "ENE eHome Infrared Remote Receiver";
|
||||
|
||||
if (dev->hw_learning_and_tx_capable) {
|
||||
rdev->s_learning_mode = ene_set_learning_mode;
|
||||
@@ -1070,7 +1070,7 @@ static int ene_probe(struct pnp_dev *pnp_dev, const struct pnp_device_id *id)
|
||||
rdev->s_tx_carrier = ene_set_tx_carrier;
|
||||
rdev->s_tx_duty_cycle = ene_set_tx_duty_cycle;
|
||||
rdev->s_carrier_report = ene_set_carrier_report;
|
||||
rdev->input_name = "ENE eHome Infrared Remote Transceiver";
|
||||
rdev->device_name = "ENE eHome Infrared Remote Transceiver";
|
||||
}
|
||||
|
||||
dev->rdev = rdev;
|
||||
|
||||
@@ -532,7 +532,7 @@ static int fintek_probe(struct pnp_dev *pdev, const struct pnp_device_id *dev_id
|
||||
rdev->allowed_protocols = RC_BIT_ALL_IR_DECODER;
|
||||
rdev->open = fintek_open;
|
||||
rdev->close = fintek_close;
|
||||
rdev->input_name = FINTEK_DESCRIPTION;
|
||||
rdev->device_name = FINTEK_DESCRIPTION;
|
||||
rdev->input_phys = "fintek/cir0";
|
||||
rdev->input_id.bustype = BUS_HOST;
|
||||
rdev->input_id.vendor = VENDOR_ID_FINTEK;
|
||||
|
||||
@@ -150,7 +150,7 @@ static int gpio_ir_recv_probe(struct platform_device *pdev)
|
||||
}
|
||||
|
||||
rcdev->priv = gpio_dev;
|
||||
rcdev->input_name = GPIO_IR_DEVICE_NAME;
|
||||
rcdev->device_name = GPIO_IR_DEVICE_NAME;
|
||||
rcdev->input_phys = GPIO_IR_DEVICE_NAME "/input0";
|
||||
rcdev->input_id.bustype = BUS_HOST;
|
||||
rcdev->input_id.vendor = 0x0001;
|
||||
|
||||
@@ -194,7 +194,7 @@ static int igorplugusb_probe(struct usb_interface *intf,
|
||||
if (!rc)
|
||||
goto fail;
|
||||
|
||||
rc->input_name = DRIVER_DESC;
|
||||
rc->device_name = DRIVER_DESC;
|
||||
rc->input_phys = ir->phys;
|
||||
usb_to_input_id(udev, &rc->input_id);
|
||||
rc->dev.parent = &intf->dev;
|
||||
|
||||
@@ -487,7 +487,7 @@ static int iguanair_probe(struct usb_interface *intf,
|
||||
|
||||
usb_make_path(ir->udev, ir->phys, sizeof(ir->phys));
|
||||
|
||||
rc->input_name = ir->name;
|
||||
rc->device_name = ir->name;
|
||||
rc->input_phys = ir->phys;
|
||||
usb_to_input_id(ir->udev, &rc->input_id);
|
||||
rc->dev.parent = &intf->dev;
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user