// SPDX-License-Identifier: GPL-2.0-or-later /* * Interrupt management for most GSC and related devices. * * (c) Copyright 1999 Alex deVries for The Puffin Group * (c) Copyright 1999 Grant Grundler for Hewlett-Packard * (c) Copyright 1999 Matthew Wilcox * (c) Copyright 2000 Helge Deller * (c) Copyright 2001 Matthew Wilcox for Hewlett-Packard
*/
/* Disable the IRQ line by clearing the bit in the IMR */
imr = gsc_readl(irq_dev->hpa + OFFSET_IMR);
imr &= ~(1 << local_irq);
gsc_writel(imr, irq_dev->hpa + OFFSET_IMR);
}
/* Enable the IRQ line by setting the bit in the IMR */
imr = gsc_readl(irq_dev->hpa + OFFSET_IMR);
imr |= 1 << local_irq;
gsc_writel(imr, irq_dev->hpa + OFFSET_IMR); /* * FIXME: read IPR to make sure the IRQ isn't already pending. * If so, we need to read IRR and manually call do_irq().
*/
}
/* work-around for 715/64 and others which have parent
at path [5] and children at path [5/0/x] */ if (padev->id.hw_type == HPHW_FAULTY)
gsc_fixup_irqs(padev, gf->ctrl, gf->choose_irq);
gf->choose_irq(padev, gf->ctrl);
int gsc_common_setup(struct parisc_device *parent, struct gsc_asic *gsc_asic)
{ struct resource *res; int i;
gsc_asic->gsc = parent;
/* Initialise local irq -> global irq mapping */ for (i = 0; i < 32; i++) {
gsc_asic->global_irq[i] = NO_IRQ;
}
/* allocate resource region */
res = request_mem_region(gsc_asic->hpa, 0x100000, gsc_asic->name); if (res) {
res->flags = IORESOURCE_MEM; /* do not mark it busy ! */
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.