diff options
author | Jeff Garzik <jeff@garzik.org> | 2006-12-03 22:22:41 -0500 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2006-12-03 22:22:41 -0500 |
commit | d916faace3efc0bf19fe9a615a1ab8fa1a24cd93 (patch) | |
tree | e6adbc42541498306728490a4978afe116131299 /include/linux | |
parent | 2b5f6dcce5bf94b9b119e9ed8d537098ec61c3d2 (diff) |
Remove long-unmaintained ftape driver subsystem.
It's bitrotten, long unmaintained, long hidden under BROKEN_ON_SMP,
etc. As scheduled in feature-removal-schedule.txt, and ack'd several
times on lkml.
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/Kbuild | 4 | ||||
-rw-r--r-- | include/linux/ftape-header-segment.h | 122 | ||||
-rw-r--r-- | include/linux/ftape-vendors.h | 137 | ||||
-rw-r--r-- | include/linux/ftape.h | 201 | ||||
-rw-r--r-- | include/linux/zftape.h | 87 |
5 files changed, 0 insertions, 551 deletions
diff --git a/include/linux/Kbuild b/include/linux/Kbuild index d7e04689304c..ff433126361f 100644 --- a/include/linux/Kbuild +++ b/include/linux/Kbuild | |||
@@ -60,8 +60,6 @@ header-y += fadvise.h | |||
60 | header-y += fd.h | 60 | header-y += fd.h |
61 | header-y += fdreg.h | 61 | header-y += fdreg.h |
62 | header-y += fib_rules.h | 62 | header-y += fib_rules.h |
63 | header-y += ftape-header-segment.h | ||
64 | header-y += ftape-vendors.h | ||
65 | header-y += fuse.h | 63 | header-y += fuse.h |
66 | header-y += futex.h | 64 | header-y += futex.h |
67 | header-y += genetlink.h | 65 | header-y += genetlink.h |
@@ -206,7 +204,6 @@ unifdef-y += fcntl.h | |||
206 | unifdef-y += filter.h | 204 | unifdef-y += filter.h |
207 | unifdef-y += flat.h | 205 | unifdef-y += flat.h |
208 | unifdef-y += fs.h | 206 | unifdef-y += fs.h |
209 | unifdef-y += ftape.h | ||
210 | unifdef-y += gameport.h | 207 | unifdef-y += gameport.h |
211 | unifdef-y += generic_serial.h | 208 | unifdef-y += generic_serial.h |
212 | unifdef-y += genhd.h | 209 | unifdef-y += genhd.h |
@@ -341,6 +338,5 @@ unifdef-y += wait.h | |||
341 | unifdef-y += wanrouter.h | 338 | unifdef-y += wanrouter.h |
342 | unifdef-y += watchdog.h | 339 | unifdef-y += watchdog.h |
343 | unifdef-y += xfrm.h | 340 | unifdef-y += xfrm.h |
344 | unifdef-y += zftape.h | ||
345 | 341 | ||
346 | objhdr-y += version.h | 342 | objhdr-y += version.h |
diff --git a/include/linux/ftape-header-segment.h b/include/linux/ftape-header-segment.h deleted file mode 100644 index 4732218f0708..000000000000 --- a/include/linux/ftape-header-segment.h +++ /dev/null | |||
@@ -1,122 +0,0 @@ | |||
1 | #ifndef _FTAPE_HEADER_SEGMENT_H | ||
2 | #define _FTAPE_HEADER_SEGMENT_H | ||
3 | |||
4 | /* | ||
5 | * Copyright (C) 1996-1997 Claus-Justus Heine. | ||
6 | |||
7 | This program is free software; you can redistribute it and/or modify | ||
8 | it under the terms of the GNU General Public License as published by | ||
9 | the Free Software Foundation; either version 2, or (at your option) | ||
10 | any later version. | ||
11 | |||
12 | This program is distributed in the hope that it will be useful, | ||
13 | but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
15 | GNU General Public License for more details. | ||
16 | |||
17 | You should have received a copy of the GNU General Public License | ||
18 | along with this program; see the file COPYING. If not, write to | ||
19 | the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. | ||
20 | |||
21 | * | ||
22 | * $Source: /homes/cvs/ftape-stacked/include/linux/ftape-header-segment.h,v $ | ||
23 | * $Revision: 1.2 $ | ||
24 | * $Date: 1997/10/05 19:19:28 $ | ||
25 | * | ||
26 | * This file defines some offsets into the header segment of a | ||
27 | * floppy tape cartridge. For use with the QIC-40/80/3010/3020 | ||
28 | * floppy-tape driver "ftape" for Linux. | ||
29 | */ | ||
30 | |||
31 | #define FT_SIGNATURE 0 /* must be 0xaa55aa55 */ | ||
32 | #define FT_FMT_CODE 4 | ||
33 | #define FT_REV_LEVEL 5 /* only for QIC-80 since. Rev. L (== 0x0c) */ | ||
34 | #define FT_HSEG_1 6 /* first header segment, except for format code 6 */ | ||
35 | #define FT_HSEG_2 8 /* second header segment, except for format code 6 */ | ||
36 | #define FT_FRST_SEG 10 /* first data segment, except for format code 6 */ | ||
37 | #define FT_LAST_SEG 12 /* last data segment, except for format code 6 */ | ||
38 | #define FT_FMT_DATE 14 /* date and time of most recent format, see below */ | ||
39 | #define FT_WR_DATE 18 /* date and time of most recent write or format */ | ||
40 | #define FT_SPT 24 /* segments per track */ | ||
41 | #define FT_TPC 26 /* tracks per cartridge */ | ||
42 | #define FT_FHM 27 /* floppy drive head (maximum of it) */ | ||
43 | #define FT_FTM 28 /* floppy track max. */ | ||
44 | #define FT_FSM 29 /* floppy sector max. (128) */ | ||
45 | #define FT_LABEL 30 /* floppy tape label */ | ||
46 | #define FT_LABEL_DATE 74 /* date and time the tape label was written */ | ||
47 | #define FT_LABEL_SZ (FT_LABEL_DATE - FT_LABEL) | ||
48 | #define FT_CMAP_START 78 /* starting segment of compression map */ | ||
49 | #define FT_FMT_ERROR 128 /* must be set to 0xff if remainder gets lost during | ||
50 | * tape format | ||
51 | */ | ||
52 | #define FT_SEG_CNT 130 /* number of seg. written, formatted or verified | ||
53 | * through lifetime of tape (why not read?) | ||
54 | */ | ||
55 | #define FT_INIT_DATE 138 /* date and time of initial tape format */ | ||
56 | #define FT_FMT_CNT 142 /* number of times tape has been formatted */ | ||
57 | #define FT_FSL_CNT 144 /* number of segments in failed sector log */ | ||
58 | #define FT_MK_CODE 146 /* id string of tape manufacturer */ | ||
59 | #define FT_LOT_CODE 190 /* tape manufacturer lot code */ | ||
60 | #define FT_6_HSEG_1 234 /* first header segment for format code 6 */ | ||
61 | #define FT_6_HSEG_2 238 /* second header segment for format code 6 */ | ||
62 | #define FT_6_FRST_SEG 242 /* first data segment for format code 6 */ | ||
63 | #define FT_6_LAST_SEG 246 /* last data segment for format code 6 */ | ||
64 | |||
65 | #define FT_FSL 256 | ||
66 | #define FT_HEADER_END 256 /* space beyond this point: | ||
67 | * format codes 2, 3 and 5: | ||
68 | * - failed sector log until byte 2047 | ||
69 | * - bad sector map in the reamining part of segment | ||
70 | * format codes 4 and 6: | ||
71 | * - bad sector map starts hear | ||
72 | */ | ||
73 | |||
74 | |||
75 | /* value to be stored at the FT_SIGNATURE offset | ||
76 | */ | ||
77 | #define FT_HSEG_MAGIC 0xaa55aa55 | ||
78 | #define FT_D2G_MAGIC 0x82288228 /* Ditto 2GB */ | ||
79 | |||
80 | /* data and time encoding: */ | ||
81 | #define FT_YEAR_SHIFT 25 | ||
82 | #define FT_YEAR_MASK 0xfe000000 | ||
83 | #define FT_YEAR_0 1970 | ||
84 | #define FT_YEAR_MAX 127 | ||
85 | #define FT_YEAR(year) ((((year)-FT_YEAR_0)<<FT_YEAR_SHIFT)&FT_YEAR_MASK) | ||
86 | |||
87 | #define FT_TIME_SHIFT 0 | ||
88 | #define FT_TIME_MASK 0x01FFFFFF | ||
89 | #define FT_TIME_MAX 0x01ea6dff /* last second of a year */ | ||
90 | #define FT_TIME(mo,d,h,m,s) \ | ||
91 | ((((s)+60*((m)+60*((h)+24*((d)+31*(mo))))) & FT_TIME_MASK)) | ||
92 | |||
93 | #define FT_TIME_STAMP(y,mo,d,h,m,s) (FT_YEAR(y) | FT_TIME(mo,d,h,m,s)) | ||
94 | |||
95 | /* values for the format code field */ | ||
96 | typedef enum { | ||
97 | fmt_normal = 2, /* QIC-80 post Rev. B 205Ft or 307Ft tape */ | ||
98 | fmt_1100ft = 3, /* QIC-80 post Rev. B 1100Ft tape */ | ||
99 | fmt_var = 4, /* QIC-80 post Rev. B variabel length format */ | ||
100 | fmt_425ft = 5, /* QIC-80 post Rev. B 425Ft tape */ | ||
101 | fmt_big = 6 /* QIC-3010/3020 variable length tape with more | ||
102 | * than 2^16 segments per tape | ||
103 | */ | ||
104 | } ft_format_type; | ||
105 | |||
106 | /* definitions for the failed sector log */ | ||
107 | #define FT_FSL_SIZE (2 * FT_SECTOR_SIZE - FT_HEADER_END) | ||
108 | #define FT_FSL_MAX_ENTRIES (FT_FSL_SIZE/sizeof(__u32)) | ||
109 | |||
110 | typedef struct ft_fsl_entry { | ||
111 | __u16 segment; | ||
112 | __u16 date; | ||
113 | } __attribute__ ((packed)) ft_fsl_entry; | ||
114 | |||
115 | |||
116 | /* date encoding for the failed sector log | ||
117 | * month: 1..12, day: 1..31, year: 1970..2097 | ||
118 | */ | ||
119 | #define FT_FSL_TIME_STAMP(y,m,d) \ | ||
120 | (((((y) - FT_YEAR_0)<<9)&0xfe00) | (((m)<<5)&0x01e0) | ((d)&0x001f)) | ||
121 | |||
122 | #endif /* _FTAPE_HEADER_SEGMENT_H */ | ||
diff --git a/include/linux/ftape-vendors.h b/include/linux/ftape-vendors.h deleted file mode 100644 index ec1a81f059e5..000000000000 --- a/include/linux/ftape-vendors.h +++ /dev/null | |||
@@ -1,137 +0,0 @@ | |||
1 | #ifndef _FTAPE_VENDORS_H | ||
2 | #define _FTAPE_VENDORS_H | ||
3 | |||
4 | /* | ||
5 | * Copyright (C) 1993-1996 Bas Laarhoven, | ||
6 | * (C) 1996-1997 Claus-Justus Heine. | ||
7 | |||
8 | This program is free software; you can redistribute it and/or modify | ||
9 | it under the terms of the GNU General Public License as published by | ||
10 | the Free Software Foundation; either version 2, or (at your option) | ||
11 | any later version. | ||
12 | |||
13 | This program is distributed in the hope that it will be useful, | ||
14 | but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
15 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
16 | GNU General Public License for more details. | ||
17 | |||
18 | You should have received a copy of the GNU General Public License | ||
19 | along with this program; see the file COPYING. If not, write to | ||
20 | the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. | ||
21 | |||
22 | * | ||
23 | * $Source: /homes/cvs/ftape-stacked/include/linux/ftape-vendors.h,v $ | ||
24 | * $Revision: 1.6 $ | ||
25 | * $Date: 1997/10/09 15:38:11 $ | ||
26 | * | ||
27 | * This file contains the supported drive types with their | ||
28 | * QIC-117 spec. vendor code and drive dependent configuration | ||
29 | * information. | ||
30 | */ | ||
31 | |||
32 | typedef enum { | ||
33 | unknown_wake_up = 0, | ||
34 | no_wake_up, | ||
35 | wake_up_colorado, | ||
36 | wake_up_mountain, | ||
37 | wake_up_insight, | ||
38 | } wake_up_types; | ||
39 | |||
40 | typedef struct { | ||
41 | wake_up_types wake_up; /* see wake_up_types */ | ||
42 | char *name; /* Text describing the drive */ | ||
43 | } wakeup_method; | ||
44 | |||
45 | /* Note: order of entries in WAKEUP_METHODS must be so that a variable | ||
46 | * of type wake_up_types can be used as an index in the array. | ||
47 | */ | ||
48 | #define WAKEUP_METHODS { \ | ||
49 | { unknown_wake_up, "Unknown" }, \ | ||
50 | { no_wake_up, "None" }, \ | ||
51 | { wake_up_colorado, "Colorado" }, \ | ||
52 | { wake_up_mountain, "Mountain" }, \ | ||
53 | { wake_up_insight, "Motor-on" }, \ | ||
54 | } | ||
55 | |||
56 | typedef struct { | ||
57 | unsigned int vendor_id; /* vendor id from drive */ | ||
58 | int speed; /* maximum tape transport speed (ips) */ | ||
59 | wake_up_types wake_up; /* see wake_up_types */ | ||
60 | char *name; /* Text describing the drive */ | ||
61 | } vendor_struct; | ||
62 | |||
63 | #define UNKNOWN_VENDOR (-1) | ||
64 | |||
65 | #define QIC117_VENDORS { \ | ||
66 | /* see _vendor_struct */ \ | ||
67 | { 0x00000, 82, wake_up_colorado, "Colorado DJ-10 (old)" }, \ | ||
68 | { 0x00047, 90, wake_up_colorado, "Colorado DJ-10/DJ-20" }, \ | ||
69 | { 0x011c2, 84, wake_up_colorado, "Colorado 700" }, \ | ||
70 | { 0x011c3, 90, wake_up_colorado, "Colorado 1400" }, \ | ||
71 | { 0x011c4, 84, wake_up_colorado, "Colorado DJ-10/DJ-20 (new)" }, \ | ||
72 | { 0x011c5, 84, wake_up_colorado, "HP Colorado T1000" }, \ | ||
73 | { 0x011c6, 90, wake_up_colorado, "HP Colorado T3000" }, \ | ||
74 | { 0x00005, 45, wake_up_mountain, "Archive 5580i" }, \ | ||
75 | { 0x10005, 50, wake_up_insight, "Insight 80Mb, Irwin 80SX" }, \ | ||
76 | { 0x00140, 74, wake_up_mountain, "Archive S.Hornet [Identity/Escom]" }, \ | ||
77 | { 0x00146, 72, wake_up_mountain, "Archive 31250Q [Escom]" }, \ | ||
78 | { 0x0014a, 100, wake_up_mountain, "Archive XL9250i [Conner/Escom]" }, \ | ||
79 | { 0x0014c, 98, wake_up_mountain, "Conner C250MQT" }, \ | ||
80 | { 0x0014e, 80, wake_up_mountain, "Conner C250MQ" }, \ | ||
81 | { 0x00150, 80, wake_up_mountain, "Conner TSM420R/TST800R" }, \ | ||
82 | { 0x00152, 80, wake_up_mountain, "Conner TSM850R" }, \ | ||
83 | { 0x00156, 80, wake_up_mountain, "Conner TSM850R/1700R/TST3200R" }, \ | ||
84 | { 0x00180, 0, wake_up_mountain, "Summit SE 150" }, \ | ||
85 | { 0x00181, 85, wake_up_mountain, "Summit SE 250, Mountain FS8000" }, \ | ||
86 | { 0x001c1, 82, no_wake_up, "Wangtek 3040F" }, \ | ||
87 | { 0x001c8, 64, no_wake_up, "Wangtek 3080F" }, \ | ||
88 | { 0x001c8, 64, wake_up_colorado, "Wangtek 3080F" }, \ | ||
89 | { 0x001ca, 67, no_wake_up, "Wangtek 3080F (new)" }, \ | ||
90 | { 0x001cc, 77, wake_up_colorado, "Wangtek 3200 / Teac 700" }, \ | ||
91 | { 0x001cd, 75, wake_up_colorado, "Reveal TB1400" }, \ | ||
92 | { 0x00380, 85, wake_up_colorado, "Exabyte Eagle-96" }, \ | ||
93 | { 0x00381, 85, wake_up_colorado, "Exabyte Eagle TR-3" }, \ | ||
94 | { 0x00382, 85, wake_up_colorado, "Exabyte Eagle TR-3" }, \ | ||
95 | { 0x003ce, 77, wake_up_colorado, "Teac 800" }, \ | ||
96 | { 0x003cf, 0, wake_up_colorado, "Teac FT3010TR" }, \ | ||
97 | { 0x08880, 64, no_wake_up, "Iomega 250, Ditto 800" }, \ | ||
98 | { 0x08880, 64, wake_up_colorado, "Iomega 250, Ditto 800" }, \ | ||
99 | { 0x08880, 64, wake_up_insight, "Iomega 250, Ditto 800" }, \ | ||
100 | { 0x08881, 80, wake_up_colorado, "Iomega 700" }, \ | ||
101 | { 0x08882, 80, wake_up_colorado, "Iomega 3200" }, \ | ||
102 | { 0x08883, 80, wake_up_colorado, "Iomega DITTO 2GB" }, \ | ||
103 | { 0x00021, 70, no_wake_up, "AIWA CT-803" }, \ | ||
104 | { 0x004c0, 80, no_wake_up, "AIWA TD-S1600" }, \ | ||
105 | { 0x00021, 0, wake_up_mountain, "COREtape QIC80" }, \ | ||
106 | { 0x00441, 0, wake_up_mountain, "ComByte DoublePlay" }, \ | ||
107 | { 0x00481, 127, wake_up_mountain, "PERTEC MyTape 800" }, \ | ||
108 | { 0x00483, 130, wake_up_mountain, "PERTEC MyTape 3200" }, \ | ||
109 | { UNKNOWN_VENDOR, 0, no_wake_up, "unknown" } \ | ||
110 | } | ||
111 | |||
112 | #define QIC117_MAKE_CODES { \ | ||
113 | { 0, "Unassigned" }, \ | ||
114 | { 1, "Alloy Computer Products" }, \ | ||
115 | { 2, "3M" }, \ | ||
116 | { 3, "Tandberg Data" }, \ | ||
117 | { 4, "Colorado" }, \ | ||
118 | { 5, "Archive/Conner" }, \ | ||
119 | { 6, "Mountain/Summit Memory Systems" }, \ | ||
120 | { 7, "Wangtek/Rexon/Tecmar" }, \ | ||
121 | { 8, "Sony" }, \ | ||
122 | { 9, "Cipher Data Products" }, \ | ||
123 | { 10, "Irwin Magnetic Systems" }, \ | ||
124 | { 11, "Braemar" }, \ | ||
125 | { 12, "Verbatim" }, \ | ||
126 | { 13, "Core International" }, \ | ||
127 | { 14, "Exabyte" }, \ | ||
128 | { 15, "Teac" }, \ | ||
129 | { 16, "Gigatek" }, \ | ||
130 | { 17, "ComByte" }, \ | ||
131 | { 18, "PERTEC Memories" }, \ | ||
132 | { 19, "Aiwa" }, \ | ||
133 | { 71, "Colorado" }, \ | ||
134 | { 546, "Iomega Inc" }, \ | ||
135 | } | ||
136 | |||
137 | #endif /* _FTAPE_VENDORS_H */ | ||
diff --git a/include/linux/ftape.h b/include/linux/ftape.h deleted file mode 100644 index 7e7038cba86a..000000000000 --- a/include/linux/ftape.h +++ /dev/null | |||
@@ -1,201 +0,0 @@ | |||
1 | #ifndef _FTAPE_H | ||
2 | #define _FTAPE_H | ||
3 | |||
4 | /* | ||
5 | * Copyright (C) 1994-1996 Bas Laarhoven, | ||
6 | * (C) 1996-1997 Claus-Justus Heine. | ||
7 | |||
8 | This program is free software; you can redistribute it and/or modify | ||
9 | it under the terms of the GNU General Public License as published by | ||
10 | the Free Software Foundation; either version 2, or (at your option) | ||
11 | any later version. | ||
12 | |||
13 | This program is distributed in the hope that it will be useful, | ||
14 | but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
15 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
16 | GNU General Public License for more details. | ||
17 | |||
18 | You should have received a copy of the GNU General Public License | ||
19 | along with this program; see the file COPYING. If not, write to | ||
20 | the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. | ||
21 | |||
22 | * | ||
23 | * $Source: /homes/cvs/ftape-stacked/include/linux/ftape.h,v $ | ||
24 | * $Revision: 1.17.6.4 $ | ||
25 | * $Date: 1997/11/25 01:52:54 $ | ||
26 | * | ||
27 | * This file contains global definitions, typedefs and macro's | ||
28 | * for the QIC-40/80/3010/3020 floppy-tape driver for Linux. | ||
29 | */ | ||
30 | |||
31 | #define FTAPE_VERSION "ftape v3.04d 25/11/97" | ||
32 | |||
33 | #ifdef __KERNEL__ | ||
34 | #include <linux/interrupt.h> | ||
35 | #include <linux/mm.h> | ||
36 | #endif | ||
37 | #include <linux/types.h> | ||
38 | #include <linux/mtio.h> | ||
39 | |||
40 | #define FT_SECTOR(x) (x+1) /* sector offset into real sector */ | ||
41 | #define FT_SECTOR_SIZE 1024 | ||
42 | #define FT_SECTORS_PER_SEGMENT 32 | ||
43 | #define FT_ECC_SECTORS 3 | ||
44 | #define FT_SEGMENT_SIZE ((FT_SECTORS_PER_SEGMENT - FT_ECC_SECTORS) * FT_SECTOR_SIZE) | ||
45 | #define FT_BUFF_SIZE (FT_SECTORS_PER_SEGMENT * FT_SECTOR_SIZE) | ||
46 | |||
47 | /* | ||
48 | * bits of the minor device number that define drive selection | ||
49 | * methods. Could be used one day to access multiple tape | ||
50 | * drives on the same controller. | ||
51 | */ | ||
52 | #define FTAPE_SEL_A 0 | ||
53 | #define FTAPE_SEL_B 1 | ||
54 | #define FTAPE_SEL_C 2 | ||
55 | #define FTAPE_SEL_D 3 | ||
56 | #define FTAPE_SEL_MASK 3 | ||
57 | #define FTAPE_SEL(unit) ((unit) & FTAPE_SEL_MASK) | ||
58 | #define FTAPE_NO_REWIND 4 /* mask for minor nr */ | ||
59 | |||
60 | /* the following two may be reported when MTIOCGET is requested ... */ | ||
61 | typedef union { | ||
62 | struct { | ||
63 | __u8 error; | ||
64 | __u8 command; | ||
65 | } error; | ||
66 | long space; | ||
67 | } ft_drive_error; | ||
68 | typedef union { | ||
69 | struct { | ||
70 | __u8 drive_status; | ||
71 | __u8 drive_config; | ||
72 | __u8 tape_status; | ||
73 | } status; | ||
74 | long space; | ||
75 | } ft_drive_status; | ||
76 | |||
77 | #ifdef __KERNEL__ | ||
78 | |||
79 | #define FT_RQM_DELAY 12 | ||
80 | #define FT_MILLISECOND 1 | ||
81 | #define FT_SECOND 1000 | ||
82 | #define FT_FOREVER -1 | ||
83 | #ifndef HZ | ||
84 | #error "HZ undefined." | ||
85 | #endif | ||
86 | #define FT_USPT (1000000/HZ) /* microseconds per tick */ | ||
87 | |||
88 | /* This defines the number of retries that the driver will allow | ||
89 | * before giving up (and letting a higher level handle the error). | ||
90 | */ | ||
91 | #ifdef TESTING | ||
92 | #define FT_SOFT_RETRIES 1 /* number of low level retries */ | ||
93 | #define FT_RETRIES_ON_ECC_ERROR 3 /* ecc error when correcting segment */ | ||
94 | #else | ||
95 | #define FT_SOFT_RETRIES 6 /* number of low level retries (triple) */ | ||
96 | #define FT_RETRIES_ON_ECC_ERROR 3 /* ecc error when correcting segment */ | ||
97 | #endif | ||
98 | |||
99 | #ifndef THE_FTAPE_MAINTAINER | ||
100 | #define THE_FTAPE_MAINTAINER "the ftape maintainer" | ||
101 | #endif | ||
102 | |||
103 | /* Initialize missing configuration parameters. | ||
104 | */ | ||
105 | #ifndef CONFIG_FT_NR_BUFFERS | ||
106 | # define CONFIG_FT_NR_BUFFERS 3 | ||
107 | #endif | ||
108 | #ifndef CONFIG_FT_FDC_THR | ||
109 | # define CONFIG_FT_FDC_THR 8 | ||
110 | #endif | ||
111 | #ifndef CONFIG_FT_FDC_MAX_RATE | ||
112 | # define CONFIG_FT_FDC_MAX_RATE 2000 | ||
113 | #endif | ||
114 | #ifndef CONFIG_FT_FDC_BASE | ||
115 | # define CONFIG_FT_FDC_BASE 0 | ||
116 | #endif | ||
117 | #ifndef CONFIG_FT_FDC_IRQ | ||
118 | # define CONFIG_FT_FDC_IRQ 0 | ||
119 | #endif | ||
120 | #ifndef CONFIG_FT_FDC_DMA | ||
121 | # define CONFIG_FT_FDC_DMA 0 | ||
122 | #endif | ||
123 | |||
124 | /* Turn some booleans into numbers. | ||
125 | */ | ||
126 | #ifdef CONFIG_FT_PROBE_FC10 | ||
127 | # undef CONFIG_FT_PROBE_FC10 | ||
128 | # define CONFIG_FT_PROBE_FC10 1 | ||
129 | #else | ||
130 | # define CONFIG_FT_PROBE_FC10 0 | ||
131 | #endif | ||
132 | #ifdef CONFIG_FT_MACH2 | ||
133 | # undef CONFIG_FT_MACH2 | ||
134 | # define CONFIG_FT_MACH2 1 | ||
135 | #else | ||
136 | # define CONFIG_FT_MACH2 0 | ||
137 | #endif | ||
138 | |||
139 | /* Insert default settings | ||
140 | */ | ||
141 | #if CONFIG_FT_PROBE_FC10 == 1 | ||
142 | # if CONFIG_FT_FDC_BASE == 0 | ||
143 | # undef CONFIG_FT_FDC_BASE | ||
144 | # define CONFIG_FT_FDC_BASE 0x180 | ||
145 | # endif | ||
146 | # if CONFIG_FT_FDC_IRQ == 0 | ||
147 | # undef CONFIG_FT_FDC_IRQ | ||
148 | # define CONFIG_FT_FDC_IRQ 9 | ||
149 | # endif | ||
150 | # if CONFIG_FT_FDC_DMA == 0 | ||
151 | # undef CONFIG_FT_FDC_DMA | ||
152 | # define CONFIG_FT_FDC_DMA 3 | ||
153 | # endif | ||
154 | #elif CONFIG_FT_MACH2 == 1 /* CONFIG_FT_PROBE_FC10 == 1 */ | ||
155 | # if CONFIG_FT_FDC_BASE == 0 | ||
156 | # undef CONFIG_FT_FDC_BASE | ||
157 | # define CONFIG_FT_FDC_BASE 0x1E0 | ||
158 | # endif | ||
159 | # if CONFIG_FT_FDC_IRQ == 0 | ||
160 | # undef CONFIG_FT_FDC_IRQ | ||
161 | # define CONFIG_FT_FDC_IRQ 6 | ||
162 | # endif | ||
163 | # if CONFIG_FT_FDC_DMA == 0 | ||
164 | # undef CONFIG_FT_FDC_DMA | ||
165 | # define CONFIG_FT_FDC_DMA 2 | ||
166 | # endif | ||
167 | #elif defined(CONFIG_FT_ALT_FDC) /* CONFIG_FT_MACH2 */ | ||
168 | # if CONFIG_FT_FDC_BASE == 0 | ||
169 | # undef CONFIG_FT_FDC_BASE | ||
170 | # define CONFIG_FT_FDC_BASE 0x370 | ||
171 | # endif | ||
172 | # if CONFIG_FT_FDC_IRQ == 0 | ||
173 | # undef CONFIG_FT_FDC_IRQ | ||
174 | # define CONFIG_FT_FDC_IRQ 6 | ||
175 | # endif | ||
176 | # if CONFIG_FT_FDC_DMA == 0 | ||
177 | # undef CONFIG_FT_FDC_DMA | ||
178 | # define CONFIG_FT_FDC_DMA 2 | ||
179 | # endif | ||
180 | #else /* CONFIG_FT_ALT_FDC */ | ||
181 | # if CONFIG_FT_FDC_BASE == 0 | ||
182 | # undef CONFIG_FT_FDC_BASE | ||
183 | # define CONFIG_FT_FDC_BASE 0x3f0 | ||
184 | # endif | ||
185 | # if CONFIG_FT_FDC_IRQ == 0 | ||
186 | # undef CONFIG_FT_FDC_IRQ | ||
187 | # define CONFIG_FT_FDC_IRQ 6 | ||
188 | # endif | ||
189 | # if CONFIG_FT_FDC_DMA == 0 | ||
190 | # undef CONFIG_FT_FDC_DMA | ||
191 | # define CONFIG_FT_FDC_DMA 2 | ||
192 | # endif | ||
193 | #endif /* standard FDC */ | ||
194 | |||
195 | /* some useful macro's | ||
196 | */ | ||
197 | #define NR_ITEMS(x) (int)(sizeof(x)/ sizeof(*x)) | ||
198 | |||
199 | #endif /* __KERNEL__ */ | ||
200 | |||
201 | #endif | ||
diff --git a/include/linux/zftape.h b/include/linux/zftape.h deleted file mode 100644 index b057c65366c6..000000000000 --- a/include/linux/zftape.h +++ /dev/null | |||
@@ -1,87 +0,0 @@ | |||
1 | #ifndef _ZFTAPE_H | ||
2 | #define _ZFTAPE_H | ||
3 | |||
4 | /* | ||
5 | * Copyright (C) 1996, 1997 Claus-Justus Heine. | ||
6 | |||
7 | This program is free software; you can redistribute it and/or modify | ||
8 | it under the terms of the GNU General Public License as published by | ||
9 | the Free Software Foundation; either version 2, or (at your option) | ||
10 | any later version. | ||
11 | |||
12 | This program is distributed in the hope that it will be useful, | ||
13 | but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
15 | GNU General Public License for more details. | ||
16 | |||
17 | You should have received a copy of the GNU General Public License | ||
18 | along with this program; see the file COPYING. If not, write to | ||
19 | the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. | ||
20 | |||
21 | * | ||
22 | * $Source: /homes/cvs/ftape-stacked/include/linux/zftape.h,v $ | ||
23 | * $Revision: 1.12 $ | ||
24 | * $Date: 1997/10/21 11:02:37 $ | ||
25 | * | ||
26 | * Special ioctl and other global info for the zftape VFS | ||
27 | * interface for the QIC-40/80/3010/3020 floppy-tape driver for | ||
28 | * Linux. | ||
29 | */ | ||
30 | |||
31 | #define ZFTAPE_VERSION "zftape for " FTAPE_VERSION | ||
32 | |||
33 | #include <linux/ftape.h> | ||
34 | |||
35 | #define ZFTAPE_LABEL "Ftape - The Linux Floppy Tape Project!" | ||
36 | |||
37 | /* Bits of the minor device number that control the operation mode */ | ||
38 | #define ZFT_Q80_MODE (1 << 3) | ||
39 | #define ZFT_ZIP_MODE (1 << 4) | ||
40 | #define ZFT_RAW_MODE (1 << 5) | ||
41 | #define ZFT_MINOR_OP_MASK (ZFT_Q80_MODE | \ | ||
42 | ZFT_ZIP_MODE | \ | ||
43 | ZFT_RAW_MODE) | ||
44 | #define ZFT_MINOR_MASK (FTAPE_SEL_MASK | \ | ||
45 | ZFT_MINOR_OP_MASK | \ | ||
46 | FTAPE_NO_REWIND) | ||
47 | |||
48 | #ifdef ZFT_OBSOLETE | ||
49 | struct mtblksz { | ||
50 | unsigned int mt_blksz; | ||
51 | }; | ||
52 | #define MTIOC_ZFTAPE_GETBLKSZ _IOR('m', 104, struct mtblksz) | ||
53 | #endif | ||
54 | |||
55 | #ifdef __KERNEL__ | ||
56 | |||
57 | extern int zft_init(void); | ||
58 | |||
59 | static inline __s64 zft_div_blksz(__s64 value, __u32 blk_sz) | ||
60 | { | ||
61 | if (blk_sz == 1) { | ||
62 | return value; | ||
63 | } else { | ||
64 | return (__s64)(((__u32)(value >> 10) + (blk_sz >> 10) - 1) | ||
65 | / (blk_sz >> 10)); | ||
66 | } | ||
67 | } | ||
68 | |||
69 | static inline __s64 zft_mul_blksz(__s64 value, __u32 blk_sz) | ||
70 | { | ||
71 | if (blk_sz == 1) { | ||
72 | return value; | ||
73 | } else { | ||
74 | /* if blk_sz != 1, then it is a multiple of 1024. In | ||
75 | * this case, `value' will also fit into 32 bits. | ||
76 | * | ||
77 | * Actually, this limits the capacity to 42 | ||
78 | * bits. This is (2^32)*1024, roughly a thousand | ||
79 | * times 2GB, or 3 Terabytes. Hopefully this is enough | ||
80 | */ | ||
81 | return(__s64)(((__u32)(value)*(blk_sz>>10))<<10); | ||
82 | } | ||
83 | } | ||
84 | |||
85 | #endif | ||
86 | |||
87 | #endif | ||