File: probe_irq_on.9

package info (click to toggle)
manpages-fr 0.9.3-1
  • links: PTS
  • area: main
  • in suites: woody
  • size: 7,052 kB
  • ctags: 4
  • sloc: makefile: 58; sh: 8
file content (149 lines) | stat: -rw-r--r-- 4,707 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
.\" -*- nroff -*-
.TH PROBE_IRQ_ON 9 "1997/08/14 07:53:32" "Linux DDI 2.1.47" "Fonctions du Noyau de Linux"
.\" Copyright (C) 1997 Neil Moore <amethyst@maxwell.ml.org>
.\"
.\" Permission is granted to make and distribute verbatim copies of this
.\" manual provided the copyright notice and this permission notice are
.\" preserved on all copies.
.\"
.\" Permission is granted to copy and distribute modified versions of this
.\" manual under the conditions for verbatim copying, provided that the
.\" entire resulting derived work is distributed under the terms of a
.\" permission notice identical to this one
.\" 
.\" Since the Linux kernel and libraries are constantly changing, this
.\" manual page may be incorrect or out-of-date.  The author(s) assume no
.\" responsibility for errors or omissions, or for damages resulting from
.\" the use of the information contained herein.  The author(s) may not
.\" have taken the same level of care in the production of this manual,
.\" which is licensed free of charge, as they might when working
.\" professionally.
.\" 
.\" Formatted or processed versions of this manual, if unaccompanied by
.\" the source, must acknowledge the copyright and authors of this work.

.\" Turn off hyphentation
.hlm 0
.\" Turn off adjustment
.na
.SH NOM
probe_irq_on, probe_irq_off \- rechereche d'IRQ
.SH SYNOPSIS
.B #include <linux/interrupt.h>
.\" To keep all components of a declaration together, escape all white
.\" space except after a comma.  In case the proc name plus the first
.\" declaration is too long for one line, allow a break after '(' by
.\" adding '\%'.
.HP
.B "unsigned\ long\ probe_irq_on(void)"
.\" We don't want an inter-paragraph space between the two declarations,
.\" but we have to end the paragraph to stop the hanging indent.  .PD 0
.\" gets rid of inter-paragraph spacing
.PD 0
.HP
.BI "int\ probe_irq_off(unsigned\ long " irqs ");"
.\" And set it back to normal now
.PD 1
.\" Back to standard adjustment
.ad
.\" Allow hypenation, omit if you want no hyphenation in the man page
.hlm 1
.SH DESCRIPTION
.SS Usage
.PP
.B probe_irq_on()
active la recherche d'IRQ. Les interruptions sans gestionnaires (c'est  dire
que le pointeur sur le gestionnaire est NULL) sont actives. La routine
gnrique de gestion des interruptions dsactivent les interruptions qui se
produisent.
.B probe_irq_on()
ajoute un vecteur  toutes les IRQ dont le numro est pass en paramtre.
Cette fonction attend 100ms pour masquer une interruption qui se produirait
puis retourne le vecteur.
.PP
.B probe_irq_off()
teste si
.I irqs
appartient  une liste interne d'IRQ actives.
.I irqs
devrait tre la valeur renvoye par le dernier appel 
.BR probe_irq_on() .
Cette fonction permet de dtecter les IRQs dont le vecteur a t dsactive,
c'est--dire, celles ayant reue une interruption.
.SS Exemple
Comme cette explication est confuse, voici un exemple pour le pilote du FUBAR
2000 pour dtecter une IRQ :
.RS
.PP
unsigned long irqs;
.br
int irq;
.sp
irqs = probe_irq_on();
.sp
outb(FB2K_GIVE_ME_AN_INTERRUPT_OR_GIVE_ME_DEATH,
     FB2K_CONTROL_PORT);
.br
  /* L'interruption peut prendre du temps pour se produire */
.br
udelay(1000);
.sp
irq = probe_irq_off(irqs);
.sp
if (irq == 0) {
.br
	printk("fb2k: Impossible de dtecter une IRQ.\en");
.br
	printk("fb2k: chec de l'nstallation.\en");
.br
} else if (irq == -1) {
.br
	printk("fb2k: plusieurs IRQs ont t dtectes.\en");
.br
	printk("fb2k: L'installation a choue.\en");
.br
} else {
.br
	fb2k_dev->irq = irq;
.br
	printk("fb2k: utilisation de l'IRQ IRQ %d.\en", irq);
.br
}
.br
.SH "VALEUR RENVOYE"
.B probe_irq_on()
retourne la liste des interruptions non gres (sauf celle qui reoivent des
interruptions innatendues). Cette valeur doit tre passe comme paramtre du
prochain appel 
.BR probe_irq_off() .
.PP
.B probe_irq_off()
retourne le numro d'IRQ pour laquelle une interruption non gre s'est
produite depuios le dermier appel 
.BR probe_irq_on() .
Si aucune intterruption ne s'est produite sur les IRQ indiques, 0 est
renvoy; sinon -1 est renvoy.
.SH DISPONIBILIT
Linux 1.2+.  (sauf sur les machines  base de m68k).
.SH "VOIR AUSSI"
.BR request_irq "(9)"
.PP
.I arch/*/kernel/irq.c
.SH AUTEUR
.RI "Neil Moore <" amethyst@maxwell.ml.org ">"
.SH TRADUCTEUR
.RI "Thierry Vignaud <" tvignaud@mandrakesoft.com ">, 1999"
.SH BOGUES
Comme mentionn prcdemment, ces fonctions ne sont pas disponibles sur les
systmes  base de microprocesseurs Motonrola (m68k : atari, amiga, mac, ...).
.PP
Cette page est confuse.
.\"
.\" probe_irq_on.9,v
.\" Revision 1.2  1997/08/14 07:53:32  amethyst
.\" Formatting changes.
.\"
.\" Revision 1.1  1997/07/28 10:28:34  amethyst
.\" Initial revision
.\"
.\"