Remove remainings of the oltr(4).
[dragonfly.git] / sys / contrib / dev / fla / prep.fla.sh
CommitLineData
984263bc
MD
1#!/bin/sh
2# $FreeBSD: src/sys/contrib/dev/fla/prep.fla.sh,v 1.2 1999/09/08 12:42:15 phk Exp $
1de703da 3# $DragonFly: src/sys/contrib/dev/fla/Attic/prep.fla.sh,v 1.2 2003/06/17 04:28:20 dillon Exp $
984263bc
MD
4
5dev=fla0
6
7grep "$dev.*sectors" /var/run/dmesg.boot | tr -d '(:)' | awk '
8 {
9 v = $3
10 c = $5
11 h = $7
12 s = $9
13 ss = c * h * s - s
14
15 print "#",$0 > "_"
16 print "g c"c" h"h" s"s > "_"
17 print "p 1 165",s,ss > "_"
18 print "a 1" > "_"
19
20 print "#",$0 > "__"
21 print "type: ESDI" > "__"
22 print "disk:", $1 > "__"
23 print "label:" > "__"
24 print "flags:" > "__"
25 print "bytes/sector: 512" > "__"
26 print "sectors/track:", s > "__"
27 print "tracks/cylinder:", h > "__"
28 print "sectors/cylinder:", s * h > "__"
29 print "cylinders:", c > "__"
30 print "sectors/unit:", ss > "__"
31 print "rpm: 3600" > "__"
32 print "interleave: 1" > "__"
33 print "trackskew: 0" > "__"
34 print "cylinderskew: 0" > "__"
35 print "headswitch: 0 # milliseconds" > "__"
36 print "track-to-track seek: 0 # milliseconds" > "__"
37 print "drivedata: 0 " > "__"
38 print "8 partitions:" > "__"
39 print "# size offset fstype [fsize bsize bps/cpg]" > "__"
40 print "a:",ss,"0 4.2BSD 512 4096 " > "__"
41 print "c:",ss,"0 unused 0 0" > "__"
42 }
43'
44fdisk -f _ -i -v $dev
45disklabel -BrR ${dev} __
46newfs /dev/r${dev}a