FreeBSD/Linux Kernel Cross Reference
sys/coda/00READ
1 What needs to be done to port Coda to a different Architecture.
2
3 I. Fixes for the Coda applications
4
5 Coda is a package under net/coda_*; so it should be easy enough to
6 build. But there are a few specific files that need to be changed
7 first. Of course, setting it up and using it is harder.
8
9 1. coda/lib-src/mlwp/process.s
10
11 Coda coda/mlwp/ implements light weight user threads. The process.s
12 file contains stack switching code. It needs to be recoded for your
13 architecture. There is some old dead code in the file that you might
14 be able to resurrect for other platforms. At present, only the x86
15 case, ns32k case and arm32 case (and possibly linux sparc) work.
16
17 2. coda/coda-src/venus/fso_cfscalls2.cc
18
19 The Coda file system expands the strings @cputype and @sys in file
20 names in a platform specific way. In fso_cfscalls2.cc, under a
21 __NetBSD__ conditional, there is platform conditional that defines:
22 static char cputype []
23 static char systype []
24 Add the values for these strings under a conditional for your
25 architecture.
26
27 II. Fixes for the Coda kernel
28
29 The coda/ directory in the kernel is machine independent. The various
30 pieces of glue code, viz. conf/files, sys/vnode.h, are in place. You
31 do have a few platform changes:
32
33 1. src/sys/arch/xxx/conf/GENERIC or others
34
35 It would be best to take the few lines that define Coda and its communications
36 pseudo device from the x86 GENERIC and put them into your platform GENERIC.
37 They should look something like:
38 file-system CODA # Coda File System; also needs vcoda (below)
39 # a pseudo device needed for Coda # also needs CODA (above)
40 pseudo-device vcoda 4 # coda minicache <-> venus comm.
41
42
43 2. src/sys/arch/xxx/conf/majors.xxx
44
45 Coda needs a pseudodevice, vcoda, to communicate between the kernel and the
46 out of kernel client program, venus.
47
48 By way of example for the x86, you add:
49
50 device-major vcoda char 60 vcoda
51
52 to the majors file.
53
54 3. src/etc/xxx/MAKEDEV
55
56 Something like the code below should work; The chr device
57 that is appropriate for your platform should be used instead of 60.
58
59 cfs0)
60 name=cfs; unit=${i#cfs}; chr=60
61 rm -f $name$unit
62 mknod $name$unit c $chr $unit
63 chown root.wheel $name$unit
64 ;;
65
66 We only support one device currently, but historically it is cfs0.
67
68
69 III. More?
70
71 There still may be a couple of other problems. If so, let us know.
Cache object: 81089849ef9d1938e436ee6655a9334f
|