/openbmc/linux/drivers/media/pci/mantis/ |
H A D | mantis_dvb.c | 154 mantis->dvb_adapter.priv = mantis; in mantis_dvb_init() 159 mantis->demux.priv = mantis; in mantis_dvb_init() 175 mantis->dmxdev.demux = &mantis->demux.dmx; in mantis_dvb_init() 187 result = mantis->demux.dmx.add_frontend(&mantis->demux.dmx, &mantis->fe_hw); in mantis_dvb_init() 195 result = mantis->demux.dmx.add_frontend(&mantis->demux.dmx, &mantis->fe_mem); in mantis_dvb_init() 207 dvb_net_init(&mantis->dvb_adapter, &mantis->dvbnet, &mantis->demux.dmx); in mantis_dvb_init() 226 mantis->fe->ops.release(mantis->fe); in mantis_dvb_init() 245 mantis->demux.dmx.remove_frontend(&mantis->demux.dmx, &mantis->fe_mem); in mantis_dvb_init() 248 mantis->demux.dmx.remove_frontend(&mantis->demux.dmx, &mantis->fe_hw); in mantis_dvb_init() 279 mantis->demux.dmx.remove_frontend(&mantis->demux.dmx, &mantis->fe_mem); in mantis_dvb_exit() [all …]
|
H A D | mantis_dma.c | 52 mantis->buf_cpu, in mantis_dma_exit() 56 mantis->buf_cpu, mantis->buf_dma); in mantis_dma_exit() 64 mantis->risc_cpu, in mantis_dma_exit() 68 mantis->risc_cpu, mantis->risc_dma); in mantis_dma_exit() 80 mantis->buf_cpu = dma_alloc_coherent(&mantis->pdev->dev, in mantis_alloc_buffers() 95 mantis->risc_cpu = dma_alloc_coherent(&mantis->pdev->dev, in mantis_alloc_buffers() 178 mantis->last_block = mantis->busy_block = 0; in mantis_dma_start() 205 struct mantis_pci *mantis = from_tasklet(mantis, t, tasklet); in mantis_dma_xfer() local 208 while (mantis->last_block != mantis->busy_block) { in mantis_dma_xfer() 210 mantis->last_block, mantis->busy_block); in mantis_dma_xfer() [all …]
|
H A D | mantis_cards.c | 68 struct mantis_pci *mantis; in mantis_irq_handler() local 72 if (unlikely(!mantis)) in mantis_irq_handler() 74 ca = mantis->mantis_ca; in mantis_irq_handler() 161 mantis = kzalloc(sizeof(*mantis), GFP_KERNEL); in mantis_pci_probe() 162 if (!mantis) in mantis_pci_probe() 166 mantis->num = devs; in mantis_pci_probe() 168 mantis->pdev = pdev; in mantis_pci_probe() 233 mantis_dvb_exit(mantis); in mantis_pci_probe() 245 kfree(mantis); in mantis_pci_probe() 254 if (mantis) { in mantis_pci_remove() [all …]
|
H A D | hopper_cards.c | 59 struct mantis_pci *mantis; in hopper_irq_handler() local 63 if (unlikely(!mantis)) in hopper_irq_handler() 65 ca = mantis->mantis_ca; in hopper_irq_handler() 152 mantis = kzalloc(sizeof(*mantis), GFP_KERNEL); in hopper_pci_probe() 153 if (!mantis) { in hopper_pci_probe() 159 mantis->num = devs; in hopper_pci_probe() 161 mantis->pdev = pdev; in hopper_pci_probe() 210 mantis_dma_exit(mantis); in hopper_pci_probe() 222 kfree(mantis); in hopper_pci_probe() 232 if (mantis) { in hopper_pci_remove() [all …]
|
H A D | mantis_pci.c | 79 if (!mantis->mmio) { in mantis_pci_init() 90 mantis->revision, in mantis_pci_init() 96 mantis->pdev->irq, in mantis_pci_init() 97 mantis->latency, in mantis_pci_init() 98 mantis->mantis_addr, in mantis_pci_init() 99 mantis->mmio); in mantis_pci_init() 105 mantis); in mantis_pci_init() 120 if (mantis->mmio) in mantis_pci_init() 121 iounmap(mantis->mmio); in mantis_pci_init() 144 if (mantis->mmio) { in mantis_pci_exit() [all …]
|
H A D | mantis_input.c | 25 if (mantis->rc) in mantis_input_process() 29 int mantis_input_init(struct mantis_pci *mantis) in mantis_input_init() argument 41 snprintf(mantis->device_name, sizeof(mantis->device_name), in mantis_input_init() 43 snprintf(mantis->input_phys, sizeof(mantis->input_phys), in mantis_input_init() 44 "pci-%s/ir0", pci_name(mantis->pdev)); in mantis_input_init() 47 dev->input_phys = mantis->input_phys; in mantis_input_init() 49 dev->input_id.vendor = mantis->vendor_id; in mantis_input_init() 50 dev->input_id.product = mantis->device_id; in mantis_input_init() 54 dev->dev.parent = &mantis->pdev->dev; in mantis_input_init() 62 mantis->rc = dev; in mantis_input_init() [all …]
|
H A D | mantis_common.h | 29 if ((mantis->verbose > MANTIS_ERROR) && (mantis->verbose > y)) \ 31 else if ((mantis->verbose > MANTIS_NOTICE) && (mantis->verbose > y)) \ 33 else if ((mantis->verbose > MANTIS_INFO) && (mantis->verbose > y)) \ 35 else if ((mantis->verbose > MANTIS_DEBUG) && (mantis->verbose > y)) \ 37 else if ((mantis->verbose > MANTIS_TMG) && (mantis->verbose > y)) \ 40 if (mantis->verbose > y) \ 49 #define mmread(addr) mread(mantis->mmio + (addr)) 172 #define MANTIS_HIF_STATUS (mantis->gpio_status) 178 spin_lock_irqsave(&mantis->intmask_lock, flags); in mantis_mask_ints() 180 spin_unlock_irqrestore(&mantis->intmask_lock, flags); in mantis_mask_ints() [all …]
|
H A D | mantis_evm.c | 30 struct mantis_pci *mantis = ca->ca_priv; in mantis_hifevm_work() local 38 dprintk(MANTIS_DEBUG, 1, "Event Mgr: Adapter(%d) Slot(0): CAM Plugin", mantis->num); in mantis_hifevm_work() 47 dprintk(MANTIS_DEBUG, 1, "Event Mgr: Adapter(%d) Slot(0): CAM Unplug", mantis->num); in mantis_hifevm_work() 56 if (mantis->gpif_status & MANTIS_GPIF_EXTIRQ) in mantis_hifevm_work() 57 dprintk(MANTIS_DEBUG, 1, "Event Mgr: Adapter(%d) Slot(0): Ext IRQ", mantis->num); in mantis_hifevm_work() 59 if (mantis->gpif_status & MANTIS_SBUF_WSTO) in mantis_hifevm_work() 62 if (mantis->gpif_status & MANTIS_GPIF_OTHERR) in mantis_hifevm_work() 63 dprintk(MANTIS_DEBUG, 1, "Event Mgr: Adapter(%d) Slot(0): Alignment Error", mantis->num); in mantis_hifevm_work() 72 dprintk(MANTIS_DEBUG, 1, "Event Mgr: Adapter(%d) Slot(0): GPIF IRQ", mantis->num); in mantis_hifevm_work() 87 struct mantis_pci *mantis = ca->ca_priv; in mantis_evmgr_init() local [all …]
|
H A D | mantis_i2c.c | 120 struct mantis_pci *mantis; in mantis_i2c_xfer() local 123 mantis = i2c_get_adapdata(adapter); in mantis_i2c_xfer() 124 BUG_ON(!mantis); in mantis_i2c_xfer() 125 config = mantis->hwconfig; in mantis_i2c_xfer() 129 mutex_lock(&mantis->i2c_lock); in mantis_i2c_xfer() 189 mutex_unlock(&mantis->i2c_lock); in mantis_i2c_xfer() 194 mutex_unlock(&mantis->i2c_lock); in mantis_i2c_xfer() 215 mutex_init(&mantis->i2c_lock); in mantis_i2c_init() 227 if (mantis->i2c_rc < 0) in mantis_i2c_init() 228 return mantis->i2c_rc; in mantis_i2c_init() [all …]
|
H A D | mantis_hif.c | 32 struct mantis_pci *mantis = ca->ca_priv; in mantis_hif_sbuf_opdone_wait() local 49 struct mantis_pci *mantis = ca->ca_priv; in mantis_hif_write_wait() local 54 mantis->gpif_status & MANTIS_GPIF_WRACK, in mantis_hif_write_wait() 61 mantis->gpif_status &= ~MANTIS_GPIF_WRACK; in mantis_hif_write_wait() 79 struct mantis_pci *mantis = ca->ca_priv; in mantis_hif_read_mem() local 82 dprintk(MANTIS_DEBUG, 1, "Adapter(%d) Slot(0): Request HIF Mem Read", mantis->num); in mantis_hif_read_mem() 108 struct mantis_pci *mantis = ca->ca_priv; in mantis_hif_write_mem() local 136 struct mantis_pci *mantis = ca->ca_priv; in mantis_hif_read_iom() local 166 struct mantis_pci *mantis = ca->ca_priv; in mantis_hif_write_iom() local 195 struct mantis_pci *mantis = ca->ca_priv; in mantis_hif_init() local [all …]
|
H A D | mantis_uart.c | 54 struct mantis_hwconfig *config = mantis->hwconfig; in mantis_uart_read() 76 mantis_input_process(mantis, scancode); in mantis_uart_read() 98 mantis_uart_read(mantis); in mantis_uart_work() 106 mantis_unmask_ints(mantis, MANTIS_INT_IRQ1); in mantis_uart_work() 143 int mantis_uart_init(struct mantis_pci *mantis) in mantis_uart_init() argument 160 mantis_uart_setup(mantis, ¶ms); in mantis_uart_init() 170 mantis_unmask_ints(mantis, MANTIS_INT_IRQ1); in mantis_uart_init() 172 schedule_work(&mantis->uart_work); in mantis_uart_init() 179 void mantis_uart_exit(struct mantis_pci *mantis) in mantis_uart_exit() argument 182 mantis_mask_ints(mantis, MANTIS_INT_IRQ1); in mantis_uart_exit() [all …]
|
H A D | mantis_vp1034.c | 37 struct mantis_pci *mantis = fe->dvb->priv; in vp1034_set_voltage() local 42 mantis_gpio_set_bits(mantis, 13, 1); in vp1034_set_voltage() 43 mantis_gpio_set_bits(mantis, 14, 0); in vp1034_set_voltage() 47 mantis_gpio_set_bits(mantis, 13, 1); in vp1034_set_voltage() 48 mantis_gpio_set_bits(mantis, 14, 1); in vp1034_set_voltage() 62 static int vp1034_frontend_init(struct mantis_pci *mantis, struct dvb_frontend *fe) in vp1034_frontend_init() argument 64 struct i2c_adapter *adapter = &mantis->adapter; in vp1034_frontend_init() 68 err = mantis_frontend_power(mantis, POWER_ON); in vp1034_frontend_init() 70 mantis_frontend_soft_reset(mantis); in vp1034_frontend_init() 90 mantis->fe = fe; in vp1034_frontend_init()
|
H A D | mantis_pcmcia.c | 32 struct mantis_pci *mantis = ca->ca_priv; in mantis_event_cam_plugin() local 37 dprintk(MANTIS_DEBUG, 1, "Event: CAM Plugged IN: Adapter(%d) Slot(0)", mantis->num); in mantis_event_cam_plugin() 56 struct mantis_pci *mantis = ca->ca_priv; in mantis_event_cam_unplug() local 61 dprintk(MANTIS_DEBUG, 1, "Event: CAM Unplugged: Adapter(%d) Slot(0)", mantis->num); in mantis_event_cam_unplug() 76 struct mantis_pci *mantis = ca->ca_priv; in mantis_pcmcia_init() local 80 mantis_unmask_ints(mantis, MANTIS_INT_IRQ0); in mantis_pcmcia_init() 85 dprintk(MANTIS_DEBUG, 1, "CAM found on Adapter(%d) Slot(0)", mantis->num); in mantis_pcmcia_init() 92 dprintk(MANTIS_DEBUG, 1, "Empty Slot on Adapter(%d) Slot(0)", mantis->num); in mantis_pcmcia_init() 105 struct mantis_pci *mantis = ca->ca_priv; in mantis_pcmcia_exit() local 108 mantis_mask_ints(mantis, MANTIS_INT_IRQ0); in mantis_pcmcia_exit()
|
H A D | mantis_ioc.c | 27 static int read_eeprom_bytes(struct mantis_pci *mantis, u8 reg, u8 *data, u8 length) in read_eeprom_bytes() argument 29 struct i2c_adapter *adapter = &mantis->adapter; in read_eeprom_bytes() 48 int mantis_get_mac(struct mantis_pci *mantis) in mantis_get_mac() argument 53 err = read_eeprom_bytes(mantis, 0x08, mac_addr, 6); in mantis_get_mac() 67 void mantis_gpio_set_bits(struct mantis_pci *mantis, u32 bitpos, u8 value) in mantis_gpio_set_bits() argument 74 mantis->gpio_status = cur | (1 << bitpos); in mantis_gpio_set_bits() 76 mantis->gpio_status = cur & (~(1 << bitpos)); in mantis_gpio_set_bits() 78 dprintk(MANTIS_DEBUG, 1, "GPIO Value <%02x>", mantis->gpio_status); in mantis_gpio_set_bits() 79 mmwrite(mantis->gpio_status, MANTIS_GPIF_ADDR); in mantis_gpio_set_bits() 84 int mantis_stream_control(struct mantis_pci *mantis, enum mantis_stream_control stream_ctl) in mantis_stream_control() argument
|
H A D | mantis_ca.c | 31 struct mantis_pci *mantis = ca->ca_priv; in mantis_ca_read_attr_mem() local 44 struct mantis_pci *mantis = ca->ca_priv; in mantis_ca_write_attr_mem() local 57 struct mantis_pci *mantis = ca->ca_priv; in mantis_ca_read_cam_ctl() local 70 struct mantis_pci *mantis = ca->ca_priv; in mantis_ca_write_cam_ctl() local 83 struct mantis_pci *mantis = ca->ca_priv; in mantis_ca_slot_reset() local 99 struct mantis_pci *mantis = ca->ca_priv; in mantis_ca_slot_shutdown() local 109 struct mantis_pci *mantis = ca->ca_priv; in mantis_ts_control() local 119 struct mantis_pci *mantis = ca->ca_priv; in mantis_slot_status() local 147 ca->ca_priv = mantis; in mantis_ca_init() 148 mantis->mantis_ca = ca; in mantis_ca_init() [all …]
|
H A D | mantis_vp2040.c | 41 struct mantis_pci *mantis = fe->dvb->priv; in tda1002x_cu1216_tuner_set() local 42 struct i2c_adapter *adapter = &mantis->adapter; in tda1002x_cu1216_tuner_set() 94 static u8 read_pwm(struct mantis_pci *mantis) in read_pwm() argument 96 struct i2c_adapter *adapter = &mantis->adapter; in read_pwm() 112 static int vp2040_frontend_init(struct mantis_pci *mantis, struct dvb_frontend *fe) in vp2040_frontend_init() argument 114 struct i2c_adapter *adapter = &mantis->adapter; in vp2040_frontend_init() 118 err = mantis_frontend_power(mantis, POWER_ON); in vp2040_frontend_init() 120 mantis_frontend_soft_reset(mantis); in vp2040_frontend_init() 126 read_pwm(mantis)); in vp2040_frontend_init() 135 read_pwm(mantis)); in vp2040_frontend_init() [all …]
|
H A D | mantis_vp2033.c | 38 static u8 read_pwm(struct mantis_pci *mantis) in read_pwm() argument 40 struct i2c_adapter *adapter = &mantis->adapter; in read_pwm() 59 struct mantis_pci *mantis = fe->dvb->priv; in tda1002x_cu1216_tuner_set() local 60 struct i2c_adapter *adapter = &mantis->adapter; in tda1002x_cu1216_tuner_set() 112 static int vp2033_frontend_init(struct mantis_pci *mantis, struct dvb_frontend *fe) in vp2033_frontend_init() argument 114 struct i2c_adapter *adapter = &mantis->adapter; in vp2033_frontend_init() 118 err = mantis_frontend_power(mantis, POWER_ON); in vp2033_frontend_init() 120 mantis_frontend_soft_reset(mantis); in vp2033_frontend_init() 126 read_pwm(mantis)); in vp2033_frontend_init() 135 read_pwm(mantis)); in vp2033_frontend_init() [all …]
|
H A D | hopper_vp3028.c | 32 static int vp3028_frontend_init(struct mantis_pci *mantis, struct dvb_frontend *fe) in vp3028_frontend_init() argument 34 struct i2c_adapter *adapter = &mantis->adapter; in vp3028_frontend_init() 35 struct mantis_hwconfig *config = mantis->hwconfig; in vp3028_frontend_init() 38 mantis_gpio_set_bits(mantis, config->reset, 0); in vp3028_frontend_init() 40 err = mantis_frontend_power(mantis, POWER_ON); in vp3028_frontend_init() 42 mantis_gpio_set_bits(mantis, config->reset, 1); in vp3028_frontend_init() 44 err = mantis_frontend_power(mantis, POWER_ON); in vp3028_frontend_init()
|
H A D | mantis_core.h | 36 extern int mantis_dma_init(struct mantis_pci *mantis); 37 extern int mantis_dma_exit(struct mantis_pci *mantis); 38 extern void mantis_dma_start(struct mantis_pci *mantis); 39 extern void mantis_dma_stop(struct mantis_pci *mantis); 40 extern int mantis_i2c_init(struct mantis_pci *mantis); 41 extern int mantis_i2c_exit(struct mantis_pci *mantis);
|
H A D | mantis_vp3030.c | 44 static int vp3030_frontend_init(struct mantis_pci *mantis, struct dvb_frontend *fe) in vp3030_frontend_init() argument 46 struct i2c_adapter *adapter = &mantis->adapter; in vp3030_frontend_init() 47 struct mantis_hwconfig *config = mantis->hwconfig; in vp3030_frontend_init() 50 mantis_gpio_set_bits(mantis, config->reset, 0); in vp3030_frontend_init() 52 err = mantis_frontend_power(mantis, POWER_ON); in vp3030_frontend_init() 54 mantis_gpio_set_bits(mantis, config->reset, 1); in vp3030_frontend_init() 73 mantis->fe = fe; in vp3030_frontend_init()
|
H A D | mantis_vp1033.c | 77 struct mantis_pci *mantis = fe->dvb->priv; in lgtdqcs001f_tuner_set() local 78 struct i2c_adapter *adapter = &mantis->adapter; in lgtdqcs001f_tuner_set() 152 static int vp1033_frontend_init(struct mantis_pci *mantis, struct dvb_frontend *fe) in vp1033_frontend_init() argument 154 struct i2c_adapter *adapter = &mantis->adapter; in vp1033_frontend_init() 158 err = mantis_frontend_power(mantis, POWER_ON); in vp1033_frontend_init() 160 mantis_frontend_soft_reset(mantis); in vp1033_frontend_init() 182 mantis->fe = fe; in vp1033_frontend_init()
|
H A D | mantis_dma.h | 12 extern int mantis_dma_init(struct mantis_pci *mantis); 13 extern int mantis_dma_exit(struct mantis_pci *mantis); 14 extern void mantis_dma_start(struct mantis_pci *mantis); 15 extern void mantis_dma_stop(struct mantis_pci *mantis);
|
H A D | mantis_dvb.h | 17 extern int mantis_frontend_power(struct mantis_pci *mantis, enum mantis_power power); 18 extern void mantis_frontend_soft_reset(struct mantis_pci *mantis); 20 extern int mantis_dvb_init(struct mantis_pci *mantis); 21 extern int mantis_dvb_exit(struct mantis_pci *mantis);
|
H A D | mantis_vp1041.c | 296 static int vp1041_frontend_init(struct mantis_pci *mantis, struct dvb_frontend *fe) in vp1041_frontend_init() argument 298 struct i2c_adapter *adapter = &mantis->adapter; in vp1041_frontend_init() 302 err = mantis_frontend_power(mantis, POWER_ON); in vp1041_frontend_init() 304 mantis_frontend_soft_reset(mantis); in vp1041_frontend_init() 306 mantis->fe = dvb_attach(stb0899_attach, &vp1041_stb0899_config, adapter); in vp1041_frontend_init() 307 if (mantis->fe) { in vp1041_frontend_init() 312 if (dvb_attach(stb6100_attach, mantis->fe, &vp1041_stb6100_config, adapter)) { in vp1041_frontend_init() 313 if (!dvb_attach(lnbp21_attach, mantis->fe, adapter, 0, 0)) in vp1041_frontend_init()
|
H A D | mantis_input.h | 12 int mantis_input_init(struct mantis_pci *mantis); 13 void mantis_input_exit(struct mantis_pci *mantis); 14 void mantis_input_process(struct mantis_pci *mantis, int scancode);
|