History

genirq: Remove GENERIC_IRQ_LEGACY_ALLOC_HWIRQ

Commit bb9d812643d8 ("arch: remove tile port") removed the last user of this cruft two years ago...

Thomas Gleixner committed 6 years ago

Commit f296dcd1 parent d315c623 files · +0 −71Browse files

Unified · Split

3 files
  1. include/linux/irq.h +0 −15
  2. kernel/irq/Kconfig +0 −5
  3. kernel/irq/irqdesc.c +0 −51
include/linux/irq.h+0−15
@@ -954,21 +954,6 @@ static inline void irq_free_desc(unsigned int irq) · 953 unmodified lines
954 irq_free_descs(irq, 1);954 irq_free_descs(irq, 1);
955}955}
956 956
957#ifdef CONFIG_GENERIC_IRQ_LEGACY_ALLOC_HWIRQ
958unsigned int irq_alloc_hwirqs(int cnt, int node);
959static inline unsigned int irq_alloc_hwirq(int node)
960{
961 return irq_alloc_hwirqs(1, node);
962}
963void irq_free_hwirqs(unsigned int from, int cnt);
964static inline void irq_free_hwirq(unsigned int irq)
965{
966 return irq_free_hwirqs(irq, 1);
967}
968int arch_setup_hwirq(unsigned int irq, int node);
969void arch_teardown_hwirq(unsigned int irq);
970#endif
971
972#ifdef CONFIG_GENERIC_IRQ_LEGACY957#ifdef CONFIG_GENERIC_IRQ_LEGACY
973void irq_init_desc(unsigned int irq);958void irq_init_desc(unsigned int irq);
974#endif959#endif
kernel/irq/Kconfig+0−5
@@ -26,11 +26,6 @@ config GENERIC_IRQ_SHOW_LEVEL · 25 unmodified lines
26config GENERIC_IRQ_EFFECTIVE_AFF_MASK26config GENERIC_IRQ_EFFECTIVE_AFF_MASK
27 bool27 bool
28 28
29# Facility to allocate a hardware interrupt. This is legacy support
30# and should not be used in new code. Use irq domains instead.
31config GENERIC_IRQ_LEGACY_ALLOC_HWIRQ
32 bool
33
34# Support for delayed migration from interrupt context29# Support for delayed migration from interrupt context
35config GENERIC_PENDING_IRQ30config GENERIC_PENDING_IRQ
36 bool31 bool
kernel/irq/irqdesc.c+0−51
@@ -810,57 +810,6 @@ unlock: · 809 unmodified lines
810}810}
811EXPORT_SYMBOL_GPL(__irq_alloc_descs);811EXPORT_SYMBOL_GPL(__irq_alloc_descs);
812 812
813#ifdef CONFIG_GENERIC_IRQ_LEGACY_ALLOC_HWIRQ
814/**
815 * irq_alloc_hwirqs - Allocate an irq descriptor and initialize the hardware
816 * @cnt: number of interrupts to allocate
817 * @node: node on which to allocate
818 *
819 * Returns an interrupt number > 0 or 0, if the allocation fails.
820 */
821unsigned int irq_alloc_hwirqs(int cnt, int node)
822{
823 int i, irq = __irq_alloc_descs(-1, 0, cnt, node, NULL, NULL);
824
825 if (irq < 0)
826 return 0;
827
828 for (i = irq; cnt > 0; i++, cnt--) {
829 if (arch_setup_hwirq(i, node))
830 goto err;
831 irq_clear_status_flags(i, _IRQ_NOREQUEST);
832 }
833 return irq;
834
835err:
836 for (i--; i >= irq; i--) {
837 irq_set_status_flags(i, _IRQ_NOREQUEST | _IRQ_NOPROBE);
838 arch_teardown_hwirq(i);
839 }
840 irq_free_descs(irq, cnt);
841 return 0;
842}
843EXPORT_SYMBOL_GPL(irq_alloc_hwirqs);
844
845/**
846 * irq_free_hwirqs - Free irq descriptor and cleanup the hardware
847 * @from: Free from irq number
848 * @cnt: number of interrupts to free
849 *
850 */
851void irq_free_hwirqs(unsigned int from, int cnt)
852{
853 int i, j;
854
855 for (i = from, j = cnt; j > 0; i++, j--) {
856 irq_set_status_flags(i, _IRQ_NOREQUEST | _IRQ_NOPROBE);
857 arch_teardown_hwirq(i);
858 }
859 irq_free_descs(from, cnt);
860}
861EXPORT_SYMBOL_GPL(irq_free_hwirqs);
862#endif
863
864/**813/**
865 * irq_get_next_irq - get next allocated irq number814 * irq_get_next_irq - get next allocated irq number
866 * @offset: where to start the search815 * @offset: where to start the search

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t