Rev 80 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
2 | pj | 1 | /* |
2 | * Project: S.Ha.R.K. |
||
3 | * |
||
4 | * Coordinators: |
||
5 | * Giorgio Buttazzo <giorgio@sssup.it> |
||
6 | * Paolo Gai <pj@gandalf.sssup.it> |
||
7 | * |
||
8 | * Authors : |
||
9 | * Paolo Gai <pj@gandalf.sssup.it> |
||
10 | * Massimiliano Giorgi <massy@gandalf.sssup.it> |
||
11 | * Luca Abeni <luca@gandalf.sssup.it> |
||
12 | * (see the web pages for full authors list) |
||
13 | * |
||
14 | * ReTiS Lab (Scuola Superiore S.Anna - Pisa - Italy) |
||
15 | * |
||
16 | * http://www.sssup.it |
||
17 | * http://retis.sssup.it |
||
18 | * http://shark.sssup.it |
||
19 | */ |
||
20 | |||
21 | /*************************************** |
||
22 | |||
80 | pj | 23 | CVS : $Id: bqueue.h,v 1.2 2003-03-13 13:43:13 pj Exp $ |
2 | pj | 24 | |
80 | pj | 25 | Revision: $Revision: 1.2 $ |
2 | pj | 26 | |
80 | pj | 27 | Last update: $Date: 2003-03-13 13:43:13 $ |
2 | pj | 28 | |
29 | This module is responsable of the protocol between the IDE device driver |
||
30 | interface and the host (the computer). |
||
31 | |||
32 | ***************************************/ |
||
33 | |||
34 | /* |
||
35 | * Copyright (C) 1999,2000 Massimiliano Giorgi |
||
36 | * |
||
37 | * This program is free software; you can redistribute it and/or modify |
||
38 | * it under the terms of the GNU General Public License as published by |
||
39 | * the Free Software Foundation; either version 2 of the License, or |
||
40 | * (at your option) any later version. |
||
41 | * |
||
42 | * This program is distributed in the hope that it will be useful, |
||
43 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
||
44 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||
45 | * GNU General Public License for more details. |
||
46 | * |
||
47 | * You should have received a copy of the GNU General Public License |
||
48 | * along with this program; if not, write to the Free Software |
||
49 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
||
50 | * |
||
51 | */ |
||
52 | |||
53 | #ifndef __BQUEUE_H |
||
54 | #define __BQUEUE_H |
||
55 | |||
56 | struct request_prolog; |
||
57 | |||
58 | #ifdef _SCHED_FCFS |
||
59 | #include "fcfs/fcfs.h" |
||
60 | #endif |
||
61 | #ifdef _SCHED_SSTF |
||
62 | #include "sstf/sstf.h" |
||
63 | #endif |
||
64 | #ifdef _SCHED_LOOK |
||
65 | #include "look/look.h" |
||
66 | #endif |
||
67 | #ifdef _SCHED_CLOOK |
||
68 | #include "clook/clook.h" |
||
69 | #endif |
||
70 | #ifdef _SCHED_EDF |
||
71 | #include "edf/edf.h" |
||
72 | #endif |
||
73 | #ifdef _SCHED_PSCAN |
||
74 | #include "pscan/pscan.h" |
||
75 | #endif |
||
76 | |||
80 | pj | 77 | #include "ll/sys/cdefs.h" |
78 | |||
79 | __BEGIN_DECLS |
||
80 | |||
2 | pj | 81 | #define REQ_DUMMY 0 |
82 | #define REQ_SEEK 1 |
||
83 | #define REQ_READ 2 |
||
84 | #define REQ_WRITE 3 |
||
85 | |||
86 | struct request_prologue { |
||
87 | unsigned sector; |
||
88 | unsigned head; |
||
89 | unsigned cylinder; |
||
90 | unsigned nsectors; |
||
91 | unsigned operation; |
||
92 | /*--*/ |
||
93 | struct request_specific x; |
||
94 | }; |
||
95 | #define request_prologue_t struct request_prologue |
||
96 | |||
97 | int bqueue_init(bqueue_t *); |
||
98 | int bqueue_numelements(bqueue_t *); |
||
99 | int bqueue_insertrequest(bqueue_t *, struct request_prologue *); |
||
100 | struct request_prologue *bqueue_getrequest(bqueue_t *); |
||
101 | int bqueue_removerequest(bqueue_t *); |
||
80 | pj | 102 | __END_DECLS |
2 | pj | 103 | #endif |