Lines Matching refs:io7

71 io7_get_irq_ctl(unsigned int irq, struct io7 **pio7)  in io7_get_irq_ctl()
75 struct io7 *io7; in io7_get_irq_ctl() local
79 if (!(io7 = marvel_find_io7(pid))) { in io7_get_irq_ctl()
96 ctl = &io7->csrs->PO7_LSI_CTL[irq & 0xff].csr; /* assume LSI */ in io7_get_irq_ctl()
98 ctl = &io7->csrs->PO7_MSI_CTL[((irq - 0x80) >> 5) & 0x0f].csr; in io7_get_irq_ctl()
100 if (pio7) *pio7 = io7; in io7_get_irq_ctl()
109 struct io7 *io7; in io7_enable_irq() local
111 ctl = io7_get_irq_ctl(irq, &io7); in io7_enable_irq()
112 if (!ctl || !io7) { in io7_enable_irq()
118 raw_spin_lock(&io7->irq_lock); in io7_enable_irq()
122 raw_spin_unlock(&io7->irq_lock); in io7_enable_irq()
130 struct io7 *io7; in io7_disable_irq() local
132 ctl = io7_get_irq_ctl(irq, &io7); in io7_disable_irq()
133 if (!ctl || !io7) { in io7_disable_irq()
139 raw_spin_lock(&io7->irq_lock); in io7_disable_irq()
143 raw_spin_unlock(&io7->irq_lock); in io7_disable_irq()
173 io7_redirect_irq(struct io7 *io7, in io7_redirect_irq() argument
189 io7_redirect_one_lsi(struct io7 *io7, unsigned int which, unsigned int where) in io7_redirect_one_lsi() argument
196 val = io7->csrs->PO7_LSI_CTL[which].csr; in io7_redirect_one_lsi()
200 io7->csrs->PO7_LSI_CTL[which].csr = val; in io7_redirect_one_lsi()
202 io7->csrs->PO7_LSI_CTL[which].csr; in io7_redirect_one_lsi()
206 io7_redirect_one_msi(struct io7 *io7, unsigned int which, unsigned int where) in io7_redirect_one_msi() argument
213 val = io7->csrs->PO7_MSI_CTL[which].csr; in io7_redirect_one_msi()
217 io7->csrs->PO7_MSI_CTL[which].csr = val; in io7_redirect_one_msi()
219 io7->csrs->PO7_MSI_CTL[which].csr; in io7_redirect_one_msi()
223 init_one_io7_lsi(struct io7 *io7, unsigned int which, unsigned int where) in init_one_io7_lsi() argument
228 io7->csrs->PO7_LSI_CTL[which].csr = ((unsigned long)where << 14); in init_one_io7_lsi()
230 io7->csrs->PO7_LSI_CTL[which].csr; in init_one_io7_lsi()
234 init_one_io7_msi(struct io7 *io7, unsigned int which, unsigned int where) in init_one_io7_msi() argument
239 io7->csrs->PO7_MSI_CTL[which].csr = ((unsigned long)where << 14); in init_one_io7_msi()
241 io7->csrs->PO7_MSI_CTL[which].csr; in init_one_io7_msi()
245 init_io7_irqs(struct io7 *io7, in init_io7_irqs() argument
249 long base = (io7->pe << MARVEL_IRQ_VEC_PE_SHIFT) + 16; in init_io7_irqs()
253 io7->pe, base); in init_io7_irqs()
266 raw_spin_lock(&io7->irq_lock); in init_io7_irqs()
269 io7_redirect_irq(io7, &io7->csrs->HLT_CTL.csr, boot_cpuid); in init_io7_irqs()
270 io7_redirect_irq(io7, &io7->csrs->HPI_CTL.csr, boot_cpuid); in init_io7_irqs()
271 io7_redirect_irq(io7, &io7->csrs->CRD_CTL.csr, boot_cpuid); in init_io7_irqs()
272 io7_redirect_irq(io7, &io7->csrs->STV_CTL.csr, boot_cpuid); in init_io7_irqs()
273 io7_redirect_irq(io7, &io7->csrs->HEI_CTL.csr, boot_cpuid); in init_io7_irqs()
283 init_one_io7_lsi(io7, i, boot_cpuid); in init_io7_irqs()
285 init_one_io7_lsi(io7, 0x74, boot_cpuid); in init_io7_irqs()
286 init_one_io7_lsi(io7, 0x75, boot_cpuid); in init_io7_irqs()
296 init_one_io7_msi(io7, i, boot_cpuid); in init_io7_irqs()
298 raw_spin_unlock(&io7->irq_lock); in init_io7_irqs()
305 struct io7 *io7 = NULL; in marvel_init_irq() local
314 for (io7 = NULL; (io7 = marvel_next_io7(io7)) != NULL; ) in marvel_init_irq()
315 init_io7_irqs(io7, &io7_lsi_irq_type, &io7_msi_irq_type); in marvel_init_irq()
324 struct io7 *io7 = io7_port->io7; in marvel_map_irq() local
359 (irq + 16) | (io7->pe << MARVEL_IRQ_VEC_PE_SHIFT), in marvel_map_irq()
360 (irq + 16) | (io7->pe << MARVEL_IRQ_VEC_PE_SHIFT)); in marvel_map_irq()
374 irq |= io7->pe << MARVEL_IRQ_VEC_PE_SHIFT; /* merge the pid */ in marvel_map_irq()
382 struct io7 *io7; in marvel_init_pci() local
392 for (io7 = NULL; (io7 = marvel_next_io7(io7)) != NULL; ) in marvel_init_pci()
393 io7_clear_errors(io7); in marvel_init_pci()
406 struct io7 *io7 = marvel_find_io7(cpuid); in marvel_smp_callin() local
409 if (!io7) in marvel_smp_callin()
418 io7_redirect_irq(io7, &io7->csrs->HLT_CTL.csr, cpuid); in marvel_smp_callin()
419 io7_redirect_irq(io7, &io7->csrs->HPI_CTL.csr, cpuid); in marvel_smp_callin()
420 io7_redirect_irq(io7, &io7->csrs->CRD_CTL.csr, cpuid); in marvel_smp_callin()
421 io7_redirect_irq(io7, &io7->csrs->STV_CTL.csr, cpuid); in marvel_smp_callin()
422 io7_redirect_irq(io7, &io7->csrs->HEI_CTL.csr, cpuid); in marvel_smp_callin()
426 io7_redirect_one_lsi(io7, i, cpuid); in marvel_smp_callin()
428 io7_redirect_one_lsi(io7, 0x74, cpuid); in marvel_smp_callin()
429 io7_redirect_one_lsi(io7, 0x75, cpuid); in marvel_smp_callin()
433 io7_redirect_one_msi(io7, i, cpuid); in marvel_smp_callin()