Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\irq\irqdomain.c Create Date:2022-07-28 10:13:57
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:q_create_mapping() - Map a hardware interrupt into linux irq space*@domain: domain owning this hardware interrupt or NULL for default domain*@hwirq: hardware irq number in that domain space* Only one mapping per hardware interrupt is permitted

Proto:unsigned int irq_create_mapping(struct irq_domain *domain, irq_hw_number_t hwirq)

Type:unsigned int

Parameter:

TypeParameterName
struct irq_domain *domain
irq_hw_number_thwirq
656  pr_debug("irq_create_mapping(0x%p, 0x%lx)\n", domain, hwirq)
659  If (domain == NULL) Then domain = irq_default_domain
661  If (domain == NULL) Then
662  WARN(1, "%s(, %lx) called with NULL domain\n", __func__, hwirq)
663  Return 0
665  pr_debug("-> using domain @%p\n", domain)
667  of_node = irq_domain_get_of_node(domain)
670  virq = q_find_mapping() - Find a linux irq from a hw irq number.*@domain: domain owning this hardware interrupt*@hwirq: hardware irq number in that domain space
671  If virq Then
672  pr_debug("-> existing mapping on virq %d\n", virq)
673  Return virq
677  virq = irq_domain_alloc_descs( - 1, 1, hwirq, of_node_to_nid(of_node), NULL)
678  If virq <= 0 Then
679  pr_debug("-> virq allocation failed\n")
680  Return 0
683  If irq_domain_associate(domain, virq, hwirq) Then
684  irq_free_desc(virq)
685  Return 0
688  pr_debug("irq %lu on domain %s mapped to virtual irq %u\n", hwirq, of_node_full_name(of_node), virq)
691  Return virq
Caller
NameDescribe
irq_create_fwspec_mapping