diff options
Diffstat (limited to 'drivers/media/pci/smipcie')
-rw-r--r-- | drivers/media/pci/smipcie/smipcie-ir.c | 7 | ||||
-rw-r--r-- | drivers/media/pci/smipcie/smipcie-main.c | 6 |
2 files changed, 6 insertions, 7 deletions
diff --git a/drivers/media/pci/smipcie/smipcie-ir.c b/drivers/media/pci/smipcie/smipcie-ir.c index 9445d792bfc9..e6b74e161a05 100644 --- a/drivers/media/pci/smipcie/smipcie-ir.c +++ b/drivers/media/pci/smipcie/smipcie-ir.c @@ -87,8 +87,7 @@ static void smi_ir_decode(struct smi_rc *ir) struct ir_raw_event rawir = {}; rawir.pulse = 0; - rawir.duration = US_TO_NS(SMI_SAMPLE_PERIOD * - SMI_SAMPLE_IDLEMIN); + rawir.duration = SMI_SAMPLE_PERIOD * SMI_SAMPLE_IDLEMIN; ir_raw_event_store_with_filter(rc_dev, &rawir); smi_set(IR_Init_Reg, rbIRhighidle); } @@ -151,8 +150,8 @@ int smi_ir_init(struct smi_dev *dev) rc_dev->dev.parent = &dev->pci_dev->dev; rc_dev->map_name = dev->info->rc_map; - rc_dev->timeout = MS_TO_NS(100); - rc_dev->rx_resolution = US_TO_NS(SMI_SAMPLE_PERIOD); + rc_dev->timeout = MS_TO_US(100); + rc_dev->rx_resolution = SMI_SAMPLE_PERIOD; ir->rc_dev = rc_dev; ir->dev = dev; diff --git a/drivers/media/pci/smipcie/smipcie-main.c b/drivers/media/pci/smipcie/smipcie-main.c index 9ca0fc3e6f80..e7604b7ecc8d 100644 --- a/drivers/media/pci/smipcie/smipcie-main.c +++ b/drivers/media/pci/smipcie/smipcie-main.c @@ -280,9 +280,9 @@ static void smi_port_clearInterrupt(struct smi_port *port) } /* tasklet handler: DMA data to dmx.*/ -static void smi_dma_xfer(unsigned long data) +static void smi_dma_xfer(struct tasklet_struct *t) { - struct smi_port *port = (struct smi_port *) data; + struct smi_port *port = from_tasklet(port, t, tasklet); struct smi_dev *dev = port->dev; u32 intr_status, finishedData, dmaManagement; u8 dmaChan0State, dmaChan1State; @@ -422,7 +422,7 @@ static int smi_port_init(struct smi_port *port, int dmaChanUsed) } smi_port_disableInterrupt(port); - tasklet_init(&port->tasklet, smi_dma_xfer, (unsigned long)port); + tasklet_setup(&port->tasklet, smi_dma_xfer); tasklet_disable(&port->tasklet); port->enable = 1; return 0; |