From 5ab868fd905c68a6fc934d2c2df514c9efae6598 Mon Sep 17 00:00:00 2001 From: Robert Morris Date: Mon, 30 Aug 2010 06:38:58 -0400 Subject: [PATCH 1/5] set only PG and WP in vminit; the rest don't seem to be needed and are confusing --- main.c | 2 +- user.h | 1 + vm.c | 5 +++-- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/main.c b/main.c index a6088cb..c8aa53a 100644 --- a/main.c +++ b/main.c @@ -41,7 +41,7 @@ void mainc(void) { cprintf("\ncpu%d: starting xv6\n\n", cpu->id); - kvmalloc(); // initialze the kernel page table + kvmalloc(); // initialize the kernel page table pinit(); // process table tvinit(); // trap vectors binit(); // buffer cache diff --git a/user.h b/user.h index 8280b2e..431428c 100644 --- a/user.h +++ b/user.h @@ -21,6 +21,7 @@ int dup(int); int getpid(); char* sbrk(int); int sleep(int); +int uptime(); // ulib.c int stat(char*, struct stat*); diff --git a/vm.c b/vm.c index 98ac108..ffdcab3 100644 --- a/vm.c +++ b/vm.c @@ -375,8 +375,9 @@ vminit(void) lcr3(PADDR(kpgdir)); cr0 = rcr0(); - cr0 |= CR0_PE|CR0_PG|CR0_AM|CR0_WP|CR0_NE|CR0_TS|CR0_EM|CR0_MP; - cr0 &= ~(CR0_TS|CR0_EM); + // cr0 |= CR0_PE|CR0_PG|CR0_AM|CR0_WP|CR0_NE|CR0_TS|CR0_EM|CR0_MP; + // cr0 &= ~(CR0_TS|CR0_EM); + cr0 |= CR0_PG | CR0_WP; lcr0(cr0); } From 8d8d6c7be31a4fe8aaff131ad72e271e14202b35 Mon Sep 17 00:00:00 2001 From: Robert Morris Date: Mon, 30 Aug 2010 06:48:48 -0400 Subject: [PATCH 2/5] we don't need CR0_WP --- vm.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/vm.c b/vm.c index ffdcab3..20afa28 100644 --- a/vm.c +++ b/vm.c @@ -375,9 +375,7 @@ vminit(void) lcr3(PADDR(kpgdir)); cr0 = rcr0(); - // cr0 |= CR0_PE|CR0_PG|CR0_AM|CR0_WP|CR0_NE|CR0_TS|CR0_EM|CR0_MP; - // cr0 &= ~(CR0_TS|CR0_EM); - cr0 |= CR0_PG | CR0_WP; + cr0 |= CR0_PG; lcr0(cr0); } From 4d972493b66d4841c135cf56414f9f54bac948bc Mon Sep 17 00:00:00 2001 From: Robert Morris Date: Mon, 30 Aug 2010 07:26:54 -0400 Subject: [PATCH 3/5] no more xv6.pdf .ps --- xv6.pdf | Bin 147427 -> 0 bytes xv6.ps | 23941 ------------------------------------------------------ 2 files changed, 23941 deletions(-) delete mode 100644 xv6.pdf delete mode 100644 xv6.ps diff --git a/xv6.pdf b/xv6.pdf deleted file mode 100644 index 51e8834468dc53f3515a3590b255d26bf63956da..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 147427 zcma%?Q;;Cd!fo5OZQHhOyL;NUZQHhO+dXaDwtJd)&bhxLzL)b-yCPpIs-m)T#oAe< z3L;{(jC3qeq+?fcg;1;n3`O!B=_le)r$yPHnAU@+}6%odx7AsbIekBFO&(g&x++ z9!0)rE>q1HIkrQRFUj#->LBu1xY~z^swmO>W6D$7|7s?(T4pEDmxrWF>J}&#_Sok+ zu!JrDg*ZLy^;I^OUR)Y%$(Ssf5+#&O#;BB1tmaHKiL|RHon)%iJ=)_anI|IoD1(}! zMjG3j`fz^dVs{c_W{9CZw<}tMNm#o1{ma|y46z|shm!WeOsj%N-Aa}Wxmb3)xU?c9 zWaWetz50z251^^f97em1RfdL8XJ|u+R#bOkkp+(qDdw}dvg!Te&n^nO_D^<}#(YKnhGUY^gJuP1%CJ~tIq^FnGxK$~Y#JSD{$j-JKay9{bd z`b)DkWN)yexlRBXr`X{J=z4+W0A zZ(af$NxL~tHbNnW78Ih;&ubiK2O>V%N;HFUIjgA1vZ6WdLgYk`ForyJTJcIY=p0dm zOgye3ErSSujw{JxRKnm?kuIcEN>V|S7y#-9#tG7mnb3tOqUZZq$$*RO6 zh9KRa941xX)dxD}E$#zCawHY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g;m0b3#LjK-1G z;P0WqxKs_{6G7WYwiyC+zKTT`aLyc2zCa$_252=XF$Fr#F!Oamj$;U zBoA&Ev>E|}sFOe*8=pub!rCwR4kA)#0zJAA>$ees1zEor=uC#fH!;5l(cpbI$b$^W z0nl(4-sgc4D;bKm1DA&!-{TP&0s~?QK!=c-dC_WQFdT)^fVYB=>%ie0;G$XIgJ^IZ z0P>*66lTc-$b;JyjRyq>ulGP6bc%|Z7vzCx3m^{!FC-6M$I*Cj$QD-rAbE(s8_?kW z5y*pp@Z&%pybhs(`-4I+z;vcxQ39vIu?xt91ovT(JSe&nGcTYa>kH_n;qQTOLyT=f z9%Sgi9$X%xodZ`#MwTxdd`X~(No1A>f{D=Y(PO3oqY&YJHyXGhWIZL&Pp>iag6{y} zidAQj2mSml^Lvmy`1l!(2SW>Fy;4Jt83+hJ1o8kajx}FM9$aTMo=m^Yg;^J%GZ-MS z@N+&7^KWHb~F4lWNq4g=pohK~%L7z=*7wk$IwR^X5l=$;CQzM`WsaQh1h?M7+b^03#!WE&&_n_lXtU}9 z>5Rbppqqxz9fIjFGGYt|nR4r>_Lp-h$MQ{NM@U&iDY^x zY-Spehlipz!f9|n1oEH (mpage) -%%LanguageLevel: 2 -%%DocumentSuppliedResources: (atend) -%%DocumentMedia: plain 612 792 0 () () -%%BoundingBox: 0 0 612 792 -%%Pages: 80 -%%EndComments -%%BeginDefaults -%%PageMedia: plain -%%EndDefaults -%%BeginProlog -%%BeginResource: procset xpdf 3.02 0 -%%Copyright: Copyright 1996-2007 Glyph & Cog, LLC -/xpdf 75 dict def xpdf begin -% PDF special state -/pdfDictSize 15 def -/pdfSetup { - 3 1 roll 2 array astore - /setpagedevice where { - pop 3 dict begin - /PageSize exch def - /ImagingBBox null def - /Policies 1 dict dup begin /PageSize 3 def end def - { /Duplex true def } if - currentdict end setpagedevice - } { - pop pop - } ifelse -} def -/pdfStartPage { - pdfDictSize dict begin - /pdfFillCS [] def - /pdfFillXform {} def - /pdfStrokeCS [] def - /pdfStrokeXform {} def - /pdfFill [0] def - /pdfStroke [0] def - /pdfFillOP false def - /pdfStrokeOP false def - /pdfLastFill false def - /pdfLastStroke false def - /pdfTextMat [1 0 0 1 0 0] def - /pdfFontSize 0 def - /pdfCharSpacing 0 def - /pdfTextRender 0 def - /pdfTextRise 0 def - /pdfWordSpacing 0 def - /pdfHorizScaling 1 def - /pdfTextClipPath [] def -} def -/pdfEndPage { end } def -% PDF color state -/cs { /pdfFillXform exch def dup /pdfFillCS exch def - setcolorspace } def -/CS { /pdfStrokeXform exch def dup /pdfStrokeCS exch def - setcolorspace } def -/sc { pdfLastFill not { pdfFillCS setcolorspace } if - dup /pdfFill exch def aload pop pdfFillXform setcolor - /pdfLastFill true def /pdfLastStroke false def } def -/SC { pdfLastStroke not { pdfStrokeCS setcolorspace } if - dup /pdfStroke exch def aload pop pdfStrokeXform setcolor - /pdfLastStroke true def /pdfLastFill false def } def -/op { /pdfFillOP exch def - pdfLastFill { pdfFillOP setoverprint } if } def -/OP { /pdfStrokeOP exch def - pdfLastStroke { pdfStrokeOP setoverprint } if } def -/fCol { - pdfLastFill not { - pdfFillCS setcolorspace - pdfFill aload pop pdfFillXform setcolor - pdfFillOP setoverprint - /pdfLastFill true def /pdfLastStroke false def - } if -} def -/sCol { - pdfLastStroke not { - pdfStrokeCS setcolorspace - pdfStroke aload pop pdfStrokeXform setcolor - pdfStrokeOP setoverprint - /pdfLastStroke true def /pdfLastFill false def - } if -} def -% build a font -/pdfMakeFont { - 4 3 roll findfont - 4 2 roll matrix scale makefont - dup length dict begin - { 1 index /FID ne { def } { pop pop } ifelse } forall - /Encoding exch def - currentdict - end - definefont pop -} def -/pdfMakeFont16 { - exch findfont - dup length dict begin - { 1 index /FID ne { def } { pop pop } ifelse } forall - /WMode exch def - currentdict - end - definefont pop -} def -% graphics state operators -/q { gsave pdfDictSize dict begin } def -/Q { - end grestore - /pdfLastFill where { - pop - pdfLastFill { - pdfFillOP setoverprint - } { - pdfStrokeOP setoverprint - } ifelse - } if -} def -/cm { concat } def -/d { setdash } def -/i { setflat } def -/j { setlinejoin } def -/J { setlinecap } def -/M { setmiterlimit } def -/w { setlinewidth } def -% path segment operators -/m { moveto } def -/l { lineto } def -/c { curveto } def -/re { 4 2 roll moveto 1 index 0 rlineto 0 exch rlineto - neg 0 rlineto closepath } def -/h { closepath } def -% path painting operators -/S { sCol stroke } def -/Sf { fCol stroke } def -/f { fCol fill } def -/f* { fCol eofill } def -% clipping operators -/W { clip newpath } def -/W* { eoclip newpath } def -/Ws { strokepath clip newpath } def -% text state operators -/Tc { /pdfCharSpacing exch def } def -/Tf { dup /pdfFontSize exch def - dup pdfHorizScaling mul exch matrix scale - pdfTextMat matrix concatmatrix dup 4 0 put dup 5 0 put - exch findfont exch makefont setfont } def -/Tr { /pdfTextRender exch def } def -/Ts { /pdfTextRise exch def } def -/Tw { /pdfWordSpacing exch def } def -/Tz { /pdfHorizScaling exch def } def -% text positioning operators -/Td { pdfTextMat transform moveto } def -/Tm { /pdfTextMat exch def } def -% text string operators -/cshow where { - pop - /cshow2 { - dup { - pop pop - 1 string dup 0 3 index put 3 index exec - } exch cshow - pop pop - } def -}{ - /cshow2 { - currentfont /FontType get 0 eq { - 0 2 2 index length 1 sub { - 2 copy get exch 1 add 2 index exch get - 2 copy exch 256 mul add - 2 string dup 0 6 5 roll put dup 1 5 4 roll put - 3 index exec - } for - } { - dup { - 1 string dup 0 3 index put 3 index exec - } forall - } ifelse - pop pop - } def -} ifelse -/awcp { - exch { - false charpath - 5 index 5 index rmoveto - 6 index eq { 7 index 7 index rmoveto } if - } exch cshow2 - 6 {pop} repeat -} def -/Tj { - fCol - 1 index stringwidth pdfTextMat idtransform pop - sub 1 index length dup 0 ne { div } { pop pop 0 } ifelse - pdfWordSpacing pdfHorizScaling mul 0 pdfTextMat dtransform 32 - 4 3 roll pdfCharSpacing pdfHorizScaling mul add 0 - pdfTextMat dtransform - 6 5 roll Tj1 -} def -/Tj16 { - fCol - 2 index stringwidth pdfTextMat idtransform pop - sub exch div - pdfWordSpacing pdfHorizScaling mul 0 pdfTextMat dtransform 32 - 4 3 roll pdfCharSpacing pdfHorizScaling mul add 0 - pdfTextMat dtransform - 6 5 roll Tj1 -} def -/Tj16V { - fCol - 2 index stringwidth pdfTextMat idtransform exch pop - sub exch div - 0 pdfWordSpacing pdfTextMat dtransform 32 - 4 3 roll pdfCharSpacing add 0 exch - pdfTextMat dtransform - 6 5 roll Tj1 -} def -/Tj1 { - 0 pdfTextRise pdfTextMat dtransform rmoveto - currentpoint 8 2 roll - pdfTextRender 1 and 0 eq { - 6 copy awidthshow - } if - pdfTextRender 3 and dup 1 eq exch 2 eq or { - 7 index 7 index moveto - 6 copy - currentfont /FontType get 3 eq { fCol } { sCol } ifelse - false awcp currentpoint stroke moveto - } if - pdfTextRender 4 and 0 ne { - 8 6 roll moveto - false awcp - /pdfTextClipPath [ pdfTextClipPath aload pop - {/moveto cvx} - {/lineto cvx} - {/curveto cvx} - {/closepath cvx} - pathforall ] def - currentpoint newpath moveto - } { - 8 {pop} repeat - } ifelse - 0 pdfTextRise neg pdfTextMat dtransform rmoveto -} def -/TJm { pdfFontSize 0.001 mul mul neg 0 - pdfTextMat dtransform rmoveto } def -/TJmV { pdfFontSize 0.001 mul mul neg 0 exch - pdfTextMat dtransform rmoveto } def -/Tclip { pdfTextClipPath cvx exec clip newpath - /pdfTextClipPath [] def } def -% Level 2 image operators -/pdfImBuf 100 string def -/pdfIm { - image - { currentfile pdfImBuf readline - not { pop exit } if - (%-EOD-) eq { exit } if } loop -} def -/pdfImM { - fCol imagemask - { currentfile pdfImBuf readline - not { pop exit } if - (%-EOD-) eq { exit } if } loop -} def -/pr { 2 index 2 index 3 2 roll putinterval 4 add } def -/pdfImClip { - gsave - 0 2 4 index length 1 sub { - dup 4 index exch 2 copy - get 5 index div put - 1 add 3 index exch 2 copy - get 3 index div put - } for - pop pop rectclip -} def -/pdfImClipEnd { grestore } def -% shading operators -/colordelta { - false 0 1 3 index length 1 sub { - dup 4 index exch get 3 index 3 2 roll get sub abs 0.004 gt { - pop true - } if - } for - exch pop exch pop -} def -/funcCol { func n array astore } def -/funcSH { - dup 0 eq { - true - } { - dup 6 eq { - false - } { - 4 index 4 index funcCol dup - 6 index 4 index funcCol dup - 3 1 roll colordelta 3 1 roll - 5 index 5 index funcCol dup - 3 1 roll colordelta 3 1 roll - 6 index 8 index funcCol dup - 3 1 roll colordelta 3 1 roll - colordelta or or or - } ifelse - } ifelse - { - 1 add - 4 index 3 index add 0.5 mul exch 4 index 3 index add 0.5 mul exch - 6 index 6 index 4 index 4 index 4 index funcSH - 2 index 6 index 6 index 4 index 4 index funcSH - 6 index 2 index 4 index 6 index 4 index funcSH - 5 3 roll 3 2 roll funcSH pop pop - } { - pop 3 index 2 index add 0.5 mul 3 index 2 index add 0.5 mul - funcCol sc - dup 4 index exch mat transform m - 3 index 3 index mat transform l - 1 index 3 index mat transform l - mat transform l pop pop h f* - } ifelse -} def -/axialCol { - dup 0 lt { - pop t0 - } { - dup 1 gt { - pop t1 - } { - dt mul t0 add - } ifelse - } ifelse - func n array astore -} def -/axialSH { - dup 0 eq { - true - } { - dup 8 eq { - false - } { - 2 index axialCol 2 index axialCol colordelta - } ifelse - } ifelse - { - 1 add 3 1 roll 2 copy add 0.5 mul - dup 4 3 roll exch 4 index axialSH - exch 3 2 roll axialSH - } { - pop 2 copy add 0.5 mul - axialCol sc - exch dup dx mul x0 add exch dy mul y0 add - 3 2 roll dup dx mul x0 add exch dy mul y0 add - dx abs dy abs ge { - 2 copy yMin sub dy mul dx div add yMin m - yMax sub dy mul dx div add yMax l - 2 copy yMax sub dy mul dx div add yMax l - yMin sub dy mul dx div add yMin l - h f* - } { - exch 2 copy xMin sub dx mul dy div add xMin exch m - xMax sub dx mul dy div add xMax exch l - exch 2 copy xMax sub dx mul dy div add xMax exch l - xMin sub dx mul dy div add xMin exch l - h f* - } ifelse - } ifelse -} def -/radialCol { - dup t0 lt { - pop t0 - } { - dup t1 gt { - pop t1 - } if - } ifelse - func n array astore -} def -/radialSH { - dup 0 eq { - true - } { - dup 8 eq { - false - } { - 2 index dt mul t0 add radialCol - 2 index dt mul t0 add radialCol colordelta - } ifelse - } ifelse - { - 1 add 3 1 roll 2 copy add 0.5 mul - dup 4 3 roll exch 4 index radialSH - exch 3 2 roll radialSH - } { - pop 2 copy add 0.5 mul dt mul t0 add - radialCol sc - encl { - exch dup dx mul x0 add exch dup dy mul y0 add exch dr mul r0 add - 0 360 arc h - dup dx mul x0 add exch dup dy mul y0 add exch dr mul r0 add - 360 0 arcn h f - } { - 2 copy - dup dx mul x0 add exch dup dy mul y0 add exch dr mul r0 add - a1 a2 arcn - dup dx mul x0 add exch dup dy mul y0 add exch dr mul r0 add - a2 a1 arcn h - dup dx mul x0 add exch dup dy mul y0 add exch dr mul r0 add - a1 a2 arc - dup dx mul x0 add exch dup dy mul y0 add exch dr mul r0 add - a2 a1 arc h f - } ifelse - } ifelse -} def -end -%%EndResource -%%EndProlog -%%BeginSetup -xpdf begin -%%BeginResource: font APYGPQ+LucidaSans-Typewriter83 -%!FontType1-1.0: APYGPQ+LucidaSans-Typewriter83 -12 dict begin -/FontInfo 10 dict dup begin -/Notice (Copyright (c) 1991 Bigelow & Holmes Inc. and Y&Y, Inc. (508) 371-3286. All Rights Reserved.) readonly def -/FullName (Lucida Sans Typewriter 83) readonly def -/FamilyName (LucidaSansTypewriter83) readonly def -/isFixedPitch true def -/ItalicAngle 0 def -/UnderlinePosition 0 def -/UnderlineThickness 0 def -end readonly def -/FontName /APYGPQ+LucidaSans-Typewriter83 def -/PaintType 0 def -/FontType 1 def -/FontMatrix [0.00083333 0 0 0.00083333 0 0] readonly def -/FontBBox [0 -170 501 652] readonly def -/StrokeWidth 0 def -/Encoding 256 array -0 1 255 {1 index exch /.notdef put} for -dup 32 /space put -dup 33 /exclam put -dup 34 /quotedbl put -dup 35 /numbersign put -dup 36 /dollar put -dup 37 /percent put -dup 38 /ampersand put -dup 39 /quoteright put -dup 40 /parenleft put -dup 41 /parenright put -dup 42 /asterisk put -dup 43 /plus put -dup 44 /comma put -dup 45 /hyphen put -dup 46 /period put -dup 47 /slash put -dup 48 /zero put -dup 49 /one put -dup 50 /two put -dup 51 /three put -dup 52 /four put -dup 53 /five put -dup 54 /six put -dup 55 /seven put -dup 56 /eight put -dup 57 /nine put -dup 58 /colon put -dup 59 /semicolon put -dup 60 /less put -dup 61 /equal put -dup 62 /greater put -dup 63 /question put -dup 64 /at put -dup 65 /A put -dup 66 /B put -dup 67 /C put -dup 68 /D put -dup 69 /E put -dup 70 /F put -dup 71 /G put -dup 72 /H put -dup 73 /I put -dup 74 /J put -dup 75 /K put -dup 76 /L put -dup 77 /M put -dup 78 /N put -dup 79 /O put -dup 80 /P put -dup 81 /Q put -dup 82 /R put -dup 83 /S put -dup 84 /T put -dup 85 /U put -dup 86 /V put -dup 87 /W put -dup 88 /X put -dup 89 /Y put -dup 90 /Z put -dup 91 /bracketleft put -dup 92 /backslash put -dup 93 /bracketright put -dup 94 /asciicircum put -dup 95 /underscore put -dup 96 /quoteleft put -dup 97 /a put -dup 98 /b put -dup 99 /c put -dup 100 /d put -dup 101 /e put -dup 102 /f put -dup 103 /g put -dup 104 /h put -dup 105 /i put -dup 106 /j put -dup 107 /k put -dup 108 /l put -dup 109 /m put -dup 110 /n put -dup 111 /o put -dup 112 /p put -dup 113 /q put -dup 114 /r put -dup 115 /s put -dup 116 /t put -dup 117 /u put -dup 118 /v put -dup 119 /w put -dup 120 /x put -dup 121 /y put -dup 122 /z put -dup 123 /braceleft put -dup 124 /bar put -dup 125 /braceright put -dup 126 /asciitilde put -readonly def -currentdict end -currentfile eexec -5AA4F71255501637F1A431BAB555283D093E1B588B45B0281559110D21315C62 -BD638C6B34BA54AA75227715D9947EBCD51A104CAEA657499E94138F5645BF68 -368BB1B1EC8E4776F067FFF2CE9B89FB7E63A7DB304498C1036D399C47A4CB79 -BD517EDB02BEB90195FD7DDAF3E839BCE2DB156D9337DBB2305A465B3E0FFB97 -1985C79DC71C47E26F9F0F042B2CDEE97B679358059256FB93D662D43C7ECB5B -1A564DFCECB963478373C69F52172F071E0AA6082A3E10D9E1CE2851CFA210EE -7BD5FCB1AAE15E89D1FB339D587D218B89C18A32F47C7451A80CB1FC07CF5EF5 -C2A9054AD59AE4D5522D8745045620C9C40EAB675A6FE53511D83C04968F37DE -389C3A7A551DC79580FF1B382205C5951A9F8E7B6CEF33E027D608C14A394033 -1E603A09B3061B66BB71AC1D2A232B5F2BC9481D7D44F334ACCBBF6537EF8BC7 -075D89E6422C4E0A415BF3A1B001A284566A4DF8C6877CB0C70D67F5E7FA25E1 -90435DC2AFD452D1184CEA4CBF9F81F8CD7BE3B6EBA8395A40925FDDEB186DE2 -AB0372CF67C17BEE733C73CA29E00C3909E960A0417FCACC7211EBF3DD7225F0 -6F4FB7DBA35BF59A21014E1066BF090958F991C2BFD22CCA4189376B0BBFE928 -8CE7E8D06A551258E5938EB0F85097E557F3C3BA2177A88670054C2473FD9D0F -D9E6EE78BE4DE7D3B32C0A4890438F857B2B893F8CA4A75001BA5A42D90EC4F2 -B0D3E24CE17100E1A20EADBD615C9B006D73287E8A5580ED034E01BB6AFBB7A0 -C1A5D5BE8ED4D234E62C1E772182E6F6963800F7A410EE3FBBC30A5FFB47BBA3 -62C0896EF2CC54DC4ED804FFB912F5407AB4542A2E55201ABBBCED278812B35E -9703C069C38BF54D0E32CD1C0F7873115DFA318F164F6E50342252E9EFE643D5 -E9C5F46AE46E7E21C3DBA8384CD35EE082D11FE17BF955D48E02736A05C23160 -7592275355E00E6967AC691913925629C1F41E0F49804C413205EF4DD853CD4A -AFEFEEB55FAA06A85289F680D6670531DF5F087ABFA6D1B9A2C381186F70CB3C -CE3FC0A3BCABEE4281A7C3DAC0B396BA8CF66077B079929DEFBE76C413ABC1B9 -E14159DE9583E6E10894C743E1C9D3CE4C3676B5A85ACA7E16E3A19B674051C5 -465EC644D5F2AA776BBEC2DA4B1977A85FA5C08E9E4286DD9BD6116B110B7724 -6AD93C41A70B08EE2FA8E1FCCBC5091B57F55D942459893BE6CC261B726BF304 -78E3F84A7C65A1ADB01906F84FEE55EA3E57A3AF2DA474592C95726288B797BF -F751385F38BA7F09673B57BF2ADD79F0A4A6069CD3C238EEB149D77528B84CDD -E31D788A4A5476B55DE425A4A120EEF60DEDE1F42FFE488A01D1ED003AEBE51F -082784D7A5892C9F5806C2914FCB8CA5C4CCDFEF5D4E14DEA1777FEAE33C139B -355BE39D995C9449B3E55807C695200EF55EA2F7EA676A6770164CB127DA7C07 -260FAEC3E976FFF9A350B8641A4D7B8EB2AF8ADBD241670C96F33EF95252FA03 -F0F65E148FA2466B74557628163CCF600D8C8858D515F09312E45FF4938FFDC6 -2BE334D3D9BDF1293532963B6EE923E356E17762BEF9E43461CFCF403CF9307F -AC186610ACF18D27F662455921F450FD6B210EDC50F0C450BA94577C18EABFB0 -A4F21370E1E3194DB8B48668BF3342A5B33D10631C2CC5FC0F2495302A7EDDE9 -B46C85BA080BF1BF5AE4E492ACFBEBC7A358D213D0325ADB982E378B621963DD -E8B0326C8E8162D878D685D25409F83A57577F1C3A0D46D9B6805C68AFEDBC48 -09E4883C54C678FECB4F587F41EBBD6F7B1F656FA528BA27273B92EA24AEA34C -D31FAB98A48968B19BFBC34DCC9CBC40F4EA35783B607966EEBD88E0752F06EB -BF3FE55F88183F5A21AB5B3CC322E5C56CCDD19E40EBE24617D02E4AB3E15CDE -E92DA46DE2357F366ECA16119EA107853FDFE570B7CBEF695FFBCF049E902B4E -CCC477AF9B9875B6D079FF00A302DAD67363BF90E38CD58C46961F7A53CE0C23 -06B0125C2DFF62A9879D24D9A524BDD035375F95790071CB9ABC08D5FF89A3D5 -583C4C33D9F20AEF1B7A12CE819A6194F7116BC7B171C1BF0454763D10EDCE92 -DBB45261F97E88977722DF2C624DBEAF95D18E5CEFCF466C58958C36A48D4190 -01E72651FD55FC8684C19C3183B306D3A061F16CFA7086C3F51CCBA865D88C9A -589F25A52DB95453BBD66E89CB1E6C8059858A4898772A5307A3592889AF708B -EC8CA855D6DD899181CF8DC664EFDF9A8DC9286918B7CD63490660C033471AA8 -2910D2ADF17271D6A680EB97891D247EAFF2A4EC3BF4FF395BCC292402ACBA77 -F7CE635F25EA8D29CCF6DF4121DE62533AD46D3A84E68AD70991E5FEF9EA2EBE -19C2071821C214700AC9D23586F03E97D71ADC38BC97A4CBE534D318853DD3E1 -968978C85F9EDC6ADE6F0BB3E97A1F3ED7BB9936365D0D15DE805EF048E26BBD -9A671078FCED2DBFF6A2FA1361EF137091FFD933EB556768D1B33A4E05048FBC -0E7C672B080578E8F478BB66DAAA9EC09C4F779553D34C0A6A2D9A685A4C040C -99AAE40D8DB6529065539BFA4681AFDFCC4BE7405875F78865D70BE1815B9E3A -D243E623E80332D958019217B70E799BD5AF9779DE42F7291E824AF4F8D0E26D -E76420BD441F4F7516A667BBDD083B40C5FF9476D707B1C10EA2F8C80BE8C9DE -4DA48BD4AE3E661841CBB3AC4EEE0BEAEC612C7C9C748D0697819680D70F91B6 -F58FE67C3B4F8E64587CAC7BDB08C3A2E594B1AC8E97E77E427A8FEC289B5533 -60CDEA1957D4527DAC116E46169D1B70D742494A567425D0417F3134E623A56C -CE14F537A4A8163C335D2FB084AAC9B5440BD23BFF9F708B1C7CB2DF361B639A -B2796CA3BD382D8F26E991C83F1D7449E3C9869B23494A02606E7DA6528797EF -85ACD89D7553701C04F77C5886CD5EC47AE302F3785944090BFC60818B486514 -1322587334EA1DCA899E1B6FB0653BBB16A15781C25B258028CEB1AAAC52016E -A8F2F36A157759A3232654C0576C51F06A370BA928CEB3B6481D57745A5CCAC4 -63B5E306C676DE356BD593692C80026EC4F5DD0B89785A2D8650289F2FEDF380 -23F066B6C104EA6789AD199F36300032371B0AE9BCC92AE9E94280AB95E7BE99 -E69EEE109E5A34D8D192181AD22D814F49DFED9B87149C8C3FA247710B996F6B -52DF6C1ACB344F56878C706E0B4EA2C33274FC47A03E549CCB29D26C1CC50450 -C4F1178015B818357F327FC4098FB65247ACA89F7852A8C5BEF8A61D928D3E29 -792F36AF218C14E22095213B9BF70F4A2AB9F8D41ABAE3F70BFD3E64434ECC5B -8AF293E0657F662F071403F7B2BB2DC191361860DDC9761CF201A9E5DD64D0F1 -EDC9592D92EB02933A4E063E224301316A22F1676DE180193B1063733D5FBF31 -85C98ED0D8C1C459F41A6DF1A614740EF25462C7748AC4615A4C983E88089255 -ECBF5A92B7DDAC6E9BC0C1AC135977F1536CE490985B364118E7753B1B5D40B0 -40DE97B0EFB6A1E09894B24A32B1B2E2ABC02C64D2ECCCB43B8D2CE9BC9ACCC8 -F570F3AA2252EB95EE46B9452DF2EC804879265A0AB41B42BE6BE78777EF9487 -74F81B1B5D92DC44926F3C8421A432589B8C4B6D98BA9602EDB7CF5BDD7DFBDE -B6C37D3FD4112313F2D404AD0770C84E9E9BC3AE4E0A12348B096EE17F95BCBC -874F5F024D3B1E4515FA9457AD089F1C14A6ED93B0A1520C3C8435D8B9CC4FC3 -39DF5D18913CECA2F9FD3DFA46424594315D1400DAC9F2A09299F4C9D7D41E34 -661E0D305E9F62FC4E36BD2FB79021D8CDAABCFAE932E23F74CDA3600121BC33 -517A1F8CF50CFF67224D8F919290534C8CFDF8EA8C688E409BF3E831FBA6B2AC -0BCB08B086D6B8F6243182E8BEF410B7551E32AB6CF2AC674A3A3A926EDEE757 -F19BFCA5BBAABB1523917BCCFA765E1360DEF6269CDB2F18A55AFA721C9C78E5 -27EB85923D08AC830462E485F9A73F4B092703DF336CDCFD15031619597C731A -37E3D119025984C85D76C493BDD17187D760AD92E22CFCFE8145D07CD8400522 -0777845D8746C9A6D111E5F1EF2419276113092AA4F5D41526D6F40C40CD93C4 -4896F797DE2387E2382D8F5A068EE0290C64154C77B0D79399D85E81BB3B028F -96E0CE1AF4021CAAAD279F78B18B54977BE8B5046ADAACC7464AD41B0C0D4E68 -FA2E980EF83C094CB09BFE4FAB84C02C70B88B9D071684DE404BDD0FA567FB66 -EF04E703C9F8580B0A095FF6076E4935A125265C35A49D263E4D3226C1BEE986 -8DEEA8F6ED7541C2EE75BC8FB8330223ACDB932803B4007435B0F36940C86510 -AEED548FD5B9E056EBF6F2484FF612D7681E04D1E87D708D95C64E58385045AC -2A87E7F6AABA9DAC680524CE99C5E7A4DA70A14873FE4A9E4F58CA6BEB0D109E -627947411DE2130D783D43CC6D3D6725F79E5BC46E14385EF63D569BFEDDBFC5 -CE454F9B754EBC68A1DE413063FF6005E027DB80750003B112C93CBEABAA04FC -E07F75A62E7BC5B34E802BAD054E3DD77A436B6A5FCC5B006E38D628F69E0409 -BA8E2D97754CE7C8B00DB026D10E4FDDC3369316BB4E0B944EEC0BF4A5544EF5 -1FA02D9B429267F2C9E852125E556A0D1116D04C2A97BD27C518ED07E952EB11 -2C0B1960FBB05CB5BEBF5C91D1703A671AFF159DF7BA512726FC058213635BA4 -11D64072880D65AEA08C585BE4BBA690528242774855410872E61DA5279908E4 -ABE0948928C1E2E47C61FCB67C9A83E489454F29E18A4E646A6BC5E367D6D84C -4B70D67CDCAA9B729085EB85582265C17E56FD97C71EB9F3472EF2422269D69F -AA40ECB9062D232AAF45AAE6EA95223C95F48F435666C06EA821A00F4F614D6D -457A3CD5AA85614D60B54BC13ABB3264EC1D822FA53ADDC1E7551A9C3CED3A60 -840A2A924BBF48CC951ED9ACBB4B7759CA3A75345DFEA4BD12543421C6E65FC3 -8007DB5EA10F40B4E0797E171F42A0A70486132291040C587F79549AE2A98FA4 -DC43764E8ED321DC920EDF6A79C34839E3C5BB11E7F3CC939AFF71AE82D8BB2B -2C4CDEE000FAC57BD089D8D5C2D6317F85546F65828A62D32C3D43A2A21EAD07 -7338893F0FC2B7C2C2F0D7F8C066549174C6C411D066AD5CBEC6892C2B092866 -3117CE0F58AFA7A2B061DA228B8CB96E533415F9D9E5F80A3E49529418775E22 -59AC479B3BC8A9A1F01CAEE5D95897730BB50C0CAA2D8974EC9B90339D08A840 -DA8E831BC7D2544A636AC9693861A4A37C8EF436896C65398718B4903598FB0A -60DA2F1C172D2362FD0CBC94197EA355ABFEBD7E8E6B95ADC8C219FAAC322876 -312B362C88BC3422379422D3DD17841A2C9D1F32FC15EEE6E780745CAD5A61D4 -FA61A2C3394585C89B5D78165009CA3620F333A6F360E06118C4B7BF69E6675B -57BB57D837E05E1F1F11A3C1276901B507B967BA69B7DE18A17BA10E0DC02828 -811E45FFD3A83CD75E69CB8F8B50F820F7AC6F1DF9776584E7778D683BC6CD2D -A9D611470E6E7AA289576EBEF0202221847E2A46286DAA4366188B425AC2D3D3 -D883B9412725017F3B6C2F35316AA01EAFDEADE1806C48AF7E82EFDDF2A00245 -DA561354F1761D126C030ED21705D89E255931B47EDB1A52C57183DDD4D33F99 -BAB362278939C80F739554D6BFC7119D941A68F33ECC2901AD2B34C0306C47EE -2372E7FE3DEEC8B02789420272BB7CC2FF4DF6D23569A118046033C811232A1D -5BCA1D629A4FF3A2C2492C0243B70C8D090778A766474FBEA9DAB50C3D29B7C5 -66FBB2D444B3C06B7C9241DF74C77DB5ADF648822014C49F9141CA9323594675 -E9640F26D24BF6B9E540034F1ACE1AD766E450865F9DA29B2F8BDF66B4FF8025 -BA11D57A064CCA9B211DAF756A18621F877942D8A30ED103C6186884D68153DD -BBAF399F3D0DF5169B0E94A214B7D18F672A48B937A13133ABC5E9033734B0A2 -12A7B4DD72BE1886ADE94B968D11D29CCDA8251C2A284287037543A6E240CF67 -0EAB7EF796BD4DBD313FD3DC6D3535674184EABDAD1DA7B0A3AAD4B78CF82241 -E378FBF975403D8FAC2AA692686545D1550E8B9F457A396B3F68493A342D1982 -3E6E24DDA7D014EA1A297C38078A3404F0D87CD299DF9BF3C93FB8F236BBCA14 -F71300C5710A43605ABA308D54DBC954C66F03123393A7379C4F20DBBB03DDD5 -C273C234E8EBE27F93347F1E5B3EC0FFCE0440A205DBA5CAC312245AF05BFCC3 -734795D36BE536F56BBE0E6A42E9E9DD7EFC0B6A032E250BE71996B41B743D7D -B2C6DF05A46CAB1FE425D0AEE07284E7A556AADB19B9DB7F4FDE477C87DF72D8 -EEC435D249CC2D564C57F2379E9912A0AAF33661D0CCD213BD1A38EAE0D4535C -08BB493031B1FFD9C030B98C455C9B04304B1E628CB95FFC7FA6AAA12C2D2C83 -9166660FDD6DFC6C0CD04FB951C6BE616A258EDFAAEE4AD926608A4A36B1CD55 -9023D8647CABD029C539163705156A854D36D83EC488258C38C9B1126555D7AC -68B4B770A5800B06D374230A78C9107963B637E39D6DC7497883032EC3055DE6 -CA392F3B2ABA182FC0C468549655B8392E94DB4D85AA14DA0E3B2D3B3DFCAEE3 -F5CF755FF7A7CE0CD930DE5AF138A6262898C2316902934912FAE3924A9833BD -8D5B85F35EA4558E1FB9FFAF597F802F89AFFB5B289884A9F9BAED04084DD7E3 -A985178519BD80E3224F8533AA2D954F75096E490ECB780E6CCFF07D91E02D2C -67AF4A699F81E84134E3EA69467F5514E5F3A73A9936839729E9347BC77B709F -19137F238C2ADAE3858F31034BBEEEE79079F4B2EBE3081701B1B2FB0F114899 -C59DB78F99ED4B980DA4F04251CEE1F478A470C3954E5E83212726EC6673273F -A2285C9AD2BCE145C5EBBB946EA0D58449BE7C77332D1F222EC6C5DF2D559BAD -6E0A3122812688D9D2807F09FC09285FC0B2D3FA570E49A776B00DE85965843A -B9C936AB2C2D8960EE0FABE64C7C983C546795A4C258E4E73AADF310673C9A2D -534055FFC79B03C3E455643AFB8629AC355BAA755FB8DD4AACCBB21F2CCF8FB1 -E51E0B5C608EA149C6E6CFE107113C36FC9C85AED43723B11AED08B1B8661C0D -EB0C7DD1EC047371DE2A4C24A789CA5B186A1AEC4258814A37FE30706D29ED48 -7639345B0CDB29BF192345D5AD372BA3E696964D91CF03748F3950BD649FC102 -A1E09A59AB246350BE4A7831D126472D627758741C8F38B6A01C0DF4C2F27C68 -6ABA6364D88DF009855B73630A4C3FAC44D2F0E2488EB71808D003C12632EE18 -039732BAC01B13E1A4D8C80C8BEF266CD168CB79462C44D0F891B60E0B15CCD8 -81949F998147933D377B10CF3AC3845FC2AA53ACA02AD96DCE8314416D09F2C1 -050AD9AA80448527A9947CC7B9B365C23E950A02FF730D1C3C91CBF14A746E6B -7A2B87FD9561A4FD6254E9A2A3004B0C9A0C2E59CB914178FB114BECC02CD370 -2DAFA039EAD3D35D6CEDB468C1C42404B88BFB70C275D8636293D1A71CB48CAA -D971DDB3252B324A5499E419CCE408BC03B688F0D8774D28D7E5D740110DC5CB -22B3CD013F61BAE5983B56D23143BC45C94CE85769C1846B1E2BFC36DF7BD587 -37919D573819EC3EFAF1EB66E2A07469CE0CE596546EBAB2EEEA5F73645429AC -551E5C8F16966BC0D32D6E1C9C3EF288EF36F977EF3751931BC881935DFC6C40 -E547AD3A923DC51D1072B085F1B23CA0E191BF3D010EA0A01C83C973B835ED74 -7DFB263E2848A83AB9E06F5071F6D252A1FF14ED1A6AA8BC3DA3996207675678 -CFCFB1E134A18D1CC3ABC395CF287E139C4338CBFFAB27345A1541073127C242 -1DA55018AB81A6B3738BF659347D8D70D86B8F4C40B8A9E991DF788399B5F13B -50ED46EEE43CADED29594102E07602154608111060499F7C1C03E5372B415F33 -5A741E8EA5E3F41AF934063C94641F1129204EC1019488EA4FF89D7B003CD643 -7D2314441404815203F7FBC2DD130A5E1C5610457E583363D8B439B75C41C3B2 -05E2348A4A826D4DE429E1B61FABE14FD4ECA2C3DB124E738FF3662840AA03B8 -EF40A8D5C60E86C341D1755EF63F1D82DCA856402B949945265283420BB2B4A4 -FBF7023F2C0B36348145F92EF66D292BE48545C5555E670B5EFB973B29FFE465 -92247869BF8E3F0644CD5754A3D35FA3A1DE5BCCC43F0BE41BA782892DCAE8E5 -5EB501686B68B9C2CDDEA53787D795F59E9C827321CF42062C503F4D4B591BD4 -0F2F661B5487F7ECA6694169D335ED8EC725E53AB0CEB25CAEB9F832E93715D8 -8C8BB6F6742B14CD5F3E837A636DB41DD9C109E9771A2F8C7D7A7D12BBCF650A -BB131F547A894CC90508A936EA97154E81443C052AD474592314BE31FBAB4A79 -4C1992A35BAAE07F6816D542463726930BF25F75AD69AA44E90F55EC8A1AB06B -232EE37734835402F80EBD4E69C375D3E704A38A6DCC903119A7E23217250899 -FA9F1F37773894E24C7054D4B736742FBB054CA11BA2D3F4C3BADC74A84C904D -6A83ED9B0BEA6694C35AE8CCB0D36B92DDFC9962D2C110D99C53CD82B57C855A -B7DB749998FF87F09C6DE41CC2302131B0876A2559E4C24FB292BB477839BD18 -05028C9D217AEFF5FA65147FE25C45E9AB9503C0C90DE3F6FB98284B41192882 -21572BD89F5E970D9ECFAC501145CD0FD0ABC38DA574C0E634B14149F3A80995 -2F6CEBA40F796D7765E629C7020A5F2E5F50ECA761629A52507344F027284E93 -97F9361949AE79D2F7D911AB1F4BA65168A682D09BBDB02979B71223175EC6DD -3FFD963B5D061B59181FCFA92434BA11A578CB8442AFCBA65580C69849A6EADD -8F1D2613362869F8E16D26770C001C1F55B93EA982B6C5CAC6BA6E92A95C03B3 -A8276A01E6FBDCADF623A538CEA34178B6690DF25563B350C18B816A724E2F7D -EB84ECDABF1C2D8AA75437368AA7041E02BFA94446AFD657B423AC4DAD19B2A1 -BDEE4F3A4BBCCE651986FC707BD35922488EC1F354A05EF6497B51277E75FCEE -92177CF4CEC6FCDAF8F899B9B9A71719493D537B7DC78B384487F6D4B898D2EF -99B796B4BED49575CBE63FE809B385FC6CC84AF3AA9F87121CF7D8BEA3C6E986 -A0781F7C920943F43C3F01981C13688F7904CA925A57C527149975371BE9AB45 -FBDB098AA2C62BDA5F44BB282D022DD64CB3FE1568AB770058E372A132456331 -71FDE3E5EA752F47931DD50BD2DC54E52C69EB63E21095DC53C056CBCC05A162 -B4950FFD705C1CE37BFB3E7426260469A80204CE9B68D1C127433ACE8C3FDB27 -FD6F9C6AD71662DA823259BC1B073F829750CB8C2A50E69799F1D58DA0CCBAA8 -EC92AF28104003E13AAEEA0BEEE540696613808D91319FB12E7812FBB2CAAEB3 -A2D3EC0E6D78E720176FD3938D4C62AE1678681E98B6F82F2772356DA8FB9D82 -EB298D383F7D0C3BE5D219DD0AC897B8A2E705F15B2F9AC9306BF39AB6F50BB1 -DADA17AB813BA25513DCA43E685D04D0B44CFC212366D3A1AFC58B4B18D3D4A9 -ECD8D864890F8C03A37E4BEA20866DEF9877065A2C3F666C2862922DC4A021AD -A75DB963BF97B8AFF3D63B89707C86B4E0E5B93BFCA9407021848444ED229F16 -0B2E8889AE97BD4AC2194546FF3555245087A98FEE7B2A38401C8BE18E9D7224 -5437ED0E4E2A8876E0C8633323A2E9A7CD8C704C858FD25311262EFC6534D7A8 -9E0857B5C6282E98938B5D8E216923B0A0A75D84B1807CDFEF19D33A15C47D2A -6DF303E5A179C1752489A9A5FBAF7F00077047551702CD0C08C30E79BAB4BBCA -10AD85AA96D1EC193E05C68B9D46E44B844CA8216A9F535B737606703F07EDEE -B3825E3473244C3F2C5EA13AFD2927C769E48B6A90B41A77D57ED5D1DE504461 -C6D373489B465F0F70F107EE46D5DCABDA14BEFDAA37CE0AF78D5F416AA1456E -3DA7E189860395CFF6236CEDBBC2E0189D3BB92FC5C958A63A641CBD415D2EAF -BC219AD89CA3A17DD335495FF452FBAF85BE0293D9E5E9927196192FE3CD25C2 -C461C62B001A3723A322AF77250B8AB1D83C16858E3FC30EFE7E338663AD9F84 -EC41DCC80171C45D187E8D5C2E7E431E899C4E0644E66958EBADA5F0F6E64D21 -B2539F89570D2C1F17CDBCF5F6CB16A9787C9A4834B2F2A516D909A141F2C614 -B4B7698315DEA7CF292A85578A127BD7E0CFC5D92C57B7EBB10111BA4165E32D -162A740EE2D921BD28B8A7300B198297A58C947919A8A64722764632D9390804 -EB5CB88B984E29A580AB26B544965E3143BCDD2EF47C2738364B3F896E76C1A9 -010B624DCB2EF607984D7657ACB93E87A4E5A280745975644ED00326C559570F -C5CF308F470074A121BDCF2CFB73E0B2A872EDDD0CE746B9DA409DEFC535EB20 -5EB9D59C076EBF6F94D31EBA64ED9BF53B69ECEF4AC19B4F9CFC0BC991581179 -94C3190C95E4F261468E0AB12BFC9C20E7B1C522959E7E761F6C5229EBCF3A86 -FCE964B1371DA44FD114FBF539608B82C6B40AF191818F8B9270530914021CCF -A9F233CF6431C7D23AED734BA58A3C5959E5A2F14FCBAEED5866BB194D8CE6CA -39ABC81C4961FAF1F6C8D66998A2861F0C42B5F95D21DE751130274176C6D363 -E832D3F711916611F6F409AA859A323183B4444EA38E79062F77F30C723A3FD9 -EC9D4D27C8C25555769B2226B66601F7DA8A94A02463E541D8352FCBDDBF1297 -BB482169E9C831640C7BA586DCF00125BC2A7448C384BA5EA898F91152FE0848 -70C084B63689E76B656231CE960D4CA628E1C070AD9A1CE3467DC83453D92E34 -2123676178D378B7D234A7280E83DBA97551467C9457BABEE8835FBB594D03F3 -0C7FF2FA6E308FE763C7C894259FA5D3C66814F6A4C3EFA30A7A4C3E081373EE -3C2EA9F831EA2A7BDDB473401CEFE0DF0EA110ECB4DDC952C05F74461BD3D9C6 -80E3BB0E6E1B6D0AAFBD5A524A3732940CB4854CDEFEC572FEEE79120D436E84 -4186D94ED3B9854450097DB09C514BFBF558BCE425003F6CEF7A5417C8960126 -BC49E6FE3CE87834CC68D540D8E12F502BD63972C802D9715ED49C7B52DE87DA -AA4710B679718F9A71C0A39085D972BE32596C509D27CE809F02960FA7560D66 -678BA0AF4D0A19CA679033B1217D852DB0B6768A6821C72321FA7194E5A62D99 -AF7AE2958947C9965A1838DB932444D886247EE953A1C8A7ED765BF1DE6CD137 -7C749F346437471DD0F0DCCE249D368608BDE06D1FBC1C0236AE40135687A8EC -6D084CDC52FB99D2963FCEF40DC6E0D23AD138F38813DB0AE9B7F731312B7831 -D84A6BA2AA09637C743F686AC572B97D8D72F825E522AD2E3B943476F664A8E9 -63313AE3DAF935EC8CA6B4FC9D396270D24D5705AD16564CBF21A9AA234B6C01 -C5B6C8CDAFF4E3462B74369FB0A63B1EB1DF9696EC7860B3F6E573E34D5E953A -0B25044729B9B19854EF5A3CABAA30D2A62F60588D7171A7732171EAF9EED5D5 -B9DB771F1AEEA1F8F658BBF35E31D88FE3511B9860154DC2A96C1C3FB233A716 -516F36767EBF1D6FECE4DDE153B4E538004E0B66FF827D52A72DDF4699D4EEED -960F974C6ED54F50D9608DEA1785164C73D0B25CA313B3630171177B8EA6A2DC -3D5704DF7A0CD5098BEE074480E862F18D47FBE0F6964125DF29C23D087D0F9A -25292369A7335F33210A4660F425EFD0FD0C3F6534A12ED913697ED4444FC93B -51CF9FFFC2AB8256303E690A71E9EA8B7766E282847681497B52C297F25E60A3 -79B1D70FE503F87E9EBB5FCF1FED71321A2D21B3BFAC5A17F66A2A5CC5BD6D0F -E968A013C33EFC735A161F340F56237CAC1B347F88A4D62249023F6763111497 -4A6F068F4A49B55791D039667EC08BEEECF3E919C4F29FAE5DECE224856FD035 -999318F9B69125586FE6972508505DDE0F129687AB056E5322C1D967FE606151 -71DC9FF6098CE976C0F7BEBD4A5B16E18C1E085894C43C4A1E311B1FA34B75AC -1F444AD9912718855B50CA02AE362D66643EBFF19EA6BE2C8EA4D4339D59C52B -BCBAC2375DF2219D9D56BAA08C4577FB159143886605FC91A09885F9C2E44064 -943BC2B9040E0031BC0744B89782BCDB129A4DDAE418A03FE6EE8705089CD7B3 -C87B18939CCE4361A4C1FFD24072E620D121EBEE435489E8907DF63FF2BD505B -FF50E33DD3B3258F32D96823BCFE4519C7B77C20D2AFE9D00036EFFCE8E586E9 -667891E4D513C3BDC4615AE8369FADF56829F68139416A40C65D736601E47B0C -793C8A7493FC11C9461685966FC974DE827E81ABBC881EAE43712C3DBA1AE5CE -BB1E7FDB696C3221681D75DD419972E6AAA0AF20F8B3826AACBD3B808BEBA198 -D90A5B27CB07C2F753AF493D1863BE77EC132A394F3DAF1F9E3DD07B6BC23765 -6A392A8611D16434BDA4CE27DE4BAA3DBF95BAA05C873CA0A36177F502F87E94 -75662F5368EC605F1E00A98F6B50FB7F522A26C1C9E73D025C3A6428DB735344 -64F704E272CC268798D13D0D93B619E550F1B80562A440E7F2462D9907AEC25F -F3A6E0A4D95B253E3144404DE918C1C40D79B578D8A2C85F943DDC9DB69727CB -957ACF72D67F50D228219C582C434B24C6E3AA6BF2A8194A85D775086929A82B -F0528989A483CE5C7723A2570529C1BDF292FDD988F59D80187A25C47501C2E3 -84C702FE7F4D6C4C6B41F778367897EC91D5A4F8A3FCF300FFA584127C3BC171 -730BCCBB51AD8A85A3810F846797476EA45C4E7A250215A79CD055BBF8B97BAE -DBEB87DA404BAE058875D793264C15010DDC6F6DBD9C45BC5307F6DB4AF867DF -236EBE6CECAA1CFD3CE15FE3EB91ACBDF5433AD03CB971E78823FABF2B3C3BA7 -8ADA62C7B4FB2E65F0D7D4411634645764E198861B589F8529DC2CB6B180889A -E35B5B1BAC735866A4C49A386C1A98A59343060D7995E7C86C3380E65670E94E -4B7C2D2FB94EBDE96773547CFA5053B3B31188BAA0B57A12A2FF6EE7945D5A17 -ED1FE90E30859D3E14EA58A9FD90D5514A115EF7B11C94ADEC8608F60F06D2B0 -46DC9861614ADBD91032A92543BDDF359DA8073FD08E64F9B4D0A7B1DFD6F52A -168E09CD5E2BF9EDA46E77AEA46C25BAC9E0D8220E30D92892426B964E894015 -2F0240EFB5D931EB16EE2423B659D360433A7DCEBA96C031FDA734F0C6E89ED3 -B00946763285821FD3A63D5E0153A4B02E5CC633F6979385C908E73DB718E004 -92105D0F71028D2CD5C0A3E3F06614716B2D48B4A51E9E9D77B058F38B0F7855 -EEC100CF05536D9AC7433A3BF58D4B068E923D4B471B9A0FDA85EECEC3ED9158 -389A10E55F4DE52D2EB5B3CB5D9CC1C24B51F1A19C2F629122B05C03FC8B2A57 -18B06EBDE41C4871BFB1E6A24A85535DF5E088B94EAD6222E07DE110F1B51DB0 -8C1586F7C9711317DF20336D6DE4A2C04A4A1B121F09A2C340B22CA9F26AE7A8 -616DDE1A2D87F9729F82E20BA099D1EAC7F726CCA9D5FA93092DC3886D2529A9 -41B75B58FF112B5F97BD4301627CB3DEE6DEFC44E0392874FB86C51CE77C1969 -2A66E623BF9A64265EF5A68C3B86EFEFEB04C920D16D9F9E037E9FCC621726D5 -69449BBCB0330CAC67F0597509316FE77395FD3ACA40FFDE9CF1976DDF047674 -93683ADF1B1EF9977B03DBF04B2D213C5A67FBA1F99F752C217D672117B9087A -6A5DDA70150BF9988514E786D28336B903B3C96A746E911D7155E49470DC2F37 -41D47249C723DC2E1846A35A67820DEFCCC9462B67B26201EA4D5625CE2DE401 -D186126A214ADCB090CA7D8DAED3A1D8FABCDD8DFE1F0837CCC087A486622C2C -281CC8260608D0896A49019EDF7FDF57D5CE0279E7F491E8370B4954779B4B53 -C6D7B6E2F349283AA0467D9BB06FDDD321BA05F988C5518DA8E48D66D24136BC -271123C27D43408927F0DCBC5DB8D8CAD7E61C46BEEE70F137B087A6899EB040 -145D9AD63C840BC5D030ACDBE4B87A23AF641A64E796336FB31B00B0674AA9CD -B19BDFF46C93DDBA27ED0D8BBF5E6DD642736D594B616C3B26A59C463FB4253A -136DDD4592D6223940C98E4BCE603CCD05D30B3A26B1A4B2C8BEEC799E61907B -855B2CE81549AF2EA116F9DD3A35446CD662EFF77C49DB0BF7B3BBF496D750B6 -E2025B2F041092F322ECF8CD037C5829568CCDE9823BF7F37756DFB7F6D05CC0 -E5B6B6F95A839DF60F9CA9E03AE4E9944ECC2957141606326763789EE4B4D7FC -154A7C3C509362E80D9D2E84967E60B2A14940B08805625EA09988A68BE7AACB -6770F8C05B472FF649514CB7DADE001B7B85E5A849ABC018F34E59292A527A99 -1E2734A3D8D3EF87CDD665814A7CFCB663ACEE51E9E61BF232FFD8F917A5AE70 -57ACF846460F772202A834BE3DB233E117DCFC0A039E04AE30EB0AA3C773CE6A -9EA4E2686283660E068FF095BC780A6F1D4857D7C0789D599798AAF9C71AB082 -6555100BC97C54577AD82D5E063017207922DBE0BF744D51E31A921B27954B60 -95B3695098C47CD0996438CC0F89198ABCA22FEEC261BD0C0B617DC02F553837 -4DD1EC502C935A8DDAF7C73791D7DA2764AA3863D43A5E3EF39AB099CA249A7C -D4CAE2FB83851EFE6863256E432D5F0DC898029C3A069C6EFB8C342B8507182A -44292E6F4E75397621A3DF4F94557AA746C9049B5B86ECE49BFA031F30B3D505 -D42215F78BD2D50E86142B28C2B06A2FD427E5F1C569E58587BB3B531AD4E8AD -10065410A4B3BFEF97070CC87FCAB12C9F0FCB5F1716E00975B2EBE522586123 -A7C33B060079D22EF11DD55A719819AF9CA90B587A11C56F8F9A846BCDB3C930 -AD1E3A490DA0643CB34758E109DD6C91B22C2AD4859101DB53723D3C9C48CC41 -7FF3D9FE1FE57922335D28EC50F0CEE33DCF55A87A0FD383EBDC3D33C8FFFBC7 -05D658873D655635A841C5D8A52294A060DA01A586F63E3EACF1AC7941CDAA7A -1A4DDF5DC5018186B40713A69B759150B3BC3561CA963516783A7BF2D182CFD6 -2529AC360ABDD6863B33C84B3DE527E64E5F1C0B72BAF23B1FF7276773FC2951 -523ACE4D620FC9A1FC5966ABC74D421DAA156B9955B579C781AD87124687BBA2 -DD1116F80D7F6980E10CC387AFF901B19F6CD0667C82932D9123287301A5FD9E -660D5F9E5ABB4A42936BC6DDAE92198CF969FB3D397BA6B1DFE1233752272225 -2B8F0BF0765ED694D50D0BE4F8C09F85713E37E85A3BFD559DAF869E3B6ECF7E -080D71A25B2FF6E38D966C75233D12E3C15A8B4002A985DE92DACB4AD2F6D9C9 -69B09914EC2719A160CDF0BD16E56898B0BD07C1B7747D1C6E591FD66DE00A64 -C5ACDE5D0488D9AAC392DAD684B5F681A554CD6EA6159B6807D861E2FAB69482 -DDB29C8D046AD8A6707BC19DD9494B8E44 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -cleartomark -%%EndResource -/F8_0 /APYGPQ+LucidaSans-Typewriter83 1 1 -[ /.notdef/.notdef/.notdef/.notdef/.notdef/.notdef/.notdef/.notdef - /.notdef/.notdef/.notdef/.notdef/.notdef/.notdef/.notdef/.notdef - /.notdef/.notdef/.notdef/.notdef/.notdef/.notdef/.notdef/.notdef - /.notdef/.notdef/.notdef/.notdef/.notdef/.notdef/.notdef/.notdef - /space/exclam/quotedbl/numbersign/dollar/percent/ampersand/quoteright - /parenleft/parenright/asterisk/plus/comma/hyphen/period/slash - /zero/one/two/three/four/five/six/seven - /eight/nine/colon/semicolon/less/equal/greater/question - /at/A/B/C/D/E/F/G - /H/I/J/K/L/M/N/O - /P/Q/R/S/T/U/V/W - /X/Y/Z/bracketleft/backslash/bracketright/asciicircum/underscore - /quoteleft/a/b/c/d/e/f/g - /h/i/j/k/l/m/n/o - /p/q/r/s/t/u/v/w - /x/y/z/braceleft/bar/braceright/asciitilde/bullet - /Euro/bullet/quotesinglbase/florin/quotedblbase/ellipsis/dagger/daggerdbl - /circumflex/perthousand/Scaron/guilsinglleft/OE/bullet/Zcaron/bullet - /bullet/quoteleft/quoteright/quotedblleft/quotedblright/bullet/endash/emdash - /tilde/trademark/scaron/guilsinglright/oe/bullet/zcaron/Ydieresis - /space/exclamdown/cent/sterling/currency/yen/brokenbar/section - /dieresis/copyright/ordfeminine/guillemotleft/logicalnot/hyphen/registered/macron - /degree/plusminus/twosuperior/threesuperior/acute/mu/paragraph/periodcentered - /cedilla/onesuperior/ordmasculine/guillemotright/onequarter/onehalf/threequarters/questiondown - /Agrave/Aacute/Acircumflex/Atilde/Adieresis/Aring/AE/Ccedilla - /Egrave/Eacute/Ecircumflex/Edieresis/Igrave/Iacute/Icircumflex/Idieresis - /Eth/Ntilde/Ograve/Oacute/Ocircumflex/Otilde/Odieresis/multiply - /Oslash/Ugrave/Uacute/Ucircumflex/Udieresis/Yacute/Thorn/germandbls - /agrave/aacute/acircumflex/atilde/adieresis/aring/ae/ccedilla - /egrave/eacute/ecircumflex/edieresis/igrave/iacute/icircumflex/idieresis - /eth/ntilde/ograve/oacute/ocircumflex/otilde/odieresis/divide - /oslash/ugrave/uacute/ucircumflex/udieresis/yacute/thorn/ydieresis] -pdfMakeFont -612 792 false pdfSetup -%%EndSetup -%%Page: 1 1 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 README Page 1) 144.161 Tj -0 -28.4801 Td -(xv6 is a re-implementation of Dennis Ritchie's and Ken Thompson\ -'s Unix) 305.796 Tj -0 -37.9735 Td -(Version 6 \(v6\). xv6 loosely follows the structure and style \ -of v6,) 292.6905 Tj -0 -47.4668 Td -(but is implemented for a modern x86-based multiprocessor using \ -ANSI C.) 305.796 Tj -0 -66.4535 Td -(ACKNOWLEDGMENTS) 65.5277 Tj -0 -85.4402 Td -(xv6 is inspired by John Lions's Commentary on UNIX 6th Edition \ -\(Peer) 297.059 Tj -0 -94.9336 Td -(to Peer Communications; ISBN: 1-57398-013-7; 1st edition \(June\ - 14,) 288.322 Tj -0 -104.4269 Td -(2000\)\). See also http://pdos.csail.mit.edu/6.828/2007/v6.html\ -, which) 297.059 Tj -0 -113.9203 Td -(provides pointers to on-line resources for v6.) 200.9517 Tj -0 -132.907 Td -(xv6 borrows code from the following sources:) 192.2146 Tj -17.4613 -142.4004 Td -(JOS \(asm.h, elf.h, mmu.h, bootasm.S, ide.c, console.c, and oth\ -ers\)) 288.322 Tj -17.4613 -151.8937 Td -(Plan 9 \(bootother.S, mp.h, mp.c, lapic.c\)) 179.1091 Tj -17.4613 -161.3871 Td -(FreeBSD \(ioapic.c\)) 78.6333 Tj -17.4613 -170.8804 Td -(NetBSD \(console.c\)) 78.6333 Tj -0 -189.8667 Td -(The following people made contributions:) 174.7406 Tj -17.4613 -199.3601 Td -(Russ Cox \(context switching, locking\)) 161.635 Tj -17.4613 -208.8535 Td -(Cliff Frey \(MP\)) 65.5277 Tj -17.4613 -218.3468 Td -(Xiao Yu \(MP\)) 52.4222 Tj -0 -237.3335 Td -(The code in the files that constitute xv6 is) 192.2146 Tj -0 -246.8269 Td -(Copyright 2006-2007 Frans Kaashoek, Robert Morris, and Russ Cox\ -.) 279.5849 Tj -0 -265.8136 Td -(ERROR REPORTS) 56.7907 Tj -0 -284.8003 Td -(If you spot errors or have suggestions for improvement, please \ -send) 292.6905 Tj -0 -294.2936 Td -(email to Frans Kaashoek and Robert Morris \(kaashoek,rtm@csail.\ -mit.edu\). ) 314.533 Tj -0 -313.2803 Td -(BUILDING AND RUNNING XV6) 104.8443 Tj -0 -332.267 Td -(To build xv6 on an x86 ELF machine \(like Linux or FreeBSD\), r\ -un "make".) 310.1645 Tj -0 -341.7604 Td -(On non-x86 or non-ELF machines \(like OS X, even on x86\), you \ -will) 283.9534 Tj -0 -351.2538 Td -(need to install a cross-compiler gcc suite capable of producing\ - x86 ELF) 310.1645 Tj -0 -360.7471 Td -(binaries. See http://pdos.csail.mit.edu/6.828/2007/tools.html.) 275.2164 Tj -0 -370.2405 Td -(Then run "make TOOLPREFIX=i386-jos-elf-".) 179.1091 Tj -0 -389.2272 Td -(To run xv6, you can use Bochs or QEMU, both PC simulators.) 253.3738 Tj -0 -398.7205 Td -(Bochs makes debugging easier, but QEMU is much faster. ) 240.2683 Tj -0 -408.2139 Td -(To run in Bochs, run "make bochs" and then type "c" at the boch\ -s prompt.) 314.533 Tj -0 -417.7073 Td -(To run in QEMU, run "make qemu". Both log the xv6 screen outpu\ -t to ) 297.059 Tj -0 -427.2006 Td -(standard output.) 69.8962 Tj -0 -446.1873 Td -(To create a typeset version of the code, run "make xv6.pdf".) 262.1109 Tj -0 -455.6807 Td -(This requires the "mpage" text formatting utility.) 218.4257 Tj -0 -465.174 Td -(See http://www.mesa.nl/pub/mpage/.) 148.5295 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 table of contents Page 1) 192.2146 Tj -0 -28.4801 Td -(The numbers to the left of the file names in the table are shee\ -t numbers.) 318.9016 Tj -0 -37.9735 Td -(The source code has been printed in a double column format with\ - fifty) 301.4275 Tj -0 -47.4668 Td -(lines per column, giving one hundred lines per sheet \(or page\)\ -.) 275.2164 Tj -0 -56.9602 Td -(Thus there is a convenient relationship between line numbers an\ -d sheet numbers.) 345.1126 Tj -0 -85.4403 Td -(# basic headers) 65.5277 Tj --4514.2 TJm -(# system calls) 61.1592 Tj --5015.87 TJm -(# pipes) 30.5796 Tj -0 -94.9336 Td -(01 types.h) 43.6851 Tj --7022.54 TJm -(24 traps.h) 43.6851 Tj --7022.54 TJm -(51 pipe.c) 39.3166 Tj -0 -104.427 Td -(01 param.h) 43.6851 Tj --7022.54 TJm -(24 vectors.pl) 56.7907 Tj -0 -113.9204 Td -(02 defs.h) 39.3166 Tj --7524.2 TJm -(25 trapasm.S) 52.4222 Tj --6019.2 TJm -(# string operations) 83.0018 Tj -0 -123.4137 Td -(04 x86.h) 34.9481 Tj --8025.87 TJm -(25 trap.c) 39.3166 Tj --7524.2 TJm -(53 string.c) 48.0537 Tj -0 -132.9071 Td -(06 asm.h) 34.9481 Tj --8025.87 TJm -(27 syscall.h) 52.4222 Tj -0 -142.4004 Td -(06 mmu.h) 34.9481 Tj --8025.87 TJm -(27 syscall.c) 52.4222 Tj --6019.2 TJm -(# low-level hardware) 87.3703 Tj -0 -151.8938 Td -(08 elf.h) 34.9481 Tj --8025.87 TJm -(29 sysproc.c) 52.4222 Tj --6019.2 TJm -(54 mp.h) 30.5796 Tj -209.536 -161.3872 Td -(55 mp.c) 30.5796 Tj -0 -170.8805 Td -(# startup) 39.3166 Tj --7524.2 TJm -(# file system) 56.7907 Tj --5517.54 TJm -(56 lapic.c) 43.6851 Tj -0 -180.3739 Td -(09 bootasm.S) 52.4222 Tj --6019.2 TJm -(30 buf.h) 34.9481 Tj --8025.87 TJm -(58 ioapic.c) 48.0537 Tj -0 -189.8672 Td -(10 bootother.S) 61.1592 Tj --5015.87 TJm -(30 fcntl.h) 43.6851 Tj --7022.54 TJm -(59 picirq.c) 48.0537 Tj -0 -199.3606 Td -(11 bootmain.c) 56.7907 Tj --5517.54 TJm -(31 stat.h) 39.3166 Tj --7524.2 TJm -(61 kbd.h) 34.9481 Tj -0 -208.854 Td -(12 main.c) 39.3166 Tj --7524.2 TJm -(31 fs.h) 30.5796 Tj --8527.54 TJm -(62 kbd.c) 34.9481 Tj -104.768 -218.3473 Td -(32 file.h) 39.3166 Tj --7524.2 TJm -(63 console.c) 52.4222 Tj -0 -227.8407 Td -(# locks) 30.5796 Tj --8527.54 TJm -(33 ide.c) 34.9481 Tj --8025.87 TJm -(66 timer.c) 43.6851 Tj -0 -237.334 Td -(13 spinlock.h) 56.7907 Tj --5517.54 TJm -(35 bio.c) 34.9481 Tj -0 -246.8274 Td -(13 spinlock.c) 56.7907 Tj --5517.54 TJm -(36 fs.c) 30.5796 Tj --8527.54 TJm -(# user-level) 52.4222 Tj -104.768 -256.3208 Td -(44 file.c) 39.3166 Tj --7524.2 TJm -(67 initcode.S) 56.7907 Tj -0 -265.8141 Td -(# processes) 48.0537 Tj --6520.87 TJm -(45 sysfile.c) 52.4222 Tj --6019.2 TJm -(67 usys.S) 39.3166 Tj -0 -275.3075 Td -(15 proc.h) 39.3166 Tj --7524.2 TJm -(50 exec.c) 39.3166 Tj --7524.2 TJm -(68 init.c) 39.3166 Tj -0 -284.8008 Td -(16 proc.c) 39.3166 Tj -209.536 -284.8008 Td -(68 sh.c) 30.5796 Tj -0 -294.2942 Td -(22 swtch.S) 43.6851 Tj -0 -303.7876 Td -(22 kalloc.c) 48.0537 Tj -0 -341.7606 Td -(The source listing is preceded by a cross-reference that lists \ -every defined ) 336.3756 Tj -0 -351.2539 Td -(constant, struct, global variable, and function in xv6. Each e\ -ntry gives,) 323.2701 Tj -0 -360.7473 Td -(on the same line as the name, the line number \(or, in a few ca\ -ses, numbers\)) 327.6386 Tj -0 -370.2406 Td -(where the name is defined. Successive lines in an entry list t\ -he line) 305.796 Tj -0 -379.734 Td -(numbers where the name is used. For example, this entry:) 249.0053 Tj -17.4613 -398.7207 Td -(swtch 2208) 43.6851 Tj -34.9226 -408.2141 Td -(0318 1928 1967 2207) 83.0018 Tj -34.9226 -417.7074 Td -(2208) 17.4741 Tj --0 -436.6941 Td -(indicates that swtch is defined on line 2208 and is mentioned o\ -n five lines) 327.6386 Tj --0 -446.1875 Td -(on sheets 03, 19, and 22.) 109.2129 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 2 2 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 cross-references Page 1) 187.8461 Tj -0 -28.4801 Td -(acquire 1373) 52.4222 Tj --12038.8 TJm -(bmap 4010) 39.3166 Tj -17.4613 -37.9735 Td -(0321 1373 1377 1759) 83.0018 Tj --8527.14 TJm -(4010 4036 4119 4169) 83.0018 Tj -17.4613 -47.4664 Td -(1917 1975 2018 2033) 83.0018 Tj --8527.14 TJm -(4222) 17.4741 Tj -17.4613 -56.9594 Td -(2066 2079 2123 2158) 83.0018 Tj --6520.6 TJm -(bootmain 1116) 56.7907 Tj -17.4613 -66.4524 Td -(2315 2362 2616 2971) 83.0018 Tj --8527.14 TJm -(0976 1116) 39.3166 Tj -17.4613 -75.9453 Td -(3407 3465 3570 3629) 83.0018 Tj --6520.6 TJm -(bootothers 1267) 65.5277 Tj -17.4613 -85.4383 Td -(3857 3890 3910 3939) 83.0018 Tj --8527.14 TJm -(1207 1234 1267) 61.1592 Tj -17.4613 -94.9313 Td -(3954 3964 4425 4441) 83.0018 Tj --6520.6 TJm -(BPB 3188) 34.9481 Tj -17.4613 -104.4243 Td -(4456 5213 5234 5255) 83.0018 Tj --8527.14 TJm -(3188 3191 3712 3714) 83.0018 Tj -17.4613 -113.9172 Td -(6360 6516 6558 6606) 83.0018 Tj --8527.14 TJm -(3740) 17.4741 Tj -0 -123.4106 Td -(allocproc 1754) 61.1592 Tj --11035.5 TJm -(bread 3602) 43.6851 Tj -17.4613 -132.9039 Td -(1754 1807 1860) 61.1592 Tj --11035.5 TJm -(0211 3602 3682 3693) 83.0018 Tj -0 -142.3973 Td -(alltraps 2506) 56.7907 Tj --13543.7 TJm -(3713 3739 3811 3832) 83.0018 Tj -17.4613 -151.8907 Td -(2459 2467 2480 2485) 83.0018 Tj --8527.14 TJm -(3917 4026 4068 4119) 83.0018 Tj -17.4613 -161.3836 Td -(2505 2506) 39.3166 Tj --13543.8 TJm -(4169 4222) 39.3166 Tj -0 -170.877 Td -(ALT 6110) 34.9481 Tj --14045.5 TJm -(brelse 3624) 48.0537 Tj -17.4613 -180.3703 Td -(6110 6138 6140) 61.1592 Tj --11035.5 TJm -(0212 3624 3627 3684) 83.0018 Tj -0 -189.8633 Td -(argfd 4563) 43.6851 Tj --15048.7 TJm -(3696 3719 3723 3746) 83.0018 Tj -17.4613 -199.3567 Td -(4563 4606 4621 4633) 83.0018 Tj --8527.14 TJm -(3817 3820 3841 3925) 83.0018 Tj -17.4613 -208.8497 Td -(4644 4656) 39.3166 Tj --13543.8 TJm -(4032 4074 4122 4173) 83.0018 Tj -0 -218.343 Td -(argint 2794) 48.0537 Tj --14547 TJm -(4233 4237) 39.3166 Tj -17.4613 -227.8364 Td -(0339 2794 2808 2824) 83.0018 Tj --6520.6 TJm -(BSIZE 3158) 43.6851 Tj -17.4613 -237.3293 Td -(2931 2956 2969 4568) 83.0018 Tj --8527.14 TJm -(3158 3168 3182 3188) 83.0018 Tj -17.4613 -246.8223 Td -(4621 4633 4858 4921) 83.0018 Tj --8527.14 TJm -(3694 4119 4120 4121) 83.0018 Tj -17.4613 -256.3153 Td -(4922 4957) 39.3166 Tj --13543.8 TJm -(4165 4166 4169 4170) 83.0018 Tj -0 -265.8086 Td -(argptr 2804) 48.0537 Tj --14547 TJm -(4171 4221 4222 4224) 83.0018 Tj -17.4613 -275.302 Td -(0340 2804 4621 4633) 83.0018 Tj --6520.6 TJm -(buf 3000) 34.9481 Tj -17.4613 -284.795 Td -(4656 4982) 39.3166 Tj --13543.8 TJm -(0200 0211 0212 0213) 83.0018 Tj -0 -294.2883 Td -(argstr 2821) 48.0537 Tj --14547 TJm -(0253 3000 3004 3005) 83.0018 Tj -17.4613 -303.7817 Td -(0341 2821 4668 4758) 83.0018 Tj --8527.14 TJm -(3006 3310 3325 3328) 83.0018 Tj -17.4613 -313.2747 Td -(4858 4906 4920 4935) 83.0018 Tj --8527.14 TJm -(3375 3404 3454 3456) 83.0018 Tj -17.4613 -322.7676 Td -(4957) 17.4741 Tj --16052.1 TJm -(3459 3527 3531 3535) 83.0018 Tj -0 -332.2606 Td -(BACK 6861) 39.3166 Tj --15550.3 TJm -(3541 3553 3565 3568) 83.0018 Tj -17.4613 -341.754 Td -(6861 6974 7120 7389) 83.0018 Tj --8527.14 TJm -(3601 3604 3614 3624) 83.0018 Tj -0 -351.2473 Td -(backcmd 6896 7114) 74.2647 Tj --11537 TJm -(3669 3680 3691 3707) 83.0018 Tj -17.4613 -360.7407 Td -(6896 6909 6975 7114) 83.0018 Tj --8527.14 TJm -(3732 3805 3829 3904) 83.0018 Tj -17.4613 -370.2337 Td -(7116 7242 7355 7390) 83.0018 Tj --8527.14 TJm -(4013 4057 4105 4155) 83.0018 Tj -0 -379.727 Td -(BACKSPACE 6450) 61.1592 Tj --13042 TJm -(4215 6328 6339 6342) 83.0018 Tj -17.4613 -389.2204 Td -(6450 6467 6526 6532) 83.0018 Tj --8527.14 TJm -(6345 6503 6524 6537) 83.0018 Tj -0 -398.7137 Td -(balloc 3704) 48.0537 Tj --14547 TJm -(6568 6601 6608 6984) 83.0018 Tj -17.4613 -408.2071 Td -(3704 3725 4017 4025) 83.0018 Tj --8527.14 TJm -(6987 6988 6989 7003) 83.0018 Tj -17.4613 -417.7001 Td -(4029) 17.4741 Tj --16052.1 TJm -(7015 7016 7019 7020) 83.0018 Tj -0 -427.1934 Td -(BBLOCK 3191) 48.0537 Tj --14547 TJm -(7021 7025) 39.3166 Tj -17.4613 -436.6868 Td -(3191 3713 3739) 61.1592 Tj --9028.94 TJm -(bwrite 3614) 48.0537 Tj -0 -446.1801 Td -(bfree 3730) 43.6851 Tj --15048.7 TJm -(0213 3614 3617 3695) 83.0018 Tj -17.4613 -455.6735 Td -(3730 4062 4072 4075) 83.0018 Tj --8527.14 TJm -(3718 3745 3816 3840) 83.0018 Tj -0 -465.1669 Td -(bget 3566) 39.3166 Tj --15550.3 TJm -(4030 4172) 39.3166 Tj -17.4613 -474.6598 Td -(3566 3596 3606) 61.1592 Tj --9028.94 TJm -(bzero 3689) 43.6851 Tj -0 -484.1532 Td -(binit 3539) 43.6851 Tj --15048.7 TJm -(3689 3736) 39.3166 Tj -17.4613 -493.6466 Td -(0210 1227 3539) 61.1592 Tj --9028.94 TJm -(B_BUSY 3009) 48.0537 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 cross-references Page 2) 187.8461 Tj -17.4613 -28.4801 Td -(3009 3458 3576 3577) 83.0018 Tj --8527.14 TJm -(7394) 17.4741 Tj -17.4613 -37.9735 Td -(3588 3591 3616 3626) 83.0018 Tj --6520.6 TJm -(CONSOLE 3290) 52.4222 Tj -17.4613 -47.4668 Td -(3638) 17.4741 Tj --16052.1 TJm -(3290 6621 6622) 61.1592 Tj -0 -56.9602 Td -(B_DIRTY 3011) 52.4222 Tj --12038.8 TJm -(consoleinit 6616) 69.8962 Tj -17.4613 -66.4535 Td -(3011 3387 3416 3421) 83.0018 Tj --8527.14 TJm -(0216 1219 6616) 61.1592 Tj -17.4613 -75.9469 Td -(3460 3479 3618) 61.1592 Tj --9028.94 TJm -(consoleintr 6512) 69.8962 Tj -0 -85.4403 Td -(B_VALID 3010) 52.4222 Tj --14045.3 TJm -(0218 6298 6512) 61.1592 Tj -17.4613 -94.9336 Td -(3010 3420 3460 3479) 83.0018 Tj --6520.6 TJm -(consoleread 6551) 69.8962 Tj -17.4613 -104.427 Td -(3607) 17.4741 Tj --16052.1 TJm -(6551 6622) 39.3166 Tj -0 -113.9203 Td -(C 6131 6509) 48.0537 Tj --12540.5 TJm -(consolewrite 6601) 74.2647 Tj -17.4613 -123.4137 Td -(6131 6179 6204 6205) 83.0018 Tj --8527.14 TJm -(6601 6621) 39.3166 Tj -17.4613 -132.9071 Td -(6206 6207 6208 6210) 83.0018 Tj --6520.6 TJm -(consputc 6487) 56.7907 Tj -17.4613 -142.4004 Td -(6509 6519 6522 6529) 83.0018 Tj --8527.14 TJm -(6315 6345 6366 6384) 83.0018 Tj -17.4613 -151.8938 Td -(6539 6569) 39.3166 Tj --13543.8 TJm -(6387 6391 6392 6487) 83.0018 Tj -0 -161.3871 Td -(CAPSLOCK 6112) 56.7907 Tj --13543.7 TJm -(6526 6532 6538 6608) 83.0018 Tj -17.4613 -170.8805 Td -(6112 6145 6286) 61.1592 Tj --9028.94 TJm -(context 1518) 52.4222 Tj -0 -180.3739 Td -(cgaputc 6455) 52.4222 Tj --14045.3 TJm -(0201 0318 1518 1537) 83.0018 Tj -17.4613 -189.8668 Td -(6455 6496) 39.3166 Tj --13543.8 TJm -(1559 1678 1787 1788) 83.0018 Tj -0 -199.3602 Td -(cli 0520) 34.9481 Tj --16052 TJm -(1789 1790 1928 1967) 83.0018 Tj -17.4613 -208.8535 Td -(0520 0522 0915 1029) 83.0018 Tj --6520.6 TJm -(cprintf 1221 6352) 74.2647 Tj -17.4613 -218.3469 Td -(1460 6406 6490) 61.1592 Tj --11035.5 TJm -(0217 1221 1222 1258) 83.0018 Tj -0 -227.8403 Td -(cmd 6865) 34.9481 Tj --16052 TJm -(1262 1676 1680 1682) 83.0018 Tj -17.4613 -237.3336 Td -(6865 6877 6886 6887) 83.0018 Tj --8527.14 TJm -(2286 2375 2637 2653) 83.0018 Tj -17.4613 -246.827 Td -(6892 6893 6898 6902) 83.0018 Tj --8527.14 TJm -(2658 2882 3410 5619) 83.0018 Tj -17.4613 -256.3203 Td -(6906 6915 6918 6923) 83.0018 Tj --8527.14 TJm -(5639 5761 5912 6352) 83.0018 Tj -17.4613 -265.8137 Td -(6931 6937 6941 6951) 83.0018 Tj --8527.14 TJm -(6408 6409 6410 6413) 83.0018 Tj -17.4613 -275.3071 Td -(6975 6977 7052 7055) 83.0018 Tj --6520.6 TJm -(cpu 1557) 34.9481 Tj -17.4613 -284.8004 Td -(7057 7058 7059 7060) 83.0018 Tj --8527.14 TJm -(0256 1221 1222 1258) 83.0018 Tj -17.4613 -294.2938 Td -(7063 7064 7066 7068) 83.0018 Tj --8527.14 TJm -(1260 1262 1271 1306) 83.0018 Tj -17.4613 -303.7871 Td -(7069 7070 7071 7072) 83.0018 Tj --8527.14 TJm -(1365 1386 1408 1446) 83.0018 Tj -17.4613 -313.2805 Td -(7073 7074 7075 7076) 83.0018 Tj --8527.14 TJm -(1461 1462 1470 1472) 83.0018 Tj -17.4613 -322.7739 Td -(7079 7080 7082 7084) 83.0018 Tj --8527.14 TJm -(1557 1567 1571 1582) 83.0018 Tj -17.4613 -332.2672 Td -(7085 7086 7087 7088) 83.0018 Tj --8527.14 TJm -(1705 1710 1715 1724) 83.0018 Tj -17.4613 -341.7606 Td -(7089 7100 7101 7103) 83.0018 Tj --8527.14 TJm -(1725 1726 1727 1728) 83.0018 Tj -17.4613 -351.2539 Td -(7105 7106 7107 7108) 83.0018 Tj --8527.14 TJm -(1729 1928 1959 1966) 83.0018 Tj -17.4613 -360.7473 Td -(7109 7110 7113 7114) 83.0018 Tj --8527.14 TJm -(1967 1968 2615 2637) 83.0018 Tj -17.4613 -370.2407 Td -(7116 7118 7119 7120) 83.0018 Tj --8527.14 TJm -(2638 2653 2654 2658) 83.0018 Tj -17.4613 -379.734 Td -(7121 7122 7212 7213) 83.0018 Tj --8527.14 TJm -(2659 5512 5513 5761) 83.0018 Tj -17.4613 -389.2274 Td -(7214 7215 7217 7221) 83.0018 Tj --8527.14 TJm -(6408) 17.4741 Tj -17.4613 -398.7207 Td -(7224 7230 7231 7234) 83.0018 Tj --6520.6 TJm -(cpunum 5751) 48.0537 Tj -17.4613 -408.2141 Td -(7237 7239 7242 7246) 83.0018 Tj --8527.14 TJm -(0269 1255 1256 1279) 83.0018 Tj -17.4613 -417.7075 Td -(7248 7250 7253 7255) 83.0018 Tj --8527.14 TJm -(1707 5751 5923 5932) 83.0018 Tj -17.4613 -427.2008 Td -(7258 7260 7263 7264) 83.0018 Tj --6520.6 TJm -(CR0_PE 0910 1024) 69.8962 Tj -17.4613 -436.6942 Td -(7275 7278 7281 7285) 83.0018 Tj --8527.14 TJm -(0956 1056) 39.3166 Tj -17.4613 -446.1875 Td -(7300 7303 7308 7312) 83.0018 Tj --6520.6 TJm -(create 4801) 48.0537 Tj -17.4613 -455.6809 Td -(7313 7316 7321 7322) 83.0018 Tj --8527.14 TJm -(4801 4821 4834 4838) 83.0018 Tj -17.4613 -465.1743 Td -(7328 7337 7338 7344) 83.0018 Tj --8527.14 TJm -(4862 4906 4923) 61.1592 Tj -17.4613 -474.6676 Td -(7345 7351 7352 7361) 83.0018 Tj --6520.6 TJm -(CRTPORT 6451) 52.4222 Tj -17.4613 -484.161 Td -(7364 7366 7372 7373) 83.0018 Tj --8527.14 TJm -(6451 6460 6461 6462) 83.0018 Tj -17.4613 -493.6543 Td -(7378 7384 7390 7391) 83.0018 Tj --8527.14 TJm -(6463 6479 6480 6481) 83.0018 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 3 3 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 cross-references Page 3) 187.8461 Tj -17.4613 -28.4801 Td -(6482) 17.4741 Tj --14045.6 TJm -(exit 2104) 39.3166 Tj -0 -37.9735 Td -(CTL 6109) 34.9481 Tj --16052 TJm -(0302 2104 2140 2605) 83.0018 Tj -17.4613 -47.4664 Td -(6109 6135 6139 6285) 83.0018 Tj --8527.14 TJm -(2609 2667 2676 2916) 83.0018 Tj -0 -56.9598 Td -(devsw 3283) 43.6851 Tj --15048.7 TJm -(6715 6718 6761 6826) 83.0018 Tj -17.4613 -66.4531 Td -(3283 3288 4108 4110) 83.0018 Tj --8527.14 TJm -(6831 6916 6925 6935) 83.0018 Tj -17.4613 -75.9465 Td -(4158 4160 4407 6621) 83.0018 Tj --8527.14 TJm -(6980 7028 7035) 61.1592 Tj -17.4613 -85.4399 Td -(6622) 17.4741 Tj --14045.6 TJm -(fdalloc 4582) 52.4222 Tj -0 -94.9332 Td -(dinode 3172) 48.0537 Tj --14547 TJm -(4582 4608 4874 4987) 83.0018 Tj -17.4613 -104.4266 Td -(3172 3182 3806 3812) 83.0018 Tj --6520.6 TJm -(fetchint 2766) 56.7907 Tj -17.4613 -113.9199 Td -(3830 3833 3905 3918) 83.0018 Tj --8527.14 TJm -(0342 2766 2796 4963) 83.0018 Tj -0 -123.4133 Td -(dirent 3203) 48.0537 Tj --12540.5 TJm -(fetchstr 2778) 56.7907 Tj -17.4613 -132.9067 Td -(3203 4216 4223 4224) 83.0018 Tj --8527.14 TJm -(0343 2778 2826 4969) 83.0018 Tj -17.4613 -142.4 Td -(4255 4705 4754) 61.1592 Tj --9028.94 TJm -(file 3250) 39.3166 Tj -0 -151.8934 Td -(dirlink 4252) 52.4222 Tj --14045.3 TJm -(0202 0225 0226 0227) 83.0018 Tj -17.4613 -161.3867 Td -(0234 4252 4267 4275) 83.0018 Tj --8527.14 TJm -(0229 0230 0231 0287) 83.0018 Tj -17.4613 -170.8801 Td -(4684 4833 4837 4838) 83.0018 Tj --8527.14 TJm -(1540 3250 3671 4404) 83.0018 Tj -0 -180.3735 Td -(dirlookup 4212) 61.1592 Tj --13042 TJm -(4410 4420 4423 4426) 83.0018 Tj -17.4613 -189.8664 Td -(0235 4212 4219 4259) 83.0018 Tj --8527.14 TJm -(4438 4439 4452 4454) 83.0018 Tj -17.4613 -199.3598 Td -(4374 4770 4811) 61.1592 Tj --11035.5 TJm -(4476 4502 4522 4557) 83.0018 Tj -0 -208.8532 Td -(DIRSIZ 3201) 48.0537 Tj --14547 TJm -(4563 4566 4582 4603) 83.0018 Tj -17.4613 -218.3465 Td -(3201 3205 4205 4272) 83.0018 Tj --8527.14 TJm -(4617 4629 4642 4653) 83.0018 Tj -17.4613 -227.8399 Td -(4328 4329 4391 4665) 83.0018 Tj --8527.14 TJm -(4855 4979 5156 5171) 83.0018 Tj -17.4613 -237.3332 Td -(4755 4805) 39.3166 Tj --13543.8 TJm -(6310 6878 6933 6934) 83.0018 Tj -0 -246.8266 Td -(DPL_USER 0711) 56.7907 Tj --13543.7 TJm -(7064 7072 7272) 61.1592 Tj -17.4613 -256.32 Td -(0711 1724 1725 1817) 83.0018 Tj --6520.6 TJm -(filealloc 4421) 61.1592 Tj -17.4613 -265.8133 Td -(1818 2572 2666 2675) 83.0018 Tj --8527.14 TJm -(0225 4421 4874 5177) 83.0018 Tj -0 -275.3067 Td -(E0ESC 6116) 43.6851 Tj --13042.1 TJm -(fileclose 4452) 61.1592 Tj -17.4613 -284.8 Td -(6116 6270 6274 6275) 83.0018 Tj --8527.14 TJm -(0226 2115 4452 4458) 83.0018 Tj -17.4613 -294.2934 Td -(6277 6280) 39.3166 Tj --13543.8 TJm -(4647 4876 4990 4991) 83.0018 Tj -0 -303.7868 Td -(elfhdr 0855) 48.0537 Tj --14547 TJm -(5204 5206) 39.3166 Tj -17.4613 -313.2801 Td -(0855 1118 1123 5014) 83.0018 Tj --6520.6 TJm -(filedup 4439) 52.4222 Tj -0 -322.7735 Td -(ELF_MAGIC 0852) 61.1592 Tj --13042 TJm -(0227 1880 4439 4443) 83.0018 Tj -17.4613 -332.2664 Td -(0852 1129 5028) 61.1592 Tj --11035.5 TJm -(4610) 17.4741 Tj -0 -341.7598 Td -(ELF_PROG_LOAD 0886) 78.6333 Tj --9028.81 TJm -(fileinit 4414) 56.7907 Tj -17.4613 -351.2532 Td -(0886 5036 5067) 61.1592 Tj --11035.5 TJm -(0228 1228 4414) 61.1592 Tj -0 -360.7465 Td -(EOI 5663) 34.9481 Tj --14045.5 TJm -(fileread 4502) 56.7907 Tj -17.4613 -370.2399 Td -(5663 5734 5775) 61.1592 Tj --11035.5 TJm -(0229 4502 4517 4623) 83.0018 Tj -0 -379.7332 Td -(ERROR 5681) 43.6851 Tj --13042.1 TJm -(filestat 4476) 56.7907 Tj -17.4613 -389.2266 Td -(5681 5727) 39.3166 Tj --13543.8 TJm -(0230 4476 4658) 61.1592 Tj -0 -398.72 Td -(ESR 5666) 34.9481 Tj --14045.5 TJm -(filewrite 4522) 61.1592 Tj -17.4613 -408.2133 Td -(5666 5730 5731) 61.1592 Tj --11035.5 TJm -(0231 4522 4537 4635) 83.0018 Tj -0 -417.7067 Td -(EXEC 6857) 39.3166 Tj --13543.8 TJm -(FL_IF 0660) 43.6851 Tj -17.4613 -427.2 Td -(6857 6922 7059 7365) 83.0018 Tj --8527.14 TJm -(0660 1462 1468 1821) 83.0018 Tj -0 -436.6934 Td -(exec 5009) 39.3166 Tj --15550.3 TJm -(1963 5758) 39.3166 Tj -17.4613 -446.1868 Td -(0222 4972 5009 6768) 83.0018 Tj --6520.6 TJm -(fork 1854) 39.3166 Tj -17.4613 -455.6801 Td -(6829 6830 6926 6927) 83.0018 Tj --8527.14 TJm -(0303 1854 2910 6760) 83.0018 Tj -0 -465.1735 Td -(execcmd 6869 7053) 74.2647 Tj --11537 TJm -(6823 6825 7043 7045) 83.0018 Tj -17.4613 -474.6665 Td -(6869 6910 6923 7053) 83.0018 Tj --6520.6 TJm -(fork1 7039) 43.6851 Tj -17.4613 -484.1598 Td -(7055 7321 7327 7328) 83.0018 Tj --8527.14 TJm -(6900 6942 6954 6961) 83.0018 Tj -17.4613 -493.6532 Td -(7356 7366) 39.3166 Tj --13543.8 TJm -(6976 7024 7039) 61.1592 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 cross-references Page 4) 187.8461 Tj -0 -28.4801 Td -(forkret 1984) 52.4222 Tj --14045.3 TJm -(3317 3391) 39.3166 Tj -17.4613 -37.9735 Td -(1616 1790 1984) 61.1592 Tj --9028.94 TJm -(IDE_CMD_WRITE 3318) 78.6333 Tj -0 -47.4664 Td -(gatedesc 0801) 56.7907 Tj --13543.7 TJm -(3318 3388) 39.3166 Tj -17.4613 -56.9598 Td -(0464 0467 0801 2560) 83.0018 Tj --6520.6 TJm -(IDE_DF 3314) 48.0537 Tj -0 -66.4531 Td -(getcallerpcs 1426) 74.2647 Tj --11537 TJm -(3314 3338) 39.3166 Tj -17.4613 -75.9465 Td -(0322 1387 1426 1678) 83.0018 Tj --6520.6 TJm -(IDE_DRDY 3313) 56.7907 Tj -17.4613 -85.4399 Td -(6411) 17.4741 Tj --16052.1 TJm -(3313 3336) 39.3166 Tj -0 -94.9332 Td -(getcmd 6984) 48.0537 Tj --12540.5 TJm -(IDE_ERR 3315) 52.4222 Tj -17.4613 -104.4266 Td -(6984 7015) 39.3166 Tj --13543.8 TJm -(3315 3338) 39.3166 Tj -0 -113.9199 Td -(gettoken 7156) 56.7907 Tj --11537.1 TJm -(idtinit 2578) 52.4222 Tj -17.4613 -123.4133 Td -(7156 7241 7245 7257) 83.0018 Tj --8527.14 TJm -(0351 1259 2578) 61.1592 Tj -17.4613 -132.9067 Td -(7270 7271 7307 7311) 83.0018 Tj --6520.6 TJm -(idup 3888) 39.3166 Tj -17.4613 -142.4 Td -(7333) 17.4741 Tj --16052.1 TJm -(0237 1881 3888 4361) 83.0018 Tj -0 -151.8934 Td -(growproc 1834) 56.7907 Tj --11537.1 TJm -(iget 3853) 39.3166 Tj -17.4613 -161.3867 Td -(0304 1834 2959) 61.1592 Tj --11035.5 TJm -(3794 3818 3853 3873) 83.0018 Tj -0 -170.8801 Td -(havedisk1 3327) 61.1592 Tj --13042 TJm -(4234 4359) 39.3166 Tj -17.4613 -180.3735 Td -(3327 3364 3462) 61.1592 Tj --9028.94 TJm -(iinit 3789) 43.6851 Tj -0 -189.8664 Td -(holding 1444) 52.4222 Tj --14045.3 TJm -(0238 1229 3789) 61.1592 Tj -17.4613 -199.3598 Td -(0323 1376 1404 1444) 83.0018 Tj --6520.6 TJm -(ilock 3902) 43.6851 Tj -17.4613 -208.8532 Td -(1957) 17.4741 Tj --16052.1 TJm -(0239 3902 3908 3928) 83.0018 Tj -0 -218.3465 Td -(ialloc 3802) 48.0537 Tj --14547 TJm -(4364 4479 4511 4531) 83.0018 Tj -17.4613 -227.8399 Td -(0236 3802 3822 4820) 83.0018 Tj --8527.14 TJm -(4672 4683 4693 4762) 83.0018 Tj -17.4613 -237.3332 Td -(4821) 17.4741 Tj --16052.1 TJm -(4774 4809 4813 4823) 83.0018 Tj -0 -246.8266 Td -(IBLOCK 3185) 48.0537 Tj --14547 TJm -(4867 4937 5023 6563) 83.0018 Tj -17.4613 -256.32 Td -(3185 3811 3832 3917) 83.0018 Tj --8527.14 TJm -(6583 6610) 39.3166 Tj -0 -265.8133 Td -(ICRHI 5674) 43.6851 Tj --13042.1 TJm -(inb 0403) 34.9481 Tj -17.4613 -275.3067 Td -(5674 5737 5807 5819) 83.0018 Tj --8527.14 TJm -(0403 0928 0936 1154) 83.0018 Tj -0 -284.8 Td -(ICRLO 5667) 43.6851 Tj --15048.7 TJm -(3336 3363 5647 6264) 83.0018 Tj -17.4613 -294.2934 Td -(5667 5738 5739 5808) 83.0018 Tj --8527.14 TJm -(6267 6461 6463) 61.1592 Tj -17.4613 -303.7868 Td -(5810 5820) 39.3166 Tj --11537.3 TJm -(initlock 1361) 56.7907 Tj -0 -313.2801 Td -(ID 5660) 30.5796 Tj -174.613 -313.2801 Td -(0324 1361 1622 2283) 83.0018 Tj -17.461 -322.7735 Td -(5660 5693 5766) 61.1592 Tj --11035.5 TJm -(2574 3355 3543 3791) 83.0018 Tj --0.0003 -332.2664 Td -(ideinit 3351) 52.4222 Tj --14045.3 TJm -(4416 5185 6618 6619) 83.0018 Tj -17.461 -341.7598 Td -(0251 1230 3351) 61.1592 Tj --9028.94 TJm -(inode 3263) 43.6851 Tj --0.0003 -351.2532 Td -(ideintr 3402) 52.4222 Tj --14045.3 TJm -(0203 0234 0235 0236) 83.0018 Tj -17.461 -360.7465 Td -(0252 2624 3402) 61.1592 Tj --11035.5 TJm -(0237 0239 0240 0241) 83.0018 Tj --0.0003 -370.2399 Td -(idelock 3324) 52.4222 Tj --14045.3 TJm -(0242 0243 0245 0246) 83.0018 Tj -17.461 -379.7332 Td -(3324 3355 3407 3409) 83.0018 Tj --8527.14 TJm -(0247 0248 0249 1541) 83.0018 Tj -17.461 -389.2266 Td -(3428 3465 3480 3482) 83.0018 Tj --8527.14 TJm -(3256 3263 3284 3285) 83.0018 Tj --0.0003 -398.72 Td -(iderw 3454) 43.6851 Tj --15048.7 TJm -(3674 3785 3794 3801) 83.0018 Tj -17.461 -408.2133 Td -(0253 3454 3459 3461) 83.0018 Tj --8527.14 TJm -(3827 3852 3855 3861) 83.0018 Tj -17.461 -417.7067 Td -(3608 3619) 39.3166 Tj --13543.8 TJm -(3887 3888 3902 3934) 83.0018 Tj --0.0003 -427.2 Td -(idestart 3375) 56.7907 Tj --13543.7 TJm -(3952 3974 4010 4054) 83.0018 Tj -17.461 -436.6934 Td -(3328 3375 3378 3426) 83.0018 Tj --8527.14 TJm -(4085 4102 4152 4211) 83.0018 Tj -17.461 -446.1868 Td -(3475) 17.4741 Tj --16052.1 TJm -(4212 4252 4256 4353) 83.0018 Tj --0.0003 -455.6801 Td -(idewait 3332) 52.4222 Tj --14045.3 TJm -(4356 4388 4395 4666) 83.0018 Tj -17.461 -465.1735 Td -(3332 3358 3380 3416) 83.0018 Tj --8527.14 TJm -(4702 4753 4800 4804) 83.0018 Tj --0.0003 -474.6665 Td -(IDE_BSY 3312) 52.4222 Tj --14045.3 TJm -(4856 4904 4915 4933) 83.0018 Tj -17.461 -484.1598 Td -(3312 3336) 39.3166 Tj --13543.8 TJm -(5015 6551 6601) 61.1592 Tj --0.0003 -493.6532 Td -(IDE_CMD_READ 3317) 74.2647 Tj --9530.47 TJm -(INPUT_BUF 6500) 61.1592 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 4 4 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 cross-references Page 5) 187.8461 Tj -17.4613 -28.4801 Td -(6500 6503 6524 6536) 83.0018 Tj --8527.14 TJm -(2432 2627 6625 6626) 83.0018 Tj -17.4613 -37.9735 Td -(6537 6539 6568) 61.1592 Tj --9028.94 TJm -(IRQ_SLAVE 5960) 61.1592 Tj -0 -47.4664 Td -(insl 0412) 39.3166 Tj --15550.3 TJm -(5960 5964 6002 6017) 83.0018 Tj -17.4613 -56.9598 Td -(0412 0414 1173 3417) 83.0018 Tj --6520.6 TJm -(IRQ_SPURIOUS 2436) 74.2647 Tj -0 -66.4531 Td -(INT_DISABLED 5869) 74.2647 Tj --11537 TJm -(2436 2636 5707) 61.1592 Tj -17.4613 -75.9465 Td -(5869 5917) 39.3166 Tj --11537.3 TJm -(IRQ_TIMER 2431) 61.1592 Tj -0 -85.4399 Td -(IOAPIC 5858) 48.0537 Tj --14547 TJm -(2431 2614 2671 5714) 83.0018 Tj -17.4613 -94.9332 Td -(5858 5908) 39.3166 Tj --13543.8 TJm -(6680) 17.4741 Tj -0 -104.4266 Td -(ioapic 5877) 48.0537 Tj --12540.5 TJm -(isdirempty 4702) 65.5277 Tj -17.4613 -113.9199 Td -(5607 5629 5630 5874) 83.0018 Tj --8527.14 TJm -(4702 4709 4778) 61.1592 Tj -17.4613 -123.4133 Td -(5877 5886 5887 5893) 83.0018 Tj --6520.6 TJm -(ismp 5514) 39.3166 Tj -17.4613 -132.9067 Td -(5894 5908) 39.3166 Tj --13543.8 TJm -(0277 1231 5514 5612) 83.0018 Tj -0 -142.4 Td -(ioapicenable 5923) 74.2647 Tj --11537 TJm -(5905 5925) 39.3166 Tj -17.4613 -151.8934 Td -(0256 3357 5923 6626) 83.0018 Tj --6520.6 TJm -(itrunc 4054) 48.0537 Tj -0 -161.3867 Td -(ioapicid 5516) 56.7907 Tj --13543.7 TJm -(3674 3961 4054) 61.1592 Tj -17.4613 -170.8801 Td -(0257 5516 5630 5911) 83.0018 Tj --6520.6 TJm -(iunlock 3934) 52.4222 Tj -17.4613 -180.3735 Td -(5912) 17.4741 Tj --16052.1 TJm -(0241 3934 3937 3976) 83.0018 Tj -0 -189.8664 Td -(ioapicinit 5901) 65.5277 Tj --12540.3 TJm -(4371 4481 4514 4534) 83.0018 Tj -17.4613 -199.3598 Td -(0258 1218 5901 5912) 83.0018 Tj --8527.14 TJm -(4679 4880 4942 6556) 83.0018 Tj -0 -208.8532 Td -(ioapicread 5884) 65.5277 Tj --12540.3 TJm -(6605) 17.4741 Tj -17.4613 -218.3465 Td -(5884 5909 5910) 61.1592 Tj --9028.94 TJm -(iunlockput 3974) 65.5277 Tj -0 -227.8399 Td -(ioapicwrite 5891) 69.8962 Tj --12038.7 TJm -(0242 3974 4366 4375) 83.0018 Tj -17.4613 -237.3332 Td -(5891 5917 5918 5931) 83.0018 Tj --8527.14 TJm -(4378 4674 4685 4688) 83.0018 Tj -17.4613 -246.8266 Td -(5932) 17.4741 Tj --16052.1 TJm -(4696 4766 4771 4779) 83.0018 Tj -0 -256.32 Td -(IO_PIC1 5957) 52.4222 Tj --14045.3 TJm -(4780 4791 4795 4812) 83.0018 Tj -17.4613 -265.8133 Td -(5957 5970 5985 5994) 83.0018 Tj --8527.14 TJm -(4816 4840 4869 4877) 83.0018 Tj -17.4613 -275.3067 Td -(5997 6002 6012 6026) 83.0018 Tj --8527.14 TJm -(4908 4925 4939 5077) 83.0018 Tj -17.4613 -284.8 Td -(6027) 17.4741 Tj --16052.1 TJm -(5118) 17.4741 Tj -0 -294.2934 Td -(IO_PIC2 5958) 52.4222 Tj --12038.8 TJm -(iupdate 3827) 52.4222 Tj -17.4613 -303.7868 Td -(5958 5971 5986 6015) 83.0018 Tj --8527.14 TJm -(0243 3827 3963 4080) 83.0018 Tj -17.4613 -313.2801 Td -(6016 6017 6020 6029) 83.0018 Tj --8527.14 TJm -(4178 4678 4695 4789) 83.0018 Tj -17.4613 -322.7735 Td -(6030) 17.4741 Tj --16052.1 TJm -(4794 4827 4831) 61.1592 Tj -0 -332.2664 Td -(IO_RTC 5786) 48.0537 Tj --12540.5 TJm -(I_BUSY 3277) 48.0537 Tj -17.4613 -341.7598 Td -(5786 5799 5800) 61.1592 Tj --11035.5 TJm -(3277 3911 3913 3936) 83.0018 Tj -0 -351.2532 Td -(IO_TIMER1 6659) 61.1592 Tj --13042 TJm -(3940 3957 3959) 61.1592 Tj -17.4613 -360.7465 Td -(6659 6668 6678 6679) 83.0018 Tj --6520.6 TJm -(I_VALID 3278) 52.4222 Tj -0 -370.2399 Td -(IPB 3182) 34.9481 Tj --16052 TJm -(3278 3916 3926 3955) 83.0018 Tj -17.4613 -379.7332 Td -(3182 3185 3191 3812) 83.0018 Tj --6520.6 TJm -(kalloc 2354) 48.0537 Tj -17.4613 -389.2266 Td -(3833 3918) 39.3166 Tj --13543.8 TJm -(0261 1283 1772 1812) 83.0018 Tj -0 -398.72 Td -(iput 3952) 39.3166 Tj --15550.3 TJm -(1838 1865 2354 2360) 83.0018 Tj -17.4613 -408.2133 Td -(0240 2120 3952 3958) 83.0018 Tj --8527.14 TJm -(2375 5058 5179) 61.1592 Tj -17.4613 -417.7067 Td -(3977 4260 4382 4471) 83.0018 Tj --6520.6 TJm -(KBDATAP 6104) 52.4222 Tj -17.4613 -427.2 Td -(4689 4943) 39.3166 Tj --13543.8 TJm -(6104 6267) 39.3166 Tj -0 -436.6934 Td -(IRQ_COM1 2433) 56.7907 Tj --11537.1 TJm -(kbdgetc 6256) 52.4222 Tj -17.4613 -446.1868 Td -(2433 2631) 39.3166 Tj --13543.8 TJm -(6256 6298) 39.3166 Tj -0 -455.6801 Td -(IRQ_ERROR 2435) 61.1592 Tj --11035.5 TJm -(kbdintr 6296) 52.4222 Tj -17.4613 -465.1735 Td -(2435 5727) 39.3166 Tj --13543.8 TJm -(0266 2628 6296) 61.1592 Tj -0 -474.6665 Td -(IRQ_IDE 2434) 52.4222 Tj --12038.8 TJm -(KBSTATP 6102) 52.4222 Tj -17.4613 -484.1598 Td -(2434 2623 3356 3357) 83.0018 Tj --8527.14 TJm -(6102 6264) 39.3166 Tj -0 -493.6532 Td -(IRQ_KBD 2432) 52.4222 Tj --12038.8 TJm -(KBS_DIB 6103) 52.4222 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 cross-references Page 6) 187.8461 Tj -17.4613 -28.4801 Td -(6103 6265) 39.3166 Tj --13543.8 TJm -(0453 0461 0954 1054) 83.0018 Tj -0 -37.9735 Td -(KEY_DEL 6128) 52.4222 Tj --14045.3 TJm -(1711) 17.4741 Tj -17.4613 -47.4664 Td -(6128 6169 6191 6215) 83.0018 Tj --6520.6 TJm -(lidt 0467) 39.3166 Tj -0 -56.9598 Td -(KEY_DN 6122) 48.0537 Tj --14547 TJm -(0467 0475 2580) 61.1592 Tj -17.4613 -66.4531 Td -(6122 6165 6187 6211) 83.0018 Tj --6520.6 TJm -(LINT0 5679) 43.6851 Tj -0 -75.9465 Td -(KEY_END 6120) 52.4222 Tj --14045.3 TJm -(5679 5718) 39.3166 Tj -17.4613 -85.4399 Td -(6120 6168 6190 6214) 83.0018 Tj --6520.6 TJm -(LINT1 5680) 43.6851 Tj -0 -94.9332 Td -(KEY_HOME 6119) 56.7907 Tj --13543.7 TJm -(5680 5719) 39.3166 Tj -17.4613 -104.4266 Td -(6119 6168 6190 6214) 83.0018 Tj --6520.6 TJm -(LIST 6860) 39.3166 Tj -0 -113.9199 Td -(KEY_INS 6127) 52.4222 Tj --14045.3 TJm -(6860 6940 7107 7383) 83.0018 Tj -17.4613 -123.4133 Td -(6127 6169 6191 6215) 83.0018 Tj --6520.6 TJm -(listcmd 6890 7101) 74.2647 Tj -0 -132.9067 Td -(KEY_LF 6123) 48.0537 Tj --14547 TJm -(6890 6911 6941 7101) 83.0018 Tj -17.4613 -142.4 Td -(6123 6167 6189 6213) 83.0018 Tj --8527.14 TJm -(7103 7246 7357 7384) 83.0018 Tj -0 -151.8934 Td -(KEY_PGDN 6126) 56.7907 Tj --11537.1 TJm -(loadgs 0514) 48.0537 Tj -17.4613 -161.3867 Td -(6126 6166 6188 6212) 83.0018 Tj --8527.14 TJm -(0514 1712) 39.3166 Tj -0 -170.8801 Td -(KEY_PGUP 6125) 56.7907 Tj --11537.1 TJm -(ltr 0479) 34.9481 Tj -17.4613 -180.3735 Td -(6125 6166 6188 6212) 83.0018 Tj --8527.14 TJm -(0479 0481 1730) 61.1592 Tj -0 -189.8664 Td -(KEY_RT 6124) 48.0537 Tj --12540.5 TJm -(MAXARGS 6863) 52.4222 Tj -17.4613 -199.3598 Td -(6124 6167 6189 6213) 83.0018 Tj --8527.14 TJm -(6863 6871 6872 7340) 83.0018 Tj -0 -208.8532 Td -(KEY_UP 6121) 48.0537 Tj --12540.5 TJm -(MAXFILE 3169) 52.4222 Tj -17.4613 -218.3465 Td -(6121 6165 6187 6211) 83.0018 Tj --8527.14 TJm -(3169 4165 4166) 61.1592 Tj -0 -227.8399 Td -(kfree 2305) 43.6851 Tj --13042.1 TJm -(memcmp 5311) 48.0537 Tj -17.4613 -237.3332 Td -(0262 1843 1866 2169) 83.0018 Tj --8527.14 TJm -(0330 5311 5543 5588) 83.0018 Tj -17.4613 -246.8266 Td -(2170 2287 2305 2310) 83.0018 Tj --6520.6 TJm -(memmove 5327) 52.4222 Tj -17.4613 -256.32 Td -(5107 5117 5202 5223) 83.0018 Tj --8527.14 TJm -(0331 1276 1814 1841) 83.0018 Tj -0 -265.8133 Td -(kill 2075) 39.3166 Tj --15550.3 TJm -(1871 3683 3839 3924) 83.0018 Tj -17.4613 -275.3067 Td -(0305 2075 2658 2933) 83.0018 Tj --8527.14 TJm -(4121 4171 4329 4331) 83.0018 Tj -17.4613 -284.8 Td -(6767) 17.4741 Tj --16052.1 TJm -(5088 5327 6474) 61.1592 Tj -0 -294.2934 Td -(kinit 2277) 43.6851 Tj --13042.1 TJm -(memset 5304) 48.0537 Tj -17.4613 -303.7868 Td -(0263 1224 2277) 61.1592 Tj --11035.5 TJm -(0332 1789 1813 1816) 83.0018 Tj -0 -313.2801 Td -(ksegment 1703) 56.7907 Tj --13543.7 TJm -(1842 2313 3694 3814) 83.0018 Tj -17.4613 -322.7735 Td -(0309 1216 1257 1703) 83.0018 Tj --8527.14 TJm -(4784 4959 5061 5075) 83.0018 Tj -0 -332.2664 Td -(KSTACKSIZE 0152) 65.5277 Tj --12540.3 TJm -(5304 6476 6987 7058) 83.0018 Tj -17.4613 -341.7598 Td -(0152 1283 1284 1729) 83.0018 Tj --8527.14 TJm -(7069 7085 7106 7119) 83.0018 Tj -17.4613 -351.2532 Td -(1772 1776 1866 2170) 83.0018 Tj --6520.6 TJm -(microdelay 5781) 65.5277 Tj -0 -360.7465 Td -(lapiceoi 5772) 56.7907 Tj --13543.7 TJm -(0274 5781 5809 5811) 83.0018 Tj -17.4613 -370.2399 Td -(0271 2621 2625 2629) 83.0018 Tj --8527.14 TJm -(5821) 17.4741 Tj -17.4613 -379.7332 Td -(2633 2639 5772) 61.1592 Tj --9028.94 TJm -(min 3673) 34.9481 Tj -0 -389.2266 Td -(lapicinit 5701) 61.1592 Tj --13042 TJm -(3673 4120 4170) 61.1592 Tj -17.4613 -398.72 Td -(0272 1215 1256 5701) 83.0018 Tj --6520.6 TJm -(mp 5402) 30.5796 Tj -0 -408.2133 Td -(lapicstartap 5791) 74.2647 Tj --11537 TJm -(5402 5507 5536 5542) 83.0018 Tj -17.4613 -417.7067 Td -(0273 1286 5791) 61.1592 Tj --11035.5 TJm -(5543 5544 5555 5560) 83.0018 Tj -0 -427.2 Td -(lapicw 5690) 48.0537 Tj --14547 TJm -(5564 5565 5568 5569) 83.0018 Tj -17.4613 -436.6934 Td -(5690 5707 5713 5714) 83.0018 Tj --8527.14 TJm -(5580 5583 5585 5587) 83.0018 Tj -17.4613 -446.1868 Td -(5715 5718 5719 5724) 83.0018 Tj --8527.14 TJm -(5594 5604 5610 5643) 83.0018 Tj -17.4613 -455.6801 Td -(5727 5730 5731 5734) 83.0018 Tj --6520.6 TJm -(mpbcpu 5519) 48.0537 Tj -17.4613 -465.1735 Td -(5737 5738 5743 5775) 83.0018 Tj --8527.14 TJm -(0278 1215 1255 5519) 83.0018 Tj -17.4613 -474.6668 Td -(5807 5808 5810 5819) 83.0018 Tj --6520.6 TJm -(MPBUS 5452) 43.6851 Tj -17.4613 -484.1602 Td -(5820) 17.4741 Tj --16052.1 TJm -(5452 5633) 39.3166 Tj -0 -493.6536 Td -(lgdt 0453) 39.3166 Tj --13543.8 TJm -(mpconf 5413) 48.0537 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 5 5 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 cross-references Page 7) 187.8461 Tj -17.4613 -28.4801 Td -(5413 5579 5582 5587) 83.0018 Tj --8527.14 TJm -(4076) 17.4741 Tj -17.4613 -37.9735 Td -(5605) 17.4741 Tj --14045.6 TJm -(NELEM 0362) 43.6851 Tj -0 -47.4664 Td -(mpconfig 5580) 56.7907 Tj --13543.7 TJm -(0362 1672 2879 4961) 83.0018 Tj -17.4613 -56.9598 Td -(5580 5610) 39.3166 Tj --11537.3 TJm -(nextpid 1615) 52.4222 Tj -0 -66.4531 Td -(mpinit 5601) 48.0537 Tj --14547 TJm -(1615 1768) 39.3166 Tj -17.4613 -75.9465 Td -(0279 1214 5601 5619) 83.0018 Tj --6520.6 TJm -(NFILE 0155) 43.6851 Tj -17.4613 -85.4399 Td -(5620 5639 5640) 61.1592 Tj --11035.5 TJm -(0155 4410 4426) 61.1592 Tj -0 -94.9332 Td -(MPIOAPIC 5453) 56.7907 Tj --11537.1 TJm -(NINDIRECT 3168) 61.1592 Tj -17.4613 -104.4266 Td -(5453 5628) 39.3166 Tj --13543.8 TJm -(3168 3169 4022 4070) 83.0018 Tj -0 -113.9199 Td -(mpioapic 5439) 56.7907 Tj --11537.1 TJm -(NINODE 0157) 48.0537 Tj -17.4613 -123.4133 Td -(5439 5607 5629 5631) 83.0018 Tj --8527.14 TJm -(0157 3785 3861) 61.1592 Tj -0 -132.9067 Td -(MPIOINTR 5454) 56.7907 Tj --11537.1 TJm -(NO 6106) 30.5796 Tj -17.4613 -142.4 Td -(5454 5634) 39.3166 Tj --13543.8 TJm -(6106 6152 6155 6157) 83.0018 Tj -0 -151.8934 Td -(MPLINTR 5455) 52.4222 Tj --14045.3 TJm -(6158 6159 6160 6162) 83.0018 Tj -17.4613 -161.3867 Td -(5455 5635) 39.3166 Tj --13543.8 TJm -(6174 6177 6179 6180) 83.0018 Tj -0 -170.8801 Td -(mpmain 1253) 48.0537 Tj --14547 TJm -(6181 6182 6184 6202) 83.0018 Tj -17.4613 -180.3735 Td -(1208 1237 1253 1258) 83.0018 Tj --8527.14 TJm -(6203 6205 6206 6207) 83.0018 Tj -17.4613 -189.8668 Td -(1285) 17.4741 Tj --16052.1 TJm -(6208) 17.4741 Tj -0 -199.3602 Td -(MPPROC 5451) 48.0537 Tj --12540.5 TJm -(NOFILE 0154) 48.0537 Tj -17.4613 -208.8535 Td -(5451 5616) 39.3166 Tj --13543.8 TJm -(0154 1540 1878 2113) 83.0018 Tj -0 -218.3469 Td -(mpproc 5428) 48.0537 Tj --14547 TJm -(4570 4586) 39.3166 Tj -17.4613 -227.8403 Td -(5428 5606 5617 5626) 83.0018 Tj --6520.6 TJm -(NPROC 0150) 43.6851 Tj -0 -237.3336 Td -(mpsearch 5556) 56.7907 Tj --13543.7 TJm -(0150 1610 1669 1760) 83.0018 Tj -17.4613 -246.827 Td -(5556 5585) 39.3166 Tj --13543.8 TJm -(1918 2057 2080 2129) 83.0018 Tj -0 -256.3203 Td -(mpsearch1 5537) 61.1592 Tj --13042 TJm -(2162) 17.4741 Tj -17.4613 -265.8137 Td -(5537 5564 5568 5571) 83.0018 Tj --6520.6 TJm -(NSEGS 1508) 43.6851 Tj -0 -275.3071 Td -(namecmp 4203) 52.4222 Tj --14045.3 TJm -(1508 1561) 39.3166 Tj -17.4613 -284.8004 Td -(0244 4203 4228 4765) 83.0018 Tj --6520.6 TJm -(nulterminate 7352) 74.2647 Tj -0 -294.2938 Td -(namei 4389) 43.6851 Tj --15048.7 TJm -(7215 7230 7352 7373) 83.0018 Tj -17.4613 -303.7871 Td -(0245 1826 4389 4670) 83.0018 Tj --8527.14 TJm -(7379 7380 7385 7386) 83.0018 Tj -17.4613 -313.2805 Td -(4865 4935 5021) 61.1592 Tj --11035.5 TJm -(7391) 17.4741 Tj -0 -322.7739 Td -(nameiparent 4396) 69.8962 Tj --10032.1 TJm -(NUMLOCK 6113) 52.4222 Tj -17.4613 -332.2668 Td -(0246 4354 4369 4381) 83.0018 Tj --8527.14 TJm -(6113 6146) 39.3166 Tj -17.4613 -341.7602 Td -(4396 4681 4760 4807) 83.0018 Tj --6520.6 TJm -(outb 0421) 39.3166 Tj -0 -351.2536 Td -(namex 4354) 43.6851 Tj --15048.7 TJm -(0421 0933 0941 1164) 83.0018 Tj -17.4613 -360.7469 Td -(4354 4392 4398) 61.1592 Tj --11035.5 TJm -(1165 1166 1167 1168) 83.0018 Tj -0 -370.2403 Td -(NBUF 0156) 39.3166 Tj --15550.3 TJm -(1169 3361 3370 3381) 83.0018 Tj -17.4613 -379.7336 Td -(0156 3531 3553) 61.1592 Tj --11035.5 TJm -(3382 3383 3384 3385) 83.0018 Tj -0 -389.227 Td -(NCPU 0153) 39.3166 Tj --15550.3 TJm -(3386 3388 3391 5646) 83.0018 Tj -17.4613 -398.7204 Td -(0153 1571 5512) 61.1592 Tj --11035.5 TJm -(5647 5799 5800 5970) 83.0018 Tj -0 -408.2137 Td -(ncpu 5515) 39.3166 Tj --15550.3 TJm -(5971 5985 5986 5994) 83.0018 Tj -17.4613 -417.7071 Td -(1222 1278 1572 3357) 83.0018 Tj --8527.14 TJm -(5997 6002 6012 6015) 83.0018 Tj -17.4613 -427.2004 Td -(5515 5618 5619 5623) 83.0018 Tj --8527.14 TJm -(6016 6017 6020 6026) 83.0018 Tj -17.4613 -436.6938 Td -(5624 5625) 39.3166 Tj --13543.8 TJm -(6027 6029 6030 6460) 83.0018 Tj -0 -446.1872 Td -(NDEV 0158) 39.3166 Tj --15550.3 TJm -(6462 6479 6480 6481) 83.0018 Tj -17.4613 -455.6805 Td -(0158 4108 4158 4407) 83.0018 Tj --8527.14 TJm -(6482 6677 6678 6679) 83.0018 Tj -0 -465.1739 Td -(NDIRECT 3167) 52.4222 Tj --12038.8 TJm -(outsl 0433) 43.6851 Tj -17.4613 -474.6668 Td -(3167 3169 3178 3274) 83.0018 Tj --8527.14 TJm -(0433 0435 3389) 61.1592 Tj -17.4613 -484.1602 Td -(4015 4020 4024 4025) 83.0018 Tj --6520.6 TJm -(outw 0427) 39.3166 Tj -17.4613 -493.6536 Td -(4060 4067 4068 4075) 83.0018 Tj --8527.14 TJm -(0427 0982 0984 1082) 83.0018 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 cross-references Page 8) 187.8461 Tj -17.4613 -28.4801 Td -(1084) 17.4741 Tj --16052.1 TJm -(7201 7225 7240 7244) 83.0018 Tj -0 -37.9735 Td -(O_CREATE 3053) 56.7907 Tj --13543.7 TJm -(7256 7269 7305 7309) 83.0018 Tj -17.4613 -47.4664 Td -(3053 4861 7278 7281) 83.0018 Tj --8527.14 TJm -(7324 7332) 39.3166 Tj -0 -56.9598 Td -(O_RDONLY 3050) 56.7907 Tj --11537.1 TJm -(picenable 5975) 61.1592 Tj -17.4613 -66.4531 Td -(3050 4868 7275) 61.1592 Tj --11035.5 TJm -(0283 3356 5975 6625) 83.0018 Tj -0 -75.9465 Td -(O_RDWR 3052) 48.0537 Tj --14547 TJm -(6680) 17.4741 Tj -17.4613 -85.4399 Td -(3052 4886 6814 6816) 83.0018 Tj --6520.6 TJm -(picinit 5982) 52.4222 Tj -17.4613 -94.9332 Td -(7007) 17.4741 Tj --16052.1 TJm -(0284 1217 5982) 61.1592 Tj -0 -104.4266 Td -(O_WRONLY 3051) 56.7907 Tj --11537.1 TJm -(picsetmask 5967) 65.5277 Tj -17.4613 -113.9199 Td -(3051 4885 4886 7278) 83.0018 Tj --8527.14 TJm -(5967 5977 6033) 61.1592 Tj -17.4613 -123.4133 Td -(7281) 17.4741 Tj --14045.6 TJm -(pinit 1620) 43.6851 Tj -0 -132.9067 Td -(PAGE 0151) 39.3166 Tj --15550.3 TJm -(0306 1225 1620) 61.1592 Tj -17.4613 -142.4 Td -(0151 0152 1811 2284) 83.0018 Tj --6520.6 TJm -(PIPE 6859) 39.3166 Tj -17.4613 -151.8934 Td -(2285 2309 2359 5054) 83.0018 Tj --8527.14 TJm -(6859 6950 7086 7377) 83.0018 Tj -17.4613 -161.3867 Td -(5057 5179 5202 5223) 83.0018 Tj --6520.6 TJm -(pipe 5161) 39.3166 Tj -0 -170.8801 Td -(panic 6401 7032) 65.5277 Tj --12540.3 TJm -(0204 0288 0289 0290) 83.0018 Tj -17.4613 -180.3735 Td -(0219 1377 1405 1469) 83.0018 Tj --8527.14 TJm -(3255 4469 4509 4529) 83.0018 Tj -17.4613 -189.8668 Td -(1471 1958 1960 1962) 83.0018 Tj --8527.14 TJm -(5161 5173 5179 5185) 83.0018 Tj -17.4613 -199.3602 Td -(1964 2006 2009 2110) 83.0018 Tj --8527.14 TJm -(5189 5193 5211 5230) 83.0018 Tj -17.4613 -208.8535 Td -(2140 2310 2321 2360) 83.0018 Tj --8527.14 TJm -(5251 6763 6952 6953) 83.0018 Tj -17.4613 -218.3469 Td -(2655 3378 3459 3461) 83.0018 Tj --6520.6 TJm -(pipealloc 5171) 61.1592 Tj -17.4613 -227.8403 Td -(3463 3596 3617 3627) 83.0018 Tj --8527.14 TJm -(0287 4984 5171) 61.1592 Tj -17.4613 -237.3336 Td -(3725 3743 3822 3873) 83.0018 Tj --6520.6 TJm -(pipeclose 5211) 61.1592 Tj -17.4613 -246.827 Td -(3908 3928 3937 3958) 83.0018 Tj --8527.14 TJm -(0288 4469 5211) 61.1592 Tj -17.4613 -256.3203 Td -(4036 4219 4267 4275) 83.0018 Tj --6520.6 TJm -(pipecmd 6884 7080) 74.2647 Tj -17.4613 -265.8137 Td -(4443 4458 4517 4537) 83.0018 Tj --8527.14 TJm -(6884 6912 6951 7080) 83.0018 Tj -17.4613 -275.3071 Td -(4709 4777 4786 4821) 83.0018 Tj --8527.14 TJm -(7082 7258 7358 7378) 83.0018 Tj -17.4613 -284.8004 Td -(4834 4838 5620 5640) 83.0018 Tj --6520.6 TJm -(piperead 5251) 56.7907 Tj -17.4613 -294.2938 Td -(6401 6408 6901 6920) 83.0018 Tj --8527.14 TJm -(0289 4509 5251) 61.1592 Tj -17.4613 -303.7871 Td -(6953 7032 7045 7228) 83.0018 Tj --6520.6 TJm -(PIPESIZE 5159) 56.7907 Tj -17.4613 -313.2805 Td -(7272 7306 7310 7336) 83.0018 Tj --8527.14 TJm -(5159 5163 5236 5244) 83.0018 Tj -17.4613 -322.7739 Td -(7341) 17.4741 Tj --16052.1 TJm -(5266) 17.4741 Tj -0 -332.2668 Td -(panicked 6317) 56.7907 Tj --11537.1 TJm -(pipewrite 5230) 61.1592 Tj -17.4613 -341.7602 Td -(6317 6414 6489) 61.1592 Tj --11035.5 TJm -(0290 4529 5230) 61.1592 Tj -0 -351.2536 Td -(parseblock 7301) 65.5277 Tj --10533.8 TJm -(popcli 1466) 48.0537 Tj -17.4613 -360.7469 Td -(7301 7306 7325) 61.1592 Tj --11035.5 TJm -(0327 1421 1466 1469) 83.0018 Tj -0 -370.2403 Td -(parsecmd 7218) 56.7907 Tj --13543.7 TJm -(1471 1731) 39.3166 Tj -17.4613 -379.7336 Td -(6902 7025 7218) 61.1592 Tj --9028.94 TJm -(printint 6325) 56.7907 Tj -0 -389.227 Td -(parseexec 7317) 61.1592 Tj --13042 TJm -(6325 6374 6378) 61.1592 Tj -17.4613 -398.7204 Td -(7214 7255 7317) 61.1592 Tj --9028.94 TJm -(proc 1529) 39.3166 Tj -0 -408.2137 Td -(parseline 7235) 61.1592 Tj --13042 TJm -(0205 0301 0342 0343) 83.0018 Tj -17.4613 -417.7071 Td -(7212 7224 7235 7246) 83.0018 Tj --8527.14 TJm -(1204 1357 1529 1535) 83.0018 Tj -17.4613 -427.2004 Td -(7308) 17.4741 Tj --16052.1 TJm -(1568 1583 1605 1610) 83.0018 Tj -0 -436.6938 Td -(parsepipe 7251) 61.1592 Tj --13042 TJm -(1613 1665 1669 1716) 83.0018 Tj -17.4613 -446.1872 Td -(7213 7239 7251 7258) 83.0018 Tj --8527.14 TJm -(1724 1725 1729 1753) 83.0018 Tj -0 -455.6805 Td -(parseredirs 7264) 69.8962 Tj --12038.7 TJm -(1756 1760 1804 1838) 83.0018 Tj -17.4613 -465.1739 Td -(7264 7312 7331 7342) 83.0018 Tj --8527.14 TJm -(1841 1842 1843 1844) 83.0018 Tj -0 -474.6668 Td -(PCINT 5678) 43.6851 Tj --15048.7 TJm -(1845 1857 1864 1871) 83.0018 Tj -17.4613 -484.1602 Td -(5678 5724) 39.3166 Tj --13543.8 TJm -(1872 1873 1879 1880) 83.0018 Tj -0 -493.6536 Td -(peek 7201) 39.3166 Tj --15550.3 TJm -(1881 1910 1918 1925) 83.0018 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 6 6 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 cross-references Page 9) 187.8461 Tj -17.4613 -28.4801 Td -(1928 1932 1961 1967) 83.0018 Tj --8527.14 TJm -(5862 5917 5918 5931) 83.0018 Tj -17.4613 -37.9735 Td -(1976 2005 2023 2024) 83.0018 Tj --8527.14 TJm -(5932) 17.4741 Tj -17.4613 -47.4668 Td -(2028 2055 2057 2077) 83.0018 Tj --6520.6 TJm -(REG_VER 5861) 52.4222 Tj -17.4613 -56.9602 Td -(2080 2106 2109 2114) 83.0018 Tj --8527.14 TJm -(5861 5909) 39.3166 Tj -17.4613 -66.4535 Td -(2115 2116 2120 2121) 83.0018 Tj --6520.6 TJm -(release 1402) 52.4222 Tj -17.4613 -75.9469 Td -(2126 2129 2130 2138) 83.0018 Tj --8527.14 TJm -(0325 1402 1405 1763) 83.0018 Tj -17.4613 -85.4403 Td -(2155 2162 2163 2182) 83.0018 Tj --8527.14 TJm -(1769 1934 1978 1987) 83.0018 Tj -17.4613 -94.9336 Td -(2188 2554 2604 2606) 83.0018 Tj --8527.14 TJm -(2019 2032 2068 2086) 83.0018 Tj -17.4613 -104.427 Td -(2608 2651 2658 2659) 83.0018 Tj --8527.14 TJm -(2090 2176 2183 2343) 83.0018 Tj -17.4613 -113.9203 Td -(2660 2666 2671 2675) 83.0018 Tj --8527.14 TJm -(2369 2373 2619 2975) 83.0018 Tj -17.4613 -123.4137 Td -(2754 2766 2778 2796) 83.0018 Tj --8527.14 TJm -(2980 3409 3428 3482) 83.0018 Tj -17.4613 -132.9071 Td -(2810 2812 2826 2878) 83.0018 Tj --8527.14 TJm -(3578 3592 3641 3864) 83.0018 Tj -17.4613 -142.4004 Td -(2880 2883 2884 2905) 83.0018 Tj --8527.14 TJm -(3880 3892 3914 3942) 83.0018 Tj -17.4613 -151.8938 Td -(2939 2958 2974 3306) 83.0018 Tj --8527.14 TJm -(3960 3969 4429 4433) 83.0018 Tj -17.4613 -161.3871 Td -(3667 4361 4555 4570) 83.0018 Tj --8527.14 TJm -(4445 4460 4466 5222) 83.0018 Tj -17.4613 -170.8805 Td -(4587 4588 4646 4943) 83.0018 Tj --8527.14 TJm -(5225 5238 5247 5258) 83.0018 Tj -17.4613 -180.3739 Td -(4944 4963 4969 4989) 83.0018 Tj --8527.14 TJm -(5269 6398 6547 6562) 83.0018 Tj -17.4613 -189.8672 Td -(5003 5104 5107 5108) 83.0018 Tj --8527.14 TJm -(6582 6609) 39.3166 Tj -17.4613 -199.3606 Td -(5109 5110 5111 5154) 83.0018 Tj --6520.6 TJm -(ROOTDEV 0159) 52.4222 Tj -17.4613 -208.8539 Td -(5237 5257 5510 5606) 83.0018 Tj --8527.14 TJm -(0159 4359) 39.3166 Tj -17.4613 -218.3473 Td -(5617 5618 5619 5622) 83.0018 Tj --6520.6 TJm -(ROOTINO 3157) 52.4222 Tj -17.4613 -227.8407 Td -(6312 6561) 39.3166 Tj --13543.8 TJm -(3157 4359) 39.3166 Tj -0 -237.334 Td -(procdump 1654) 56.7907 Tj --11537.1 TJm -(run 2262) 34.9481 Tj -17.4613 -246.8274 Td -(0307 1654 6520) 61.1592 Tj --11035.5 TJm -(1661 2262 2263 2269) 83.0018 Tj -0 -256.3207 Td -(proghdr 0874) 52.4222 Tj --14045.3 TJm -(2307 2316 2317 2319) 83.0018 Tj -17.4613 -265.8141 Td -(0874 1119 1133 5016) 83.0018 Tj --8527.14 TJm -(2357) 17.4741 Tj -0 -275.3075 Td -(pushcli 1455) 52.4222 Tj --12038.8 TJm -(runcmd 6906) 48.0537 Tj -17.4613 -284.8008 Td -(0326 1375 1455 1723) 83.0018 Tj --8527.14 TJm -(6906 6920 6937 6943) 83.0018 Tj -0 -294.2942 Td -(readeflags 0485) 65.5277 Tj --12540.3 TJm -(6945 6959 6966 6977) 83.0018 Tj -17.4613 -303.7875 Td -(0485 1459 1468 1963) 83.0018 Tj --8527.14 TJm -(7025) 17.4741 Tj -17.4613 -313.2809 Td -(5758) 17.4741 Tj --14045.6 TJm -(RUNNING 1526) 52.4222 Tj -0 -322.7743 Td -(readi 4102) 43.6851 Tj --15048.7 TJm -(1526 1661 1927 1961) 83.0018 Tj -17.4613 -332.2672 Td -(0247 4102 4266 4512) 83.0018 Tj --8527.14 TJm -(2671) 17.4741 Tj -17.4613 -341.7606 Td -(4708 4709 5026 5034) 83.0018 Tj --6520.6 TJm -(safestrcpy 5375) 65.5277 Tj -17.4613 -351.2539 Td -(5065 5073) 39.3166 Tj --13543.8 TJm -(0333 1825 5104 5375) 83.0018 Tj -0 -360.7473 Td -(readsb 3678) 48.0537 Tj --12540.5 TJm -(sched 1953) 43.6851 Tj -17.4613 -370.2407 Td -(3678 3711 3738 3809) 83.0018 Tj --8527.14 TJm -(1953 1958 1960 1962) 83.0018 Tj -0 -379.734 Td -(readsect 1160) 56.7907 Tj --13543.7 TJm -(1964 1977 2025 2139) 83.0018 Tj -17.4613 -389.2274 Td -(1160 1195) 39.3166 Tj --11537.3 TJm -(scheduler 1908) 61.1592 Tj -0 -398.7207 Td -(readseg 1179) 52.4222 Tj --14045.3 TJm -(0308 1263 1559 1908) 83.0018 Tj -17.4613 -408.2141 Td -(1113 1126 1137 1179) 83.0018 Tj --8527.14 TJm -(1928 1967) 39.3166 Tj -0 -417.7075 Td -(REDIR 6858) 43.6851 Tj --13042.1 TJm -(SCROLLLOCK 6114) 65.5277 Tj -17.4613 -427.2008 Td -(6858 6930 7070 7371) 83.0018 Tj --8527.14 TJm -(6114 6147) 39.3166 Tj -0 -436.6942 Td -(redircmd 6875 7064) 78.6333 Tj --9028.81 TJm -(SECTSIZE 1111) 56.7907 Tj -17.4613 -446.1875 Td -(6875 6913 6931 7064) 83.0018 Tj --8527.14 TJm -(1111 1173 1186 1189) 83.0018 Tj -17.4613 -455.6809 Td -(7066 7275 7278 7281) 83.0018 Tj --8527.14 TJm -(1194) 17.4741 Tj -17.4613 -465.1743 Td -(7359 7372) 39.3166 Tj --11537.3 TJm -(SEG 0701) 34.9481 Tj -0 -474.6672 Td -(REG_ID 5860) 48.0537 Tj --14547 TJm -(0701 1708 1709 1710) 83.0018 Tj -17.4613 -484.1606 Td -(5860 5910) 39.3166 Tj --13543.8 TJm -(1724 1725) 39.3166 Tj -0 -493.654 Td -(REG_TABLE 5862) 61.1592 Tj --11035.5 TJm -(SEG16 0706) 43.6851 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 cross-references Page 10) 192.2146 Tj -17.4613 -28.4801 Td -(0706 1726) 39.3166 Tj --13543.8 TJm -(3665 4085 4476 4553) 83.0018 Tj -0 -37.9735 Td -(segdesc 0677) 52.4222 Tj --14045.3 TJm -(4654 6803) 39.3166 Tj -17.4613 -47.4664 Td -(0450 0453 0677 0701) 83.0018 Tj --6520.6 TJm -(stati 4085) 43.6851 Tj -17.4613 -56.9598 Td -(0706 1561) 39.3166 Tj --13543.8 TJm -(0248 4085 4480) 61.1592 Tj -0 -66.4531 Td -(SEG_ASM 0608) 52.4222 Tj --12038.8 TJm -(STA_R 0617 0718) 65.5277 Tj -17.4613 -75.9465 Td -(0608 0992 0993 1092) 83.0018 Tj --8527.14 TJm -(0617 0718 0992 1092) 83.0018 Tj -17.4613 -85.4399 Td -(1093) 17.4741 Tj --16052.1 TJm -(1708 1724) 39.3166 Tj -0 -94.9332 Td -(SEG_KCODE 0907 1021 1502 2500) 126.6869 Tj --3510.47 TJm -(STA_W 0616 0717) 65.5277 Tj -17.4613 -104.4266 Td -(0961 1061 1502 1708) 83.0018 Tj --8527.14 TJm -(0616 0717 0993 1093) 83.0018 Tj -17.4613 -113.9199 Td -(2571 2572) 39.3166 Tj --13543.8 TJm -(1709 1710 1725) 61.1592 Tj -0 -123.4133 Td -(SEG_KCPU 1504 2502) 78.6333 Tj --9028.81 TJm -(STA_X 0613 0714) 65.5277 Tj -17.4613 -132.9067 Td -(1504 1710 1712 2518) 83.0018 Tj --8527.14 TJm -(0613 0714 0992 1092) 83.0018 Tj -0 -142.4 Td -(SEG_KDATA 0908 1022 1503 2501) 126.6869 Tj --5517.01 TJm -(1708 1724) 39.3166 Tj -17.4613 -151.8934 Td -(0966 1066 1503 1709) 83.0018 Tj --6520.6 TJm -(sti 0526) 34.9481 Tj -17.4613 -161.3867 Td -(1728 2515) 39.3166 Tj --13543.8 TJm -(0526 0528 1473 1914) 83.0018 Tj -0 -170.8801 Td -(SEG_NULLASM 0604) 69.8962 Tj --10032.1 TJm -(stosb 0442) 43.6851 Tj -17.4613 -180.3735 Td -(0604 0991 1091) 61.1592 Tj --11035.5 TJm -(0442 0444 1139 5306) 83.0018 Tj -0 -189.8664 Td -(SEG_TSS 1507) 52.4222 Tj --12038.8 TJm -(strlen 5389) 48.0537 Tj -17.4613 -199.3598 Td -(1507 1726 1727 1730) 83.0018 Tj --8527.14 TJm -(0334 5046 5086 5389) 83.0018 Tj -0 -208.8532 Td -(SEG_UCODE 1505) 61.1592 Tj --13042 TJm -(7019 7223) 39.3166 Tj -17.4613 -218.3465 Td -(1505 1724 1817) 61.1592 Tj --9028.94 TJm -(strncmp 5351) 52.4222 Tj -0 -227.8399 Td -(SEG_UDATA 1506) 61.1592 Tj --13042 TJm -(0335 4205 5351) 61.1592 Tj -17.4613 -237.3332 Td -(1506 1725 1818) 61.1592 Tj --9028.94 TJm -(strncpy 5361) 52.4222 Tj -0 -246.8266 Td -(SETGATE 0821) 52.4222 Tj --14045.3 TJm -(0336 4272 5361) 61.1592 Tj -17.4613 -256.32 Td -(0821 2571 2572) 61.1592 Tj --9028.94 TJm -(STS_IG32 0732) 56.7907 Tj -0 -265.8133 Td -(SHIFT 6108) 43.6851 Tj --15048.7 TJm -(0732 0827) 39.3166 Tj -17.4613 -275.3067 Td -(6108 6136 6137 6285) 83.0018 Tj --6520.6 TJm -(STS_T32A 0729) 56.7907 Tj -0 -284.8 Td -(skipelem 4315) 56.7907 Tj --13543.7 TJm -(0729 1726) 39.3166 Tj -17.4613 -294.2934 Td -(4315 4363) 39.3166 Tj --11537.3 TJm -(STS_TG32 0733) 56.7907 Tj -0 -303.7868 Td -(sleep 2003) 43.6851 Tj --15048.7 TJm -(0733 0827) 39.3166 Tj -17.4613 -313.2801 Td -(0311 1659 2003 2006) 83.0018 Tj --6520.6 TJm -(sum 5525) 34.9481 Tj -17.4613 -322.7735 Td -(2009 2188 2978 3480) 83.0018 Tj --8527.14 TJm -(5525 5527 5529 5531) 83.0018 Tj -17.4613 -332.2668 Td -(3581 3912 5242 5261) 83.0018 Tj --8527.14 TJm -(5532 5543 5592) 61.1592 Tj -17.4613 -341.7602 Td -(6566 6779) 39.3166 Tj --11537.3 TJm -(superblock 3161) 65.5277 Tj -0 -351.2536 Td -(spinlock 1301) 56.7907 Tj --13543.7 TJm -(3161 3678 3708 3733) 83.0018 Tj -17.4613 -360.7469 Td -(0206 0311 0321 0323) 83.0018 Tj --8527.14 TJm -(3807) 17.4741 Tj -17.4613 -370.2403 Td -(0324 0325 0354 1301) 83.0018 Tj --6520.6 TJm -(SVR 5664) 34.9481 Tj -17.4613 -379.7336 Td -(1358 1361 1373 1402) 83.0018 Tj --8527.14 TJm -(5664 5707) 39.3166 Tj -17.4613 -389.227 Td -(1444 1606 1609 2003) 83.0018 Tj --6520.6 TJm -(swtch 2208) 43.6851 Tj -17.4613 -398.7204 Td -(2260 2268 2557 2562) 83.0018 Tj --8527.14 TJm -(0318 1928 1967 2207) 83.0018 Tj -17.4613 -408.2137 Td -(3309 3324 3526 3530) 83.0018 Tj --8527.14 TJm -(2208) 17.4741 Tj -17.4613 -417.7071 Td -(3668 3784 4405 4409) 83.0018 Tj --6520.6 TJm -(SYSCALL 6753 6760 6761 6762 6763 67) 152.898 Tj -17.4613 -427.2004 Td -(5157 5162 6308 6320) 83.0018 Tj --8527.14 TJm -(6760 6761 6762 6763) 83.0018 Tj -17.4613 -436.6938 Td -(6502) 17.4741 Tj --16052.1 TJm -(6764 6765 6766 6767) 83.0018 Tj -0 -446.1872 Td -(start 0914 1028 6707) 87.3703 Tj --10032 TJm -(6768 6769 6770 6771) 83.0018 Tj -17.4613 -455.6805 Td -(0913 0914 0975 1027) 83.0018 Tj --8527.14 TJm -(6772 6773 6774 6775) 83.0018 Tj -17.4613 -465.1739 Td -(1028 1075 1076 6706) 83.0018 Tj --8527.14 TJm -(6776 6777 6778 6779) 83.0018 Tj -17.4613 -474.6672 Td -(6707) 17.4741 Tj --14045.6 TJm -(syscall 2874) 52.4222 Tj -0 -484.1606 Td -(stat 3104) 39.3166 Tj --15550.3 TJm -(0344 2607 2756 2874) 83.0018 Tj -17.4613 -493.654 Td -(0207 0230 0248 3104) 83.0018 Tj --6520.6 TJm -(SYS_chdir 2716) 61.1592 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 7 7 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 cross-references Page 11) 192.2146 Tj -17.4613 -28.4801 Td -(2716 2851) 39.3166 Tj --13543.8 TJm -(2841 2863 4851) 61.1592 Tj -0 -37.9735 Td -(sys_chdir 4930) 61.1592 Tj --11035.5 TJm -(SYS_pipe 2704) 56.7907 Tj -17.4613 -47.4664 Td -(2829 2851 4930) 61.1592 Tj --11035.5 TJm -(2704 2864) 39.3166 Tj -0 -56.9598 Td -(SYS_close 2707) 61.1592 Tj --11035.5 TJm -(sys_pipe 4976) 56.7907 Tj -17.4613 -66.4531 Td -(2707 2852) 39.3166 Tj --13543.8 TJm -(2842 2864 4976) 61.1592 Tj -0 -75.9465 Td -(sys_close 4639) 61.1592 Tj --11035.5 TJm -(SYS_read 2706) 56.7907 Tj -17.4613 -85.4399 Td -(2830 2852 4639) 61.1592 Tj --11035.5 TJm -(2706 2865) 39.3166 Tj -0 -94.9332 Td -(SYS_dup 2717) 52.4222 Tj --12038.8 TJm -(sys_read 4615) 56.7907 Tj -17.4613 -104.4266 Td -(2717 2853) 39.3166 Tj --13543.8 TJm -(2843 2865 4615) 61.1592 Tj -0 -113.9199 Td -(sys_dup 4601) 52.4222 Tj --12038.8 TJm -(SYS_sbrk 2719) 56.7907 Tj -17.4613 -123.4133 Td -(2831 2853 4601) 61.1592 Tj --11035.5 TJm -(2719 2866) 39.3166 Tj -0 -132.9067 Td -(SYS_exec 2709) 56.7907 Tj --11537.1 TJm -(sys_sbrk 2951) 56.7907 Tj -17.4613 -142.4 Td -(2709 2854 6711) 61.1592 Tj --11035.5 TJm -(2844 2866 2951) 61.1592 Tj -0 -151.8934 Td -(sys_exec 4951) 56.7907 Tj --11537.1 TJm -(SYS_sleep 2720) 61.1592 Tj -17.4613 -161.3867 Td -(2832 2854 4951) 61.1592 Tj --11035.5 TJm -(2720 2867) 39.3166 Tj -0 -170.8801 Td -(SYS_exit 2702) 56.7907 Tj --11537.1 TJm -(sys_sleep 2965) 61.1592 Tj -17.4613 -180.3735 Td -(2702 2855 6716) 61.1592 Tj --11035.5 TJm -(2845 2867 2965) 61.1592 Tj -0 -189.8664 Td -(sys_exit 2914) 56.7907 Tj --11537.1 TJm -(SYS_unlink 2712) 65.5277 Tj -17.4613 -199.3598 Td -(2833 2855 2914) 61.1592 Tj --11035.5 TJm -(2712 2868) 39.3166 Tj -0 -208.8532 Td -(SYS_fork 2701) 56.7907 Tj --11537.1 TJm -(sys_unlink 4751) 65.5277 Tj -17.4613 -218.3465 Td -(2701 2856) 39.3166 Tj --13543.8 TJm -(2846 2868 4751) 61.1592 Tj -0 -227.8399 Td -(sys_fork 2908) 56.7907 Tj --11537.1 TJm -(SYS_wait 2703) 56.7907 Tj -17.4613 -237.3332 Td -(2834 2856 2908) 61.1592 Tj --11035.5 TJm -(2703 2869) 39.3166 Tj -0 -246.8266 Td -(SYS_fstat 2713) 61.1592 Tj --11035.5 TJm -(sys_wait 2921) 56.7907 Tj -17.4613 -256.32 Td -(2713 2857) 39.3166 Tj --13543.8 TJm -(2847 2869 2921) 61.1592 Tj -0 -265.8133 Td -(sys_fstat 4651) 61.1592 Tj --11035.5 TJm -(SYS_write 2705) 61.1592 Tj -17.4613 -275.3067 Td -(2835 2857 4651) 61.1592 Tj --11035.5 TJm -(2705 2870) 39.3166 Tj -0 -284.8 Td -(SYS_getpid 2718) 65.5277 Tj --10533.8 TJm -(sys_write 4627) 61.1592 Tj -17.4613 -294.2934 Td -(2718 2858) 39.3166 Tj --13543.8 TJm -(2848 2870 4627) 61.1592 Tj -0 -303.7868 Td -(sys_getpid 2937) 65.5277 Tj --10533.8 TJm -(taskstate 0751) 61.1592 Tj -17.4613 -313.2801 Td -(2836 2858 2937) 61.1592 Tj --11035.5 TJm -(0751 1560) 39.3166 Tj -0 -322.7735 Td -(SYS_kill 2708) 56.7907 Tj --11537.1 TJm -(TDCR 5685) 39.3166 Tj -17.4613 -332.2664 Td -(2708 2859) 39.3166 Tj --13543.8 TJm -(5685 5713) 39.3166 Tj -0 -341.7598 Td -(sys_kill 2927) 56.7907 Tj --11537.1 TJm -(ticks 2563) 43.6851 Tj -17.4613 -351.2532 Td -(2837 2859 2927) 61.1592 Tj --11035.5 TJm -(0352 2563 2617 2618) 83.0018 Tj -0 -360.7465 Td -(SYS_link 2714) 56.7907 Tj --13543.7 TJm -(2972 2973 2978) 61.1592 Tj -17.4613 -370.2399 Td -(2714 2860) 39.3166 Tj --11537.3 TJm -(tickslock 2562) 61.1592 Tj -0 -379.7332 Td -(sys_link 4663) 56.7907 Tj --13543.7 TJm -(0354 2562 2574 2616) 83.0018 Tj -17.4613 -389.2266 Td -(2838 2860 4663) 61.1592 Tj --11035.5 TJm -(2619 2971 2975 2978) 83.0018 Tj -0 -398.72 Td -(SYS_mkdir 2715) 61.1592 Tj --13042 TJm -(2980) 17.4741 Tj -17.4613 -408.2133 Td -(2715 2861) 39.3166 Tj --11537.3 TJm -(TICR 5683) 39.3166 Tj -0 -417.7067 Td -(sys_mkdir 4901) 61.1592 Tj --13042 TJm -(5683 5715) 39.3166 Tj -17.4613 -427.2 Td -(2839 2861 4901) 61.1592 Tj --9028.94 TJm -(TIMER 5675) 43.6851 Tj -0 -436.6934 Td -(SYS_mknod 2711) 61.1592 Tj --13042 TJm -(5675 5714) 39.3166 Tj -17.4613 -446.1868 Td -(2711 2862) 39.3166 Tj --11537.3 TJm -(timerinit 6674) 61.1592 Tj -0 -455.6801 Td -(sys_mknod 4913) 61.1592 Tj --13042 TJm -(0347 1232 6674) 61.1592 Tj -17.4613 -465.1735 Td -(2840 2862 4913) 61.1592 Tj --9028.94 TJm -(TIMER_16BIT 6671) 69.8962 Tj -0 -474.6665 Td -(SYS_open 2710) 56.7907 Tj --13543.7 TJm -(6671 6677) 39.3166 Tj -17.4613 -484.1598 Td -(2710 2863) 39.3166 Tj --11537.3 TJm -(TIMER_DIV 6666) 61.1592 Tj -0 -493.6532 Td -(sys_open 4851) 56.7907 Tj --13543.7 TJm -(6666 6678 6679) 61.1592 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 cross-references Page 12) 192.2146 Tj -0 -28.4801 Td -(TIMER_FREQ 6665) 65.5277 Tj --12540.3 TJm -(5931 5997 6016) 61.1592 Tj -17.4613 -37.9735 Td -(6665 6666) 39.3166 Tj --11537.3 TJm -(T_SYSCALL 2426) 61.1592 Tj -0 -47.4664 Td -(TIMER_MODE 6668) 65.5277 Tj --12540.3 TJm -(2426 2572 2603 6712) 83.0018 Tj -17.4613 -56.9598 Td -(6668 6677) 39.3166 Tj --13543.8 TJm -(6717 6757) 39.3166 Tj -0 -66.4531 Td -(TIMER_RATEGEN 6670) 78.6333 Tj --9028.81 TJm -(usegment 1721) 56.7907 Tj -17.4613 -75.9465 Td -(6670 6677) 39.3166 Tj --13543.8 TJm -(0310 1721 1846 1926) 83.0018 Tj -0 -85.4399 Td -(TIMER_SEL0 6669) 65.5277 Tj --12540.3 TJm -(5112) 17.4741 Tj -17.4613 -94.9332 Td -(6669 6677) 39.3166 Tj --11537.3 TJm -(userinit 1802) 56.7907 Tj -0 -104.4266 Td -(TPR 5662) 34.9481 Tj --16052 TJm -(0312 1233 1802) 61.1592 Tj -17.4613 -113.9199 Td -(5662 5743) 39.3166 Tj --11537.3 TJm -(VER 5661) 34.9481 Tj -0 -123.4133 Td -(trap 2601) 39.3166 Tj --15550.3 TJm -(5661 5723) 39.3166 Tj -17.4613 -132.9067 Td -(2452 2454 2524 2601) 83.0018 Tj --6520.6 TJm -(wait 2153) 39.3166 Tj -17.4613 -142.4 Td -(2653 2655 2658) 61.1592 Tj --11035.5 TJm -(0313 2153 2923 6762) 83.0018 Tj -0 -151.8934 Td -(trapframe 0552) 61.1592 Tj --13042 TJm -(6833 6944 6970 6971) 83.0018 Tj -17.4613 -161.3867 Td -(0552 1536 1780 2601) 83.0018 Tj --8527.14 TJm -(7026) 17.4741 Tj -0 -170.8801 Td -(trapret 2529) 52.4222 Tj --12038.8 TJm -(waitdisk 1151) 56.7907 Tj -17.4613 -180.3735 Td -(1617 1785 2528 2529) 83.0018 Tj --8527.14 TJm -(1151 1163 1172) 61.1592 Tj -0 -189.8664 Td -(tvinit 2566) 48.0537 Tj --12540.5 TJm -(wakeup 2064) 48.0537 Tj -17.4613 -199.3598 Td -(0353 1226 2566) 61.1592 Tj --11035.5 TJm -(0314 2064 2618 3422) 83.0018 Tj -0 -208.8532 Td -(T_DEV 3102) 43.6851 Tj --15048.7 TJm -(3639 3941 3966 5216) 83.0018 Tj -17.4613 -218.3465 Td -(3102 4107 4157 4923) 83.0018 Tj --8527.14 TJm -(5219 5241 5246 5268) 83.0018 Tj -0 -227.8399 Td -(T_DIR 3100) 43.6851 Tj --15048.7 TJm -(6541) 17.4741 Tj -17.4613 -237.3332 Td -(3100 4218 4365 4673) 83.0018 Tj --6520.6 TJm -(wakeup1 2053) 52.4222 Tj -17.4613 -246.8266 Td -(4778 4787 4829 4868) 83.0018 Tj --8527.14 TJm -(2053 2067 2126 2133) 83.0018 Tj -17.4613 -256.32 Td -(4906 4938) 39.3166 Tj --11537.3 TJm -(writei 4152) 48.0537 Tj -0 -265.8133 Td -(T_FILE 3101) 48.0537 Tj --14547 TJm -(0249 4152 4274 4532) 83.0018 Tj -17.4613 -275.3067 Td -(3101 4814 4862) 61.1592 Tj --11035.5 TJm -(4785 4786) 39.3166 Tj -0 -284.8 Td -(T_IRQ0 2429) 48.0537 Tj --12540.5 TJm -(xchg 0501) 39.3166 Tj -17.4613 -294.2934 Td -(2429 2614 2623 2627) 83.0018 Tj --8527.14 TJm -(0501 1260 1382 1419) 83.0018 Tj -17.4613 -303.7868 Td -(2631 2635 2636 2671) 83.0018 Tj --6520.6 TJm -(yield 1973) 43.6851 Tj -17.4613 -313.2801 Td -(5707 5714 5727 5917) 83.0018 Tj --8527.14 TJm -(0315 1973 2672) 61.1592 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 8 8 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/types.h Page 1) 166.0035 Tj -0 -28.4801 Td -(0100 typedef unsigned int uint;) 144.161 Tj -0 -37.9735 Td -(0101 typedef unsigned short ushort;) 152.898 Tj -0 -47.4668 Td -(0102 typedef unsigned char uchar;) 148.5295 Tj -0 -56.9602 Td -(0103 ) 21.8426 Tj -0 -66.4535 Td -(0104 ) 21.8426 Tj -0 -75.9469 Td -(0105 ) 21.8426 Tj -0 -85.4403 Td -(0106 ) 21.8426 Tj -0 -94.9336 Td -(0107 ) 21.8426 Tj -0 -104.427 Td -(0108 ) 21.8426 Tj -0 -113.9203 Td -(0109 ) 21.8426 Tj -0 -123.4137 Td -(0110 ) 21.8426 Tj -0 -132.9071 Td -(0111 ) 21.8426 Tj -0 -142.4004 Td -(0112 ) 21.8426 Tj -0 -151.8938 Td -(0113 ) 21.8426 Tj -0 -161.3871 Td -(0114 ) 21.8426 Tj -0 -170.8805 Td -(0115 ) 21.8426 Tj -0 -180.3739 Td -(0116 ) 21.8426 Tj -0 -189.8672 Td -(0117 ) 21.8426 Tj -0 -199.3606 Td -(0118 ) 21.8426 Tj -0 -208.8539 Td -(0119 ) 21.8426 Tj -0 -218.3473 Td -(0120 ) 21.8426 Tj -0 -227.8407 Td -(0121 ) 21.8426 Tj -0 -237.334 Td -(0122 ) 21.8426 Tj -0 -246.8274 Td -(0123 ) 21.8426 Tj -0 -256.3207 Td -(0124 ) 21.8426 Tj -0 -265.8141 Td -(0125 ) 21.8426 Tj -0 -275.3075 Td -(0126 ) 21.8426 Tj -0 -284.8008 Td -(0127 ) 21.8426 Tj -0 -294.2942 Td -(0128 ) 21.8426 Tj -0 -303.7875 Td -(0129 ) 21.8426 Tj -0 -313.2809 Td -(0130 ) 21.8426 Tj -0 -322.7743 Td -(0131 ) 21.8426 Tj -0 -332.2676 Td -(0132 ) 21.8426 Tj -0 -341.761 Td -(0133 ) 21.8426 Tj -0 -351.2543 Td -(0134 ) 21.8426 Tj -0 -360.7477 Td -(0135 ) 21.8426 Tj -0 -370.2411 Td -(0136 ) 21.8426 Tj -0 -379.7344 Td -(0137 ) 21.8426 Tj -0 -389.2278 Td -(0138 ) 21.8426 Tj -0 -398.7211 Td -(0139 ) 21.8426 Tj -0 -408.2145 Td -(0140 ) 21.8426 Tj -0 -417.7079 Td -(0141 ) 21.8426 Tj -0 -427.2012 Td -(0142 ) 21.8426 Tj -0 -436.6946 Td -(0143 ) 21.8426 Tj -0 -446.1879 Td -(0144 ) 21.8426 Tj -0 -455.6813 Td -(0145 ) 21.8426 Tj -0 -465.1747 Td -(0146 ) 21.8426 Tj -0 -474.668 Td -(0147 ) 21.8426 Tj -0 -484.1614 Td -(0148 ) 21.8426 Tj -0 -493.6547 Td -(0149 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 01) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/param.h Page 1) 166.0035 Tj -0 -28.4801 Td -(0150 #define NPROC 64 // maximum number of processes) 262.1109 Tj -0 -37.9735 Td -(0151 #define PAGE 4096 // granularity of user-space memo\ -ry allocation) 332.0071 Tj -0 -47.4668 Td -(0152 #define KSTACKSIZE PAGE // size of per-process kernel sta\ -ck) 283.9534 Tj -0 -56.9602 Td -(0153 #define NCPU 8 // maximum number of CPUs) 240.2683 Tj -0 -66.4535 Td -(0154 #define NOFILE 16 // open files per process) 240.2683 Tj -0 -75.9469 Td -(0155 #define NFILE 100 // open files per system) 235.8998 Tj -0 -85.4403 Td -(0156 #define NBUF 10 // size of disk block cache) 249.0053 Tj -0 -94.9336 Td -(0157 #define NINODE 50 // maximum number of active i-nod\ -es) 283.9534 Tj -0 -104.427 Td -(0158 #define NDEV 10 // maximum major device number) 262.1109 Tj -0 -113.9203 Td -(0159 #define ROOTDEV 1 // device number of file system r\ -oot disk) 310.1645 Tj -0 -123.4137 Td -(0160 ) 21.8426 Tj -0 -132.9071 Td -(0161 ) 21.8426 Tj -0 -142.4004 Td -(0162 ) 21.8426 Tj -0 -151.8938 Td -(0163 ) 21.8426 Tj -0 -161.3871 Td -(0164 ) 21.8426 Tj -0 -170.8805 Td -(0165 ) 21.8426 Tj -0 -180.3739 Td -(0166 ) 21.8426 Tj -0 -189.8672 Td -(0167 ) 21.8426 Tj -0 -199.3606 Td -(0168 ) 21.8426 Tj -0 -208.8539 Td -(0169 ) 21.8426 Tj -0 -218.3473 Td -(0170 ) 21.8426 Tj -0 -227.8407 Td -(0171 ) 21.8426 Tj -0 -237.334 Td -(0172 ) 21.8426 Tj -0 -246.8274 Td -(0173 ) 21.8426 Tj -0 -256.3207 Td -(0174 ) 21.8426 Tj -0 -265.8141 Td -(0175 ) 21.8426 Tj -0 -275.3075 Td -(0176 ) 21.8426 Tj -0 -284.8008 Td -(0177 ) 21.8426 Tj -0 -294.2942 Td -(0178 ) 21.8426 Tj -0 -303.7875 Td -(0179 ) 21.8426 Tj -0 -313.2809 Td -(0180 ) 21.8426 Tj -0 -322.7743 Td -(0181 ) 21.8426 Tj -0 -332.2676 Td -(0182 ) 21.8426 Tj -0 -341.761 Td -(0183 ) 21.8426 Tj -0 -351.2543 Td -(0184 ) 21.8426 Tj -0 -360.7477 Td -(0185 ) 21.8426 Tj -0 -370.2411 Td -(0186 ) 21.8426 Tj -0 -379.7344 Td -(0187 ) 21.8426 Tj -0 -389.2278 Td -(0188 ) 21.8426 Tj -0 -398.7211 Td -(0189 ) 21.8426 Tj -0 -408.2145 Td -(0190 ) 21.8426 Tj -0 -417.7079 Td -(0191 ) 21.8426 Tj -0 -427.2012 Td -(0192 ) 21.8426 Tj -0 -436.6946 Td -(0193 ) 21.8426 Tj -0 -446.1879 Td -(0194 ) 21.8426 Tj -0 -455.6813 Td -(0195 ) 21.8426 Tj -0 -465.1747 Td -(0196 ) 21.8426 Tj -0 -474.668 Td -(0197 ) 21.8426 Tj -0 -484.1614 Td -(0198 ) 21.8426 Tj -0 -493.6547 Td -(0199 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 01) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 9 9 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/defs.h Page 1) 161.635 Tj -0 -28.4801 Td -(0200 struct buf;) 69.8962 Tj -0 -37.9735 Td -(0201 struct context;) 87.3703 Tj -0 -47.4668 Td -(0202 struct file;) 74.2647 Tj -0 -56.9602 Td -(0203 struct inode;) 78.6333 Tj -0 -66.4535 Td -(0204 struct pipe;) 74.2647 Tj -0 -75.9469 Td -(0205 struct proc;) 74.2647 Tj -0 -85.4403 Td -(0206 struct spinlock;) 91.7388 Tj -0 -94.9336 Td -(0207 struct stat;) 74.2647 Tj -0 -104.427 Td -(0208 ) 21.8426 Tj -0 -113.9203 Td -(0209 // bio.c) 56.7907 Tj -0 -123.4137 Td -(0210 void binit\(void\);) 144.161 Tj -0 -132.9071 Td -(0211 struct buf* bread\(uint, uint\);) 170.3721 Tj -0 -142.4004 Td -(0212 void brelse\(struct buf*\);) 179.1091 Tj -0 -151.8938 Td -(0213 void bwrite\(struct buf*\);) 179.1091 Tj -0 -161.3871 Td -(0214 ) 21.8426 Tj -0 -170.8805 Td -(0215 // console.c) 74.2647 Tj -0 -180.3739 Td -(0216 void consoleinit\(void\);) 170.3721 Tj -0 -189.8672 Td -(0217 void cprintf\(char*, ...\);) 179.1091 Tj -0 -199.3606 Td -(0218 void consoleintr\(int\(*\)\(void\)\);) 205.3202 Tj -0 -208.8539 Td -(0219 void panic\(char*\) __attribute__\(\(noreturn\)\ -\);) 262.1109 Tj -0 -218.3473 Td -(0220 ) 21.8426 Tj -0 -227.8407 Td -(0221 // exec.c) 61.1592 Tj -0 -237.334 Td -(0222 int exec\(char*, char**\);) 179.1091 Tj -0 -246.8274 Td -(0223 ) 21.8426 Tj -0 -256.3207 Td -(0224 // file.c) 61.1592 Tj -0 -265.8141 Td -(0225 struct file* filealloc\(void\);) 161.635 Tj -0 -275.3075 Td -(0226 void fileclose\(struct file*\);) 196.5831 Tj -0 -284.8008 Td -(0227 struct file* filedup\(struct file*\);) 187.8461 Tj -0 -294.2942 Td -(0228 void fileinit\(void\);) 157.2665 Tj -0 -303.7875 Td -(0229 int fileread\(struct file*, char*, int n\);) 253.3738 Tj -0 -313.2809 Td -(0230 int filestat\(struct file*, struct stat*\);) 253.3738 Tj -0 -322.7743 Td -(0231 int filewrite\(struct file*, char*, int n\);) 257.7424 Tj -0 -332.2676 Td -(0232 ) 21.8426 Tj -0 -341.761 Td -(0233 // fs.c) 52.4222 Tj -0 -351.2543 Td -(0234 int dirlink\(struct inode*, char*, uint\);) 249.0053 Tj -0 -360.7477 Td -(0235 struct inode* dirlookup\(struct inode*, char*, uint*\);) 262.1109 Tj -0 -370.2411 Td -(0236 struct inode* ialloc\(uint, short\);) 179.1091 Tj -0 -379.7344 Td -(0237 struct inode* idup\(struct inode*\);) 179.1091 Tj -0 -389.2278 Td -(0238 void iinit\(void\);) 144.161 Tj -0 -398.7211 Td -(0239 void ilock\(struct inode*\);) 183.4776 Tj -0 -408.2145 Td -(0240 void iput\(struct inode*\);) 179.1091 Tj -0 -417.7079 Td -(0241 void iunlock\(struct inode*\);) 192.2146 Tj -0 -427.2012 Td -(0242 void iunlockput\(struct inode*\);) 205.3202 Tj -0 -436.6946 Td -(0243 void iupdate\(struct inode*\);) 192.2146 Tj -0 -446.1879 Td -(0244 int namecmp\(const char*, const char*\);) 240.2683 Tj -0 -455.6813 Td -(0245 struct inode* namei\(char*\);) 148.5295 Tj -0 -465.1747 Td -(0246 struct inode* nameiparent\(char*, char*\);) 205.3202 Tj -0 -474.668 Td -(0247 int readi\(struct inode*, char*, uint, uint\);) 266.4794 Tj -0 -484.1614 Td -(0248 void stati\(struct inode*, struct stat*\);) 244.6368 Tj -0 -493.6547 Td -(0249 int writei\(struct inode*, char*, uint, uint\)\ -;) 270.8479 Tj -0 -522.1348 Td -(Sheet 02) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/defs.h Page 2) 161.635 Tj -0 -28.4801 Td -(0250 // ide.c) 56.7907 Tj -0 -37.9735 Td -(0251 void ideinit\(void\);) 152.898 Tj -0 -47.4668 Td -(0252 void ideintr\(void\);) 152.898 Tj -0 -56.9602 Td -(0253 void iderw\(struct buf*\);) 174.7406 Tj -0 -66.4535 Td -(0254 ) 21.8426 Tj -0 -75.9469 Td -(0255 // ioapic.c) 69.8962 Tj -0 -85.4403 Td -(0256 void ioapicenable\(int irq, int cpu\);) 227.1628 Tj -0 -94.9336 Td -(0257 extern uchar ioapicid;) 131.0554 Tj -0 -104.427 Td -(0258 void ioapicinit\(void\);) 166.0035 Tj -0 -113.9203 Td -(0259 ) 21.8426 Tj -0 -123.4137 Td -(0260 // kalloc.c) 69.8962 Tj -0 -132.9071 Td -(0261 char* kalloc\(int\);) 144.161 Tj -0 -142.4004 Td -(0262 void kfree\(char*, int\);) 170.3721 Tj -0 -151.8938 Td -(0263 void kinit\(void\);) 144.161 Tj -0 -161.3871 Td -(0264 ) 21.8426 Tj -0 -170.8805 Td -(0265 // kbd.c) 56.7907 Tj -0 -180.3739 Td -(0266 void kbdintr\(void\);) 152.898 Tj -0 -189.8672 Td -(0267 ) 21.8426 Tj -0 -199.3606 Td -(0268 // lapic.c) 65.5277 Tj -0 -208.8539 Td -(0269 int cpunum\(void\);) 148.5295 Tj -0 -218.3473 Td -(0270 extern volatile uint* lapic;) 157.2665 Tj -0 -227.8407 Td -(0271 void lapiceoi\(void\);) 157.2665 Tj -0 -237.334 Td -(0272 void lapicinit\(int\);) 157.2665 Tj -0 -246.8274 Td -(0273 void lapicstartap\(uchar, uint\);) 205.3202 Tj -0 -256.3207 Td -(0274 void microdelay\(int\);) 161.635 Tj -0 -265.8141 Td -(0275 ) 21.8426 Tj -0 -275.3075 Td -(0276 // mp.c) 52.4222 Tj -0 -284.8008 Td -(0277 extern int ismp;) 113.5814 Tj -0 -294.2942 Td -(0278 int mpbcpu\(void\);) 148.5295 Tj -0 -303.7875 Td -(0279 void mpinit\(void\);) 148.5295 Tj -0 -313.2809 Td -(0280 void mpstartthem\(void\);) 170.3721 Tj -0 -322.7743 Td -(0281 ) 21.8426 Tj -0 -332.2676 Td -(0282 // picirq.c) 69.8962 Tj -0 -341.761 Td -(0283 void picenable\(int\);) 157.2665 Tj -0 -351.2543 Td -(0284 void picinit\(void\);) 152.898 Tj -0 -360.7477 Td -(0285 ) 21.8426 Tj -0 -370.2411 Td -(0286 // pipe.c) 61.1592 Tj -0 -379.7344 Td -(0287 int pipealloc\(struct file**, struct file**\);) 266.4794 Tj -0 -389.2278 Td -(0288 void pipeclose\(struct pipe*, int\);) 218.4257 Tj -0 -398.7211 Td -(0289 int piperead\(struct pipe*, char*, int\);) 244.6368 Tj -0 -408.2145 Td -(0290 int pipewrite\(struct pipe*, char*, int\);) 249.0053 Tj -0 -417.7079 Td -(0291 ) 21.8426 Tj -0 -427.2012 Td -(0292 ) 21.8426 Tj -0 -436.6946 Td -(0293 ) 21.8426 Tj -0 -446.1879 Td -(0294 ) 21.8426 Tj -0 -455.6813 Td -(0295 ) 21.8426 Tj -0 -465.1747 Td -(0296 ) 21.8426 Tj -0 -474.668 Td -(0297 ) 21.8426 Tj -0 -484.1614 Td -(0298 ) 21.8426 Tj -0 -493.6547 Td -(0299 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 02) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 10 10 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/defs.h Page 3) 161.635 Tj -0 -28.4801 Td -(0300 // proc.c) 61.1592 Tj -0 -37.9735 Td -(0301 struct proc* copyproc\(struct proc*\);) 192.2146 Tj -0 -47.4668 Td -(0302 void exit\(void\);) 139.7925 Tj -0 -56.9602 Td -(0303 int fork\(void\);) 139.7925 Tj -0 -66.4535 Td -(0304 int growproc\(int\);) 152.898 Tj -0 -75.9469 Td -(0305 int kill\(int\);) 135.4239 Tj -0 -85.4403 Td -(0306 void pinit\(void\);) 144.161 Tj -0 -94.9336 Td -(0307 void procdump\(void\);) 157.2665 Tj -0 -104.427 Td -(0308 void scheduler\(void\) __attribute__\(\(noretur\ -n\)\);) 275.2164 Tj -0 -113.9203 Td -(0309 void ksegment\(void\);) 157.2665 Tj -0 -123.4137 Td -(0310 void usegment\(void\);) 157.2665 Tj -0 -132.9071 Td -(0311 void sleep\(void*, struct spinlock*\);) 227.1628 Tj -0 -142.4004 Td -(0312 void userinit\(void\);) 157.2665 Tj -0 -151.8938 Td -(0313 int wait\(void\);) 139.7925 Tj -0 -161.3871 Td -(0314 void wakeup\(void*\);) 152.898 Tj -0 -170.8805 Td -(0315 void yield\(void\);) 144.161 Tj -0 -180.3739 Td -(0316 ) 21.8426 Tj -0 -189.8672 Td -(0317 // swtch.S) 65.5277 Tj -0 -199.3606 Td -(0318 void swtch\(struct context**, struct context*\)\ -;) 270.8479 Tj -0 -208.8539 Td -(0319 ) 21.8426 Tj -0 -218.3473 Td -(0320 // spinlock.c) 78.6333 Tj -0 -227.8407 Td -(0321 void acquire\(struct spinlock*\);) 205.3202 Tj -0 -237.334 Td -(0322 void getcallerpcs\(void*, uint*\);) 209.6887 Tj -0 -246.8274 Td -(0323 int holding\(struct spinlock*\);) 205.3202 Tj -0 -256.3207 Td -(0324 void initlock\(struct spinlock*, char*\);) 240.2683 Tj -0 -265.8141 Td -(0325 void release\(struct spinlock*\);) 205.3202 Tj -0 -275.3075 Td -(0326 void pushcli\(\);) 135.4239 Tj -0 -284.8008 Td -(0327 void popcli\(\);) 131.0554 Tj -0 -294.2942 Td -(0328 ) 21.8426 Tj -0 -303.7875 Td -(0329 // string.c) 69.8962 Tj -0 -313.2809 Td -(0330 int memcmp\(const void*, const void*, uint\);) 262.1109 Tj -0 -322.7743 Td -(0331 void* memmove\(void*, const void*, uint\);) 240.2683 Tj -0 -332.2676 Td -(0332 void* memset\(void*, int, uint\);) 200.9517 Tj -0 -341.761 Td -(0333 char* safestrcpy\(char*, const char*, int\);) 249.0053 Tj -0 -351.2543 Td -(0334 int strlen\(const char*\);) 179.1091 Tj -0 -360.7477 Td -(0335 int strncmp\(const char*, const char*, uint\);) 266.4794 Tj -0 -370.2411 Td -(0336 char* strncpy\(char*, const char*, int\);) 235.8998 Tj -0 -379.7344 Td -(0337 ) 21.8426 Tj -0 -389.2278 Td -(0338 // syscall.c) 74.2647 Tj -0 -398.7211 Td -(0339 int argint\(int, int*\);) 170.3721 Tj -0 -408.2145 Td -(0340 int argptr\(int, char**, int\);) 200.9517 Tj -0 -417.7079 Td -(0341 int argstr\(int, char**\);) 179.1091 Tj -0 -427.2012 Td -(0342 int fetchint\(struct proc*, uint, int*\);) 244.6368 Tj -0 -436.6946 Td -(0343 int fetchstr\(struct proc*, uint, char**\);) 253.3738 Tj -0 -446.1879 Td -(0344 void syscall\(void\);) 152.898 Tj -0 -455.6813 Td -(0345 ) 21.8426 Tj -0 -465.1747 Td -(0346 // timer.c) 65.5277 Tj -0 -474.668 Td -(0347 void timerinit\(void\);) 161.635 Tj -0 -484.1614 Td -(0348 ) 21.8426 Tj -0 -493.6547 Td -(0349 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 03) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/defs.h Page 4) 161.635 Tj -0 -28.4801 Td -(0350 // trap.c) 61.1592 Tj -0 -37.9735 Td -(0351 void idtinit\(void\);) 152.898 Tj -0 -47.4668 Td -(0352 extern int ticks;) 117.9499 Tj -0 -56.9602 Td -(0353 void tvinit\(void\);) 148.5295 Tj -0 -66.4535 Td -(0354 extern struct spinlock tickslock;) 166.0035 Tj -0 -75.9469 Td -(0355 ) 21.8426 Tj -0 -85.4403 Td -(0356 // uart.c) 61.1592 Tj -0 -94.9336 Td -(0357 void uartinit\(void\);) 157.2665 Tj -0 -104.427 Td -(0358 void uartintr\(void\);) 157.2665 Tj -0 -113.9203 Td -(0359 void uartputc\(int\);) 152.898 Tj -0 -123.4137 Td -(0360 ) 21.8426 Tj -0 -132.9071 Td -(0361 // number of elements in fixed-size array) 200.9517 Tj -0 -142.4004 Td -(0362 #define NELEM\(x\) \(sizeof\(x\)/sizeof\(\(x\)[0]\)\)) 209.6887 Tj -0 -151.8938 Td -(0363 ) 21.8426 Tj -0 -161.3871 Td -(0364 ) 21.8426 Tj -0 -170.8805 Td -(0365 ) 21.8426 Tj -0 -180.3739 Td -(0366 ) 21.8426 Tj -0 -189.8672 Td -(0367 ) 21.8426 Tj -0 -199.3606 Td -(0368 ) 21.8426 Tj -0 -208.8539 Td -(0369 ) 21.8426 Tj -0 -218.3473 Td -(0370 ) 21.8426 Tj -0 -227.8407 Td -(0371 ) 21.8426 Tj -0 -237.334 Td -(0372 ) 21.8426 Tj -0 -246.8274 Td -(0373 ) 21.8426 Tj -0 -256.3207 Td -(0374 ) 21.8426 Tj -0 -265.8141 Td -(0375 ) 21.8426 Tj -0 -275.3075 Td -(0376 ) 21.8426 Tj -0 -284.8008 Td -(0377 ) 21.8426 Tj -0 -294.2942 Td -(0378 ) 21.8426 Tj -0 -303.7875 Td -(0379 ) 21.8426 Tj -0 -313.2809 Td -(0380 ) 21.8426 Tj -0 -322.7743 Td -(0381 ) 21.8426 Tj -0 -332.2676 Td -(0382 ) 21.8426 Tj -0 -341.761 Td -(0383 ) 21.8426 Tj -0 -351.2543 Td -(0384 ) 21.8426 Tj -0 -360.7477 Td -(0385 ) 21.8426 Tj -0 -370.2411 Td -(0386 ) 21.8426 Tj -0 -379.7344 Td -(0387 ) 21.8426 Tj -0 -389.2278 Td -(0388 ) 21.8426 Tj -0 -398.7211 Td -(0389 ) 21.8426 Tj -0 -408.2145 Td -(0390 ) 21.8426 Tj -0 -417.7079 Td -(0391 ) 21.8426 Tj -0 -427.2012 Td -(0392 ) 21.8426 Tj -0 -436.6946 Td -(0393 ) 21.8426 Tj -0 -446.1879 Td -(0394 ) 21.8426 Tj -0 -455.6813 Td -(0395 ) 21.8426 Tj -0 -465.1747 Td -(0396 ) 21.8426 Tj -0 -474.668 Td -(0397 ) 21.8426 Tj -0 -484.1614 Td -(0398 ) 21.8426 Tj -0 -493.6547 Td -(0399 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 03) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 11 11 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/x86.h Page 1) 157.2665 Tj -0 -28.4801 Td -(0400 // Routines to let C code use special x86 instructions.) 262.1109 Tj -0 -37.9735 Td -(0401 ) 21.8426 Tj -0 -47.4668 Td -(0402 static inline uchar) 104.8443 Tj -0 -56.9602 Td -(0403 inb\(ushort port\)) 91.7388 Tj -0 -66.4535 Td -(0404 {) 26.2111 Tj -0 -75.9469 Td -(0405 uchar data;) 78.6333 Tj -0 -85.4403 Td -(0406 ) 21.8426 Tj -0 -94.9336 Td -(0407 asm volatile\("in %1,%0" : "=a" \(data\) : "d" \(port\)\)\ -;) 257.7424 Tj -0 -104.427 Td -(0408 return data;) 83.0018 Tj -0 -113.9203 Td -(0409 }) 26.2111 Tj -0 -123.4137 Td -(0410 ) 21.8426 Tj -0 -132.9071 Td -(0411 static inline void) 100.4758 Tj -0 -142.4004 Td -(0412 insl\(int port, void *addr, int cnt\)) 174.7406 Tj -0 -151.8938 Td -(0413 {) 26.2111 Tj -0 -161.3871 Td -(0414 asm volatile\("cld; rep insl" :) 161.635 Tj -0 -170.8805 Td -(0415 "=D" \(addr\), "=c" \(cnt\) :) 196.5831 Tj -0 -180.3739 Td -(0416 "d" \(port\), "0" \(addr\), "1" \(cnt\) :) 240.2683 Tj -0 -189.8672 Td -(0417 "memory", "cc"\);) 157.2665 Tj -0 -199.3606 Td -(0418 }) 26.2111 Tj -0 -208.8539 Td -(0419 ) 21.8426 Tj -0 -218.3473 Td -(0420 static inline void) 100.4758 Tj -0 -227.8407 Td -(0421 outb\(ushort port, uchar data\)) 148.5295 Tj -0 -237.334 Td -(0422 {) 26.2111 Tj -0 -246.8274 Td -(0423 asm volatile\("out %0,%1" : : "a" \(data\), "d" \(port\)\ -\);) 262.1109 Tj -0 -256.3207 Td -(0424 }) 26.2111 Tj -0 -265.8141 Td -(0425 ) 21.8426 Tj -0 -275.3075 Td -(0426 static inline void) 100.4758 Tj -0 -284.8008 Td -(0427 outw\(ushort port, ushort data\)) 152.898 Tj -0 -294.2942 Td -(0428 {) 26.2111 Tj -0 -303.7875 Td -(0429 asm volatile\("out %0,%1" : : "a" \(data\), "d" \(port\)\ -\);) 262.1109 Tj -0 -313.2809 Td -(0430 }) 26.2111 Tj -0 -322.7743 Td -(0431 ) 21.8426 Tj -0 -332.2676 Td -(0432 static inline void) 100.4758 Tj -0 -341.761 Td -(0433 outsl\(int port, const void *addr, int cnt\)) 205.3202 Tj -0 -351.2543 Td -(0434 {) 26.2111 Tj -0 -360.7477 Td -(0435 asm volatile\("cld; rep outsl" :) 166.0035 Tj -0 -370.2411 Td -(0436 "=S" \(addr\), "=c" \(cnt\) :) 196.5831 Tj -0 -379.7344 Td -(0437 "d" \(port\), "0" \(addr\), "1" \(cnt\) :) 240.2683 Tj -0 -389.2278 Td -(0438 "cc"\);) 113.5814 Tj -0 -398.7211 Td -(0439 }) 26.2111 Tj -0 -408.2145 Td -(0440 ) 21.8426 Tj -0 -417.7079 Td -(0441 static inline void) 100.4758 Tj -0 -427.2012 Td -(0442 stosb\(void *addr, int data, int cnt\)) 179.1091 Tj -0 -436.6946 Td -(0443 {) 26.2111 Tj -0 -446.1879 Td -(0444 asm volatile\("cld; rep stosb" :) 166.0035 Tj -0 -455.6813 Td -(0445 "=D" \(addr\), "=c" \(cnt\) :) 196.5831 Tj -0 -465.1747 Td -(0446 "0" \(addr\), "1" \(cnt\), "a" \(data\) :) 240.2683 Tj -0 -474.668 Td -(0447 "memory", "cc"\);) 157.2665 Tj -0 -484.1614 Td -(0448 }) 26.2111 Tj -0 -493.6547 Td -(0449 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 04) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/x86.h Page 2) 157.2665 Tj -0 -28.4801 Td -(0450 struct segdesc;) 87.3703 Tj -0 -37.9735 Td -(0451 ) 21.8426 Tj -0 -47.4668 Td -(0452 static inline void) 100.4758 Tj -0 -56.9602 Td -(0453 lgdt\(struct segdesc *p, int size\)) 166.0035 Tj -0 -66.4535 Td -(0454 {) 26.2111 Tj -0 -75.9469 Td -(0455 volatile ushort pd[3];) 126.6869 Tj -0 -85.4403 Td -(0456 ) 21.8426 Tj -0 -94.9336 Td -(0457 pd[0] = size-1;) 96.1073 Tj -0 -104.427 Td -(0458 pd[1] = \(uint\)p;) 100.4758 Tj -0 -113.9203 Td -(0459 pd[2] = \(uint\)p >> 16;) 126.6869 Tj -0 -123.4137 Td -(0460 ) 21.8426 Tj -0 -132.9071 Td -(0461 asm volatile\("lgdt \(%0\)" : : "r" \(pd\)\);) 200.9517 Tj -0 -142.4004 Td -(0462 }) 26.2111 Tj -0 -151.8938 Td -(0463 ) 21.8426 Tj -0 -161.3871 Td -(0464 struct gatedesc;) 91.7388 Tj -0 -170.8805 Td -(0465 ) 21.8426 Tj -0 -180.3739 Td -(0466 static inline void) 100.4758 Tj -0 -189.8672 Td -(0467 lidt\(struct gatedesc *p, int size\)) 170.3721 Tj -0 -199.3606 Td -(0468 {) 26.2111 Tj -0 -208.8539 Td -(0469 volatile ushort pd[3];) 126.6869 Tj -0 -218.3473 Td -(0470 ) 21.8426 Tj -0 -227.8407 Td -(0471 pd[0] = size-1;) 96.1073 Tj -0 -237.334 Td -(0472 pd[1] = \(uint\)p;) 100.4758 Tj -0 -246.8274 Td -(0473 pd[2] = \(uint\)p >> 16;) 126.6869 Tj -0 -256.3207 Td -(0474 ) 21.8426 Tj -0 -265.8141 Td -(0475 asm volatile\("lidt \(%0\)" : : "r" \(pd\)\);) 200.9517 Tj -0 -275.3075 Td -(0476 }) 26.2111 Tj -0 -284.8008 Td -(0477 ) 21.8426 Tj -0 -294.2942 Td -(0478 static inline void) 100.4758 Tj -0 -303.7875 Td -(0479 ltr\(ushort sel\)) 87.3703 Tj -0 -313.2809 Td -(0480 {) 26.2111 Tj -0 -322.7743 Td -(0481 asm volatile\("ltr %0" : : "r" \(sel\)\);) 192.2146 Tj -0 -332.2676 Td -(0482 }) 26.2111 Tj -0 -341.761 Td -(0483 ) 21.8426 Tj -0 -351.2543 Td -(0484 static inline uint) 100.4758 Tj -0 -360.7477 Td -(0485 readeflags\(void\)) 91.7388 Tj -0 -370.2411 Td -(0486 {) 26.2111 Tj -0 -379.7344 Td -(0487 uint eflags;) 83.0018 Tj -0 -389.2278 Td -(0488 asm volatile\("pushfl; popl %0" : "=r" \(eflags\)\);) 240.2683 Tj -0 -398.7211 Td -(0489 return eflags;) 91.7388 Tj -0 -408.2145 Td -(0490 }) 26.2111 Tj -0 -417.7079 Td -(0491 ) 21.8426 Tj -0 -427.2012 Td -(0492 ) 21.8426 Tj -0 -436.6946 Td -(0493 ) 21.8426 Tj -0 -446.1879 Td -(0494 ) 21.8426 Tj -0 -455.6813 Td -(0495 ) 21.8426 Tj -0 -465.1747 Td -(0496 ) 21.8426 Tj -0 -474.668 Td -(0497 ) 21.8426 Tj -0 -484.1614 Td -(0498 ) 21.8426 Tj -0 -493.6547 Td -(0499 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 04) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 12 12 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/x86.h Page 3) 157.2665 Tj -0 -28.4801 Td -(0500 static inline uint) 100.4758 Tj -0 -37.9735 Td -(0501 xchg\(volatile uint *addr, uint newval\)) 187.8461 Tj -0 -47.4668 Td -(0502 {) 26.2111 Tj -0 -56.9602 Td -(0503 uint result;) 83.0018 Tj -0 -66.4535 Td -(0504 ) 21.8426 Tj -0 -75.9469 Td -(0505 // The + in "+m" denotes a read-modify-write operand.) 262.1109 Tj -0 -85.4403 Td -(0506 asm volatile\("lock; xchgl %0, %1" :) 183.4776 Tj -0 -94.9336 Td -(0507 "+m" \(*addr\), "=a" \(result\) :) 214.0572 Tj -0 -104.427 Td -(0508 "1" \(newval\) :) 148.5295 Tj -0 -113.9203 Td -(0509 "cc"\);) 113.5814 Tj -0 -123.4137 Td -(0510 return result;) 91.7388 Tj -0 -132.9071 Td -(0511 }) 26.2111 Tj -0 -142.4004 Td -(0512 ) 21.8426 Tj -0 -151.8938 Td -(0513 static inline void) 100.4758 Tj -0 -161.3871 Td -(0514 loadgs\(ushort v\)) 91.7388 Tj -0 -170.8805 Td -(0515 {) 26.2111 Tj -0 -180.3739 Td -(0516 asm volatile\("movw %0, %%gs" : : "r" \(v\)\);) 214.0572 Tj -0 -189.8672 Td -(0517 }) 26.2111 Tj -0 -199.3606 Td -(0518 ) 21.8426 Tj -0 -208.8539 Td -(0519 static inline void) 100.4758 Tj -0 -218.3473 Td -(0520 cli\(void\)) 61.1592 Tj -0 -227.8407 Td -(0521 {) 26.2111 Tj -0 -237.334 Td -(0522 asm volatile\("cli"\);) 117.9499 Tj -0 -246.8274 Td -(0523 }) 26.2111 Tj -0 -256.3207 Td -(0524 ) 21.8426 Tj -0 -265.8141 Td -(0525 static inline void) 100.4758 Tj -0 -275.3075 Td -(0526 sti\(void\)) 61.1592 Tj -0 -284.8008 Td -(0527 {) 26.2111 Tj -0 -294.2942 Td -(0528 asm volatile\("sti"\);) 117.9499 Tj -0 -303.7875 Td -(0529 }) 26.2111 Tj -0 -313.2809 Td -(0530 ) 21.8426 Tj -0 -322.7743 Td -(0531 ) 21.8426 Tj -0 -332.2676 Td -(0532 ) 21.8426 Tj -0 -341.761 Td -(0533 ) 21.8426 Tj -0 -351.2543 Td -(0534 ) 21.8426 Tj -0 -360.7477 Td -(0535 ) 21.8426 Tj -0 -370.2411 Td -(0536 ) 21.8426 Tj -0 -379.7344 Td -(0537 ) 21.8426 Tj -0 -389.2278 Td -(0538 ) 21.8426 Tj -0 -398.7211 Td -(0539 ) 21.8426 Tj -0 -408.2145 Td -(0540 ) 21.8426 Tj -0 -417.7079 Td -(0541 ) 21.8426 Tj -0 -427.2012 Td -(0542 ) 21.8426 Tj -0 -436.6946 Td -(0543 ) 21.8426 Tj -0 -446.1879 Td -(0544 ) 21.8426 Tj -0 -455.6813 Td -(0545 ) 21.8426 Tj -0 -465.1747 Td -(0546 ) 21.8426 Tj -0 -474.668 Td -(0547 ) 21.8426 Tj -0 -484.1614 Td -(0548 ) 21.8426 Tj -0 -493.6547 Td -(0549 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 05) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/x86.h Page 4) 157.2665 Tj -0 -28.4801 Td -(0550 // Layout of the trap frame built on the stack by the) 253.3738 Tj -0 -37.9735 Td -(0551 // hardware and by trapasm.S, and passed to trap\(\).) 244.6368 Tj -0 -47.4668 Td -(0552 struct trapframe {) 100.4758 Tj -0 -56.9602 Td -(0553 // registers as pushed by pusha) 166.0035 Tj -0 -66.4535 Td -(0554 uint edi;) 69.8962 Tj -0 -75.9469 Td -(0555 uint esi;) 69.8962 Tj -0 -85.4403 Td -(0556 uint ebp;) 69.8962 Tj -0 -94.9336 Td -(0557 uint oesp; // useless & ignored) 187.8461 Tj -0 -104.427 Td -(0558 uint ebx;) 69.8962 Tj -0 -113.9203 Td -(0559 uint edx;) 69.8962 Tj -0 -123.4137 Td -(0560 uint ecx;) 69.8962 Tj -0 -132.9071 Td -(0561 uint eax;) 69.8962 Tj -0 -142.4004 Td -(0562 ) 21.8426 Tj -0 -151.8938 Td -(0563 // rest of trap frame) 122.3184 Tj -0 -161.3871 Td -(0564 ushort gs;) 74.2647 Tj -0 -170.8805 Td -(0565 ushort padding1;) 100.4758 Tj -0 -180.3739 Td -(0566 ushort fs;) 74.2647 Tj -0 -189.8672 Td -(0567 ushort padding2;) 100.4758 Tj -0 -199.3606 Td -(0568 ushort es;) 74.2647 Tj -0 -208.8539 Td -(0569 ushort padding3;) 100.4758 Tj -0 -218.3473 Td -(0570 ushort ds;) 74.2647 Tj -0 -227.8407 Td -(0571 ushort padding4;) 100.4758 Tj -0 -237.334 Td -(0572 uint trapno;) 83.0018 Tj -0 -246.8274 Td -(0573 ) 21.8426 Tj -0 -256.3207 Td -(0574 // below here defined by x86 hardware) 192.2146 Tj -0 -265.8141 Td -(0575 uint err;) 69.8962 Tj -0 -275.3075 Td -(0576 uint eip;) 69.8962 Tj -0 -284.8008 Td -(0577 ushort cs;) 74.2647 Tj -0 -294.2942 Td -(0578 ushort padding5;) 100.4758 Tj -0 -303.7875 Td -(0579 uint eflags;) 83.0018 Tj -0 -313.2809 Td -(0580 ) 21.8426 Tj -0 -322.7743 Td -(0581 // below here only when crossing rings, such as from use\ -r to kernel) 323.2701 Tj -0 -332.2676 Td -(0582 uint esp;) 69.8962 Tj -0 -341.761 Td -(0583 ushort ss;) 74.2647 Tj -0 -351.2543 Td -(0584 ushort padding6;) 100.4758 Tj -0 -360.7477 Td -(0585 };) 30.5796 Tj -0 -370.2411 Td -(0586 ) 21.8426 Tj -0 -379.7344 Td -(0587 ) 21.8426 Tj -0 -389.2278 Td -(0588 ) 21.8426 Tj -0 -398.7211 Td -(0589 ) 21.8426 Tj -0 -408.2145 Td -(0590 ) 21.8426 Tj -0 -417.7079 Td -(0591 ) 21.8426 Tj -0 -427.2012 Td -(0592 ) 21.8426 Tj -0 -436.6946 Td -(0593 ) 21.8426 Tj -0 -446.1879 Td -(0594 ) 21.8426 Tj -0 -455.6813 Td -(0595 ) 21.8426 Tj -0 -465.1747 Td -(0596 ) 21.8426 Tj -0 -474.668 Td -(0597 ) 21.8426 Tj -0 -484.1614 Td -(0598 ) 21.8426 Tj -0 -493.6547 Td -(0599 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 05) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 13 13 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/asm.h Page 1) 157.2665 Tj -0 -28.4801 Td -(0600 //) 30.5796 Tj -0 -37.9735 Td -(0601 // assembler macros to create x86 segments) 205.3202 Tj -0 -47.4668 Td -(0602 //) 30.5796 Tj -0 -56.9602 Td -(0603 ) 21.8426 Tj -0 -66.4535 Td -(0604 #define SEG_NULLASM \ - \\) 305.796 Tj -0 -75.9469 Td -(0605 .word 0, 0; \ - \\) 305.796 Tj -0 -85.4403 Td -(0606 .byte 0, 0, 0, 0) 126.6869 Tj -0 -94.9336 Td -(0607 ) 21.8426 Tj -0 -104.427 Td -(0608 #define SEG_ASM\(type,base,lim\) \ - \\) 305.796 Tj -0 -113.9203 Td -(0609 .word \(\(\(lim\) >> 12\) & 0xffff\), \(\(base\) &\ - 0xffff\); \\) 305.796 Tj -0 -123.4137 Td -(0610 .byte \(\(\(base\) >> 16\) & 0xff\), \(0x90 | \(ty\ -pe\)\), \\) 305.796 Tj -0 -132.9071 Td -(0611 \(0xC0 | \(\(\(lim\) >> 28\) & 0xf\)\), \(\ -\(\(base\) >> 24\) & 0xff\)) 332.0071 Tj -0 -142.4004 Td -(0612 ) 21.8426 Tj -0 -151.8938 Td -(0613 #define STA_X 0x8 // Executable segment) 235.8998 Tj -0 -161.3871 Td -(0614 #define STA_E 0x4 // Expand down \(non-executabl\ -e segments\)) 318.9016 Tj -0 -170.8805 Td -(0615 #define STA_C 0x4 // Conforming code segment \(e\ -xecutable only\)) 336.3756 Tj -0 -180.3739 Td -(0616 #define STA_W 0x2 // Writeable \(non-executable \ -segments\)) 310.1645 Tj -0 -189.8672 Td -(0617 #define STA_R 0x2 // Readable \(executable segme\ -nts\)) 288.322 Tj -0 -199.3606 Td -(0618 #define STA_A 0x1 // Accessed) 192.2146 Tj -0 -208.8539 Td -(0619 ) 21.8426 Tj -0 -218.3473 Td -(0620 ) 21.8426 Tj -0 -227.8407 Td -(0621 ) 21.8426 Tj -0 -237.334 Td -(0622 ) 21.8426 Tj -0 -246.8274 Td -(0623 ) 21.8426 Tj -0 -256.3207 Td -(0624 ) 21.8426 Tj -0 -265.8141 Td -(0625 ) 21.8426 Tj -0 -275.3075 Td -(0626 ) 21.8426 Tj -0 -284.8008 Td -(0627 ) 21.8426 Tj -0 -294.2942 Td -(0628 ) 21.8426 Tj -0 -303.7875 Td -(0629 ) 21.8426 Tj -0 -313.2809 Td -(0630 ) 21.8426 Tj -0 -322.7743 Td -(0631 ) 21.8426 Tj -0 -332.2676 Td -(0632 ) 21.8426 Tj -0 -341.761 Td -(0633 ) 21.8426 Tj -0 -351.2543 Td -(0634 ) 21.8426 Tj -0 -360.7477 Td -(0635 ) 21.8426 Tj -0 -370.2411 Td -(0636 ) 21.8426 Tj -0 -379.7344 Td -(0637 ) 21.8426 Tj -0 -389.2278 Td -(0638 ) 21.8426 Tj -0 -398.7211 Td -(0639 ) 21.8426 Tj -0 -408.2145 Td -(0640 ) 21.8426 Tj -0 -417.7079 Td -(0641 ) 21.8426 Tj -0 -427.2012 Td -(0642 ) 21.8426 Tj -0 -436.6946 Td -(0643 ) 21.8426 Tj -0 -446.1879 Td -(0644 ) 21.8426 Tj -0 -455.6813 Td -(0645 ) 21.8426 Tj -0 -465.1747 Td -(0646 ) 21.8426 Tj -0 -474.668 Td -(0647 ) 21.8426 Tj -0 -484.1614 Td -(0648 ) 21.8426 Tj -0 -493.6547 Td -(0649 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 06) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/mmu.h Page 1) 157.2665 Tj -0 -28.4801 Td -(0650 // This file contains definitions for the) 200.9517 Tj -0 -37.9735 Td -(0651 // x86 memory management unit \(MMU\).) 179.1091 Tj -0 -47.4668 Td -(0652 ) 21.8426 Tj -0 -56.9602 Td -(0653 // Eflags register) 100.4758 Tj -0 -66.4535 Td -(0654 #define FL_CF 0x00000001 // Carry Flag) 253.3738 Tj -0 -75.9469 Td -(0655 #define FL_PF 0x00000004 // Parity Flag) 257.7424 Tj -0 -85.4403 Td -(0656 #define FL_AF 0x00000010 // Auxiliary carry\ - Flag) 297.059 Tj -0 -94.9336 Td -(0657 #define FL_ZF 0x00000040 // Zero Flag) 249.0053 Tj -0 -104.427 Td -(0658 #define FL_SF 0x00000080 // Sign Flag) 249.0053 Tj -0 -113.9203 Td -(0659 #define FL_TF 0x00000100 // Trap Flag) 249.0053 Tj -0 -123.4137 Td -(0660 #define FL_IF 0x00000200 // Interrupt Enabl\ -e) 279.5849 Tj -0 -132.9071 Td -(0661 #define FL_DF 0x00000400 // Direction Flag) 270.8479 Tj -0 -142.4004 Td -(0662 #define FL_OF 0x00000800 // Overflow Flag) 266.4794 Tj -0 -151.8938 Td -(0663 #define FL_IOPL_MASK 0x00003000 // I/O Privilege L\ -evel bitmask) 327.6386 Tj -0 -161.3871 Td -(0664 #define FL_IOPL_0 0x00000000 // IOPL == 0) 257.7424 Tj -0 -170.8805 Td -(0665 #define FL_IOPL_1 0x00001000 // IOPL == 1) 257.7424 Tj -0 -180.3739 Td -(0666 #define FL_IOPL_2 0x00002000 // IOPL == 2) 257.7424 Tj -0 -189.8672 Td -(0667 #define FL_IOPL_3 0x00003000 // IOPL == 3) 257.7424 Tj -0 -199.3606 Td -(0668 #define FL_NT 0x00004000 // Nested Task) 257.7424 Tj -0 -208.8539 Td -(0669 #define FL_RF 0x00010000 // Resume Flag) 257.7424 Tj -0 -218.3473 Td -(0670 #define FL_VM 0x00020000 // Virtual 8086 mo\ -de) 283.9534 Tj -0 -227.8407 Td -(0671 #define FL_AC 0x00040000 // Alignment Check) 275.2164 Tj -0 -237.334 Td -(0672 #define FL_VIF 0x00080000 // Virtual Interru\ -pt Flag) 305.796 Tj -0 -246.8274 Td -(0673 #define FL_VIP 0x00100000 // Virtual Interru\ -pt Pending) 318.9016 Tj -0 -256.3207 Td -(0674 #define FL_ID 0x00200000 // ID flag) 240.2683 Tj -0 -265.8141 Td -(0675 ) 21.8426 Tj -0 -275.3075 Td -(0676 // Segment Descriptor) 113.5814 Tj -0 -284.8008 Td -(0677 struct segdesc {) 91.7388 Tj -0 -294.2942 Td -(0678 uint lim_15_0 : 16; // Low bits of segment limit) 244.6368 Tj -0 -303.7875 Td -(0679 uint base_15_0 : 16; // Low bits of segment base address) 275.2164 Tj -0 -313.2809 Td -(0680 uint base_23_16 : 8; // Middle bits of segment base addr\ -ess) 288.322 Tj -0 -322.7743 Td -(0681 uint type : 4; // Segment type \(see STS_ constant\ -s\)) 279.5849 Tj -0 -332.2676 Td -(0682 uint s : 1; // 0 = system, 1 = application) 253.3738 Tj -0 -341.761 Td -(0683 uint dpl : 2; // Descriptor Privilege Level) 249.0053 Tj -0 -351.2543 Td -(0684 uint p : 1; // Present) 166.0035 Tj -0 -360.7477 Td -(0685 uint lim_19_16 : 4; // High bits of segment limit) 249.0053 Tj -0 -370.2411 Td -(0686 uint avl : 1; // Unused \(available for software \ -use\)) 288.322 Tj -0 -379.7344 Td -(0687 uint rsv1 : 1; // Reserved) 170.3721 Tj -0 -389.2278 Td -(0688 uint db : 1; // 0 = 16-bit segment, 1 = 32-bit s\ -egment) 301.4275 Tj -0 -398.7211 Td -(0689 uint g : 1; // Granularity: limit scaled by 4K \ -when set) 310.1645 Tj -0 -408.2145 Td -(0690 uint base_31_24 : 8; // High bits of segment base addres\ -s) 279.5849 Tj -0 -417.7079 Td -(0691 };) 30.5796 Tj -0 -427.2012 Td -(0692 ) 21.8426 Tj -0 -436.6946 Td -(0693 ) 21.8426 Tj -0 -446.1879 Td -(0694 ) 21.8426 Tj -0 -455.6813 Td -(0695 ) 21.8426 Tj -0 -465.1747 Td -(0696 ) 21.8426 Tj -0 -474.668 Td -(0697 ) 21.8426 Tj -0 -484.1614 Td -(0698 ) 21.8426 Tj -0 -493.6547 Td -(0699 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 06) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 14 14 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/mmu.h Page 2) 157.2665 Tj -0 -28.4801 Td -(0700 // Normal segment) 96.1073 Tj -0 -37.9735 Td -(0701 #define SEG\(type, base, lim, dpl\) \(struct segdesc\) \ -\\) 262.1109 Tj -0 -47.4668 Td -(0702 { \(\(lim\) >> 12\) & 0xffff, \(uint\)\(base\) & 0xffff, \ - \\) 262.1109 Tj -0 -56.9602 Td -(0703 \(\(uint\)\(base\) >> 16\) & 0xff, type, 1, dpl, 1, \ - \\) 262.1109 Tj -0 -66.4535 Td -(0704 \(uint\)\(lim\) >> 28, 0, 0, 1, 1, \(uint\)\(base\) >> 2\ -4 }) 253.3738 Tj -0 -75.9469 Td -(0705 ) 21.8426 Tj -0 -85.4403 Td -(0706 #define SEG16\(type, base, lim, dpl\) \(struct segdesc\) \ -\\) 262.1109 Tj -0 -94.9336 Td -(0707 { \(lim\) & 0xffff, \(uint\)\(base\) & 0xffff, \ - \\) 262.1109 Tj -0 -104.427 Td -(0708 \(\(uint\)\(base\) >> 16\) & 0xff, type, 1, dpl, 1, \ - \\) 262.1109 Tj -0 -113.9203 Td -(0709 \(uint\)\(lim\) >> 16, 0, 0, 1, 0, \(uint\)\(base\) >> 2\ -4 }) 253.3738 Tj -0 -123.4137 Td -(0710 ) 21.8426 Tj -0 -132.9071 Td -(0711 #define DPL_USER 0x3 // User DPL) 192.2146 Tj -0 -142.4004 Td -(0712 ) 21.8426 Tj -0 -151.8938 Td -(0713 // Application segment type bits) 161.635 Tj -0 -161.3871 Td -(0714 #define STA_X 0x8 // Executable segment) 235.8998 Tj -0 -170.8805 Td -(0715 #define STA_E 0x4 // Expand down \(non-executabl\ -e segments\)) 318.9016 Tj -0 -180.3739 Td -(0716 #define STA_C 0x4 // Conforming code segment \(e\ -xecutable only\)) 336.3756 Tj -0 -189.8672 Td -(0717 #define STA_W 0x2 // Writeable \(non-executable \ -segments\)) 310.1645 Tj -0 -199.3606 Td -(0718 #define STA_R 0x2 // Readable \(executable segme\ -nts\)) 288.322 Tj -0 -208.8539 Td -(0719 #define STA_A 0x1 // Accessed) 192.2146 Tj -0 -218.3473 Td -(0720 ) 21.8426 Tj -0 -227.8407 Td -(0721 // System segment type bits) 139.7925 Tj -0 -237.334 Td -(0722 #define STS_T16A 0x1 // Available 16-bit TSS) 244.6368 Tj -0 -246.8274 Td -(0723 #define STS_LDT 0x2 // Local Descriptor Table) 253.3738 Tj -0 -256.3207 Td -(0724 #define STS_T16B 0x3 // Busy 16-bit TSS) 222.7942 Tj -0 -265.8141 Td -(0725 #define STS_CG16 0x4 // 16-bit Call Gate) 227.1628 Tj -0 -275.3075 Td -(0726 #define STS_TG 0x5 // Task Gate / Coum Transmitio\ -ns) 283.9534 Tj -0 -284.8008 Td -(0727 #define STS_IG16 0x6 // 16-bit Interrupt Gate) 249.0053 Tj -0 -294.2942 Td -(0728 #define STS_TG16 0x7 // 16-bit Trap Gate) 227.1628 Tj -0 -303.7875 Td -(0729 #define STS_T32A 0x9 // Available 32-bit TSS) 244.6368 Tj -0 -313.2809 Td -(0730 #define STS_T32B 0xB // Busy 32-bit TSS) 222.7942 Tj -0 -322.7743 Td -(0731 #define STS_CG32 0xC // 32-bit Call Gate) 227.1628 Tj -0 -332.2676 Td -(0732 #define STS_IG32 0xE // 32-bit Interrupt Gate) 249.0053 Tj -0 -341.761 Td -(0733 #define STS_TG32 0xF // 32-bit Trap Gate) 227.1628 Tj -0 -351.2543 Td -(0734 ) 21.8426 Tj -0 -360.7477 Td -(0735 ) 21.8426 Tj -0 -370.2411 Td -(0736 ) 21.8426 Tj -0 -379.7344 Td -(0737 ) 21.8426 Tj -0 -389.2278 Td -(0738 ) 21.8426 Tj -0 -398.7211 Td -(0739 ) 21.8426 Tj -0 -408.2145 Td -(0740 ) 21.8426 Tj -0 -417.7079 Td -(0741 ) 21.8426 Tj -0 -427.2012 Td -(0742 ) 21.8426 Tj -0 -436.6946 Td -(0743 ) 21.8426 Tj -0 -446.1879 Td -(0744 ) 21.8426 Tj -0 -455.6813 Td -(0745 ) 21.8426 Tj -0 -465.1747 Td -(0746 ) 21.8426 Tj -0 -474.668 Td -(0747 ) 21.8426 Tj -0 -484.1614 Td -(0748 ) 21.8426 Tj -0 -493.6547 Td -(0749 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 07) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/mmu.h Page 3) 157.2665 Tj -0 -28.4801 Td -(0750 // Task state segment format) 144.161 Tj -0 -37.9735 Td -(0751 struct taskstate {) 100.4758 Tj -0 -47.4668 Td -(0752 uint link; // Old ts selector) 192.2146 Tj -0 -56.9602 Td -(0753 uint esp0; // Stack pointers and segment selecto\ -rs) 283.9534 Tj -0 -66.4535 Td -(0754 ushort ss0; // after an increase in privilege l\ -evel) 292.6905 Tj -0 -75.9469 Td -(0755 ushort padding1;) 100.4758 Tj -0 -85.4403 Td -(0756 uint *esp1;) 78.6333 Tj -0 -94.9336 Td -(0757 ushort ss1;) 78.6333 Tj -0 -104.427 Td -(0758 ushort padding2;) 100.4758 Tj -0 -113.9203 Td -(0759 uint *esp2;) 78.6333 Tj -0 -123.4137 Td -(0760 ushort ss2;) 78.6333 Tj -0 -132.9071 Td -(0761 ushort padding3;) 100.4758 Tj -0 -142.4004 Td -(0762 void *cr3; // Page directory base) 209.6887 Tj -0 -151.8938 Td -(0763 uint *eip; // Saved state from last task switch) 270.8479 Tj -0 -161.3871 Td -(0764 uint eflags;) 83.0018 Tj -0 -170.8805 Td -(0765 uint eax; // More saved state \(registers\)) 249.0053 Tj -0 -180.3739 Td -(0766 uint ecx;) 69.8962 Tj -0 -189.8672 Td -(0767 uint edx;) 69.8962 Tj -0 -199.3606 Td -(0768 uint ebx;) 69.8962 Tj -0 -208.8539 Td -(0769 uint *esp;) 74.2647 Tj -0 -218.3473 Td -(0770 uint *ebp;) 74.2647 Tj -0 -227.8407 Td -(0771 uint esi;) 69.8962 Tj -0 -237.334 Td -(0772 uint edi;) 69.8962 Tj -0 -246.8274 Td -(0773 ushort es; // Even more saved state \(segment se\ -lectors\)) 305.796 Tj -0 -256.3207 Td -(0774 ushort padding4;) 100.4758 Tj -0 -265.8141 Td -(0775 ushort cs;) 74.2647 Tj -0 -275.3075 Td -(0776 ushort padding5;) 100.4758 Tj -0 -284.8008 Td -(0777 ushort ss;) 74.2647 Tj -0 -294.2942 Td -(0778 ushort padding6;) 100.4758 Tj -0 -303.7875 Td -(0779 ushort ds;) 74.2647 Tj -0 -313.2809 Td -(0780 ushort padding7;) 100.4758 Tj -0 -322.7743 Td -(0781 ushort fs;) 74.2647 Tj -0 -332.2676 Td -(0782 ushort padding8;) 100.4758 Tj -0 -341.761 Td -(0783 ushort gs;) 74.2647 Tj -0 -351.2543 Td -(0784 ushort padding9;) 100.4758 Tj -0 -360.7477 Td -(0785 ushort ldt;) 78.6333 Tj -0 -370.2411 Td -(0786 ushort padding10;) 104.8443 Tj -0 -379.7344 Td -(0787 ushort t; // Trap on task switch) 209.6887 Tj -0 -389.2278 Td -(0788 ushort iomb; // I/O map base address) 214.0572 Tj -0 -398.7211 Td -(0789 };) 30.5796 Tj -0 -408.2145 Td -(0790 ) 21.8426 Tj -0 -417.7079 Td -(0791 ) 21.8426 Tj -0 -427.2012 Td -(0792 ) 21.8426 Tj -0 -436.6946 Td -(0793 ) 21.8426 Tj -0 -446.1879 Td -(0794 ) 21.8426 Tj -0 -455.6813 Td -(0795 ) 21.8426 Tj -0 -465.1747 Td -(0796 ) 21.8426 Tj -0 -474.668 Td -(0797 ) 21.8426 Tj -0 -484.1614 Td -(0798 ) 21.8426 Tj -0 -493.6547 Td -(0799 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 07) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 15 15 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/mmu.h Page 4) 157.2665 Tj -0 -28.4801 Td -(0800 // Gate descriptors for interrupts and traps) 214.0572 Tj -0 -37.9735 Td -(0801 struct gatedesc {) 96.1073 Tj -0 -47.4668 Td -(0802 uint off_15_0 : 16; // low 16 bits of offset in segmen\ -t) 279.5849 Tj -0 -56.9602 Td -(0803 uint cs : 16; // code segment selector) 231.5313 Tj -0 -66.4535 Td -(0804 uint args : 5; // # args, 0 for interrupt/trap ga\ -tes) 288.322 Tj -0 -75.9469 Td -(0805 uint rsv1 : 3; // reserved\(should be zero I gues\ -s\)) 279.5849 Tj -0 -85.4403 Td -(0806 uint type : 4; // type\(STS_{TG,IG32,TG32}\)) 244.6368 Tj -0 -94.9336 Td -(0807 uint s : 1; // must be 0 \(system\)) 218.4257 Tj -0 -104.427 Td -(0808 uint dpl : 2; // descriptor\(meaning new\) privi\ -lege level) 310.1645 Tj -0 -113.9203 Td -(0809 uint p : 1; // Present) 170.3721 Tj -0 -123.4137 Td -(0810 uint off_31_16 : 16; // high bits of offset in segment) 270.8479 Tj -0 -132.9071 Td -(0811 };) 30.5796 Tj -0 -142.4004 Td -(0812 ) 21.8426 Tj -0 -151.8938 Td -(0813 // Set up a normal interrupt/trap gate descriptor.) 240.2683 Tj -0 -161.3871 Td -(0814 // - istrap: 1 for a trap \(= exception\) gate, 0 for an i\ -nterrupt gate.) 327.6386 Tj -0 -170.8805 Td -(0815 // interrupt gate clears FL_IF, trap gate leaves FL_IF a\ -lone) 292.6905 Tj -0 -180.3739 Td -(0816 // - sel: Code segment selector for interrupt/trap handler) 275.2164 Tj -0 -189.8672 Td -(0817 // - off: Offset in code segment for interrupt/trap handle\ -r) 279.5849 Tj -0 -199.3606 Td -(0818 // - dpl: Descriptor Privilege Level -) 187.8461 Tj -0 -208.8539 Td -(0819 // the privilege level required for software to inv\ -oke) 288.322 Tj -0 -218.3473 Td -(0820 // this interrupt/trap gate explicitly using an int\ - instruction.) 332.0071 Tj -0 -227.8407 Td -(0821 #define SETGATE\(gate, istrap, sel, off, d\) \ - \\) 279.5849 Tj -0 -237.334 Td -(0822 { \ -\\) 279.5849 Tj -0 -246.8274 Td -(0823 \(gate\).off_15_0 = \(uint\) \(off\) & 0xffff; \ - \\) 279.5849 Tj -0 -256.3207 Td -(0824 \(gate\).cs = \(sel\); \ - \\) 279.5849 Tj -0 -265.8141 Td -(0825 \(gate\).args = 0; \ - \\) 279.5849 Tj -0 -275.3075 Td -(0826 \(gate\).rsv1 = 0; \ - \\) 279.5849 Tj -0 -284.8008 Td -(0827 \(gate\).type = \(istrap\) ? STS_TG32 : STS_IG32; \ - \\) 279.5849 Tj -0 -294.2942 Td -(0828 \(gate\).s = 0; \ - \\) 279.5849 Tj -0 -303.7875 Td -(0829 \(gate\).dpl = \(d\); \ - \\) 279.5849 Tj -0 -313.2809 Td -(0830 \(gate\).p = 1; \ - \\) 279.5849 Tj -0 -322.7743 Td -(0831 \(gate\).off_31_16 = \(uint\) \(off\) >> 16; \ - \\) 279.5849 Tj -0 -332.2676 Td -(0832 }) 26.2111 Tj -0 -341.761 Td -(0833 ) 21.8426 Tj -0 -351.2543 Td -(0834 ) 21.8426 Tj -0 -360.7477 Td -(0835 ) 21.8426 Tj -0 -370.2411 Td -(0836 ) 21.8426 Tj -0 -379.7344 Td -(0837 ) 21.8426 Tj -0 -389.2278 Td -(0838 ) 21.8426 Tj -0 -398.7211 Td -(0839 ) 21.8426 Tj -0 -408.2145 Td -(0840 ) 21.8426 Tj -0 -417.7079 Td -(0841 ) 21.8426 Tj -0 -427.2012 Td -(0842 ) 21.8426 Tj -0 -436.6946 Td -(0843 ) 21.8426 Tj -0 -446.1879 Td -(0844 ) 21.8426 Tj -0 -455.6813 Td -(0845 ) 21.8426 Tj -0 -465.1747 Td -(0846 ) 21.8426 Tj -0 -474.668 Td -(0847 ) 21.8426 Tj -0 -484.1614 Td -(0848 ) 21.8426 Tj -0 -493.6547 Td -(0849 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 08) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/elf.h Page 1) 157.2665 Tj -0 -28.4801 Td -(0850 // Format of an ELF executable file) 174.7406 Tj -0 -37.9735 Td -(0851 ) 21.8426 Tj -0 -47.4668 Td -(0852 #define ELF_MAGIC 0x464C457FU // "\\x7FELF" in little end\ -ian) 283.9534 Tj -0 -56.9602 Td -(0853 ) 21.8426 Tj -0 -66.4535 Td -(0854 // File header) 83.0018 Tj -0 -75.9469 Td -(0855 struct elfhdr {) 87.3703 Tj -0 -85.4403 Td -(0856 uint magic; // must equal ELF_MAGIC) 187.8461 Tj -0 -94.9336 Td -(0857 uchar elf[12];) 91.7388 Tj -0 -104.427 Td -(0858 ushort type;) 83.0018 Tj -0 -113.9203 Td -(0859 ushort machine;) 96.1073 Tj -0 -123.4137 Td -(0860 uint version;) 87.3703 Tj -0 -132.9071 Td -(0861 uint entry;) 78.6333 Tj -0 -142.4004 Td -(0862 uint phoff;) 78.6333 Tj -0 -151.8938 Td -(0863 uint shoff;) 78.6333 Tj -0 -161.3871 Td -(0864 uint flags;) 78.6333 Tj -0 -170.8805 Td -(0865 ushort ehsize;) 91.7388 Tj -0 -180.3739 Td -(0866 ushort phentsize;) 104.8443 Tj -0 -189.8672 Td -(0867 ushort phnum;) 87.3703 Tj -0 -199.3606 Td -(0868 ushort shentsize;) 104.8443 Tj -0 -208.8539 Td -(0869 ushort shnum;) 87.3703 Tj -0 -218.3473 Td -(0870 ushort shstrndx;) 100.4758 Tj -0 -227.8407 Td -(0871 };) 30.5796 Tj -0 -237.334 Td -(0872 ) 21.8426 Tj -0 -246.8274 Td -(0873 // Program section header) 131.0554 Tj -0 -256.3207 Td -(0874 struct proghdr {) 91.7388 Tj -0 -265.8141 Td -(0875 uint type;) 74.2647 Tj -0 -275.3075 Td -(0876 uint offset;) 83.0018 Tj -0 -284.8008 Td -(0877 uint va;) 65.5277 Tj -0 -294.2942 Td -(0878 uint pa;) 65.5277 Tj -0 -303.7875 Td -(0879 uint filesz;) 83.0018 Tj -0 -313.2809 Td -(0880 uint memsz;) 78.6333 Tj -0 -322.7743 Td -(0881 uint flags;) 78.6333 Tj -0 -332.2676 Td -(0882 uint align;) 78.6333 Tj -0 -341.761 Td -(0883 };) 30.5796 Tj -0 -351.2543 Td -(0884 ) 21.8426 Tj -0 -360.7477 Td -(0885 // Values for Proghdr type) 135.4239 Tj -0 -370.2411 Td -(0886 #define ELF_PROG_LOAD 1) 166.0035 Tj -0 -379.7344 Td -(0887 ) 21.8426 Tj -0 -389.2278 Td -(0888 // Flag bits for Proghdr flags) 152.898 Tj -0 -398.7211 Td -(0889 #define ELF_PROG_FLAG_EXEC 1) 166.0035 Tj -0 -408.2145 Td -(0890 #define ELF_PROG_FLAG_WRITE 2) 166.0035 Tj -0 -417.7079 Td -(0891 #define ELF_PROG_FLAG_READ 4) 166.0035 Tj -0 -427.2012 Td -(0892 ) 21.8426 Tj -0 -436.6946 Td -(0893 ) 21.8426 Tj -0 -446.1879 Td -(0894 ) 21.8426 Tj -0 -455.6813 Td -(0895 ) 21.8426 Tj -0 -465.1747 Td -(0896 ) 21.8426 Tj -0 -474.668 Td -(0897 ) 21.8426 Tj -0 -484.1614 Td -(0898 ) 21.8426 Tj -0 -493.6547 Td -(0899 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 08) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 16 16 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/bootasm.S Page 1) 174.7406 Tj -0 -28.4801 Td -(0900 #include "asm.h") 91.7388 Tj -0 -37.9735 Td -(0901 ) 21.8426 Tj -0 -47.4668 Td -(0902 # Start the first CPU: switch to 32-bit protected mode, ju\ -mp into C.) 318.9016 Tj -0 -56.9602 Td -(0903 # The BIOS loads this code from the first sector of the ha\ -rd disk into) 327.6386 Tj -0 -66.4535 Td -(0904 # memory at physical address 0x7c00 and starts executing i\ -n real mode) 323.2701 Tj -0 -75.9469 Td -(0905 # with %cs=0 %ip=7c00.) 117.9499 Tj -0 -85.4403 Td -(0906 ) 21.8426 Tj -0 -94.9336 Td -(0907 #define SEG_KCODE 1 // kernel code) 174.7406 Tj -0 -104.427 Td -(0908 #define SEG_KDATA 2 // kernel data+stack) 200.9517 Tj -0 -113.9203 Td -(0909 ) 21.8426 Tj -0 -123.4137 Td -(0910 #define CR0_PE 1 // protected mode enable bit) 235.8998 Tj -0 -132.9071 Td -(0911 ) 21.8426 Tj -0 -142.4004 Td -(0912 .code16 # Assemble for 16-bit mode) 266.4794 Tj -0 -151.8938 Td -(0913 .globl start) 74.2647 Tj -0 -161.3871 Td -(0914 start:) 48.0537 Tj -0 -170.8805 Td -(0915 cli # Disable interrupts) 240.2683 Tj -0 -180.3739 Td -(0916 ) 21.8426 Tj -0 -189.8672 Td -(0917 # Set up the important data segment registers \(DS, ES, \ -SS\).) 288.322 Tj -0 -199.3606 Td -(0918 xorw %ax,%ax # Segment number zero) 244.6368 Tj -0 -208.8539 Td -(0919 movw %ax,%ds # -> Data Segment) 227.1628 Tj -0 -218.3473 Td -(0920 movw %ax,%es # -> Extra Segment) 231.5313 Tj -0 -227.8407 Td -(0921 movw %ax,%ss # -> Stack Segment) 231.5313 Tj -0 -237.334 Td -(0922 ) 21.8426 Tj -0 -246.8274 Td -(0923 # Enable A20:) 87.3703 Tj -0 -256.3207 Td -(0924 # For backwards compatibility with the earliest PCs, p\ -hysical) 305.796 Tj -0 -265.8141 Td -(0925 # address line 20 is tied low, so that addresses highe\ -r than) 301.4275 Tj -0 -275.3075 Td -(0926 # 1MB wrap around to zero by default. This code undoe\ -s this.) 305.796 Tj -0 -284.8008 Td -(0927 seta20.1:) 61.1592 Tj -0 -294.2942 Td -(0928 inb $0x64,%al # Wait for not busy) 253.3738 Tj -0 -303.7875 Td -(0929 testb $0x2,%al) 100.4758 Tj -0 -313.2809 Td -(0930 jnz seta20.1) 100.4758 Tj -0 -322.7743 Td -(0931 ) 21.8426 Tj -0 -332.2676 Td -(0932 movb $0xd1,%al # 0xd1 -> port 0x64) 253.3738 Tj -0 -341.761 Td -(0933 outb %al,$0x64) 104.8443 Tj -0 -351.2543 Td -(0934 ) 21.8426 Tj -0 -360.7477 Td -(0935 seta20.2:) 61.1592 Tj -0 -370.2411 Td -(0936 inb $0x64,%al # Wait for not busy) 253.3738 Tj -0 -379.7344 Td -(0937 testb $0x2,%al) 100.4758 Tj -0 -389.2278 Td -(0938 jnz seta20.2) 100.4758 Tj -0 -398.7211 Td -(0939 ) 21.8426 Tj -0 -408.2145 Td -(0940 movb $0xdf,%al # 0xdf -> port 0x60) 253.3738 Tj -0 -417.7079 Td -(0941 outb %al,$0x60) 104.8443 Tj -0 -427.2012 Td -(0942 ) 21.8426 Tj -0 -436.6946 Td -(0943 ) 21.8426 Tj -0 -446.1879 Td -(0944 ) 21.8426 Tj -0 -455.6813 Td -(0945 ) 21.8426 Tj -0 -465.1747 Td -(0946 ) 21.8426 Tj -0 -474.668 Td -(0947 ) 21.8426 Tj -0 -484.1614 Td -(0948 ) 21.8426 Tj -0 -493.6547 Td -(0949 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 09) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/bootasm.S Page 2) 174.7406 Tj -0 -28.4801 Td -(0950 # Switch from real to protected mode, using a bootstrap \ -GDT) 288.322 Tj -0 -37.9735 Td -(0951 # and segment translation that makes virtual addresses) 266.4794 Tj -0 -47.4668 Td -(0952 # identical to physical addresses, so that the) 231.5313 Tj -0 -56.9602 Td -(0953 # effective memory map does not change during the switch\ -.) 279.5849 Tj -0 -66.4535 Td -(0954 lgdt gdtdesc) 96.1073 Tj -0 -75.9469 Td -(0955 movl %cr0, %eax) 109.2129 Tj -0 -85.4403 Td -(0956 orl $CR0_PE, %eax) 122.3184 Tj -0 -94.9336 Td -(0957 movl %eax, %cr0) 109.2129 Tj -0 -104.427 Td -(0958 ) 21.8426 Tj -0 -113.9203 Td -(0959 # Jump to next instruction, but in 32-bit code segment.) 270.8479 Tj -0 -123.4137 Td -(0960 # Switches processor into 32-bit mode.) 196.5831 Tj -0 -132.9071 Td -(0961 ljmp $\(SEG_KCODE<<3\), $start32) 174.7406 Tj -0 -142.4004 Td -(0962 ) 21.8426 Tj -0 -151.8938 Td -(0963 .code32 # Assemble for 32-bit mode) 266.4794 Tj -0 -161.3871 Td -(0964 start32:) 56.7907 Tj -0 -170.8805 Td -(0965 # Set up the protected-mode data segment registers) 249.0053 Tj -0 -180.3739 Td -(0966 movw $\(SEG_KDATA<<3\), %ax # Our data segment sel\ -ector) 288.322 Tj -0 -189.8672 Td -(0967 movw %ax, %ds # -> DS: Data Segment) 262.1109 Tj -0 -199.3606 Td -(0968 movw %ax, %es # -> ES: Extra Segment) 266.4794 Tj -0 -208.8539 Td -(0969 movw %ax, %ss # -> SS: Stack Segment) 266.4794 Tj -0 -218.3473 Td -(0970 movw $0, %ax # Zero segments not read\ -y for use) 314.533 Tj -0 -227.8407 Td -(0971 movw %ax, %fs # -> FS) 200.9517 Tj -0 -237.334 Td -(0972 movw %ax, %gs # -> GS) 200.9517 Tj -0 -246.8274 Td -(0973 ) 21.8426 Tj -0 -256.3207 Td -(0974 # Set up the stack pointer and call into C.) 218.4257 Tj -0 -265.8141 Td -(0975 movl $start, %esp) 117.9499 Tj -0 -275.3075 Td -(0976 call bootmain) 100.4758 Tj -0 -284.8008 Td -(0977 ) 21.8426 Tj -0 -294.2942 Td -(0978 # If bootmain returns \(it shouldn't\), trigger a Bochs) 262.1109 Tj -0 -303.7875 Td -(0979 # breakpoint if running under Bochs, then loop.) 235.8998 Tj -0 -313.2809 Td -(0980 movw $0x8a00, %ax # 0x8a00 -> port 0x8a00) 270.8479 Tj -0 -322.7743 Td -(0981 movw %ax, %dx) 100.4758 Tj -0 -332.2676 Td -(0982 outw %ax, %dx) 100.4758 Tj -0 -341.761 Td -(0983 movw $0x8e00, %ax # 0x8e00 -> port 0x8a00) 270.8479 Tj -0 -351.2543 Td -(0984 outw %ax, %dx) 100.4758 Tj -0 -360.7477 Td -(0985 spin:) 43.6851 Tj -0 -370.2411 Td -(0986 jmp spin) 83.0018 Tj -0 -379.7344 Td -(0987 ) 21.8426 Tj -0 -389.2278 Td -(0988 # Bootstrap GDT) 87.3703 Tj -0 -398.7211 Td -(0989 .p2align 2 # force 4 byte a\ -lignment) 310.1645 Tj -0 -408.2145 Td -(0990 gdt:) 39.3166 Tj -0 -417.7079 Td -(0991 SEG_NULLASM # null seg) 249.0053 Tj -0 -427.2012 Td -(0992 SEG_ASM\(STA_X|STA_R, 0x0, 0xffffffff\) # code seg) 249.0053 Tj -0 -436.6946 Td -(0993 SEG_ASM\(STA_W, 0x0, 0xffffffff\) # data seg) 249.0053 Tj -0 -446.1879 Td -(0994 ) 21.8426 Tj -0 -455.6813 Td -(0995 gdtdesc:) 56.7907 Tj -0 -465.1747 Td -(0996 .word \(gdtdesc - gdt - 1\) \ - # sizeof\(gdt\) - 1) 345.1126 Tj -0 -474.668 Td -(0997 .long gdt # address gdt) 262.1109 Tj -0 -484.1614 Td -(0998 ) 21.8426 Tj -0 -493.6547 Td -(0999 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 09) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 17 17 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/bootother.S Page 1) 183.4776 Tj -0 -28.4801 Td -(1000 #include "asm.h") 91.7388 Tj -0 -37.9735 Td -(1001 ) 21.8426 Tj -0 -47.4668 Td -(1002 # Each non-boot CPU \("AP"\) is started up in response to \ -a STARTUP) 305.796 Tj -0 -56.9602 Td -(1003 # IPI from the boot CPU. Section B.4.2 of the Multi-Proce\ -ssor) 292.6905 Tj -0 -66.4535 Td -(1004 # Specification says that the AP will start in real mode w\ -ith CS:IP) 314.533 Tj -0 -75.9469 Td -(1005 # set to XY00:0000, where XY is an 8-bit value sent with t\ -he) 283.9534 Tj -0 -85.4403 Td -(1006 # STARTUP. Thus this code must start at a 4096-byte bounda\ -ry.) 288.322 Tj -0 -94.9336 Td -(1007 #) 26.2111 Tj -0 -104.427 Td -(1008 # Because this code sets DS to zero, it must sit) 231.5313 Tj -0 -113.9203 Td -(1009 # at an address in the low 2^16 bytes.) 187.8461 Tj -0 -123.4137 Td -(1010 #) 26.2111 Tj -0 -132.9071 Td -(1011 # Bootothers \(in main.c\) sends the STARTUPs, one at a ti\ -me.) 279.5849 Tj -0 -142.4004 Td -(1012 # It puts this code \(start\) at 0x7000.) 187.8461 Tj -0 -151.8938 Td -(1013 # It puts the correct %esp in start-4,) 187.8461 Tj -0 -161.3871 Td -(1014 # and the place to jump to in start-8.) 187.8461 Tj -0 -170.8805 Td -(1015 #) 26.2111 Tj -0 -180.3739 Td -(1016 # This code is identical to bootasm.S except:) 218.4257 Tj -0 -189.8672 Td -(1017 # - it does not need to enable A20) 179.1091 Tj -0 -199.3606 Td -(1018 # - it uses the address at start-4 for the %esp) 235.8998 Tj -0 -208.8539 Td -(1019 # - it jumps to the address at start-8 instead of callin\ -g bootmain) 318.9016 Tj -0 -218.3473 Td -(1020 ) 21.8426 Tj -0 -227.8407 Td -(1021 #define SEG_KCODE 1 // kernel code) 174.7406 Tj -0 -237.334 Td -(1022 #define SEG_KDATA 2 // kernel data+stack) 200.9517 Tj -0 -246.8274 Td -(1023 ) 21.8426 Tj -0 -256.3207 Td -(1024 #define CR0_PE 1 // protected mode enable bit) 235.8998 Tj -0 -265.8141 Td -(1025 ) 21.8426 Tj -0 -275.3075 Td -(1026 .code16 # Assemble for 16-bit mode) 266.4794 Tj -0 -284.8008 Td -(1027 .globl start) 74.2647 Tj -0 -294.2942 Td -(1028 start:) 48.0537 Tj -0 -303.7875 Td -(1029 cli # Disable interrupts) 240.2683 Tj -0 -313.2809 Td -(1030 ) 21.8426 Tj -0 -322.7743 Td -(1031 # Set up the important data segment registers \(DS, ES, \ -SS\).) 288.322 Tj -0 -332.2676 Td -(1032 xorw %ax,%ax # Segment number zero) 244.6368 Tj -0 -341.761 Td -(1033 movw %ax,%ds # -> Data Segment) 227.1628 Tj -0 -351.2543 Td -(1034 movw %ax,%es # -> Extra Segment) 231.5313 Tj -0 -360.7477 Td -(1035 movw %ax,%ss # -> Stack Segment) 231.5313 Tj -0 -370.2411 Td -(1036 ) 21.8426 Tj -0 -379.7344 Td -(1037 ) 21.8426 Tj -0 -389.2278 Td -(1038 ) 21.8426 Tj -0 -398.7211 Td -(1039 ) 21.8426 Tj -0 -408.2145 Td -(1040 ) 21.8426 Tj -0 -417.7079 Td -(1041 ) 21.8426 Tj -0 -427.2012 Td -(1042 ) 21.8426 Tj -0 -436.6946 Td -(1043 ) 21.8426 Tj -0 -446.1879 Td -(1044 ) 21.8426 Tj -0 -455.6813 Td -(1045 ) 21.8426 Tj -0 -465.1747 Td -(1046 ) 21.8426 Tj -0 -474.668 Td -(1047 ) 21.8426 Tj -0 -484.1614 Td -(1048 ) 21.8426 Tj -0 -493.6547 Td -(1049 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 10) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/bootother.S Page 2) 183.4776 Tj -0 -28.4801 Td -(1050 # Switch from real to protected mode, using a bootstrap \ -GDT) 288.322 Tj -0 -37.9735 Td -(1051 # and segment translation that makes virtual addresses) 266.4794 Tj -0 -47.4668 Td -(1052 # identical to physical addresses, so that the) 231.5313 Tj -0 -56.9602 Td -(1053 # effective memory map does not change during the switch\ -.) 279.5849 Tj -0 -66.4535 Td -(1054 lgdt gdtdesc) 96.1073 Tj -0 -75.9469 Td -(1055 movl %cr0, %eax) 109.2129 Tj -0 -85.4403 Td -(1056 orl $CR0_PE, %eax) 122.3184 Tj -0 -94.9336 Td -(1057 movl %eax, %cr0) 109.2129 Tj -0 -104.427 Td -(1058 ) 21.8426 Tj -0 -113.9203 Td -(1059 # Jump to next instruction, but in 32-bit code segment.) 270.8479 Tj -0 -123.4137 Td -(1060 # Switches processor into 32-bit mode.) 196.5831 Tj -0 -132.9071 Td -(1061 ljmp $\(SEG_KCODE<<3\), $start32) 174.7406 Tj -0 -142.4004 Td -(1062 ) 21.8426 Tj -0 -151.8938 Td -(1063 .code32 # Assemble for 32-bit mode) 266.4794 Tj -0 -161.3871 Td -(1064 start32:) 56.7907 Tj -0 -170.8805 Td -(1065 # Set up the protected-mode data segment registers) 249.0053 Tj -0 -180.3739 Td -(1066 movw $\(SEG_KDATA<<3\), %ax # Our data segment sel\ -ector) 288.322 Tj -0 -189.8672 Td -(1067 movw %ax, %ds # -> DS: Data Segment) 262.1109 Tj -0 -199.3606 Td -(1068 movw %ax, %es # -> ES: Extra Segment) 266.4794 Tj -0 -208.8539 Td -(1069 movw %ax, %ss # -> SS: Stack Segment) 266.4794 Tj -0 -218.3473 Td -(1070 movw $0, %ax # Zero segments not read\ -y for use) 314.533 Tj -0 -227.8407 Td -(1071 movw %ax, %fs # -> FS) 200.9517 Tj -0 -237.334 Td -(1072 movw %ax, %gs # -> GS) 200.9517 Tj -0 -246.8274 Td -(1073 ) 21.8426 Tj -0 -256.3207 Td -(1074 # Set up the stack pointer and call into C.) 218.4257 Tj -0 -265.8141 Td -(1075 movl start-4, %esp) 122.3184 Tj -0 -275.3075 Td -(1076 call) 48.0537 Tj --2507.8 TJm -(*\(start-8\)) 43.6851 Tj -0 -284.8008 Td -(1077 ) 21.8426 Tj -0 -294.2942 Td -(1078 # If the call returns \(it shouldn't\), trigger a Bochs) 262.1109 Tj -0 -303.7875 Td -(1079 # breakpoint if running under Bochs, then loop.) 235.8998 Tj -0 -313.2809 Td -(1080 movw $0x8a00, %ax # 0x8a00 -> port 0x8a00) 270.8479 Tj -0 -322.7743 Td -(1081 movw %ax, %dx) 100.4758 Tj -0 -332.2676 Td -(1082 outw %ax, %dx) 100.4758 Tj -0 -341.761 Td -(1083 movw $0x8e00, %ax # 0x8e00 -> port 0x8a00) 270.8479 Tj -0 -351.2543 Td -(1084 outw %ax, %dx) 100.4758 Tj -0 -360.7477 Td -(1085 spin:) 43.6851 Tj -0 -370.2411 Td -(1086 jmp spin) 83.0018 Tj -0 -379.7344 Td -(1087 ) 21.8426 Tj -0 -389.2278 Td -(1088 # Bootstrap GDT) 87.3703 Tj -0 -398.7211 Td -(1089 .p2align 2 # force 4 byte a\ -lignment) 310.1645 Tj -0 -408.2145 Td -(1090 gdt:) 39.3166 Tj -0 -417.7079 Td -(1091 SEG_NULLASM # null seg) 249.0053 Tj -0 -427.2012 Td -(1092 SEG_ASM\(STA_X|STA_R, 0x0, 0xffffffff\) # code seg) 249.0053 Tj -0 -436.6946 Td -(1093 SEG_ASM\(STA_W, 0x0, 0xffffffff\) # data seg) 249.0053 Tj -0 -446.1879 Td -(1094 ) 21.8426 Tj -0 -455.6813 Td -(1095 gdtdesc:) 56.7907 Tj -0 -465.1747 Td -(1096 .word \(gdtdesc - gdt - 1\) \ - # sizeof\(gdt\) - 1) 345.1126 Tj -0 -474.668 Td -(1097 .long gdt # address gdt) 262.1109 Tj -0 -484.1614 Td -(1098 ) 21.8426 Tj -0 -493.6547 Td -(1099 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 10) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 18 18 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/bootmain.c Page 1) 179.1091 Tj -0 -28.4801 Td -(1100 // Boot loader.) 87.3703 Tj -0 -37.9735 Td -(1101 //) 30.5796 Tj -0 -47.4668 Td -(1102 // Part of the boot sector, along with bootasm.S, which ca\ -lls bootmain\(\).) 340.7441 Tj -0 -56.9602 Td -(1103 // bootasm.S has put the processor into protected 32-bit m\ -ode.) 292.6905 Tj -0 -66.4535 Td -(1104 // bootmain\(\) loads an ELF kernel image from the disk st\ -arting at) 305.796 Tj -0 -75.9469 Td -(1105 // sector 1 and then jumps to the kernel entry routine.) 262.1109 Tj -0 -85.4403 Td -(1106 ) 21.8426 Tj -0 -94.9336 Td -(1107 #include "types.h") 100.4758 Tj -0 -104.427 Td -(1108 #include "elf.h") 91.7388 Tj -0 -113.9203 Td -(1109 #include "x86.h") 91.7388 Tj -0 -123.4137 Td -(1110 ) 21.8426 Tj -0 -132.9071 Td -(1111 #define SECTSIZE 512) 113.5814 Tj -0 -142.4004 Td -(1112 ) 21.8426 Tj -0 -151.8938 Td -(1113 void readseg\(uchar*, uint, uint\);) 166.0035 Tj -0 -161.3871 Td -(1114 ) 21.8426 Tj -0 -170.8805 Td -(1115 void) 39.3166 Tj -0 -180.3739 Td -(1116 bootmain\(void\)) 83.0018 Tj -0 -189.8672 Td -(1117 {) 26.2111 Tj -0 -199.3606 Td -(1118 struct elfhdr *elf;) 113.5814 Tj -0 -208.8539 Td -(1119 struct proghdr *ph, *eph;) 139.7925 Tj -0 -218.3473 Td -(1120 void \(*entry\)\(void\);) 117.9499 Tj -0 -227.8407 Td -(1121 uchar* va;) 74.2647 Tj -0 -237.334 Td -(1122 ) 21.8426 Tj -0 -246.8274 Td -(1123 elf = \(struct elfhdr*\)0x10000; // scratch space) 240.2683 Tj -0 -256.3207 Td -(1124 ) 21.8426 Tj -0 -265.8141 Td -(1125 // Read 1st page off disk) 139.7925 Tj -0 -275.3075 Td -(1126 readseg\(\(uchar*\)elf, 4096, 0\);) 161.635 Tj -0 -284.8008 Td -(1127 ) 21.8426 Tj -0 -294.2942 Td -(1128 // Is this an ELF executable?) 157.2665 Tj -0 -303.7875 Td -(1129 if\(elf->magic != ELF_MAGIC\)) 148.5295 Tj -0 -313.2809 Td -(1130 return; // let bootasm.S handle error) 205.3202 Tj -0 -322.7743 Td -(1131 ) 21.8426 Tj -0 -332.2676 Td -(1132 // Load each program segment \(ignores ph flags\).) 240.2683 Tj -0 -341.761 Td -(1133 ph = \(struct proghdr*\)\(\(uchar*\)elf + elf->phoff\);) 244.6368 Tj -0 -351.2543 Td -(1134 eph = ph + elf->phnum;) 126.6869 Tj -0 -360.7477 Td -(1135 for\(; ph < eph; ph++\) {) 131.0554 Tj -0 -370.2411 Td -(1136 va = \(uchar*\)\(ph->va & 0xFFFFFF\);) 183.4776 Tj -0 -379.7344 Td -(1137 readseg\(va, ph->filesz, ph->offset\);) 196.5831 Tj -0 -389.2278 Td -(1138 if\(ph->memsz > ph->filesz\)) 152.898 Tj -0 -398.7211 Td -(1139 stosb\(va + ph->filesz, 0, ph->memsz - ph->filesz\);) 266.4794 Tj -0 -408.2145 Td -(1140 }) 34.9481 Tj -0 -417.7079 Td -(1141 ) 21.8426 Tj -0 -427.2012 Td -(1142 // Call the entry point from the ELF header.) 222.7942 Tj -0 -436.6946 Td -(1143 // Does not return!) 113.5814 Tj -0 -446.1879 Td -(1144 entry = \(void\(*\)\(void\)\)\(elf->entry & 0xFFFFFF\);) 235.8998 Tj -0 -455.6813 Td -(1145 entry\(\);) 65.5277 Tj -0 -465.1747 Td -(1146 }) 26.2111 Tj -0 -474.668 Td -(1147 ) 21.8426 Tj -0 -484.1614 Td -(1148 ) 21.8426 Tj -0 -493.6547 Td -(1149 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 11) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/bootmain.c Page 2) 179.1091 Tj -0 -28.4801 Td -(1150 void) 39.3166 Tj -0 -37.9735 Td -(1151 waitdisk\(void\)) 83.0018 Tj -0 -47.4668 Td -(1152 {) 26.2111 Tj -0 -56.9602 Td -(1153 // Wait for disk ready.) 131.0554 Tj -0 -66.4535 Td -(1154 while\(\(inb\(0x1F7\) & 0xC0\) != 0x40\)) 179.1091 Tj -0 -75.9469 Td -(1155 ;) 43.6851 Tj -0 -85.4403 Td -(1156 }) 26.2111 Tj -0 -94.9336 Td -(1157 ) 21.8426 Tj -0 -104.427 Td -(1158 // Read a single sector at offset into dst.) 209.6887 Tj -0 -113.9203 Td -(1159 void) 39.3166 Tj -0 -123.4137 Td -(1160 readsect\(void *dst, uint offset\)) 161.635 Tj -0 -132.9071 Td -(1161 {) 26.2111 Tj -0 -142.4004 Td -(1162 // Issue command.) 104.8443 Tj -0 -151.8938 Td -(1163 waitdisk\(\);) 78.6333 Tj -0 -161.3871 Td -(1164 outb\(0x1F2, 1\); // count = 1) 161.635 Tj -0 -170.8805 Td -(1165 outb\(0x1F3, offset\);) 117.9499 Tj -0 -180.3739 Td -(1166 outb\(0x1F4, offset >> 8\);) 139.7925 Tj -0 -189.8672 Td -(1167 outb\(0x1F5, offset >> 16\);) 144.161 Tj -0 -199.3606 Td -(1168 outb\(0x1F6, \(offset >> 24\) | 0xE0\);) 183.4776 Tj -0 -208.8539 Td -(1169 outb\(0x1F7, 0x20\); // cmd 0x20 - read sectors) 231.5313 Tj -0 -218.3473 Td -(1170 ) 21.8426 Tj -0 -227.8407 Td -(1171 // Read data.) 87.3703 Tj -0 -237.334 Td -(1172 waitdisk\(\);) 78.6333 Tj -0 -246.8274 Td -(1173 insl\(0x1F0, dst, SECTSIZE/4\);) 157.2665 Tj -0 -256.3207 Td -(1174 }) 26.2111 Tj -0 -265.8141 Td -(1175 ) 21.8426 Tj -0 -275.3075 Td -(1176 // Read 'count' bytes at 'offset' from kernel into virtual\ - address 'va'.) 336.3756 Tj -0 -284.8008 Td -(1177 // Might copy more than asked.) 152.898 Tj -0 -294.2942 Td -(1178 void) 39.3166 Tj -0 -303.7875 Td -(1179 readseg\(uchar* va, uint count, uint offset\)) 209.6887 Tj -0 -313.2809 Td -(1180 {) 26.2111 Tj -0 -322.7743 Td -(1181 uchar* eva;) 78.6333 Tj -0 -332.2676 Td -(1182 ) 21.8426 Tj -0 -341.761 Td -(1183 eva = va + count;) 104.8443 Tj -0 -351.2543 Td -(1184 ) 21.8426 Tj -0 -360.7477 Td -(1185 // Round down to sector boundary.) 174.7406 Tj -0 -370.2411 Td -(1186 va -= offset % SECTSIZE;) 135.4239 Tj -0 -379.7344 Td -(1187 ) 21.8426 Tj -0 -389.2278 Td -(1188 // Translate from bytes to sectors; kernel starts at sec\ -tor 1.) 301.4275 Tj -0 -398.7211 Td -(1189 offset = \(offset / SECTSIZE\) + 1;) 174.7406 Tj -0 -408.2145 Td -(1190 ) 21.8426 Tj -0 -417.7079 Td -(1191 // If this is too slow, we could read lots of sectors at\ - a time.) 310.1645 Tj -0 -427.2012 Td -(1192 // We'd write more to memory than asked, but it doesn't \ -matter --) 314.533 Tj -0 -436.6946 Td -(1193 // we load in increasing order.) 166.0035 Tj -0 -446.1879 Td -(1194 for\(; va < eva; va += SECTSIZE, offset++\)) 209.6887 Tj -0 -455.6813 Td -(1195 readsect\(va, offset\);) 131.0554 Tj -0 -465.1747 Td -(1196 }) 26.2111 Tj -0 -474.668 Td -(1197 ) 21.8426 Tj -0 -484.1614 Td -(1198 ) 21.8426 Tj -0 -493.6547 Td -(1199 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 11) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 19 19 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/main.c Page 1) 161.635 Tj -0 -28.4801 Td -(1200 #include "types.h") 100.4758 Tj -0 -37.9735 Td -(1201 #include "defs.h") 96.1073 Tj -0 -47.4668 Td -(1202 #include "param.h") 100.4758 Tj -0 -56.9602 Td -(1203 #include "mmu.h") 91.7388 Tj -0 -66.4535 Td -(1204 #include "proc.h") 96.1073 Tj -0 -75.9469 Td -(1205 #include "x86.h") 91.7388 Tj -0 -85.4403 Td -(1206 ) 21.8426 Tj -0 -94.9336 Td -(1207 static void bootothers\(void\);) 148.5295 Tj -0 -104.427 Td -(1208 static void mpmain\(void\) __attribute__\(\(noreturn\)\);) 244.6368 Tj -0 -113.9203 Td -(1209 ) 21.8426 Tj -0 -123.4137 Td -(1210 // Bootstrap processor starts running C code here.) 240.2683 Tj -0 -132.9071 Td -(1211 int) 34.9481 Tj -0 -142.4004 Td -(1212 main\(void\)) 65.5277 Tj -0 -151.8938 Td -(1213 {) 26.2111 Tj -0 -161.3871 Td -(1214 mpinit\(\); // collect info about this machine) 222.7942 Tj -0 -170.8805 Td -(1215 lapicinit\(mpbcpu\(\)\);) 117.9499 Tj -0 -180.3739 Td -(1216 ksegment\(\);) 78.6333 Tj -0 -189.8672 Td -(1217 picinit\(\); // interrupt controller) 205.3202 Tj -0 -199.3606 Td -(1218 ioapicinit\(\); // another interrupt controller) 240.2683 Tj -0 -208.8539 Td -(1219 consoleinit\(\); // I/O devices & their interrupts) 249.0053 Tj -0 -218.3473 Td -(1220 uartinit\(\); // serial port) 166.0035 Tj -0 -227.8407 Td -(1221 cprintf\("cpus %p cpu %p\\n", cpus, cpu\);) 192.2146 Tj -0 -237.334 Td -(1222 cprintf\("\\ncpu%d: starting xv6\\n\\n", cpu->id\);) 231.5313 Tj -0 -246.8274 Td -(1223 ) 21.8426 Tj -0 -256.3207 Td -(1224 kinit\(\); // physical memory allocator) 227.1628 Tj -0 -265.8141 Td -(1225 pinit\(\); // process table) 174.7406 Tj -0 -275.3075 Td -(1226 tvinit\(\); // trap vectors) 170.3721 Tj -0 -284.8008 Td -(1227 binit\(\); // buffer cache) 170.3721 Tj -0 -294.2942 Td -(1228 fileinit\(\); // file table) 161.635 Tj -0 -303.7875 Td -(1229 iinit\(\); // inode cache) 166.0035 Tj -0 -313.2809 Td -(1230 ideinit\(\); // disk) 135.4239 Tj -0 -322.7743 Td -(1231 if\(!ismp\)) 69.8962 Tj -0 -332.2676 Td -(1232 timerinit\(\); // uniprocessor timer) 196.5831 Tj -0 -341.761 Td -(1233 userinit\(\); // first user process) 196.5831 Tj -0 -351.2543 Td -(1234 bootothers\(\); // start other processors) 214.0572 Tj -0 -360.7477 Td -(1235 ) 21.8426 Tj -0 -370.2411 Td -(1236 // Finish setting up this processor in mpmain.) 231.5313 Tj -0 -379.7344 Td -(1237 mpmain\(\);) 69.8962 Tj -0 -389.2278 Td -(1238 }) 26.2111 Tj -0 -398.7211 Td -(1239 ) 21.8426 Tj -0 -408.2145 Td -(1240 ) 21.8426 Tj -0 -417.7079 Td -(1241 ) 21.8426 Tj -0 -427.2012 Td -(1242 ) 21.8426 Tj -0 -436.6946 Td -(1243 ) 21.8426 Tj -0 -446.1879 Td -(1244 ) 21.8426 Tj -0 -455.6813 Td -(1245 ) 21.8426 Tj -0 -465.1747 Td -(1246 ) 21.8426 Tj -0 -474.668 Td -(1247 ) 21.8426 Tj -0 -484.1614 Td -(1248 ) 21.8426 Tj -0 -493.6547 Td -(1249 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 12) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/main.c Page 2) 161.635 Tj -0 -28.4801 Td -(1250 // Bootstrap processor gets here after setting up the hard\ -ware.) 297.059 Tj -0 -37.9735 Td -(1251 // Additional processors start here.) 179.1091 Tj -0 -47.4668 Td -(1252 static void) 69.8962 Tj -0 -56.9602 Td -(1253 mpmain\(void\)) 74.2647 Tj -0 -66.4535 Td -(1254 {) 26.2111 Tj -0 -75.9469 Td -(1255 if\(cpunum\(\) != mpbcpu\(\)\)) 135.4239 Tj -0 -85.4403 Td -(1256 lapicinit\(cpunum\(\)\);) 126.6869 Tj -0 -94.9336 Td -(1257 ksegment\(\);) 78.6333 Tj -0 -104.427 Td -(1258 cprintf\("cpu%d: mpmain\\n", cpu->id\);) 187.8461 Tj -0 -113.9203 Td -(1259 idtinit\(\);) 74.2647 Tj -0 -123.4137 Td -(1260 xchg\(&cpu->booted, 1\);) 126.6869 Tj -0 -132.9071 Td -(1261 ) 21.8426 Tj -0 -142.4004 Td -(1262 cprintf\("cpu%d: scheduling\\n", cpu->id\);) 205.3202 Tj -0 -151.8938 Td -(1263 scheduler\(\);) 83.0018 Tj -0 -161.3871 Td -(1264 }) 26.2111 Tj -0 -170.8805 Td -(1265 ) 21.8426 Tj -0 -180.3739 Td -(1266 static void) 69.8962 Tj -0 -189.8672 Td -(1267 bootothers\(void\)) 91.7388 Tj -0 -199.3606 Td -(1268 {) 26.2111 Tj -0 -208.8539 Td -(1269 extern uchar _binary_bootother_start[], _binary_bootothe\ -r_size[];) 314.533 Tj -0 -218.3473 Td -(1270 uchar *code;) 83.0018 Tj -0 -227.8407 Td -(1271 struct cpu *c;) 91.7388 Tj -0 -237.334 Td -(1272 char *stack;) 83.0018 Tj -0 -246.8274 Td -(1273 ) 21.8426 Tj -0 -256.3207 Td -(1274 // Write bootstrap code to unused memory at 0x7000.) 253.3738 Tj -0 -265.8141 Td -(1275 code = \(uchar*\)0x7000;) 126.6869 Tj -0 -275.3075 Td -(1276 memmove\(code, _binary_bootother_start, \(uint\)_binary_\ -bootother_size\);) 332.0071 Tj -0 -284.8008 Td -(1277 ) 21.8426 Tj -0 -294.2942 Td -(1278 for\(c = cpus; c < cpus+ncpu; c++\){) 179.1091 Tj -0 -303.7875 Td -(1279 if\(c == cpus+cpunum\(\)\) // We've started already.) 253.3738 Tj -0 -313.2809 Td -(1280 continue;) 87.3703 Tj -0 -322.7743 Td -(1281 ) 21.8426 Tj -0 -332.2676 Td -(1282 // Fill in %esp, %eip and start code on cpu.) 231.5313 Tj -0 -341.761 Td -(1283 stack = kalloc\(KSTACKSIZE\);) 157.2665 Tj -0 -351.2543 Td -(1284 *\(void**\)\(code-4\) = stack + KSTACKSIZE;) 209.6887 Tj -0 -360.7477 Td -(1285 *\(void**\)\(code-8\) = mpmain;) 157.2665 Tj -0 -370.2411 Td -(1286 lapicstartap\(c->id, \(uint\)code\);) 179.1091 Tj -0 -379.7344 Td -(1287 ) 21.8426 Tj -0 -389.2278 Td -(1288 // Wait for cpu to get through bootstrap.) 218.4257 Tj -0 -398.7211 Td -(1289 while\(c->booted == 0\)) 131.0554 Tj -0 -408.2145 Td -(1290 ;) 52.4222 Tj -0 -417.7079 Td -(1291 }) 34.9481 Tj -0 -427.2012 Td -(1292 }) 26.2111 Tj -0 -436.6946 Td -(1293 ) 21.8426 Tj -0 -446.1879 Td -(1294 ) 21.8426 Tj -0 -455.6813 Td -(1295 ) 21.8426 Tj -0 -465.1747 Td -(1296 ) 21.8426 Tj -0 -474.668 Td -(1297 ) 21.8426 Tj -0 -484.1614 Td -(1298 ) 21.8426 Tj -0 -493.6547 Td -(1299 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 12) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 20 20 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/spinlock.h Page 1) 179.1091 Tj -0 -28.4801 Td -(1300 // Mutual exclusion lock.) 131.0554 Tj -0 -37.9735 Td -(1301 struct spinlock {) 96.1073 Tj -0 -47.4668 Td -(1302 uint locked; // Is the lock held?) 200.9517 Tj -0 -56.9602 Td -(1303 ) 21.8426 Tj -0 -66.4535 Td -(1304 // For debugging:) 104.8443 Tj -0 -75.9469 Td -(1305 char *name; // Name of lock.) 183.4776 Tj -0 -85.4403 Td -(1306 struct cpu *cpu; // The cpu holding the lock.) 235.8998 Tj -0 -94.9336 Td -(1307 uint pcs[10]; // The call stack \(an array of progr\ -am counters\)) 323.2701 Tj -0 -104.427 Td -(1308 // that locked the lock.) 218.4257 Tj -0 -113.9203 Td -(1309 };) 30.5796 Tj -0 -123.4137 Td -(1310 ) 21.8426 Tj -0 -132.9071 Td -(1311 ) 21.8426 Tj -0 -142.4004 Td -(1312 ) 21.8426 Tj -0 -151.8938 Td -(1313 ) 21.8426 Tj -0 -161.3871 Td -(1314 ) 21.8426 Tj -0 -170.8805 Td -(1315 ) 21.8426 Tj -0 -180.3739 Td -(1316 ) 21.8426 Tj -0 -189.8672 Td -(1317 ) 21.8426 Tj -0 -199.3606 Td -(1318 ) 21.8426 Tj -0 -208.8539 Td -(1319 ) 21.8426 Tj -0 -218.3473 Td -(1320 ) 21.8426 Tj -0 -227.8407 Td -(1321 ) 21.8426 Tj -0 -237.334 Td -(1322 ) 21.8426 Tj -0 -246.8274 Td -(1323 ) 21.8426 Tj -0 -256.3207 Td -(1324 ) 21.8426 Tj -0 -265.8141 Td -(1325 ) 21.8426 Tj -0 -275.3075 Td -(1326 ) 21.8426 Tj -0 -284.8008 Td -(1327 ) 21.8426 Tj -0 -294.2942 Td -(1328 ) 21.8426 Tj -0 -303.7875 Td -(1329 ) 21.8426 Tj -0 -313.2809 Td -(1330 ) 21.8426 Tj -0 -322.7743 Td -(1331 ) 21.8426 Tj -0 -332.2676 Td -(1332 ) 21.8426 Tj -0 -341.761 Td -(1333 ) 21.8426 Tj -0 -351.2543 Td -(1334 ) 21.8426 Tj -0 -360.7477 Td -(1335 ) 21.8426 Tj -0 -370.2411 Td -(1336 ) 21.8426 Tj -0 -379.7344 Td -(1337 ) 21.8426 Tj -0 -389.2278 Td -(1338 ) 21.8426 Tj -0 -398.7211 Td -(1339 ) 21.8426 Tj -0 -408.2145 Td -(1340 ) 21.8426 Tj -0 -417.7079 Td -(1341 ) 21.8426 Tj -0 -427.2012 Td -(1342 ) 21.8426 Tj -0 -436.6946 Td -(1343 ) 21.8426 Tj -0 -446.1879 Td -(1344 ) 21.8426 Tj -0 -455.6813 Td -(1345 ) 21.8426 Tj -0 -465.1747 Td -(1346 ) 21.8426 Tj -0 -474.668 Td -(1347 ) 21.8426 Tj -0 -484.1614 Td -(1348 ) 21.8426 Tj -0 -493.6547 Td -(1349 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 13) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/spinlock.c Page 1) 179.1091 Tj -0 -28.4801 Td -(1350 // Mutual exclusion spin locks.) 157.2665 Tj -0 -37.9735 Td -(1351 ) 21.8426 Tj -0 -47.4668 Td -(1352 #include "types.h") 100.4758 Tj -0 -56.9602 Td -(1353 #include "defs.h") 96.1073 Tj -0 -66.4535 Td -(1354 #include "param.h") 100.4758 Tj -0 -75.9469 Td -(1355 #include "x86.h") 91.7388 Tj -0 -85.4403 Td -(1356 #include "mmu.h") 91.7388 Tj -0 -94.9336 Td -(1357 #include "proc.h") 96.1073 Tj -0 -104.427 Td -(1358 #include "spinlock.h") 113.5814 Tj -0 -113.9203 Td -(1359 ) 21.8426 Tj -0 -123.4137 Td -(1360 void) 39.3166 Tj -0 -132.9071 Td -(1361 initlock\(struct spinlock *lk, char *name\)) 200.9517 Tj -0 -142.4004 Td -(1362 {) 26.2111 Tj -0 -151.8938 Td -(1363 lk->name = name;) 100.4758 Tj -0 -161.3871 Td -(1364 lk->locked = 0;) 96.1073 Tj -0 -170.8805 Td -(1365 lk->cpu = 0;) 83.0018 Tj -0 -180.3739 Td -(1366 }) 26.2111 Tj -0 -189.8672 Td -(1367 ) 21.8426 Tj -0 -199.3606 Td -(1368 // Acquire the lock.) 109.2129 Tj -0 -208.8539 Td -(1369 // Loops \(spins\) until the lock is acquired.) 214.0572 Tj -0 -218.3473 Td -(1370 // Holding a lock for a long time may cause) 209.6887 Tj -0 -227.8407 Td -(1371 // other CPUs to waste time spinning to acquire it.) 244.6368 Tj -0 -237.334 Td -(1372 void) 39.3166 Tj -0 -246.8274 Td -(1373 acquire\(struct spinlock *lk\)) 144.161 Tj -0 -256.3207 Td -(1374 {) 26.2111 Tj -0 -265.8141 Td -(1375 pushcli\(\);) 74.2647 Tj -0 -275.3075 Td -(1376 if\(holding\(lk\)\)) 96.1073 Tj -0 -284.8008 Td -(1377 panic\("acquire"\);) 113.5814 Tj -0 -294.2942 Td -(1378 ) 21.8426 Tj -0 -303.7875 Td -(1379 // The xchg is atomic.) 126.6869 Tj -0 -313.2809 Td -(1380 // It also serializes, so that reads after acquire are n\ -ot) 283.9534 Tj -0 -322.7743 Td -(1381 // reordered before it.) 131.0554 Tj -0 -332.2676 Td -(1382 while\(xchg\(&lk->locked, 1\) != 0\)) 170.3721 Tj -0 -341.761 Td -(1383 ;) 43.6851 Tj -0 -351.2543 Td -(1384 ) 21.8426 Tj -0 -360.7477 Td -(1385 // Record info about lock acquisition for debugging.) 257.7424 Tj -0 -370.2411 Td -(1386 lk->cpu = cpu;) 91.7388 Tj -0 -379.7344 Td -(1387 getcallerpcs\(&lk, lk->pcs\);) 148.5295 Tj -0 -389.2278 Td -(1388 }) 26.2111 Tj -0 -398.7211 Td -(1389 ) 21.8426 Tj -0 -408.2145 Td -(1390 ) 21.8426 Tj -0 -417.7079 Td -(1391 ) 21.8426 Tj -0 -427.2012 Td -(1392 ) 21.8426 Tj -0 -436.6946 Td -(1393 ) 21.8426 Tj -0 -446.1879 Td -(1394 ) 21.8426 Tj -0 -455.6813 Td -(1395 ) 21.8426 Tj -0 -465.1747 Td -(1396 ) 21.8426 Tj -0 -474.668 Td -(1397 ) 21.8426 Tj -0 -484.1614 Td -(1398 ) 21.8426 Tj -0 -493.6547 Td -(1399 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 13) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 21 21 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/spinlock.c Page 2) 179.1091 Tj -0 -28.4801 Td -(1400 // Release the lock.) 109.2129 Tj -0 -37.9735 Td -(1401 void) 39.3166 Tj -0 -47.4668 Td -(1402 release\(struct spinlock *lk\)) 144.161 Tj -0 -56.9602 Td -(1403 {) 26.2111 Tj -0 -66.4535 Td -(1404 if\(!holding\(lk\)\)) 100.4758 Tj -0 -75.9469 Td -(1405 panic\("release"\);) 113.5814 Tj -0 -85.4403 Td -(1406 ) 21.8426 Tj -0 -94.9336 Td -(1407 lk->pcs[0] = 0;) 96.1073 Tj -0 -104.427 Td -(1408 lk->cpu = 0;) 83.0018 Tj -0 -113.9203 Td -(1409 ) 21.8426 Tj -0 -123.4137 Td -(1410 // The xchg serializes, so that reads before release are) 275.2164 Tj -0 -132.9071 Td -(1411 // not reordered after it. The 1996 PentiumPro manual \(\ -Volume 3,) 314.533 Tj -0 -142.4004 Td -(1412 // 7.2\) says reads can be carried out speculatively and\ - in) 283.9534 Tj -0 -151.8938 Td -(1413 // any order, which implies we need to serialize here.) 266.4794 Tj -0 -161.3871 Td -(1414 // But the 2007 Intel 64 Architecture Memory Ordering Wh\ -ite) 288.322 Tj -0 -170.8805 Td -(1415 // Paper says that Intel 64 and IA-32 will not move a lo\ -ad) 283.9534 Tj -0 -180.3739 Td -(1416 // after a store. So lock->locked = 0 would work here.) 266.4794 Tj -0 -189.8672 Td -(1417 // The xchg being asm volatile ensures gcc emits it afte\ -r) 279.5849 Tj -0 -199.3606 Td -(1418 // the above assignments \(and after the critical sectio\ -n\).) 283.9534 Tj -0 -208.8539 Td -(1419 xchg\(&lk->locked, 0\);) 122.3184 Tj -0 -218.3473 Td -(1420 ) 21.8426 Tj -0 -227.8407 Td -(1421 popcli\(\);) 69.8962 Tj -0 -237.334 Td -(1422 }) 26.2111 Tj -0 -246.8274 Td -(1423 ) 21.8426 Tj -0 -256.3207 Td -(1424 // Record the current call stack in pcs[] by following the\ - %ebp chain.) 327.6386 Tj -0 -265.8141 Td -(1425 void) 39.3166 Tj -0 -275.3075 Td -(1426 getcallerpcs\(void *v, uint pcs[]\)) 166.0035 Tj -0 -284.8008 Td -(1427 {) 26.2111 Tj -0 -294.2942 Td -(1428 uint *ebp;) 74.2647 Tj -0 -303.7875 Td -(1429 int i;) 56.7907 Tj -0 -313.2809 Td -(1430 ) 21.8426 Tj -0 -322.7743 Td -(1431 ebp = \(uint*\)v - 2;) 113.5814 Tj -0 -332.2676 Td -(1432 for\(i = 0; i < 10; i++\){) 135.4239 Tj -0 -341.761 Td -(1433 if\(ebp == 0 || ebp == \(uint*\)0xffffffff\)) 214.0572 Tj -0 -351.2543 Td -(1434 break;) 74.2647 Tj -0 -360.7477 Td -(1435 pcs[i] = ebp[1]; // saved %eip) 187.8461 Tj -0 -370.2411 Td -(1436 ebp = \(uint*\)ebp[0]; // saved %ebp) 187.8461 Tj -0 -379.7344 Td -(1437 }) 34.9481 Tj -0 -389.2278 Td -(1438 for\(; i < 10; i++\)) 109.2129 Tj -0 -398.7211 Td -(1439 pcs[i] = 0;) 87.3703 Tj -0 -408.2145 Td -(1440 }) 26.2111 Tj -0 -417.7079 Td -(1441 ) 21.8426 Tj -0 -427.2012 Td -(1442 // Check whether this cpu is holding the lock.) 222.7942 Tj -0 -436.6946 Td -(1443 int) 34.9481 Tj -0 -446.1879 Td -(1444 holding\(struct spinlock *lock\)) 152.898 Tj -0 -455.6813 Td -(1445 {) 26.2111 Tj -0 -465.1747 Td -(1446 return lock->locked && lock->cpu == cpu;) 205.3202 Tj -0 -474.668 Td -(1447 }) 26.2111 Tj -0 -484.1614 Td -(1448 ) 21.8426 Tj -0 -493.6547 Td -(1449 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 14) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/spinlock.c Page 3) 179.1091 Tj -0 -28.4801 Td -(1450 // Pushcli/popcli are like cli/sti except that they are ma\ -tched:) 301.4275 Tj -0 -37.9735 Td -(1451 // it takes two popcli to undo two pushcli. Also, if inte\ -rrupts) 301.4275 Tj -0 -47.4668 Td -(1452 // are off, then pushcli, popcli leaves them off.) 235.8998 Tj -0 -56.9602 Td -(1453 ) 21.8426 Tj -0 -66.4535 Td -(1454 void) 39.3166 Tj -0 -75.9469 Td -(1455 pushcli\(void\)) 78.6333 Tj -0 -85.4403 Td -(1456 {) 26.2111 Tj -0 -94.9336 Td -(1457 int eflags;) 78.6333 Tj -0 -104.427 Td -(1458 ) 21.8426 Tj -0 -113.9203 Td -(1459 eflags = readeflags\(\);) 126.6869 Tj -0 -123.4137 Td -(1460 cli\(\);) 56.7907 Tj -0 -132.9071 Td -(1461 if\(cpu->ncli++ == 0\)) 117.9499 Tj -0 -142.4004 Td -(1462 cpu->intena = eflags & FL_IF;) 166.0035 Tj -0 -151.8938 Td -(1463 }) 26.2111 Tj -0 -161.3871 Td -(1464 ) 21.8426 Tj -0 -170.8805 Td -(1465 void) 39.3166 Tj -0 -180.3739 Td -(1466 popcli\(void\)) 74.2647 Tj -0 -189.8672 Td -(1467 {) 26.2111 Tj -0 -199.3606 Td -(1468 if\(readeflags\(\)&FL_IF\)) 126.6869 Tj -0 -208.8539 Td -(1469 panic\("popcli - interruptible"\);) 179.1091 Tj -0 -218.3473 Td -(1470 if\(--cpu->ncli < 0\)) 113.5814 Tj -0 -227.8407 Td -(1471 panic\("popcli"\);) 109.2129 Tj -0 -237.334 Td -(1472 if\(cpu->ncli == 0 && cpu->intena\)) 174.7406 Tj -0 -246.8274 Td -(1473 sti\(\);) 65.5277 Tj -0 -256.3207 Td -(1474 }) 26.2111 Tj -0 -265.8141 Td -(1475 ) 21.8426 Tj -0 -275.3075 Td -(1476 ) 21.8426 Tj -0 -284.8008 Td -(1477 ) 21.8426 Tj -0 -294.2942 Td -(1478 ) 21.8426 Tj -0 -303.7875 Td -(1479 ) 21.8426 Tj -0 -313.2809 Td -(1480 ) 21.8426 Tj -0 -322.7743 Td -(1481 ) 21.8426 Tj -0 -332.2676 Td -(1482 ) 21.8426 Tj -0 -341.761 Td -(1483 ) 21.8426 Tj -0 -351.2543 Td -(1484 ) 21.8426 Tj -0 -360.7477 Td -(1485 ) 21.8426 Tj -0 -370.2411 Td -(1486 ) 21.8426 Tj -0 -379.7344 Td -(1487 ) 21.8426 Tj -0 -389.2278 Td -(1488 ) 21.8426 Tj -0 -398.7211 Td -(1489 ) 21.8426 Tj -0 -408.2145 Td -(1490 ) 21.8426 Tj -0 -417.7079 Td -(1491 ) 21.8426 Tj -0 -427.2012 Td -(1492 ) 21.8426 Tj -0 -436.6946 Td -(1493 ) 21.8426 Tj -0 -446.1879 Td -(1494 ) 21.8426 Tj -0 -455.6813 Td -(1495 ) 21.8426 Tj -0 -465.1747 Td -(1496 ) 21.8426 Tj -0 -474.668 Td -(1497 ) 21.8426 Tj -0 -484.1614 Td -(1498 ) 21.8426 Tj -0 -493.6547 Td -(1499 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 14) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 22 22 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/proc.h Page 1) 161.635 Tj -0 -28.4801 Td -(1500 // Segments in proc->gdt.) 131.0554 Tj -0 -37.9735 Td -(1501 // Also known to bootasm.S and trapasm.S) 196.5831 Tj -0 -47.4668 Td -(1502 #define SEG_KCODE 1 // kernel code) 174.7406 Tj -0 -56.9602 Td -(1503 #define SEG_KDATA 2 // kernel data+stack) 200.9517 Tj -0 -66.4535 Td -(1504 #define SEG_KCPU 3 // kernel per-cpu data) 209.6887 Tj -0 -75.9469 Td -(1505 #define SEG_UCODE 4) 104.8443 Tj -0 -85.4403 Td -(1506 #define SEG_UDATA 5) 104.8443 Tj -0 -94.9336 Td -(1507 #define SEG_TSS 6 // this process's task state) 235.8998 Tj -0 -104.427 Td -(1508 #define NSEGS 7) 104.8443 Tj -0 -113.9203 Td -(1509 ) 21.8426 Tj -0 -123.4137 Td -(1510 // Saved registers for kernel context switches.) 227.1628 Tj -0 -132.9071 Td -(1511 // Don't need to save all the segment registers \(%cs, etc\ -\),) 279.5849 Tj -0 -142.4004 Td -(1512 // because they are constant across kernel contexts.) 249.0053 Tj -0 -151.8938 Td -(1513 // Don't need to save %eax, %ecx, %edx, because the) 244.6368 Tj -0 -161.3871 Td -(1514 // x86 convention is that the caller has saved them.) 249.0053 Tj -0 -170.8805 Td -(1515 // Contexts are stored at the bottom of the stack they) 257.7424 Tj -0 -180.3739 Td -(1516 // describe; the stack pointer is the address of the conte\ -xt.) 288.322 Tj -0 -189.8672 Td -(1517 // The layout of the context must match the code in swtch.\ -S.) 283.9534 Tj -0 -199.3606 Td -(1518 struct context {) 91.7388 Tj -0 -208.8539 Td -(1519 uint edi;) 69.8962 Tj -0 -218.3473 Td -(1520 uint esi;) 69.8962 Tj -0 -227.8407 Td -(1521 uint ebx;) 69.8962 Tj -0 -237.334 Td -(1522 uint ebp;) 69.8962 Tj -0 -246.8274 Td -(1523 uint eip;) 69.8962 Tj -0 -256.3207 Td -(1524 };) 30.5796 Tj -0 -265.8141 Td -(1525 ) 21.8426 Tj -0 -275.3075 Td -(1526 enum procstate { UNUSED, EMBRYO, SLEEPING, RUNNABLE, RUNNI\ -NG, ZOMBIE };) 332.0071 Tj -0 -284.8008 Td -(1527 ) 21.8426 Tj -0 -294.2942 Td -(1528 // Per-process state) 109.2129 Tj -0 -303.7875 Td -(1529 struct proc {) 78.6333 Tj -0 -313.2809 Td -(1530 char *mem; // Start of process memory \ -\(kernel address\)) 345.1126 Tj -0 -322.7743 Td -(1531 uint sz; // Size of process memory \(\ -bytes\)) 301.4275 Tj -0 -332.2676 Td -(1532 char *kstack; // Bottom of kernel stack f\ -or this process) 340.7441 Tj -0 -341.761 Td -(1533 enum procstate state; // Process state) 227.1628 Tj -0 -351.2543 Td -(1534 volatile int pid; // Process ID) 214.0572 Tj -0 -360.7477 Td -(1535 struct proc *parent; // Parent process) 231.5313 Tj -0 -370.2411 Td -(1536 struct trapframe *tf; // Trap frame for current s\ -yscall) 301.4275 Tj -0 -379.7344 Td -(1537 struct context *context; // Switch here to run proce\ -ss) 283.9534 Tj -0 -389.2278 Td -(1538 void *chan; // If non-zero, sleeping on\ - chan) 297.059 Tj -0 -398.7211 Td -(1539 int killed; // If non-zero, have been k\ -illed) 297.059 Tj -0 -408.2145 Td -(1540 struct file *ofile[NOFILE]; // Open files) 214.0572 Tj -0 -417.7079 Td -(1541 struct inode *cwd; // Current directory) 244.6368 Tj -0 -427.2012 Td -(1542 char name[16]; // Process name \(debugging\ -\)) 275.2164 Tj -0 -436.6946 Td -(1543 };) 30.5796 Tj -0 -446.1879 Td -(1544 ) 21.8426 Tj -0 -455.6813 Td -(1545 ) 21.8426 Tj -0 -465.1747 Td -(1546 ) 21.8426 Tj -0 -474.668 Td -(1547 ) 21.8426 Tj -0 -484.1614 Td -(1548 ) 21.8426 Tj -0 -493.6547 Td -(1549 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 15) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/proc.h Page 2) 161.635 Tj -0 -28.4801 Td -(1550 // Process memory is laid out contiguously, low addresses \ -first:) 301.4275 Tj -0 -37.9735 Td -(1551 // text) 61.1592 Tj -0 -47.4668 Td -(1552 // original data and bss) 135.4239 Tj -0 -56.9602 Td -(1553 // fixed-size stack) 113.5814 Tj -0 -66.4535 Td -(1554 // expandable heap) 109.2129 Tj -0 -75.9469 Td -(1555 ) 21.8426 Tj -0 -85.4403 Td -(1556 // Per-CPU state) 91.7388 Tj -0 -94.9336 Td -(1557 struct cpu {) 74.2647 Tj -0 -104.427 Td -(1558 uchar id; // Local APIC ID; index int\ -o cpus[] below) 336.3756 Tj -0 -113.9203 Td -(1559 struct context *scheduler; // Switch here to enter sch\ -eduler) 301.4275 Tj -0 -123.4137 Td -(1560 struct taskstate ts; // Used by x86 to find stac\ -k for interrupt) 340.7441 Tj -0 -132.9071 Td -(1561 struct segdesc gdt[NSEGS]; // x86 global descriptor ta\ -ble) 288.322 Tj -0 -142.4004 Td -(1562 volatile uint booted; // Has the CPU started?) 257.7424 Tj -0 -151.8938 Td -(1563 int ncli; // Depth of pushcli nesting\ -.) 279.5849 Tj -0 -161.3871 Td -(1564 int intena; // Were interrupts enabled \ -before pushcli?) 340.7441 Tj -0 -170.8805 Td -(1565 ) 21.8426 Tj -0 -180.3739 Td -(1566 // Cpu-local storage variables; see below) 209.6887 Tj -0 -189.8672 Td -(1567 struct cpu *cpu;) 100.4758 Tj -0 -199.3606 Td -(1568 struct proc *proc;) 109.2129 Tj -0 -208.8539 Td -(1569 };) 30.5796 Tj -0 -218.3473 Td -(1570 ) 21.8426 Tj -0 -227.8407 Td -(1571 extern struct cpu cpus[NCPU];) 148.5295 Tj -0 -237.334 Td -(1572 extern int ncpu;) 91.7388 Tj -0 -246.8274 Td -(1573 ) 21.8426 Tj -0 -256.3207 Td -(1574 // Per-CPU variables, holding pointers to the) 218.4257 Tj -0 -265.8141 Td -(1575 // current cpu and to the current process.) 205.3202 Tj -0 -275.3075 Td -(1576 // The asm suffix tells gcc to use "%gs:0" to refer to cpu) 275.2164 Tj -0 -284.8008 Td -(1577 // and "%gs:4" to refer to proc. ksegment sets up the) 257.7424 Tj -0 -294.2942 Td -(1578 // %gs segment register so that %gs refers to the memory) 266.4794 Tj -0 -303.7875 Td -(1579 // holding those two variables in the local cpu's struct c\ -pu.) 288.322 Tj -0 -313.2809 Td -(1580 // This is similar to how thread-local variables are imple\ -mented) 301.4275 Tj -0 -322.7743 Td -(1581 // in thread libraries such as Linux pthreads.) 222.7942 Tj -0 -332.2676 Td -(1582 extern struct cpu *cpu asm\("%gs:0"\); // This cpu.) 262.1109 Tj -0 -341.761 Td -(1583 extern struct proc *proc asm\("%gs:4"\); // Current pr\ -oc on this cpu.) 332.0071 Tj -0 -351.2543 Td -(1584 ) 21.8426 Tj -0 -360.7477 Td -(1585 ) 21.8426 Tj -0 -370.2411 Td -(1586 ) 21.8426 Tj -0 -379.7344 Td -(1587 ) 21.8426 Tj -0 -389.2278 Td -(1588 ) 21.8426 Tj -0 -398.7211 Td -(1589 ) 21.8426 Tj -0 -408.2145 Td -(1590 ) 21.8426 Tj -0 -417.7079 Td -(1591 ) 21.8426 Tj -0 -427.2012 Td -(1592 ) 21.8426 Tj -0 -436.6946 Td -(1593 ) 21.8426 Tj -0 -446.1879 Td -(1594 ) 21.8426 Tj -0 -455.6813 Td -(1595 ) 21.8426 Tj -0 -465.1747 Td -(1596 ) 21.8426 Tj -0 -474.668 Td -(1597 ) 21.8426 Tj -0 -484.1614 Td -(1598 ) 21.8426 Tj -0 -493.6547 Td -(1599 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 15) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 23 23 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/proc.c Page 1) 161.635 Tj -0 -28.4801 Td -(1600 #include "types.h") 100.4758 Tj -0 -37.9735 Td -(1601 #include "defs.h") 96.1073 Tj -0 -47.4668 Td -(1602 #include "param.h") 100.4758 Tj -0 -56.9602 Td -(1603 #include "mmu.h") 91.7388 Tj -0 -66.4535 Td -(1604 #include "x86.h") 91.7388 Tj -0 -75.9469 Td -(1605 #include "proc.h") 96.1073 Tj -0 -85.4403 Td -(1606 #include "spinlock.h") 113.5814 Tj -0 -94.9336 Td -(1607 ) 21.8426 Tj -0 -104.427 Td -(1608 struct {) 56.7907 Tj -0 -113.9203 Td -(1609 struct spinlock lock;) 122.3184 Tj -0 -123.4137 Td -(1610 struct proc proc[NPROC];) 135.4239 Tj -0 -132.9071 Td -(1611 } ptable;) 61.1592 Tj -0 -142.4004 Td -(1612 ) 21.8426 Tj -0 -151.8938 Td -(1613 static struct proc *initproc;) 148.5295 Tj -0 -161.3871 Td -(1614 ) 21.8426 Tj -0 -170.8805 Td -(1615 int nextpid = 1;) 91.7388 Tj -0 -180.3739 Td -(1616 extern void forkret\(void\);) 135.4239 Tj -0 -189.8672 Td -(1617 extern void trapret\(void\);) 135.4239 Tj -0 -199.3606 Td -(1618 ) 21.8426 Tj -0 -208.8539 Td -(1619 void) 39.3166 Tj -0 -218.3473 Td -(1620 pinit\(void\)) 69.8962 Tj -0 -227.8407 Td -(1621 {) 26.2111 Tj -0 -237.334 Td -(1622 initlock\(&ptable.lock, "ptable"\);) 174.7406 Tj -0 -246.8274 Td -(1623 }) 26.2111 Tj -0 -256.3207 Td -(1624 ) 21.8426 Tj -0 -265.8141 Td -(1625 ) 21.8426 Tj -0 -275.3075 Td -(1626 ) 21.8426 Tj -0 -284.8008 Td -(1627 ) 21.8426 Tj -0 -294.2942 Td -(1628 ) 21.8426 Tj -0 -303.7875 Td -(1629 ) 21.8426 Tj -0 -313.2809 Td -(1630 ) 21.8426 Tj -0 -322.7743 Td -(1631 ) 21.8426 Tj -0 -332.2676 Td -(1632 ) 21.8426 Tj -0 -341.761 Td -(1633 ) 21.8426 Tj -0 -351.2543 Td -(1634 ) 21.8426 Tj -0 -360.7477 Td -(1635 ) 21.8426 Tj -0 -370.2411 Td -(1636 ) 21.8426 Tj -0 -379.7344 Td -(1637 ) 21.8426 Tj -0 -389.2278 Td -(1638 ) 21.8426 Tj -0 -398.7211 Td -(1639 ) 21.8426 Tj -0 -408.2145 Td -(1640 ) 21.8426 Tj -0 -417.7079 Td -(1641 ) 21.8426 Tj -0 -427.2012 Td -(1642 ) 21.8426 Tj -0 -436.6946 Td -(1643 ) 21.8426 Tj -0 -446.1879 Td -(1644 ) 21.8426 Tj -0 -455.6813 Td -(1645 ) 21.8426 Tj -0 -465.1747 Td -(1646 ) 21.8426 Tj -0 -474.668 Td -(1647 ) 21.8426 Tj -0 -484.1614 Td -(1648 ) 21.8426 Tj -0 -493.6547 Td -(1649 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 16) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/proc.c Page 2) 161.635 Tj -0 -28.4801 Td -(1650 // Print a process listing to console. For debugging.) 257.7424 Tj -0 -37.9735 Td -(1651 // Runs when user types ^P on console.) 187.8461 Tj -0 -47.4668 Td -(1652 // No lock to avoid wedging a stuck machine further.) 249.0053 Tj -0 -56.9602 Td -(1653 void) 39.3166 Tj -0 -66.4535 Td -(1654 procdump\(void\)) 83.0018 Tj -0 -75.9469 Td -(1655 {) 26.2111 Tj -0 -85.4403 Td -(1656 static char *states[] = {) 139.7925 Tj -0 -94.9336 Td -(1657 [UNUSED] "unused",) 122.3184 Tj -0 -104.427 Td -(1658 [EMBRYO] "embryo",) 122.3184 Tj -0 -113.9203 Td -(1659 [SLEEPING] "sleep ",) 122.3184 Tj -0 -123.4137 Td -(1660 [RUNNABLE] "runble",) 122.3184 Tj -0 -132.9071 Td -(1661 [RUNNING] "run ",) 122.3184 Tj -0 -142.4004 Td -(1662 [ZOMBIE] "zombie") 117.9499 Tj -0 -151.8938 Td -(1663 };) 39.3166 Tj -0 -161.3871 Td -(1664 int i;) 56.7907 Tj -0 -170.8805 Td -(1665 struct proc *p;) 96.1073 Tj -0 -180.3739 Td -(1666 char *state;) 83.0018 Tj -0 -189.8672 Td -(1667 uint pc[10];) 83.0018 Tj -0 -199.3606 Td -(1668 ) 21.8426 Tj -0 -208.8539 Td -(1669 for\(p = ptable.proc; p < &ptable.proc[NPROC]; p++\){) 253.3738 Tj -0 -218.3473 Td -(1670 if\(p->state == UNUSED\)) 135.4239 Tj -0 -227.8407 Td -(1671 continue;) 87.3703 Tj -0 -237.334 Td -(1672 if\(p->state >= 0 && p->state < NELEM\(states\) && sta\ -tes[p->state]\)) 323.2701 Tj -0 -246.8274 Td -(1673 state = states[p->state];) 157.2665 Tj -0 -256.3207 Td -(1674 else) 56.7907 Tj -0 -265.8141 Td -(1675 state = "???";) 109.2129 Tj -0 -275.3075 Td -(1676 cprintf\("%d %s %s", p->pid, state, p->name\);) 231.5313 Tj -0 -284.8008 Td -(1677 if\(p->state == SLEEPING\){) 148.5295 Tj -0 -294.2942 Td -(1678 getcallerpcs\(\(uint*\)p->context->ebp+2, pc\);) 235.8998 Tj -0 -303.7875 Td -(1679 for\(i=0; i<10 && pc[i] != 0; i++\)) 192.2146 Tj -0 -313.2809 Td -(1680 cprintf\(" %p", pc[i]\);) 152.898 Tj -0 -322.7743 Td -(1681 }) 43.6851 Tj -0 -332.2676 Td -(1682 cprintf\("\\n"\);) 100.4758 Tj -0 -341.761 Td -(1683 }) 34.9481 Tj -0 -351.2543 Td -(1684 }) 26.2111 Tj -0 -360.7477 Td -(1685 ) 21.8426 Tj -0 -370.2411 Td -(1686 ) 21.8426 Tj -0 -379.7344 Td -(1687 ) 21.8426 Tj -0 -389.2278 Td -(1688 ) 21.8426 Tj -0 -398.7211 Td -(1689 ) 21.8426 Tj -0 -408.2145 Td -(1690 ) 21.8426 Tj -0 -417.7079 Td -(1691 ) 21.8426 Tj -0 -427.2012 Td -(1692 ) 21.8426 Tj -0 -436.6946 Td -(1693 ) 21.8426 Tj -0 -446.1879 Td -(1694 ) 21.8426 Tj -0 -455.6813 Td -(1695 ) 21.8426 Tj -0 -465.1747 Td -(1696 ) 21.8426 Tj -0 -474.668 Td -(1697 ) 21.8426 Tj -0 -484.1614 Td -(1698 ) 21.8426 Tj -0 -493.6547 Td -(1699 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 16) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 24 24 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/proc.c Page 3) 161.635 Tj -0 -28.4801 Td -(1700 // Set up CPU's kernel segment descriptors.) 209.6887 Tj -0 -37.9735 Td -(1701 // Run once at boot time on each CPU.) 183.4776 Tj -0 -47.4668 Td -(1702 void) 39.3166 Tj -0 -56.9602 Td -(1703 ksegment\(void\)) 83.0018 Tj -0 -66.4535 Td -(1704 {) 26.2111 Tj -0 -75.9469 Td -(1705 struct cpu *c;) 91.7388 Tj -0 -85.4403 Td -(1706 ) 21.8426 Tj -0 -94.9336 Td -(1707 c = &cpus[cpunum\(\)];) 117.9499 Tj -0 -104.427 Td -(1708 c->gdt[SEG_KCODE] = SEG\(STA_X|STA_R, 0, 0x100000 + 64*1\ -024-1, 0\);) 314.533 Tj -0 -113.9203 Td -(1709 c->gdt[SEG_KDATA] = SEG\(STA_W, 0, 0xffffffff, 0\);) 244.6368 Tj -0 -123.4137 Td -(1710 c->gdt[SEG_KCPU] = SEG\(STA_W, &c->cpu, 8, 0\);) 227.1628 Tj -0 -132.9071 Td -(1711 lgdt\(c->gdt, sizeof\(c->gdt\)\);) 157.2665 Tj -0 -142.4004 Td -(1712 loadgs\(SEG_KCPU << 3\);) 126.6869 Tj -0 -151.8938 Td -(1713 ) 21.8426 Tj -0 -161.3871 Td -(1714 // Initialize cpu-local storage.) 170.3721 Tj -0 -170.8805 Td -(1715 cpu = c;) 65.5277 Tj -0 -180.3739 Td -(1716 proc = 0;) 69.8962 Tj -0 -189.8672 Td -(1717 }) 26.2111 Tj -0 -199.3606 Td -(1718 ) 21.8426 Tj -0 -208.8539 Td -(1719 // Set up CPU's segment descriptors and current process ta\ -sk state.) 314.533 Tj -0 -218.3473 Td -(1720 void) 39.3166 Tj -0 -227.8407 Td -(1721 usegment\(void\)) 83.0018 Tj -0 -237.334 Td -(1722 {) 26.2111 Tj -0 -246.8274 Td -(1723 pushcli\(\);) 74.2647 Tj -0 -256.3207 Td -(1724 cpu->gdt[SEG_UCODE] = SEG\(STA_X|STA_R, proc->mem, proc-\ ->sz-1, DPL_USER\);) 345.1126 Tj -0 -265.8141 Td -(1725 cpu->gdt[SEG_UDATA] = SEG\(STA_W, proc->mem, proc->sz-1,\ - DPL_USER\);) 318.9016 Tj -0 -275.3075 Td -(1726 cpu->gdt[SEG_TSS] = SEG16\(STS_T32A, &cpu->ts, sizeof\(c\ -pu->ts\)-1, 0\);) 327.6386 Tj -0 -284.8008 Td -(1727 cpu->gdt[SEG_TSS].s = 0;) 135.4239 Tj -0 -294.2942 Td -(1728 cpu->ts.ss0 = SEG_KDATA << 3;) 157.2665 Tj -0 -303.7875 Td -(1729 cpu->ts.esp0 = \(uint\)proc->kstack + KSTACKSIZE;) 235.8998 Tj -0 -313.2809 Td -(1730 ltr\(SEG_TSS << 3\);) 109.2129 Tj -0 -322.7743 Td -(1731 popcli\(\);) 69.8962 Tj -0 -332.2676 Td -(1732 }) 26.2111 Tj -0 -341.761 Td -(1733 ) 21.8426 Tj -0 -351.2543 Td -(1734 ) 21.8426 Tj -0 -360.7477 Td -(1735 ) 21.8426 Tj -0 -370.2411 Td -(1736 ) 21.8426 Tj -0 -379.7344 Td -(1737 ) 21.8426 Tj -0 -389.2278 Td -(1738 ) 21.8426 Tj -0 -398.7211 Td -(1739 ) 21.8426 Tj -0 -408.2145 Td -(1740 ) 21.8426 Tj -0 -417.7079 Td -(1741 ) 21.8426 Tj -0 -427.2012 Td -(1742 ) 21.8426 Tj -0 -436.6946 Td -(1743 ) 21.8426 Tj -0 -446.1879 Td -(1744 ) 21.8426 Tj -0 -455.6813 Td -(1745 ) 21.8426 Tj -0 -465.1747 Td -(1746 ) 21.8426 Tj -0 -474.668 Td -(1747 ) 21.8426 Tj -0 -484.1614 Td -(1748 ) 21.8426 Tj -0 -493.6547 Td -(1749 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 17) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/proc.c Page 4) 161.635 Tj -0 -28.4801 Td -(1750 // Look in the process table for an UNUSED proc.) 231.5313 Tj -0 -37.9735 Td -(1751 // If found, change state to EMBRYO and return it.) 240.2683 Tj -0 -47.4668 Td -(1752 // Otherwise return 0.) 117.9499 Tj -0 -56.9602 Td -(1753 static struct proc*) 104.8443 Tj -0 -66.4535 Td -(1754 allocproc\(void\)) 87.3703 Tj -0 -75.9469 Td -(1755 {) 26.2111 Tj -0 -85.4403 Td -(1756 struct proc *p;) 96.1073 Tj -0 -94.9336 Td -(1757 char *sp;) 69.8962 Tj -0 -104.427 Td -(1758 ) 21.8426 Tj -0 -113.9203 Td -(1759 acquire\(&ptable.lock\);) 126.6869 Tj -0 -123.4137 Td -(1760 for\(p = ptable.proc; p < &ptable.proc[NPROC]; p++\)) 249.0053 Tj -0 -132.9071 Td -(1761 if\(p->state == UNUSED\)) 135.4239 Tj -0 -142.4004 Td -(1762 goto found;) 96.1073 Tj -0 -151.8938 Td -(1763 release\(&ptable.lock\);) 126.6869 Tj -0 -161.3871 Td -(1764 return 0;) 69.8962 Tj -0 -170.8805 Td -(1765 ) 21.8426 Tj -0 -180.3739 Td -(1766 found:) 48.0537 Tj -0 -189.8672 Td -(1767 p->state = EMBRYO;) 109.2129 Tj -0 -199.3606 Td -(1768 p->pid = nextpid++;) 113.5814 Tj -0 -208.8539 Td -(1769 release\(&ptable.lock\);) 126.6869 Tj -0 -218.3473 Td -(1770 ) 21.8426 Tj -0 -227.8407 Td -(1771 // Allocate kernel stack if necessary.) 196.5831 Tj -0 -237.334 Td -(1772 if\(\(p->kstack = kalloc\(KSTACKSIZE\)\) == 0\){) 214.0572 Tj -0 -246.8274 Td -(1773 p->state = UNUSED;) 117.9499 Tj -0 -256.3207 Td -(1774 return 0;) 78.6333 Tj -0 -265.8141 Td -(1775 }) 34.9481 Tj -0 -275.3075 Td -(1776 sp = p->kstack + KSTACKSIZE;) 152.898 Tj -0 -284.8008 Td -(1777 ) 21.8426 Tj -0 -294.2942 Td -(1778 // Leave room for trap frame.) 157.2665 Tj -0 -303.7875 Td -(1779 sp -= sizeof *p->tf;) 117.9499 Tj -0 -313.2809 Td -(1780 p->tf = \(struct trapframe*\)sp;) 161.635 Tj -0 -322.7743 Td -(1781 ) 21.8426 Tj -0 -332.2676 Td -(1782 // Set up new context to start executing at forkret,) 257.7424 Tj -0 -341.761 Td -(1783 // which returns to trapret \(see below\).) 205.3202 Tj -0 -351.2543 Td -(1784 sp -= 4;) 65.5277 Tj -0 -360.7477 Td -(1785 *\(uint*\)sp = \(uint\)trapret;) 148.5295 Tj -0 -370.2411 Td -(1786 ) 21.8426 Tj -0 -379.7344 Td -(1787 sp -= sizeof *p->context;) 139.7925 Tj -0 -389.2278 Td -(1788 p->context = \(struct context*\)sp;) 174.7406 Tj -0 -398.7211 Td -(1789 memset\(p->context, 0, sizeof *p->context\);) 214.0572 Tj -0 -408.2145 Td -(1790 p->context->eip = \(uint\)forkret;) 170.3721 Tj -0 -417.7079 Td -(1791 return p;) 69.8962 Tj -0 -427.2012 Td -(1792 }) 26.2111 Tj -0 -436.6946 Td -(1793 ) 21.8426 Tj -0 -446.1879 Td -(1794 ) 21.8426 Tj -0 -455.6813 Td -(1795 ) 21.8426 Tj -0 -465.1747 Td -(1796 ) 21.8426 Tj -0 -474.668 Td -(1797 ) 21.8426 Tj -0 -484.1614 Td -(1798 ) 21.8426 Tj -0 -493.6547 Td -(1799 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 17) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 25 25 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/proc.c Page 5) 161.635 Tj -0 -28.4801 Td -(1800 // Set up first user process.) 148.5295 Tj -0 -37.9735 Td -(1801 void) 39.3166 Tj -0 -47.4668 Td -(1802 userinit\(void\)) 83.0018 Tj -0 -56.9602 Td -(1803 {) 26.2111 Tj -0 -66.4535 Td -(1804 struct proc *p;) 96.1073 Tj -0 -75.9469 Td -(1805 extern char _binary_initcode_start[], _binary_initcode_s\ -ize[];) 301.4275 Tj -0 -85.4403 Td -(1806 ) 21.8426 Tj -0 -94.9336 Td -(1807 p = allocproc\(\);) 100.4758 Tj -0 -104.427 Td -(1808 initproc = p;) 87.3703 Tj -0 -113.9203 Td -(1809 ) 21.8426 Tj -0 -123.4137 Td -(1810 // Initialize memory from initcode.S) 187.8461 Tj -0 -132.9071 Td -(1811 p->sz = PAGE;) 87.3703 Tj -0 -142.4004 Td -(1812 p->mem = kalloc\(p->sz\);) 131.0554 Tj -0 -151.8938 Td -(1813 memset\(p->mem, 0, p->sz\);) 139.7925 Tj -0 -161.3871 Td -(1814 memmove\(p->mem, _binary_initcode_start, \(int\)_binary_\ -initcode_size\);) 327.6386 Tj -0 -170.8805 Td -(1815 ) 21.8426 Tj -0 -180.3739 Td -(1816 memset\(p->tf, 0, sizeof\(*p->tf\)\);) 174.7406 Tj -0 -189.8672 Td -(1817 p->tf->cs = \(SEG_UCODE << 3\) | DPL_USER;) 205.3202 Tj -0 -199.3606 Td -(1818 p->tf->ds = \(SEG_UDATA << 3\) | DPL_USER;) 205.3202 Tj -0 -208.8539 Td -(1819 p->tf->es = p->tf->ds;) 126.6869 Tj -0 -218.3473 Td -(1820 p->tf->ss = p->tf->ds;) 126.6869 Tj -0 -227.8407 Td -(1821 p->tf->eflags = FL_IF;) 126.6869 Tj -0 -237.334 Td -(1822 p->tf->esp = p->sz;) 113.5814 Tj -0 -246.8274 Td -(1823 p->tf->eip = 0; // beginning of initcode.S) 218.4257 Tj -0 -256.3207 Td -(1824 ) 21.8426 Tj -0 -265.8141 Td -(1825 safestrcpy\(p->name, "initcode", sizeof\(p->name\)\);) 244.6368 Tj -0 -275.3075 Td -(1826 p->cwd = namei\("/"\);) 117.9499 Tj -0 -284.8008 Td -(1827 ) 21.8426 Tj -0 -294.2942 Td -(1828 p->state = RUNNABLE;) 117.9499 Tj -0 -303.7875 Td -(1829 }) 26.2111 Tj -0 -313.2809 Td -(1830 ) 21.8426 Tj -0 -322.7743 Td -(1831 // Grow current process's memory by n bytes.) 214.0572 Tj -0 -332.2676 Td -(1832 // Return 0 on success, -1 on failure.) 187.8461 Tj -0 -341.761 Td -(1833 int) 34.9481 Tj -0 -351.2543 Td -(1834 growproc\(int n\)) 87.3703 Tj -0 -360.7477 Td -(1835 {) 26.2111 Tj -0 -370.2411 Td -(1836 char *newmem;) 87.3703 Tj -0 -379.7344 Td -(1837 ) 21.8426 Tj -0 -389.2278 Td -(1838 newmem = kalloc\(proc->sz + n\);) 161.635 Tj -0 -398.7211 Td -(1839 if\(newmem == 0\)) 96.1073 Tj -0 -408.2145 Td -(1840 return -1;) 83.0018 Tj -0 -417.7079 Td -(1841 memmove\(newmem, proc->mem, proc->sz\);) 192.2146 Tj -0 -427.2012 Td -(1842 memset\(newmem + proc->sz, 0, n\);) 170.3721 Tj -0 -436.6946 Td -(1843 kfree\(proc->mem, proc->sz\);) 148.5295 Tj -0 -446.1879 Td -(1844 proc->mem = newmem;) 113.5814 Tj -0 -455.6813 Td -(1845 proc->sz += n;) 91.7388 Tj -0 -465.1747 Td -(1846 usegment\(\);) 78.6333 Tj -0 -474.668 Td -(1847 return 0;) 69.8962 Tj -0 -484.1614 Td -(1848 }) 26.2111 Tj -0 -493.6547 Td -(1849 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 18) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/proc.c Page 6) 161.635 Tj -0 -28.4801 Td -(1850 // Create a new process copying p as the parent.) 231.5313 Tj -0 -37.9735 Td -(1851 // Sets up stack to return as if from system call.) 240.2683 Tj -0 -47.4668 Td -(1852 // Caller must set state of returned proc to RUNNABLE.) 257.7424 Tj -0 -56.9602 Td -(1853 int) 34.9481 Tj -0 -66.4535 Td -(1854 fork\(void\)) 65.5277 Tj -0 -75.9469 Td -(1855 {) 26.2111 Tj -0 -85.4403 Td -(1856 int i, pid;) 78.6333 Tj -0 -94.9336 Td -(1857 struct proc *np;) 100.4758 Tj -0 -104.427 Td -(1858 ) 21.8426 Tj -0 -113.9203 Td -(1859 // Allocate process.) 117.9499 Tj -0 -123.4137 Td -(1860 if\(\(np = allocproc\(\)\) == 0\)) 148.5295 Tj -0 -132.9071 Td -(1861 return -1;) 83.0018 Tj -0 -142.4004 Td -(1862 ) 21.8426 Tj -0 -151.8938 Td -(1863 // Copy process state from p.) 157.2665 Tj -0 -161.3871 Td -(1864 np->sz = proc->sz;) 109.2129 Tj -0 -170.8805 Td -(1865 if\(\(np->mem = kalloc\(np->sz\)\) == 0\){) 187.8461 Tj -0 -180.3739 Td -(1866 kfree\(np->kstack, KSTACKSIZE\);) 170.3721 Tj -0 -189.8672 Td -(1867 np->kstack = 0;) 104.8443 Tj -0 -199.3606 Td -(1868 np->state = UNUSED;) 122.3184 Tj -0 -208.8539 Td -(1869 return -1;) 83.0018 Tj -0 -218.3473 Td -(1870 }) 34.9481 Tj -0 -227.8407 Td -(1871 memmove\(np->mem, proc->mem, np->sz\);) 187.8461 Tj -0 -237.334 Td -(1872 np->parent = proc;) 109.2129 Tj -0 -246.8274 Td -(1873 *np->tf = *proc->tf;) 117.9499 Tj -0 -256.3207 Td -(1874 ) 21.8426 Tj -0 -265.8141 Td -(1875 // Clear %eax so that fork returns 0 in the child.) 249.0053 Tj -0 -275.3075 Td -(1876 np->tf->eax = 0;) 100.4758 Tj -0 -284.8008 Td -(1877 ) 21.8426 Tj -0 -294.2942 Td -(1878 for\(i = 0; i < NOFILE; i++\)) 148.5295 Tj -0 -303.7875 Td -(1879 if\(proc->ofile[i]\)) 117.9499 Tj -0 -313.2809 Td -(1880 np->ofile[i] = filedup\(proc->ofile[i]\);) 218.4257 Tj -0 -322.7743 Td -(1881 np->cwd = idup\(proc->cwd\);) 144.161 Tj -0 -332.2676 Td -(1882 ) 21.8426 Tj -0 -341.761 Td -(1883 pid = np->pid;) 91.7388 Tj -0 -351.2543 Td -(1884 np->state = RUNNABLE;) 122.3184 Tj -0 -360.7477 Td -(1885 ) 21.8426 Tj -0 -370.2411 Td -(1886 return pid;) 78.6333 Tj -0 -379.7344 Td -(1887 }) 26.2111 Tj -0 -389.2278 Td -(1888 ) 21.8426 Tj -0 -398.7211 Td -(1889 ) 21.8426 Tj -0 -408.2145 Td -(1890 ) 21.8426 Tj -0 -417.7079 Td -(1891 ) 21.8426 Tj -0 -427.2012 Td -(1892 ) 21.8426 Tj -0 -436.6946 Td -(1893 ) 21.8426 Tj -0 -446.1879 Td -(1894 ) 21.8426 Tj -0 -455.6813 Td -(1895 ) 21.8426 Tj -0 -465.1747 Td -(1896 ) 21.8426 Tj -0 -474.668 Td -(1897 ) 21.8426 Tj -0 -484.1614 Td -(1898 ) 21.8426 Tj -0 -493.6547 Td -(1899 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 18) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 26 26 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/proc.c Page 7) 161.635 Tj -0 -28.4801 Td -(1900 // Per-CPU process scheduler.) 148.5295 Tj -0 -37.9735 Td -(1901 // Each CPU calls scheduler\(\) after setting itself up.) 257.7424 Tj -0 -47.4668 Td -(1902 // Scheduler never returns. It loops, doing:) 218.4257 Tj -0 -56.9602 Td -(1903 // - choose a process to run) 148.5295 Tj -0 -66.4535 Td -(1904 // - swtch to start running that process) 200.9517 Tj -0 -75.9469 Td -(1905 // - eventually that process transfers control) 227.1628 Tj -0 -85.4403 Td -(1906 // via swtch back to the scheduler.) 196.5831 Tj -0 -94.9336 Td -(1907 void) 39.3166 Tj -0 -104.427 Td -(1908 scheduler\(void\)) 87.3703 Tj -0 -113.9203 Td -(1909 {) 26.2111 Tj -0 -123.4137 Td -(1910 struct proc *p;) 96.1073 Tj -0 -132.9071 Td -(1911 ) 21.8426 Tj -0 -142.4004 Td -(1912 for\(;;\){) 65.5277 Tj -0 -151.8938 Td -(1913 // Enable interrupts on this processor.) 209.6887 Tj -0 -161.3871 Td -(1914 sti\(\);) 65.5277 Tj -0 -170.8805 Td -(1915 ) 21.8426 Tj -0 -180.3739 Td -(1916 // Loop over process table looking for process to run.) 275.2164 Tj -0 -189.8672 Td -(1917 acquire\(&ptable.lock\);) 135.4239 Tj -0 -199.3606 Td -(1918 for\(p = ptable.proc; p < &ptable.proc[NPROC]; p++\){) 262.1109 Tj -0 -208.8539 Td -(1919 if\(p->state != RUNNABLE\)) 152.898 Tj -0 -218.3473 Td -(1920 continue;) 96.1073 Tj -0 -227.8407 Td -(1921 ) 21.8426 Tj -0 -237.334 Td -(1922 // Switch to chosen process. It is the process's jo\ -b) 279.5849 Tj -0 -246.8274 Td -(1923 // to release ptable.lock and then reacquire it) 253.3738 Tj -0 -256.3207 Td -(1924 // before jumping back to us.) 174.7406 Tj -0 -265.8141 Td -(1925 proc = p;) 87.3703 Tj -0 -275.3075 Td -(1926 usegment\(\);) 96.1073 Tj -0 -284.8008 Td -(1927 p->state = RUNNING;) 131.0554 Tj -0 -294.2942 Td -(1928 swtch\(&cpu->scheduler, proc->context\);) 214.0572 Tj -0 -303.7875 Td -(1929 ) 21.8426 Tj -0 -313.2809 Td -(1930 // Process is done running for now.) 200.9517 Tj -0 -322.7743 Td -(1931 // It should have changed its p->state before coming\ - back.) 301.4275 Tj -0 -332.2676 Td -(1932 proc = 0;) 87.3703 Tj -0 -341.761 Td -(1933 }) 43.6851 Tj -0 -351.2543 Td -(1934 release\(&ptable.lock\);) 135.4239 Tj -0 -360.7477 Td -(1935 ) 21.8426 Tj -0 -370.2411 Td -(1936 }) 34.9481 Tj -0 -379.7344 Td -(1937 }) 26.2111 Tj -0 -389.2278 Td -(1938 ) 21.8426 Tj -0 -398.7211 Td -(1939 ) 21.8426 Tj -0 -408.2145 Td -(1940 ) 21.8426 Tj -0 -417.7079 Td -(1941 ) 21.8426 Tj -0 -427.2012 Td -(1942 ) 21.8426 Tj -0 -436.6946 Td -(1943 ) 21.8426 Tj -0 -446.1879 Td -(1944 ) 21.8426 Tj -0 -455.6813 Td -(1945 ) 21.8426 Tj -0 -465.1747 Td -(1946 ) 21.8426 Tj -0 -474.668 Td -(1947 ) 21.8426 Tj -0 -484.1614 Td -(1948 ) 21.8426 Tj -0 -493.6547 Td -(1949 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 19) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/proc.c Page 8) 161.635 Tj -0 -28.4801 Td -(1950 // Enter scheduler. Must hold only ptable.lock) 227.1628 Tj -0 -37.9735 Td -(1951 // and have changed proc->state.) 161.635 Tj -0 -47.4668 Td -(1952 void) 39.3166 Tj -0 -56.9602 Td -(1953 sched\(void\)) 69.8962 Tj -0 -66.4535 Td -(1954 {) 26.2111 Tj -0 -75.9469 Td -(1955 int intena;) 78.6333 Tj -0 -85.4403 Td -(1956 ) 21.8426 Tj -0 -94.9336 Td -(1957 if\(!holding\(&ptable.lock\)\)) 144.161 Tj -0 -104.427 Td -(1958 panic\("sched ptable.lock"\);) 157.2665 Tj -0 -113.9203 Td -(1959 if\(cpu->ncli != 1\)) 109.2129 Tj -0 -123.4137 Td -(1960 panic\("sched locks"\);) 131.0554 Tj -0 -132.9071 Td -(1961 if\(proc->state == RUNNING\)) 144.161 Tj -0 -142.4004 Td -(1962 panic\("sched running"\);) 139.7925 Tj -0 -151.8938 Td -(1963 if\(readeflags\(\)&FL_IF\)) 126.6869 Tj -0 -161.3871 Td -(1964 panic\("sched interruptible"\);) 166.0035 Tj -0 -170.8805 Td -(1965 ) 21.8426 Tj -0 -180.3739 Td -(1966 intena = cpu->intena;) 122.3184 Tj -0 -189.8672 Td -(1967 swtch\(&proc->context, cpu->scheduler\);) 196.5831 Tj -0 -199.3606 Td -(1968 cpu->intena = intena;) 122.3184 Tj -0 -208.8539 Td -(1969 }) 26.2111 Tj -0 -218.3473 Td -(1970 ) 21.8426 Tj -0 -227.8407 Td -(1971 // Give up the CPU for one scheduling round.) 214.0572 Tj -0 -237.334 Td -(1972 void) 39.3166 Tj -0 -246.8274 Td -(1973 yield\(void\)) 69.8962 Tj -0 -256.3207 Td -(1974 {) 26.2111 Tj -0 -265.8141 Td -(1975 acquire\(&ptable.lock\); ) 135.4239 Tj -0 -275.3075 Td -(1976 proc->state = RUNNABLE;) 131.0554 Tj -0 -284.8008 Td -(1977 sched\(\);) 65.5277 Tj -0 -294.2942 Td -(1978 release\(&ptable.lock\);) 126.6869 Tj -0 -303.7875 Td -(1979 }) 26.2111 Tj -0 -313.2809 Td -(1980 ) 21.8426 Tj -0 -322.7743 Td -(1981 // A fork child's very first scheduling by scheduler\(\)) 257.7424 Tj -0 -332.2676 Td -(1982 // will swtch here. "Return" to user space.) 214.0572 Tj -0 -341.761 Td -(1983 void) 39.3166 Tj -0 -351.2543 Td -(1984 forkret\(void\)) 78.6333 Tj -0 -360.7477 Td -(1985 {) 26.2111 Tj -0 -370.2411 Td -(1986 // Still holding ptable.lock from scheduler.) 222.7942 Tj -0 -379.7344 Td -(1987 release\(&ptable.lock\);) 126.6869 Tj -0 -389.2278 Td -(1988 ) 21.8426 Tj -0 -398.7211 Td -(1989 // Return to "caller", actually trapret \(see allocproc\)\ -.) 275.2164 Tj -0 -408.2145 Td -(1990 }) 26.2111 Tj -0 -417.7079 Td -(1991 ) 21.8426 Tj -0 -427.2012 Td -(1992 ) 21.8426 Tj -0 -436.6946 Td -(1993 ) 21.8426 Tj -0 -446.1879 Td -(1994 ) 21.8426 Tj -0 -455.6813 Td -(1995 ) 21.8426 Tj -0 -465.1747 Td -(1996 ) 21.8426 Tj -0 -474.668 Td -(1997 ) 21.8426 Tj -0 -484.1614 Td -(1998 ) 21.8426 Tj -0 -493.6547 Td -(1999 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 19) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 27 27 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/proc.c Page 9) 161.635 Tj -0 -28.4801 Td -(2000 // Atomically release lock and sleep on chan.) 218.4257 Tj -0 -37.9735 Td -(2001 // Reacquires lock when awakened.) 166.0035 Tj -0 -47.4668 Td -(2002 void) 39.3166 Tj -0 -56.9602 Td -(2003 sleep\(void *chan, struct spinlock *lk\)) 187.8461 Tj -0 -66.4535 Td -(2004 {) 26.2111 Tj -0 -75.9469 Td -(2005 if\(proc == 0\)) 87.3703 Tj -0 -85.4403 Td -(2006 panic\("sleep"\);) 104.8443 Tj -0 -94.9336 Td -(2007 ) 21.8426 Tj -0 -104.427 Td -(2008 if\(lk == 0\)) 78.6333 Tj -0 -113.9203 Td -(2009 panic\("sleep without lk"\);) 152.898 Tj -0 -123.4137 Td -(2010 ) 21.8426 Tj -0 -132.9071 Td -(2011 // Must acquire ptable.lock in order to) 200.9517 Tj -0 -142.4004 Td -(2012 // change p->state and then call sched.) 200.9517 Tj -0 -151.8938 Td -(2013 // Once we hold ptable.lock, we can be) 196.5831 Tj -0 -161.3871 Td -(2014 // guaranteed that we won't miss any wakeup) 218.4257 Tj -0 -170.8805 Td -(2015 // \(wakeup runs with ptable.lock locked\),) 209.6887 Tj -0 -180.3739 Td -(2016 // so it's okay to release lk.) 161.635 Tj -0 -189.8672 Td -(2017 if\(lk != &ptable.lock\){ ) 139.7925 Tj -0 -199.3606 Td -(2018 acquire\(&ptable.lock\); ) 144.161 Tj -0 -208.8539 Td -(2019 release\(lk\);) 91.7388 Tj -0 -218.3473 Td -(2020 }) 34.9481 Tj -0 -227.8407 Td -(2021 ) 21.8426 Tj -0 -237.334 Td -(2022 // Go to sleep.) 96.1073 Tj -0 -246.8274 Td -(2023 proc->chan = chan;) 109.2129 Tj -0 -256.3207 Td -(2024 proc->state = SLEEPING;) 131.0554 Tj -0 -265.8141 Td -(2025 sched\(\);) 65.5277 Tj -0 -275.3075 Td -(2026 ) 21.8426 Tj -0 -284.8008 Td -(2027 // Tidy up.) 78.6333 Tj -0 -294.2942 Td -(2028 proc->chan = 0;) 96.1073 Tj -0 -303.7875 Td -(2029 ) 21.8426 Tj -0 -313.2809 Td -(2030 // Reacquire original lock.) 148.5295 Tj -0 -322.7743 Td -(2031 if\(lk != &ptable.lock\){ ) 139.7925 Tj -0 -332.2676 Td -(2032 release\(&ptable.lock\);) 135.4239 Tj -0 -341.761 Td -(2033 acquire\(lk\);) 91.7388 Tj -0 -351.2543 Td -(2034 }) 34.9481 Tj -0 -360.7477 Td -(2035 }) 26.2111 Tj -0 -370.2411 Td -(2036 ) 21.8426 Tj -0 -379.7344 Td -(2037 ) 21.8426 Tj -0 -389.2278 Td -(2038 ) 21.8426 Tj -0 -398.7211 Td -(2039 ) 21.8426 Tj -0 -408.2145 Td -(2040 ) 21.8426 Tj -0 -417.7079 Td -(2041 ) 21.8426 Tj -0 -427.2012 Td -(2042 ) 21.8426 Tj -0 -436.6946 Td -(2043 ) 21.8426 Tj -0 -446.1879 Td -(2044 ) 21.8426 Tj -0 -455.6813 Td -(2045 ) 21.8426 Tj -0 -465.1747 Td -(2046 ) 21.8426 Tj -0 -474.668 Td -(2047 ) 21.8426 Tj -0 -484.1614 Td -(2048 ) 21.8426 Tj -0 -493.6547 Td -(2049 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 20) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/proc.c Page 10) 166.0035 Tj -0 -28.4801 Td -(2050 // Wake up all processes sleeping on chan.) 205.3202 Tj -0 -37.9735 Td -(2051 // The ptable lock must be held.) 161.635 Tj -0 -47.4668 Td -(2052 static void) 69.8962 Tj -0 -56.9602 Td -(2053 wakeup1\(void *chan\)) 104.8443 Tj -0 -66.4535 Td -(2054 {) 26.2111 Tj -0 -75.9469 Td -(2055 struct proc *p;) 96.1073 Tj -0 -85.4403 Td -(2056 ) 21.8426 Tj -0 -94.9336 Td -(2057 for\(p = ptable.proc; p < &ptable.proc[NPROC]; p++\)) 249.0053 Tj -0 -104.427 Td -(2058 if\(p->state == SLEEPING && p->chan == chan\)) 227.1628 Tj -0 -113.9203 Td -(2059 p->state = RUNNABLE;) 135.4239 Tj -0 -123.4137 Td -(2060 }) 26.2111 Tj -0 -132.9071 Td -(2061 ) 21.8426 Tj -0 -142.4004 Td -(2062 // Wake up all processes sleeping on chan.) 205.3202 Tj -0 -151.8938 Td -(2063 void) 39.3166 Tj -0 -161.3871 Td -(2064 wakeup\(void *chan\)) 100.4758 Tj -0 -170.8805 Td -(2065 {) 26.2111 Tj -0 -180.3739 Td -(2066 acquire\(&ptable.lock\);) 126.6869 Tj -0 -189.8672 Td -(2067 wakeup1\(chan\);) 91.7388 Tj -0 -199.3606 Td -(2068 release\(&ptable.lock\);) 126.6869 Tj -0 -208.8539 Td -(2069 }) 26.2111 Tj -0 -218.3473 Td -(2070 ) 21.8426 Tj -0 -227.8407 Td -(2071 // Kill the process with the given pid.) 192.2146 Tj -0 -237.334 Td -(2072 // Process won't exit until it returns) 187.8461 Tj -0 -246.8274 Td -(2073 // to user space \(see trap in trap.c\).) 187.8461 Tj -0 -256.3207 Td -(2074 int) 34.9481 Tj -0 -265.8141 Td -(2075 kill\(int pid\)) 78.6333 Tj -0 -275.3075 Td -(2076 {) 26.2111 Tj -0 -284.8008 Td -(2077 struct proc *p;) 96.1073 Tj -0 -294.2942 Td -(2078 ) 21.8426 Tj -0 -303.7875 Td -(2079 acquire\(&ptable.lock\);) 126.6869 Tj -0 -313.2809 Td -(2080 for\(p = ptable.proc; p < &ptable.proc[NPROC]; p++\){) 253.3738 Tj -0 -322.7743 Td -(2081 if\(p->pid == pid\){) 117.9499 Tj -0 -332.2676 Td -(2082 p->killed = 1;) 109.2129 Tj -0 -341.761 Td -(2083 // Wake process from sleep if necessary.) 222.7942 Tj -0 -351.2543 Td -(2084 if\(p->state == SLEEPING\)) 152.898 Tj -0 -360.7477 Td -(2085 p->state = RUNNABLE;) 144.161 Tj -0 -370.2411 Td -(2086 release\(&ptable.lock\);) 144.161 Tj -0 -379.7344 Td -(2087 return 0;) 87.3703 Tj -0 -389.2278 Td -(2088 }) 43.6851 Tj -0 -398.7211 Td -(2089 }) 34.9481 Tj -0 -408.2145 Td -(2090 release\(&ptable.lock\);) 126.6869 Tj -0 -417.7079 Td -(2091 return -1;) 74.2647 Tj -0 -427.2012 Td -(2092 }) 26.2111 Tj -0 -436.6946 Td -(2093 ) 21.8426 Tj -0 -446.1879 Td -(2094 ) 21.8426 Tj -0 -455.6813 Td -(2095 ) 21.8426 Tj -0 -465.1747 Td -(2096 ) 21.8426 Tj -0 -474.668 Td -(2097 ) 21.8426 Tj -0 -484.1614 Td -(2098 ) 21.8426 Tj -0 -493.6547 Td -(2099 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 20) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 28 28 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/proc.c Page 11) 166.0035 Tj -0 -28.4801 Td -(2100 // Exit the current process. Does not return.) 222.7942 Tj -0 -37.9735 Td -(2101 // An exited process remains in the zombie state) 231.5313 Tj -0 -47.4668 Td -(2102 // until its parent calls wait\(\) to find out it exited.) 262.1109 Tj -0 -56.9602 Td -(2103 void) 39.3166 Tj -0 -66.4535 Td -(2104 exit\(void\)) 65.5277 Tj -0 -75.9469 Td -(2105 {) 26.2111 Tj -0 -85.4403 Td -(2106 struct proc *p;) 96.1073 Tj -0 -94.9336 Td -(2107 int fd;) 61.1592 Tj -0 -104.427 Td -(2108 ) 21.8426 Tj -0 -113.9203 Td -(2109 if\(proc == initproc\)) 117.9499 Tj -0 -123.4137 Td -(2110 panic\("init exiting"\);) 135.4239 Tj -0 -132.9071 Td -(2111 ) 21.8426 Tj -0 -142.4004 Td -(2112 // Close all open files.) 135.4239 Tj -0 -151.8938 Td -(2113 for\(fd = 0; fd < NOFILE; fd++\){) 166.0035 Tj -0 -161.3871 Td -(2114 if\(proc->ofile[fd]\){) 126.6869 Tj -0 -170.8805 Td -(2115 fileclose\(proc->ofile[fd]\);) 166.0035 Tj -0 -180.3739 Td -(2116 proc->ofile[fd] = 0;) 135.4239 Tj -0 -189.8672 Td -(2117 }) 43.6851 Tj -0 -199.3606 Td -(2118 }) 34.9481 Tj -0 -208.8539 Td -(2119 ) 21.8426 Tj -0 -218.3473 Td -(2120 iput\(proc->cwd\);) 100.4758 Tj -0 -227.8407 Td -(2121 proc->cwd = 0;) 91.7388 Tj -0 -237.334 Td -(2122 ) 21.8426 Tj -0 -246.8274 Td -(2123 acquire\(&ptable.lock\);) 126.6869 Tj -0 -256.3207 Td -(2124 ) 21.8426 Tj -0 -265.8141 Td -(2125 // Parent might be sleeping in wait\(\).) 196.5831 Tj -0 -275.3075 Td -(2126 wakeup1\(proc->parent\);) 126.6869 Tj -0 -284.8008 Td -(2127 ) 21.8426 Tj -0 -294.2942 Td -(2128 // Pass abandoned children to init.) 183.4776 Tj -0 -303.7875 Td -(2129 for\(p = ptable.proc; p < &ptable.proc[NPROC]; p++\){) 253.3738 Tj -0 -313.2809 Td -(2130 if\(p->parent == proc\){) 135.4239 Tj -0 -322.7743 Td -(2131 p->parent = initproc;) 139.7925 Tj -0 -332.2676 Td -(2132 if\(p->state == ZOMBIE\)) 144.161 Tj -0 -341.761 Td -(2133 wakeup1\(initproc\);) 135.4239 Tj -0 -351.2543 Td -(2134 }) 43.6851 Tj -0 -360.7477 Td -(2135 }) 34.9481 Tj -0 -370.2411 Td -(2136 ) 21.8426 Tj -0 -379.7344 Td -(2137 // Jump into the scheduler, never to return.) 222.7942 Tj -0 -389.2278 Td -(2138 proc->state = ZOMBIE;) 122.3184 Tj -0 -398.7211 Td -(2139 sched\(\);) 65.5277 Tj -0 -408.2145 Td -(2140 panic\("zombie exit"\);) 122.3184 Tj -0 -417.7079 Td -(2141 }) 26.2111 Tj -0 -427.2012 Td -(2142 ) 21.8426 Tj -0 -436.6946 Td -(2143 ) 21.8426 Tj -0 -446.1879 Td -(2144 ) 21.8426 Tj -0 -455.6813 Td -(2145 ) 21.8426 Tj -0 -465.1747 Td -(2146 ) 21.8426 Tj -0 -474.668 Td -(2147 ) 21.8426 Tj -0 -484.1614 Td -(2148 ) 21.8426 Tj -0 -493.6547 Td -(2149 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 21) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/proc.c Page 12) 166.0035 Tj -0 -28.4801 Td -(2150 // Wait for a child process to exit and return its pid.) 262.1109 Tj -0 -37.9735 Td -(2151 // Return -1 if this process has no children.) 218.4257 Tj -0 -47.4668 Td -(2152 int) 34.9481 Tj -0 -56.9602 Td -(2153 wait\(void\)) 65.5277 Tj -0 -66.4535 Td -(2154 {) 26.2111 Tj -0 -75.9469 Td -(2155 struct proc *p;) 96.1073 Tj -0 -85.4403 Td -(2156 int havekids, pid;) 109.2129 Tj -0 -94.9336 Td -(2157 ) 21.8426 Tj -0 -104.427 Td -(2158 acquire\(&ptable.lock\);) 126.6869 Tj -0 -113.9203 Td -(2159 for\(;;\){) 65.5277 Tj -0 -123.4137 Td -(2160 // Scan through table looking for zombie children.) 257.7424 Tj -0 -132.9071 Td -(2161 havekids = 0;) 96.1073 Tj -0 -142.4004 Td -(2162 for\(p = ptable.proc; p < &ptable.proc[NPROC]; p++\){) 262.1109 Tj -0 -151.8938 Td -(2163 if\(p->parent != proc\)) 139.7925 Tj -0 -161.3871 Td -(2164 continue;) 96.1073 Tj -0 -170.8805 Td -(2165 havekids = 1;) 104.8443 Tj -0 -180.3739 Td -(2166 if\(p->state == ZOMBIE\){) 148.5295 Tj -0 -189.8672 Td -(2167 // Found one.) 113.5814 Tj -0 -199.3606 Td -(2168 pid = p->pid;) 113.5814 Tj -0 -208.8539 Td -(2169 kfree\(p->mem, p->sz\);) 148.5295 Tj -0 -218.3473 Td -(2170 kfree\(p->kstack, KSTACKSIZE\);) 183.4776 Tj -0 -227.8407 Td -(2171 p->state = UNUSED;) 135.4239 Tj -0 -237.334 Td -(2172 p->pid = 0;) 104.8443 Tj -0 -246.8274 Td -(2173 p->parent = 0;) 117.9499 Tj -0 -256.3207 Td -(2174 p->name[0] = 0;) 122.3184 Tj -0 -265.8141 Td -(2175 p->killed = 0;) 117.9499 Tj -0 -275.3075 Td -(2176 release\(&ptable.lock\);) 152.898 Tj -0 -284.8008 Td -(2177 return pid;) 104.8443 Tj -0 -294.2942 Td -(2178 }) 52.4222 Tj -0 -303.7875 Td -(2179 }) 43.6851 Tj -0 -313.2809 Td -(2180 ) 21.8426 Tj -0 -322.7743 Td -(2181 // No point waiting if we don't have any children.) 257.7424 Tj -0 -332.2676 Td -(2182 if\(!havekids || proc->killed\){) 170.3721 Tj -0 -341.761 Td -(2183 release\(&ptable.lock\);) 144.161 Tj -0 -351.2543 Td -(2184 return -1;) 91.7388 Tj -0 -360.7477 Td -(2185 }) 43.6851 Tj -0 -370.2411 Td -(2186 ) 21.8426 Tj -0 -379.7344 Td -(2187 // Wait for children to exit. \(See wakeup1 call in p\ -roc_exit.\)) 314.533 Tj -0 -389.2278 Td -(2188 sleep\(proc, &ptable.lock\); ) 161.635 Tj -0 -398.7211 Td -(2189 }) 34.9481 Tj -0 -408.2145 Td -(2190 }) 26.2111 Tj -0 -417.7079 Td -(2191 ) 21.8426 Tj -0 -427.2012 Td -(2192 ) 21.8426 Tj -0 -436.6946 Td -(2193 ) 21.8426 Tj -0 -446.1879 Td -(2194 ) 21.8426 Tj -0 -455.6813 Td -(2195 ) 21.8426 Tj -0 -465.1747 Td -(2196 ) 21.8426 Tj -0 -474.668 Td -(2197 ) 21.8426 Tj -0 -484.1614 Td -(2198 ) 21.8426 Tj -0 -493.6547 Td -(2199 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 21) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 29 29 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/swtch.S Page 1) 166.0035 Tj -0 -28.4801 Td -(2200 # Context switch) 91.7388 Tj -0 -37.9735 Td -(2201 #) 26.2111 Tj -0 -47.4668 Td -(2202 # void swtch\(struct context **old, struct context *new\)\ -;) 275.2164 Tj -0 -56.9602 Td -(2203 #) 26.2111 Tj -0 -66.4535 Td -(2204 # Save current register context in old) 187.8461 Tj -0 -75.9469 Td -(2205 # and then load register context from new.) 205.3202 Tj -0 -85.4403 Td -(2206 ) 21.8426 Tj -0 -94.9336 Td -(2207 .globl swtch) 74.2647 Tj -0 -104.427 Td -(2208 swtch:) 48.0537 Tj -0 -113.9203 Td -(2209 movl 4\(%esp\), %eax) 109.2129 Tj -0 -123.4137 Td -(2210 movl 8\(%esp\), %edx) 109.2129 Tj -0 -132.9071 Td -(2211 ) 21.8426 Tj -0 -142.4004 Td -(2212 # Save old callee-save registers) 170.3721 Tj -0 -151.8938 Td -(2213 pushl %ebp) 74.2647 Tj -0 -161.3871 Td -(2214 pushl %ebx) 74.2647 Tj -0 -170.8805 Td -(2215 pushl %esi) 74.2647 Tj -0 -180.3739 Td -(2216 pushl %edi) 74.2647 Tj -0 -189.8672 Td -(2217 ) 21.8426 Tj -0 -199.3606 Td -(2218 # Switch stacks) 96.1073 Tj -0 -208.8539 Td -(2219 movl %esp, \(%eax\)) 104.8443 Tj -0 -218.3473 Td -(2220 movl %edx, %esp) 96.1073 Tj -0 -227.8407 Td -(2221 ) 21.8426 Tj -0 -237.334 Td -(2222 # Load new callee-save registers) 170.3721 Tj -0 -246.8274 Td -(2223 popl %edi) 69.8962 Tj -0 -256.3207 Td -(2224 popl %esi) 69.8962 Tj -0 -265.8141 Td -(2225 popl %ebx) 69.8962 Tj -0 -275.3075 Td -(2226 popl %ebp) 69.8962 Tj -0 -284.8008 Td -(2227 ret) 43.6851 Tj -0 -294.2942 Td -(2228 ) 21.8426 Tj -0 -303.7875 Td -(2229 ) 21.8426 Tj -0 -313.2809 Td -(2230 ) 21.8426 Tj -0 -322.7743 Td -(2231 ) 21.8426 Tj -0 -332.2676 Td -(2232 ) 21.8426 Tj -0 -341.761 Td -(2233 ) 21.8426 Tj -0 -351.2543 Td -(2234 ) 21.8426 Tj -0 -360.7477 Td -(2235 ) 21.8426 Tj -0 -370.2411 Td -(2236 ) 21.8426 Tj -0 -379.7344 Td -(2237 ) 21.8426 Tj -0 -389.2278 Td -(2238 ) 21.8426 Tj -0 -398.7211 Td -(2239 ) 21.8426 Tj -0 -408.2145 Td -(2240 ) 21.8426 Tj -0 -417.7079 Td -(2241 ) 21.8426 Tj -0 -427.2012 Td -(2242 ) 21.8426 Tj -0 -436.6946 Td -(2243 ) 21.8426 Tj -0 -446.1879 Td -(2244 ) 21.8426 Tj -0 -455.6813 Td -(2245 ) 21.8426 Tj -0 -465.1747 Td -(2246 ) 21.8426 Tj -0 -474.668 Td -(2247 ) 21.8426 Tj -0 -484.1614 Td -(2248 ) 21.8426 Tj -0 -493.6547 Td -(2249 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 22) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/kalloc.c Page 1) 170.3721 Tj -0 -28.4801 Td -(2250 // Physical memory allocator, intended to allocate) 240.2683 Tj -0 -37.9735 Td -(2251 // memory for user processes. Allocates in 4096-byte "page\ -s".) 288.322 Tj -0 -47.4668 Td -(2252 // Free list is kept sorted and combines adjacent pages in\ -to) 283.9534 Tj -0 -56.9602 Td -(2253 // long runs, to make it easier to allocate big segments.) 270.8479 Tj -0 -66.4535 Td -(2254 // One reason the page size is 4k is that the x86 segment \ -size) 292.6905 Tj -0 -75.9469 Td -(2255 // granularity is 4k.) 113.5814 Tj -0 -85.4403 Td -(2256 ) 21.8426 Tj -0 -94.9336 Td -(2257 #include "types.h") 100.4758 Tj -0 -104.427 Td -(2258 #include "defs.h") 96.1073 Tj -0 -113.9203 Td -(2259 #include "param.h") 100.4758 Tj -0 -123.4137 Td -(2260 #include "spinlock.h") 113.5814 Tj -0 -132.9071 Td -(2261 ) 21.8426 Tj -0 -142.4004 Td -(2262 struct run {) 74.2647 Tj -0 -151.8938 Td -(2263 struct run *next;) 104.8443 Tj -0 -161.3871 Td -(2264 int len; // bytes) 104.8443 Tj -0 -170.8805 Td -(2265 };) 30.5796 Tj -0 -180.3739 Td -(2266 ) 21.8426 Tj -0 -189.8672 Td -(2267 struct {) 56.7907 Tj -0 -199.3606 Td -(2268 struct spinlock lock;) 122.3184 Tj -0 -208.8539 Td -(2269 struct run *freelist;) 122.3184 Tj -0 -218.3473 Td -(2270 } kmem;) 52.4222 Tj -0 -227.8407 Td -(2271 ) 21.8426 Tj -0 -237.334 Td -(2272 // Initialize free list of physical pages.) 205.3202 Tj -0 -246.8274 Td -(2273 // This code cheats by just considering one megabyte of) 262.1109 Tj -0 -256.3207 Td -(2274 // pages after end. Real systems would determine the) 253.3738 Tj -0 -265.8141 Td -(2275 // amount of memory available in the system and use it all\ -.) 279.5849 Tj -0 -275.3075 Td -(2276 void) 39.3166 Tj -0 -284.8008 Td -(2277 kinit\(void\)) 69.8962 Tj -0 -294.2942 Td -(2278 {) 26.2111 Tj -0 -303.7875 Td -(2279 extern char end[];) 109.2129 Tj -0 -313.2809 Td -(2280 uint len;) 69.8962 Tj -0 -322.7743 Td -(2281 char *p;) 65.5277 Tj -0 -332.2676 Td -(2282 ) 21.8426 Tj -0 -341.761 Td -(2283 initlock\(&kmem.lock, "kmem"\);) 157.2665 Tj -0 -351.2543 Td -(2284 p = \(char*\)\(\(\(uint\)end + PAGE\) & ~\(PAGE-1\)\);) 222.7942 Tj -0 -360.7477 Td -(2285 len = 256*PAGE; // assume computer has 256 pages of RAM,\ - 1 MB) 297.059 Tj -0 -370.2411 Td -(2286 cprintf\("mem = %d\\n", len\);) 148.5295 Tj -0 -379.7344 Td -(2287 kfree\(p, len\);) 91.7388 Tj -0 -389.2278 Td -(2288 }) 26.2111 Tj -0 -398.7211 Td -(2289 ) 21.8426 Tj -0 -408.2145 Td -(2290 ) 21.8426 Tj -0 -417.7079 Td -(2291 ) 21.8426 Tj -0 -427.2012 Td -(2292 ) 21.8426 Tj -0 -436.6946 Td -(2293 ) 21.8426 Tj -0 -446.1879 Td -(2294 ) 21.8426 Tj -0 -455.6813 Td -(2295 ) 21.8426 Tj -0 -465.1747 Td -(2296 ) 21.8426 Tj -0 -474.668 Td -(2297 ) 21.8426 Tj -0 -484.1614 Td -(2298 ) 21.8426 Tj -0 -493.6547 Td -(2299 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 22) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 30 30 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/kalloc.c Page 2) 170.3721 Tj -0 -28.4801 Td -(2300 // Free the len bytes of memory pointed at by v,) 231.5313 Tj -0 -37.9735 Td -(2301 // which normally should have been returned by a) 231.5313 Tj -0 -47.4668 Td -(2302 // call to kalloc\(len\). \(The exception is when) 227.1628 Tj -0 -56.9602 Td -(2303 // initializing the allocator; see kinit above.\)) 231.5313 Tj -0 -66.4535 Td -(2304 void) 39.3166 Tj -0 -75.9469 Td -(2305 kfree\(char *v, int len\)) 122.3184 Tj -0 -85.4403 Td -(2306 {) 26.2111 Tj -0 -94.9336 Td -(2307 struct run *r, *rend, **rp, *p, *pend;) 196.5831 Tj -0 -104.427 Td -(2308 ) 21.8426 Tj -0 -113.9203 Td -(2309 if\(len <= 0 || len % PAGE\)) 144.161 Tj -0 -123.4137 Td -(2310 panic\("kfree"\);) 104.8443 Tj -0 -132.9071 Td -(2311 ) 21.8426 Tj -0 -142.4004 Td -(2312 // Fill with junk to catch dangling refs.) 209.6887 Tj -0 -151.8938 Td -(2313 memset\(v, 1, len\);) 109.2129 Tj -0 -161.3871 Td -(2314 ) 21.8426 Tj -0 -170.8805 Td -(2315 acquire\(&kmem.lock\);) 117.9499 Tj -0 -180.3739 Td -(2316 p = \(struct run*\)v;) 113.5814 Tj -0 -189.8672 Td -(2317 pend = \(struct run*\)\(v + len\);) 161.635 Tj -0 -199.3606 Td -(2318 for\(rp=&kmem.freelist; \(r=*rp\) != 0 && r <= pend; rp=\ -&r->next\){) 305.796 Tj -0 -208.8539 Td -(2319 rend = \(struct run*\)\(\(char*\)r + r->len\);) 214.0572 Tj -0 -218.3473 Td -(2320 if\(r <= p && p < rend\)) 135.4239 Tj -0 -227.8407 Td -(2321 panic\("freeing free page"\);) 166.0035 Tj -0 -237.334 Td -(2322 if\(rend == p\){ // r before p: expand r to include p) 266.4794 Tj -0 -246.8274 Td -(2323 r->len += len;) 109.2129 Tj -0 -256.3207 Td -(2324 if\(r->next && r->next == pend\){ // r now next to \ -r->next?) 301.4275 Tj -0 -265.8141 Td -(2325 r->len += r->next->len;) 157.2665 Tj -0 -275.3075 Td -(2326 r->next = r->next->next;) 161.635 Tj -0 -284.8008 Td -(2327 }) 52.4222 Tj -0 -294.2942 Td -(2328 goto out;) 87.3703 Tj -0 -303.7875 Td -(2329 }) 43.6851 Tj -0 -313.2809 Td -(2330 if\(pend == r\){ // p before r: expand p to include, \ -replace r) 305.796 Tj -0 -322.7743 Td -(2331 p->len = len + r->len;) 144.161 Tj -0 -332.2676 Td -(2332 p->next = r->next;) 126.6869 Tj -0 -341.761 Td -(2333 *rp = p;) 83.0018 Tj -0 -351.2543 Td -(2334 goto out;) 87.3703 Tj -0 -360.7477 Td -(2335 }) 43.6851 Tj -0 -370.2411 Td -(2336 }) 34.9481 Tj -0 -379.7344 Td -(2337 // Insert p before r in list.) 157.2665 Tj -0 -389.2278 Td -(2338 p->len = len;) 87.3703 Tj -0 -398.7211 Td -(2339 p->next = r;) 83.0018 Tj -0 -408.2145 Td -(2340 *rp = p;) 65.5277 Tj -0 -417.7079 Td -(2341 ) 21.8426 Tj -0 -427.2012 Td -(2342 out:) 43.6851 Tj -0 -436.6946 Td -(2343 release\(&kmem.lock\);) 117.9499 Tj -0 -446.1879 Td -(2344 }) 26.2111 Tj -0 -455.6813 Td -(2345 ) 21.8426 Tj -0 -465.1747 Td -(2346 ) 21.8426 Tj -0 -474.668 Td -(2347 ) 21.8426 Tj -0 -484.1614 Td -(2348 ) 21.8426 Tj -0 -493.6547 Td -(2349 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 23) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/kalloc.c Page 3) 170.3721 Tj -0 -28.4801 Td -(2350 // Allocate n bytes of physical memory.) 192.2146 Tj -0 -37.9735 Td -(2351 // Returns a kernel-segment pointer.) 179.1091 Tj -0 -47.4668 Td -(2352 // Returns 0 if the memory cannot be allocated.) 227.1628 Tj -0 -56.9602 Td -(2353 char*) 43.6851 Tj -0 -66.4535 Td -(2354 kalloc\(int n\)) 78.6333 Tj -0 -75.9469 Td -(2355 {) 26.2111 Tj -0 -85.4403 Td -(2356 char *p;) 65.5277 Tj -0 -94.9336 Td -(2357 struct run *r, **rp;) 117.9499 Tj -0 -104.427 Td -(2358 ) 21.8426 Tj -0 -113.9203 Td -(2359 if\(n % PAGE || n <= 0\)) 126.6869 Tj -0 -123.4137 Td -(2360 panic\("kalloc"\);) 109.2129 Tj -0 -132.9071 Td -(2361 ) 21.8426 Tj -0 -142.4004 Td -(2362 acquire\(&kmem.lock\);) 117.9499 Tj -0 -151.8938 Td -(2363 for\(rp=&kmem.freelist; \(r=*rp\) != 0; rp=&r->next\){) 249.0053 Tj -0 -161.3871 Td -(2364 if\(r->len >= n\){) 109.2129 Tj -0 -170.8805 Td -(2365 r->len -= n;) 100.4758 Tj -0 -180.3739 Td -(2366 p = \(char*\)r + r->len;) 144.161 Tj -0 -189.8672 Td -(2367 if\(r->len == 0\)) 113.5814 Tj -0 -199.3606 Td -(2368 *rp = r->next;) 117.9499 Tj -0 -208.8539 Td -(2369 release\(&kmem.lock\);) 135.4239 Tj -0 -218.3473 Td -(2370 return p;) 87.3703 Tj -0 -227.8407 Td -(2371 }) 43.6851 Tj -0 -237.334 Td -(2372 }) 34.9481 Tj -0 -246.8274 Td -(2373 release\(&kmem.lock\);) 117.9499 Tj -0 -256.3207 Td -(2374 ) 21.8426 Tj -0 -265.8141 Td -(2375 cprintf\("kalloc: out of memory\\n"\);) 183.4776 Tj -0 -275.3075 Td -(2376 return 0;) 69.8962 Tj -0 -284.8008 Td -(2377 }) 26.2111 Tj -0 -294.2942 Td -(2378 ) 21.8426 Tj -0 -303.7875 Td -(2379 ) 21.8426 Tj -0 -313.2809 Td -(2380 ) 21.8426 Tj -0 -322.7743 Td -(2381 ) 21.8426 Tj -0 -332.2676 Td -(2382 ) 21.8426 Tj -0 -341.761 Td -(2383 ) 21.8426 Tj -0 -351.2543 Td -(2384 ) 21.8426 Tj -0 -360.7477 Td -(2385 ) 21.8426 Tj -0 -370.2411 Td -(2386 ) 21.8426 Tj -0 -379.7344 Td -(2387 ) 21.8426 Tj -0 -389.2278 Td -(2388 ) 21.8426 Tj -0 -398.7211 Td -(2389 ) 21.8426 Tj -0 -408.2145 Td -(2390 ) 21.8426 Tj -0 -417.7079 Td -(2391 ) 21.8426 Tj -0 -427.2012 Td -(2392 ) 21.8426 Tj -0 -436.6946 Td -(2393 ) 21.8426 Tj -0 -446.1879 Td -(2394 ) 21.8426 Tj -0 -455.6813 Td -(2395 ) 21.8426 Tj -0 -465.1747 Td -(2396 ) 21.8426 Tj -0 -474.668 Td -(2397 ) 21.8426 Tj -0 -484.1614 Td -(2398 ) 21.8426 Tj -0 -493.6547 Td -(2399 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 23) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 31 31 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/traps.h Page 1) 166.0035 Tj -0 -28.4801 Td -(2400 // x86 trap and interrupt constants.) 179.1091 Tj -0 -37.9735 Td -(2401 ) 21.8426 Tj -0 -47.4668 Td -(2402 // Processor-defined:) 113.5814 Tj -0 -56.9602 Td -(2403 #define T_DIVIDE 0 // divide error) 227.1628 Tj -0 -66.4535 Td -(2404 #define T_DEBUG 1 // debug exception) 240.2683 Tj -0 -75.9469 Td -(2405 #define T_NMI 2 // non-maskable interrupt) 270.8479 Tj -0 -85.4403 Td -(2406 #define T_BRKPT 3 // breakpoint) 218.4257 Tj -0 -94.9336 Td -(2407 #define T_OFLOW 4 // overflow) 209.6887 Tj -0 -104.427 Td -(2408 #define T_BOUND 5 // bounds check) 227.1628 Tj -0 -113.9203 Td -(2409 #define T_ILLOP 6 // illegal opcode) 235.8998 Tj -0 -123.4137 Td -(2410 #define T_DEVICE 7 // device not available) 262.1109 Tj -0 -132.9071 Td -(2411 #define T_DBLFLT 8 // double fault) 227.1628 Tj -0 -142.4004 Td -(2412 // #define T_COPROC 9 // reserved \(not used sin\ -ce 486\)) 301.4275 Tj -0 -151.8938 Td -(2413 #define T_TSS 10 // invalid task switch seg\ -ment) 292.6905 Tj -0 -161.3871 Td -(2414 #define T_SEGNP 11 // segment not present) 257.7424 Tj -0 -170.8805 Td -(2415 #define T_STACK 12 // stack exception) 240.2683 Tj -0 -180.3739 Td -(2416 #define T_GPFLT 13 // general protection faul\ -t) 279.5849 Tj -0 -189.8672 Td -(2417 #define T_PGFLT 14 // page fault) 218.4257 Tj -0 -199.3606 Td -(2418 // #define T_RES 15 // reserved) 209.6887 Tj -0 -208.8539 Td -(2419 #define T_FPERR 16 // floating point error) 262.1109 Tj -0 -218.3473 Td -(2420 #define T_ALIGN 17 // aligment check) 235.8998 Tj -0 -227.8407 Td -(2421 #define T_MCHK 18 // machine check) 231.5313 Tj -0 -237.334 Td -(2422 #define T_SIMDERR 19 // SIMD floating point err\ -or) 283.9534 Tj -0 -246.8274 Td -(2423 ) 21.8426 Tj -0 -256.3207 Td -(2424 // These are arbitrarily chosen, but with care not to over\ -lap) 288.322 Tj -0 -265.8141 Td -(2425 // processor defined exceptions or interrupt vectors.) 253.3738 Tj -0 -275.3075 Td -(2426 #define T_SYSCALL 64 // system call) 218.4257 Tj -0 -284.8008 Td -(2427 #define T_DEFAULT 500 // catchall) 209.6887 Tj -0 -294.2942 Td -(2428 ) 21.8426 Tj -0 -303.7875 Td -(2429 #define T_IRQ0 32 // IRQ 0 corresponds to in\ -t T_IRQ) 305.796 Tj -0 -313.2809 Td -(2430 ) 21.8426 Tj -0 -322.7743 Td -(2431 #define IRQ_TIMER 0) 135.4239 Tj -0 -332.2676 Td -(2432 #define IRQ_KBD 1) 135.4239 Tj -0 -341.761 Td -(2433 #define IRQ_COM1 4) 135.4239 Tj -0 -351.2543 Td -(2434 #define IRQ_IDE 14) 135.4239 Tj -0 -360.7477 Td -(2435 #define IRQ_ERROR 19) 135.4239 Tj -0 -370.2411 Td -(2436 #define IRQ_SPURIOUS 31) 135.4239 Tj -0 -379.7344 Td -(2437 ) 21.8426 Tj -0 -389.2278 Td -(2438 ) 21.8426 Tj -0 -398.7211 Td -(2439 ) 21.8426 Tj -0 -408.2145 Td -(2440 ) 21.8426 Tj -0 -417.7079 Td -(2441 ) 21.8426 Tj -0 -427.2012 Td -(2442 ) 21.8426 Tj -0 -436.6946 Td -(2443 ) 21.8426 Tj -0 -446.1879 Td -(2444 ) 21.8426 Tj -0 -455.6813 Td -(2445 ) 21.8426 Tj -0 -465.1747 Td -(2446 ) 21.8426 Tj -0 -474.668 Td -(2447 ) 21.8426 Tj -0 -484.1614 Td -(2448 ) 21.8426 Tj -0 -493.6547 Td -(2449 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 24) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/vectors.pl Page 1) 179.1091 Tj -0 -28.4801 Td -(2450 #!/usr/bin/perl -w) 100.4758 Tj -0 -37.9735 Td -(2451 ) 21.8426 Tj -0 -47.4668 Td -(2452 # Generate vectors.S, the trap/interrupt entry points.) 257.7424 Tj -0 -56.9602 Td -(2453 # There has to be one entry point per interrupt number) 257.7424 Tj -0 -66.4535 Td -(2454 # since otherwise there's no way for trap\(\) to discover) 262.1109 Tj -0 -75.9469 Td -(2455 # the interrupt number.) 122.3184 Tj -0 -85.4403 Td -(2456 ) 21.8426 Tj -0 -94.9336 Td -(2457 print "# generated by vectors.pl - do not edit\\n";) 240.2683 Tj -0 -104.427 Td -(2458 print "# handlers\\n";) 113.5814 Tj -0 -113.9203 Td -(2459 print ".globl alltraps\\n";) 135.4239 Tj -0 -123.4137 Td -(2460 for\(my $i = 0; $i < 256; $i++\){) 157.2665 Tj -0 -132.9071 Td -(2461 print ".globl vector$i\\n";) 152.898 Tj -0 -142.4004 Td -(2462 print "vector$i:\\n";) 126.6869 Tj -0 -151.8938 Td -(2463 if\(!\($i == 8 || \($i >= 10 && $i <= 14\) || $i == 17\ -\)\){) 270.8479 Tj -0 -161.3871 Td -(2464 print " pushl \\$0\\n";) 152.898 Tj -0 -170.8805 Td -(2465 }) 43.6851 Tj -0 -180.3739 Td -(2466 print " pushl \\$$i\\n";) 139.7925 Tj -0 -189.8672 Td -(2467 print " jmp alltraps\\n";) 148.5295 Tj -0 -199.3606 Td -(2468 }) 26.2111 Tj -0 -208.8539 Td -(2469 ) 21.8426 Tj -0 -218.3473 Td -(2470 print "\\n# vector table\\n";) 139.7925 Tj -0 -227.8407 Td -(2471 print ".data\\n";) 91.7388 Tj -0 -237.334 Td -(2472 print ".globl vectors\\n";) 131.0554 Tj -0 -246.8274 Td -(2473 print "vectors:\\n";) 104.8443 Tj -0 -256.3207 Td -(2474 for\(my $i = 0; $i < 256; $i++\){) 157.2665 Tj -0 -265.8141 Td -(2475 print " .long vector$i\\n";) 157.2665 Tj -0 -275.3075 Td -(2476 }) 26.2111 Tj -0 -284.8008 Td -(2477 ) 21.8426 Tj -0 -294.2942 Td -(2478 # sample output:) 91.7388 Tj -0 -303.7875 Td -(2479 # # handlers) 83.0018 Tj -0 -313.2809 Td -(2480 # .globl alltraps) 104.8443 Tj -0 -322.7743 Td -(2481 # .globl vector0) 100.4758 Tj -0 -332.2676 Td -(2482 # vector0:) 74.2647 Tj -0 -341.761 Td -(2483 # pushl $0) 83.0018 Tj -0 -351.2543 Td -(2484 # pushl $0) 83.0018 Tj -0 -360.7477 Td -(2485 # jmp alltraps) 100.4758 Tj -0 -370.2411 Td -(2486 # ...) 52.4222 Tj -0 -379.7344 Td -(2487 #) 26.2111 Tj -0 -389.2278 Td -(2488 # # vector table) 100.4758 Tj -0 -398.7211 Td -(2489 # .data) 61.1592 Tj -0 -408.2145 Td -(2490 # .globl vectors) 100.4758 Tj -0 -417.7079 Td -(2491 # vectors:) 74.2647 Tj -0 -427.2012 Td -(2492 # .long vector0) 104.8443 Tj -0 -436.6946 Td -(2493 # .long vector1) 104.8443 Tj -0 -446.1879 Td -(2494 # .long vector2) 104.8443 Tj -0 -455.6813 Td -(2495 # ...) 52.4222 Tj -0 -465.1747 Td -(2496 ) 21.8426 Tj -0 -474.668 Td -(2497 ) 21.8426 Tj -0 -484.1614 Td -(2498 ) 21.8426 Tj -0 -493.6547 Td -(2499 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 24) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 32 32 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/trapasm.S Page 1) 174.7406 Tj -0 -28.4801 Td -(2500 #define SEG_KCODE 1 // kernel code) 174.7406 Tj -0 -37.9735 Td -(2501 #define SEG_KDATA 2 // kernel data+stack) 200.9517 Tj -0 -47.4668 Td -(2502 #define SEG_KCPU 3 // kernel per-cpu data) 209.6887 Tj -0 -56.9602 Td -(2503 ) 21.8426 Tj -0 -66.4535 Td -(2504 # vectors.S sends all traps here.) 174.7406 Tj -0 -75.9469 Td -(2505 .globl alltraps) 87.3703 Tj -0 -85.4403 Td -(2506 alltraps:) 61.1592 Tj -0 -94.9336 Td -(2507 # Build trap frame.) 113.5814 Tj -0 -104.427 Td -(2508 pushl %ds) 69.8962 Tj -0 -113.9203 Td -(2509 pushl %es) 69.8962 Tj -0 -123.4137 Td -(2510 pushl %fs) 69.8962 Tj -0 -132.9071 Td -(2511 pushl %gs) 69.8962 Tj -0 -142.4004 Td -(2512 pushal) 56.7907 Tj -0 -151.8938 Td -(2513 ) 21.8426 Tj -0 -161.3871 Td -(2514 # Set up data and per-cpu segments.) 183.4776 Tj -0 -170.8805 Td -(2515 movw $\(SEG_KDATA<<3\), %ax) 139.7925 Tj -0 -180.3739 Td -(2516 movw %ax, %ds) 87.3703 Tj -0 -189.8672 Td -(2517 movw %ax, %es) 87.3703 Tj -0 -199.3606 Td -(2518 movw $\(SEG_KCPU<<3\), %ax) 135.4239 Tj -0 -208.8539 Td -(2519 movw %ax, %fs) 87.3703 Tj -0 -218.3473 Td -(2520 movw %ax, %gs) 87.3703 Tj -0 -227.8407 Td -(2521 ) 21.8426 Tj -0 -237.334 Td -(2522 # Call trap\(tf\), where tf=%esp) 161.635 Tj -0 -246.8274 Td -(2523 pushl %esp) 74.2647 Tj -0 -256.3207 Td -(2524 call trap) 69.8962 Tj -0 -265.8141 Td -(2525 addl $4, %esp) 87.3703 Tj -0 -275.3075 Td -(2526 ) 21.8426 Tj -0 -284.8008 Td -(2527 # Return falls through to trapret...) 187.8461 Tj -0 -294.2942 Td -(2528 .globl trapret) 83.0018 Tj -0 -303.7875 Td -(2529 trapret:) 56.7907 Tj -0 -313.2809 Td -(2530 popal) 52.4222 Tj -0 -322.7743 Td -(2531 popl %gs) 65.5277 Tj -0 -332.2676 Td -(2532 popl %fs) 65.5277 Tj -0 -341.761 Td -(2533 popl %es) 65.5277 Tj -0 -351.2543 Td -(2534 popl %ds) 65.5277 Tj -0 -360.7477 Td -(2535 addl $0x8, %esp # trapno and errcode) 192.2146 Tj -0 -370.2411 Td -(2536 iret) 48.0537 Tj -0 -379.7344 Td -(2537 ) 21.8426 Tj -0 -389.2278 Td -(2538 ) 21.8426 Tj -0 -398.7211 Td -(2539 ) 21.8426 Tj -0 -408.2145 Td -(2540 ) 21.8426 Tj -0 -417.7079 Td -(2541 ) 21.8426 Tj -0 -427.2012 Td -(2542 ) 21.8426 Tj -0 -436.6946 Td -(2543 ) 21.8426 Tj -0 -446.1879 Td -(2544 ) 21.8426 Tj -0 -455.6813 Td -(2545 ) 21.8426 Tj -0 -465.1747 Td -(2546 ) 21.8426 Tj -0 -474.668 Td -(2547 ) 21.8426 Tj -0 -484.1614 Td -(2548 ) 21.8426 Tj -0 -493.6547 Td -(2549 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 25) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/trap.c Page 1) 161.635 Tj -0 -28.4801 Td -(2550 #include "types.h") 100.4758 Tj -0 -37.9735 Td -(2551 #include "defs.h") 96.1073 Tj -0 -47.4668 Td -(2552 #include "param.h") 100.4758 Tj -0 -56.9602 Td -(2553 #include "mmu.h") 91.7388 Tj -0 -66.4535 Td -(2554 #include "proc.h") 96.1073 Tj -0 -75.9469 Td -(2555 #include "x86.h") 91.7388 Tj -0 -85.4403 Td -(2556 #include "traps.h") 100.4758 Tj -0 -94.9336 Td -(2557 #include "spinlock.h") 113.5814 Tj -0 -104.427 Td -(2558 ) 21.8426 Tj -0 -113.9203 Td -(2559 // Interrupt descriptor table \(shared by all CPUs\).) 244.6368 Tj -0 -123.4137 Td -(2560 struct gatedesc idt[256];) 131.0554 Tj -0 -132.9071 Td -(2561 extern uint vectors[]; // in vectors.S: array of 256 entr\ -y pointers) 318.9016 Tj -0 -142.4004 Td -(2562 struct spinlock tickslock;) 135.4239 Tj -0 -151.8938 Td -(2563 int ticks;) 65.5277 Tj -0 -161.3871 Td -(2564 ) 21.8426 Tj -0 -170.8805 Td -(2565 void) 39.3166 Tj -0 -180.3739 Td -(2566 tvinit\(void\)) 74.2647 Tj -0 -189.8672 Td -(2567 {) 26.2111 Tj -0 -199.3606 Td -(2568 int i;) 56.7907 Tj -0 -208.8539 Td -(2569 ) 21.8426 Tj -0 -218.3473 Td -(2570 for\(i = 0; i < 256; i++\)) 135.4239 Tj -0 -227.8407 Td -(2571 SETGATE\(idt[i], 0, SEG_KCODE<<3, vectors[i], 0\);) 249.0053 Tj -0 -237.334 Td -(2572 SETGATE\(idt[T_SYSCALL], 1, SEG_KCODE<<3, vectors[T_SYSC\ -ALL], DPL_USER\);) 340.7441 Tj -0 -246.8274 Td -(2573 ) 21.8426 Tj -0 -256.3207 Td -(2574 initlock\(&tickslock, "time"\);) 157.2665 Tj -0 -265.8141 Td -(2575 }) 26.2111 Tj -0 -275.3075 Td -(2576 ) 21.8426 Tj -0 -284.8008 Td -(2577 void) 39.3166 Tj -0 -294.2942 Td -(2578 idtinit\(void\)) 78.6333 Tj -0 -303.7875 Td -(2579 {) 26.2111 Tj -0 -313.2809 Td -(2580 lidt\(idt, sizeof\(idt\)\);) 131.0554 Tj -0 -322.7743 Td -(2581 }) 26.2111 Tj -0 -332.2676 Td -(2582 ) 21.8426 Tj -0 -341.761 Td -(2583 ) 21.8426 Tj -0 -351.2543 Td -(2584 ) 21.8426 Tj -0 -360.7477 Td -(2585 ) 21.8426 Tj -0 -370.2411 Td -(2586 ) 21.8426 Tj -0 -379.7344 Td -(2587 ) 21.8426 Tj -0 -389.2278 Td -(2588 ) 21.8426 Tj -0 -398.7211 Td -(2589 ) 21.8426 Tj -0 -408.2145 Td -(2590 ) 21.8426 Tj -0 -417.7079 Td -(2591 ) 21.8426 Tj -0 -427.2012 Td -(2592 ) 21.8426 Tj -0 -436.6946 Td -(2593 ) 21.8426 Tj -0 -446.1879 Td -(2594 ) 21.8426 Tj -0 -455.6813 Td -(2595 ) 21.8426 Tj -0 -465.1747 Td -(2596 ) 21.8426 Tj -0 -474.668 Td -(2597 ) 21.8426 Tj -0 -484.1614 Td -(2598 ) 21.8426 Tj -0 -493.6547 Td -(2599 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 25) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 33 33 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/trap.c Page 2) 161.635 Tj -0 -28.4801 Td -(2600 void) 39.3166 Tj -0 -37.9735 Td -(2601 trap\(struct trapframe *tf\)) 135.4239 Tj -0 -47.4668 Td -(2602 {) 26.2111 Tj -0 -56.9602 Td -(2603 if\(tf->trapno == T_SYSCALL\){) 152.898 Tj -0 -66.4535 Td -(2604 if\(proc->killed\)) 109.2129 Tj -0 -75.9469 Td -(2605 exit\(\);) 78.6333 Tj -0 -85.4403 Td -(2606 proc->tf = tf;) 100.4758 Tj -0 -94.9336 Td -(2607 syscall\(\);) 83.0018 Tj -0 -104.427 Td -(2608 if\(proc->killed\)) 109.2129 Tj -0 -113.9203 Td -(2609 exit\(\);) 78.6333 Tj -0 -123.4137 Td -(2610 return;) 69.8962 Tj -0 -132.9071 Td -(2611 }) 34.9481 Tj -0 -142.4004 Td -(2612 ) 21.8426 Tj -0 -151.8938 Td -(2613 switch\(tf->trapno\){) 113.5814 Tj -0 -161.3871 Td -(2614 case T_IRQ0 + IRQ_TIMER:) 135.4239 Tj -0 -170.8805 Td -(2615 if\(cpu->id == 0\){) 113.5814 Tj -0 -180.3739 Td -(2616 acquire\(&tickslock\);) 135.4239 Tj -0 -189.8672 Td -(2617 ticks++;) 83.0018 Tj -0 -199.3606 Td -(2618 wakeup\(&ticks\);) 113.5814 Tj -0 -208.8539 Td -(2619 release\(&tickslock\);) 135.4239 Tj -0 -218.3473 Td -(2620 }) 43.6851 Tj -0 -227.8407 Td -(2621 lapiceoi\(\);) 87.3703 Tj -0 -237.334 Td -(2622 break;) 65.5277 Tj -0 -246.8274 Td -(2623 case T_IRQ0 + IRQ_IDE:) 126.6869 Tj -0 -256.3207 Td -(2624 ideintr\(\);) 83.0018 Tj -0 -265.8141 Td -(2625 lapiceoi\(\);) 87.3703 Tj -0 -275.3075 Td -(2626 break;) 65.5277 Tj -0 -284.8008 Td -(2627 case T_IRQ0 + IRQ_KBD:) 126.6869 Tj -0 -294.2942 Td -(2628 kbdintr\(\);) 83.0018 Tj -0 -303.7875 Td -(2629 lapiceoi\(\);) 87.3703 Tj -0 -313.2809 Td -(2630 break;) 65.5277 Tj -0 -322.7743 Td -(2631 case T_IRQ0 + IRQ_COM1:) 131.0554 Tj -0 -332.2676 Td -(2632 uartintr\(\);) 87.3703 Tj -0 -341.761 Td -(2633 lapiceoi\(\);) 87.3703 Tj -0 -351.2543 Td -(2634 break;) 65.5277 Tj -0 -360.7477 Td -(2635 case T_IRQ0 + 7:) 100.4758 Tj -0 -370.2411 Td -(2636 case T_IRQ0 + IRQ_SPURIOUS:) 148.5295 Tj -0 -379.7344 Td -(2637 cprintf\("cpu%d: spurious interrupt at %x:%x\\n",) 244.6368 Tj -0 -389.2278 Td -(2638 cpu->id, tf->cs, tf->eip\);) 187.8461 Tj -0 -398.7211 Td -(2639 lapiceoi\(\);) 87.3703 Tj -0 -408.2145 Td -(2640 break;) 65.5277 Tj -0 -417.7079 Td -(2641 ) 21.8426 Tj -0 -427.2012 Td -(2642 ) 21.8426 Tj -0 -436.6946 Td -(2643 ) 21.8426 Tj -0 -446.1879 Td -(2644 ) 21.8426 Tj -0 -455.6813 Td -(2645 ) 21.8426 Tj -0 -465.1747 Td -(2646 ) 21.8426 Tj -0 -474.668 Td -(2647 ) 21.8426 Tj -0 -484.1614 Td -(2648 ) 21.8426 Tj -0 -493.6547 Td -(2649 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 26) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/trap.c Page 3) 161.635 Tj -0 -28.4801 Td -(2650 default:) 65.5277 Tj -0 -37.9735 Td -(2651 if\(proc == 0 || \(tf->cs&3\) == 0\){) 183.4776 Tj -0 -47.4668 Td -(2652 // In kernel, it must be our mistake.) 209.6887 Tj -0 -56.9602 Td -(2653 cprintf\("unexpected trap %d from cpu %d eip %x\\n",) 266.4794 Tj -0 -66.4535 Td -(2654 tf->trapno, cpu->id, tf->eip\);) 214.0572 Tj -0 -75.9469 Td -(2655 panic\("trap"\);) 109.2129 Tj -0 -85.4403 Td -(2656 }) 43.6851 Tj -0 -94.9336 Td -(2657 // In user space, assume process misbehaved.) 231.5313 Tj -0 -104.427 Td -(2658 cprintf\("pid %d %s: trap %d err %d on cpu %d eip %x -\ -- kill proc\\n",) 336.3756 Tj -0 -113.9203 Td -(2659 proc->pid, proc->name, tf->trapno, tf->err, cp\ -u->id, tf->eip\);) 345.1126 Tj -0 -123.4137 Td -(2660 proc->killed = 1;) 113.5814 Tj -0 -132.9071 Td -(2661 }) 34.9481 Tj -0 -142.4004 Td -(2662 ) 21.8426 Tj -0 -151.8938 Td -(2663 // Force process exit if it has been killed and is in us\ -er space.) 314.533 Tj -0 -161.3871 Td -(2664 // \(If it is still executing in the kernel, let it keep\ - running) 305.796 Tj -0 -170.8805 Td -(2665 // until it gets to the regular system call return.\)) 257.7424 Tj -0 -180.3739 Td -(2666 if\(proc && proc->killed && \(tf->cs&3\) == DPL_USER\)) 249.0053 Tj -0 -189.8672 Td -(2667 exit\(\);) 69.8962 Tj -0 -199.3606 Td -(2668 ) 21.8426 Tj -0 -208.8539 Td -(2669 // Force process to give up CPU on clock tick.) 231.5313 Tj -0 -218.3473 Td -(2670 // If interrupts were on while locks held, would need to\ - check nlock.) 332.0071 Tj -0 -227.8407 Td -(2671 if\(proc && proc->state == RUNNING && tf->trapno == T_IR\ -Q0+IRQ_TIMER\)) 327.6386 Tj -0 -237.334 Td -(2672 yield\(\);) 74.2647 Tj -0 -246.8274 Td -(2673 ) 21.8426 Tj -0 -256.3207 Td -(2674 // Check if the process has been killed since we yielded) 275.2164 Tj -0 -265.8141 Td -(2675 if\(proc && proc->killed && \(tf->cs&3\) == DPL_USER\)) 249.0053 Tj -0 -275.3075 Td -(2676 exit\(\);) 69.8962 Tj -0 -284.8008 Td -(2677 }) 26.2111 Tj -0 -294.2942 Td -(2678 ) 21.8426 Tj -0 -303.7875 Td -(2679 ) 21.8426 Tj -0 -313.2809 Td -(2680 ) 21.8426 Tj -0 -322.7743 Td -(2681 ) 21.8426 Tj -0 -332.2676 Td -(2682 ) 21.8426 Tj -0 -341.761 Td -(2683 ) 21.8426 Tj -0 -351.2543 Td -(2684 ) 21.8426 Tj -0 -360.7477 Td -(2685 ) 21.8426 Tj -0 -370.2411 Td -(2686 ) 21.8426 Tj -0 -379.7344 Td -(2687 ) 21.8426 Tj -0 -389.2278 Td -(2688 ) 21.8426 Tj -0 -398.7211 Td -(2689 ) 21.8426 Tj -0 -408.2145 Td -(2690 ) 21.8426 Tj -0 -417.7079 Td -(2691 ) 21.8426 Tj -0 -427.2012 Td -(2692 ) 21.8426 Tj -0 -436.6946 Td -(2693 ) 21.8426 Tj -0 -446.1879 Td -(2694 ) 21.8426 Tj -0 -455.6813 Td -(2695 ) 21.8426 Tj -0 -465.1747 Td -(2696 ) 21.8426 Tj -0 -474.668 Td -(2697 ) 21.8426 Tj -0 -484.1614 Td -(2698 ) 21.8426 Tj -0 -493.6547 Td -(2699 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 26) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 34 34 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/syscall.h Page 1) 174.7406 Tj -0 -28.4801 Td -(2700 // System call numbers) 117.9499 Tj -0 -37.9735 Td -(2701 #define SYS_fork 1) 113.5814 Tj -0 -47.4668 Td -(2702 #define SYS_exit 2) 113.5814 Tj -0 -56.9602 Td -(2703 #define SYS_wait 3) 113.5814 Tj -0 -66.4535 Td -(2704 #define SYS_pipe 4) 113.5814 Tj -0 -75.9469 Td -(2705 #define SYS_write 5) 113.5814 Tj -0 -85.4403 Td -(2706 #define SYS_read 6) 113.5814 Tj -0 -94.9336 Td -(2707 #define SYS_close 7) 113.5814 Tj -0 -104.427 Td -(2708 #define SYS_kill 8) 113.5814 Tj -0 -113.9203 Td -(2709 #define SYS_exec 9) 113.5814 Tj -0 -123.4137 Td -(2710 #define SYS_open 10) 113.5814 Tj -0 -132.9071 Td -(2711 #define SYS_mknod 11) 113.5814 Tj -0 -142.4004 Td -(2712 #define SYS_unlink 12) 113.5814 Tj -0 -151.8938 Td -(2713 #define SYS_fstat 13) 113.5814 Tj -0 -161.3871 Td -(2714 #define SYS_link 14) 113.5814 Tj -0 -170.8805 Td -(2715 #define SYS_mkdir 15) 113.5814 Tj -0 -180.3739 Td -(2716 #define SYS_chdir 16) 113.5814 Tj -0 -189.8672 Td -(2717 #define SYS_dup 17) 113.5814 Tj -0 -199.3606 Td -(2718 #define SYS_getpid 18) 113.5814 Tj -0 -208.8539 Td -(2719 #define SYS_sbrk 19) 113.5814 Tj -0 -218.3473 Td -(2720 #define SYS_sleep 20) 113.5814 Tj -0 -227.8407 Td -(2721 ) 21.8426 Tj -0 -237.334 Td -(2722 ) 21.8426 Tj -0 -246.8274 Td -(2723 ) 21.8426 Tj -0 -256.3207 Td -(2724 ) 21.8426 Tj -0 -265.8141 Td -(2725 ) 21.8426 Tj -0 -275.3075 Td -(2726 ) 21.8426 Tj -0 -284.8008 Td -(2727 ) 21.8426 Tj -0 -294.2942 Td -(2728 ) 21.8426 Tj -0 -303.7875 Td -(2729 ) 21.8426 Tj -0 -313.2809 Td -(2730 ) 21.8426 Tj -0 -322.7743 Td -(2731 ) 21.8426 Tj -0 -332.2676 Td -(2732 ) 21.8426 Tj -0 -341.761 Td -(2733 ) 21.8426 Tj -0 -351.2543 Td -(2734 ) 21.8426 Tj -0 -360.7477 Td -(2735 ) 21.8426 Tj -0 -370.2411 Td -(2736 ) 21.8426 Tj -0 -379.7344 Td -(2737 ) 21.8426 Tj -0 -389.2278 Td -(2738 ) 21.8426 Tj -0 -398.7211 Td -(2739 ) 21.8426 Tj -0 -408.2145 Td -(2740 ) 21.8426 Tj -0 -417.7079 Td -(2741 ) 21.8426 Tj -0 -427.2012 Td -(2742 ) 21.8426 Tj -0 -436.6946 Td -(2743 ) 21.8426 Tj -0 -446.1879 Td -(2744 ) 21.8426 Tj -0 -455.6813 Td -(2745 ) 21.8426 Tj -0 -465.1747 Td -(2746 ) 21.8426 Tj -0 -474.668 Td -(2747 ) 21.8426 Tj -0 -484.1614 Td -(2748 ) 21.8426 Tj -0 -493.6547 Td -(2749 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 27) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/syscall.c Page 1) 174.7406 Tj -0 -28.4801 Td -(2750 #include "types.h") 100.4758 Tj -0 -37.9735 Td -(2751 #include "defs.h") 96.1073 Tj -0 -47.4668 Td -(2752 #include "param.h") 100.4758 Tj -0 -56.9602 Td -(2753 #include "mmu.h") 91.7388 Tj -0 -66.4535 Td -(2754 #include "proc.h") 96.1073 Tj -0 -75.9469 Td -(2755 #include "x86.h") 91.7388 Tj -0 -85.4403 Td -(2756 #include "syscall.h") 109.2129 Tj -0 -94.9336 Td -(2757 ) 21.8426 Tj -0 -104.427 Td -(2758 // User code makes a system call with INT T_SYSCALL.) 249.0053 Tj -0 -113.9203 Td -(2759 // System call number in %eax.) 152.898 Tj -0 -123.4137 Td -(2760 // Arguments on the stack, from the user call to the C) 257.7424 Tj -0 -132.9071 Td -(2761 // library system call function. The saved user %esp point\ -s) 279.5849 Tj -0 -142.4004 Td -(2762 // to a saved program counter, and then the first argument\ -.) 279.5849 Tj -0 -151.8938 Td -(2763 ) 21.8426 Tj -0 -161.3871 Td -(2764 // Fetch the int at addr from process p.) 196.5831 Tj -0 -170.8805 Td -(2765 int) 34.9481 Tj -0 -180.3739 Td -(2766 fetchint\(struct proc *p, uint addr, int *ip\)) 214.0572 Tj -0 -189.8672 Td -(2767 {) 26.2111 Tj -0 -199.3606 Td -(2768 if\(addr >= p->sz || addr+4 > p->sz\)) 183.4776 Tj -0 -208.8539 Td -(2769 return -1;) 83.0018 Tj -0 -218.3473 Td -(2770 *ip = *\(int*\)\(p->mem + addr\);) 157.2665 Tj -0 -227.8407 Td -(2771 return 0;) 69.8962 Tj -0 -237.334 Td -(2772 }) 26.2111 Tj -0 -246.8274 Td -(2773 ) 21.8426 Tj -0 -256.3207 Td -(2774 // Fetch the nul-terminated string at addr from process p.) 275.2164 Tj -0 -265.8141 Td -(2775 // Doesn't actually copy the string - just sets *pp to poi\ -nt at it.) 314.533 Tj -0 -275.3075 Td -(2776 // Returns length of string, not including nul.) 227.1628 Tj -0 -284.8008 Td -(2777 int) 34.9481 Tj -0 -294.2942 Td -(2778 fetchstr\(struct proc *p, uint addr, char **pp\)) 222.7942 Tj -0 -303.7875 Td -(2779 {) 26.2111 Tj -0 -313.2809 Td -(2780 char *s, *ep;) 87.3703 Tj -0 -322.7743 Td -(2781 ) 21.8426 Tj -0 -332.2676 Td -(2782 if\(addr >= p->sz\)) 104.8443 Tj -0 -341.761 Td -(2783 return -1;) 83.0018 Tj -0 -351.2543 Td -(2784 *pp = p->mem + addr;) 117.9499 Tj -0 -360.7477 Td -(2785 ep = p->mem + p->sz;) 117.9499 Tj -0 -370.2411 Td -(2786 for\(s = *pp; s < ep; s++\)) 139.7925 Tj -0 -379.7344 Td -(2787 if\(*s == 0\)) 87.3703 Tj -0 -389.2278 Td -(2788 return s - *pp;) 113.5814 Tj -0 -398.7211 Td -(2789 return -1;) 74.2647 Tj -0 -408.2145 Td -(2790 }) 26.2111 Tj -0 -417.7079 Td -(2791 ) 21.8426 Tj -0 -427.2012 Td -(2792 // Fetch the nth 32-bit system call argument.) 218.4257 Tj -0 -436.6946 Td -(2793 int) 34.9481 Tj -0 -446.1879 Td -(2794 argint\(int n, int *ip\)) 117.9499 Tj -0 -455.6813 Td -(2795 {) 26.2111 Tj -0 -465.1747 Td -(2796 return fetchint\(proc, proc->tf->esp + 4 + 4*n, ip\);) 253.3738 Tj -0 -474.668 Td -(2797 }) 26.2111 Tj -0 -484.1614 Td -(2798 ) 21.8426 Tj -0 -493.6547 Td -(2799 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 27) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 35 35 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/syscall.c Page 2) 174.7406 Tj -0 -28.4801 Td -(2800 // Fetch the nth word-sized system call argument as a poin\ -ter) 288.322 Tj -0 -37.9735 Td -(2801 // to a block of memory of size n bytes. Check that the p\ -ointer) 301.4275 Tj -0 -47.4668 Td -(2802 // lies within the process address space.) 200.9517 Tj -0 -56.9602 Td -(2803 int) 34.9481 Tj -0 -66.4535 Td -(2804 argptr\(int n, char **pp, int size\)) 170.3721 Tj -0 -75.9469 Td -(2805 {) 26.2111 Tj -0 -85.4403 Td -(2806 int i;) 56.7907 Tj -0 -94.9336 Td -(2807 ) 21.8426 Tj -0 -104.427 Td -(2808 if\(argint\(n, &i\) < 0\)) 122.3184 Tj -0 -113.9203 Td -(2809 return -1;) 83.0018 Tj -0 -123.4137 Td -(2810 if\(\(uint\)i >= proc->sz || \(uint\)i+size >= proc->sz\)) 253.3738 Tj -0 -132.9071 Td -(2811 return -1;) 83.0018 Tj -0 -142.4004 Td -(2812 *pp = proc->mem + i;) 117.9499 Tj -0 -151.8938 Td -(2813 return 0;) 69.8962 Tj -0 -161.3871 Td -(2814 }) 26.2111 Tj -0 -170.8805 Td -(2815 ) 21.8426 Tj -0 -180.3739 Td -(2816 // Fetch the nth word-sized system call argument as a stri\ -ng pointer.) 323.2701 Tj -0 -189.8672 Td -(2817 // Check that the pointer is valid and the string is nul-t\ -erminated.) 318.9016 Tj -0 -199.3606 Td -(2818 // \(There is no shared writable memory, so the string can\ -'t change) 310.1645 Tj -0 -208.8539 Td -(2819 // between this check and being used by the kernel.\)) 249.0053 Tj -0 -218.3473 Td -(2820 int) 34.9481 Tj -0 -227.8407 Td -(2821 argstr\(int n, char **pp\)) 126.6869 Tj -0 -237.334 Td -(2822 {) 26.2111 Tj -0 -246.8274 Td -(2823 int addr;) 69.8962 Tj -0 -256.3207 Td -(2824 if\(argint\(n, &addr\) < 0\)) 135.4239 Tj -0 -265.8141 Td -(2825 return -1;) 83.0018 Tj -0 -275.3075 Td -(2826 return fetchstr\(proc, addr, pp\);) 170.3721 Tj -0 -284.8008 Td -(2827 }) 26.2111 Tj -0 -294.2942 Td -(2828 ) 21.8426 Tj -0 -303.7875 Td -(2829 extern int sys_chdir\(void\);) 139.7925 Tj -0 -313.2809 Td -(2830 extern int sys_close\(void\);) 139.7925 Tj -0 -322.7743 Td -(2831 extern int sys_dup\(void\);) 131.0554 Tj -0 -332.2676 Td -(2832 extern int sys_exec\(void\);) 135.4239 Tj -0 -341.761 Td -(2833 extern int sys_exit\(void\);) 135.4239 Tj -0 -351.2543 Td -(2834 extern int sys_fork\(void\);) 135.4239 Tj -0 -360.7477 Td -(2835 extern int sys_fstat\(void\);) 139.7925 Tj -0 -370.2411 Td -(2836 extern int sys_getpid\(void\);) 144.161 Tj -0 -379.7344 Td -(2837 extern int sys_kill\(void\);) 135.4239 Tj -0 -389.2278 Td -(2838 extern int sys_link\(void\);) 135.4239 Tj -0 -398.7211 Td -(2839 extern int sys_mkdir\(void\);) 139.7925 Tj -0 -408.2145 Td -(2840 extern int sys_mknod\(void\);) 139.7925 Tj -0 -417.7079 Td -(2841 extern int sys_open\(void\);) 135.4239 Tj -0 -427.2012 Td -(2842 extern int sys_pipe\(void\);) 135.4239 Tj -0 -436.6946 Td -(2843 extern int sys_read\(void\);) 135.4239 Tj -0 -446.1879 Td -(2844 extern int sys_sbrk\(void\);) 135.4239 Tj -0 -455.6813 Td -(2845 extern int sys_sleep\(void\);) 139.7925 Tj -0 -465.1747 Td -(2846 extern int sys_unlink\(void\);) 144.161 Tj -0 -474.668 Td -(2847 extern int sys_wait\(void\);) 135.4239 Tj -0 -484.1614 Td -(2848 extern int sys_write\(void\);) 139.7925 Tj -0 -493.6547 Td -(2849 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 28) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/syscall.c Page 3) 174.7406 Tj -0 -28.4801 Td -(2850 static int \(*syscalls[]\)\(void\) = {) 170.3721 Tj -0 -37.9735 Td -(2851 [SYS_chdir] sys_chdir,) 126.6869 Tj -0 -47.4668 Td -(2852 [SYS_close] sys_close,) 126.6869 Tj -0 -56.9602 Td -(2853 [SYS_dup] sys_dup,) 117.9499 Tj -0 -66.4535 Td -(2854 [SYS_exec] sys_exec,) 122.3184 Tj -0 -75.9469 Td -(2855 [SYS_exit] sys_exit,) 122.3184 Tj -0 -85.4403 Td -(2856 [SYS_fork] sys_fork,) 122.3184 Tj -0 -94.9336 Td -(2857 [SYS_fstat] sys_fstat,) 126.6869 Tj -0 -104.427 Td -(2858 [SYS_getpid] sys_getpid,) 131.0554 Tj -0 -113.9203 Td -(2859 [SYS_kill] sys_kill,) 122.3184 Tj -0 -123.4137 Td -(2860 [SYS_link] sys_link,) 122.3184 Tj -0 -132.9071 Td -(2861 [SYS_mkdir] sys_mkdir,) 126.6869 Tj -0 -142.4004 Td -(2862 [SYS_mknod] sys_mknod,) 126.6869 Tj -0 -151.8938 Td -(2863 [SYS_open] sys_open,) 122.3184 Tj -0 -161.3871 Td -(2864 [SYS_pipe] sys_pipe,) 122.3184 Tj -0 -170.8805 Td -(2865 [SYS_read] sys_read,) 122.3184 Tj -0 -180.3739 Td -(2866 [SYS_sbrk] sys_sbrk,) 122.3184 Tj -0 -189.8672 Td -(2867 [SYS_sleep] sys_sleep,) 126.6869 Tj -0 -199.3606 Td -(2868 [SYS_unlink] sys_unlink,) 131.0554 Tj -0 -208.8539 Td -(2869 [SYS_wait] sys_wait,) 122.3184 Tj -0 -218.3473 Td -(2870 [SYS_write] sys_write,) 126.6869 Tj -0 -227.8407 Td -(2871 };) 30.5796 Tj -0 -237.334 Td -(2872 ) 21.8426 Tj -0 -246.8274 Td -(2873 void) 39.3166 Tj -0 -256.3207 Td -(2874 syscall\(void\)) 78.6333 Tj -0 -265.8141 Td -(2875 {) 26.2111 Tj -0 -275.3075 Td -(2876 int num;) 65.5277 Tj -0 -284.8008 Td -(2877 ) 21.8426 Tj -0 -294.2942 Td -(2878 num = proc->tf->eax;) 117.9499 Tj -0 -303.7875 Td -(2879 if\(num >= 0 && num < NELEM\(syscalls\) && syscalls[num]\ -\)) 266.4794 Tj -0 -313.2809 Td -(2880 proc->tf->eax = syscalls[num]\(\);) 179.1091 Tj -0 -322.7743 Td -(2881 else {) 56.7907 Tj -0 -332.2676 Td -(2882 cprintf\("%d %s: unknown sys call %d\\n",) 209.6887 Tj -0 -341.761 Td -(2883 proc->pid, proc->name, num\);) 196.5831 Tj -0 -351.2543 Td -(2884 proc->tf->eax = -1;) 122.3184 Tj -0 -360.7477 Td -(2885 }) 34.9481 Tj -0 -370.2411 Td -(2886 }) 26.2111 Tj -0 -379.7344 Td -(2887 ) 21.8426 Tj -0 -389.2278 Td -(2888 ) 21.8426 Tj -0 -398.7211 Td -(2889 ) 21.8426 Tj -0 -408.2145 Td -(2890 ) 21.8426 Tj -0 -417.7079 Td -(2891 ) 21.8426 Tj -0 -427.2012 Td -(2892 ) 21.8426 Tj -0 -436.6946 Td -(2893 ) 21.8426 Tj -0 -446.1879 Td -(2894 ) 21.8426 Tj -0 -455.6813 Td -(2895 ) 21.8426 Tj -0 -465.1747 Td -(2896 ) 21.8426 Tj -0 -474.668 Td -(2897 ) 21.8426 Tj -0 -484.1614 Td -(2898 ) 21.8426 Tj -0 -493.6547 Td -(2899 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 28) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 36 36 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sysproc.c Page 1) 174.7406 Tj -0 -28.4801 Td -(2900 #include "types.h") 100.4758 Tj -0 -37.9735 Td -(2901 #include "x86.h") 91.7388 Tj -0 -47.4668 Td -(2902 #include "defs.h") 96.1073 Tj -0 -56.9602 Td -(2903 #include "param.h") 100.4758 Tj -0 -66.4535 Td -(2904 #include "mmu.h") 91.7388 Tj -0 -75.9469 Td -(2905 #include "proc.h") 96.1073 Tj -0 -85.4403 Td -(2906 ) 21.8426 Tj -0 -94.9336 Td -(2907 int) 34.9481 Tj -0 -104.427 Td -(2908 sys_fork\(void\)) 83.0018 Tj -0 -113.9203 Td -(2909 {) 26.2111 Tj -0 -123.4137 Td -(2910 return fork\(\);) 91.7388 Tj -0 -132.9071 Td -(2911 }) 26.2111 Tj -0 -142.4004 Td -(2912 ) 21.8426 Tj -0 -151.8938 Td -(2913 int) 34.9481 Tj -0 -161.3871 Td -(2914 sys_exit\(void\)) 83.0018 Tj -0 -170.8805 Td -(2915 {) 26.2111 Tj -0 -180.3739 Td -(2916 exit\(\);) 61.1592 Tj -0 -189.8672 Td -(2917 return 0; // not reached) 139.7925 Tj -0 -199.3606 Td -(2918 }) 26.2111 Tj -0 -208.8539 Td -(2919 ) 21.8426 Tj -0 -218.3473 Td -(2920 int) 34.9481 Tj -0 -227.8407 Td -(2921 sys_wait\(void\)) 83.0018 Tj -0 -237.334 Td -(2922 {) 26.2111 Tj -0 -246.8274 Td -(2923 return wait\(\);) 91.7388 Tj -0 -256.3207 Td -(2924 }) 26.2111 Tj -0 -265.8141 Td -(2925 ) 21.8426 Tj -0 -275.3075 Td -(2926 int) 34.9481 Tj -0 -284.8008 Td -(2927 sys_kill\(void\)) 83.0018 Tj -0 -294.2942 Td -(2928 {) 26.2111 Tj -0 -303.7875 Td -(2929 int pid;) 65.5277 Tj -0 -313.2809 Td -(2930 ) 21.8426 Tj -0 -322.7743 Td -(2931 if\(argint\(0, &pid\) < 0\)) 131.0554 Tj -0 -332.2676 Td -(2932 return -1;) 83.0018 Tj -0 -341.761 Td -(2933 return kill\(pid\);) 104.8443 Tj -0 -351.2543 Td -(2934 }) 26.2111 Tj -0 -360.7477 Td -(2935 ) 21.8426 Tj -0 -370.2411 Td -(2936 int) 34.9481 Tj -0 -379.7344 Td -(2937 sys_getpid\(void\)) 91.7388 Tj -0 -389.2278 Td -(2938 {) 26.2111 Tj -0 -398.7211 Td -(2939 return proc->pid;) 104.8443 Tj -0 -408.2145 Td -(2940 }) 26.2111 Tj -0 -417.7079 Td -(2941 ) 21.8426 Tj -0 -427.2012 Td -(2942 ) 21.8426 Tj -0 -436.6946 Td -(2943 ) 21.8426 Tj -0 -446.1879 Td -(2944 ) 21.8426 Tj -0 -455.6813 Td -(2945 ) 21.8426 Tj -0 -465.1747 Td -(2946 ) 21.8426 Tj -0 -474.668 Td -(2947 ) 21.8426 Tj -0 -484.1614 Td -(2948 ) 21.8426 Tj -0 -493.6547 Td -(2949 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 29) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sysproc.c Page 2) 174.7406 Tj -0 -28.4801 Td -(2950 int) 34.9481 Tj -0 -37.9735 Td -(2951 sys_sbrk\(void\)) 83.0018 Tj -0 -47.4668 Td -(2952 {) 26.2111 Tj -0 -56.9602 Td -(2953 int addr;) 69.8962 Tj -0 -66.4535 Td -(2954 int n;) 56.7907 Tj -0 -75.9469 Td -(2955 ) 21.8426 Tj -0 -85.4403 Td -(2956 if\(argint\(0, &n\) < 0\)) 122.3184 Tj -0 -94.9336 Td -(2957 return -1;) 83.0018 Tj -0 -104.427 Td -(2958 addr = proc->sz;) 100.4758 Tj -0 -113.9203 Td -(2959 if\(growproc\(n\) < 0\)) 113.5814 Tj -0 -123.4137 Td -(2960 return -1;) 83.0018 Tj -0 -132.9071 Td -(2961 return addr;) 83.0018 Tj -0 -142.4004 Td -(2962 }) 26.2111 Tj -0 -151.8938 Td -(2963 ) 21.8426 Tj -0 -161.3871 Td -(2964 int) 34.9481 Tj -0 -170.8805 Td -(2965 sys_sleep\(void\)) 87.3703 Tj -0 -180.3739 Td -(2966 {) 26.2111 Tj -0 -189.8672 Td -(2967 int n, ticks0;) 91.7388 Tj -0 -199.3606 Td -(2968 ) 21.8426 Tj -0 -208.8539 Td -(2969 if\(argint\(0, &n\) < 0\)) 122.3184 Tj -0 -218.3473 Td -(2970 return -1;) 83.0018 Tj -0 -227.8407 Td -(2971 acquire\(&tickslock\);) 117.9499 Tj -0 -237.334 Td -(2972 ticks0 = ticks;) 96.1073 Tj -0 -246.8274 Td -(2973 while\(ticks - ticks0 < n\){) 144.161 Tj -0 -256.3207 Td -(2974 if\(proc->killed\){) 113.5814 Tj -0 -265.8141 Td -(2975 release\(&tickslock\);) 135.4239 Tj -0 -275.3075 Td -(2976 return -1;) 91.7388 Tj -0 -284.8008 Td -(2977 }) 43.6851 Tj -0 -294.2942 Td -(2978 sleep\(&ticks, &tickslock\);) 152.898 Tj -0 -303.7875 Td -(2979 }) 34.9481 Tj -0 -313.2809 Td -(2980 release\(&tickslock\);) 117.9499 Tj -0 -322.7743 Td -(2981 return 0;) 69.8962 Tj -0 -332.2676 Td -(2982 }) 26.2111 Tj -0 -341.761 Td -(2983 ) 21.8426 Tj -0 -351.2543 Td -(2984 ) 21.8426 Tj -0 -360.7477 Td -(2985 ) 21.8426 Tj -0 -370.2411 Td -(2986 ) 21.8426 Tj -0 -379.7344 Td -(2987 ) 21.8426 Tj -0 -389.2278 Td -(2988 ) 21.8426 Tj -0 -398.7211 Td -(2989 ) 21.8426 Tj -0 -408.2145 Td -(2990 ) 21.8426 Tj -0 -417.7079 Td -(2991 ) 21.8426 Tj -0 -427.2012 Td -(2992 ) 21.8426 Tj -0 -436.6946 Td -(2993 ) 21.8426 Tj -0 -446.1879 Td -(2994 ) 21.8426 Tj -0 -455.6813 Td -(2995 ) 21.8426 Tj -0 -465.1747 Td -(2996 ) 21.8426 Tj -0 -474.668 Td -(2997 ) 21.8426 Tj -0 -484.1614 Td -(2998 ) 21.8426 Tj -0 -493.6547 Td -(2999 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 29) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 37 37 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/buf.h Page 1) 157.2665 Tj -0 -28.4801 Td -(3000 struct buf {) 74.2647 Tj -0 -37.9735 Td -(3001 int flags;) 74.2647 Tj -0 -47.4668 Td -(3002 uint dev;) 69.8962 Tj -0 -56.9602 Td -(3003 uint sector;) 83.0018 Tj -0 -66.4535 Td -(3004 struct buf *prev; // LRU cache list) 183.4776 Tj -0 -75.9469 Td -(3005 struct buf *next;) 104.8443 Tj -0 -85.4403 Td -(3006 struct buf *qnext; // disk queue) 170.3721 Tj -0 -94.9336 Td -(3007 uchar data[512];) 100.4758 Tj -0 -104.427 Td -(3008 };) 30.5796 Tj -0 -113.9203 Td -(3009 #define B_BUSY 0x1 // buffer is locked by some process) 266.4794 Tj -0 -123.4137 Td -(3010 #define B_VALID 0x2 // buffer has been read from disk) 257.7424 Tj -0 -132.9071 Td -(3011 #define B_DIRTY 0x4 // buffer needs to be written to disk) 275.2164 Tj -0 -142.4004 Td -(3012 ) 21.8426 Tj -0 -151.8938 Td -(3013 ) 21.8426 Tj -0 -161.3871 Td -(3014 ) 21.8426 Tj -0 -170.8805 Td -(3015 ) 21.8426 Tj -0 -180.3739 Td -(3016 ) 21.8426 Tj -0 -189.8672 Td -(3017 ) 21.8426 Tj -0 -199.3606 Td -(3018 ) 21.8426 Tj -0 -208.8539 Td -(3019 ) 21.8426 Tj -0 -218.3473 Td -(3020 ) 21.8426 Tj -0 -227.8407 Td -(3021 ) 21.8426 Tj -0 -237.334 Td -(3022 ) 21.8426 Tj -0 -246.8274 Td -(3023 ) 21.8426 Tj -0 -256.3207 Td -(3024 ) 21.8426 Tj -0 -265.8141 Td -(3025 ) 21.8426 Tj -0 -275.3075 Td -(3026 ) 21.8426 Tj -0 -284.8008 Td -(3027 ) 21.8426 Tj -0 -294.2942 Td -(3028 ) 21.8426 Tj -0 -303.7875 Td -(3029 ) 21.8426 Tj -0 -313.2809 Td -(3030 ) 21.8426 Tj -0 -322.7743 Td -(3031 ) 21.8426 Tj -0 -332.2676 Td -(3032 ) 21.8426 Tj -0 -341.761 Td -(3033 ) 21.8426 Tj -0 -351.2543 Td -(3034 ) 21.8426 Tj -0 -360.7477 Td -(3035 ) 21.8426 Tj -0 -370.2411 Td -(3036 ) 21.8426 Tj -0 -379.7344 Td -(3037 ) 21.8426 Tj -0 -389.2278 Td -(3038 ) 21.8426 Tj -0 -398.7211 Td -(3039 ) 21.8426 Tj -0 -408.2145 Td -(3040 ) 21.8426 Tj -0 -417.7079 Td -(3041 ) 21.8426 Tj -0 -427.2012 Td -(3042 ) 21.8426 Tj -0 -436.6946 Td -(3043 ) 21.8426 Tj -0 -446.1879 Td -(3044 ) 21.8426 Tj -0 -455.6813 Td -(3045 ) 21.8426 Tj -0 -465.1747 Td -(3046 ) 21.8426 Tj -0 -474.668 Td -(3047 ) 21.8426 Tj -0 -484.1614 Td -(3048 ) 21.8426 Tj -0 -493.6547 Td -(3049 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 30) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fcntl.h Page 1) 166.0035 Tj -0 -28.4801 Td -(3050 #define O_RDONLY 0x000) 122.3184 Tj -0 -37.9735 Td -(3051 #define O_WRONLY 0x001) 122.3184 Tj -0 -47.4668 Td -(3052 #define O_RDWR 0x002) 122.3184 Tj -0 -56.9602 Td -(3053 #define O_CREATE 0x200) 122.3184 Tj -0 -66.4535 Td -(3054 ) 21.8426 Tj -0 -75.9469 Td -(3055 ) 21.8426 Tj -0 -85.4403 Td -(3056 ) 21.8426 Tj -0 -94.9336 Td -(3057 ) 21.8426 Tj -0 -104.427 Td -(3058 ) 21.8426 Tj -0 -113.9203 Td -(3059 ) 21.8426 Tj -0 -123.4137 Td -(3060 ) 21.8426 Tj -0 -132.9071 Td -(3061 ) 21.8426 Tj -0 -142.4004 Td -(3062 ) 21.8426 Tj -0 -151.8938 Td -(3063 ) 21.8426 Tj -0 -161.3871 Td -(3064 ) 21.8426 Tj -0 -170.8805 Td -(3065 ) 21.8426 Tj -0 -180.3739 Td -(3066 ) 21.8426 Tj -0 -189.8672 Td -(3067 ) 21.8426 Tj -0 -199.3606 Td -(3068 ) 21.8426 Tj -0 -208.8539 Td -(3069 ) 21.8426 Tj -0 -218.3473 Td -(3070 ) 21.8426 Tj -0 -227.8407 Td -(3071 ) 21.8426 Tj -0 -237.334 Td -(3072 ) 21.8426 Tj -0 -246.8274 Td -(3073 ) 21.8426 Tj -0 -256.3207 Td -(3074 ) 21.8426 Tj -0 -265.8141 Td -(3075 ) 21.8426 Tj -0 -275.3075 Td -(3076 ) 21.8426 Tj -0 -284.8008 Td -(3077 ) 21.8426 Tj -0 -294.2942 Td -(3078 ) 21.8426 Tj -0 -303.7875 Td -(3079 ) 21.8426 Tj -0 -313.2809 Td -(3080 ) 21.8426 Tj -0 -322.7743 Td -(3081 ) 21.8426 Tj -0 -332.2676 Td -(3082 ) 21.8426 Tj -0 -341.761 Td -(3083 ) 21.8426 Tj -0 -351.2543 Td -(3084 ) 21.8426 Tj -0 -360.7477 Td -(3085 ) 21.8426 Tj -0 -370.2411 Td -(3086 ) 21.8426 Tj -0 -379.7344 Td -(3087 ) 21.8426 Tj -0 -389.2278 Td -(3088 ) 21.8426 Tj -0 -398.7211 Td -(3089 ) 21.8426 Tj -0 -408.2145 Td -(3090 ) 21.8426 Tj -0 -417.7079 Td -(3091 ) 21.8426 Tj -0 -427.2012 Td -(3092 ) 21.8426 Tj -0 -436.6946 Td -(3093 ) 21.8426 Tj -0 -446.1879 Td -(3094 ) 21.8426 Tj -0 -455.6813 Td -(3095 ) 21.8426 Tj -0 -465.1747 Td -(3096 ) 21.8426 Tj -0 -474.668 Td -(3097 ) 21.8426 Tj -0 -484.1614 Td -(3098 ) 21.8426 Tj -0 -493.6547 Td -(3099 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 30) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 38 38 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/stat.h Page 1) 161.635 Tj -0 -28.4801 Td -(3100 #define T_DIR 1 // Directory) 157.2665 Tj -0 -37.9735 Td -(3101 #define T_FILE 2 // File) 135.4239 Tj -0 -47.4668 Td -(3102 #define T_DEV 3 // Special device) 179.1091 Tj -0 -56.9602 Td -(3103 ) 21.8426 Tj -0 -66.4535 Td -(3104 struct stat {) 78.6333 Tj -0 -75.9469 Td -(3105 short type; // Type of file) 152.898 Tj -0 -85.4403 Td -(3106 int dev; // Device number) 157.2665 Tj -0 -94.9336 Td -(3107 uint ino; // Inode number on device) 196.5831 Tj -0 -104.427 Td -(3108 short nlink; // Number of links to file) 200.9517 Tj -0 -113.9203 Td -(3109 uint size; // Size of file in bytes) 192.2146 Tj -0 -123.4137 Td -(3110 };) 30.5796 Tj -0 -132.9071 Td -(3111 ) 21.8426 Tj -0 -142.4004 Td -(3112 ) 21.8426 Tj -0 -151.8938 Td -(3113 ) 21.8426 Tj -0 -161.3871 Td -(3114 ) 21.8426 Tj -0 -170.8805 Td -(3115 ) 21.8426 Tj -0 -180.3739 Td -(3116 ) 21.8426 Tj -0 -189.8672 Td -(3117 ) 21.8426 Tj -0 -199.3606 Td -(3118 ) 21.8426 Tj -0 -208.8539 Td -(3119 ) 21.8426 Tj -0 -218.3473 Td -(3120 ) 21.8426 Tj -0 -227.8407 Td -(3121 ) 21.8426 Tj -0 -237.334 Td -(3122 ) 21.8426 Tj -0 -246.8274 Td -(3123 ) 21.8426 Tj -0 -256.3207 Td -(3124 ) 21.8426 Tj -0 -265.8141 Td -(3125 ) 21.8426 Tj -0 -275.3075 Td -(3126 ) 21.8426 Tj -0 -284.8008 Td -(3127 ) 21.8426 Tj -0 -294.2942 Td -(3128 ) 21.8426 Tj -0 -303.7875 Td -(3129 ) 21.8426 Tj -0 -313.2809 Td -(3130 ) 21.8426 Tj -0 -322.7743 Td -(3131 ) 21.8426 Tj -0 -332.2676 Td -(3132 ) 21.8426 Tj -0 -341.761 Td -(3133 ) 21.8426 Tj -0 -351.2543 Td -(3134 ) 21.8426 Tj -0 -360.7477 Td -(3135 ) 21.8426 Tj -0 -370.2411 Td -(3136 ) 21.8426 Tj -0 -379.7344 Td -(3137 ) 21.8426 Tj -0 -389.2278 Td -(3138 ) 21.8426 Tj -0 -398.7211 Td -(3139 ) 21.8426 Tj -0 -408.2145 Td -(3140 ) 21.8426 Tj -0 -417.7079 Td -(3141 ) 21.8426 Tj -0 -427.2012 Td -(3142 ) 21.8426 Tj -0 -436.6946 Td -(3143 ) 21.8426 Tj -0 -446.1879 Td -(3144 ) 21.8426 Tj -0 -455.6813 Td -(3145 ) 21.8426 Tj -0 -465.1747 Td -(3146 ) 21.8426 Tj -0 -474.668 Td -(3147 ) 21.8426 Tj -0 -484.1614 Td -(3148 ) 21.8426 Tj -0 -493.6547 Td -(3149 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 31) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.h Page 1) 152.898 Tj -0 -28.4801 Td -(3150 // On-disk file system format.) 152.898 Tj -0 -37.9735 Td -(3151 // Both the kernel and user programs use this header file.) 275.2164 Tj -0 -47.4668 Td -(3152 ) 21.8426 Tj -0 -56.9602 Td -(3153 // Block 0 is unused.) 113.5814 Tj -0 -66.4535 Td -(3154 // Block 1 is super block.) 135.4239 Tj -0 -75.9469 Td -(3155 // Inodes start at block 2.) 139.7925 Tj -0 -85.4403 Td -(3156 ) 21.8426 Tj -0 -94.9336 Td -(3157 #define ROOTINO 1 // root i-number) 174.7406 Tj -0 -104.427 Td -(3158 #define BSIZE 512 // block size) 161.635 Tj -0 -113.9203 Td -(3159 ) 21.8426 Tj -0 -123.4137 Td -(3160 // File system super block) 135.4239 Tj -0 -132.9071 Td -(3161 struct superblock {) 104.8443 Tj -0 -142.4004 Td -(3162 uint size; // Size of file system image \(blocks\ -\)) 275.2164 Tj -0 -151.8938 Td -(3163 uint nblocks; // Number of data blocks) 218.4257 Tj -0 -161.3871 Td -(3164 uint ninodes; // Number of inodes.) 200.9517 Tj -0 -170.8805 Td -(3165 };) 30.5796 Tj -0 -180.3739 Td -(3166 ) 21.8426 Tj -0 -189.8672 Td -(3167 #define NDIRECT 12) 100.4758 Tj -0 -199.3606 Td -(3168 #define NINDIRECT \(BSIZE / sizeof\(uint\)\)) 196.5831 Tj -0 -208.8539 Td -(3169 #define MAXFILE \(NDIRECT + NINDIRECT\)) 183.4776 Tj -0 -218.3473 Td -(3170 ) 21.8426 Tj -0 -227.8407 Td -(3171 // On-disk inode structure) 135.4239 Tj -0 -237.334 Td -(3172 struct dinode {) 87.3703 Tj -0 -246.8274 Td -(3173 short type; // File type) 179.1091 Tj -0 -256.3207 Td -(3174 short major; // Major device number \(T_DEV onl\ -y\)) 279.5849 Tj -0 -265.8141 Td -(3175 short minor; // Minor device number \(T_DEV onl\ -y\)) 279.5849 Tj -0 -275.3075 Td -(3176 short nlink; // Number of links to inode in fil\ -e system) 310.1645 Tj -0 -284.8008 Td -(3177 uint size; // Size of file \(bytes\)) 227.1628 Tj -0 -294.2942 Td -(3178 uint addrs[NDIRECT+1]; // Data block addresses) 240.2683 Tj -0 -303.7875 Td -(3179 };) 30.5796 Tj -0 -313.2809 Td -(3180 ) 21.8426 Tj -0 -322.7743 Td -(3181 // Inodes per block.) 109.2129 Tj -0 -332.2676 Td -(3182 #define IPB \(BSIZE / sizeof\(struct dinode\)\)) 253.3738 Tj -0 -341.761 Td -(3183 ) 21.8426 Tj -0 -351.2543 Td -(3184 // Block containing inode i) 139.7925 Tj -0 -360.7477 Td -(3185 #define IBLOCK\(i\) \(\(i\) / IPB + 2\)) 183.4776 Tj -0 -370.2411 Td -(3186 ) 21.8426 Tj -0 -379.7344 Td -(3187 // Bitmap bits per block) 126.6869 Tj -0 -389.2278 Td -(3188 #define BPB \(BSIZE*8\)) 157.2665 Tj -0 -398.7211 Td -(3189 ) 21.8426 Tj -0 -408.2145 Td -(3190 // Block containing bit for block b) 174.7406 Tj -0 -417.7079 Td -(3191 #define BBLOCK\(b, ninodes\) \(b/BPB + \(ninodes\)/IPB + 3\ -\)) 257.7424 Tj -0 -427.2012 Td -(3192 ) 21.8426 Tj -0 -436.6946 Td -(3193 ) 21.8426 Tj -0 -446.1879 Td -(3194 ) 21.8426 Tj -0 -455.6813 Td -(3195 ) 21.8426 Tj -0 -465.1747 Td -(3196 ) 21.8426 Tj -0 -474.668 Td -(3197 ) 21.8426 Tj -0 -484.1614 Td -(3198 ) 21.8426 Tj -0 -493.6547 Td -(3199 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 31) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 39 39 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.h Page 2) 152.898 Tj -0 -28.4801 Td -(3200 // Directory is a file containing a sequence of dirent str\ -uctures.) 310.1645 Tj -0 -37.9735 Td -(3201 #define DIRSIZ 14) 96.1073 Tj -0 -47.4668 Td -(3202 ) 21.8426 Tj -0 -56.9602 Td -(3203 struct dirent {) 87.3703 Tj -0 -66.4535 Td -(3204 ushort inum;) 83.0018 Tj -0 -75.9469 Td -(3205 char name[DIRSIZ];) 109.2129 Tj -0 -85.4403 Td -(3206 };) 30.5796 Tj -0 -94.9336 Td -(3207 ) 21.8426 Tj -0 -104.427 Td -(3208 ) 21.8426 Tj -0 -113.9203 Td -(3209 ) 21.8426 Tj -0 -123.4137 Td -(3210 ) 21.8426 Tj -0 -132.9071 Td -(3211 ) 21.8426 Tj -0 -142.4004 Td -(3212 ) 21.8426 Tj -0 -151.8938 Td -(3213 ) 21.8426 Tj -0 -161.3871 Td -(3214 ) 21.8426 Tj -0 -170.8805 Td -(3215 ) 21.8426 Tj -0 -180.3739 Td -(3216 ) 21.8426 Tj -0 -189.8672 Td -(3217 ) 21.8426 Tj -0 -199.3606 Td -(3218 ) 21.8426 Tj -0 -208.8539 Td -(3219 ) 21.8426 Tj -0 -218.3473 Td -(3220 ) 21.8426 Tj -0 -227.8407 Td -(3221 ) 21.8426 Tj -0 -237.334 Td -(3222 ) 21.8426 Tj -0 -246.8274 Td -(3223 ) 21.8426 Tj -0 -256.3207 Td -(3224 ) 21.8426 Tj -0 -265.8141 Td -(3225 ) 21.8426 Tj -0 -275.3075 Td -(3226 ) 21.8426 Tj -0 -284.8008 Td -(3227 ) 21.8426 Tj -0 -294.2942 Td -(3228 ) 21.8426 Tj -0 -303.7875 Td -(3229 ) 21.8426 Tj -0 -313.2809 Td -(3230 ) 21.8426 Tj -0 -322.7743 Td -(3231 ) 21.8426 Tj -0 -332.2676 Td -(3232 ) 21.8426 Tj -0 -341.761 Td -(3233 ) 21.8426 Tj -0 -351.2543 Td -(3234 ) 21.8426 Tj -0 -360.7477 Td -(3235 ) 21.8426 Tj -0 -370.2411 Td -(3236 ) 21.8426 Tj -0 -379.7344 Td -(3237 ) 21.8426 Tj -0 -389.2278 Td -(3238 ) 21.8426 Tj -0 -398.7211 Td -(3239 ) 21.8426 Tj -0 -408.2145 Td -(3240 ) 21.8426 Tj -0 -417.7079 Td -(3241 ) 21.8426 Tj -0 -427.2012 Td -(3242 ) 21.8426 Tj -0 -436.6946 Td -(3243 ) 21.8426 Tj -0 -446.1879 Td -(3244 ) 21.8426 Tj -0 -455.6813 Td -(3245 ) 21.8426 Tj -0 -465.1747 Td -(3246 ) 21.8426 Tj -0 -474.668 Td -(3247 ) 21.8426 Tj -0 -484.1614 Td -(3248 ) 21.8426 Tj -0 -493.6547 Td -(3249 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 32) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/file.h Page 1) 161.635 Tj -0 -28.4801 Td -(3250 struct file {) 78.6333 Tj -0 -37.9735 Td -(3251 enum { FD_NONE, FD_PIPE, FD_INODE } type;) 209.6887 Tj -0 -47.4668 Td -(3252 int ref; // reference count) 148.5295 Tj -0 -56.9602 Td -(3253 char readable;) 91.7388 Tj -0 -66.4535 Td -(3254 char writable;) 91.7388 Tj -0 -75.9469 Td -(3255 struct pipe *pipe;) 109.2129 Tj -0 -85.4403 Td -(3256 struct inode *ip;) 104.8443 Tj -0 -94.9336 Td -(3257 uint off;) 69.8962 Tj -0 -104.427 Td -(3258 };) 30.5796 Tj -0 -113.9203 Td -(3259 ) 21.8426 Tj -0 -123.4137 Td -(3260 ) 21.8426 Tj -0 -132.9071 Td -(3261 // in-core file system types) 144.161 Tj -0 -142.4004 Td -(3262 ) 21.8426 Tj -0 -151.8938 Td -(3263 struct inode {) 83.0018 Tj -0 -161.3871 Td -(3264 uint dev; // Device number) 187.8461 Tj -0 -170.8805 Td -(3265 uint inum; // Inode number) 183.4776 Tj -0 -180.3739 Td -(3266 int ref; // Reference count) 196.5831 Tj -0 -189.8672 Td -(3267 int flags; // I_BUSY, I_VALID) 196.5831 Tj -0 -199.3606 Td -(3268 ) 21.8426 Tj -0 -208.8539 Td -(3269 short type; // copy of disk inode) 209.6887 Tj -0 -218.3473 Td -(3270 short major;) 83.0018 Tj -0 -227.8407 Td -(3271 short minor;) 83.0018 Tj -0 -237.334 Td -(3272 short nlink;) 83.0018 Tj -0 -246.8274 Td -(3273 uint size;) 74.2647 Tj -0 -256.3207 Td -(3274 uint addrs[NDIRECT+1];) 126.6869 Tj -0 -265.8141 Td -(3275 };) 30.5796 Tj -0 -275.3075 Td -(3276 ) 21.8426 Tj -0 -284.8008 Td -(3277 #define I_BUSY 0x1) 100.4758 Tj -0 -294.2942 Td -(3278 #define I_VALID 0x2) 104.8443 Tj -0 -303.7875 Td -(3279 ) 21.8426 Tj -0 -313.2809 Td -(3280 ) 21.8426 Tj -0 -322.7743 Td -(3281 // device implementations) 131.0554 Tj -0 -332.2676 Td -(3282 ) 21.8426 Tj -0 -341.761 Td -(3283 struct devsw {) 83.0018 Tj -0 -351.2543 Td -(3284 int \(*read\)\(struct inode*, char*, int\);) 200.9517 Tj -0 -360.7477 Td -(3285 int \(*write\)\(struct inode*, char*, int\);) 205.3202 Tj -0 -370.2411 Td -(3286 };) 30.5796 Tj -0 -379.7344 Td -(3287 ) 21.8426 Tj -0 -389.2278 Td -(3288 extern struct devsw devsw[];) 144.161 Tj -0 -398.7211 Td -(3289 ) 21.8426 Tj -0 -408.2145 Td -(3290 #define CONSOLE 1) 96.1073 Tj -0 -417.7079 Td -(3291 ) 21.8426 Tj -0 -427.2012 Td -(3292 ) 21.8426 Tj -0 -436.6946 Td -(3293 ) 21.8426 Tj -0 -446.1879 Td -(3294 ) 21.8426 Tj -0 -455.6813 Td -(3295 ) 21.8426 Tj -0 -465.1747 Td -(3296 ) 21.8426 Tj -0 -474.668 Td -(3297 ) 21.8426 Tj -0 -484.1614 Td -(3298 ) 21.8426 Tj -0 -493.6547 Td -(3299 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 32) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 40 40 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/ide.c Page 1) 157.2665 Tj -0 -28.4801 Td -(3300 // Simple PIO-based \(non-DMA\) IDE driver code.) 222.7942 Tj -0 -37.9735 Td -(3301 ) 21.8426 Tj -0 -47.4668 Td -(3302 #include "types.h") 100.4758 Tj -0 -56.9602 Td -(3303 #include "defs.h") 96.1073 Tj -0 -66.4535 Td -(3304 #include "param.h") 100.4758 Tj -0 -75.9469 Td -(3305 #include "mmu.h") 91.7388 Tj -0 -85.4403 Td -(3306 #include "proc.h") 96.1073 Tj -0 -94.9336 Td -(3307 #include "x86.h") 91.7388 Tj -0 -104.427 Td -(3308 #include "traps.h") 100.4758 Tj -0 -113.9203 Td -(3309 #include "spinlock.h") 113.5814 Tj -0 -123.4137 Td -(3310 #include "buf.h") 91.7388 Tj -0 -132.9071 Td -(3311 ) 21.8426 Tj -0 -142.4004 Td -(3312 #define IDE_BSY 0x80) 135.4239 Tj -0 -151.8938 Td -(3313 #define IDE_DRDY 0x40) 135.4239 Tj -0 -161.3871 Td -(3314 #define IDE_DF 0x20) 135.4239 Tj -0 -170.8805 Td -(3315 #define IDE_ERR 0x01) 135.4239 Tj -0 -180.3739 Td -(3316 ) 21.8426 Tj -0 -189.8672 Td -(3317 #define IDE_CMD_READ 0x20) 135.4239 Tj -0 -199.3606 Td -(3318 #define IDE_CMD_WRITE 0x30) 135.4239 Tj -0 -208.8539 Td -(3319 ) 21.8426 Tj -0 -218.3473 Td -(3320 // idequeue points to the buf now being read/written to th\ -e disk.) 305.796 Tj -0 -227.8407 Td -(3321 // idequeue->qnext points to the next buf to be processed.) 275.2164 Tj -0 -237.334 Td -(3322 // You must hold idelock while manipulating queue.) 240.2683 Tj -0 -246.8274 Td -(3323 ) 21.8426 Tj -0 -256.3207 Td -(3324 static struct spinlock idelock;) 157.2665 Tj -0 -265.8141 Td -(3325 static struct buf *idequeue;) 144.161 Tj -0 -275.3075 Td -(3326 ) 21.8426 Tj -0 -284.8008 Td -(3327 static int havedisk1;) 113.5814 Tj -0 -294.2942 Td -(3328 static void idestart\(struct buf*\);) 170.3721 Tj -0 -303.7875 Td -(3329 ) 21.8426 Tj -0 -313.2809 Td -(3330 // Wait for IDE disk to become ready.) 183.4776 Tj -0 -322.7743 Td -(3331 static int) 65.5277 Tj -0 -332.2676 Td -(3332 idewait\(int checkerr\)) 113.5814 Tj -0 -341.761 Td -(3333 {) 26.2111 Tj -0 -351.2543 Td -(3334 int r;) 56.7907 Tj -0 -360.7477 Td -(3335 ) 21.8426 Tj -0 -370.2411 Td -(3336 while\(\(\(r = inb\(0x1f7\)\) & \(IDE_BSY|IDE_DRDY\)\) !\ -= IDE_DRDY\)) 283.9534 Tj -0 -379.7344 Td -(3337 ;) 43.6851 Tj -0 -389.2278 Td -(3338 if\(checkerr && \(r & \(IDE_DF|IDE_ERR\)\) != 0\)) 218.4257 Tj -0 -398.7211 Td -(3339 return -1;) 83.0018 Tj -0 -408.2145 Td -(3340 return 0;) 69.8962 Tj -0 -417.7079 Td -(3341 }) 26.2111 Tj -0 -427.2012 Td -(3342 ) 21.8426 Tj -0 -436.6946 Td -(3343 ) 21.8426 Tj -0 -446.1879 Td -(3344 ) 21.8426 Tj -0 -455.6813 Td -(3345 ) 21.8426 Tj -0 -465.1747 Td -(3346 ) 21.8426 Tj -0 -474.668 Td -(3347 ) 21.8426 Tj -0 -484.1614 Td -(3348 ) 21.8426 Tj -0 -493.6547 Td -(3349 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 33) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/ide.c Page 2) 157.2665 Tj -0 -28.4801 Td -(3350 void) 39.3166 Tj -0 -37.9735 Td -(3351 ideinit\(void\)) 78.6333 Tj -0 -47.4668 Td -(3352 {) 26.2111 Tj -0 -56.9602 Td -(3353 int i;) 56.7907 Tj -0 -66.4535 Td -(3354 ) 21.8426 Tj -0 -75.9469 Td -(3355 initlock\(&idelock, "ide"\);) 144.161 Tj -0 -85.4403 Td -(3356 picenable\(IRQ_IDE\);) 113.5814 Tj -0 -94.9336 Td -(3357 ioapicenable\(IRQ_IDE, ncpu - 1\);) 170.3721 Tj -0 -104.427 Td -(3358 idewait\(0\);) 78.6333 Tj -0 -113.9203 Td -(3359 ) 21.8426 Tj -0 -123.4137 Td -(3360 // Check if disk 1 is present) 157.2665 Tj -0 -132.9071 Td -(3361 outb\(0x1f6, 0xe0 | \(1<<4\)\);) 148.5295 Tj -0 -142.4004 Td -(3362 for\(i=0; i<1000; i++\){) 126.6869 Tj -0 -151.8938 Td -(3363 if\(inb\(0x1f7\) != 0\){) 126.6869 Tj -0 -161.3871 Td -(3364 havedisk1 = 1;) 109.2129 Tj -0 -170.8805 Td -(3365 break;) 74.2647 Tj -0 -180.3739 Td -(3366 }) 43.6851 Tj -0 -189.8672 Td -(3367 }) 34.9481 Tj -0 -199.3606 Td -(3368 ) 21.8426 Tj -0 -208.8539 Td -(3369 // Switch back to disk 0.) 139.7925 Tj -0 -218.3473 Td -(3370 outb\(0x1f6, 0xe0 | \(0<<4\)\);) 148.5295 Tj -0 -227.8407 Td -(3371 }) 26.2111 Tj -0 -237.334 Td -(3372 ) 21.8426 Tj -0 -246.8274 Td -(3373 // Start the request for b. Caller must hold idelock.) 257.7424 Tj -0 -256.3207 Td -(3374 static void) 69.8962 Tj -0 -265.8141 Td -(3375 idestart\(struct buf *b\)) 122.3184 Tj -0 -275.3075 Td -(3376 {) 26.2111 Tj -0 -284.8008 Td -(3377 if\(b == 0\)) 74.2647 Tj -0 -294.2942 Td -(3378 panic\("idestart"\);) 117.9499 Tj -0 -303.7875 Td -(3379 ) 21.8426 Tj -0 -313.2809 Td -(3380 idewait\(0\);) 78.6333 Tj -0 -322.7743 Td -(3381 outb\(0x3f6, 0\); // generate interrupt) 196.5831 Tj -0 -332.2676 Td -(3382 outb\(0x1f2, 1\); // number of sectors) 192.2146 Tj -0 -341.761 Td -(3383 outb\(0x1f3, b->sector & 0xff\);) 161.635 Tj -0 -351.2543 Td -(3384 outb\(0x1f4, \(b->sector >> 8\) & 0xff\);) 192.2146 Tj -0 -360.7477 Td -(3385 outb\(0x1f5, \(b->sector >> 16\) & 0xff\);) 196.5831 Tj -0 -370.2411 Td -(3386 outb\(0x1f6, 0xe0 | \(\(b->dev&1\)<<4\) | \(\(b->sector>\ ->24\)&0x0f\)\);) 297.059 Tj -0 -379.7344 Td -(3387 if\(b->flags & B_DIRTY\){) 131.0554 Tj -0 -389.2278 Td -(3388 outb\(0x1f7, IDE_CMD_WRITE\);) 157.2665 Tj -0 -398.7211 Td -(3389 outsl\(0x1f0, b->data, 512/4\);) 166.0035 Tj -0 -408.2145 Td -(3390 } else {) 65.5277 Tj -0 -417.7079 Td -(3391 outb\(0x1f7, IDE_CMD_READ\);) 152.898 Tj -0 -427.2012 Td -(3392 }) 34.9481 Tj -0 -436.6946 Td -(3393 }) 26.2111 Tj -0 -446.1879 Td -(3394 ) 21.8426 Tj -0 -455.6813 Td -(3395 ) 21.8426 Tj -0 -465.1747 Td -(3396 ) 21.8426 Tj -0 -474.668 Td -(3397 ) 21.8426 Tj -0 -484.1614 Td -(3398 ) 21.8426 Tj -0 -493.6547 Td -(3399 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 33) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 41 41 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/ide.c Page 3) 157.2665 Tj -0 -28.4801 Td -(3400 // Interrupt handler.) 113.5814 Tj -0 -37.9735 Td -(3401 void) 39.3166 Tj -0 -47.4668 Td -(3402 ideintr\(void\)) 78.6333 Tj -0 -56.9602 Td -(3403 {) 26.2111 Tj -0 -66.4535 Td -(3404 struct buf *b;) 91.7388 Tj -0 -75.9469 Td -(3405 ) 21.8426 Tj -0 -85.4403 Td -(3406 // Take first buffer off queue.) 166.0035 Tj -0 -94.9336 Td -(3407 acquire\(&idelock\);) 109.2129 Tj -0 -104.427 Td -(3408 if\(\(b = idequeue\) == 0\){) 135.4239 Tj -0 -113.9203 Td -(3409 release\(&idelock\);) 117.9499 Tj -0 -123.4137 Td -(3410 cprintf\("Spurious IDE interrupt.\\n"\);) 200.9517 Tj -0 -132.9071 Td -(3411 return;) 69.8962 Tj -0 -142.4004 Td -(3412 }) 34.9481 Tj -0 -151.8938 Td -(3413 idequeue = b->qnext;) 117.9499 Tj -0 -161.3871 Td -(3414 ) 21.8426 Tj -0 -170.8805 Td -(3415 // Read data if needed.) 131.0554 Tj -0 -180.3739 Td -(3416 if\(!\(b->flags & B_DIRTY\) && idewait\(1\) >= 0\)) 222.7942 Tj -0 -189.8672 Td -(3417 insl\(0x1f0, b->data, 512/4\);) 161.635 Tj -0 -199.3606 Td -(3418 ) 21.8426 Tj -0 -208.8539 Td -(3419 // Wake process waiting for this buf.) 192.2146 Tj -0 -218.3473 Td -(3420 b->flags |= B_VALID;) 117.9499 Tj -0 -227.8407 Td -(3421 b->flags &= ~B_DIRTY;) 122.3184 Tj -0 -237.334 Td -(3422 wakeup\(b\);) 74.2647 Tj -0 -246.8274 Td -(3423 ) 21.8426 Tj -0 -256.3207 Td -(3424 // Start disk on next buf in queue.) 183.4776 Tj -0 -265.8141 Td -(3425 if\(idequeue != 0\)) 104.8443 Tj -0 -275.3075 Td -(3426 idestart\(idequeue\);) 122.3184 Tj -0 -284.8008 Td -(3427 ) 21.8426 Tj -0 -294.2942 Td -(3428 release\(&idelock\);) 109.2129 Tj -0 -303.7875 Td -(3429 }) 26.2111 Tj -0 -313.2809 Td -(3430 ) 21.8426 Tj -0 -322.7743 Td -(3431 ) 21.8426 Tj -0 -332.2676 Td -(3432 ) 21.8426 Tj -0 -341.761 Td -(3433 ) 21.8426 Tj -0 -351.2543 Td -(3434 ) 21.8426 Tj -0 -360.7477 Td -(3435 ) 21.8426 Tj -0 -370.2411 Td -(3436 ) 21.8426 Tj -0 -379.7344 Td -(3437 ) 21.8426 Tj -0 -389.2278 Td -(3438 ) 21.8426 Tj -0 -398.7211 Td -(3439 ) 21.8426 Tj -0 -408.2145 Td -(3440 ) 21.8426 Tj -0 -417.7079 Td -(3441 ) 21.8426 Tj -0 -427.2012 Td -(3442 ) 21.8426 Tj -0 -436.6946 Td -(3443 ) 21.8426 Tj -0 -446.1879 Td -(3444 ) 21.8426 Tj -0 -455.6813 Td -(3445 ) 21.8426 Tj -0 -465.1747 Td -(3446 ) 21.8426 Tj -0 -474.668 Td -(3447 ) 21.8426 Tj -0 -484.1614 Td -(3448 ) 21.8426 Tj -0 -493.6547 Td -(3449 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 34) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/ide.c Page 4) 157.2665 Tj -0 -28.4801 Td -(3450 // Sync buf with disk.) 117.9499 Tj -0 -37.9735 Td -(3451 // If B_DIRTY is set, write buf to disk, clear B_DIRTY, se\ -t B_VALID.) 318.9016 Tj -0 -47.4668 Td -(3452 // Else if B_VALID is not set, read buf from disk, set B_V\ -ALID.) 297.059 Tj -0 -56.9602 Td -(3453 void) 39.3166 Tj -0 -66.4535 Td -(3454 iderw\(struct buf *b\)) 109.2129 Tj -0 -75.9469 Td -(3455 {) 26.2111 Tj -0 -85.4403 Td -(3456 struct buf **pp;) 100.4758 Tj -0 -94.9336 Td -(3457 ) 21.8426 Tj -0 -104.427 Td -(3458 if\(!\(b->flags & B_BUSY\)\)) 135.4239 Tj -0 -113.9203 Td -(3459 panic\("iderw: buf not busy"\);) 166.0035 Tj -0 -123.4137 Td -(3460 if\(\(b->flags & \(B_VALID|B_DIRTY\)\) == B_VALID\)) 227.1628 Tj -0 -132.9071 Td -(3461 panic\("iderw: nothing to do"\);) 170.3721 Tj -0 -142.4004 Td -(3462 if\(b->dev != 0 && !havedisk1\)) 157.2665 Tj -0 -151.8938 Td -(3463 panic\("idrw: ide disk 1 not present"\);) 205.3202 Tj -0 -161.3871 Td -(3464 ) 21.8426 Tj -0 -170.8805 Td -(3465 acquire\(&idelock\);) 109.2129 Tj -0 -180.3739 Td -(3466 ) 21.8426 Tj -0 -189.8672 Td -(3467 // Append b to idequeue.) 135.4239 Tj -0 -199.3606 Td -(3468 b->qnext = 0;) 87.3703 Tj -0 -208.8539 Td -(3469 for\(pp=&idequeue; *pp; pp=&\(*pp\)->qnext\)) 205.3202 Tj -0 -218.3473 Td -(3470 ;) 43.6851 Tj -0 -227.8407 Td -(3471 *pp = b;) 65.5277 Tj -0 -237.334 Td -(3472 ) 21.8426 Tj -0 -246.8274 Td -(3473 // Start disk if necessary.) 148.5295 Tj -0 -256.3207 Td -(3474 if\(idequeue == b\)) 104.8443 Tj -0 -265.8141 Td -(3475 idestart\(b\);) 91.7388 Tj -0 -275.3075 Td -(3476 ) 21.8426 Tj -0 -284.8008 Td -(3477 // Wait for request to finish.) 161.635 Tj -0 -294.2942 Td -(3478 // Assuming will not sleep too long: ignore proc->killed\ -.) 279.5849 Tj -0 -303.7875 Td -(3479 while\(\(b->flags & \(B_VALID|B_DIRTY\)\) != B_VALID\)) 240.2683 Tj -0 -313.2809 Td -(3480 sleep\(b, &idelock\);) 122.3184 Tj -0 -322.7743 Td -(3481 ) 21.8426 Tj -0 -332.2676 Td -(3482 release\(&idelock\);) 109.2129 Tj -0 -341.761 Td -(3483 }) 26.2111 Tj -0 -351.2543 Td -(3484 ) 21.8426 Tj -0 -360.7477 Td -(3485 ) 21.8426 Tj -0 -370.2411 Td -(3486 ) 21.8426 Tj -0 -379.7344 Td -(3487 ) 21.8426 Tj -0 -389.2278 Td -(3488 ) 21.8426 Tj -0 -398.7211 Td -(3489 ) 21.8426 Tj -0 -408.2145 Td -(3490 ) 21.8426 Tj -0 -417.7079 Td -(3491 ) 21.8426 Tj -0 -427.2012 Td -(3492 ) 21.8426 Tj -0 -436.6946 Td -(3493 ) 21.8426 Tj -0 -446.1879 Td -(3494 ) 21.8426 Tj -0 -455.6813 Td -(3495 ) 21.8426 Tj -0 -465.1747 Td -(3496 ) 21.8426 Tj -0 -474.668 Td -(3497 ) 21.8426 Tj -0 -484.1614 Td -(3498 ) 21.8426 Tj -0 -493.6547 Td -(3499 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 34) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 42 42 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/bio.c Page 1) 157.2665 Tj -0 -28.4801 Td -(3500 // Buffer cache.) 91.7388 Tj -0 -37.9735 Td -(3501 //) 30.5796 Tj -0 -47.4668 Td -(3502 // The buffer cache is a linked list of buf structures hol\ -ding) 292.6905 Tj -0 -56.9602 Td -(3503 // cached copies of disk block contents. Caching disk blo\ -cks) 288.322 Tj -0 -66.4535 Td -(3504 // in memory reduces the number of disk reads and also pro\ -vides) 297.059 Tj -0 -75.9469 Td -(3505 // a synchronization point for disk blocks used by multipl\ -e processes.) 327.6386 Tj -0 -85.4403 Td -(3506 //) 30.5796 Tj -0 -94.9336 Td -(3507 // Interface:) 78.6333 Tj -0 -104.427 Td -(3508 // * To get a buffer for a particular disk block, call bre\ -ad.) 288.322 Tj -0 -113.9203 Td -(3509 // * After changing buffer data, call bwrite to flush it t\ -o disk.) 305.796 Tj -0 -123.4137 Td -(3510 // * When done with the buffer, call brelse.) 214.0572 Tj -0 -132.9071 Td -(3511 // * Do not use the buffer after calling brelse.) 231.5313 Tj -0 -142.4004 Td -(3512 // * Only one process at a time can use a buffer,) 235.8998 Tj -0 -151.8938 Td -(3513 // so do not keep them longer than necessary.) 235.8998 Tj -0 -161.3871 Td -(3514 //) 30.5796 Tj -0 -170.8805 Td -(3515 // The implementation uses three state flags internally:) 266.4794 Tj -0 -180.3739 Td -(3516 // * B_BUSY: the block has been returned from bread) 244.6368 Tj -0 -189.8672 Td -(3517 // and has not been passed back to brelse.) 222.7942 Tj -0 -199.3606 Td -(3518 // * B_VALID: the buffer data has been initialized) 240.2683 Tj -0 -208.8539 Td -(3519 // with the associated disk block contents.) 227.1628 Tj -0 -218.3473 Td -(3520 // * B_DIRTY: the buffer data has been modified) 227.1628 Tj -0 -227.8407 Td -(3521 // and needs to be written to disk.) 192.2146 Tj -0 -237.334 Td -(3522 ) 21.8426 Tj -0 -246.8274 Td -(3523 #include "types.h") 100.4758 Tj -0 -256.3207 Td -(3524 #include "defs.h") 96.1073 Tj -0 -265.8141 Td -(3525 #include "param.h") 100.4758 Tj -0 -275.3075 Td -(3526 #include "spinlock.h") 113.5814 Tj -0 -284.8008 Td -(3527 #include "buf.h") 91.7388 Tj -0 -294.2942 Td -(3528 ) 21.8426 Tj -0 -303.7875 Td -(3529 struct {) 56.7907 Tj -0 -313.2809 Td -(3530 struct spinlock lock;) 122.3184 Tj -0 -322.7743 Td -(3531 struct buf buf[NBUF];) 122.3184 Tj -0 -332.2676 Td -(3532 ) 21.8426 Tj -0 -341.761 Td -(3533 // Linked list of all buffers, through prev/next.) 244.6368 Tj -0 -351.2543 Td -(3534 // head.next is most recently used.) 183.4776 Tj -0 -360.7477 Td -(3535 struct buf head;) 100.4758 Tj -0 -370.2411 Td -(3536 } bcache;) 61.1592 Tj -0 -379.7344 Td -(3537 ) 21.8426 Tj -0 -389.2278 Td -(3538 void) 39.3166 Tj -0 -398.7211 Td -(3539 binit\(void\)) 69.8962 Tj -0 -408.2145 Td -(3540 {) 26.2111 Tj -0 -417.7079 Td -(3541 struct buf *b;) 91.7388 Tj -0 -427.2012 Td -(3542 ) 21.8426 Tj -0 -436.6946 Td -(3543 initlock\(&bcache.lock, "bcache"\);) 174.7406 Tj -0 -446.1879 Td -(3544 ) 21.8426 Tj -0 -455.6813 Td -(3545 ) 21.8426 Tj -0 -465.1747 Td -(3546 ) 21.8426 Tj -0 -474.668 Td -(3547 ) 21.8426 Tj -0 -484.1614 Td -(3548 ) 21.8426 Tj -0 -493.6547 Td -(3549 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 35) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/bio.c Page 2) 157.2665 Tj -0 -28.4801 Td -(3550 // Create linked list of buffers) 170.3721 Tj -0 -37.9735 Td -(3551 bcache.head.prev = &bcache.head;) 170.3721 Tj -0 -47.4668 Td -(3552 bcache.head.next = &bcache.head;) 170.3721 Tj -0 -56.9602 Td -(3553 for\(b = bcache.buf; b < bcache.buf+NBUF; b++\){) 231.5313 Tj -0 -66.4535 Td -(3554 b->next = bcache.head.next;) 157.2665 Tj -0 -75.9469 Td -(3555 b->prev = &bcache.head;) 139.7925 Tj -0 -85.4403 Td -(3556 b->dev = -1;) 91.7388 Tj -0 -94.9336 Td -(3557 bcache.head.next->prev = b;) 157.2665 Tj -0 -104.427 Td -(3558 bcache.head.next = b;) 131.0554 Tj -0 -113.9203 Td -(3559 }) 34.9481 Tj -0 -123.4137 Td -(3560 }) 26.2111 Tj -0 -132.9071 Td -(3561 ) 21.8426 Tj -0 -142.4004 Td -(3562 // Look through buffer cache for sector on device dev.) 257.7424 Tj -0 -151.8938 Td -(3563 // If not found, allocate fresh block.) 187.8461 Tj -0 -161.3871 Td -(3564 // In either case, return locked buffer.) 196.5831 Tj -0 -170.8805 Td -(3565 static struct buf*) 100.4758 Tj -0 -180.3739 Td -(3566 bget\(uint dev, uint sector\)) 139.7925 Tj -0 -189.8672 Td -(3567 {) 26.2111 Tj -0 -199.3606 Td -(3568 struct buf *b;) 91.7388 Tj -0 -208.8539 Td -(3569 ) 21.8426 Tj -0 -218.3473 Td -(3570 acquire\(&bcache.lock\);) 126.6869 Tj -0 -227.8407 Td -(3571 ) 21.8426 Tj -0 -237.334 Td -(3572 loop:) 48.0537 Tj -0 -246.8274 Td -(3573 // Try for cached block.) 135.4239 Tj -0 -256.3207 Td -(3574 for\(b = bcache.head.next; b != &bcache.head; b = b->nex\ -t\){) 283.9534 Tj -0 -265.8141 Td -(3575 if\(b->dev == dev && b->sector == sector\){) 218.4257 Tj -0 -275.3075 Td -(3576 if\(!\(b->flags & B_BUSY\)\){) 157.2665 Tj -0 -284.8008 Td -(3577 b->flags |= B_BUSY;) 139.7925 Tj -0 -294.2942 Td -(3578 release\(&bcache.lock\);) 152.898 Tj -0 -303.7875 Td -(3579 return b;) 96.1073 Tj -0 -313.2809 Td -(3580 }) 52.4222 Tj -0 -322.7743 Td -(3581 sleep\(b, &bcache.lock\);) 148.5295 Tj -0 -332.2676 Td -(3582 goto loop;) 91.7388 Tj -0 -341.761 Td -(3583 }) 43.6851 Tj -0 -351.2543 Td -(3584 }) 34.9481 Tj -0 -360.7477 Td -(3585 ) 21.8426 Tj -0 -370.2411 Td -(3586 // Allocate fresh block.) 135.4239 Tj -0 -379.7344 Td -(3587 for\(b = bcache.head.prev; b != &bcache.head; b = b->pre\ -v\){) 283.9534 Tj -0 -389.2278 Td -(3588 if\(\(b->flags & B_BUSY\) == 0\){) 166.0035 Tj -0 -398.7211 Td -(3589 b->dev = dev;) 104.8443 Tj -0 -408.2145 Td -(3590 b->sector = sector;) 131.0554 Tj -0 -417.7079 Td -(3591 b->flags = B_BUSY;) 126.6869 Tj -0 -427.2012 Td -(3592 release\(&bcache.lock\);) 144.161 Tj -0 -436.6946 Td -(3593 return b;) 87.3703 Tj -0 -446.1879 Td -(3594 }) 43.6851 Tj -0 -455.6813 Td -(3595 }) 34.9481 Tj -0 -465.1747 Td -(3596 panic\("bget: no buffers"\);) 144.161 Tj -0 -474.668 Td -(3597 }) 26.2111 Tj -0 -484.1614 Td -(3598 ) 21.8426 Tj -0 -493.6547 Td -(3599 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 35) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 43 43 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/bio.c Page 3) 157.2665 Tj -0 -28.4801 Td -(3600 // Return a B_BUSY buf with the contents of the indicated \ -disk sector.) 327.6386 Tj -0 -37.9735 Td -(3601 struct buf*) 69.8962 Tj -0 -47.4668 Td -(3602 bread\(uint dev, uint sector\)) 144.161 Tj -0 -56.9602 Td -(3603 {) 26.2111 Tj -0 -66.4535 Td -(3604 struct buf *b;) 91.7388 Tj -0 -75.9469 Td -(3605 ) 21.8426 Tj -0 -85.4403 Td -(3606 b = bget\(dev, sector\);) 126.6869 Tj -0 -94.9336 Td -(3607 if\(!\(b->flags & B_VALID\)\)) 139.7925 Tj -0 -104.427 Td -(3608 iderw\(b\);) 78.6333 Tj -0 -113.9203 Td -(3609 return b;) 69.8962 Tj -0 -123.4137 Td -(3610 }) 26.2111 Tj -0 -132.9071 Td -(3611 ) 21.8426 Tj -0 -142.4004 Td -(3612 // Write b's contents to disk. Must be locked.) 227.1628 Tj -0 -151.8938 Td -(3613 void) 39.3166 Tj -0 -161.3871 Td -(3614 bwrite\(struct buf *b\)) 113.5814 Tj -0 -170.8805 Td -(3615 {) 26.2111 Tj -0 -180.3739 Td -(3616 if\(\(b->flags & B_BUSY\) == 0\)) 152.898 Tj -0 -189.8672 Td -(3617 panic\("bwrite"\);) 109.2129 Tj -0 -199.3606 Td -(3618 b->flags |= B_DIRTY;) 117.9499 Tj -0 -208.8539 Td -(3619 iderw\(b\);) 69.8962 Tj -0 -218.3473 Td -(3620 }) 26.2111 Tj -0 -227.8407 Td -(3621 ) 21.8426 Tj -0 -237.334 Td -(3622 // Release the buffer b.) 126.6869 Tj -0 -246.8274 Td -(3623 void) 39.3166 Tj -0 -256.3207 Td -(3624 brelse\(struct buf *b\)) 113.5814 Tj -0 -265.8141 Td -(3625 {) 26.2111 Tj -0 -275.3075 Td -(3626 if\(\(b->flags & B_BUSY\) == 0\)) 152.898 Tj -0 -284.8008 Td -(3627 panic\("brelse"\);) 109.2129 Tj -0 -294.2942 Td -(3628 ) 21.8426 Tj -0 -303.7875 Td -(3629 acquire\(&bcache.lock\);) 126.6869 Tj -0 -313.2809 Td -(3630 ) 21.8426 Tj -0 -322.7743 Td -(3631 b->next->prev = b->prev;) 135.4239 Tj -0 -332.2676 Td -(3632 b->prev->next = b->next;) 135.4239 Tj -0 -341.761 Td -(3633 b->next = bcache.head.next;) 148.5295 Tj -0 -351.2543 Td -(3634 b->prev = &bcache.head;) 131.0554 Tj -0 -360.7477 Td -(3635 bcache.head.next->prev = b;) 148.5295 Tj -0 -370.2411 Td -(3636 bcache.head.next = b;) 122.3184 Tj -0 -379.7344 Td -(3637 ) 21.8426 Tj -0 -389.2278 Td -(3638 b->flags &= ~B_BUSY;) 117.9499 Tj -0 -398.7211 Td -(3639 wakeup\(b\);) 74.2647 Tj -0 -408.2145 Td -(3640 ) 21.8426 Tj -0 -417.7079 Td -(3641 release\(&bcache.lock\);) 126.6869 Tj -0 -427.2012 Td -(3642 }) 26.2111 Tj -0 -436.6946 Td -(3643 ) 21.8426 Tj -0 -446.1879 Td -(3644 ) 21.8426 Tj -0 -455.6813 Td -(3645 ) 21.8426 Tj -0 -465.1747 Td -(3646 ) 21.8426 Tj -0 -474.668 Td -(3647 ) 21.8426 Tj -0 -484.1614 Td -(3648 ) 21.8426 Tj -0 -493.6547 Td -(3649 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 36) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.c Page 1) 152.898 Tj -0 -28.4801 Td -(3650 // File system implementation. Four layers:) 214.0572 Tj -0 -37.9735 Td -(3651 // + Blocks: allocator for raw disk blocks.) 218.4257 Tj -0 -47.4668 Td -(3652 // + Files: inode allocator, reading, writing, metadata.) 275.2164 Tj -0 -56.9602 Td -(3653 // + Directories: inode with special contents \(list of \ -other inodes!\)) 332.0071 Tj -0 -66.4535 Td -(3654 // + Names: paths like /usr/rtm/xv6/fs.c for convenient \ -naming.) 305.796 Tj -0 -75.9469 Td -(3655 //) 30.5796 Tj -0 -85.4403 Td -(3656 // Disk layout is: superblock, inodes, block in-use bitmap\ -, data blocks.) 336.3756 Tj -0 -94.9336 Td -(3657 //) 30.5796 Tj -0 -104.427 Td -(3658 // This file contains the low-level file system manipulati\ -on) 283.9534 Tj -0 -113.9203 Td -(3659 // routines. The \(higher-level\) system call implementat\ -ions) 283.9534 Tj -0 -123.4137 Td -(3660 // are in sysfile.c.) 109.2129 Tj -0 -132.9071 Td -(3661 ) 21.8426 Tj -0 -142.4004 Td -(3662 #include "types.h") 100.4758 Tj -0 -151.8938 Td -(3663 #include "defs.h") 96.1073 Tj -0 -161.3871 Td -(3664 #include "param.h") 100.4758 Tj -0 -170.8805 Td -(3665 #include "stat.h") 96.1073 Tj -0 -180.3739 Td -(3666 #include "mmu.h") 91.7388 Tj -0 -189.8672 Td -(3667 #include "proc.h") 96.1073 Tj -0 -199.3606 Td -(3668 #include "spinlock.h") 113.5814 Tj -0 -208.8539 Td -(3669 #include "buf.h") 91.7388 Tj -0 -218.3473 Td -(3670 #include "fs.h") 87.3703 Tj -0 -227.8407 Td -(3671 #include "file.h") 96.1073 Tj -0 -237.334 Td -(3672 ) 21.8426 Tj -0 -246.8274 Td -(3673 #define min\(a, b\) \(\(a\) < \(b\) ? \(a\) : \(b\)\)) 200.9517 Tj -0 -256.3207 Td -(3674 static void itrunc\(struct inode*\);) 170.3721 Tj -0 -265.8141 Td -(3675 ) 21.8426 Tj -0 -275.3075 Td -(3676 // Read the super block.) 126.6869 Tj -0 -284.8008 Td -(3677 static void) 69.8962 Tj -0 -294.2942 Td -(3678 readsb\(int dev, struct superblock *sb\)) 187.8461 Tj -0 -303.7875 Td -(3679 {) 26.2111 Tj -0 -313.2809 Td -(3680 struct buf *bp;) 96.1073 Tj -0 -322.7743 Td -(3681 ) 21.8426 Tj -0 -332.2676 Td -(3682 bp = bread\(dev, 1\);) 113.5814 Tj -0 -341.761 Td -(3683 memmove\(sb, bp->data, sizeof\(*sb\)\);) 183.4776 Tj -0 -351.2543 Td -(3684 brelse\(bp\);) 78.6333 Tj -0 -360.7477 Td -(3685 }) 26.2111 Tj -0 -370.2411 Td -(3686 ) 21.8426 Tj -0 -379.7344 Td -(3687 // Zero a block.) 91.7388 Tj -0 -389.2278 Td -(3688 static void) 69.8962 Tj -0 -398.7211 Td -(3689 bzero\(int dev, int bno\)) 122.3184 Tj -0 -408.2145 Td -(3690 {) 26.2111 Tj -0 -417.7079 Td -(3691 struct buf *bp;) 96.1073 Tj -0 -427.2012 Td -(3692 ) 21.8426 Tj -0 -436.6946 Td -(3693 bp = bread\(dev, bno\);) 122.3184 Tj -0 -446.1879 Td -(3694 memset\(bp->data, 0, BSIZE\);) 148.5295 Tj -0 -455.6813 Td -(3695 bwrite\(bp\);) 78.6333 Tj -0 -465.1747 Td -(3696 brelse\(bp\);) 78.6333 Tj -0 -474.668 Td -(3697 }) 26.2111 Tj -0 -484.1614 Td -(3698 ) 21.8426 Tj -0 -493.6547 Td -(3699 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 36) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 44 44 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.c Page 2) 152.898 Tj -0 -28.4801 Td -(3700 // Blocks.) 65.5277 Tj -0 -37.9735 Td -(3701 ) 21.8426 Tj -0 -47.4668 Td -(3702 // Allocate a disk block.) 131.0554 Tj -0 -56.9602 Td -(3703 static uint) 69.8962 Tj -0 -66.4535 Td -(3704 balloc\(uint dev\)) 91.7388 Tj -0 -75.9469 Td -(3705 {) 26.2111 Tj -0 -85.4403 Td -(3706 int b, bi, m;) 87.3703 Tj -0 -94.9336 Td -(3707 struct buf *bp;) 96.1073 Tj -0 -104.427 Td -(3708 struct superblock sb;) 122.3184 Tj -0 -113.9203 Td -(3709 ) 21.8426 Tj -0 -123.4137 Td -(3710 bp = 0;) 61.1592 Tj -0 -132.9071 Td -(3711 readsb\(dev, &sb\);) 104.8443 Tj -0 -142.4004 Td -(3712 for\(b = 0; b < sb.size; b += BPB\){) 179.1091 Tj -0 -151.8938 Td -(3713 bp = bread\(dev, BBLOCK\(b, sb.ninodes\)\);) 209.6887 Tj -0 -161.3871 Td -(3714 for\(bi = 0; bi < BPB; bi++\){) 161.635 Tj -0 -170.8805 Td -(3715 m = 1 << \(bi % 8\);) 126.6869 Tj -0 -180.3739 Td -(3716 if\(\(bp->data[bi/8] & m\) == 0\){ // Is block free\ -?) 262.1109 Tj -0 -189.8672 Td -(3717 bp->data[bi/8] |= m; // Mark block in use on disk\ -.) 279.5849 Tj -0 -199.3606 Td -(3718 bwrite\(bp\);) 104.8443 Tj -0 -208.8539 Td -(3719 brelse\(bp\);) 104.8443 Tj -0 -218.3473 Td -(3720 return b + bi;) 117.9499 Tj -0 -227.8407 Td -(3721 }) 52.4222 Tj -0 -237.334 Td -(3722 }) 43.6851 Tj -0 -246.8274 Td -(3723 brelse\(bp\);) 87.3703 Tj -0 -256.3207 Td -(3724 }) 34.9481 Tj -0 -265.8141 Td -(3725 panic\("balloc: out of blocks"\);) 166.0035 Tj -0 -275.3075 Td -(3726 }) 26.2111 Tj -0 -284.8008 Td -(3727 ) 21.8426 Tj -0 -294.2942 Td -(3728 // Free a disk block.) 113.5814 Tj -0 -303.7875 Td -(3729 static void) 69.8962 Tj -0 -313.2809 Td -(3730 bfree\(int dev, uint b\)) 117.9499 Tj -0 -322.7743 Td -(3731 {) 26.2111 Tj -0 -332.2676 Td -(3732 struct buf *bp;) 96.1073 Tj -0 -341.761 Td -(3733 struct superblock sb;) 122.3184 Tj -0 -351.2543 Td -(3734 int bi, m;) 74.2647 Tj -0 -360.7477 Td -(3735 ) 21.8426 Tj -0 -370.2411 Td -(3736 bzero\(dev, b\);) 91.7388 Tj -0 -379.7344 Td -(3737 ) 21.8426 Tj -0 -389.2278 Td -(3738 readsb\(dev, &sb\);) 104.8443 Tj -0 -398.7211 Td -(3739 bp = bread\(dev, BBLOCK\(b, sb.ninodes\)\);) 200.9517 Tj -0 -408.2145 Td -(3740 bi = b % BPB;) 87.3703 Tj -0 -417.7079 Td -(3741 m = 1 << \(bi % 8\);) 109.2129 Tj -0 -427.2012 Td -(3742 if\(\(bp->data[bi/8] & m\) == 0\)) 157.2665 Tj -0 -436.6946 Td -(3743 panic\("freeing free block"\);) 161.635 Tj -0 -446.1879 Td -(3744 bp->data[bi/8] &= ~m; // Mark block free on disk.) 249.0053 Tj -0 -455.6813 Td -(3745 bwrite\(bp\);) 78.6333 Tj -0 -465.1747 Td -(3746 brelse\(bp\);) 78.6333 Tj -0 -474.668 Td -(3747 }) 26.2111 Tj -0 -484.1614 Td -(3748 ) 21.8426 Tj -0 -493.6547 Td -(3749 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 37) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.c Page 3) 152.898 Tj -0 -28.4801 Td -(3750 // Inodes.) 65.5277 Tj -0 -37.9735 Td -(3751 //) 30.5796 Tj -0 -47.4668 Td -(3752 // An inode is a single, unnamed file in the file system.) 270.8479 Tj -0 -56.9602 Td -(3753 // The inode disk structure holds metadata \(the type, dev\ -ice numbers,) 323.2701 Tj -0 -66.4535 Td -(3754 // and data size\) along with a list of blocks where the a\ -ssociated) 310.1645 Tj -0 -75.9469 Td -(3755 // data can be found.) 113.5814 Tj -0 -85.4403 Td -(3756 //) 30.5796 Tj -0 -94.9336 Td -(3757 // The inodes are laid out sequentially on disk immediatel\ -y after) 305.796 Tj -0 -104.427 Td -(3758 // the superblock. The kernel keeps a cache of the in-use) 275.2164 Tj -0 -113.9203 Td -(3759 // on-disk structures to provide a place for synchronizing\ - access) 305.796 Tj -0 -123.4137 Td -(3760 // to inodes shared between multiple processes.) 227.1628 Tj -0 -132.9071 Td -(3761 //) 30.5796 Tj -0 -142.4004 Td -(3762 // ip->ref counts the number of pointer references to this\ - cached) 305.796 Tj -0 -151.8938 Td -(3763 // inode; references are typically kept in struct file and\ - in proc->cwd.) 336.3756 Tj -0 -161.3871 Td -(3764 // When ip->ref falls to zero, the inode is no longer cach\ -ed.) 288.322 Tj -0 -170.8805 Td -(3765 // It is an error to use an inode without holding a refere\ -nce to it.) 318.9016 Tj -0 -180.3739 Td -(3766 //) 30.5796 Tj -0 -189.8672 Td -(3767 // Processes are only allowed to read and write inode) 253.3738 Tj -0 -199.3606 Td -(3768 // metadata and contents when holding the inode's lock,) 262.1109 Tj -0 -208.8539 Td -(3769 // represented by the I_BUSY flag in the in-memory copy.) 266.4794 Tj -0 -218.3473 Td -(3770 // Because inode locks are held during disk accesses,) 253.3738 Tj -0 -227.8407 Td -(3771 // they are implemented using a flag rather than with) 253.3738 Tj -0 -237.334 Td -(3772 // spin locks. Callers are responsible for locking) 244.6368 Tj -0 -246.8274 Td -(3773 // inodes before passing them to routines in this file; le\ -aving) 297.059 Tj -0 -256.3207 Td -(3774 // this responsibility with the caller makes it possible f\ -or them) 305.796 Tj -0 -265.8141 Td -(3775 // to create arbitrarily-sized atomic operations.) 235.8998 Tj -0 -275.3075 Td -(3776 //) 30.5796 Tj -0 -284.8008 Td -(3777 // To give maximum control over locking to the callers,) 262.1109 Tj -0 -294.2942 Td -(3778 // the routines in this file that return inode pointers) 262.1109 Tj -0 -303.7875 Td -(3779 // return pointers to *unlocked* inodes. It is the caller\ -s') 283.9534 Tj -0 -313.2809 Td -(3780 // responsibility to lock them before using them. A non-z\ -ero) 288.322 Tj -0 -322.7743 Td -(3781 // ip->ref keeps these unlocked inodes in the cache.) 249.0053 Tj -0 -332.2676 Td -(3782 ) 21.8426 Tj -0 -341.761 Td -(3783 struct {) 56.7907 Tj -0 -351.2543 Td -(3784 struct spinlock lock;) 122.3184 Tj -0 -360.7477 Td -(3785 struct inode inode[NINODE];) 148.5295 Tj -0 -370.2411 Td -(3786 } icache;) 61.1592 Tj -0 -379.7344 Td -(3787 ) 21.8426 Tj -0 -389.2278 Td -(3788 void) 39.3166 Tj -0 -398.7211 Td -(3789 iinit\(void\)) 69.8962 Tj -0 -408.2145 Td -(3790 {) 26.2111 Tj -0 -417.7079 Td -(3791 initlock\(&icache.lock, "icache"\);) 174.7406 Tj -0 -427.2012 Td -(3792 }) 26.2111 Tj -0 -436.6946 Td -(3793 ) 21.8426 Tj -0 -446.1879 Td -(3794 static struct inode* iget\(uint dev, uint inum\);) 227.1628 Tj -0 -455.6813 Td -(3795 ) 21.8426 Tj -0 -465.1747 Td -(3796 ) 21.8426 Tj -0 -474.668 Td -(3797 ) 21.8426 Tj -0 -484.1614 Td -(3798 ) 21.8426 Tj -0 -493.6547 Td -(3799 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 37) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 45 45 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.c Page 4) 152.898 Tj -0 -28.4801 Td -(3800 // Allocate a new inode with the given type on device dev.) 275.2164 Tj -0 -37.9735 Td -(3801 struct inode*) 78.6333 Tj -0 -47.4668 Td -(3802 ialloc\(uint dev, short type\)) 144.161 Tj -0 -56.9602 Td -(3803 {) 26.2111 Tj -0 -66.4535 Td -(3804 int inum;) 69.8962 Tj -0 -75.9469 Td -(3805 struct buf *bp;) 96.1073 Tj -0 -85.4403 Td -(3806 struct dinode *dip;) 113.5814 Tj -0 -94.9336 Td -(3807 struct superblock sb;) 122.3184 Tj -0 -104.427 Td -(3808 ) 21.8426 Tj -0 -113.9203 Td -(3809 readsb\(dev, &sb\);) 104.8443 Tj -0 -123.4137 Td -(3810 for\(inum = 1; inum < sb.ninodes; inum++\){ // loop ove\ -r inode blocks) 327.6386 Tj -0 -132.9071 Td -(3811 bp = bread\(dev, IBLOCK\(inum\)\);) 170.3721 Tj -0 -142.4004 Td -(3812 dip = \(struct dinode*\)bp->data + inum%IPB;) 222.7942 Tj -0 -151.8938 Td -(3813 if\(dip->type == 0\){ // a free inode) 196.5831 Tj -0 -161.3871 Td -(3814 memset\(dip, 0, sizeof\(*dip\)\);) 174.7406 Tj -0 -170.8805 Td -(3815 dip->type = type;) 122.3184 Tj -0 -180.3739 Td -(3816 bwrite\(bp\); // mark it allocated on the disk) 249.0053 Tj -0 -189.8672 Td -(3817 brelse\(bp\);) 96.1073 Tj -0 -199.3606 Td -(3818 return iget\(dev, inum\);) 148.5295 Tj -0 -208.8539 Td -(3819 }) 43.6851 Tj -0 -218.3473 Td -(3820 brelse\(bp\);) 87.3703 Tj -0 -227.8407 Td -(3821 }) 34.9481 Tj -0 -237.334 Td -(3822 panic\("ialloc: no inodes"\);) 148.5295 Tj -0 -246.8274 Td -(3823 }) 26.2111 Tj -0 -256.3207 Td -(3824 ) 21.8426 Tj -0 -265.8141 Td -(3825 // Copy inode, which has changed, from memory to disk.) 257.7424 Tj -0 -275.3075 Td -(3826 void) 39.3166 Tj -0 -284.8008 Td -(3827 iupdate\(struct inode *ip\)) 131.0554 Tj -0 -294.2942 Td -(3828 {) 26.2111 Tj -0 -303.7875 Td -(3829 struct buf *bp;) 96.1073 Tj -0 -313.2809 Td -(3830 struct dinode *dip;) 113.5814 Tj -0 -322.7743 Td -(3831 ) 21.8426 Tj -0 -332.2676 Td -(3832 bp = bread\(ip->dev, IBLOCK\(ip->inum\)\);) 196.5831 Tj -0 -341.761 Td -(3833 dip = \(struct dinode*\)bp->data + ip->inum%IPB;) 231.5313 Tj -0 -351.2543 Td -(3834 dip->type = ip->type;) 122.3184 Tj -0 -360.7477 Td -(3835 dip->major = ip->major;) 131.0554 Tj -0 -370.2411 Td -(3836 dip->minor = ip->minor;) 131.0554 Tj -0 -379.7344 Td -(3837 dip->nlink = ip->nlink;) 131.0554 Tj -0 -389.2278 Td -(3838 dip->size = ip->size;) 122.3184 Tj -0 -398.7211 Td -(3839 memmove\(dip->addrs, ip->addrs, sizeof\(ip->addrs\)\);) 249.0053 Tj -0 -408.2145 Td -(3840 bwrite\(bp\);) 78.6333 Tj -0 -417.7079 Td -(3841 brelse\(bp\);) 78.6333 Tj -0 -427.2012 Td -(3842 }) 26.2111 Tj -0 -436.6946 Td -(3843 ) 21.8426 Tj -0 -446.1879 Td -(3844 ) 21.8426 Tj -0 -455.6813 Td -(3845 ) 21.8426 Tj -0 -465.1747 Td -(3846 ) 21.8426 Tj -0 -474.668 Td -(3847 ) 21.8426 Tj -0 -484.1614 Td -(3848 ) 21.8426 Tj -0 -493.6547 Td -(3849 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 38) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.c Page 5) 152.898 Tj -0 -28.4801 Td -(3850 // Find the inode with number inum on device dev) 231.5313 Tj -0 -37.9735 Td -(3851 // and return the in-memory copy.) 166.0035 Tj -0 -47.4668 Td -(3852 static struct inode*) 109.2129 Tj -0 -56.9602 Td -(3853 iget\(uint dev, uint inum\)) 131.0554 Tj -0 -66.4535 Td -(3854 {) 26.2111 Tj -0 -75.9469 Td -(3855 struct inode *ip, *empty;) 139.7925 Tj -0 -85.4403 Td -(3856 ) 21.8426 Tj -0 -94.9336 Td -(3857 acquire\(&icache.lock\);) 126.6869 Tj -0 -104.427 Td -(3858 ) 21.8426 Tj -0 -113.9203 Td -(3859 // Try for cached inode.) 135.4239 Tj -0 -123.4137 Td -(3860 empty = 0;) 74.2647 Tj -0 -132.9071 Td -(3861 for\(ip = &icache.inode[0]; ip < &icache.inode[NINODE]; \ -ip++\){) 297.059 Tj -0 -142.4004 Td -(3862 if\(ip->ref > 0 && ip->dev == dev && ip->inum == inum\)\ -{) 275.2164 Tj -0 -151.8938 Td -(3863 ip->ref++;) 91.7388 Tj -0 -161.3871 Td -(3864 release\(&icache.lock\);) 144.161 Tj -0 -170.8805 Td -(3865 return ip;) 91.7388 Tj -0 -180.3739 Td -(3866 }) 43.6851 Tj -0 -189.8672 Td -(3867 if\(empty == 0 && ip->ref == 0\) // Remember empty \ -slot.) 288.322 Tj -0 -199.3606 Td -(3868 empty = ip;) 96.1073 Tj -0 -208.8539 Td -(3869 }) 34.9481 Tj -0 -218.3473 Td -(3870 ) 21.8426 Tj -0 -227.8407 Td -(3871 // Allocate fresh inode.) 135.4239 Tj -0 -237.334 Td -(3872 if\(empty == 0\)) 91.7388 Tj -0 -246.8274 Td -(3873 panic\("iget: no inodes"\);) 148.5295 Tj -0 -256.3207 Td -(3874 ) 21.8426 Tj -0 -265.8141 Td -(3875 ip = empty;) 78.6333 Tj -0 -275.3075 Td -(3876 ip->dev = dev;) 91.7388 Tj -0 -284.8008 Td -(3877 ip->inum = inum;) 100.4758 Tj -0 -294.2942 Td -(3878 ip->ref = 1;) 83.0018 Tj -0 -303.7875 Td -(3879 ip->flags = 0;) 91.7388 Tj -0 -313.2809 Td -(3880 release\(&icache.lock\);) 126.6869 Tj -0 -322.7743 Td -(3881 ) 21.8426 Tj -0 -332.2676 Td -(3882 return ip;) 74.2647 Tj -0 -341.761 Td -(3883 }) 26.2111 Tj -0 -351.2543 Td -(3884 ) 21.8426 Tj -0 -360.7477 Td -(3885 // Increment reference count for ip.) 179.1091 Tj -0 -370.2411 Td -(3886 // Returns ip to enable ip = idup\(ip1\) idiom.) 218.4257 Tj -0 -379.7344 Td -(3887 struct inode*) 78.6333 Tj -0 -389.2278 Td -(3888 idup\(struct inode *ip\)) 117.9499 Tj -0 -398.7211 Td -(3889 {) 26.2111 Tj -0 -408.2145 Td -(3890 acquire\(&icache.lock\);) 126.6869 Tj -0 -417.7079 Td -(3891 ip->ref++;) 74.2647 Tj -0 -427.2012 Td -(3892 release\(&icache.lock\);) 126.6869 Tj -0 -436.6946 Td -(3893 return ip;) 74.2647 Tj -0 -446.1879 Td -(3894 }) 26.2111 Tj -0 -455.6813 Td -(3895 ) 21.8426 Tj -0 -465.1747 Td -(3896 ) 21.8426 Tj -0 -474.668 Td -(3897 ) 21.8426 Tj -0 -484.1614 Td -(3898 ) 21.8426 Tj -0 -493.6547 Td -(3899 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 38) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 46 46 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.c Page 6) 152.898 Tj -0 -28.4801 Td -(3900 // Lock the given inode.) 126.6869 Tj -0 -37.9735 Td -(3901 void) 39.3166 Tj -0 -47.4668 Td -(3902 ilock\(struct inode *ip\)) 122.3184 Tj -0 -56.9602 Td -(3903 {) 26.2111 Tj -0 -66.4535 Td -(3904 struct buf *bp;) 96.1073 Tj -0 -75.9469 Td -(3905 struct dinode *dip;) 113.5814 Tj -0 -85.4403 Td -(3906 ) 21.8426 Tj -0 -94.9336 Td -(3907 if\(ip == 0 || ip->ref < 1\)) 144.161 Tj -0 -104.427 Td -(3908 panic\("ilock"\);) 104.8443 Tj -0 -113.9203 Td -(3909 ) 21.8426 Tj -0 -123.4137 Td -(3910 acquire\(&icache.lock\);) 126.6869 Tj -0 -132.9071 Td -(3911 while\(ip->flags & I_BUSY\)) 139.7925 Tj -0 -142.4004 Td -(3912 sleep\(ip, &icache.lock\);) 144.161 Tj -0 -151.8938 Td -(3913 ip->flags |= I_BUSY;) 117.9499 Tj -0 -161.3871 Td -(3914 release\(&icache.lock\);) 126.6869 Tj -0 -170.8805 Td -(3915 ) 21.8426 Tj -0 -180.3739 Td -(3916 if\(!\(ip->flags & I_VALID\)\){) 148.5295 Tj -0 -189.8672 Td -(3917 bp = bread\(ip->dev, IBLOCK\(ip->inum\)\);) 205.3202 Tj -0 -199.3606 Td -(3918 dip = \(struct dinode*\)bp->data + ip->inum%IPB;) 240.2683 Tj -0 -208.8539 Td -(3919 ip->type = dip->type;) 131.0554 Tj -0 -218.3473 Td -(3920 ip->major = dip->major;) 139.7925 Tj -0 -227.8407 Td -(3921 ip->minor = dip->minor;) 139.7925 Tj -0 -237.334 Td -(3922 ip->nlink = dip->nlink;) 139.7925 Tj -0 -246.8274 Td -(3923 ip->size = dip->size;) 131.0554 Tj -0 -256.3207 Td -(3924 memmove\(ip->addrs, dip->addrs, sizeof\(ip->addrs\)\);) 257.7424 Tj -0 -265.8141 Td -(3925 brelse\(bp\);) 87.3703 Tj -0 -275.3075 Td -(3926 ip->flags |= I_VALID;) 131.0554 Tj -0 -284.8008 Td -(3927 if\(ip->type == 0\)) 113.5814 Tj -0 -294.2942 Td -(3928 panic\("ilock: no type"\);) 152.898 Tj -0 -303.7875 Td -(3929 }) 34.9481 Tj -0 -313.2809 Td -(3930 }) 26.2111 Tj -0 -322.7743 Td -(3931 ) 21.8426 Tj -0 -332.2676 Td -(3932 // Unlock the given inode.) 135.4239 Tj -0 -341.761 Td -(3933 void) 39.3166 Tj -0 -351.2543 Td -(3934 iunlock\(struct inode *ip\)) 131.0554 Tj -0 -360.7477 Td -(3935 {) 26.2111 Tj -0 -370.2411 Td -(3936 if\(ip == 0 || !\(ip->flags & I_BUSY\) || ip->ref < 1\)) 253.3738 Tj -0 -379.7344 Td -(3937 panic\("iunlock"\);) 113.5814 Tj -0 -389.2278 Td -(3938 ) 21.8426 Tj -0 -398.7211 Td -(3939 acquire\(&icache.lock\);) 126.6869 Tj -0 -408.2145 Td -(3940 ip->flags &= ~I_BUSY;) 122.3184 Tj -0 -417.7079 Td -(3941 wakeup\(ip\);) 78.6333 Tj -0 -427.2012 Td -(3942 release\(&icache.lock\);) 126.6869 Tj -0 -436.6946 Td -(3943 }) 26.2111 Tj -0 -446.1879 Td -(3944 ) 21.8426 Tj -0 -455.6813 Td -(3945 ) 21.8426 Tj -0 -465.1747 Td -(3946 ) 21.8426 Tj -0 -474.668 Td -(3947 ) 21.8426 Tj -0 -484.1614 Td -(3948 ) 21.8426 Tj -0 -493.6547 Td -(3949 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 39) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.c Page 7) 152.898 Tj -0 -28.4801 Td -(3950 // Caller holds reference to unlocked ip. Drop reference.) 275.2164 Tj -0 -37.9735 Td -(3951 void) 39.3166 Tj -0 -47.4668 Td -(3952 iput\(struct inode *ip\)) 117.9499 Tj -0 -56.9602 Td -(3953 {) 26.2111 Tj -0 -66.4535 Td -(3954 acquire\(&icache.lock\);) 126.6869 Tj -0 -75.9469 Td -(3955 if\(ip->ref == 1 && \(ip->flags & I_VALID\) && ip->nlink\ - == 0\){) 292.6905 Tj -0 -85.4403 Td -(3956 // inode is no longer used: truncate and free inode.) 266.4794 Tj -0 -94.9336 Td -(3957 if\(ip->flags & I_BUSY\)) 135.4239 Tj -0 -104.427 Td -(3958 panic\("iput busy"\);) 131.0554 Tj -0 -113.9203 Td -(3959 ip->flags |= I_BUSY;) 126.6869 Tj -0 -123.4137 Td -(3960 release\(&icache.lock\);) 135.4239 Tj -0 -132.9071 Td -(3961 itrunc\(ip\);) 87.3703 Tj -0 -142.4004 Td -(3962 ip->type = 0;) 96.1073 Tj -0 -151.8938 Td -(3963 iupdate\(ip\);) 91.7388 Tj -0 -161.3871 Td -(3964 acquire\(&icache.lock\);) 135.4239 Tj -0 -170.8805 Td -(3965 ip->flags = 0;) 100.4758 Tj -0 -180.3739 Td -(3966 wakeup\(ip\);) 87.3703 Tj -0 -189.8672 Td -(3967 }) 34.9481 Tj -0 -199.3606 Td -(3968 ip->ref--;) 74.2647 Tj -0 -208.8539 Td -(3969 release\(&icache.lock\);) 126.6869 Tj -0 -218.3473 Td -(3970 }) 26.2111 Tj -0 -227.8407 Td -(3971 ) 21.8426 Tj -0 -237.334 Td -(3972 // Common idiom: unlock, then put.) 170.3721 Tj -0 -246.8274 Td -(3973 void) 39.3166 Tj -0 -256.3207 Td -(3974 iunlockput\(struct inode *ip\)) 144.161 Tj -0 -265.8141 Td -(3975 {) 26.2111 Tj -0 -275.3075 Td -(3976 iunlock\(ip\);) 83.0018 Tj -0 -284.8008 Td -(3977 iput\(ip\);) 69.8962 Tj -0 -294.2942 Td -(3978 }) 26.2111 Tj -0 -303.7875 Td -(3979 ) 21.8426 Tj -0 -313.2809 Td -(3980 ) 21.8426 Tj -0 -322.7743 Td -(3981 ) 21.8426 Tj -0 -332.2676 Td -(3982 ) 21.8426 Tj -0 -341.761 Td -(3983 ) 21.8426 Tj -0 -351.2543 Td -(3984 ) 21.8426 Tj -0 -360.7477 Td -(3985 ) 21.8426 Tj -0 -370.2411 Td -(3986 ) 21.8426 Tj -0 -379.7344 Td -(3987 ) 21.8426 Tj -0 -389.2278 Td -(3988 ) 21.8426 Tj -0 -398.7211 Td -(3989 ) 21.8426 Tj -0 -408.2145 Td -(3990 ) 21.8426 Tj -0 -417.7079 Td -(3991 ) 21.8426 Tj -0 -427.2012 Td -(3992 ) 21.8426 Tj -0 -436.6946 Td -(3993 ) 21.8426 Tj -0 -446.1879 Td -(3994 ) 21.8426 Tj -0 -455.6813 Td -(3995 ) 21.8426 Tj -0 -465.1747 Td -(3996 ) 21.8426 Tj -0 -474.668 Td -(3997 ) 21.8426 Tj -0 -484.1614 Td -(3998 ) 21.8426 Tj -0 -493.6547 Td -(3999 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 39) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 47 47 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.c Page 8) 152.898 Tj -0 -28.4801 Td -(4000 // Inode contents) 96.1073 Tj -0 -37.9735 Td -(4001 //) 30.5796 Tj -0 -47.4668 Td -(4002 // The contents \(data\) associated with each inode is sto\ -red) 279.5849 Tj -0 -56.9602 Td -(4003 // in a sequence of blocks on the disk. The first NDIRECT\ - blocks) 305.796 Tj -0 -66.4535 Td -(4004 // are listed in ip->addrs[]. The next NINDIRECT blocks a\ -re) 283.9534 Tj -0 -75.9469 Td -(4005 // listed in the block ip->addrs[INDIRECT].) 209.6887 Tj -0 -85.4403 Td -(4006 ) 21.8426 Tj -0 -94.9336 Td -(4007 // Return the disk block address of the nth block in inode\ - ip.) 292.6905 Tj -0 -104.427 Td -(4008 // If there is no such block, bmap allocates one.) 235.8998 Tj -0 -113.9203 Td -(4009 static uint) 69.8962 Tj -0 -123.4137 Td -(4010 bmap\(struct inode *ip, uint bn\)) 157.2665 Tj -0 -132.9071 Td -(4011 {) 26.2111 Tj -0 -142.4004 Td -(4012 uint addr, *a;) 91.7388 Tj -0 -151.8938 Td -(4013 struct buf *bp;) 96.1073 Tj -0 -161.3871 Td -(4014 ) 21.8426 Tj -0 -170.8805 Td -(4015 if\(bn < NDIRECT\){) 104.8443 Tj -0 -180.3739 Td -(4016 if\(\(addr = ip->addrs[bn]\) == 0\)) 174.7406 Tj -0 -189.8672 Td -(4017 ip->addrs[bn] = addr = balloc\(ip->dev\);) 218.4257 Tj -0 -199.3606 Td -(4018 return addr;) 91.7388 Tj -0 -208.8539 Td -(4019 }) 34.9481 Tj -0 -218.3473 Td -(4020 bn -= NDIRECT;) 91.7388 Tj -0 -227.8407 Td -(4021 ) 21.8426 Tj -0 -237.334 Td -(4022 if\(bn < NINDIRECT\){) 113.5814 Tj -0 -246.8274 Td -(4023 // Load indirect block, allocating if necessary.) 249.0053 Tj -0 -256.3207 Td -(4024 if\(\(addr = ip->addrs[NDIRECT]\) == 0\)) 196.5831 Tj -0 -265.8141 Td -(4025 ip->addrs[NDIRECT] = addr = balloc\(ip->dev\);) 240.2683 Tj -0 -275.3075 Td -(4026 bp = bread\(ip->dev, addr\);) 152.898 Tj -0 -284.8008 Td -(4027 a = \(uint*\)bp->data;) 126.6869 Tj -0 -294.2942 Td -(4028 if\(\(addr = a[bn]\) == 0\){) 144.161 Tj -0 -303.7875 Td -(4029 a[bn] = addr = balloc\(ip->dev\);) 183.4776 Tj -0 -313.2809 Td -(4030 bwrite\(bp\);) 96.1073 Tj -0 -322.7743 Td -(4031 }) 43.6851 Tj -0 -332.2676 Td -(4032 brelse\(bp\);) 87.3703 Tj -0 -341.761 Td -(4033 return addr;) 91.7388 Tj -0 -351.2543 Td -(4034 }) 34.9481 Tj -0 -360.7477 Td -(4035 ) 21.8426 Tj -0 -370.2411 Td -(4036 panic\("bmap: out of range"\);) 152.898 Tj -0 -379.7344 Td -(4037 }) 26.2111 Tj -0 -389.2278 Td -(4038 ) 21.8426 Tj -0 -398.7211 Td -(4039 ) 21.8426 Tj -0 -408.2145 Td -(4040 ) 21.8426 Tj -0 -417.7079 Td -(4041 ) 21.8426 Tj -0 -427.2012 Td -(4042 ) 21.8426 Tj -0 -436.6946 Td -(4043 ) 21.8426 Tj -0 -446.1879 Td -(4044 ) 21.8426 Tj -0 -455.6813 Td -(4045 ) 21.8426 Tj -0 -465.1747 Td -(4046 ) 21.8426 Tj -0 -474.668 Td -(4047 ) 21.8426 Tj -0 -484.1614 Td -(4048 ) 21.8426 Tj -0 -493.6547 Td -(4049 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 40) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.c Page 9) 152.898 Tj -0 -28.4801 Td -(4050 // Truncate inode \(discard contents\).) 183.4776 Tj -0 -37.9735 Td -(4051 // Only called after the last dirent referring) 222.7942 Tj -0 -47.4668 Td -(4052 // to this inode has been erased on disk.) 200.9517 Tj -0 -56.9602 Td -(4053 static void) 69.8962 Tj -0 -66.4535 Td -(4054 itrunc\(struct inode *ip\)) 126.6869 Tj -0 -75.9469 Td -(4055 {) 26.2111 Tj -0 -85.4403 Td -(4056 int i, j;) 69.8962 Tj -0 -94.9336 Td -(4057 struct buf *bp;) 96.1073 Tj -0 -104.427 Td -(4058 uint *a;) 65.5277 Tj -0 -113.9203 Td -(4059 ) 21.8426 Tj -0 -123.4137 Td -(4060 for\(i = 0; i < NDIRECT; i++\){) 157.2665 Tj -0 -132.9071 Td -(4061 if\(ip->addrs[i]\){) 113.5814 Tj -0 -142.4004 Td -(4062 bfree\(ip->dev, ip->addrs[i]\);) 174.7406 Tj -0 -151.8938 Td -(4063 ip->addrs[i] = 0;) 122.3184 Tj -0 -161.3871 Td -(4064 }) 43.6851 Tj -0 -170.8805 Td -(4065 }) 34.9481 Tj -0 -180.3739 Td -(4066 ) 21.8426 Tj -0 -189.8672 Td -(4067 if\(ip->addrs[NDIRECT]\){) 131.0554 Tj -0 -199.3606 Td -(4068 bp = bread\(ip->dev, ip->addrs[NDIRECT]\);) 214.0572 Tj -0 -208.8539 Td -(4069 a = \(uint*\)bp->data;) 126.6869 Tj -0 -218.3473 Td -(4070 for\(j = 0; j < NINDIRECT; j++\){) 174.7406 Tj -0 -227.8407 Td -(4071 if\(a[j]\)) 83.0018 Tj -0 -237.334 Td -(4072 bfree\(ip->dev, a[j]\);) 148.5295 Tj -0 -246.8274 Td -(4073 }) 43.6851 Tj -0 -256.3207 Td -(4074 brelse\(bp\);) 87.3703 Tj -0 -265.8141 Td -(4075 bfree\(ip->dev, ip->addrs[NDIRECT]\);) 192.2146 Tj -0 -275.3075 Td -(4076 ip->addrs[NDIRECT] = 0;) 139.7925 Tj -0 -284.8008 Td -(4077 }) 34.9481 Tj -0 -294.2942 Td -(4078 ) 21.8426 Tj -0 -303.7875 Td -(4079 ip->size = 0;) 87.3703 Tj -0 -313.2809 Td -(4080 iupdate\(ip\);) 83.0018 Tj -0 -322.7743 Td -(4081 }) 26.2111 Tj -0 -332.2676 Td -(4082 ) 21.8426 Tj -0 -341.761 Td -(4083 // Copy stat information from inode.) 179.1091 Tj -0 -351.2543 Td -(4084 void) 39.3166 Tj -0 -360.7477 Td -(4085 stati\(struct inode *ip, struct stat *st\)) 196.5831 Tj -0 -370.2411 Td -(4086 {) 26.2111 Tj -0 -379.7344 Td -(4087 st->dev = ip->dev;) 109.2129 Tj -0 -389.2278 Td -(4088 st->ino = ip->inum;) 113.5814 Tj -0 -398.7211 Td -(4089 st->type = ip->type;) 117.9499 Tj -0 -408.2145 Td -(4090 st->nlink = ip->nlink;) 126.6869 Tj -0 -417.7079 Td -(4091 st->size = ip->size;) 117.9499 Tj -0 -427.2012 Td -(4092 }) 26.2111 Tj -0 -436.6946 Td -(4093 ) 21.8426 Tj -0 -446.1879 Td -(4094 ) 21.8426 Tj -0 -455.6813 Td -(4095 ) 21.8426 Tj -0 -465.1747 Td -(4096 ) 21.8426 Tj -0 -474.668 Td -(4097 ) 21.8426 Tj -0 -484.1614 Td -(4098 ) 21.8426 Tj -0 -493.6547 Td -(4099 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 40) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 48 48 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.c Page 10) 157.2665 Tj -0 -28.4801 Td -(4100 // Read data from inode.) 126.6869 Tj -0 -37.9735 Td -(4101 int) 34.9481 Tj -0 -47.4668 Td -(4102 readi\(struct inode *ip, char *dst, uint off, uint n\)) 249.0053 Tj -0 -56.9602 Td -(4103 {) 26.2111 Tj -0 -66.4535 Td -(4104 uint tot, m;) 83.0018 Tj -0 -75.9469 Td -(4105 struct buf *bp;) 96.1073 Tj -0 -85.4403 Td -(4106 ) 21.8426 Tj -0 -94.9336 Td -(4107 if\(ip->type == T_DEV\){) 126.6869 Tj -0 -104.427 Td -(4108 if\(ip->major < 0 || ip->major >= NDEV || !devsw[ip->m\ -ajor].read\)) 318.9016 Tj -0 -113.9203 Td -(4109 return -1;) 91.7388 Tj -0 -123.4137 Td -(4110 return devsw[ip->major].read\(ip, dst, n\);) 218.4257 Tj -0 -132.9071 Td -(4111 }) 34.9481 Tj -0 -142.4004 Td -(4112 ) 21.8426 Tj -0 -151.8938 Td -(4113 if\(off > ip->size || off + n < off\)) 183.4776 Tj -0 -161.3871 Td -(4114 return -1;) 83.0018 Tj -0 -170.8805 Td -(4115 if\(off + n > ip->size\)) 126.6869 Tj -0 -180.3739 Td -(4116 n = ip->size - off;) 122.3184 Tj -0 -189.8672 Td -(4117 ) 21.8426 Tj -0 -199.3606 Td -(4118 for\(tot=0; totdev, bmap\(ip, off/BSIZE\)\);) 218.4257 Tj -0 -218.3473 Td -(4120 m = min\(n - tot, BSIZE - off%BSIZE\);) 196.5831 Tj -0 -227.8407 Td -(4121 memmove\(dst, bp->data + off%BSIZE, m\);) 205.3202 Tj -0 -237.334 Td -(4122 brelse\(bp\);) 87.3703 Tj -0 -246.8274 Td -(4123 }) 34.9481 Tj -0 -256.3207 Td -(4124 return n;) 69.8962 Tj -0 -265.8141 Td -(4125 }) 26.2111 Tj -0 -275.3075 Td -(4126 ) 21.8426 Tj -0 -284.8008 Td -(4127 ) 21.8426 Tj -0 -294.2942 Td -(4128 ) 21.8426 Tj -0 -303.7875 Td -(4129 ) 21.8426 Tj -0 -313.2809 Td -(4130 ) 21.8426 Tj -0 -322.7743 Td -(4131 ) 21.8426 Tj -0 -332.2676 Td -(4132 ) 21.8426 Tj -0 -341.761 Td -(4133 ) 21.8426 Tj -0 -351.2543 Td -(4134 ) 21.8426 Tj -0 -360.7477 Td -(4135 ) 21.8426 Tj -0 -370.2411 Td -(4136 ) 21.8426 Tj -0 -379.7344 Td -(4137 ) 21.8426 Tj -0 -389.2278 Td -(4138 ) 21.8426 Tj -0 -398.7211 Td -(4139 ) 21.8426 Tj -0 -408.2145 Td -(4140 ) 21.8426 Tj -0 -417.7079 Td -(4141 ) 21.8426 Tj -0 -427.2012 Td -(4142 ) 21.8426 Tj -0 -436.6946 Td -(4143 ) 21.8426 Tj -0 -446.1879 Td -(4144 ) 21.8426 Tj -0 -455.6813 Td -(4145 ) 21.8426 Tj -0 -465.1747 Td -(4146 ) 21.8426 Tj -0 -474.668 Td -(4147 ) 21.8426 Tj -0 -484.1614 Td -(4148 ) 21.8426 Tj -0 -493.6547 Td -(4149 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 41) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.c Page 11) 157.2665 Tj -0 -28.4801 Td -(4150 // Write data to inode.) 122.3184 Tj -0 -37.9735 Td -(4151 int) 34.9481 Tj -0 -47.4668 Td -(4152 writei\(struct inode *ip, char *src, uint off, uint n\)) 253.3738 Tj -0 -56.9602 Td -(4153 {) 26.2111 Tj -0 -66.4535 Td -(4154 uint tot, m;) 83.0018 Tj -0 -75.9469 Td -(4155 struct buf *bp;) 96.1073 Tj -0 -85.4403 Td -(4156 ) 21.8426 Tj -0 -94.9336 Td -(4157 if\(ip->type == T_DEV\){) 126.6869 Tj -0 -104.427 Td -(4158 if\(ip->major < 0 || ip->major >= NDEV || !devsw[ip->m\ -ajor].write\)) 323.2701 Tj -0 -113.9203 Td -(4159 return -1;) 91.7388 Tj -0 -123.4137 Td -(4160 return devsw[ip->major].write\(ip, src, n\);) 222.7942 Tj -0 -132.9071 Td -(4161 }) 34.9481 Tj -0 -142.4004 Td -(4162 ) 21.8426 Tj -0 -151.8938 Td -(4163 if\(off > ip->size || off + n < off\)) 183.4776 Tj -0 -161.3871 Td -(4164 return -1;) 83.0018 Tj -0 -170.8805 Td -(4165 if\(off + n > MAXFILE*BSIZE\)) 148.5295 Tj -0 -180.3739 Td -(4166 n = MAXFILE*BSIZE - off;) 144.161 Tj -0 -189.8672 Td -(4167 ) 21.8426 Tj -0 -199.3606 Td -(4168 for\(tot=0; totdev, bmap\(ip, off/BSIZE\)\);) 218.4257 Tj -0 -218.3473 Td -(4170 m = min\(n - tot, BSIZE - off%BSIZE\);) 196.5831 Tj -0 -227.8407 Td -(4171 memmove\(bp->data + off%BSIZE, src, m\);) 205.3202 Tj -0 -237.334 Td -(4172 bwrite\(bp\);) 87.3703 Tj -0 -246.8274 Td -(4173 brelse\(bp\);) 87.3703 Tj -0 -256.3207 Td -(4174 }) 34.9481 Tj -0 -265.8141 Td -(4175 ) 21.8426 Tj -0 -275.3075 Td -(4176 if\(n > 0 && off > ip->size\){) 152.898 Tj -0 -284.8008 Td -(4177 ip->size = off;) 104.8443 Tj -0 -294.2942 Td -(4178 iupdate\(ip\);) 91.7388 Tj -0 -303.7875 Td -(4179 }) 34.9481 Tj -0 -313.2809 Td -(4180 return n;) 69.8962 Tj -0 -322.7743 Td -(4181 }) 26.2111 Tj -0 -332.2676 Td -(4182 ) 21.8426 Tj -0 -341.761 Td -(4183 ) 21.8426 Tj -0 -351.2543 Td -(4184 ) 21.8426 Tj -0 -360.7477 Td -(4185 ) 21.8426 Tj -0 -370.2411 Td -(4186 ) 21.8426 Tj -0 -379.7344 Td -(4187 ) 21.8426 Tj -0 -389.2278 Td -(4188 ) 21.8426 Tj -0 -398.7211 Td -(4189 ) 21.8426 Tj -0 -408.2145 Td -(4190 ) 21.8426 Tj -0 -417.7079 Td -(4191 ) 21.8426 Tj -0 -427.2012 Td -(4192 ) 21.8426 Tj -0 -436.6946 Td -(4193 ) 21.8426 Tj -0 -446.1879 Td -(4194 ) 21.8426 Tj -0 -455.6813 Td -(4195 ) 21.8426 Tj -0 -465.1747 Td -(4196 ) 21.8426 Tj -0 -474.668 Td -(4197 ) 21.8426 Tj -0 -484.1614 Td -(4198 ) 21.8426 Tj -0 -493.6547 Td -(4199 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 41) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 49 49 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.c Page 12) 157.2665 Tj -0 -28.4801 Td -(4200 // Directories) 83.0018 Tj -0 -37.9735 Td -(4201 ) 21.8426 Tj -0 -47.4668 Td -(4202 int) 34.9481 Tj -0 -56.9602 Td -(4203 namecmp\(const char *s, const char *t\)) 183.4776 Tj -0 -66.4535 Td -(4204 {) 26.2111 Tj -0 -75.9469 Td -(4205 return strncmp\(s, t, DIRSIZ\);) 157.2665 Tj -0 -85.4403 Td -(4206 }) 26.2111 Tj -0 -94.9336 Td -(4207 ) 21.8426 Tj -0 -104.427 Td -(4208 // Look for a directory entry in a directory.) 218.4257 Tj -0 -113.9203 Td -(4209 // If found, set *poff to byte offset of entry.) 227.1628 Tj -0 -123.4137 Td -(4210 // Caller must have already locked dp.) 187.8461 Tj -0 -132.9071 Td -(4211 struct inode*) 78.6333 Tj -0 -142.4004 Td -(4212 dirlookup\(struct inode *dp, char *name, uint *poff\)) 244.6368 Tj -0 -151.8938 Td -(4213 {) 26.2111 Tj -0 -161.3871 Td -(4214 uint off, inum;) 96.1073 Tj -0 -170.8805 Td -(4215 struct buf *bp;) 96.1073 Tj -0 -180.3739 Td -(4216 struct dirent *de;) 109.2129 Tj -0 -189.8672 Td -(4217 ) 21.8426 Tj -0 -199.3606 Td -(4218 if\(dp->type != T_DIR\)) 122.3184 Tj -0 -208.8539 Td -(4219 panic\("dirlookup not DIR"\);) 157.2665 Tj -0 -218.3473 Td -(4220 ) 21.8426 Tj -0 -227.8407 Td -(4221 for\(off = 0; off < dp->size; off += BSIZE\){) 218.4257 Tj -0 -237.334 Td -(4222 bp = bread\(dp->dev, bmap\(dp, off / BSIZE\)\);) 227.1628 Tj -0 -246.8274 Td -(4223 for\(de = \(struct dirent*\)bp->data;) 187.8461 Tj -0 -256.3207 Td -(4224 de < \(struct dirent*\)\(bp->data + BSIZE\);) 231.5313 Tj -0 -265.8141 Td -(4225 de++\){) 83.0018 Tj -0 -275.3075 Td -(4226 if\(de->inum == 0\)) 122.3184 Tj -0 -284.8008 Td -(4227 continue;) 96.1073 Tj -0 -294.2942 Td -(4228 if\(namecmp\(name, de->name\) == 0\){) 192.2146 Tj -0 -303.7875 Td -(4229 // entry matches path element) 183.4776 Tj -0 -313.2809 Td -(4230 if\(poff\)) 91.7388 Tj -0 -322.7743 Td -(4231 *poff = off + \(uchar*\)de - bp->data;) 222.7942 Tj -0 -332.2676 Td -(4232 inum = de->inum;) 126.6869 Tj -0 -341.761 Td -(4233 brelse\(bp\);) 104.8443 Tj -0 -351.2543 Td -(4234 return iget\(dp->dev, inum\);) 174.7406 Tj -0 -360.7477 Td -(4235 }) 52.4222 Tj -0 -370.2411 Td -(4236 }) 43.6851 Tj -0 -379.7344 Td -(4237 brelse\(bp\);) 87.3703 Tj -0 -389.2278 Td -(4238 }) 34.9481 Tj -0 -398.7211 Td -(4239 return 0;) 69.8962 Tj -0 -408.2145 Td -(4240 }) 26.2111 Tj -0 -417.7079 Td -(4241 ) 21.8426 Tj -0 -427.2012 Td -(4242 ) 21.8426 Tj -0 -436.6946 Td -(4243 ) 21.8426 Tj -0 -446.1879 Td -(4244 ) 21.8426 Tj -0 -455.6813 Td -(4245 ) 21.8426 Tj -0 -465.1747 Td -(4246 ) 21.8426 Tj -0 -474.668 Td -(4247 ) 21.8426 Tj -0 -484.1614 Td -(4248 ) 21.8426 Tj -0 -493.6547 Td -(4249 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 42) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.c Page 13) 157.2665 Tj -0 -28.4801 Td -(4250 // Write a new directory entry \(name, inum\) into the dir\ -ectory dp.) 310.1645 Tj -0 -37.9735 Td -(4251 int) 34.9481 Tj -0 -47.4668 Td -(4252 dirlink\(struct inode *dp, char *name, uint inum\)) 231.5313 Tj -0 -56.9602 Td -(4253 {) 26.2111 Tj -0 -66.4535 Td -(4254 int off;) 65.5277 Tj -0 -75.9469 Td -(4255 struct dirent de;) 104.8443 Tj -0 -85.4403 Td -(4256 struct inode *ip;) 104.8443 Tj -0 -94.9336 Td -(4257 ) 21.8426 Tj -0 -104.427 Td -(4258 // Check that name is not present.) 179.1091 Tj -0 -113.9203 Td -(4259 if\(\(ip = dirlookup\(dp, name, 0\)\) != 0\){) 200.9517 Tj -0 -123.4137 Td -(4260 iput\(ip\);) 78.6333 Tj -0 -132.9071 Td -(4261 return -1;) 83.0018 Tj -0 -142.4004 Td -(4262 }) 34.9481 Tj -0 -151.8938 Td -(4263 ) 21.8426 Tj -0 -161.3871 Td -(4264 // Look for an empty dirent.) 152.898 Tj -0 -170.8805 Td -(4265 for\(off = 0; off < dp->size; off += sizeof\(de\)\){) 240.2683 Tj -0 -180.3739 Td -(4266 if\(readi\(dp, \(char*\)&de, off, sizeof\(de\)\) != si\ -zeof\(de\)\)) 283.9534 Tj -0 -189.8672 Td -(4267 panic\("dirlink read"\);) 144.161 Tj -0 -199.3606 Td -(4268 if\(de.inum == 0\)) 109.2129 Tj -0 -208.8539 Td -(4269 break;) 74.2647 Tj -0 -218.3473 Td -(4270 }) 34.9481 Tj -0 -227.8407 Td -(4271 ) 21.8426 Tj -0 -237.334 Td -(4272 strncpy\(de.name, name, DIRSIZ\);) 166.0035 Tj -0 -246.8274 Td -(4273 de.inum = inum;) 96.1073 Tj -0 -256.3207 Td -(4274 if\(writei\(dp, \(char*\)&de, off, sizeof\(de\)\) != siz\ -eof\(de\)\)) 279.5849 Tj -0 -265.8141 Td -(4275 panic\("dirlink"\);) 113.5814 Tj -0 -275.3075 Td -(4276 ) 21.8426 Tj -0 -284.8008 Td -(4277 return 0;) 69.8962 Tj -0 -294.2942 Td -(4278 }) 26.2111 Tj -0 -303.7875 Td -(4279 ) 21.8426 Tj -0 -313.2809 Td -(4280 ) 21.8426 Tj -0 -322.7743 Td -(4281 ) 21.8426 Tj -0 -332.2676 Td -(4282 ) 21.8426 Tj -0 -341.761 Td -(4283 ) 21.8426 Tj -0 -351.2543 Td -(4284 ) 21.8426 Tj -0 -360.7477 Td -(4285 ) 21.8426 Tj -0 -370.2411 Td -(4286 ) 21.8426 Tj -0 -379.7344 Td -(4287 ) 21.8426 Tj -0 -389.2278 Td -(4288 ) 21.8426 Tj -0 -398.7211 Td -(4289 ) 21.8426 Tj -0 -408.2145 Td -(4290 ) 21.8426 Tj -0 -417.7079 Td -(4291 ) 21.8426 Tj -0 -427.2012 Td -(4292 ) 21.8426 Tj -0 -436.6946 Td -(4293 ) 21.8426 Tj -0 -446.1879 Td -(4294 ) 21.8426 Tj -0 -455.6813 Td -(4295 ) 21.8426 Tj -0 -465.1747 Td -(4296 ) 21.8426 Tj -0 -474.668 Td -(4297 ) 21.8426 Tj -0 -484.1614 Td -(4298 ) 21.8426 Tj -0 -493.6547 Td -(4299 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 42) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 50 50 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.c Page 14) 157.2665 Tj -0 -28.4801 Td -(4300 // Paths) 56.7907 Tj -0 -37.9735 Td -(4301 ) 21.8426 Tj -0 -47.4668 Td -(4302 // Copy the next path element from path into name.) 240.2683 Tj -0 -56.9602 Td -(4303 // Return a pointer to the element following the copied on\ -e.) 283.9534 Tj -0 -66.4535 Td -(4304 // The returned path has no leading slashes,) 214.0572 Tj -0 -75.9469 Td -(4305 // so the caller can check *path=='\\0' to see if the name\ - is the last one.) 345.1126 Tj -0 -85.4403 Td -(4306 // If no name to remove, return 0.) 170.3721 Tj -0 -94.9336 Td -(4307 //) 30.5796 Tj -0 -104.427 Td -(4308 // Examples:) 74.2647 Tj -0 -113.9203 Td -(4309 // skipelem\("a/bb/c", name\) = "bb/c", setting name = "\ -a") 275.2164 Tj -0 -123.4137 Td -(4310 // skipelem\("///a//bb", name\) = "bb", setting name = "\ -a") 275.2164 Tj -0 -132.9071 Td -(4311 // skipelem\("a", name\) = "", setting name = "a") 235.8998 Tj -0 -142.4004 Td -(4312 // skipelem\("", name\) = skipelem\("////", name\) = 0) 249.0053 Tj -0 -151.8938 Td -(4313 //) 30.5796 Tj -0 -161.3871 Td -(4314 static char*) 74.2647 Tj -0 -170.8805 Td -(4315 skipelem\(char *path, char *name\)) 161.635 Tj -0 -180.3739 Td -(4316 {) 26.2111 Tj -0 -189.8672 Td -(4317 char *s;) 65.5277 Tj -0 -199.3606 Td -(4318 int len;) 65.5277 Tj -0 -208.8539 Td -(4319 ) 21.8426 Tj -0 -218.3473 Td -(4320 while\(*path == '/'\)) 113.5814 Tj -0 -227.8407 Td -(4321 path++;) 69.8962 Tj -0 -237.334 Td -(4322 if\(*path == 0\)) 91.7388 Tj -0 -246.8274 Td -(4323 return 0;) 78.6333 Tj -0 -256.3207 Td -(4324 s = path;) 69.8962 Tj -0 -265.8141 Td -(4325 while\(*path != '/' && *path != 0\)) 174.7406 Tj -0 -275.3075 Td -(4326 path++;) 69.8962 Tj -0 -284.8008 Td -(4327 len = path - s;) 96.1073 Tj -0 -294.2942 Td -(4328 if\(len >= DIRSIZ\)) 104.8443 Tj -0 -303.7875 Td -(4329 memmove\(name, s, DIRSIZ\);) 148.5295 Tj -0 -313.2809 Td -(4330 else {) 56.7907 Tj -0 -322.7743 Td -(4331 memmove\(name, s, len\);) 135.4239 Tj -0 -332.2676 Td -(4332 name[len] = 0;) 100.4758 Tj -0 -341.761 Td -(4333 }) 34.9481 Tj -0 -351.2543 Td -(4334 while\(*path == '/'\)) 113.5814 Tj -0 -360.7477 Td -(4335 path++;) 69.8962 Tj -0 -370.2411 Td -(4336 return path;) 83.0018 Tj -0 -379.7344 Td -(4337 }) 26.2111 Tj -0 -389.2278 Td -(4338 ) 21.8426 Tj -0 -398.7211 Td -(4339 ) 21.8426 Tj -0 -408.2145 Td -(4340 ) 21.8426 Tj -0 -417.7079 Td -(4341 ) 21.8426 Tj -0 -427.2012 Td -(4342 ) 21.8426 Tj -0 -436.6946 Td -(4343 ) 21.8426 Tj -0 -446.1879 Td -(4344 ) 21.8426 Tj -0 -455.6813 Td -(4345 ) 21.8426 Tj -0 -465.1747 Td -(4346 ) 21.8426 Tj -0 -474.668 Td -(4347 ) 21.8426 Tj -0 -484.1614 Td -(4348 ) 21.8426 Tj -0 -493.6547 Td -(4349 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 43) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/fs.c Page 15) 157.2665 Tj -0 -28.4801 Td -(4350 // Look up and return the inode for a path name.) 231.5313 Tj -0 -37.9735 Td -(4351 // If parent != 0, return the inode for the parent and cop\ -y the final) 323.2701 Tj -0 -47.4668 Td -(4352 // path element into name, which must have room for DIRSIZ\ - bytes.) 305.796 Tj -0 -56.9602 Td -(4353 static struct inode*) 109.2129 Tj -0 -66.4535 Td -(4354 namex\(char *path, int nameiparent, char *name\)) 222.7942 Tj -0 -75.9469 Td -(4355 {) 26.2111 Tj -0 -85.4403 Td -(4356 struct inode *ip, *next;) 135.4239 Tj -0 -94.9336 Td -(4357 ) 21.8426 Tj -0 -104.427 Td -(4358 if\(*path == '/'\)) 100.4758 Tj -0 -113.9203 Td -(4359 ip = iget\(ROOTDEV, ROOTINO\);) 161.635 Tj -0 -123.4137 Td -(4360 else) 48.0537 Tj -0 -132.9071 Td -(4361 ip = idup\(proc->cwd\);) 131.0554 Tj -0 -142.4004 Td -(4362 ) 21.8426 Tj -0 -151.8938 Td -(4363 while\(\(path = skipelem\(path, name\)\) != 0\){) 214.0572 Tj -0 -161.3871 Td -(4364 ilock\(ip\);) 83.0018 Tj -0 -170.8805 Td -(4365 if\(ip->type != T_DIR\){) 135.4239 Tj -0 -180.3739 Td -(4366 iunlockput\(ip\);) 113.5814 Tj -0 -189.8672 Td -(4367 return 0;) 87.3703 Tj -0 -199.3606 Td -(4368 }) 43.6851 Tj -0 -208.8539 Td -(4369 if\(nameiparent && *path == '\\0'\){) 183.4776 Tj -0 -218.3473 Td -(4370 // Stop one level early.) 152.898 Tj -0 -227.8407 Td -(4371 iunlock\(ip\);) 100.4758 Tj -0 -237.334 Td -(4372 return ip;) 91.7388 Tj -0 -246.8274 Td -(4373 }) 43.6851 Tj -0 -256.3207 Td -(4374 if\(\(next = dirlookup\(ip, name, 0\)\) == 0\){) 218.4257 Tj -0 -265.8141 Td -(4375 iunlockput\(ip\);) 113.5814 Tj -0 -275.3075 Td -(4376 return 0;) 87.3703 Tj -0 -284.8008 Td -(4377 }) 43.6851 Tj -0 -294.2942 Td -(4378 iunlockput\(ip\);) 104.8443 Tj -0 -303.7875 Td -(4379 ip = next;) 83.0018 Tj -0 -313.2809 Td -(4380 }) 34.9481 Tj -0 -322.7743 Td -(4381 if\(nameiparent\){) 100.4758 Tj -0 -332.2676 Td -(4382 iput\(ip\);) 78.6333 Tj -0 -341.761 Td -(4383 return 0;) 78.6333 Tj -0 -351.2543 Td -(4384 }) 34.9481 Tj -0 -360.7477 Td -(4385 return ip;) 74.2647 Tj -0 -370.2411 Td -(4386 }) 26.2111 Tj -0 -379.7344 Td -(4387 ) 21.8426 Tj -0 -389.2278 Td -(4388 struct inode*) 78.6333 Tj -0 -398.7211 Td -(4389 namei\(char *path\)) 96.1073 Tj -0 -408.2145 Td -(4390 {) 26.2111 Tj -0 -417.7079 Td -(4391 char name[DIRSIZ];) 109.2129 Tj -0 -427.2012 Td -(4392 return namex\(path, 0, name\);) 152.898 Tj -0 -436.6946 Td -(4393 }) 26.2111 Tj -0 -446.1879 Td -(4394 ) 21.8426 Tj -0 -455.6813 Td -(4395 struct inode*) 78.6333 Tj -0 -465.1747 Td -(4396 nameiparent\(char *path, char *name\)) 174.7406 Tj -0 -474.668 Td -(4397 {) 26.2111 Tj -0 -484.1614 Td -(4398 return namex\(path, 1, name\);) 152.898 Tj -0 -493.6547 Td -(4399 }) 26.2111 Tj -0 -522.1348 Td -(Sheet 43) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 51 51 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/file.c Page 1) 161.635 Tj -0 -28.4801 Td -(4400 #include "types.h") 100.4758 Tj -0 -37.9735 Td -(4401 #include "defs.h") 96.1073 Tj -0 -47.4668 Td -(4402 #include "param.h") 100.4758 Tj -0 -56.9602 Td -(4403 #include "fs.h") 87.3703 Tj -0 -66.4535 Td -(4404 #include "file.h") 96.1073 Tj -0 -75.9469 Td -(4405 #include "spinlock.h") 113.5814 Tj -0 -85.4403 Td -(4406 ) 21.8426 Tj -0 -94.9336 Td -(4407 struct devsw devsw[NDEV];) 131.0554 Tj -0 -104.427 Td -(4408 struct {) 56.7907 Tj -0 -113.9203 Td -(4409 struct spinlock lock;) 122.3184 Tj -0 -123.4137 Td -(4410 struct file file[NFILE];) 135.4239 Tj -0 -132.9071 Td -(4411 } ftable;) 61.1592 Tj -0 -142.4004 Td -(4412 ) 21.8426 Tj -0 -151.8938 Td -(4413 void) 39.3166 Tj -0 -161.3871 Td -(4414 fileinit\(void\)) 83.0018 Tj -0 -170.8805 Td -(4415 {) 26.2111 Tj -0 -180.3739 Td -(4416 initlock\(&ftable.lock, "ftable"\);) 174.7406 Tj -0 -189.8672 Td -(4417 }) 26.2111 Tj -0 -199.3606 Td -(4418 ) 21.8426 Tj -0 -208.8539 Td -(4419 // Allocate a file structure.) 148.5295 Tj -0 -218.3473 Td -(4420 struct file*) 74.2647 Tj -0 -227.8407 Td -(4421 filealloc\(void\)) 87.3703 Tj -0 -237.334 Td -(4422 {) 26.2111 Tj -0 -246.8274 Td -(4423 struct file *f;) 96.1073 Tj -0 -256.3207 Td -(4424 ) 21.8426 Tj -0 -265.8141 Td -(4425 acquire\(&ftable.lock\);) 126.6869 Tj -0 -275.3075 Td -(4426 for\(f = ftable.file; f < ftable.file + NFILE; f++\){) 253.3738 Tj -0 -284.8008 Td -(4427 if\(f->ref == 0\){) 109.2129 Tj -0 -294.2942 Td -(4428 f->ref = 1;) 96.1073 Tj -0 -303.7875 Td -(4429 release\(&ftable.lock\);) 144.161 Tj -0 -313.2809 Td -(4430 return f;) 87.3703 Tj -0 -322.7743 Td -(4431 }) 43.6851 Tj -0 -332.2676 Td -(4432 }) 34.9481 Tj -0 -341.761 Td -(4433 release\(&ftable.lock\);) 126.6869 Tj -0 -351.2543 Td -(4434 return 0;) 69.8962 Tj -0 -360.7477 Td -(4435 }) 26.2111 Tj -0 -370.2411 Td -(4436 ) 21.8426 Tj -0 -379.7344 Td -(4437 // Increment ref count for file f.) 170.3721 Tj -0 -389.2278 Td -(4438 struct file*) 74.2647 Tj -0 -398.7211 Td -(4439 filedup\(struct file *f\)) 122.3184 Tj -0 -408.2145 Td -(4440 {) 26.2111 Tj -0 -417.7079 Td -(4441 acquire\(&ftable.lock\);) 126.6869 Tj -0 -427.2012 Td -(4442 if\(f->ref < 1\)) 91.7388 Tj -0 -436.6946 Td -(4443 panic\("filedup"\);) 113.5814 Tj -0 -446.1879 Td -(4444 f->ref++;) 69.8962 Tj -0 -455.6813 Td -(4445 release\(&ftable.lock\);) 126.6869 Tj -0 -465.1747 Td -(4446 return f;) 69.8962 Tj -0 -474.668 Td -(4447 }) 26.2111 Tj -0 -484.1614 Td -(4448 ) 21.8426 Tj -0 -493.6547 Td -(4449 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 44) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/file.c Page 2) 161.635 Tj -0 -28.4801 Td -(4450 // Close file f. \(Decrement ref count, close when reache\ -s 0.\)) 292.6905 Tj -0 -37.9735 Td -(4451 void) 39.3166 Tj -0 -47.4668 Td -(4452 fileclose\(struct file *f\)) 131.0554 Tj -0 -56.9602 Td -(4453 {) 26.2111 Tj -0 -66.4535 Td -(4454 struct file ff;) 96.1073 Tj -0 -75.9469 Td -(4455 ) 21.8426 Tj -0 -85.4403 Td -(4456 acquire\(&ftable.lock\);) 126.6869 Tj -0 -94.9336 Td -(4457 if\(f->ref < 1\)) 91.7388 Tj -0 -104.427 Td -(4458 panic\("fileclose"\);) 122.3184 Tj -0 -113.9203 Td -(4459 if\(--f->ref > 0\){) 104.8443 Tj -0 -123.4137 Td -(4460 release\(&ftable.lock\);) 135.4239 Tj -0 -132.9071 Td -(4461 return;) 69.8962 Tj -0 -142.4004 Td -(4462 }) 34.9481 Tj -0 -151.8938 Td -(4463 ff = *f;) 65.5277 Tj -0 -161.3871 Td -(4464 f->ref = 0;) 78.6333 Tj -0 -170.8805 Td -(4465 f->type = FD_NONE;) 109.2129 Tj -0 -180.3739 Td -(4466 release\(&ftable.lock\);) 126.6869 Tj -0 -189.8672 Td -(4467 ) 21.8426 Tj -0 -199.3606 Td -(4468 if\(ff.type == FD_PIPE\)) 126.6869 Tj -0 -208.8539 Td -(4469 pipeclose\(ff.pipe, ff.writable\);) 179.1091 Tj -0 -218.3473 Td -(4470 else if\(ff.type == FD_INODE\)) 152.898 Tj -0 -227.8407 Td -(4471 iput\(ff.ip\);) 91.7388 Tj -0 -237.334 Td -(4472 }) 26.2111 Tj -0 -246.8274 Td -(4473 ) 21.8426 Tj -0 -256.3207 Td -(4474 // Get metadata about file f.) 148.5295 Tj -0 -265.8141 Td -(4475 int) 34.9481 Tj -0 -275.3075 Td -(4476 filestat\(struct file *f, struct stat *st\)) 200.9517 Tj -0 -284.8008 Td -(4477 {) 26.2111 Tj -0 -294.2942 Td -(4478 if\(f->type == FD_INODE\){) 135.4239 Tj -0 -303.7875 Td -(4479 ilock\(f->ip\);) 96.1073 Tj -0 -313.2809 Td -(4480 stati\(f->ip, st\);) 113.5814 Tj -0 -322.7743 Td -(4481 iunlock\(f->ip\);) 104.8443 Tj -0 -332.2676 Td -(4482 return 0;) 78.6333 Tj -0 -341.761 Td -(4483 }) 34.9481 Tj -0 -351.2543 Td -(4484 return -1;) 74.2647 Tj -0 -360.7477 Td -(4485 }) 26.2111 Tj -0 -370.2411 Td -(4486 ) 21.8426 Tj -0 -379.7344 Td -(4487 ) 21.8426 Tj -0 -389.2278 Td -(4488 ) 21.8426 Tj -0 -398.7211 Td -(4489 ) 21.8426 Tj -0 -408.2145 Td -(4490 ) 21.8426 Tj -0 -417.7079 Td -(4491 ) 21.8426 Tj -0 -427.2012 Td -(4492 ) 21.8426 Tj -0 -436.6946 Td -(4493 ) 21.8426 Tj -0 -446.1879 Td -(4494 ) 21.8426 Tj -0 -455.6813 Td -(4495 ) 21.8426 Tj -0 -465.1747 Td -(4496 ) 21.8426 Tj -0 -474.668 Td -(4497 ) 21.8426 Tj -0 -484.1614 Td -(4498 ) 21.8426 Tj -0 -493.6547 Td -(4499 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 44) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 52 52 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/file.c Page 3) 161.635 Tj -0 -28.4801 Td -(4500 // Read from file f. Addr is kernel address.) 218.4257 Tj -0 -37.9735 Td -(4501 int) 34.9481 Tj -0 -47.4668 Td -(4502 fileread\(struct file *f, char *addr, int n\)) 209.6887 Tj -0 -56.9602 Td -(4503 {) 26.2111 Tj -0 -66.4535 Td -(4504 int r;) 56.7907 Tj -0 -75.9469 Td -(4505 ) 21.8426 Tj -0 -85.4403 Td -(4506 if\(f->readable == 0\)) 117.9499 Tj -0 -94.9336 Td -(4507 return -1;) 83.0018 Tj -0 -104.427 Td -(4508 if\(f->type == FD_PIPE\)) 126.6869 Tj -0 -113.9203 Td -(4509 return piperead\(f->pipe, addr, n\);) 187.8461 Tj -0 -123.4137 Td -(4510 if\(f->type == FD_INODE\){) 135.4239 Tj -0 -132.9071 Td -(4511 ilock\(f->ip\);) 96.1073 Tj -0 -142.4004 Td -(4512 if\(\(r = readi\(f->ip, addr, f->off, n\)\) > 0\)) 227.1628 Tj -0 -151.8938 Td -(4513 f->off += r;) 100.4758 Tj -0 -161.3871 Td -(4514 iunlock\(f->ip\);) 104.8443 Tj -0 -170.8805 Td -(4515 return r;) 78.6333 Tj -0 -180.3739 Td -(4516 }) 34.9481 Tj -0 -189.8672 Td -(4517 panic\("fileread"\);) 109.2129 Tj -0 -199.3606 Td -(4518 }) 26.2111 Tj -0 -208.8539 Td -(4519 ) 21.8426 Tj -0 -218.3473 Td -(4520 // Write to file f. Addr is kernel address.) 214.0572 Tj -0 -227.8407 Td -(4521 int) 34.9481 Tj -0 -237.334 Td -(4522 filewrite\(struct file *f, char *addr, int n\)) 214.0572 Tj -0 -246.8274 Td -(4523 {) 26.2111 Tj -0 -256.3207 Td -(4524 int r;) 56.7907 Tj -0 -265.8141 Td -(4525 ) 21.8426 Tj -0 -275.3075 Td -(4526 if\(f->writable == 0\)) 117.9499 Tj -0 -284.8008 Td -(4527 return -1;) 83.0018 Tj -0 -294.2942 Td -(4528 if\(f->type == FD_PIPE\)) 126.6869 Tj -0 -303.7875 Td -(4529 return pipewrite\(f->pipe, addr, n\);) 192.2146 Tj -0 -313.2809 Td -(4530 if\(f->type == FD_INODE\){) 135.4239 Tj -0 -322.7743 Td -(4531 ilock\(f->ip\);) 96.1073 Tj -0 -332.2676 Td -(4532 if\(\(r = writei\(f->ip, addr, f->off, n\)\) > 0\)) 231.5313 Tj -0 -341.761 Td -(4533 f->off += r;) 100.4758 Tj -0 -351.2543 Td -(4534 iunlock\(f->ip\);) 104.8443 Tj -0 -360.7477 Td -(4535 return r;) 78.6333 Tj -0 -370.2411 Td -(4536 }) 34.9481 Tj -0 -379.7344 Td -(4537 panic\("filewrite"\);) 113.5814 Tj -0 -389.2278 Td -(4538 }) 26.2111 Tj -0 -398.7211 Td -(4539 ) 21.8426 Tj -0 -408.2145 Td -(4540 ) 21.8426 Tj -0 -417.7079 Td -(4541 ) 21.8426 Tj -0 -427.2012 Td -(4542 ) 21.8426 Tj -0 -436.6946 Td -(4543 ) 21.8426 Tj -0 -446.1879 Td -(4544 ) 21.8426 Tj -0 -455.6813 Td -(4545 ) 21.8426 Tj -0 -465.1747 Td -(4546 ) 21.8426 Tj -0 -474.668 Td -(4547 ) 21.8426 Tj -0 -484.1614 Td -(4548 ) 21.8426 Tj -0 -493.6547 Td -(4549 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 45) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sysfile.c Page 1) 174.7406 Tj -0 -28.4801 Td -(4550 #include "types.h") 100.4758 Tj -0 -37.9735 Td -(4551 #include "defs.h") 96.1073 Tj -0 -47.4668 Td -(4552 #include "param.h") 100.4758 Tj -0 -56.9602 Td -(4553 #include "stat.h") 96.1073 Tj -0 -66.4535 Td -(4554 #include "mmu.h") 91.7388 Tj -0 -75.9469 Td -(4555 #include "proc.h") 96.1073 Tj -0 -85.4403 Td -(4556 #include "fs.h") 87.3703 Tj -0 -94.9336 Td -(4557 #include "file.h") 96.1073 Tj -0 -104.427 Td -(4558 #include "fcntl.h") 100.4758 Tj -0 -113.9203 Td -(4559 ) 21.8426 Tj -0 -123.4137 Td -(4560 // Fetch the nth word-sized system call argument as a file\ - descriptor) 323.2701 Tj -0 -132.9071 Td -(4561 // and return both the descriptor and the corresponding st\ -ruct file.) 318.9016 Tj -0 -142.4004 Td -(4562 static int) 65.5277 Tj -0 -151.8938 Td -(4563 argfd\(int n, int *pfd, struct file **pf\)) 196.5831 Tj -0 -161.3871 Td -(4564 {) 26.2111 Tj -0 -170.8805 Td -(4565 int fd;) 61.1592 Tj -0 -180.3739 Td -(4566 struct file *f;) 96.1073 Tj -0 -189.8672 Td -(4567 ) 21.8426 Tj -0 -199.3606 Td -(4568 if\(argint\(n, &fd\) < 0\)) 126.6869 Tj -0 -208.8539 Td -(4569 return -1;) 83.0018 Tj -0 -218.3473 Td -(4570 if\(fd < 0 || fd >= NOFILE || \(f=proc->ofile[fd]\) == 0\ -\)) 266.4794 Tj -0 -227.8407 Td -(4571 return -1;) 83.0018 Tj -0 -237.334 Td -(4572 if\(pfd\)) 61.1592 Tj -0 -246.8274 Td -(4573 *pfd = fd;) 83.0018 Tj -0 -256.3207 Td -(4574 if\(pf\)) 56.7907 Tj -0 -265.8141 Td -(4575 *pf = f;) 74.2647 Tj -0 -275.3075 Td -(4576 return 0;) 69.8962 Tj -0 -284.8008 Td -(4577 }) 26.2111 Tj -0 -294.2942 Td -(4578 ) 21.8426 Tj -0 -303.7875 Td -(4579 // Allocate a file descriptor for the given file.) 235.8998 Tj -0 -313.2809 Td -(4580 // Takes over file reference from caller on success.) 249.0053 Tj -0 -322.7743 Td -(4581 static int) 65.5277 Tj -0 -332.2676 Td -(4582 fdalloc\(struct file *f\)) 122.3184 Tj -0 -341.761 Td -(4583 {) 26.2111 Tj -0 -351.2543 Td -(4584 int fd;) 61.1592 Tj -0 -360.7477 Td -(4585 ) 21.8426 Tj -0 -370.2411 Td -(4586 for\(fd = 0; fd < NOFILE; fd++\){) 166.0035 Tj -0 -379.7344 Td -(4587 if\(proc->ofile[fd] == 0\){) 148.5295 Tj -0 -389.2278 Td -(4588 proc->ofile[fd] = f;) 135.4239 Tj -0 -398.7211 Td -(4589 return fd;) 91.7388 Tj -0 -408.2145 Td -(4590 }) 43.6851 Tj -0 -417.7079 Td -(4591 }) 34.9481 Tj -0 -427.2012 Td -(4592 return -1;) 74.2647 Tj -0 -436.6946 Td -(4593 }) 26.2111 Tj -0 -446.1879 Td -(4594 ) 21.8426 Tj -0 -455.6813 Td -(4595 ) 21.8426 Tj -0 -465.1747 Td -(4596 ) 21.8426 Tj -0 -474.668 Td -(4597 ) 21.8426 Tj -0 -484.1614 Td -(4598 ) 21.8426 Tj -0 -493.6547 Td -(4599 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 45) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 53 53 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sysfile.c Page 2) 174.7406 Tj -0 -28.4801 Td -(4600 int) 34.9481 Tj -0 -37.9735 Td -(4601 sys_dup\(void\)) 78.6333 Tj -0 -47.4668 Td -(4602 {) 26.2111 Tj -0 -56.9602 Td -(4603 struct file *f;) 96.1073 Tj -0 -66.4535 Td -(4604 int fd;) 61.1592 Tj -0 -75.9469 Td -(4605 ) 21.8426 Tj -0 -85.4403 Td -(4606 if\(argfd\(0, 0, &f\) < 0\)) 131.0554 Tj -0 -94.9336 Td -(4607 return -1;) 83.0018 Tj -0 -104.427 Td -(4608 if\(\(fd=fdalloc\(f\)\) < 0\)) 131.0554 Tj -0 -113.9203 Td -(4609 return -1;) 83.0018 Tj -0 -123.4137 Td -(4610 filedup\(f\);) 78.6333 Tj -0 -132.9071 Td -(4611 return fd;) 74.2647 Tj -0 -142.4004 Td -(4612 }) 26.2111 Tj -0 -151.8938 Td -(4613 ) 21.8426 Tj -0 -161.3871 Td -(4614 int) 34.9481 Tj -0 -170.8805 Td -(4615 sys_read\(void\)) 83.0018 Tj -0 -180.3739 Td -(4616 {) 26.2111 Tj -0 -189.8672 Td -(4617 struct file *f;) 96.1073 Tj -0 -199.3606 Td -(4618 int n;) 56.7907 Tj -0 -208.8539 Td -(4619 char *p;) 65.5277 Tj -0 -218.3473 Td -(4620 ) 21.8426 Tj -0 -227.8407 Td -(4621 if\(argfd\(0, 0, &f\) < 0 || argint\(2, &n\) < 0 || argp\ -tr\(1, &p, n\) < 0\)) 327.6386 Tj -0 -237.334 Td -(4622 return -1;) 83.0018 Tj -0 -246.8274 Td -(4623 return fileread\(f, p, n\);) 139.7925 Tj -0 -256.3207 Td -(4624 }) 26.2111 Tj -0 -265.8141 Td -(4625 ) 21.8426 Tj -0 -275.3075 Td -(4626 int) 34.9481 Tj -0 -284.8008 Td -(4627 sys_write\(void\)) 87.3703 Tj -0 -294.2942 Td -(4628 {) 26.2111 Tj -0 -303.7875 Td -(4629 struct file *f;) 96.1073 Tj -0 -313.2809 Td -(4630 int n;) 56.7907 Tj -0 -322.7743 Td -(4631 char *p;) 65.5277 Tj -0 -332.2676 Td -(4632 ) 21.8426 Tj -0 -341.761 Td -(4633 if\(argfd\(0, 0, &f\) < 0 || argint\(2, &n\) < 0 || argp\ -tr\(1, &p, n\) < 0\)) 327.6386 Tj -0 -351.2543 Td -(4634 return -1;) 83.0018 Tj -0 -360.7477 Td -(4635 return filewrite\(f, p, n\);) 144.161 Tj -0 -370.2411 Td -(4636 }) 26.2111 Tj -0 -379.7344 Td -(4637 ) 21.8426 Tj -0 -389.2278 Td -(4638 int) 34.9481 Tj -0 -398.7211 Td -(4639 sys_close\(void\)) 87.3703 Tj -0 -408.2145 Td -(4640 {) 26.2111 Tj -0 -417.7079 Td -(4641 int fd;) 61.1592 Tj -0 -427.2012 Td -(4642 struct file *f;) 96.1073 Tj -0 -436.6946 Td -(4643 ) 21.8426 Tj -0 -446.1879 Td -(4644 if\(argfd\(0, &fd, &f\) < 0\)) 139.7925 Tj -0 -455.6813 Td -(4645 return -1;) 83.0018 Tj -0 -465.1747 Td -(4646 proc->ofile[fd] = 0;) 117.9499 Tj -0 -474.668 Td -(4647 fileclose\(f\);) 87.3703 Tj -0 -484.1614 Td -(4648 return 0;) 69.8962 Tj -0 -493.6547 Td -(4649 }) 26.2111 Tj -0 -522.1348 Td -(Sheet 46) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sysfile.c Page 3) 174.7406 Tj -0 -28.4801 Td -(4650 int) 34.9481 Tj -0 -37.9735 Td -(4651 sys_fstat\(void\)) 87.3703 Tj -0 -47.4668 Td -(4652 {) 26.2111 Tj -0 -56.9602 Td -(4653 struct file *f;) 96.1073 Tj -0 -66.4535 Td -(4654 struct stat *st;) 100.4758 Tj -0 -75.9469 Td -(4655 ) 21.8426 Tj -0 -85.4403 Td -(4656 if\(argfd\(0, 0, &f\) < 0 || argptr\(1, \(void*\)&st, si\ -zeof\(*st\)\) < 0\)) 314.533 Tj -0 -94.9336 Td -(4657 return -1;) 83.0018 Tj -0 -104.427 Td -(4658 return filestat\(f, st\);) 131.0554 Tj -0 -113.9203 Td -(4659 }) 26.2111 Tj -0 -123.4137 Td -(4660 ) 21.8426 Tj -0 -132.9071 Td -(4661 // Create the path new as a link to the same inode as old.) 275.2164 Tj -0 -142.4004 Td -(4662 int) 34.9481 Tj -0 -151.8938 Td -(4663 sys_link\(void\)) 83.0018 Tj -0 -161.3871 Td -(4664 {) 26.2111 Tj -0 -170.8805 Td -(4665 char name[DIRSIZ], *new, *old;) 161.635 Tj -0 -180.3739 Td -(4666 struct inode *dp, *ip;) 126.6869 Tj -0 -189.8672 Td -(4667 ) 21.8426 Tj -0 -199.3606 Td -(4668 if\(argstr\(0, &old\) < 0 || argstr\(1, &new\) < 0\)) 231.5313 Tj -0 -208.8539 Td -(4669 return -1;) 83.0018 Tj -0 -218.3473 Td -(4670 if\(\(ip = namei\(old\)\) == 0\)) 144.161 Tj -0 -227.8407 Td -(4671 return -1;) 83.0018 Tj -0 -237.334 Td -(4672 ilock\(ip\);) 74.2647 Tj -0 -246.8274 Td -(4673 if\(ip->type == T_DIR\){) 126.6869 Tj -0 -256.3207 Td -(4674 iunlockput\(ip\);) 104.8443 Tj -0 -265.8141 Td -(4675 return -1;) 83.0018 Tj -0 -275.3075 Td -(4676 }) 34.9481 Tj -0 -284.8008 Td -(4677 ip->nlink++;) 83.0018 Tj -0 -294.2942 Td -(4678 iupdate\(ip\);) 83.0018 Tj -0 -303.7875 Td -(4679 iunlock\(ip\);) 83.0018 Tj -0 -313.2809 Td -(4680 ) 21.8426 Tj -0 -322.7743 Td -(4681 if\(\(dp = nameiparent\(new, name\)\) == 0\)) 196.5831 Tj -0 -332.2676 Td -(4682 goto bad;) 78.6333 Tj -0 -341.761 Td -(4683 ilock\(dp\);) 74.2647 Tj -0 -351.2543 Td -(4684 if\(dp->dev != ip->dev || dirlink\(dp, name, ip->inum\) \ -< 0\){) 283.9534 Tj -0 -360.7477 Td -(4685 iunlockput\(dp\);) 104.8443 Tj -0 -370.2411 Td -(4686 goto bad;) 78.6333 Tj -0 -379.7344 Td -(4687 }) 34.9481 Tj -0 -389.2278 Td -(4688 iunlockput\(dp\);) 96.1073 Tj -0 -398.7211 Td -(4689 iput\(ip\);) 69.8962 Tj -0 -408.2145 Td -(4690 return 0;) 69.8962 Tj -0 -417.7079 Td -(4691 ) 21.8426 Tj -0 -427.2012 Td -(4692 bad:) 39.3166 Tj -0 -436.6946 Td -(4693 ilock\(ip\);) 74.2647 Tj -0 -446.1879 Td -(4694 ip->nlink--;) 83.0018 Tj -0 -455.6813 Td -(4695 iupdate\(ip\);) 83.0018 Tj -0 -465.1747 Td -(4696 iunlockput\(ip\);) 96.1073 Tj -0 -474.668 Td -(4697 return -1;) 74.2647 Tj -0 -484.1614 Td -(4698 }) 26.2111 Tj -0 -493.6547 Td -(4699 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 46) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 54 54 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sysfile.c Page 4) 174.7406 Tj -0 -28.4801 Td -(4700 // Is the directory dp empty except for "." and ".." ?) 257.7424 Tj -0 -37.9735 Td -(4701 static int) 65.5277 Tj -0 -47.4668 Td -(4702 isdirempty\(struct inode *dp\)) 144.161 Tj -0 -56.9602 Td -(4703 {) 26.2111 Tj -0 -66.4535 Td -(4704 int off;) 65.5277 Tj -0 -75.9469 Td -(4705 struct dirent de;) 104.8443 Tj -0 -85.4403 Td -(4706 ) 21.8426 Tj -0 -94.9336 Td -(4707 for\(off=2*sizeof\(de\); offsize; off+=sizeof\(de\)\ -\){) 262.1109 Tj -0 -104.427 Td -(4708 if\(readi\(dp, \(char*\)&de, off, sizeof\(de\)\) != si\ -zeof\(de\)\)) 283.9534 Tj -0 -113.9203 Td -(4709 panic\("isdirempty: readi"\);) 166.0035 Tj -0 -123.4137 Td -(4710 if\(de.inum != 0\)) 109.2129 Tj -0 -132.9071 Td -(4711 return 0;) 87.3703 Tj -0 -142.4004 Td -(4712 }) 34.9481 Tj -0 -151.8938 Td -(4713 return 1;) 69.8962 Tj -0 -161.3871 Td -(4714 }) 26.2111 Tj -0 -170.8805 Td -(4715 ) 21.8426 Tj -0 -180.3739 Td -(4716 ) 21.8426 Tj -0 -189.8672 Td -(4717 ) 21.8426 Tj -0 -199.3606 Td -(4718 ) 21.8426 Tj -0 -208.8539 Td -(4719 ) 21.8426 Tj -0 -218.3473 Td -(4720 ) 21.8426 Tj -0 -227.8407 Td -(4721 ) 21.8426 Tj -0 -237.334 Td -(4722 ) 21.8426 Tj -0 -246.8274 Td -(4723 ) 21.8426 Tj -0 -256.3207 Td -(4724 ) 21.8426 Tj -0 -265.8141 Td -(4725 ) 21.8426 Tj -0 -275.3075 Td -(4726 ) 21.8426 Tj -0 -284.8008 Td -(4727 ) 21.8426 Tj -0 -294.2942 Td -(4728 ) 21.8426 Tj -0 -303.7875 Td -(4729 ) 21.8426 Tj -0 -313.2809 Td -(4730 ) 21.8426 Tj -0 -322.7743 Td -(4731 ) 21.8426 Tj -0 -332.2676 Td -(4732 ) 21.8426 Tj -0 -341.761 Td -(4733 ) 21.8426 Tj -0 -351.2543 Td -(4734 ) 21.8426 Tj -0 -360.7477 Td -(4735 ) 21.8426 Tj -0 -370.2411 Td -(4736 ) 21.8426 Tj -0 -379.7344 Td -(4737 ) 21.8426 Tj -0 -389.2278 Td -(4738 ) 21.8426 Tj -0 -398.7211 Td -(4739 ) 21.8426 Tj -0 -408.2145 Td -(4740 ) 21.8426 Tj -0 -417.7079 Td -(4741 ) 21.8426 Tj -0 -427.2012 Td -(4742 ) 21.8426 Tj -0 -436.6946 Td -(4743 ) 21.8426 Tj -0 -446.1879 Td -(4744 ) 21.8426 Tj -0 -455.6813 Td -(4745 ) 21.8426 Tj -0 -465.1747 Td -(4746 ) 21.8426 Tj -0 -474.668 Td -(4747 ) 21.8426 Tj -0 -484.1614 Td -(4748 ) 21.8426 Tj -0 -493.6547 Td -(4749 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 47) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sysfile.c Page 5) 174.7406 Tj -0 -28.4801 Td -(4750 int) 34.9481 Tj -0 -37.9735 Td -(4751 sys_unlink\(void\)) 91.7388 Tj -0 -47.4668 Td -(4752 {) 26.2111 Tj -0 -56.9602 Td -(4753 struct inode *ip, *dp;) 126.6869 Tj -0 -66.4535 Td -(4754 struct dirent de;) 104.8443 Tj -0 -75.9469 Td -(4755 char name[DIRSIZ], *path;) 139.7925 Tj -0 -85.4403 Td -(4756 uint off;) 69.8962 Tj -0 -94.9336 Td -(4757 ) 21.8426 Tj -0 -104.427 Td -(4758 if\(argstr\(0, &path\) < 0\)) 135.4239 Tj -0 -113.9203 Td -(4759 return -1;) 83.0018 Tj -0 -123.4137 Td -(4760 if\(\(dp = nameiparent\(path, name\)\) == 0\)) 200.9517 Tj -0 -132.9071 Td -(4761 return -1;) 83.0018 Tj -0 -142.4004 Td -(4762 ilock\(dp\);) 74.2647 Tj -0 -151.8938 Td -(4763 ) 21.8426 Tj -0 -161.3871 Td -(4764 // Cannot unlink "." or "..".) 157.2665 Tj -0 -170.8805 Td -(4765 if\(namecmp\(name, "."\) == 0 || namecmp\(name, ".."\) =\ -= 0\){) 275.2164 Tj -0 -180.3739 Td -(4766 iunlockput\(dp\);) 104.8443 Tj -0 -189.8672 Td -(4767 return -1;) 83.0018 Tj -0 -199.3606 Td -(4768 }) 34.9481 Tj -0 -208.8539 Td -(4769 ) 21.8426 Tj -0 -218.3473 Td -(4770 if\(\(ip = dirlookup\(dp, name, &off\)\) == 0\){) 214.0572 Tj -0 -227.8407 Td -(4771 iunlockput\(dp\);) 104.8443 Tj -0 -237.334 Td -(4772 return -1;) 83.0018 Tj -0 -246.8274 Td -(4773 }) 34.9481 Tj -0 -256.3207 Td -(4774 ilock\(ip\);) 74.2647 Tj -0 -265.8141 Td -(4775 ) 21.8426 Tj -0 -275.3075 Td -(4776 if\(ip->nlink < 1\)) 104.8443 Tj -0 -284.8008 Td -(4777 panic\("unlink: nlink < 1"\);) 157.2665 Tj -0 -294.2942 Td -(4778 if\(ip->type == T_DIR && !isdirempty\(ip\)\){) 209.6887 Tj -0 -303.7875 Td -(4779 iunlockput\(ip\);) 104.8443 Tj -0 -313.2809 Td -(4780 iunlockput\(dp\);) 104.8443 Tj -0 -322.7743 Td -(4781 return -1;) 83.0018 Tj -0 -332.2676 Td -(4782 }) 34.9481 Tj -0 -341.761 Td -(4783 ) 21.8426 Tj -0 -351.2543 Td -(4784 memset\(&de, 0, sizeof\(de\)\);) 148.5295 Tj -0 -360.7477 Td -(4785 if\(writei\(dp, \(char*\)&de, off, sizeof\(de\)\) != siz\ -eof\(de\)\)) 279.5849 Tj -0 -370.2411 Td -(4786 panic\("unlink: writei"\);) 144.161 Tj -0 -379.7344 Td -(4787 if\(ip->type == T_DIR\){) 126.6869 Tj -0 -389.2278 Td -(4788 dp->nlink--;) 91.7388 Tj -0 -398.7211 Td -(4789 iupdate\(dp\);) 91.7388 Tj -0 -408.2145 Td -(4790 }) 34.9481 Tj -0 -417.7079 Td -(4791 iunlockput\(dp\);) 96.1073 Tj -0 -427.2012 Td -(4792 ) 21.8426 Tj -0 -436.6946 Td -(4793 ip->nlink--;) 83.0018 Tj -0 -446.1879 Td -(4794 iupdate\(ip\);) 83.0018 Tj -0 -455.6813 Td -(4795 iunlockput\(ip\);) 96.1073 Tj -0 -465.1747 Td -(4796 return 0;) 69.8962 Tj -0 -474.668 Td -(4797 }) 26.2111 Tj -0 -484.1614 Td -(4798 ) 21.8426 Tj -0 -493.6547 Td -(4799 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 47) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 55 55 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sysfile.c Page 6) 174.7406 Tj -0 -28.4801 Td -(4800 static struct inode*) 109.2129 Tj -0 -37.9735 Td -(4801 create\(char *path, short type, short major, short minor\)) 266.4794 Tj -0 -47.4668 Td -(4802 {) 26.2111 Tj -0 -56.9602 Td -(4803 uint off;) 69.8962 Tj -0 -66.4535 Td -(4804 struct inode *ip, *dp;) 126.6869 Tj -0 -75.9469 Td -(4805 char name[DIRSIZ];) 109.2129 Tj -0 -85.4403 Td -(4806 ) 21.8426 Tj -0 -94.9336 Td -(4807 if\(\(dp = nameiparent\(path, name\)\) == 0\)) 200.9517 Tj -0 -104.427 Td -(4808 return 0;) 78.6333 Tj -0 -113.9203 Td -(4809 ilock\(dp\);) 74.2647 Tj -0 -123.4137 Td -(4810 ) 21.8426 Tj -0 -132.9071 Td -(4811 if\(\(ip = dirlookup\(dp, name, &off\)\) != 0\){) 214.0572 Tj -0 -142.4004 Td -(4812 iunlockput\(dp\);) 104.8443 Tj -0 -151.8938 Td -(4813 ilock\(ip\);) 83.0018 Tj -0 -161.3871 Td -(4814 if\(type == T_FILE && ip->type == T_FILE\)) 214.0572 Tj -0 -170.8805 Td -(4815 return ip;) 91.7388 Tj -0 -180.3739 Td -(4816 iunlockput\(ip\);) 104.8443 Tj -0 -189.8672 Td -(4817 return 0;) 78.6333 Tj -0 -199.3606 Td -(4818 }) 34.9481 Tj -0 -208.8539 Td -(4819 ) 21.8426 Tj -0 -218.3473 Td -(4820 if\(\(ip = ialloc\(dp->dev, type\)\) == 0\)) 192.2146 Tj -0 -227.8407 Td -(4821 panic\("create: ialloc"\);) 144.161 Tj -0 -237.334 Td -(4822 ) 21.8426 Tj -0 -246.8274 Td -(4823 ilock\(ip\);) 74.2647 Tj -0 -256.3207 Td -(4824 ip->major = major;) 109.2129 Tj -0 -265.8141 Td -(4825 ip->minor = minor;) 109.2129 Tj -0 -275.3075 Td -(4826 ip->nlink = 1;) 91.7388 Tj -0 -284.8008 Td -(4827 iupdate\(ip\);) 83.0018 Tj -0 -294.2942 Td -(4828 ) 21.8426 Tj -0 -303.7875 Td -(4829 if\(type == T_DIR\){ // Create . and .. entries.) 235.8998 Tj -0 -313.2809 Td -(4830 dp->nlink++; // for "..") 148.5295 Tj -0 -322.7743 Td -(4831 iupdate\(dp\);) 91.7388 Tj -0 -332.2676 Td -(4832 // No ip->nlink++ for ".": avoid cyclic ref count.) 257.7424 Tj -0 -341.761 Td -(4833 if\(dirlink\(ip, ".", ip->inum\) < 0 || dirlink\(ip, "\ -..", dp->inum\) < 0\)) 340.7441 Tj -0 -351.2543 Td -(4834 panic\("create dots"\);) 139.7925 Tj -0 -360.7477 Td -(4835 }) 34.9481 Tj -0 -370.2411 Td -(4836 ) 21.8426 Tj -0 -379.7344 Td -(4837 if\(dirlink\(dp, name, ip->inum\) < 0\)) 183.4776 Tj -0 -389.2278 Td -(4838 panic\("create: dirlink"\);) 148.5295 Tj -0 -398.7211 Td -(4839 ) 21.8426 Tj -0 -408.2145 Td -(4840 iunlockput\(dp\);) 96.1073 Tj -0 -417.7079 Td -(4841 return ip;) 74.2647 Tj -0 -427.2012 Td -(4842 }) 26.2111 Tj -0 -436.6946 Td -(4843 ) 21.8426 Tj -0 -446.1879 Td -(4844 ) 21.8426 Tj -0 -455.6813 Td -(4845 ) 21.8426 Tj -0 -465.1747 Td -(4846 ) 21.8426 Tj -0 -474.668 Td -(4847 ) 21.8426 Tj -0 -484.1614 Td -(4848 ) 21.8426 Tj -0 -493.6547 Td -(4849 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 48) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sysfile.c Page 7) 174.7406 Tj -0 -28.4801 Td -(4850 int) 34.9481 Tj -0 -37.9735 Td -(4851 sys_open\(void\)) 83.0018 Tj -0 -47.4668 Td -(4852 {) 26.2111 Tj -0 -56.9602 Td -(4853 char *path;) 78.6333 Tj -0 -66.4535 Td -(4854 int fd, omode;) 91.7388 Tj -0 -75.9469 Td -(4855 struct file *f;) 96.1073 Tj -0 -85.4403 Td -(4856 struct inode *ip;) 104.8443 Tj -0 -94.9336 Td -(4857 ) 21.8426 Tj -0 -104.427 Td -(4858 if\(argstr\(0, &path\) < 0 || argint\(1, &omode\) < 0\)) 244.6368 Tj -0 -113.9203 Td -(4859 return -1;) 83.0018 Tj -0 -123.4137 Td -(4860 ) 21.8426 Tj -0 -132.9071 Td -(4861 if\(omode & O_CREATE\){) 122.3184 Tj -0 -142.4004 Td -(4862 if\(\(ip = create\(path, T_FILE, 0, 0\)\) == 0\)) 222.7942 Tj -0 -151.8938 Td -(4863 return -1;) 91.7388 Tj -0 -161.3871 Td -(4864 } else {) 65.5277 Tj -0 -170.8805 Td -(4865 if\(\(ip = namei\(path\)\) == 0\)) 157.2665 Tj -0 -180.3739 Td -(4866 return -1;) 91.7388 Tj -0 -189.8672 Td -(4867 ilock\(ip\);) 83.0018 Tj -0 -199.3606 Td -(4868 if\(ip->type == T_DIR && omode != O_RDONLY\){) 227.1628 Tj -0 -208.8539 Td -(4869 iunlockput\(ip\);) 113.5814 Tj -0 -218.3473 Td -(4870 return -1;) 91.7388 Tj -0 -227.8407 Td -(4871 }) 43.6851 Tj -0 -237.334 Td -(4872 }) 34.9481 Tj -0 -246.8274 Td -(4873 ) 21.8426 Tj -0 -256.3207 Td -(4874 if\(\(f = filealloc\(\)\) == 0 || \(fd = fdalloc\(f\)\) \ -< 0\){) 257.7424 Tj -0 -265.8141 Td -(4875 if\(f\)) 61.1592 Tj -0 -275.3075 Td -(4876 fileclose\(f\);) 104.8443 Tj -0 -284.8008 Td -(4877 iunlockput\(ip\);) 104.8443 Tj -0 -294.2942 Td -(4878 return -1;) 83.0018 Tj -0 -303.7875 Td -(4879 }) 34.9481 Tj -0 -313.2809 Td -(4880 iunlock\(ip\);) 83.0018 Tj -0 -322.7743 Td -(4881 ) 21.8426 Tj -0 -332.2676 Td -(4882 f->type = FD_INODE;) 113.5814 Tj -0 -341.761 Td -(4883 f->ip = ip;) 78.6333 Tj -0 -351.2543 Td -(4884 f->off = 0;) 78.6333 Tj -0 -360.7477 Td -(4885 f->readable = !\(omode & O_WRONLY\);) 179.1091 Tj -0 -370.2411 Td -(4886 f->writable = \(omode & O_WRONLY\) || \(omode & O_RDWR\)\ -;) 262.1109 Tj -0 -379.7344 Td -(4887 ) 21.8426 Tj -0 -389.2278 Td -(4888 return fd;) 74.2647 Tj -0 -398.7211 Td -(4889 }) 26.2111 Tj -0 -408.2145 Td -(4890 ) 21.8426 Tj -0 -417.7079 Td -(4891 ) 21.8426 Tj -0 -427.2012 Td -(4892 ) 21.8426 Tj -0 -436.6946 Td -(4893 ) 21.8426 Tj -0 -446.1879 Td -(4894 ) 21.8426 Tj -0 -455.6813 Td -(4895 ) 21.8426 Tj -0 -465.1747 Td -(4896 ) 21.8426 Tj -0 -474.668 Td -(4897 ) 21.8426 Tj -0 -484.1614 Td -(4898 ) 21.8426 Tj -0 -493.6547 Td -(4899 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 48) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 56 56 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sysfile.c Page 8) 174.7406 Tj -0 -28.4801 Td -(4900 int) 34.9481 Tj -0 -37.9735 Td -(4901 sys_mkdir\(void\)) 87.3703 Tj -0 -47.4668 Td -(4902 {) 26.2111 Tj -0 -56.9602 Td -(4903 char *path;) 78.6333 Tj -0 -66.4535 Td -(4904 struct inode *ip;) 104.8443 Tj -0 -75.9469 Td -(4905 ) 21.8426 Tj -0 -85.4403 Td -(4906 if\(argstr\(0, &path\) < 0 || \(ip = create\(path, T_DIR\ -, 0, 0\)\) == 0\)) 314.533 Tj -0 -94.9336 Td -(4907 return -1;) 83.0018 Tj -0 -104.427 Td -(4908 iunlockput\(ip\);) 96.1073 Tj -0 -113.9203 Td -(4909 return 0;) 69.8962 Tj -0 -123.4137 Td -(4910 }) 26.2111 Tj -0 -132.9071 Td -(4911 ) 21.8426 Tj -0 -142.4004 Td -(4912 int) 34.9481 Tj -0 -151.8938 Td -(4913 sys_mknod\(void\)) 87.3703 Tj -0 -161.3871 Td -(4914 {) 26.2111 Tj -0 -170.8805 Td -(4915 struct inode *ip;) 104.8443 Tj -0 -180.3739 Td -(4916 char *path;) 78.6333 Tj -0 -189.8672 Td -(4917 int len;) 65.5277 Tj -0 -199.3606 Td -(4918 int major, minor;) 104.8443 Tj -0 -208.8539 Td -(4919 ) 21.8426 Tj -0 -218.3473 Td -(4920 if\(\(len=argstr\(0, &path\)\) < 0 ||) 170.3721 Tj -0 -227.8407 Td -(4921 argint\(1, &major\) < 0 ||) 148.5295 Tj -0 -237.334 Td -(4922 argint\(2, &minor\) < 0 ||) 148.5295 Tj -0 -246.8274 Td -(4923 \(ip = create\(path, T_DEV, major, minor\)\) == 0\)) 244.6368 Tj -0 -256.3207 Td -(4924 return -1;) 83.0018 Tj -0 -265.8141 Td -(4925 iunlockput\(ip\);) 96.1073 Tj -0 -275.3075 Td -(4926 return 0;) 69.8962 Tj -0 -284.8008 Td -(4927 }) 26.2111 Tj -0 -294.2942 Td -(4928 ) 21.8426 Tj -0 -303.7875 Td -(4929 int) 34.9481 Tj -0 -313.2809 Td -(4930 sys_chdir\(void\)) 87.3703 Tj -0 -322.7743 Td -(4931 {) 26.2111 Tj -0 -332.2676 Td -(4932 char *path;) 78.6333 Tj -0 -341.761 Td -(4933 struct inode *ip;) 104.8443 Tj -0 -351.2543 Td -(4934 ) 21.8426 Tj -0 -360.7477 Td -(4935 if\(argstr\(0, &path\) < 0 || \(ip = namei\(path\)\) == \ -0\)) 253.3738 Tj -0 -370.2411 Td -(4936 return -1;) 83.0018 Tj -0 -379.7344 Td -(4937 ilock\(ip\);) 74.2647 Tj -0 -389.2278 Td -(4938 if\(ip->type != T_DIR\){) 126.6869 Tj -0 -398.7211 Td -(4939 iunlockput\(ip\);) 104.8443 Tj -0 -408.2145 Td -(4940 return -1;) 83.0018 Tj -0 -417.7079 Td -(4941 }) 34.9481 Tj -0 -427.2012 Td -(4942 iunlock\(ip\);) 83.0018 Tj -0 -436.6946 Td -(4943 iput\(proc->cwd\);) 100.4758 Tj -0 -446.1879 Td -(4944 proc->cwd = ip;) 96.1073 Tj -0 -455.6813 Td -(4945 return 0;) 69.8962 Tj -0 -465.1747 Td -(4946 }) 26.2111 Tj -0 -474.668 Td -(4947 ) 21.8426 Tj -0 -484.1614 Td -(4948 ) 21.8426 Tj -0 -493.6547 Td -(4949 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 49) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sysfile.c Page 9) 174.7406 Tj -0 -28.4801 Td -(4950 int) 34.9481 Tj -0 -37.9735 Td -(4951 sys_exec\(void\)) 83.0018 Tj -0 -47.4668 Td -(4952 {) 26.2111 Tj -0 -56.9602 Td -(4953 char *path, *argv[20];) 126.6869 Tj -0 -66.4535 Td -(4954 int i;) 56.7907 Tj -0 -75.9469 Td -(4955 uint uargv, uarg;) 104.8443 Tj -0 -85.4403 Td -(4956 ) 21.8426 Tj -0 -94.9336 Td -(4957 if\(argstr\(0, &path\) < 0 || argint\(1, \(int*\)&uargv\)\ - < 0\)) 270.8479 Tj -0 -104.427 Td -(4958 return -1;) 83.0018 Tj -0 -113.9203 Td -(4959 memset\(argv, 0, sizeof\(argv\)\);) 161.635 Tj -0 -123.4137 Td -(4960 for\(i=0;; i++\){) 96.1073 Tj -0 -132.9071 Td -(4961 if\(i >= NELEM\(argv\)\)) 126.6869 Tj -0 -142.4004 Td -(4962 return -1;) 91.7388 Tj -0 -151.8938 Td -(4963 if\(fetchint\(proc, uargv+4*i, \(int*\)&uarg\) < 0\)) 240.2683 Tj -0 -161.3871 Td -(4964 return -1;) 91.7388 Tj -0 -170.8805 Td -(4965 if\(uarg == 0\){) 100.4758 Tj -0 -180.3739 Td -(4966 argv[i] = 0;) 100.4758 Tj -0 -189.8672 Td -(4967 break;) 74.2647 Tj -0 -199.3606 Td -(4968 }) 43.6851 Tj -0 -208.8539 Td -(4969 if\(fetchstr\(proc, uarg, &argv[i]\) < 0\)) 205.3202 Tj -0 -218.3473 Td -(4970 return -1;) 91.7388 Tj -0 -227.8407 Td -(4971 }) 34.9481 Tj -0 -237.334 Td -(4972 return exec\(path, argv\);) 135.4239 Tj -0 -246.8274 Td -(4973 }) 26.2111 Tj -0 -256.3207 Td -(4974 ) 21.8426 Tj -0 -265.8141 Td -(4975 int) 34.9481 Tj -0 -275.3075 Td -(4976 sys_pipe\(void\)) 83.0018 Tj -0 -284.8008 Td -(4977 {) 26.2111 Tj -0 -294.2942 Td -(4978 int *fd;) 65.5277 Tj -0 -303.7875 Td -(4979 struct file *rf, *wf;) 122.3184 Tj -0 -313.2809 Td -(4980 int fd0, fd1;) 87.3703 Tj -0 -322.7743 Td -(4981 ) 21.8426 Tj -0 -332.2676 Td -(4982 if\(argptr\(0, \(void*\)&fd, 2*sizeof\(fd[0]\)\) < 0\)) 231.5313 Tj -0 -341.761 Td -(4983 return -1;) 83.0018 Tj -0 -351.2543 Td -(4984 if\(pipealloc\(&rf, &wf\) < 0\)) 148.5295 Tj -0 -360.7477 Td -(4985 return -1;) 83.0018 Tj -0 -370.2411 Td -(4986 fd0 = -1;) 69.8962 Tj -0 -379.7344 Td -(4987 if\(\(fd0 = fdalloc\(rf\)\) < 0 || \(fd1 = fdalloc\(wf\)\ -\) < 0\){) 270.8479 Tj -0 -389.2278 Td -(4988 if\(fd0 >= 0\)) 91.7388 Tj -0 -398.7211 Td -(4989 proc->ofile[fd0] = 0;) 139.7925 Tj -0 -408.2145 Td -(4990 fileclose\(rf\);) 100.4758 Tj -0 -417.7079 Td -(4991 fileclose\(wf\);) 100.4758 Tj -0 -427.2012 Td -(4992 return -1;) 83.0018 Tj -0 -436.6946 Td -(4993 }) 34.9481 Tj -0 -446.1879 Td -(4994 fd[0] = fd0;) 83.0018 Tj -0 -455.6813 Td -(4995 fd[1] = fd1;) 83.0018 Tj -0 -465.1747 Td -(4996 return 0;) 69.8962 Tj -0 -474.668 Td -(4997 }) 26.2111 Tj -0 -484.1614 Td -(4998 ) 21.8426 Tj -0 -493.6547 Td -(4999 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 49) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 57 57 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/exec.c Page 1) 161.635 Tj -0 -28.4801 Td -(5000 #include "types.h") 100.4758 Tj -0 -37.9735 Td -(5001 #include "param.h") 100.4758 Tj -0 -47.4668 Td -(5002 #include "mmu.h") 91.7388 Tj -0 -56.9602 Td -(5003 #include "proc.h") 96.1073 Tj -0 -66.4535 Td -(5004 #include "defs.h") 96.1073 Tj -0 -75.9469 Td -(5005 #include "x86.h") 91.7388 Tj -0 -85.4403 Td -(5006 #include "elf.h") 91.7388 Tj -0 -94.9336 Td -(5007 ) 21.8426 Tj -0 -104.427 Td -(5008 int) 34.9481 Tj -0 -113.9203 Td -(5009 exec\(char *path, char **argv\)) 148.5295 Tj -0 -123.4137 Td -(5010 {) 26.2111 Tj -0 -132.9071 Td -(5011 char *mem, *s, *last;) 122.3184 Tj -0 -142.4004 Td -(5012 int i, argc, arglen, len, off;) 161.635 Tj -0 -151.8938 Td -(5013 uint sz, sp, argp;) 109.2129 Tj -0 -161.3871 Td -(5014 struct elfhdr elf;) 109.2129 Tj -0 -170.8805 Td -(5015 struct inode *ip;) 104.8443 Tj -0 -180.3739 Td -(5016 struct proghdr ph;) 109.2129 Tj -0 -189.8672 Td -(5017 ) 21.8426 Tj -0 -199.3606 Td -(5018 mem = 0;) 65.5277 Tj -0 -208.8539 Td -(5019 sz = 0;) 61.1592 Tj -0 -218.3473 Td -(5020 ) 21.8426 Tj -0 -227.8407 Td -(5021 if\(\(ip = namei\(path\)\) == 0\)) 148.5295 Tj -0 -237.334 Td -(5022 return -1;) 83.0018 Tj -0 -246.8274 Td -(5023 ilock\(ip\);) 74.2647 Tj -0 -256.3207 Td -(5024 ) 21.8426 Tj -0 -265.8141 Td -(5025 // Check ELF header) 113.5814 Tj -0 -275.3075 Td -(5026 if\(readi\(ip, \(char*\)&elf, 0, sizeof\(elf\)\) < sizeo\ -f\(elf\)\)) 275.2164 Tj -0 -284.8008 Td -(5027 goto bad;) 78.6333 Tj -0 -294.2942 Td -(5028 if\(elf.magic != ELF_MAGIC\)) 144.161 Tj -0 -303.7875 Td -(5029 goto bad;) 78.6333 Tj -0 -313.2809 Td -(5030 ) 21.8426 Tj -0 -322.7743 Td -(5031 // Compute memory size of new process.) 196.5831 Tj -0 -332.2676 Td -(5032 // Program segments.) 117.9499 Tj -0 -341.761 Td -(5033 for\(i=0, off=elf.phoff; i sz\)) 270.8479 Tj -0 -218.3473 Td -(5070 goto bad;) 87.3703 Tj -0 -227.8407 Td -(5071 if\(ph.memsz < ph.filesz\)) 144.161 Tj -0 -237.334 Td -(5072 goto bad;) 87.3703 Tj -0 -246.8274 Td -(5073 if\(readi\(ip, mem + ph.va, ph.offset, ph.filesz\) != \ -ph.filesz\)) 305.796 Tj -0 -256.3207 Td -(5074 goto bad;) 87.3703 Tj -0 -265.8141 Td -(5075 memset\(mem + ph.va + ph.filesz, 0, ph.memsz - ph.file\ -sz\);) 288.322 Tj -0 -275.3075 Td -(5076 }) 34.9481 Tj -0 -284.8008 Td -(5077 iunlockput\(ip\);) 96.1073 Tj -0 -294.2942 Td -(5078 ) 21.8426 Tj -0 -303.7875 Td -(5079 // Initialize stack.) 117.9499 Tj -0 -313.2809 Td -(5080 sp = sz;) 65.5277 Tj -0 -322.7743 Td -(5081 argp = sz - arglen - 4*\(argc+1\);) 170.3721 Tj -0 -332.2676 Td -(5082 ) 21.8426 Tj -0 -341.761 Td -(5083 // Copy argv strings and pointers to stack.) 218.4257 Tj -0 -351.2543 Td -(5084 *\(uint*\)\(mem+argp + 4*argc\) = 0; // argv[argc]) 235.8998 Tj -0 -360.7477 Td -(5085 for\(i=argc-1; i>=0; i--\){) 139.7925 Tj -0 -370.2411 Td -(5086 len = strlen\(argv[i]\) + 1;) 152.898 Tj -0 -379.7344 Td -(5087 sp -= len;) 83.0018 Tj -0 -389.2278 Td -(5088 memmove\(mem+sp, argv[i], len\);) 170.3721 Tj -0 -398.7211 Td -(5089 *\(uint*\)\(mem+argp + 4*i\) = sp; // argv[i]) 222.7942 Tj -0 -408.2145 Td -(5090 }) 34.9481 Tj -0 -417.7079 Td -(5091 ) 21.8426 Tj -0 -427.2012 Td -(5092 // Stack frame for main\(argc, argv\), below arguments.) 262.1109 Tj -0 -436.6946 Td -(5093 sp = argp;) 74.2647 Tj -0 -446.1879 Td -(5094 sp -= 4;) 65.5277 Tj -0 -455.6813 Td -(5095 *\(uint*\)\(mem+sp\) = argp;) 135.4239 Tj -0 -465.1747 Td -(5096 sp -= 4;) 65.5277 Tj -0 -474.668 Td -(5097 *\(uint*\)\(mem+sp\) = argc;) 135.4239 Tj -0 -484.1614 Td -(5098 sp -= 4;) 65.5277 Tj -0 -493.6547 Td -(5099 *\(uint*\)\(mem+sp\) = 0xffffffff; // fake return pc) 249.0053 Tj -0 -522.1348 Td -(Sheet 50) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 58 58 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/exec.c Page 3) 161.635 Tj -0 -28.4801 Td -(5100 // Save program name for debugging.) 183.4776 Tj -0 -37.9735 Td -(5101 for\(last=s=path; *s; s++\)) 139.7925 Tj -0 -47.4668 Td -(5102 if\(*s == '/'\)) 96.1073 Tj -0 -56.9602 Td -(5103 last = s+1;) 96.1073 Tj -0 -66.4535 Td -(5104 safestrcpy\(proc->name, last, sizeof\(proc->name\)\);) 244.6368 Tj -0 -75.9469 Td -(5105 ) 21.8426 Tj -0 -85.4403 Td -(5106 // Commit to the new image.) 148.5295 Tj -0 -94.9336 Td -(5107 kfree\(proc->mem, proc->sz\);) 148.5295 Tj -0 -104.427 Td -(5108 proc->mem = mem;) 100.4758 Tj -0 -113.9203 Td -(5109 proc->sz = sz;) 91.7388 Tj -0 -123.4137 Td -(5110 proc->tf->eip = elf.entry; // main) 183.4776 Tj -0 -132.9071 Td -(5111 proc->tf->esp = sp;) 113.5814 Tj -0 -142.4004 Td -(5112 usegment\(\);) 78.6333 Tj -0 -151.8938 Td -(5113 return 0;) 69.8962 Tj -0 -161.3871 Td -(5114 ) 21.8426 Tj -0 -170.8805 Td -(5115 bad:) 43.6851 Tj -0 -180.3739 Td -(5116 if\(mem\)) 61.1592 Tj -0 -189.8672 Td -(5117 kfree\(mem, sz\);) 104.8443 Tj -0 -199.3606 Td -(5118 iunlockput\(ip\);) 96.1073 Tj -0 -208.8539 Td -(5119 return -1;) 74.2647 Tj -0 -218.3473 Td -(5120 }) 26.2111 Tj -0 -227.8407 Td -(5121 ) 21.8426 Tj -0 -237.334 Td -(5122 ) 21.8426 Tj -0 -246.8274 Td -(5123 ) 21.8426 Tj -0 -256.3207 Td -(5124 ) 21.8426 Tj -0 -265.8141 Td -(5125 ) 21.8426 Tj -0 -275.3075 Td -(5126 ) 21.8426 Tj -0 -284.8008 Td -(5127 ) 21.8426 Tj -0 -294.2942 Td -(5128 ) 21.8426 Tj -0 -303.7875 Td -(5129 ) 21.8426 Tj -0 -313.2809 Td -(5130 ) 21.8426 Tj -0 -322.7743 Td -(5131 ) 21.8426 Tj -0 -332.2676 Td -(5132 ) 21.8426 Tj -0 -341.761 Td -(5133 ) 21.8426 Tj -0 -351.2543 Td -(5134 ) 21.8426 Tj -0 -360.7477 Td -(5135 ) 21.8426 Tj -0 -370.2411 Td -(5136 ) 21.8426 Tj -0 -379.7344 Td -(5137 ) 21.8426 Tj -0 -389.2278 Td -(5138 ) 21.8426 Tj -0 -398.7211 Td -(5139 ) 21.8426 Tj -0 -408.2145 Td -(5140 ) 21.8426 Tj -0 -417.7079 Td -(5141 ) 21.8426 Tj -0 -427.2012 Td -(5142 ) 21.8426 Tj -0 -436.6946 Td -(5143 ) 21.8426 Tj -0 -446.1879 Td -(5144 ) 21.8426 Tj -0 -455.6813 Td -(5145 ) 21.8426 Tj -0 -465.1747 Td -(5146 ) 21.8426 Tj -0 -474.668 Td -(5147 ) 21.8426 Tj -0 -484.1614 Td -(5148 ) 21.8426 Tj -0 -493.6547 Td -(5149 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 51) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/pipe.c Page 1) 161.635 Tj -0 -28.4801 Td -(5150 #include "types.h") 100.4758 Tj -0 -37.9735 Td -(5151 #include "defs.h") 96.1073 Tj -0 -47.4668 Td -(5152 #include "param.h") 100.4758 Tj -0 -56.9602 Td -(5153 #include "mmu.h") 91.7388 Tj -0 -66.4535 Td -(5154 #include "proc.h") 96.1073 Tj -0 -75.9469 Td -(5155 #include "fs.h") 87.3703 Tj -0 -85.4403 Td -(5156 #include "file.h") 96.1073 Tj -0 -94.9336 Td -(5157 #include "spinlock.h") 113.5814 Tj -0 -104.427 Td -(5158 ) 21.8426 Tj -0 -113.9203 Td -(5159 #define PIPESIZE 512) 109.2129 Tj -0 -123.4137 Td -(5160 ) 21.8426 Tj -0 -132.9071 Td -(5161 struct pipe {) 78.6333 Tj -0 -142.4004 Td -(5162 struct spinlock lock;) 122.3184 Tj -0 -151.8938 Td -(5163 char data[PIPESIZE];) 117.9499 Tj -0 -161.3871 Td -(5164 uint nread; // number of bytes read) 200.9517 Tj -0 -170.8805 Td -(5165 uint nwrite; // number of bytes written) 214.0572 Tj -0 -180.3739 Td -(5166 int readopen; // read fd is still open) 205.3202 Tj -0 -189.8672 Td -(5167 int writeopen; // write fd is still open) 209.6887 Tj -0 -199.3606 Td -(5168 };) 30.5796 Tj -0 -208.8539 Td -(5169 ) 21.8426 Tj -0 -218.3473 Td -(5170 int) 34.9481 Tj -0 -227.8407 Td -(5171 pipealloc\(struct file **f0, struct file **f1\)) 218.4257 Tj -0 -237.334 Td -(5172 {) 26.2111 Tj -0 -246.8274 Td -(5173 struct pipe *p;) 96.1073 Tj -0 -256.3207 Td -(5174 ) 21.8426 Tj -0 -265.8141 Td -(5175 p = 0;) 56.7907 Tj -0 -275.3075 Td -(5176 *f0 = *f1 = 0;) 91.7388 Tj -0 -284.8008 Td -(5177 if\(\(*f0 = filealloc\(\)\) == 0 || \(*f1 = filealloc\(\)\ -\) == 0\)) 275.2164 Tj -0 -294.2942 Td -(5178 goto bad;) 78.6333 Tj -0 -303.7875 Td -(5179 if\(\(p = \(struct pipe*\)kalloc\(PAGE\)\) == 0\)) 209.6887 Tj -0 -313.2809 Td -(5180 goto bad;) 78.6333 Tj -0 -322.7743 Td -(5181 p->readopen = 1;) 100.4758 Tj -0 -332.2676 Td -(5182 p->writeopen = 1;) 104.8443 Tj -0 -341.761 Td -(5183 p->nwrite = 0;) 91.7388 Tj -0 -351.2543 Td -(5184 p->nread = 0;) 87.3703 Tj -0 -360.7477 Td -(5185 initlock\(&p->lock, "pipe"\);) 148.5295 Tj -0 -370.2411 Td -(5186 \(*f0\)->type = FD_PIPE;) 126.6869 Tj -0 -379.7344 Td -(5187 \(*f0\)->readable = 1;) 117.9499 Tj -0 -389.2278 Td -(5188 \(*f0\)->writable = 0;) 117.9499 Tj -0 -398.7211 Td -(5189 \(*f0\)->pipe = p;) 100.4758 Tj -0 -408.2145 Td -(5190 \(*f1\)->type = FD_PIPE;) 126.6869 Tj -0 -417.7079 Td -(5191 \(*f1\)->readable = 0;) 117.9499 Tj -0 -427.2012 Td -(5192 \(*f1\)->writable = 1;) 117.9499 Tj -0 -436.6946 Td -(5193 \(*f1\)->pipe = p;) 100.4758 Tj -0 -446.1879 Td -(5194 return 0;) 69.8962 Tj -0 -455.6813 Td -(5195 ) 21.8426 Tj -0 -465.1747 Td -(5196 ) 21.8426 Tj -0 -474.668 Td -(5197 ) 21.8426 Tj -0 -484.1614 Td -(5198 ) 21.8426 Tj -0 -493.6547 Td -(5199 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 51) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 59 59 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/pipe.c Page 2) 161.635 Tj -0 -28.4801 Td -(5200 bad:) 43.6851 Tj -0 -37.9735 Td -(5201 if\(p\)) 52.4222 Tj -0 -47.4668 Td -(5202 kfree\(\(char*\)p, PAGE\);) 135.4239 Tj -0 -56.9602 Td -(5203 if\(*f0\)) 61.1592 Tj -0 -66.4535 Td -(5204 fileclose\(*f0\);) 104.8443 Tj -0 -75.9469 Td -(5205 if\(*f1\)) 61.1592 Tj -0 -85.4403 Td -(5206 fileclose\(*f1\);) 104.8443 Tj -0 -94.9336 Td -(5207 return -1;) 74.2647 Tj -0 -104.427 Td -(5208 }) 26.2111 Tj -0 -113.9203 Td -(5209 ) 21.8426 Tj -0 -123.4137 Td -(5210 void) 39.3166 Tj -0 -132.9071 Td -(5211 pipeclose\(struct pipe *p, int writable\)) 192.2146 Tj -0 -142.4004 Td -(5212 {) 26.2111 Tj -0 -151.8938 Td -(5213 acquire\(&p->lock\);) 109.2129 Tj -0 -161.3871 Td -(5214 if\(writable\){) 87.3703 Tj -0 -170.8805 Td -(5215 p->writeopen = 0;) 113.5814 Tj -0 -180.3739 Td -(5216 wakeup\(&p->nread\);) 117.9499 Tj -0 -189.8672 Td -(5217 } else {) 65.5277 Tj -0 -199.3606 Td -(5218 p->readopen = 0;) 109.2129 Tj -0 -208.8539 Td -(5219 wakeup\(&p->nwrite\);) 122.3184 Tj -0 -218.3473 Td -(5220 }) 34.9481 Tj -0 -227.8407 Td -(5221 if\(p->readopen == 0 && p->writeopen == 0\) {) 218.4257 Tj -0 -237.334 Td -(5222 release\(&p->lock\);) 117.9499 Tj -0 -246.8274 Td -(5223 kfree\(\(char*\)p, PAGE\);) 135.4239 Tj -0 -256.3207 Td -(5224 } else) 56.7907 Tj -0 -265.8141 Td -(5225 release\(&p->lock\);) 117.9499 Tj -0 -275.3075 Td -(5226 }) 26.2111 Tj -0 -284.8008 Td -(5227 ) 21.8426 Tj -0 -294.2942 Td -(5228 ) 21.8426 Tj -0 -303.7875 Td -(5229 int) 34.9481 Tj -0 -313.2809 Td -(5230 pipewrite\(struct pipe *p, char *addr, int n\)) 214.0572 Tj -0 -322.7743 Td -(5231 {) 26.2111 Tj -0 -332.2676 Td -(5232 int i;) 56.7907 Tj -0 -341.761 Td -(5233 ) 21.8426 Tj -0 -351.2543 Td -(5234 acquire\(&p->lock\);) 109.2129 Tj -0 -360.7477 Td -(5235 for\(i = 0; i < n; i++\){) 131.0554 Tj -0 -370.2411 Td -(5236 while\(p->nwrite == p->nread + PIPESIZE\) { ) 227.1628 Tj -0 -379.7344 Td -(5237 if\(p->readopen == 0 || proc->killed\){) 209.6887 Tj -0 -389.2278 Td -(5238 release\(&p->lock\);) 135.4239 Tj -0 -398.7211 Td -(5239 return -1;) 100.4758 Tj -0 -408.2145 Td -(5240 }) 52.4222 Tj -0 -417.7079 Td -(5241 wakeup\(&p->nread\);) 126.6869 Tj -0 -427.2012 Td -(5242 sleep\(&p->nwrite, &p->lock\); ) 179.1091 Tj -0 -436.6946 Td -(5243 }) 43.6851 Tj -0 -446.1879 Td -(5244 p->data[p->nwrite++ % PIPESIZE] = addr[i];) 222.7942 Tj -0 -455.6813 Td -(5245 }) 34.9481 Tj -0 -465.1747 Td -(5246 wakeup\(&p->nread\); ) 117.9499 Tj -0 -474.668 Td -(5247 release\(&p->lock\);) 109.2129 Tj -0 -484.1614 Td -(5248 return n;) 69.8962 Tj -0 -493.6547 Td -(5249 }) 26.2111 Tj -0 -522.1348 Td -(Sheet 52) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/pipe.c Page 3) 161.635 Tj -0 -28.4801 Td -(5250 int) 34.9481 Tj -0 -37.9735 Td -(5251 piperead\(struct pipe *p, char *addr, int n\)) 209.6887 Tj -0 -47.4668 Td -(5252 {) 26.2111 Tj -0 -56.9602 Td -(5253 int i;) 56.7907 Tj -0 -66.4535 Td -(5254 ) 21.8426 Tj -0 -75.9469 Td -(5255 acquire\(&p->lock\);) 109.2129 Tj -0 -85.4403 Td -(5256 while\(p->nread == p->nwrite && p->writeopen\){ ) 235.8998 Tj -0 -94.9336 Td -(5257 if\(proc->killed\){) 113.5814 Tj -0 -104.427 Td -(5258 release\(&p->lock\);) 126.6869 Tj -0 -113.9203 Td -(5259 return -1;) 91.7388 Tj -0 -123.4137 Td -(5260 }) 43.6851 Tj -0 -132.9071 Td -(5261 sleep\(&p->nread, &p->lock\); ) 161.635 Tj -0 -142.4004 Td -(5262 }) 34.9481 Tj -0 -151.8938 Td -(5263 for\(i = 0; i < n; i++\){ ) 139.7925 Tj -0 -161.3871 Td -(5264 if\(p->nread == p->nwrite\)) 148.5295 Tj -0 -170.8805 Td -(5265 break;) 74.2647 Tj -0 -180.3739 Td -(5266 addr[i] = p->data[p->nread++ % PIPESIZE];) 218.4257 Tj -0 -189.8672 Td -(5267 }) 34.9481 Tj -0 -199.3606 Td -(5268 wakeup\(&p->nwrite\); ) 122.3184 Tj -0 -208.8539 Td -(5269 release\(&p->lock\);) 109.2129 Tj -0 -218.3473 Td -(5270 return i;) 69.8962 Tj -0 -227.8407 Td -(5271 }) 26.2111 Tj -0 -237.334 Td -(5272 ) 21.8426 Tj -0 -246.8274 Td -(5273 ) 21.8426 Tj -0 -256.3207 Td -(5274 ) 21.8426 Tj -0 -265.8141 Td -(5275 ) 21.8426 Tj -0 -275.3075 Td -(5276 ) 21.8426 Tj -0 -284.8008 Td -(5277 ) 21.8426 Tj -0 -294.2942 Td -(5278 ) 21.8426 Tj -0 -303.7875 Td -(5279 ) 21.8426 Tj -0 -313.2809 Td -(5280 ) 21.8426 Tj -0 -322.7743 Td -(5281 ) 21.8426 Tj -0 -332.2676 Td -(5282 ) 21.8426 Tj -0 -341.761 Td -(5283 ) 21.8426 Tj -0 -351.2543 Td -(5284 ) 21.8426 Tj -0 -360.7477 Td -(5285 ) 21.8426 Tj -0 -370.2411 Td -(5286 ) 21.8426 Tj -0 -379.7344 Td -(5287 ) 21.8426 Tj -0 -389.2278 Td -(5288 ) 21.8426 Tj -0 -398.7211 Td -(5289 ) 21.8426 Tj -0 -408.2145 Td -(5290 ) 21.8426 Tj -0 -417.7079 Td -(5291 ) 21.8426 Tj -0 -427.2012 Td -(5292 ) 21.8426 Tj -0 -436.6946 Td -(5293 ) 21.8426 Tj -0 -446.1879 Td -(5294 ) 21.8426 Tj -0 -455.6813 Td -(5295 ) 21.8426 Tj -0 -465.1747 Td -(5296 ) 21.8426 Tj -0 -474.668 Td -(5297 ) 21.8426 Tj -0 -484.1614 Td -(5298 ) 21.8426 Tj -0 -493.6547 Td -(5299 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 52) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 60 60 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/string.c Page 1) 170.3721 Tj -0 -28.4801 Td -(5300 #include "types.h") 100.4758 Tj -0 -37.9735 Td -(5301 #include "x86.h") 91.7388 Tj -0 -47.4668 Td -(5302 ) 21.8426 Tj -0 -56.9602 Td -(5303 void*) 43.6851 Tj -0 -66.4535 Td -(5304 memset\(void *dst, int c, uint n\)) 161.635 Tj -0 -75.9469 Td -(5305 {) 26.2111 Tj -0 -85.4403 Td -(5306 stosb\(dst, c, n\);) 104.8443 Tj -0 -94.9336 Td -(5307 return dst;) 78.6333 Tj -0 -104.427 Td -(5308 }) 26.2111 Tj -0 -113.9203 Td -(5309 ) 21.8426 Tj -0 -123.4137 Td -(5310 int) 34.9481 Tj -0 -132.9071 Td -(5311 memcmp\(const void *v1, const void *v2, uint n\)) 222.7942 Tj -0 -142.4004 Td -(5312 {) 26.2111 Tj -0 -151.8938 Td -(5313 const uchar *s1, *s2;) 122.3184 Tj -0 -161.3871 Td -(5314 ) 21.8426 Tj -0 -170.8805 Td -(5315 s1 = v1;) 65.5277 Tj -0 -180.3739 Td -(5316 s2 = v2;) 65.5277 Tj -0 -189.8672 Td -(5317 while\(n-- > 0\){) 96.1073 Tj -0 -199.3606 Td -(5318 if\(*s1 != *s2\)) 100.4758 Tj -0 -208.8539 Td -(5319 return *s1 - *s2;) 122.3184 Tj -0 -218.3473 Td -(5320 s1++, s2++;) 87.3703 Tj -0 -227.8407 Td -(5321 }) 34.9481 Tj -0 -237.334 Td -(5322 ) 21.8426 Tj -0 -246.8274 Td -(5323 return 0;) 69.8962 Tj -0 -256.3207 Td -(5324 }) 26.2111 Tj -0 -265.8141 Td -(5325 ) 21.8426 Tj -0 -275.3075 Td -(5326 void*) 43.6851 Tj -0 -284.8008 Td -(5327 memmove\(void *dst, const void *src, uint n\)) 209.6887 Tj -0 -294.2942 Td -(5328 {) 26.2111 Tj -0 -303.7875 Td -(5329 const char *s;) 91.7388 Tj -0 -313.2809 Td -(5330 char *d;) 65.5277 Tj -0 -322.7743 Td -(5331 ) 21.8426 Tj -0 -332.2676 Td -(5332 s = src;) 65.5277 Tj -0 -341.761 Td -(5333 d = dst;) 65.5277 Tj -0 -351.2543 Td -(5334 if\(s < d && s + n > d\){) 131.0554 Tj -0 -360.7477 Td -(5335 s += n;) 69.8962 Tj -0 -370.2411 Td -(5336 d += n;) 69.8962 Tj -0 -379.7344 Td -(5337 while\(n-- > 0\)) 100.4758 Tj -0 -389.2278 Td -(5338 *--d = *--s;) 100.4758 Tj -0 -398.7211 Td -(5339 } else) 56.7907 Tj -0 -408.2145 Td -(5340 while\(n-- > 0\)) 100.4758 Tj -0 -417.7079 Td -(5341 *d++ = *s++;) 100.4758 Tj -0 -427.2012 Td -(5342 ) 21.8426 Tj -0 -436.6946 Td -(5343 return dst;) 78.6333 Tj -0 -446.1879 Td -(5344 }) 26.2111 Tj -0 -455.6813 Td -(5345 ) 21.8426 Tj -0 -465.1747 Td -(5346 ) 21.8426 Tj -0 -474.668 Td -(5347 ) 21.8426 Tj -0 -484.1614 Td -(5348 ) 21.8426 Tj -0 -493.6547 Td -(5349 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 53) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/string.c Page 2) 170.3721 Tj -0 -28.4801 Td -(5350 int) 34.9481 Tj -0 -37.9735 Td -(5351 strncmp\(const char *p, const char *q, uint n\)) 218.4257 Tj -0 -47.4668 Td -(5352 {) 26.2111 Tj -0 -56.9602 Td -(5353 while\(n > 0 && *p && *p == *q\)) 161.635 Tj -0 -66.4535 Td -(5354 n--, p++, q++;) 100.4758 Tj -0 -75.9469 Td -(5355 if\(n == 0\)) 74.2647 Tj -0 -85.4403 Td -(5356 return 0;) 78.6333 Tj -0 -94.9336 Td -(5357 return \(uchar\)*p - \(uchar\)*q;) 157.2665 Tj -0 -104.427 Td -(5358 }) 26.2111 Tj -0 -113.9203 Td -(5359 ) 21.8426 Tj -0 -123.4137 Td -(5360 char*) 43.6851 Tj -0 -132.9071 Td -(5361 strncpy\(char *s, const char *t, int n\)) 187.8461 Tj -0 -142.4004 Td -(5362 {) 26.2111 Tj -0 -151.8938 Td -(5363 char *os;) 69.8962 Tj -0 -161.3871 Td -(5364 ) 21.8426 Tj -0 -170.8805 Td -(5365 os = s;) 61.1592 Tj -0 -180.3739 Td -(5366 while\(n-- > 0 && \(*s++ = *t++\) != 0\)) 187.8461 Tj -0 -189.8672 Td -(5367 ;) 43.6851 Tj -0 -199.3606 Td -(5368 while\(n-- > 0\)) 91.7388 Tj -0 -208.8539 Td -(5369 *s++ = 0;) 78.6333 Tj -0 -218.3473 Td -(5370 return os;) 74.2647 Tj -0 -227.8407 Td -(5371 }) 26.2111 Tj -0 -237.334 Td -(5372 ) 21.8426 Tj -0 -246.8274 Td -(5373 // Like strncpy but guaranteed to NUL-terminate.) 231.5313 Tj -0 -256.3207 Td -(5374 char*) 43.6851 Tj -0 -265.8141 Td -(5375 safestrcpy\(char *s, const char *t, int n\)) 200.9517 Tj -0 -275.3075 Td -(5376 {) 26.2111 Tj -0 -284.8008 Td -(5377 char *os;) 69.8962 Tj -0 -294.2942 Td -(5378 ) 21.8426 Tj -0 -303.7875 Td -(5379 os = s;) 61.1592 Tj -0 -313.2809 Td -(5380 if\(n <= 0\)) 74.2647 Tj -0 -322.7743 Td -(5381 return os;) 83.0018 Tj -0 -332.2676 Td -(5382 while\(--n > 0 && \(*s++ = *t++\) != 0\)) 187.8461 Tj -0 -341.761 Td -(5383 ;) 43.6851 Tj -0 -351.2543 Td -(5384 *s = 0;) 61.1592 Tj -0 -360.7477 Td -(5385 return os;) 74.2647 Tj -0 -370.2411 Td -(5386 }) 26.2111 Tj -0 -379.7344 Td -(5387 ) 21.8426 Tj -0 -389.2278 Td -(5388 int) 34.9481 Tj -0 -398.7211 Td -(5389 strlen\(const char *s\)) 113.5814 Tj -0 -408.2145 Td -(5390 {) 26.2111 Tj -0 -417.7079 Td -(5391 int n;) 56.7907 Tj -0 -427.2012 Td -(5392 ) 21.8426 Tj -0 -436.6946 Td -(5393 for\(n = 0; s[n]; n++\)) 122.3184 Tj -0 -446.1879 Td -(5394 ;) 43.6851 Tj -0 -455.6813 Td -(5395 return n;) 69.8962 Tj -0 -465.1747 Td -(5396 }) 26.2111 Tj -0 -474.668 Td -(5397 ) 21.8426 Tj -0 -484.1614 Td -(5398 ) 21.8426 Tj -0 -493.6547 Td -(5399 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 53) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 61 61 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/mp.h Page 1) 152.898 Tj -0 -28.4801 Td -(5400 // See MultiProcessor Specification Version 1.[14]) 240.2683 Tj -0 -37.9735 Td -(5401 ) 21.8426 Tj -0 -47.4668 Td -(5402 struct mp { // floating pointer) 209.6887 Tj -0 -56.9602 Td -(5403 uchar signature[4]; // "_MP_") 200.9517 Tj -0 -66.4535 Td -(5404 void *physaddr; // phys addr of MP config \ -table) 297.059 Tj -0 -75.9469 Td -(5405 uchar length; // 1) 179.1091 Tj -0 -85.4403 Td -(5406 uchar specrev; // [14]) 192.2146 Tj -0 -94.9336 Td -(5407 uchar checksum; // all bytes must add up t\ -o 0) 288.322 Tj -0 -104.427 Td -(5408 uchar type; // MP system config type) 266.4794 Tj -0 -113.9203 Td -(5409 uchar imcrp;) 83.0018 Tj -0 -123.4137 Td -(5410 uchar reserved[3];) 109.2129 Tj -0 -132.9071 Td -(5411 };) 30.5796 Tj -0 -142.4004 Td -(5412 ) 21.8426 Tj -0 -151.8938 Td -(5413 struct mpconf { // configuration table header) 253.3738 Tj -0 -161.3871 Td -(5414 uchar signature[4]; // "PCMP") 200.9517 Tj -0 -170.8805 Td -(5415 ushort length; // total table length) 253.3738 Tj -0 -180.3739 Td -(5416 uchar version; // [14]) 192.2146 Tj -0 -189.8672 Td -(5417 uchar checksum; // all bytes must add up t\ -o 0) 288.322 Tj -0 -199.3606 Td -(5418 uchar product[20]; // product id) 218.4257 Tj -0 -208.8539 Td -(5419 uint *oemtable; // OEM table pointer) 249.0053 Tj -0 -218.3473 Td -(5420 ushort oemlength; // OEM table length) 244.6368 Tj -0 -227.8407 Td -(5421 ushort entry; // entry count) 222.7942 Tj -0 -237.334 Td -(5422 uint *lapicaddr; // address of local APIC) 266.4794 Tj -0 -246.8274 Td -(5423 ushort xlength; // extended table length) 266.4794 Tj -0 -256.3207 Td -(5424 uchar xchecksum; // extended table checksum) 275.2164 Tj -0 -265.8141 Td -(5425 uchar reserved;) 96.1073 Tj -0 -275.3075 Td -(5426 };) 30.5796 Tj -0 -284.8008 Td -(5427 ) 21.8426 Tj -0 -294.2942 Td -(5428 struct mpproc { // processor table entry) 231.5313 Tj -0 -303.7875 Td -(5429 uchar type; // entry type \(0\)) 235.8998 Tj -0 -313.2809 Td -(5430 uchar apicid; // local APIC id) 231.5313 Tj -0 -322.7743 Td -(5431 uchar version; // local APIC verison) 253.3738 Tj -0 -332.2676 Td -(5432 uchar flags; // CPU flags) 214.0572 Tj -0 -341.761 Td -(5433 #define MPBOOT 0x02 // This proc is the boot\ -strap processor.) 345.1126 Tj -0 -351.2543 Td -(5434 uchar signature[4]; // CPU signature) 231.5313 Tj -0 -360.7477 Td -(5435 uint feature; // feature flags from CPUI\ -D instruction) 332.0071 Tj -0 -370.2411 Td -(5436 uchar reserved[8];) 109.2129 Tj -0 -379.7344 Td -(5437 };) 30.5796 Tj -0 -389.2278 Td -(5438 ) 21.8426 Tj -0 -398.7211 Td -(5439 struct mpioapic { // I/O APIC table entry) 227.1628 Tj -0 -408.2145 Td -(5440 uchar type; // entry type \(2\)) 235.8998 Tj -0 -417.7079 Td -(5441 uchar apicno; // I/O APIC id) 222.7942 Tj -0 -427.2012 Td -(5442 uchar version; // I/O APIC version) 244.6368 Tj -0 -436.6946 Td -(5443 uchar flags; // I/O APIC flags) 235.8998 Tj -0 -446.1879 Td -(5444 uint *addr; // I/O APIC address) 240.2683 Tj -0 -455.6813 Td -(5445 };) 30.5796 Tj -0 -465.1747 Td -(5446 ) 21.8426 Tj -0 -474.668 Td -(5447 ) 21.8426 Tj -0 -484.1614 Td -(5448 ) 21.8426 Tj -0 -493.6547 Td -(5449 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 54) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/mp.h Page 2) 152.898 Tj -0 -28.4801 Td -(5450 // Table entry types) 109.2129 Tj -0 -37.9735 Td -(5451 #define MPPROC 0x00 // One per processor) 214.0572 Tj -0 -47.4668 Td -(5452 #define MPBUS 0x01 // One per bus) 187.8461 Tj -0 -56.9602 Td -(5453 #define MPIOAPIC 0x02 // One per I/O APIC) 209.6887 Tj -0 -66.4535 Td -(5454 #define MPIOINTR 0x03 // One per bus interrupt source) 262.1109 Tj -0 -75.9469 Td -(5455 #define MPLINTR 0x04 // One per system interrupt source) 275.2164 Tj -0 -85.4403 Td -(5456 ) 21.8426 Tj -0 -94.9336 Td -(5457 ) 21.8426 Tj -0 -104.427 Td -(5458 ) 21.8426 Tj -0 -113.9203 Td -(5459 ) 21.8426 Tj -0 -123.4137 Td -(5460 ) 21.8426 Tj -0 -132.9071 Td -(5461 ) 21.8426 Tj -0 -142.4004 Td -(5462 ) 21.8426 Tj -0 -151.8938 Td -(5463 ) 21.8426 Tj -0 -161.3871 Td -(5464 ) 21.8426 Tj -0 -170.8805 Td -(5465 ) 21.8426 Tj -0 -180.3739 Td -(5466 ) 21.8426 Tj -0 -189.8672 Td -(5467 ) 21.8426 Tj -0 -199.3606 Td -(5468 ) 21.8426 Tj -0 -208.8539 Td -(5469 ) 21.8426 Tj -0 -218.3473 Td -(5470 ) 21.8426 Tj -0 -227.8407 Td -(5471 ) 21.8426 Tj -0 -237.334 Td -(5472 ) 21.8426 Tj -0 -246.8274 Td -(5473 ) 21.8426 Tj -0 -256.3207 Td -(5474 ) 21.8426 Tj -0 -265.8141 Td -(5475 ) 21.8426 Tj -0 -275.3075 Td -(5476 ) 21.8426 Tj -0 -284.8008 Td -(5477 ) 21.8426 Tj -0 -294.2942 Td -(5478 ) 21.8426 Tj -0 -303.7875 Td -(5479 ) 21.8426 Tj -0 -313.2809 Td -(5480 ) 21.8426 Tj -0 -322.7743 Td -(5481 ) 21.8426 Tj -0 -332.2676 Td -(5482 ) 21.8426 Tj -0 -341.761 Td -(5483 ) 21.8426 Tj -0 -351.2543 Td -(5484 ) 21.8426 Tj -0 -360.7477 Td -(5485 ) 21.8426 Tj -0 -370.2411 Td -(5486 ) 21.8426 Tj -0 -379.7344 Td -(5487 ) 21.8426 Tj -0 -389.2278 Td -(5488 ) 21.8426 Tj -0 -398.7211 Td -(5489 ) 21.8426 Tj -0 -408.2145 Td -(5490 ) 21.8426 Tj -0 -417.7079 Td -(5491 ) 21.8426 Tj -0 -427.2012 Td -(5492 ) 21.8426 Tj -0 -436.6946 Td -(5493 ) 21.8426 Tj -0 -446.1879 Td -(5494 ) 21.8426 Tj -0 -455.6813 Td -(5495 ) 21.8426 Tj -0 -465.1747 Td -(5496 ) 21.8426 Tj -0 -474.668 Td -(5497 ) 21.8426 Tj -0 -484.1614 Td -(5498 ) 21.8426 Tj -0 -493.6547 Td -(5499 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 54) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 62 62 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/mp.c Page 1) 152.898 Tj -0 -28.4801 Td -(5500 // Multiprocessor bootstrap.) 144.161 Tj -0 -37.9735 Td -(5501 // Search memory for MP description structures.) 227.1628 Tj -0 -47.4668 Td -(5502 // http://developer.intel.com/design/pentium/datashts/2420\ -1606.pdf) 310.1645 Tj -0 -56.9602 Td -(5503 ) 21.8426 Tj -0 -66.4535 Td -(5504 #include "types.h") 100.4758 Tj -0 -75.9469 Td -(5505 #include "defs.h") 96.1073 Tj -0 -85.4403 Td -(5506 #include "param.h") 100.4758 Tj -0 -94.9336 Td -(5507 #include "mp.h") 87.3703 Tj -0 -104.427 Td -(5508 #include "x86.h") 91.7388 Tj -0 -113.9203 Td -(5509 #include "mmu.h") 91.7388 Tj -0 -123.4137 Td -(5510 #include "proc.h") 96.1073 Tj -0 -132.9071 Td -(5511 ) 21.8426 Tj -0 -142.4004 Td -(5512 struct cpu cpus[NCPU];) 117.9499 Tj -0 -151.8938 Td -(5513 static struct cpu *bcpu;) 126.6869 Tj -0 -161.3871 Td -(5514 int ismp;) 61.1592 Tj -0 -170.8805 Td -(5515 int ncpu;) 61.1592 Tj -0 -180.3739 Td -(5516 uchar ioapicid;) 87.3703 Tj -0 -189.8672 Td -(5517 ) 21.8426 Tj -0 -199.3606 Td -(5518 int) 34.9481 Tj -0 -208.8539 Td -(5519 mpbcpu\(void\)) 74.2647 Tj -0 -218.3473 Td -(5520 {) 26.2111 Tj -0 -227.8407 Td -(5521 return bcpu-cpus;) 104.8443 Tj -0 -237.334 Td -(5522 }) 26.2111 Tj -0 -246.8274 Td -(5523 ) 21.8426 Tj -0 -256.3207 Td -(5524 static uchar) 74.2647 Tj -0 -265.8141 Td -(5525 sum\(uchar *addr, int len\)) 131.0554 Tj -0 -275.3075 Td -(5526 {) 26.2111 Tj -0 -284.8008 Td -(5527 int i, sum;) 78.6333 Tj -0 -294.2942 Td -(5528 ) 21.8426 Tj -0 -303.7875 Td -(5529 sum = 0;) 65.5277 Tj -0 -313.2809 Td -(5530 for\(i=0; iphysaddr == 0\)) 235.8998 Tj -0 -370.2411 Td -(5586 return 0;) 78.6333 Tj -0 -379.7344 Td -(5587 conf = \(struct mpconf*\)mp->physaddr;) 187.8461 Tj -0 -389.2278 Td -(5588 if\(memcmp\(conf, "PCMP", 4\) != 0\)) 170.3721 Tj -0 -398.7211 Td -(5589 return 0;) 78.6333 Tj -0 -408.2145 Td -(5590 if\(conf->version != 1 && conf->version != 4\)) 222.7942 Tj -0 -417.7079 Td -(5591 return 0;) 78.6333 Tj -0 -427.2012 Td -(5592 if\(sum\(\(uchar*\)conf, conf->length\) != 0\)) 205.3202 Tj -0 -436.6946 Td -(5593 return 0;) 78.6333 Tj -0 -446.1879 Td -(5594 *pmp = mp;) 74.2647 Tj -0 -455.6813 Td -(5595 return conf;) 83.0018 Tj -0 -465.1747 Td -(5596 }) 26.2111 Tj -0 -474.668 Td -(5597 ) 21.8426 Tj -0 -484.1614 Td -(5598 ) 21.8426 Tj -0 -493.6547 Td -(5599 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 55) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 63 63 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/mp.c Page 3) 152.898 Tj -0 -28.4801 Td -(5600 void) 39.3166 Tj -0 -37.9735 Td -(5601 mpinit\(void\)) 74.2647 Tj -0 -47.4668 Td -(5602 {) 26.2111 Tj -0 -56.9602 Td -(5603 uchar *p, *e;) 87.3703 Tj -0 -66.4535 Td -(5604 struct mp *mp;) 91.7388 Tj -0 -75.9469 Td -(5605 struct mpconf *conf;) 117.9499 Tj -0 -85.4403 Td -(5606 struct mpproc *proc;) 117.9499 Tj -0 -94.9336 Td -(5607 struct mpioapic *ioapic;) 135.4239 Tj -0 -104.427 Td -(5608 ) 21.8426 Tj -0 -113.9203 Td -(5609 bcpu = &cpus[0];) 100.4758 Tj -0 -123.4137 Td -(5610 if\(\(conf = mpconfig\(&mp\)\) == 0\)) 166.0035 Tj -0 -132.9071 Td -(5611 return;) 69.8962 Tj -0 -142.4004 Td -(5612 ismp = 1;) 69.8962 Tj -0 -151.8938 Td -(5613 lapic = \(uint*\)conf->lapicaddr;) 166.0035 Tj -0 -161.3871 Td -(5614 for\(p=\(uchar*\)\(conf+1\), e=\(uchar*\)conf+conf->leng\ -th; papicid\) {) 161.635 Tj -0 -208.8539 Td -(5619 cprintf\("mpinit: ncpu=%d apicpid=%d", ncpu, proc-\ ->apicid\);) 310.1645 Tj -0 -218.3473 Td -(5620 panic\("mpinit"\);) 126.6869 Tj -0 -227.8407 Td -(5621 }) 52.4222 Tj -0 -237.334 Td -(5622 if\(proc->flags & MPBOOT\)) 152.898 Tj -0 -246.8274 Td -(5623 bcpu = &cpus[ncpu];) 139.7925 Tj -0 -256.3207 Td -(5624 cpus[ncpu].id = ncpu;) 139.7925 Tj -0 -265.8141 Td -(5625 ncpu++;) 78.6333 Tj -0 -275.3075 Td -(5626 p += sizeof\(struct mpproc\);) 166.0035 Tj -0 -284.8008 Td -(5627 continue;) 87.3703 Tj -0 -294.2942 Td -(5628 case MPIOAPIC:) 100.4758 Tj -0 -303.7875 Td -(5629 ioapic = \(struct mpioapic*\)p;) 174.7406 Tj -0 -313.2809 Td -(5630 ioapicid = ioapic->apicno;) 161.635 Tj -0 -322.7743 Td -(5631 p += sizeof\(struct mpioapic\);) 174.7406 Tj -0 -332.2676 Td -(5632 continue;) 87.3703 Tj -0 -341.761 Td -(5633 case MPBUS:) 87.3703 Tj -0 -351.2543 Td -(5634 case MPIOINTR:) 100.4758 Tj -0 -360.7477 Td -(5635 case MPLINTR:) 96.1073 Tj -0 -370.2411 Td -(5636 p += 8;) 78.6333 Tj -0 -379.7344 Td -(5637 continue;) 87.3703 Tj -0 -389.2278 Td -(5638 default:) 74.2647 Tj -0 -398.7211 Td -(5639 cprintf\("mpinit: unknown config type %x\\n", *p\);) 257.7424 Tj -0 -408.2145 Td -(5640 panic\("mpinit"\);) 117.9499 Tj -0 -417.7079 Td -(5641 }) 43.6851 Tj -0 -427.2012 Td -(5642 }) 34.9481 Tj -0 -436.6946 Td -(5643 if\(mp->imcrp\){) 91.7388 Tj -0 -446.1879 Td -(5644 // Bochs doesn't support IMCR, so this doesn't run on \ -Bochs.) 301.4275 Tj -0 -455.6813 Td -(5645 // But it would on real hardware.) 183.4776 Tj -0 -465.1747 Td -(5646 outb\(0x22, 0x70\); // Select IMCR) 187.8461 Tj -0 -474.668 Td -(5647 outb\(0x23, inb\(0x23\) | 1\); // Mask external inter\ -rupts.) 283.9534 Tj -0 -484.1614 Td -(5648 }) 34.9481 Tj -0 -493.6547 Td -(5649 }) 26.2111 Tj -0 -522.1348 Td -(Sheet 56) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/lapic.c Page 1) 166.0035 Tj -0 -28.4801 Td -(5650 // The local APIC manages internal \(non-I/O\) interrupts.) 266.4794 Tj -0 -37.9735 Td -(5651 // See Chapter 8 & Appendix C of Intel processor manual vo\ -lume 3.) 305.796 Tj -0 -47.4668 Td -(5652 ) 21.8426 Tj -0 -56.9602 Td -(5653 #include "types.h") 100.4758 Tj -0 -66.4535 Td -(5654 #include "defs.h") 96.1073 Tj -0 -75.9469 Td -(5655 #include "traps.h") 100.4758 Tj -0 -85.4403 Td -(5656 #include "mmu.h") 91.7388 Tj -0 -94.9336 Td -(5657 #include "x86.h") 91.7388 Tj -0 -104.427 Td -(5658 ) 21.8426 Tj -0 -113.9203 Td -(5659 // Local APIC registers, divided by 4 for use as uint[] in\ -dices.) 301.4275 Tj -0 -123.4137 Td -(5660 #define ID \(0x0020/4\) // ID) 170.3721 Tj -0 -132.9071 Td -(5661 #define VER \(0x0030/4\) // Version) 192.2146 Tj -0 -142.4004 Td -(5662 #define TPR \(0x0080/4\) // Task Priority) 218.4257 Tj -0 -151.8938 Td -(5663 #define EOI \(0x00B0/4\) // EOI) 174.7406 Tj -0 -161.3871 Td -(5664 #define SVR \(0x00F0/4\) // Spurious Interrupt Vecto\ -r) 270.8479 Tj -0 -170.8805 Td -(5665 #define ENABLE 0x00000100 // Unit Enable) 231.5313 Tj -0 -180.3739 Td -(5666 #define ESR \(0x0280/4\) // Error Status) 214.0572 Tj -0 -189.8672 Td -(5667 #define ICRLO \(0x0300/4\) // Interrupt Command) 235.8998 Tj -0 -199.3606 Td -(5668 #define INIT 0x00000500 // INIT/RESET) 227.1628 Tj -0 -208.8539 Td -(5669 #define STARTUP 0x00000600 // Startup IPI) 231.5313 Tj -0 -218.3473 Td -(5670 #define DELIVS 0x00001000 // Delivery status) 249.0053 Tj -0 -227.8407 Td -(5671 #define ASSERT 0x00004000 // Assert interrupt \(vs\ - deassert\)) 314.533 Tj -0 -237.334 Td -(5672 #define LEVEL 0x00008000 // Level triggered) 249.0053 Tj -0 -246.8274 Td -(5673 #define BCAST 0x00080000 // Send to all APICs, in\ -cluding self.) 332.0071 Tj -0 -256.3207 Td -(5674 #define ICRHI \(0x0310/4\) // Interrupt Command [63:32\ -]) 270.8479 Tj -0 -265.8141 Td -(5675 #define TIMER \(0x0320/4\) // Local Vector Table 0 \(T\ -IMER\)) 283.9534 Tj -0 -275.3075 Td -(5676 #define X1 0x0000000B // divide counts by 1) 262.1109 Tj -0 -284.8008 Td -(5677 #define PERIODIC 0x00020000 // Periodic) 218.4257 Tj -0 -294.2942 Td -(5678 #define PCINT \(0x0340/4\) // Performance Counter LVT) 262.1109 Tj -0 -303.7875 Td -(5679 #define LINT0 \(0x0350/4\) // Local Vector Table 1 \(L\ -INT0\)) 283.9534 Tj -0 -313.2809 Td -(5680 #define LINT1 \(0x0360/4\) // Local Vector Table 2 \(L\ -INT1\)) 283.9534 Tj -0 -322.7743 Td -(5681 #define ERROR \(0x0370/4\) // Local Vector Table 3 \(E\ -RROR\)) 283.9534 Tj -0 -332.2676 Td -(5682 #define MASKED 0x00010000 // Interrupt masked) 253.3738 Tj -0 -341.761 Td -(5683 #define TICR \(0x0380/4\) // Timer Initial Count) 244.6368 Tj -0 -351.2543 Td -(5684 #define TCCR \(0x0390/4\) // Timer Current Count) 244.6368 Tj -0 -360.7477 Td -(5685 #define TDCR \(0x03E0/4\) // Timer Divide Configurati\ -on) 275.2164 Tj -0 -370.2411 Td -(5686 ) 21.8426 Tj -0 -379.7344 Td -(5687 volatile uint *lapic; // Initialized in mp.c) 218.4257 Tj -0 -389.2278 Td -(5688 ) 21.8426 Tj -0 -398.7211 Td -(5689 static void) 69.8962 Tj -0 -408.2145 Td -(5690 lapicw\(int index, int value\)) 144.161 Tj -0 -417.7079 Td -(5691 {) 26.2111 Tj -0 -427.2012 Td -(5692 lapic[index] = value;) 122.3184 Tj -0 -436.6946 Td -(5693 lapic[ID]; // wait for write to finish, by reading) 253.3738 Tj -0 -446.1879 Td -(5694 }) 26.2111 Tj -0 -455.6813 Td -(5695 ) 21.8426 Tj -0 -465.1747 Td -(5696 ) 21.8426 Tj -0 -474.668 Td -(5697 ) 21.8426 Tj -0 -484.1614 Td -(5698 ) 21.8426 Tj -0 -493.6547 Td -(5699 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 56) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 64 64 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/lapic.c Page 2) 166.0035 Tj -0 -28.4801 Td -(5700 void) 39.3166 Tj -0 -37.9735 Td -(5701 lapicinit\(int c\)) 91.7388 Tj -0 -47.4668 Td -(5702 {) 26.2111 Tj -0 -56.9602 Td -(5703 if\(!lapic\)) 74.2647 Tj -0 -66.4535 Td -(5704 return;) 69.8962 Tj -0 -75.9469 Td -(5705 ) 21.8426 Tj -0 -85.4403 Td -(5706 // Enable local APIC; set spurious interrupt vector.) 257.7424 Tj -0 -94.9336 Td -(5707 lapicw\(SVR, ENABLE | \(T_IRQ0 + IRQ_SPURIOUS\)\);) 231.5313 Tj -0 -104.427 Td -(5708 ) 21.8426 Tj -0 -113.9203 Td -(5709 // The timer repeatedly counts down at bus frequency) 257.7424 Tj -0 -123.4137 Td -(5710 // from lapic[TICR] and then issues an interrupt.) 244.6368 Tj -0 -132.9071 Td -(5711 // If xv6 cared more about precise timekeeping,) 235.8998 Tj -0 -142.4004 Td -(5712 // TICR would be calibrated using an external time sourc\ -e.) 283.9534 Tj -0 -151.8938 Td -(5713 lapicw\(TDCR, X1\);) 104.8443 Tj -0 -161.3871 Td -(5714 lapicw\(TIMER, PERIODIC | \(T_IRQ0 + IRQ_TIMER\)\);) 235.8998 Tj -0 -170.8805 Td -(5715 lapicw\(TICR, 10000000\);) 131.0554 Tj -0 -180.3739 Td -(5716 ) 21.8426 Tj -0 -189.8672 Td -(5717 // Disable logical interrupt lines.) 183.4776 Tj -0 -199.3606 Td -(5718 lapicw\(LINT0, MASKED\);) 126.6869 Tj -0 -208.8539 Td -(5719 lapicw\(LINT1, MASKED\);) 126.6869 Tj -0 -218.3473 Td -(5720 ) 21.8426 Tj -0 -227.8407 Td -(5721 // Disable performance counter overflow interrupts) 249.0053 Tj -0 -237.334 Td -(5722 // on machines that provide that interrupt entry.) 244.6368 Tj -0 -246.8274 Td -(5723 if\(\(\(lapic[VER]>>16\) & 0xFF\) >= 4\)) 179.1091 Tj -0 -256.3207 Td -(5724 lapicw\(PCINT, MASKED\);) 135.4239 Tj -0 -265.8141 Td -(5725 ) 21.8426 Tj -0 -275.3075 Td -(5726 // Map error interrupt to IRQ_ERROR.) 187.8461 Tj -0 -284.8008 Td -(5727 lapicw\(ERROR, T_IRQ0 + IRQ_ERROR\);) 179.1091 Tj -0 -294.2942 Td -(5728 ) 21.8426 Tj -0 -303.7875 Td -(5729 // Clear error status register \(requires back-to-back w\ -rites\).) 301.4275 Tj -0 -313.2809 Td -(5730 lapicw\(ESR, 0\);) 96.1073 Tj -0 -322.7743 Td -(5731 lapicw\(ESR, 0\);) 96.1073 Tj -0 -332.2676 Td -(5732 ) 21.8426 Tj -0 -341.761 Td -(5733 // Ack any outstanding interrupts.) 179.1091 Tj -0 -351.2543 Td -(5734 lapicw\(EOI, 0\);) 96.1073 Tj -0 -360.7477 Td -(5735 ) 21.8426 Tj -0 -370.2411 Td -(5736 // Send an Init Level De-Assert to synchronise arbitrati\ -on ID's.) 310.1645 Tj -0 -379.7344 Td -(5737 lapicw\(ICRHI, 0\);) 104.8443 Tj -0 -389.2278 Td -(5738 lapicw\(ICRLO, BCAST | INIT | LEVEL\);) 187.8461 Tj -0 -398.7211 Td -(5739 while\(lapic[ICRLO] & DELIVS\)) 152.898 Tj -0 -408.2145 Td -(5740 ;) 43.6851 Tj -0 -417.7079 Td -(5741 ) 21.8426 Tj -0 -427.2012 Td -(5742 // Enable interrupts on the APIC \(but not on the proces\ -sor\).) 292.6905 Tj -0 -436.6946 Td -(5743 lapicw\(TPR, 0\);) 96.1073 Tj -0 -446.1879 Td -(5744 }) 26.2111 Tj -0 -455.6813 Td -(5745 ) 21.8426 Tj -0 -465.1747 Td -(5746 ) 21.8426 Tj -0 -474.668 Td -(5747 ) 21.8426 Tj -0 -484.1614 Td -(5748 ) 21.8426 Tj -0 -493.6547 Td -(5749 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 57) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/lapic.c Page 3) 166.0035 Tj -0 -28.4801 Td -(5750 int) 34.9481 Tj -0 -37.9735 Td -(5751 cpunum\(void\)) 74.2647 Tj -0 -47.4668 Td -(5752 {) 26.2111 Tj -0 -56.9602 Td -(5753 // Cannot call cpu when interrupts are enabled:) 235.8998 Tj -0 -66.4535 Td -(5754 // result not guaranteed to last long enough to be used!) 275.2164 Tj -0 -75.9469 Td -(5755 // Would prefer to panic but even printing is chancy her\ -e:) 283.9534 Tj -0 -85.4403 Td -(5756 // almost everything, including cprintf and panic, calls\ - cpu,) 297.059 Tj -0 -94.9336 Td -(5757 // often indirectly through acquire and release.) 240.2683 Tj -0 -104.427 Td -(5758 if\(readeflags\(\)&FL_IF\){) 131.0554 Tj -0 -113.9203 Td -(5759 static int n;) 96.1073 Tj -0 -123.4137 Td -(5760 if\(n++ == 0\)) 91.7388 Tj -0 -132.9071 Td -(5761 cprintf\("cpu called from %x with interrupts enabled\ -\\n",) 288.322 Tj -0 -142.4004 Td -(5762 __builtin_return_address\(0\)\);) 183.4776 Tj -0 -151.8938 Td -(5763 }) 34.9481 Tj -0 -161.3871 Td -(5764 ) 21.8426 Tj -0 -170.8805 Td -(5765 if\(lapic\)) 69.8962 Tj -0 -180.3739 Td -(5766 return lapic[ID]>>24;) 131.0554 Tj -0 -189.8672 Td -(5767 return 0;) 69.8962 Tj -0 -199.3606 Td -(5768 }) 26.2111 Tj -0 -208.8539 Td -(5769 ) 21.8426 Tj -0 -218.3473 Td -(5770 // Acknowledge interrupt.) 131.0554 Tj -0 -227.8407 Td -(5771 void) 39.3166 Tj -0 -237.334 Td -(5772 lapiceoi\(void\)) 83.0018 Tj -0 -246.8274 Td -(5773 {) 26.2111 Tj -0 -256.3207 Td -(5774 if\(lapic\)) 69.8962 Tj -0 -265.8141 Td -(5775 lapicw\(EOI, 0\);) 104.8443 Tj -0 -275.3075 Td -(5776 }) 26.2111 Tj -0 -284.8008 Td -(5777 ) 21.8426 Tj -0 -294.2942 Td -(5778 // Spin for a given number of microseconds.) 209.6887 Tj -0 -303.7875 Td -(5779 // On real hardware would want to tune this dynamically.) 266.4794 Tj -0 -313.2809 Td -(5780 void) 39.3166 Tj -0 -322.7743 Td -(5781 microdelay\(int us\)) 100.4758 Tj -0 -332.2676 Td -(5782 {) 26.2111 Tj -0 -341.761 Td -(5783 }) 26.2111 Tj -0 -351.2543 Td -(5784 ) 21.8426 Tj -0 -360.7477 Td -(5785 ) 21.8426 Tj -0 -370.2411 Td -(5786 #define IO_RTC 0x70) 109.2129 Tj -0 -379.7344 Td -(5787 ) 21.8426 Tj -0 -389.2278 Td -(5788 // Start additional processor running bootstrap code at ad\ -dr.) 288.322 Tj -0 -398.7211 Td -(5789 // See Appendix B of MultiProcessor Specification.) 240.2683 Tj -0 -408.2145 Td -(5790 void) 39.3166 Tj -0 -417.7079 Td -(5791 lapicstartap\(uchar apicid, uint addr\)) 183.4776 Tj -0 -427.2012 Td -(5792 {) 26.2111 Tj -0 -436.6946 Td -(5793 int i;) 56.7907 Tj -0 -446.1879 Td -(5794 ushort *wrv;) 83.0018 Tj -0 -455.6813 Td -(5795 ) 21.8426 Tj -0 -465.1747 Td -(5796 // "The BSP must initialize CMOS shutdown code to 0AH) 262.1109 Tj -0 -474.668 Td -(5797 // and the warm reset vector \(DWORD based at 40:67\) to\ - point at) 305.796 Tj -0 -484.1614 Td -(5798 // the AP startup code prior to the [universal startup a\ -lgorithm].") 323.2701 Tj -0 -493.6547 Td -(5799 outb\(IO_RTC, 0xF\); // offset 0xF is shutdown code) 249.0053 Tj -0 -522.1348 Td -(Sheet 57) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 65 65 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/lapic.c Page 4) 166.0035 Tj -0 -28.4801 Td -(5800 outb\(IO_RTC+1, 0x0A\);) 122.3184 Tj -0 -37.9735 Td -(5801 wrv = \(ushort*\)\(0x40<<4 | 0x67\); // Warm reset vect\ -or) 266.4794 Tj -0 -47.4668 Td -(5802 wrv[0] = 0;) 78.6333 Tj -0 -56.9602 Td -(5803 wrv[1] = addr >> 4;) 113.5814 Tj -0 -66.4535 Td -(5804 ) 21.8426 Tj -0 -75.9469 Td -(5805 // "Universal startup algorithm.") 174.7406 Tj -0 -85.4403 Td -(5806 // Send INIT \(level-triggered\) interrupt to reset othe\ -r CPU.) 292.6905 Tj -0 -94.9336 Td -(5807 lapicw\(ICRHI, apicid<<24\);) 144.161 Tj -0 -104.427 Td -(5808 lapicw\(ICRLO, INIT | LEVEL | ASSERT\);) 192.2146 Tj -0 -113.9203 Td -(5809 microdelay\(200\);) 100.4758 Tj -0 -123.4137 Td -(5810 lapicw\(ICRLO, INIT | LEVEL\);) 152.898 Tj -0 -132.9071 Td -(5811 microdelay\(100\); // should be 10ms, but too slow in\ - Bochs!) 297.059 Tj -0 -142.4004 Td -(5812 ) 21.8426 Tj -0 -151.8938 Td -(5813 // Send startup IPI \(twice!\) to enter bootstrap code.) 262.1109 Tj -0 -161.3871 Td -(5814 // Regular hardware is supposed to only accept a STARTUP) 275.2164 Tj -0 -170.8805 Td -(5815 // when it is in the halted state due to an INIT. So th\ -e second) 310.1645 Tj -0 -180.3739 Td -(5816 // should be ignored, but it is part of the official Int\ -el algorithm.) 332.0071 Tj -0 -189.8672 Td -(5817 // Bochs complains about the second one. Too bad for Bo\ -chs.) 292.6905 Tj -0 -199.3606 Td -(5818 for\(i = 0; i < 2; i++\){) 131.0554 Tj -0 -208.8539 Td -(5819 lapicw\(ICRHI, apicid<<24\);) 152.898 Tj -0 -218.3473 Td -(5820 lapicw\(ICRLO, STARTUP | \(addr>>12\)\);) 196.5831 Tj -0 -227.8407 Td -(5821 microdelay\(200\);) 109.2129 Tj -0 -237.334 Td -(5822 }) 34.9481 Tj -0 -246.8274 Td -(5823 }) 26.2111 Tj -0 -256.3207 Td -(5824 ) 21.8426 Tj -0 -265.8141 Td -(5825 ) 21.8426 Tj -0 -275.3075 Td -(5826 ) 21.8426 Tj -0 -284.8008 Td -(5827 ) 21.8426 Tj -0 -294.2942 Td -(5828 ) 21.8426 Tj -0 -303.7875 Td -(5829 ) 21.8426 Tj -0 -313.2809 Td -(5830 ) 21.8426 Tj -0 -322.7743 Td -(5831 ) 21.8426 Tj -0 -332.2676 Td -(5832 ) 21.8426 Tj -0 -341.761 Td -(5833 ) 21.8426 Tj -0 -351.2543 Td -(5834 ) 21.8426 Tj -0 -360.7477 Td -(5835 ) 21.8426 Tj -0 -370.2411 Td -(5836 ) 21.8426 Tj -0 -379.7344 Td -(5837 ) 21.8426 Tj -0 -389.2278 Td -(5838 ) 21.8426 Tj -0 -398.7211 Td -(5839 ) 21.8426 Tj -0 -408.2145 Td -(5840 ) 21.8426 Tj -0 -417.7079 Td -(5841 ) 21.8426 Tj -0 -427.2012 Td -(5842 ) 21.8426 Tj -0 -436.6946 Td -(5843 ) 21.8426 Tj -0 -446.1879 Td -(5844 ) 21.8426 Tj -0 -455.6813 Td -(5845 ) 21.8426 Tj -0 -465.1747 Td -(5846 ) 21.8426 Tj -0 -474.668 Td -(5847 ) 21.8426 Tj -0 -484.1614 Td -(5848 ) 21.8426 Tj -0 -493.6547 Td -(5849 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 58) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/ioapic.c Page 1) 170.3721 Tj -0 -28.4801 Td -(5850 // The I/O APIC manages hardware interrupts for an SMP sys\ -tem.) 292.6905 Tj -0 -37.9735 Td -(5851 // http://www.intel.com/design/chipsets/datashts/29056601.\ -pdf) 288.322 Tj -0 -47.4668 Td -(5852 // See also picirq.c.) 113.5814 Tj -0 -56.9602 Td -(5853 ) 21.8426 Tj -0 -66.4535 Td -(5854 #include "types.h") 100.4758 Tj -0 -75.9469 Td -(5855 #include "defs.h") 96.1073 Tj -0 -85.4403 Td -(5856 #include "traps.h") 100.4758 Tj -0 -94.9336 Td -(5857 ) 21.8426 Tj -0 -104.427 Td -(5858 #define IOAPIC 0xFEC00000 // Default physical address o\ -f IO APIC) 314.533 Tj -0 -113.9203 Td -(5859 ) 21.8426 Tj -0 -123.4137 Td -(5860 #define REG_ID 0x00 // Register index: ID) 222.7942 Tj -0 -132.9071 Td -(5861 #define REG_VER 0x01 // Register index: version) 244.6368 Tj -0 -142.4004 Td -(5862 #define REG_TABLE 0x10 // Redirection table base) 240.2683 Tj -0 -151.8938 Td -(5863 ) 21.8426 Tj -0 -161.3871 Td -(5864 // The redirection table starts at REG_TABLE and uses) 253.3738 Tj -0 -170.8805 Td -(5865 // two registers to configure each interrupt.) 218.4257 Tj -0 -180.3739 Td -(5866 // The first \(low\) register in a pair contains configura\ -tion bits.) 310.1645 Tj -0 -189.8672 Td -(5867 // The second \(high\) register contains a bitmask telling\ - which) 292.6905 Tj -0 -199.3606 Td -(5868 // CPUs can serve that interrupt.) 166.0035 Tj -0 -208.8539 Td -(5869 #define INT_DISABLED 0x00010000 // Interrupt disabled) 266.4794 Tj -0 -218.3473 Td -(5870 #define INT_LEVEL 0x00008000 // Level-triggered \(vs\ - edge-\)) 301.4275 Tj -0 -227.8407 Td -(5871 #define INT_ACTIVELOW 0x00002000 // Active low \(vs high\ -\)) 275.2164 Tj -0 -237.334 Td -(5872 #define INT_LOGICAL 0x00000800 // Destination is CPU i\ -d \(vs APIC ID\)) 336.3756 Tj -0 -246.8274 Td -(5873 ) 21.8426 Tj -0 -256.3207 Td -(5874 volatile struct ioapic *ioapic;) 157.2665 Tj -0 -265.8141 Td -(5875 ) 21.8426 Tj -0 -275.3075 Td -(5876 // IO APIC MMIO structure: write reg, then read or write d\ -ata.) 292.6905 Tj -0 -284.8008 Td -(5877 struct ioapic {) 87.3703 Tj -0 -294.2942 Td -(5878 uint reg;) 69.8962 Tj -0 -303.7875 Td -(5879 uint pad[3];) 83.0018 Tj -0 -313.2809 Td -(5880 uint data;) 74.2647 Tj -0 -322.7743 Td -(5881 };) 30.5796 Tj -0 -332.2676 Td -(5882 ) 21.8426 Tj -0 -341.761 Td -(5883 static uint) 69.8962 Tj -0 -351.2543 Td -(5884 ioapicread\(int reg\)) 104.8443 Tj -0 -360.7477 Td -(5885 {) 26.2111 Tj -0 -370.2411 Td -(5886 ioapic->reg = reg;) 109.2129 Tj -0 -379.7344 Td -(5887 return ioapic->data;) 117.9499 Tj -0 -389.2278 Td -(5888 }) 26.2111 Tj -0 -398.7211 Td -(5889 ) 21.8426 Tj -0 -408.2145 Td -(5890 static void) 69.8962 Tj -0 -417.7079 Td -(5891 ioapicwrite\(int reg, uint data\)) 157.2665 Tj -0 -427.2012 Td -(5892 {) 26.2111 Tj -0 -436.6946 Td -(5893 ioapic->reg = reg;) 109.2129 Tj -0 -446.1879 Td -(5894 ioapic->data = data;) 117.9499 Tj -0 -455.6813 Td -(5895 }) 26.2111 Tj -0 -465.1747 Td -(5896 ) 21.8426 Tj -0 -474.668 Td -(5897 ) 21.8426 Tj -0 -484.1614 Td -(5898 ) 21.8426 Tj -0 -493.6547 Td -(5899 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 58) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 66 66 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/ioapic.c Page 2) 170.3721 Tj -0 -28.4801 Td -(5900 void) 39.3166 Tj -0 -37.9735 Td -(5901 ioapicinit\(void\)) 91.7388 Tj -0 -47.4668 Td -(5902 {) 26.2111 Tj -0 -56.9602 Td -(5903 int i, id, maxintr;) 113.5814 Tj -0 -66.4535 Td -(5904 ) 21.8426 Tj -0 -75.9469 Td -(5905 if\(!ismp\)) 69.8962 Tj -0 -85.4403 Td -(5906 return;) 69.8962 Tj -0 -94.9336 Td -(5907 ) 21.8426 Tj -0 -104.427 Td -(5908 ioapic = \(volatile struct ioapic*\)IOAPIC;) 209.6887 Tj -0 -113.9203 Td -(5909 maxintr = \(ioapicread\(REG_VER\) >> 16\) & 0xFF;) 227.1628 Tj -0 -123.4137 Td -(5910 id = ioapicread\(REG_ID\) >> 24;) 161.635 Tj -0 -132.9071 Td -(5911 if\(id != ioapicid\)) 109.2129 Tj -0 -142.4004 Td -(5912 cprintf\("ioapicinit: id isn't equal to ioapicid; not \ -a MP\\n"\);) 310.1645 Tj -0 -151.8938 Td -(5913 ) 21.8426 Tj -0 -161.3871 Td -(5914 // Mark all interrupts edge-triggered, active high, disa\ -bled,) 297.059 Tj -0 -170.8805 Td -(5915 // and not routed to any CPUs.) 161.635 Tj -0 -180.3739 Td -(5916 for\(i = 0; i <= maxintr; i++\){) 161.635 Tj -0 -189.8672 Td -(5917 ioapicwrite\(REG_TABLE+2*i, INT_DISABLED | \(T_IRQ0 + \ -i\)\);) 283.9534 Tj -0 -199.3606 Td -(5918 ioapicwrite\(REG_TABLE+2*i+1, 0\);) 179.1091 Tj -0 -208.8539 Td -(5919 }) 34.9481 Tj -0 -218.3473 Td -(5920 }) 26.2111 Tj -0 -227.8407 Td -(5921 ) 21.8426 Tj -0 -237.334 Td -(5922 void) 39.3166 Tj -0 -246.8274 Td -(5923 ioapicenable\(int irq, int cpunum\)) 166.0035 Tj -0 -256.3207 Td -(5924 {) 26.2111 Tj -0 -265.8141 Td -(5925 if\(!ismp\)) 69.8962 Tj -0 -275.3075 Td -(5926 return;) 69.8962 Tj -0 -284.8008 Td -(5927 ) 21.8426 Tj -0 -294.2942 Td -(5928 // Mark interrupt edge-triggered, active high,) 231.5313 Tj -0 -303.7875 Td -(5929 // enabled, and routed to the given cpunum,) 218.4257 Tj -0 -313.2809 Td -(5930 // which happens to be that cpu's APIC ID.) 214.0572 Tj -0 -322.7743 Td -(5931 ioapicwrite\(REG_TABLE+2*irq, T_IRQ0 + irq\);) 218.4257 Tj -0 -332.2676 Td -(5932 ioapicwrite\(REG_TABLE+2*irq+1, cpunum << 24\);) 227.1628 Tj -0 -341.761 Td -(5933 }) 26.2111 Tj -0 -351.2543 Td -(5934 ) 21.8426 Tj -0 -360.7477 Td -(5935 ) 21.8426 Tj -0 -370.2411 Td -(5936 ) 21.8426 Tj -0 -379.7344 Td -(5937 ) 21.8426 Tj -0 -389.2278 Td -(5938 ) 21.8426 Tj -0 -398.7211 Td -(5939 ) 21.8426 Tj -0 -408.2145 Td -(5940 ) 21.8426 Tj -0 -417.7079 Td -(5941 ) 21.8426 Tj -0 -427.2012 Td -(5942 ) 21.8426 Tj -0 -436.6946 Td -(5943 ) 21.8426 Tj -0 -446.1879 Td -(5944 ) 21.8426 Tj -0 -455.6813 Td -(5945 ) 21.8426 Tj -0 -465.1747 Td -(5946 ) 21.8426 Tj -0 -474.668 Td -(5947 ) 21.8426 Tj -0 -484.1614 Td -(5948 ) 21.8426 Tj -0 -493.6547 Td -(5949 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 59) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/picirq.c Page 1) 170.3721 Tj -0 -28.4801 Td -(5950 // Intel 8259A programmable interrupt controllers.) 240.2683 Tj -0 -37.9735 Td -(5951 ) 21.8426 Tj -0 -47.4668 Td -(5952 #include "types.h") 100.4758 Tj -0 -56.9602 Td -(5953 #include "x86.h") 91.7388 Tj -0 -66.4535 Td -(5954 #include "traps.h") 100.4758 Tj -0 -75.9469 Td -(5955 ) 21.8426 Tj -0 -85.4403 Td -(5956 // I/O Addresses of the two programmable interrupt control\ -lers) 292.6905 Tj -0 -94.9336 Td -(5957 #define IO_PIC1 0x20 // Master \(IRQs 0-7\)) 249.0053 Tj -0 -104.427 Td -(5958 #define IO_PIC2 0xA0 // Slave \(IRQs 8-15\)) 249.0053 Tj -0 -113.9203 Td -(5959 ) 21.8426 Tj -0 -123.4137 Td -(5960 #define IRQ_SLAVE 2 // IRQ at which slave conn\ -ects to master) 336.3756 Tj -0 -132.9071 Td -(5961 ) 21.8426 Tj -0 -142.4004 Td -(5962 // Current IRQ mask.) 109.2129 Tj -0 -151.8938 Td -(5963 // Initial IRQ mask has interrupt 2 enabled \(for slave 82\ -59A\).) 292.6905 Tj -0 -161.3871 Td -(5964 static ushort irqmask = 0xFFFF & ~\(1<> 8\);) 148.5295 Tj -0 -237.334 Td -(5972 }) 26.2111 Tj -0 -246.8274 Td -(5973 ) 21.8426 Tj -0 -256.3207 Td -(5974 void) 39.3166 Tj -0 -265.8141 Td -(5975 picenable\(int irq\)) 100.4758 Tj -0 -275.3075 Td -(5976 {) 26.2111 Tj -0 -284.8008 Td -(5977 picsetmask\(irqmask & ~\(1<', '?', NO, '*', // 0x30) 270.8479 Tj -0 -322.7743 Td -(6181 NO, ' ', NO, NO, NO, NO, NO, NO,) 227.1628 Tj -0 -332.2676 Td -(6182 NO, NO, NO, NO, NO, NO, NO, '7', // 0x40) 270.8479 Tj -0 -341.761 Td -(6183 '8', '9', '-', '4', '5', '6', '+', '1',) 231.5313 Tj -0 -351.2543 Td -(6184 '2', '3', '0', '.', NO, NO, NO, NO, // 0x50) 270.8479 Tj -0 -360.7477 Td -(6185 [0x9C] '\\n', // KP_Enter) 157.2665 Tj -0 -370.2411 Td -(6186 [0xB5] '/', // KP_Div) 148.5295 Tj -0 -379.7344 Td -(6187 [0xC8] KEY_UP, [0xD0] KEY_DN,) 170.3721 Tj -0 -389.2278 Td -(6188 [0xC9] KEY_PGUP, [0xD1] KEY_PGDN,) 179.1091 Tj -0 -398.7211 Td -(6189 [0xCB] KEY_LF, [0xCD] KEY_RT,) 170.3721 Tj -0 -408.2145 Td -(6190 [0x97] KEY_HOME, [0xCF] KEY_END,) 174.7406 Tj -0 -417.7079 Td -(6191 [0xD2] KEY_INS, [0xD3] KEY_DEL) 170.3721 Tj -0 -427.2012 Td -(6192 };) 30.5796 Tj -0 -436.6946 Td -(6193 ) 21.8426 Tj -0 -446.1879 Td -(6194 ) 21.8426 Tj -0 -455.6813 Td -(6195 ) 21.8426 Tj -0 -465.1747 Td -(6196 ) 21.8426 Tj -0 -474.668 Td -(6197 ) 21.8426 Tj -0 -484.1614 Td -(6198 ) 21.8426 Tj -0 -493.6547 Td -(6199 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 61) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 69 69 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/kbd.h Page 3) 157.2665 Tj -0 -28.4801 Td -(6200 static uchar ctlmap[256] =) 135.4239 Tj -0 -37.9735 Td -(6201 {) 26.2111 Tj -0 -47.4668 Td -(6202 NO, NO, NO, NO, NO, NO, NO\ -, NO,) 318.9016 Tj -0 -56.9602 Td -(6203 NO, NO, NO, NO, NO, NO, NO\ -, NO,) 318.9016 Tj -0 -66.4535 Td -(6204 C\('Q'\), C\('W'\), C\('E'\), C\('R'\), C\('T'\), C\ -\('Y'\), C\('U'\), C\('I'\),) 336.3756 Tj -0 -75.9469 Td -(6205 C\('O'\), C\('P'\), NO, NO, '\\r', NO, \ - C\('A'\), C\('S'\),) 336.3756 Tj -0 -85.4403 Td -(6206 C\('D'\), C\('F'\), C\('G'\), C\('H'\), C\('J'\), C\ -\('K'\), C\('L'\), NO,) 318.9016 Tj -0 -94.9336 Td -(6207 NO, NO, NO, C\('\\\\'\), C\('Z'\), C\('X\ -'\), C\('C'\), C\('V'\),) 336.3756 Tj -0 -104.427 Td -(6208 C\('B'\), C\('N'\), C\('M'\), NO, NO, C\('/\ -'\), NO, NO,) 318.9016 Tj -0 -113.9203 Td -(6209 [0x9C] '\\r', // KP_Enter) 157.2665 Tj -0 -123.4137 Td -(6210 [0xB5] C\('/'\), // KP_Div) 148.5295 Tj -0 -132.9071 Td -(6211 [0xC8] KEY_UP, [0xD0] KEY_DN,) 170.3721 Tj -0 -142.4004 Td -(6212 [0xC9] KEY_PGUP, [0xD1] KEY_PGDN,) 179.1091 Tj -0 -151.8938 Td -(6213 [0xCB] KEY_LF, [0xCD] KEY_RT,) 170.3721 Tj -0 -161.3871 Td -(6214 [0x97] KEY_HOME, [0xCF] KEY_END,) 174.7406 Tj -0 -170.8805 Td -(6215 [0xD2] KEY_INS, [0xD3] KEY_DEL) 170.3721 Tj -0 -180.3739 Td -(6216 };) 30.5796 Tj -0 -189.8672 Td -(6217 ) 21.8426 Tj -0 -199.3606 Td -(6218 ) 21.8426 Tj -0 -208.8539 Td -(6219 ) 21.8426 Tj -0 -218.3473 Td -(6220 ) 21.8426 Tj -0 -227.8407 Td -(6221 ) 21.8426 Tj -0 -237.334 Td -(6222 ) 21.8426 Tj -0 -246.8274 Td -(6223 ) 21.8426 Tj -0 -256.3207 Td -(6224 ) 21.8426 Tj -0 -265.8141 Td -(6225 ) 21.8426 Tj -0 -275.3075 Td -(6226 ) 21.8426 Tj -0 -284.8008 Td -(6227 ) 21.8426 Tj -0 -294.2942 Td -(6228 ) 21.8426 Tj -0 -303.7875 Td -(6229 ) 21.8426 Tj -0 -313.2809 Td -(6230 ) 21.8426 Tj -0 -322.7743 Td -(6231 ) 21.8426 Tj -0 -332.2676 Td -(6232 ) 21.8426 Tj -0 -341.761 Td -(6233 ) 21.8426 Tj -0 -351.2543 Td -(6234 ) 21.8426 Tj -0 -360.7477 Td -(6235 ) 21.8426 Tj -0 -370.2411 Td -(6236 ) 21.8426 Tj -0 -379.7344 Td -(6237 ) 21.8426 Tj -0 -389.2278 Td -(6238 ) 21.8426 Tj -0 -398.7211 Td -(6239 ) 21.8426 Tj -0 -408.2145 Td -(6240 ) 21.8426 Tj -0 -417.7079 Td -(6241 ) 21.8426 Tj -0 -427.2012 Td -(6242 ) 21.8426 Tj -0 -436.6946 Td -(6243 ) 21.8426 Tj -0 -446.1879 Td -(6244 ) 21.8426 Tj -0 -455.6813 Td -(6245 ) 21.8426 Tj -0 -465.1747 Td -(6246 ) 21.8426 Tj -0 -474.668 Td -(6247 ) 21.8426 Tj -0 -484.1614 Td -(6248 ) 21.8426 Tj -0 -493.6547 Td -(6249 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 62) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/kbd.c Page 1) 157.2665 Tj -0 -28.4801 Td -(6250 #include "types.h") 100.4758 Tj -0 -37.9735 Td -(6251 #include "x86.h") 91.7388 Tj -0 -47.4668 Td -(6252 #include "defs.h") 96.1073 Tj -0 -56.9602 Td -(6253 #include "kbd.h") 91.7388 Tj -0 -66.4535 Td -(6254 ) 21.8426 Tj -0 -75.9469 Td -(6255 int) 34.9481 Tj -0 -85.4403 Td -(6256 kbdgetc\(void\)) 78.6333 Tj -0 -94.9336 Td -(6257 {) 26.2111 Tj -0 -104.427 Td -(6258 static uint shift;) 109.2129 Tj -0 -113.9203 Td -(6259 static uchar *charcode[4] = {) 157.2665 Tj -0 -123.4137 Td -(6260 normalmap, shiftmap, ctlmap, ctlmap) 192.2146 Tj -0 -132.9071 Td -(6261 };) 39.3166 Tj -0 -142.4004 Td -(6262 uint st, data, c;) 104.8443 Tj -0 -151.8938 Td -(6263 ) 21.8426 Tj -0 -161.3871 Td -(6264 st = inb\(KBSTATP\);) 109.2129 Tj -0 -170.8805 Td -(6265 if\(\(st & KBS_DIB\) == 0\)) 131.0554 Tj -0 -180.3739 Td -(6266 return -1;) 83.0018 Tj -0 -189.8672 Td -(6267 data = inb\(KBDATAP\);) 117.9499 Tj -0 -199.3606 Td -(6268 ) 21.8426 Tj -0 -208.8539 Td -(6269 if\(data == 0xE0\){) 104.8443 Tj -0 -218.3473 Td -(6270 shift |= E0ESC;) 104.8443 Tj -0 -227.8407 Td -(6271 return 0;) 78.6333 Tj -0 -237.334 Td -(6272 } else if\(data & 0x80\){) 131.0554 Tj -0 -246.8274 Td -(6273 // Key released) 104.8443 Tj -0 -256.3207 Td -(6274 data = \(shift & E0ESC ? data : data & 0x7F\);) 231.5313 Tj -0 -265.8141 Td -(6275 shift &= ~\(shiftcode[data] | E0ESC\);) 196.5831 Tj -0 -275.3075 Td -(6276 return 0;) 78.6333 Tj -0 -284.8008 Td -(6277 } else if\(shift & E0ESC\){) 139.7925 Tj -0 -294.2942 Td -(6278 // Last character was an E0 escape; or with 0x80) 249.0053 Tj -0 -303.7875 Td -(6279 data |= 0x80;) 96.1073 Tj -0 -313.2809 Td -(6280 shift &= ~E0ESC;) 109.2129 Tj -0 -322.7743 Td -(6281 }) 34.9481 Tj -0 -332.2676 Td -(6282 ) 21.8426 Tj -0 -341.761 Td -(6283 shift |= shiftcode[data];) 139.7925 Tj -0 -351.2543 Td -(6284 shift ^= togglecode[data];) 144.161 Tj -0 -360.7477 Td -(6285 c = charcode[shift & \(CTL | SHIFT\)][data];) 214.0572 Tj -0 -370.2411 Td -(6286 if\(shift & CAPSLOCK\){) 122.3184 Tj -0 -379.7344 Td -(6287 if\('a' <= c && c <= 'z'\)) 144.161 Tj -0 -389.2278 Td -(6288 c += 'A' - 'a';) 113.5814 Tj -0 -398.7211 Td -(6289 else if\('A' <= c && c <= 'Z'\)) 166.0035 Tj -0 -408.2145 Td -(6290 c += 'a' - 'A';) 113.5814 Tj -0 -417.7079 Td -(6291 }) 34.9481 Tj -0 -427.2012 Td -(6292 return c;) 69.8962 Tj -0 -436.6946 Td -(6293 }) 26.2111 Tj -0 -446.1879 Td -(6294 ) 21.8426 Tj -0 -455.6813 Td -(6295 void) 39.3166 Tj -0 -465.1747 Td -(6296 kbdintr\(void\)) 78.6333 Tj -0 -474.668 Td -(6297 {) 26.2111 Tj -0 -484.1614 Td -(6298 consoleintr\(kbdgetc\);) 122.3184 Tj -0 -493.6547 Td -(6299 }) 26.2111 Tj -0 -522.1348 Td -(Sheet 62) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 70 70 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/console.c Page 1) 174.7406 Tj -0 -28.4801 Td -(6300 // Console input and output.) 144.161 Tj -0 -37.9735 Td -(6301 // Input is from the keyboard or serial port.) 218.4257 Tj -0 -47.4668 Td -(6302 // Output is written to the screen and serial port.) 244.6368 Tj -0 -56.9602 Td -(6303 ) 21.8426 Tj -0 -66.4535 Td -(6304 #include "types.h") 100.4758 Tj -0 -75.9469 Td -(6305 #include "defs.h") 96.1073 Tj -0 -85.4403 Td -(6306 #include "param.h") 100.4758 Tj -0 -94.9336 Td -(6307 #include "traps.h") 100.4758 Tj -0 -104.427 Td -(6308 #include "spinlock.h") 113.5814 Tj -0 -113.9203 Td -(6309 #include "fs.h") 87.3703 Tj -0 -123.4137 Td -(6310 #include "file.h") 96.1073 Tj -0 -132.9071 Td -(6311 #include "mmu.h") 91.7388 Tj -0 -142.4004 Td -(6312 #include "proc.h") 96.1073 Tj -0 -151.8938 Td -(6313 #include "x86.h") 91.7388 Tj -0 -161.3871 Td -(6314 ) 21.8426 Tj -0 -170.8805 Td -(6315 static void consputc\(int\);) 135.4239 Tj -0 -180.3739 Td -(6316 ) 21.8426 Tj -0 -189.8672 Td -(6317 static int panicked = 0;) 126.6869 Tj -0 -199.3606 Td -(6318 ) 21.8426 Tj -0 -208.8539 Td -(6319 static struct {) 87.3703 Tj -0 -218.3473 Td -(6320 ) 21.8426 Tj --1504.73 TJm -(struct spinlock lock;) 91.7388 Tj -0 -227.8407 Td -(6321 ) 21.8426 Tj --1504.73 TJm -(int locking;) 52.4222 Tj -0 -237.334 Td -(6322 } cons;) 52.4222 Tj -0 -246.8274 Td -(6323 ) 21.8426 Tj -0 -256.3207 Td -(6324 static void) 69.8962 Tj -0 -265.8141 Td -(6325 printint\(int xx, int base, int sgn\)) 174.7406 Tj -0 -275.3075 Td -(6326 {) 26.2111 Tj -0 -284.8008 Td -(6327 static char digits[] = "0123456789abcdef";) 214.0572 Tj -0 -294.2942 Td -(6328 char buf[16];) 87.3703 Tj -0 -303.7875 Td -(6329 int i = 0, neg = 0;) 113.5814 Tj -0 -313.2809 Td -(6330 uint x;) 61.1592 Tj -0 -322.7743 Td -(6331 ) 21.8426 Tj -0 -332.2676 Td -(6332 if\(sgn && xx < 0\){) 109.2129 Tj -0 -341.761 Td -(6333 neg = 1;) 74.2647 Tj -0 -351.2543 Td -(6334 x = -xx;) 74.2647 Tj -0 -360.7477 Td -(6335 } else) 56.7907 Tj -0 -370.2411 Td -(6336 x = xx;) 69.8962 Tj -0 -379.7344 Td -(6337 ) 21.8426 Tj -0 -389.2278 Td -(6338 do{) 43.6851 Tj -0 -398.7211 Td -(6339 buf[i++] = digits[x % base];) 161.635 Tj -0 -408.2145 Td -(6340 }while\(\(x /= base\) != 0\);) 139.7925 Tj -0 -417.7079 Td -(6341 if\(neg\)) 61.1592 Tj -0 -427.2012 Td -(6342 buf[i++] = '-';) 104.8443 Tj -0 -436.6946 Td -(6343 ) 21.8426 Tj -0 -446.1879 Td -(6344 while\(--i >= 0\)) 96.1073 Tj -0 -455.6813 Td -(6345 consputc\(buf[i]\);) 113.5814 Tj -0 -465.1747 Td -(6346 }) 26.2111 Tj -0 -474.668 Td -(6347 ) 21.8426 Tj -0 -484.1614 Td -(6348 ) 21.8426 Tj -0 -493.6547 Td -(6349 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 63) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/console.c Page 2) 174.7406 Tj -0 -28.4801 Td -(6350 // Print to the console. only understands %d, %x, %p, %s.) 270.8479 Tj -0 -37.9735 Td -(6351 void) 39.3166 Tj -0 -47.4668 Td -(6352 cprintf\(char *fmt, ...\)) 122.3184 Tj -0 -56.9602 Td -(6353 {) 26.2111 Tj -0 -66.4535 Td -(6354 int i, c, state, locking;) 139.7925 Tj -0 -75.9469 Td -(6355 uint *argp;) 78.6333 Tj -0 -85.4403 Td -(6356 char *s;) 65.5277 Tj -0 -94.9336 Td -(6357 ) 21.8426 Tj -0 -104.427 Td -(6358 locking = cons.locking;) 131.0554 Tj -0 -113.9203 Td -(6359 if\(locking\)) 78.6333 Tj -0 -123.4137 Td -(6360 acquire\(&cons.lock\);) 126.6869 Tj -0 -132.9071 Td -(6361 ) 21.8426 Tj -0 -142.4004 Td -(6362 argp = \(uint*\)\(void*\)\(&fmt + 1\);) 170.3721 Tj -0 -151.8938 Td -(6363 state = 0;) 74.2647 Tj -0 -161.3871 Td -(6364 for\(i = 0; \(c = fmt[i] & 0xff\) != 0; i++\){) 214.0572 Tj -0 -170.8805 Td -(6365 if\(c != '%'\){) 96.1073 Tj -0 -180.3739 Td -(6366 consputc\(c\);) 100.4758 Tj -0 -189.8672 Td -(6367 continue;) 87.3703 Tj -0 -199.3606 Td -(6368 }) 43.6851 Tj -0 -208.8539 Td -(6369 c = fmt[++i] & 0xff;) 126.6869 Tj -0 -218.3473 Td -(6370 if\(c == 0\)) 83.0018 Tj -0 -227.8407 Td -(6371 break;) 74.2647 Tj -0 -237.334 Td -(6372 switch\(c\){) 83.0018 Tj -0 -246.8274 Td -(6373 case 'd':) 78.6333 Tj -0 -256.3207 Td -(6374 printint\(*argp++, 10, 1\);) 157.2665 Tj -0 -265.8141 Td -(6375 break;) 74.2647 Tj -0 -275.3075 Td -(6376 case 'x':) 78.6333 Tj -0 -284.8008 Td -(6377 case 'p':) 78.6333 Tj -0 -294.2942 Td -(6378 printint\(*argp++, 16, 0\);) 157.2665 Tj -0 -303.7875 Td -(6379 break;) 74.2647 Tj -0 -313.2809 Td -(6380 case 's':) 78.6333 Tj -0 -322.7743 Td -(6381 if\(\(s = \(char*\)*argp++\) == 0\)) 174.7406 Tj -0 -332.2676 Td -(6382 s = "\(null\)";) 113.5814 Tj -0 -341.761 Td -(6383 for\(; *s; s++\)) 109.2129 Tj -0 -351.2543 Td -(6384 consputc\(*s\);) 113.5814 Tj -0 -360.7477 Td -(6385 break;) 74.2647 Tj -0 -370.2411 Td -(6386 case '%':) 78.6333 Tj -0 -379.7344 Td -(6387 consputc\('%'\);) 109.2129 Tj -0 -389.2278 Td -(6388 break;) 74.2647 Tj -0 -398.7211 Td -(6389 default:) 74.2647 Tj -0 -408.2145 Td -(6390 // Print unknown % sequence to draw attention.) 249.0053 Tj -0 -417.7079 Td -(6391 consputc\('%'\);) 109.2129 Tj -0 -427.2012 Td -(6392 consputc\(c\);) 100.4758 Tj -0 -436.6946 Td -(6393 break;) 74.2647 Tj -0 -446.1879 Td -(6394 }) 43.6851 Tj -0 -455.6813 Td -(6395 }) 34.9481 Tj -0 -465.1747 Td -(6396 ) 21.8426 Tj -0 -474.668 Td -(6397 if\(locking\)) 78.6333 Tj -0 -484.1614 Td -(6398 release\(&cons.lock\);) 126.6869 Tj -0 -493.6547 Td -(6399 }) 26.2111 Tj -0 -522.1348 Td -(Sheet 63) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 71 71 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/console.c Page 3) 174.7406 Tj -0 -28.4801 Td -(6400 void) 39.3166 Tj -0 -37.9735 Td -(6401 panic\(char *s\)) 83.0018 Tj -0 -47.4668 Td -(6402 {) 26.2111 Tj -0 -56.9602 Td -(6403 int i;) 56.7907 Tj -0 -66.4535 Td -(6404 uint pcs[10];) 87.3703 Tj -0 -75.9469 Td -(6405 ) 21.8426 Tj -0 -85.4403 Td -(6406 cli\(\);) 56.7907 Tj -0 -94.9336 Td -(6407 cons.locking = 0;) 104.8443 Tj -0 -104.427 Td -(6408 cprintf\("cpu%d: panic: ", cpu->id\);) 183.4776 Tj -0 -113.9203 Td -(6409 cprintf\(s\);) 78.6333 Tj -0 -123.4137 Td -(6410 cprintf\("\\n"\);) 91.7388 Tj -0 -132.9071 Td -(6411 getcallerpcs\(&s, pcs\);) 126.6869 Tj -0 -142.4004 Td -(6412 for\(i=0; i<10; i++\)) 113.5814 Tj -0 -151.8938 Td -(6413 cprintf\(" %p", pcs[i]\);) 139.7925 Tj -0 -161.3871 Td -(6414 panicked = 1; // freeze other CPU) 174.7406 Tj -0 -170.8805 Td -(6415 for\(;;\)) 61.1592 Tj -0 -180.3739 Td -(6416 ;) 43.6851 Tj -0 -189.8672 Td -(6417 }) 26.2111 Tj -0 -199.3606 Td -(6418 ) 21.8426 Tj -0 -208.8539 Td -(6419 ) 21.8426 Tj -0 -218.3473 Td -(6420 ) 21.8426 Tj -0 -227.8407 Td -(6421 ) 21.8426 Tj -0 -237.334 Td -(6422 ) 21.8426 Tj -0 -246.8274 Td -(6423 ) 21.8426 Tj -0 -256.3207 Td -(6424 ) 21.8426 Tj -0 -265.8141 Td -(6425 ) 21.8426 Tj -0 -275.3075 Td -(6426 ) 21.8426 Tj -0 -284.8008 Td -(6427 ) 21.8426 Tj -0 -294.2942 Td -(6428 ) 21.8426 Tj -0 -303.7875 Td -(6429 ) 21.8426 Tj -0 -313.2809 Td -(6430 ) 21.8426 Tj -0 -322.7743 Td -(6431 ) 21.8426 Tj -0 -332.2676 Td -(6432 ) 21.8426 Tj -0 -341.761 Td -(6433 ) 21.8426 Tj -0 -351.2543 Td -(6434 ) 21.8426 Tj -0 -360.7477 Td -(6435 ) 21.8426 Tj -0 -370.2411 Td -(6436 ) 21.8426 Tj -0 -379.7344 Td -(6437 ) 21.8426 Tj -0 -389.2278 Td -(6438 ) 21.8426 Tj -0 -398.7211 Td -(6439 ) 21.8426 Tj -0 -408.2145 Td -(6440 ) 21.8426 Tj -0 -417.7079 Td -(6441 ) 21.8426 Tj -0 -427.2012 Td -(6442 ) 21.8426 Tj -0 -436.6946 Td -(6443 ) 21.8426 Tj -0 -446.1879 Td -(6444 ) 21.8426 Tj -0 -455.6813 Td -(6445 ) 21.8426 Tj -0 -465.1747 Td -(6446 ) 21.8426 Tj -0 -474.668 Td -(6447 ) 21.8426 Tj -0 -484.1614 Td -(6448 ) 21.8426 Tj -0 -493.6547 Td -(6449 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 64) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/console.c Page 4) 174.7406 Tj -0 -28.4801 Td -(6450 #define BACKSPACE 0x100) 122.3184 Tj -0 -37.9735 Td -(6451 #define CRTPORT 0x3d4) 113.5814 Tj -0 -47.4668 Td -(6452 static ushort *crt = \(ushort*\)0xb8000; // CGA memory) 253.3738 Tj -0 -56.9602 Td -(6453 ) 21.8426 Tj -0 -66.4535 Td -(6454 static void) 69.8962 Tj -0 -75.9469 Td -(6455 cgaputc\(int c\)) 83.0018 Tj -0 -85.4403 Td -(6456 {) 26.2111 Tj -0 -94.9336 Td -(6457 int pos;) 65.5277 Tj -0 -104.427 Td -(6458 ) 21.8426 Tj -0 -113.9203 Td -(6459 // Cursor position: col + 80*row.) 174.7406 Tj -0 -123.4137 Td -(6460 outb\(CRTPORT, 14\);) 109.2129 Tj -0 -132.9071 Td -(6461 pos = inb\(CRTPORT+1\) << 8;) 144.161 Tj -0 -142.4004 Td -(6462 outb\(CRTPORT, 15\);) 109.2129 Tj -0 -151.8938 Td -(6463 pos |= inb\(CRTPORT+1\);) 126.6869 Tj -0 -161.3871 Td -(6464 ) 21.8426 Tj -0 -170.8805 Td -(6465 if\(c == '\\n'\)) 87.3703 Tj -0 -180.3739 Td -(6466 pos += 80 - pos%80;) 122.3184 Tj -0 -189.8672 Td -(6467 else if\(c == BACKSPACE\){) 135.4239 Tj -0 -199.3606 Td -(6468 if\(pos > 0\)) 87.3703 Tj -0 -208.8539 Td -(6469 crt[--pos] = ' ' | 0x0700;) 161.635 Tj -0 -218.3473 Td -(6470 } else) 56.7907 Tj -0 -227.8407 Td -(6471 crt[pos++] = \(c&0xff\) | 0x0700; // black on white) 257.7424 Tj -0 -237.334 Td -(6472 ) 21.8426 Tj -0 -246.8274 Td -(6473 if\(\(pos/80\) >= 24\){ // Scroll up.) 179.1091 Tj -0 -256.3207 Td -(6474 memmove\(crt, crt+80, sizeof\(crt[0]\)*23*80\);) 227.1628 Tj -0 -265.8141 Td -(6475 pos -= 80;) 83.0018 Tj -0 -275.3075 Td -(6476 memset\(crt+pos, 0, sizeof\(crt[0]\)*\(24*80 - pos\)\)\ -;) 253.3738 Tj -0 -284.8008 Td -(6477 }) 34.9481 Tj -0 -294.2942 Td -(6478 ) 21.8426 Tj -0 -303.7875 Td -(6479 outb\(CRTPORT, 14\);) 109.2129 Tj -0 -313.2809 Td -(6480 outb\(CRTPORT+1, pos>>8\);) 135.4239 Tj -0 -322.7743 Td -(6481 outb\(CRTPORT, 15\);) 109.2129 Tj -0 -332.2676 Td -(6482 outb\(CRTPORT+1, pos\);) 122.3184 Tj -0 -341.761 Td -(6483 crt[pos] = ' ' | 0x0700;) 135.4239 Tj -0 -351.2543 Td -(6484 }) 26.2111 Tj -0 -360.7477 Td -(6485 ) 21.8426 Tj -0 -370.2411 Td -(6486 void) 39.3166 Tj -0 -379.7344 Td -(6487 consputc\(int c\)) 87.3703 Tj -0 -389.2278 Td -(6488 {) 26.2111 Tj -0 -398.7211 Td -(6489 if\(panicked\){) 87.3703 Tj -0 -408.2145 Td -(6490 cli\(\);) 65.5277 Tj -0 -417.7079 Td -(6491 for\(;;\)) 69.8962 Tj -0 -427.2012 Td -(6492 ;) 52.4222 Tj -0 -436.6946 Td -(6493 }) 34.9481 Tj -0 -446.1879 Td -(6494 ) 21.8426 Tj -0 -455.6813 Td -(6495 uartputc\(c\);) 83.0018 Tj -0 -465.1747 Td -(6496 cgaputc\(c\);) 78.6333 Tj -0 -474.668 Td -(6497 }) 26.2111 Tj -0 -484.1614 Td -(6498 ) 21.8426 Tj -0 -493.6547 Td -(6499 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 64) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 72 72 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/console.c Page 5) 174.7406 Tj -0 -28.4801 Td -(6500 #define INPUT_BUF 128) 113.5814 Tj -0 -37.9735 Td -(6501 struct {) 56.7907 Tj -0 -47.4668 Td -(6502 struct spinlock lock;) 122.3184 Tj -0 -56.9602 Td -(6503 char buf[INPUT_BUF];) 117.9499 Tj -0 -66.4535 Td -(6504 uint r; // Read index) 126.6869 Tj -0 -75.9469 Td -(6505 uint w; // Write index) 131.0554 Tj -0 -85.4403 Td -(6506 uint e; // Edit index) 126.6869 Tj -0 -94.9336 Td -(6507 } input;) 56.7907 Tj -0 -104.427 Td -(6508 ) 21.8426 Tj -0 -113.9203 Td -(6509 #define C\(x\) \(\(x\)-'@'\) // Control-x) 183.4776 Tj -0 -123.4137 Td -(6510 ) 21.8426 Tj -0 -132.9071 Td -(6511 void) 39.3166 Tj -0 -142.4004 Td -(6512 consoleintr\(int \(*getc\)\(void\)\)) 152.898 Tj -0 -151.8938 Td -(6513 {) 26.2111 Tj -0 -161.3871 Td -(6514 int c;) 56.7907 Tj -0 -170.8805 Td -(6515 ) 21.8426 Tj -0 -180.3739 Td -(6516 acquire\(&input.lock\);) 122.3184 Tj -0 -189.8672 Td -(6517 while\(\(c = getc\(\)\) >= 0\){) 139.7925 Tj -0 -199.3606 Td -(6518 switch\(c\){) 83.0018 Tj -0 -208.8539 Td -(6519 case C\('P'\): // Process listing.) 183.4776 Tj -0 -218.3473 Td -(6520 procdump\(\);) 96.1073 Tj -0 -227.8407 Td -(6521 break;) 74.2647 Tj -0 -237.334 Td -(6522 case C\('U'\): // Kill line.) 157.2665 Tj -0 -246.8274 Td -(6523 while\(input.e != input.w &&) 166.0035 Tj -0 -256.3207 Td -(6524 input.buf[\(input.e-1\) % INPUT_BUF] != '\\n'\)\ -{) 266.4794 Tj -0 -265.8141 Td -(6525 input.e--;) 100.4758 Tj -0 -275.3075 Td -(6526 consputc\(BACKSPACE\);) 144.161 Tj -0 -284.8008 Td -(6527 }) 52.4222 Tj -0 -294.2942 Td -(6528 break;) 74.2647 Tj -0 -303.7875 Td -(6529 case C\('H'\): // Backspace) 152.898 Tj -0 -313.2809 Td -(6530 if\(input.e != input.w\){) 148.5295 Tj -0 -322.7743 Td -(6531 input.e--;) 100.4758 Tj -0 -332.2676 Td -(6532 consputc\(BACKSPACE\);) 144.161 Tj -0 -341.761 Td -(6533 }) 52.4222 Tj -0 -351.2543 Td -(6534 break;) 74.2647 Tj -0 -360.7477 Td -(6535 default:) 74.2647 Tj -0 -370.2411 Td -(6536 if\(c != 0 && input.e-input.r < INPUT_BUF\){) 231.5313 Tj -0 -379.7344 Td -(6537 input.buf[input.e++ % INPUT_BUF] = c;) 218.4257 Tj -0 -389.2278 Td -(6538 consputc\(c\);) 109.2129 Tj -0 -398.7211 Td -(6539 if\(c == '\\n' || c == C\('D'\) || input.e == inpu\ -t.r+INPUT_BUF\){) 323.2701 Tj -0 -408.2145 Td -(6540 input.w = input.e;) 144.161 Tj -0 -417.7079 Td -(6541 wakeup\(&input.r\);) 139.7925 Tj -0 -427.2012 Td -(6542 }) 61.1592 Tj -0 -436.6946 Td -(6543 }) 52.4222 Tj -0 -446.1879 Td -(6544 break;) 74.2647 Tj -0 -455.6813 Td -(6545 }) 43.6851 Tj -0 -465.1747 Td -(6546 }) 34.9481 Tj -0 -474.668 Td -(6547 release\(&input.lock\);) 122.3184 Tj -0 -484.1614 Td -(6548 }) 26.2111 Tj -0 -493.6547 Td -(6549 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 65) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/console.c Page 6) 174.7406 Tj -0 -28.4801 Td -(6550 int) 34.9481 Tj -0 -37.9735 Td -(6551 consoleread\(struct inode *ip, char *dst, int n\)) 227.1628 Tj -0 -47.4668 Td -(6552 {) 26.2111 Tj -0 -56.9602 Td -(6553 uint target;) 83.0018 Tj -0 -66.4535 Td -(6554 int c;) 56.7907 Tj -0 -75.9469 Td -(6555 ) 21.8426 Tj -0 -85.4403 Td -(6556 iunlock\(ip\);) 83.0018 Tj -0 -94.9336 Td -(6557 target = n;) 78.6333 Tj -0 -104.427 Td -(6558 acquire\(&input.lock\);) 122.3184 Tj -0 -113.9203 Td -(6559 while\(n > 0\){) 87.3703 Tj -0 -123.4137 Td -(6560 while\(input.r == input.w\){) 152.898 Tj -0 -132.9071 Td -(6561 if\(proc->killed\){) 122.3184 Tj -0 -142.4004 Td -(6562 release\(&input.lock\);) 148.5295 Tj -0 -151.8938 Td -(6563 ilock\(ip\);) 100.4758 Tj -0 -161.3871 Td -(6564 return -1;) 100.4758 Tj -0 -170.8805 Td -(6565 }) 52.4222 Tj -0 -180.3739 Td -(6566 sleep\(&input.r, &input.lock\);) 174.7406 Tj -0 -189.8672 Td -(6567 }) 43.6851 Tj -0 -199.3606 Td -(6568 c = input.buf[input.r++ % INPUT_BUF];) 200.9517 Tj -0 -208.8539 Td -(6569 if\(c == C\('D'\)\){ // EOF) 144.161 Tj -0 -218.3473 Td -(6570 if\(n < target\){) 113.5814 Tj -0 -227.8407 Td -(6571 // Save ^D for next time, to make sure) 222.7942 Tj -0 -237.334 Td -(6572 // caller gets a 0-byte result.) 192.2146 Tj -0 -246.8274 Td -(6573 input.r--;) 100.4758 Tj -0 -256.3207 Td -(6574 }) 52.4222 Tj -0 -265.8141 Td -(6575 break;) 74.2647 Tj -0 -275.3075 Td -(6576 }) 43.6851 Tj -0 -284.8008 Td -(6577 *dst++ = c;) 87.3703 Tj -0 -294.2942 Td -(6578 --n;) 56.7907 Tj -0 -303.7875 Td -(6579 if\(c == '\\n'\)) 96.1073 Tj -0 -313.2809 Td -(6580 break;) 74.2647 Tj -0 -322.7743 Td -(6581 }) 34.9481 Tj -0 -332.2676 Td -(6582 release\(&input.lock\);) 122.3184 Tj -0 -341.761 Td -(6583 ilock\(ip\);) 74.2647 Tj -0 -351.2543 Td -(6584 ) 21.8426 Tj -0 -360.7477 Td -(6585 return target - n;) 109.2129 Tj -0 -370.2411 Td -(6586 }) 26.2111 Tj -0 -379.7344 Td -(6587 ) 21.8426 Tj -0 -389.2278 Td -(6588 ) 21.8426 Tj -0 -398.7211 Td -(6589 ) 21.8426 Tj -0 -408.2145 Td -(6590 ) 21.8426 Tj -0 -417.7079 Td -(6591 ) 21.8426 Tj -0 -427.2012 Td -(6592 ) 21.8426 Tj -0 -436.6946 Td -(6593 ) 21.8426 Tj -0 -446.1879 Td -(6594 ) 21.8426 Tj -0 -455.6813 Td -(6595 ) 21.8426 Tj -0 -465.1747 Td -(6596 ) 21.8426 Tj -0 -474.668 Td -(6597 ) 21.8426 Tj -0 -484.1614 Td -(6598 ) 21.8426 Tj -0 -493.6547 Td -(6599 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 65) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 73 73 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/console.c Page 7) 174.7406 Tj -0 -28.4801 Td -(6600 int) 34.9481 Tj -0 -37.9735 Td -(6601 consolewrite\(struct inode *ip, char *buf, int n\)) 231.5313 Tj -0 -47.4668 Td -(6602 {) 26.2111 Tj -0 -56.9602 Td -(6603 int i;) 56.7907 Tj -0 -66.4535 Td -(6604 ) 21.8426 Tj -0 -75.9469 Td -(6605 iunlock\(ip\);) 83.0018 Tj -0 -85.4403 Td -(6606 acquire\(&cons.lock\);) 117.9499 Tj -0 -94.9336 Td -(6607 for\(i = 0; i < n; i++\)) 126.6869 Tj -0 -104.427 Td -(6608 consputc\(buf[i] & 0xff\);) 144.161 Tj -0 -113.9203 Td -(6609 release\(&cons.lock\);) 117.9499 Tj -0 -123.4137 Td -(6610 ilock\(ip\);) 74.2647 Tj -0 -132.9071 Td -(6611 ) 21.8426 Tj -0 -142.4004 Td -(6612 return n;) 69.8962 Tj -0 -151.8938 Td -(6613 }) 26.2111 Tj -0 -161.3871 Td -(6614 ) 21.8426 Tj -0 -170.8805 Td -(6615 void) 39.3166 Tj -0 -180.3739 Td -(6616 consoleinit\(void\)) 96.1073 Tj -0 -189.8672 Td -(6617 {) 26.2111 Tj -0 -199.3606 Td -(6618 initlock\(&cons.lock, "console"\);) 170.3721 Tj -0 -208.8539 Td -(6619 initlock\(&input.lock, "input"\);) 166.0035 Tj -0 -218.3473 Td -(6620 ) 21.8426 Tj -0 -227.8407 Td -(6621 devsw[CONSOLE].write = consolewrite;) 187.8461 Tj -0 -237.334 Td -(6622 devsw[CONSOLE].read = consoleread;) 179.1091 Tj -0 -246.8274 Td -(6623 cons.locking = 1;) 104.8443 Tj -0 -256.3207 Td -(6624 ) 21.8426 Tj -0 -265.8141 Td -(6625 picenable\(IRQ_KBD\);) 113.5814 Tj -0 -275.3075 Td -(6626 ioapicenable\(IRQ_KBD, 0\);) 139.7925 Tj -0 -284.8008 Td -(6627 }) 26.2111 Tj -0 -294.2942 Td -(6628 ) 21.8426 Tj -0 -303.7875 Td -(6629 ) 21.8426 Tj -0 -313.2809 Td -(6630 ) 21.8426 Tj -0 -322.7743 Td -(6631 ) 21.8426 Tj -0 -332.2676 Td -(6632 ) 21.8426 Tj -0 -341.761 Td -(6633 ) 21.8426 Tj -0 -351.2543 Td -(6634 ) 21.8426 Tj -0 -360.7477 Td -(6635 ) 21.8426 Tj -0 -370.2411 Td -(6636 ) 21.8426 Tj -0 -379.7344 Td -(6637 ) 21.8426 Tj -0 -389.2278 Td -(6638 ) 21.8426 Tj -0 -398.7211 Td -(6639 ) 21.8426 Tj -0 -408.2145 Td -(6640 ) 21.8426 Tj -0 -417.7079 Td -(6641 ) 21.8426 Tj -0 -427.2012 Td -(6642 ) 21.8426 Tj -0 -436.6946 Td -(6643 ) 21.8426 Tj -0 -446.1879 Td -(6644 ) 21.8426 Tj -0 -455.6813 Td -(6645 ) 21.8426 Tj -0 -465.1747 Td -(6646 ) 21.8426 Tj -0 -474.668 Td -(6647 ) 21.8426 Tj -0 -484.1614 Td -(6648 ) 21.8426 Tj -0 -493.6547 Td -(6649 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 66) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/timer.c Page 1) 166.0035 Tj -0 -28.4801 Td -(6650 // Intel 8253/8254/82C54 Programmable Interval Timer \(PIT\ -\).) 279.5849 Tj -0 -37.9735 Td -(6651 // Only used on uniprocessors;) 152.898 Tj -0 -47.4668 Td -(6652 // SMP machines use the local APIC timer.) 200.9517 Tj -0 -56.9602 Td -(6653 ) 21.8426 Tj -0 -66.4535 Td -(6654 #include "types.h") 100.4758 Tj -0 -75.9469 Td -(6655 #include "defs.h") 96.1073 Tj -0 -85.4403 Td -(6656 #include "traps.h") 100.4758 Tj -0 -94.9336 Td -(6657 #include "x86.h") 91.7388 Tj -0 -104.427 Td -(6658 ) 21.8426 Tj -0 -113.9203 Td -(6659 #define IO_TIMER1 0x040 // 8253 Timer #1) 266.4794 Tj -0 -123.4137 Td -(6660 ) 21.8426 Tj -0 -132.9071 Td -(6661 // Frequency of all three count-down timers;) 214.0572 Tj -0 -142.4004 Td -(6662 // \(TIMER_FREQ/freq\) is the appropriate count) 218.4257 Tj -0 -151.8938 Td -(6663 // to generate a frequency of freq Hz.) 187.8461 Tj -0 -161.3871 Td -(6664 ) 21.8426 Tj -0 -170.8805 Td -(6665 #define TIMER_FREQ 1193182) 157.2665 Tj -0 -180.3739 Td -(6666 #define TIMER_DIV\(x\) \(\(TIMER_FREQ+\(x\)/2\)/\(x\)\)) 231.5313 Tj -0 -189.8672 Td -(6667 ) 21.8426 Tj -0 -199.3606 Td -(6668 #define TIMER_MODE \(IO_TIMER1 + 3\) // timer mode po\ -rt) 275.2164 Tj -0 -208.8539 Td -(6669 #define TIMER_SEL0 0x00 // select counter 0) 244.6368 Tj -0 -218.3473 Td -(6670 #define TIMER_RATEGEN 0x04 // mode 2, rate generator) 270.8479 Tj -0 -227.8407 Td -(6671 #define TIMER_16BIT 0x30 // r/w counter 16 bits, LS\ -B first) 305.796 Tj -0 -237.334 Td -(6672 ) 21.8426 Tj -0 -246.8274 Td -(6673 void) 39.3166 Tj -0 -256.3207 Td -(6674 timerinit\(void\)) 87.3703 Tj -0 -265.8141 Td -(6675 {) 26.2111 Tj -0 -275.3075 Td -(6676 // Interrupt 100 times/sec.) 148.5295 Tj -0 -284.8008 Td -(6677 outb\(TIMER_MODE, TIMER_SEL0 | TIMER_RATEGEN | TIMER_16B\ -IT\);) 288.322 Tj -0 -294.2942 Td -(6678 outb\(IO_TIMER1, TIMER_DIV\(100\) % 256\);) 196.5831 Tj -0 -303.7875 Td -(6679 outb\(IO_TIMER1, TIMER_DIV\(100\) / 256\);) 196.5831 Tj -0 -313.2809 Td -(6680 picenable\(IRQ_TIMER\);) 122.3184 Tj -0 -322.7743 Td -(6681 }) 26.2111 Tj -0 -332.2676 Td -(6682 ) 21.8426 Tj -0 -341.761 Td -(6683 ) 21.8426 Tj -0 -351.2543 Td -(6684 ) 21.8426 Tj -0 -360.7477 Td -(6685 ) 21.8426 Tj -0 -370.2411 Td -(6686 ) 21.8426 Tj -0 -379.7344 Td -(6687 ) 21.8426 Tj -0 -389.2278 Td -(6688 ) 21.8426 Tj -0 -398.7211 Td -(6689 ) 21.8426 Tj -0 -408.2145 Td -(6690 ) 21.8426 Tj -0 -417.7079 Td -(6691 ) 21.8426 Tj -0 -427.2012 Td -(6692 ) 21.8426 Tj -0 -436.6946 Td -(6693 ) 21.8426 Tj -0 -446.1879 Td -(6694 ) 21.8426 Tj -0 -455.6813 Td -(6695 ) 21.8426 Tj -0 -465.1747 Td -(6696 ) 21.8426 Tj -0 -474.668 Td -(6697 ) 21.8426 Tj -0 -484.1614 Td -(6698 ) 21.8426 Tj -0 -493.6547 Td -(6699 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 66) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 74 74 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/initcode.S Page 1) 179.1091 Tj -0 -28.4801 Td -(6700 # Initial process execs /init.) 152.898 Tj -0 -37.9735 Td -(6701 ) 21.8426 Tj -0 -47.4668 Td -(6702 #include "syscall.h") 109.2129 Tj -0 -56.9602 Td -(6703 #include "traps.h") 100.4758 Tj -0 -66.4535 Td -(6704 ) 21.8426 Tj -0 -75.9469 Td -(6705 # exec\(init, argv\)) 100.4758 Tj -0 -85.4403 Td -(6706 .globl start) 74.2647 Tj -0 -94.9336 Td -(6707 start:) 48.0537 Tj -0 -104.427 Td -(6708 pushl $argv) 78.6333 Tj -0 -113.9203 Td -(6709 pushl $init) 78.6333 Tj -0 -123.4137 Td -(6710 pushl $0 // where caller pc would be) 192.2146 Tj -0 -132.9071 Td -(6711 movl $SYS_exec, %eax) 117.9499 Tj -0 -142.4004 Td -(6712 int $T_SYSCALL) 91.7388 Tj -0 -151.8938 Td -(6713 ) 21.8426 Tj -0 -161.3871 Td -(6714 # for\(;;\) exit\(\);) 96.1073 Tj -0 -170.8805 Td -(6715 exit:) 43.6851 Tj -0 -180.3739 Td -(6716 movl $SYS_exit, %eax) 117.9499 Tj -0 -189.8672 Td -(6717 int $T_SYSCALL) 91.7388 Tj -0 -199.3606 Td -(6718 jmp exit) 65.5277 Tj -0 -208.8539 Td -(6719 ) 21.8426 Tj -0 -218.3473 Td -(6720 # char init[] = "/init\\0";) 135.4239 Tj -0 -227.8407 Td -(6721 init:) 43.6851 Tj -0 -237.334 Td -(6722 .string "/init\\0") 104.8443 Tj -0 -246.8274 Td -(6723 ) 21.8426 Tj -0 -256.3207 Td -(6724 # char *argv[] = { init, 0 };) 148.5295 Tj -0 -265.8141 Td -(6725 .p2align 2) 65.5277 Tj -0 -275.3075 Td -(6726 argv:) 43.6851 Tj -0 -284.8008 Td -(6727 .long init) 74.2647 Tj -0 -294.2942 Td -(6728 .long 0) 61.1592 Tj -0 -303.7875 Td -(6729 ) 21.8426 Tj -0 -313.2809 Td -(6730 ) 21.8426 Tj -0 -322.7743 Td -(6731 ) 21.8426 Tj -0 -332.2676 Td -(6732 ) 21.8426 Tj -0 -341.761 Td -(6733 ) 21.8426 Tj -0 -351.2543 Td -(6734 ) 21.8426 Tj -0 -360.7477 Td -(6735 ) 21.8426 Tj -0 -370.2411 Td -(6736 ) 21.8426 Tj -0 -379.7344 Td -(6737 ) 21.8426 Tj -0 -389.2278 Td -(6738 ) 21.8426 Tj -0 -398.7211 Td -(6739 ) 21.8426 Tj -0 -408.2145 Td -(6740 ) 21.8426 Tj -0 -417.7079 Td -(6741 ) 21.8426 Tj -0 -427.2012 Td -(6742 ) 21.8426 Tj -0 -436.6946 Td -(6743 ) 21.8426 Tj -0 -446.1879 Td -(6744 ) 21.8426 Tj -0 -455.6813 Td -(6745 ) 21.8426 Tj -0 -465.1747 Td -(6746 ) 21.8426 Tj -0 -474.668 Td -(6747 ) 21.8426 Tj -0 -484.1614 Td -(6748 ) 21.8426 Tj -0 -493.6547 Td -(6749 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 67) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/usys.S Page 1) 161.635 Tj -0 -28.4801 Td -(6750 #include "syscall.h") 109.2129 Tj -0 -37.9735 Td -(6751 #include "traps.h") 100.4758 Tj -0 -47.4668 Td -(6752 ) 21.8426 Tj -0 -56.9602 Td -(6753 #define SYSCALL\(name\) \\) 122.3184 Tj -0 -66.4535 Td -(6754 .globl name; \\) 91.7388 Tj -0 -75.9469 Td -(6755 name: \\) 61.1592 Tj -0 -85.4403 Td -(6756 movl $SYS_ ## name, %eax; \\) 157.2665 Tj -0 -94.9336 Td -(6757 int $T_SYSCALL; \\) 113.5814 Tj -0 -104.427 Td -(6758 ret) 52.4222 Tj -0 -113.9203 Td -(6759 ) 21.8426 Tj -0 -123.4137 Td -(6760 SYSCALL\(fork\)) 78.6333 Tj -0 -132.9071 Td -(6761 SYSCALL\(exit\)) 78.6333 Tj -0 -142.4004 Td -(6762 SYSCALL\(wait\)) 78.6333 Tj -0 -151.8938 Td -(6763 SYSCALL\(pipe\)) 78.6333 Tj -0 -161.3871 Td -(6764 SYSCALL\(read\)) 78.6333 Tj -0 -170.8805 Td -(6765 SYSCALL\(write\)) 83.0018 Tj -0 -180.3739 Td -(6766 SYSCALL\(close\)) 83.0018 Tj -0 -189.8672 Td -(6767 SYSCALL\(kill\)) 78.6333 Tj -0 -199.3606 Td -(6768 SYSCALL\(exec\)) 78.6333 Tj -0 -208.8539 Td -(6769 SYSCALL\(open\)) 78.6333 Tj -0 -218.3473 Td -(6770 SYSCALL\(mknod\)) 83.0018 Tj -0 -227.8407 Td -(6771 SYSCALL\(unlink\)) 87.3703 Tj -0 -237.334 Td -(6772 SYSCALL\(fstat\)) 83.0018 Tj -0 -246.8274 Td -(6773 SYSCALL\(link\)) 78.6333 Tj -0 -256.3207 Td -(6774 SYSCALL\(mkdir\)) 83.0018 Tj -0 -265.8141 Td -(6775 SYSCALL\(chdir\)) 83.0018 Tj -0 -275.3075 Td -(6776 SYSCALL\(dup\)) 74.2647 Tj -0 -284.8008 Td -(6777 SYSCALL\(getpid\)) 87.3703 Tj -0 -294.2942 Td -(6778 SYSCALL\(sbrk\)) 78.6333 Tj -0 -303.7875 Td -(6779 SYSCALL\(sleep\)) 83.0018 Tj -0 -313.2809 Td -(6780 ) 21.8426 Tj -0 -322.7743 Td -(6781 ) 21.8426 Tj -0 -332.2676 Td -(6782 ) 21.8426 Tj -0 -341.761 Td -(6783 ) 21.8426 Tj -0 -351.2543 Td -(6784 ) 21.8426 Tj -0 -360.7477 Td -(6785 ) 21.8426 Tj -0 -370.2411 Td -(6786 ) 21.8426 Tj -0 -379.7344 Td -(6787 ) 21.8426 Tj -0 -389.2278 Td -(6788 ) 21.8426 Tj -0 -398.7211 Td -(6789 ) 21.8426 Tj -0 -408.2145 Td -(6790 ) 21.8426 Tj -0 -417.7079 Td -(6791 ) 21.8426 Tj -0 -427.2012 Td -(6792 ) 21.8426 Tj -0 -436.6946 Td -(6793 ) 21.8426 Tj -0 -446.1879 Td -(6794 ) 21.8426 Tj -0 -455.6813 Td -(6795 ) 21.8426 Tj -0 -465.1747 Td -(6796 ) 21.8426 Tj -0 -474.668 Td -(6797 ) 21.8426 Tj -0 -484.1614 Td -(6798 ) 21.8426 Tj -0 -493.6547 Td -(6799 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 67) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 75 75 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/init.c Page 1) 161.635 Tj -0 -28.4801 Td -(6800 // init: The initial user-level program) 192.2146 Tj -0 -37.9735 Td -(6801 ) 21.8426 Tj -0 -47.4668 Td -(6802 #include "types.h") 100.4758 Tj -0 -56.9602 Td -(6803 #include "stat.h") 96.1073 Tj -0 -66.4535 Td -(6804 #include "user.h") 96.1073 Tj -0 -75.9469 Td -(6805 #include "fcntl.h") 100.4758 Tj -0 -85.4403 Td -(6806 ) 21.8426 Tj -0 -94.9336 Td -(6807 char *argv[] = { "sh", 0 };) 139.7925 Tj -0 -104.427 Td -(6808 ) 21.8426 Tj -0 -113.9203 Td -(6809 int) 34.9481 Tj -0 -123.4137 Td -(6810 main\(void\)) 65.5277 Tj -0 -132.9071 Td -(6811 {) 26.2111 Tj -0 -142.4004 Td -(6812 int pid, wpid;) 91.7388 Tj -0 -151.8938 Td -(6813 ) 21.8426 Tj -0 -161.3871 Td -(6814 if\(open\("console", O_RDWR\) < 0\){) 170.3721 Tj -0 -170.8805 Td -(6815 mknod\("console", 1, 1\);) 139.7925 Tj -0 -180.3739 Td -(6816 open\("console", O_RDWR\);) 144.161 Tj -0 -189.8672 Td -(6817 }) 34.9481 Tj -0 -199.3606 Td -(6818 dup\(0\); // stdout) 109.2129 Tj -0 -208.8539 Td -(6819 dup\(0\); // stderr) 109.2129 Tj -0 -218.3473 Td -(6820 ) 21.8426 Tj -0 -227.8407 Td -(6821 for\(;;\){) 65.5277 Tj -0 -237.334 Td -(6822 printf\(1, "init: starting sh\\n"\);) 183.4776 Tj -0 -246.8274 Td -(6823 pid = fork\(\);) 96.1073 Tj -0 -256.3207 Td -(6824 if\(pid < 0\){) 91.7388 Tj -0 -265.8141 Td -(6825 printf\(1, "init: fork failed\\n"\);) 192.2146 Tj -0 -275.3075 Td -(6826 exit\(\);) 78.6333 Tj -0 -284.8008 Td -(6827 }) 43.6851 Tj -0 -294.2942 Td -(6828 if\(pid == 0\){) 96.1073 Tj -0 -303.7875 Td -(6829 exec\("sh", argv\);) 122.3184 Tj -0 -313.2809 Td -(6830 printf\(1, "init: exec sh failed\\n"\);) 205.3202 Tj -0 -322.7743 Td -(6831 exit\(\);) 78.6333 Tj -0 -332.2676 Td -(6832 }) 43.6851 Tj -0 -341.761 Td -(6833 while\(\(wpid=wait\(\)\) >= 0 && wpid != pid\)) 214.0572 Tj -0 -351.2543 Td -(6834 printf\(1, "zombie!\\n"\);) 148.5295 Tj -0 -360.7477 Td -(6835 }) 34.9481 Tj -0 -370.2411 Td -(6836 }) 26.2111 Tj -0 -379.7344 Td -(6837 ) 21.8426 Tj -0 -389.2278 Td -(6838 ) 21.8426 Tj -0 -398.7211 Td -(6839 ) 21.8426 Tj -0 -408.2145 Td -(6840 ) 21.8426 Tj -0 -417.7079 Td -(6841 ) 21.8426 Tj -0 -427.2012 Td -(6842 ) 21.8426 Tj -0 -436.6946 Td -(6843 ) 21.8426 Tj -0 -446.1879 Td -(6844 ) 21.8426 Tj -0 -455.6813 Td -(6845 ) 21.8426 Tj -0 -465.1747 Td -(6846 ) 21.8426 Tj -0 -474.668 Td -(6847 ) 21.8426 Tj -0 -484.1614 Td -(6848 ) 21.8426 Tj -0 -493.6547 Td -(6849 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 68) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sh.c Page 1) 152.898 Tj -0 -28.4801 Td -(6850 // Shell.) 61.1592 Tj -0 -37.9735 Td -(6851 ) 21.8426 Tj -0 -47.4668 Td -(6852 #include "types.h") 100.4758 Tj -0 -56.9602 Td -(6853 #include "user.h") 96.1073 Tj -0 -66.4535 Td -(6854 #include "fcntl.h") 100.4758 Tj -0 -75.9469 Td -(6855 ) 21.8426 Tj -0 -85.4403 Td -(6856 // Parsed command representation) 161.635 Tj -0 -94.9336 Td -(6857 #define EXEC 1) 87.3703 Tj -0 -104.427 Td -(6858 #define REDIR 2) 87.3703 Tj -0 -113.9203 Td -(6859 #define PIPE 3) 87.3703 Tj -0 -123.4137 Td -(6860 #define LIST 4) 87.3703 Tj -0 -132.9071 Td -(6861 #define BACK 5) 87.3703 Tj -0 -142.4004 Td -(6862 ) 21.8426 Tj -0 -151.8938 Td -(6863 #define MAXARGS 10) 100.4758 Tj -0 -161.3871 Td -(6864 ) 21.8426 Tj -0 -170.8805 Td -(6865 struct cmd {) 74.2647 Tj -0 -180.3739 Td -(6866 int type;) 69.8962 Tj -0 -189.8672 Td -(6867 };) 30.5796 Tj -0 -199.3606 Td -(6868 ) 21.8426 Tj -0 -208.8539 Td -(6869 struct execcmd {) 91.7388 Tj -0 -218.3473 Td -(6870 int type;) 69.8962 Tj -0 -227.8407 Td -(6871 char *argv[MAXARGS];) 117.9499 Tj -0 -237.334 Td -(6872 char *eargv[MAXARGS];) 122.3184 Tj -0 -246.8274 Td -(6873 };) 30.5796 Tj -0 -256.3207 Td -(6874 ) 21.8426 Tj -0 -265.8141 Td -(6875 struct redircmd {) 96.1073 Tj -0 -275.3075 Td -(6876 int type;) 69.8962 Tj -0 -284.8008 Td -(6877 struct cmd *cmd;) 100.4758 Tj -0 -294.2942 Td -(6878 char *file;) 78.6333 Tj -0 -303.7875 Td -(6879 char *efile;) 83.0018 Tj -0 -313.2809 Td -(6880 int mode;) 69.8962 Tj -0 -322.7743 Td -(6881 int fd;) 61.1592 Tj -0 -332.2676 Td -(6882 };) 30.5796 Tj -0 -341.761 Td -(6883 ) 21.8426 Tj -0 -351.2543 Td -(6884 struct pipecmd {) 91.7388 Tj -0 -360.7477 Td -(6885 int type;) 69.8962 Tj -0 -370.2411 Td -(6886 struct cmd *left;) 104.8443 Tj -0 -379.7344 Td -(6887 struct cmd *right;) 109.2129 Tj -0 -389.2278 Td -(6888 };) 30.5796 Tj -0 -398.7211 Td -(6889 ) 21.8426 Tj -0 -408.2145 Td -(6890 struct listcmd {) 91.7388 Tj -0 -417.7079 Td -(6891 int type;) 69.8962 Tj -0 -427.2012 Td -(6892 struct cmd *left;) 104.8443 Tj -0 -436.6946 Td -(6893 struct cmd *right;) 109.2129 Tj -0 -446.1879 Td -(6894 };) 30.5796 Tj -0 -455.6813 Td -(6895 ) 21.8426 Tj -0 -465.1747 Td -(6896 struct backcmd {) 91.7388 Tj -0 -474.668 Td -(6897 int type;) 69.8962 Tj -0 -484.1614 Td -(6898 struct cmd *cmd;) 100.4758 Tj -0 -493.6547 Td -(6899 };) 30.5796 Tj -0 -522.1348 Td -(Sheet 68) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 76 76 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sh.c Page 2) 152.898 Tj -0 -28.4801 Td -(6900 int fork1\(void\); // Fork but panics on failure.) 231.5313 Tj -0 -37.9735 Td -(6901 void panic\(char*\);) 100.4758 Tj -0 -47.4668 Td -(6902 struct cmd *parsecmd\(char*\);) 144.161 Tj -0 -56.9602 Td -(6903 ) 21.8426 Tj -0 -66.4535 Td -(6904 // Execute cmd. Never returns.) 157.2665 Tj -0 -75.9469 Td -(6905 void) 39.3166 Tj -0 -85.4403 Td -(6906 runcmd\(struct cmd *cmd\)) 122.3184 Tj -0 -94.9336 Td -(6907 {) 26.2111 Tj -0 -104.427 Td -(6908 int p[2];) 69.8962 Tj -0 -113.9203 Td -(6909 struct backcmd *bcmd;) 122.3184 Tj -0 -123.4137 Td -(6910 struct execcmd *ecmd;) 122.3184 Tj -0 -132.9071 Td -(6911 struct listcmd *lcmd;) 122.3184 Tj -0 -142.4004 Td -(6912 struct pipecmd *pcmd;) 122.3184 Tj -0 -151.8938 Td -(6913 struct redircmd *rcmd;) 126.6869 Tj -0 -161.3871 Td -(6914 ) 21.8426 Tj -0 -170.8805 Td -(6915 if\(cmd == 0\)) 83.0018 Tj -0 -180.3739 Td -(6916 exit\(\);) 69.8962 Tj -0 -189.8672 Td -(6917 ) 21.8426 Tj -0 -199.3606 Td -(6918 switch\(cmd->type\){) 109.2129 Tj -0 -208.8539 Td -(6919 default:) 65.5277 Tj -0 -218.3473 Td -(6920 panic\("runcmd"\);) 109.2129 Tj -0 -227.8407 Td -(6921 ) 21.8426 Tj -0 -237.334 Td -(6922 case EXEC:) 74.2647 Tj -0 -246.8274 Td -(6923 ecmd = \(struct execcmd*\)cmd;) 161.635 Tj -0 -256.3207 Td -(6924 if\(ecmd->argv[0] == 0\)) 135.4239 Tj -0 -265.8141 Td -(6925 exit\(\);) 78.6333 Tj -0 -275.3075 Td -(6926 exec\(ecmd->argv[0], ecmd->argv\);) 179.1091 Tj -0 -284.8008 Td -(6927 printf\(2, "exec %s failed\\n", ecmd->argv[0]\);) 235.8998 Tj -0 -294.2942 Td -(6928 break;) 65.5277 Tj -0 -303.7875 Td -(6929 ) 21.8426 Tj -0 -313.2809 Td -(6930 case REDIR:) 78.6333 Tj -0 -322.7743 Td -(6931 rcmd = \(struct redircmd*\)cmd;) 166.0035 Tj -0 -332.2676 Td -(6932 close\(rcmd->fd\);) 109.2129 Tj -0 -341.761 Td -(6933 if\(open\(rcmd->file, rcmd->mode\) < 0\){) 200.9517 Tj -0 -351.2543 Td -(6934 printf\(2, "open %s failed\\n", rcmd->file\);) 231.5313 Tj -0 -360.7477 Td -(6935 exit\(\);) 78.6333 Tj -0 -370.2411 Td -(6936 }) 43.6851 Tj -0 -379.7344 Td -(6937 runcmd\(rcmd->cmd\);) 117.9499 Tj -0 -389.2278 Td -(6938 break;) 65.5277 Tj -0 -398.7211 Td -(6939 ) 21.8426 Tj -0 -408.2145 Td -(6940 case LIST:) 74.2647 Tj -0 -417.7079 Td -(6941 lcmd = \(struct listcmd*\)cmd;) 161.635 Tj -0 -427.2012 Td -(6942 if\(fork1\(\) == 0\)) 109.2129 Tj -0 -436.6946 Td -(6943 runcmd\(lcmd->left\);) 131.0554 Tj -0 -446.1879 Td -(6944 wait\(\);) 69.8962 Tj -0 -455.6813 Td -(6945 runcmd\(lcmd->right\);) 126.6869 Tj -0 -465.1747 Td -(6946 break;) 65.5277 Tj -0 -474.668 Td -(6947 ) 21.8426 Tj -0 -484.1614 Td -(6948 ) 21.8426 Tj -0 -493.6547 Td -(6949 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 69) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sh.c Page 3) 152.898 Tj -0 -28.4801 Td -(6950 case PIPE:) 74.2647 Tj -0 -37.9735 Td -(6951 pcmd = \(struct pipecmd*\)cmd;) 161.635 Tj -0 -47.4668 Td -(6952 if\(pipe\(p\) < 0\)) 104.8443 Tj -0 -56.9602 Td -(6953 panic\("pipe"\);) 109.2129 Tj -0 -66.4535 Td -(6954 if\(fork1\(\) == 0\){) 113.5814 Tj -0 -75.9469 Td -(6955 close\(1\);) 87.3703 Tj -0 -85.4403 Td -(6956 dup\(p[1]\);) 91.7388 Tj -0 -94.9336 Td -(6957 close\(p[0]\);) 100.4758 Tj -0 -104.427 Td -(6958 close\(p[1]\);) 100.4758 Tj -0 -113.9203 Td -(6959 runcmd\(pcmd->left\);) 131.0554 Tj -0 -123.4137 Td -(6960 }) 43.6851 Tj -0 -132.9071 Td -(6961 if\(fork1\(\) == 0\){) 113.5814 Tj -0 -142.4004 Td -(6962 close\(0\);) 87.3703 Tj -0 -151.8938 Td -(6963 dup\(p[0]\);) 91.7388 Tj -0 -161.3871 Td -(6964 close\(p[0]\);) 100.4758 Tj -0 -170.8805 Td -(6965 close\(p[1]\);) 100.4758 Tj -0 -180.3739 Td -(6966 runcmd\(pcmd->right\);) 135.4239 Tj -0 -189.8672 Td -(6967 }) 43.6851 Tj -0 -199.3606 Td -(6968 close\(p[0]\);) 91.7388 Tj -0 -208.8539 Td -(6969 close\(p[1]\);) 91.7388 Tj -0 -218.3473 Td -(6970 wait\(\);) 69.8962 Tj -0 -227.8407 Td -(6971 wait\(\);) 69.8962 Tj -0 -237.334 Td -(6972 break;) 65.5277 Tj -0 -246.8274 Td -(6973 ) 21.8426 Tj -0 -256.3207 Td -(6974 case BACK:) 74.2647 Tj -0 -265.8141 Td -(6975 bcmd = \(struct backcmd*\)cmd;) 161.635 Tj -0 -275.3075 Td -(6976 if\(fork1\(\) == 0\)) 109.2129 Tj -0 -284.8008 Td -(6977 runcmd\(bcmd->cmd\);) 126.6869 Tj -0 -294.2942 Td -(6978 break;) 65.5277 Tj -0 -303.7875 Td -(6979 }) 34.9481 Tj -0 -313.2809 Td -(6980 exit\(\);) 61.1592 Tj -0 -322.7743 Td -(6981 }) 26.2111 Tj -0 -332.2676 Td -(6982 ) 21.8426 Tj -0 -341.761 Td -(6983 int) 34.9481 Tj -0 -351.2543 Td -(6984 getcmd\(char *buf, int nbuf\)) 139.7925 Tj -0 -360.7477 Td -(6985 {) 26.2111 Tj -0 -370.2411 Td -(6986 printf\(2, "$ "\);) 100.4758 Tj -0 -379.7344 Td -(6987 memset\(buf, 0, nbuf\);) 122.3184 Tj -0 -389.2278 Td -(6988 gets\(buf, nbuf\);) 100.4758 Tj -0 -398.7211 Td -(6989 if\(buf[0] == 0\) // EOF) 126.6869 Tj -0 -408.2145 Td -(6990 return -1;) 83.0018 Tj -0 -417.7079 Td -(6991 return 0;) 69.8962 Tj -0 -427.2012 Td -(6992 }) 26.2111 Tj -0 -436.6946 Td -(6993 ) 21.8426 Tj -0 -446.1879 Td -(6994 ) 21.8426 Tj -0 -455.6813 Td -(6995 ) 21.8426 Tj -0 -465.1747 Td -(6996 ) 21.8426 Tj -0 -474.668 Td -(6997 ) 21.8426 Tj -0 -484.1614 Td -(6998 ) 21.8426 Tj -0 -493.6547 Td -(6999 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 69) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 77 77 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sh.c Page 4) 152.898 Tj -0 -28.4801 Td -(7000 int) 34.9481 Tj -0 -37.9735 Td -(7001 main\(void\)) 65.5277 Tj -0 -47.4668 Td -(7002 {) 26.2111 Tj -0 -56.9602 Td -(7003 static char buf[100];) 122.3184 Tj -0 -66.4535 Td -(7004 int fd;) 61.1592 Tj -0 -75.9469 Td -(7005 ) 21.8426 Tj -0 -85.4403 Td -(7006 // Assumes three file descriptors open.) 200.9517 Tj -0 -94.9336 Td -(7007 while\(\(fd = open\("console", O_RDWR\)\) >= 0\){) 218.4257 Tj -0 -104.427 Td -(7008 if\(fd >= 3\){) 91.7388 Tj -0 -113.9203 Td -(7009 close\(fd\);) 91.7388 Tj -0 -123.4137 Td -(7010 break;) 74.2647 Tj -0 -132.9071 Td -(7011 }) 43.6851 Tj -0 -142.4004 Td -(7012 }) 34.9481 Tj -0 -151.8938 Td -(7013 ) 21.8426 Tj -0 -161.3871 Td -(7014 // Read and run input commands.) 166.0035 Tj -0 -170.8805 Td -(7015 while\(getcmd\(buf, sizeof\(buf\)\) >= 0\){) 192.2146 Tj -0 -180.3739 Td -(7016 if\(buf[0] == 'c' && buf[1] == 'd' && buf[2] == ' '\){) 266.4794 Tj -0 -189.8672 Td -(7017 // Clumsy but will have to do for now.) 214.0572 Tj -0 -199.3606 Td -(7018 // Chdir has no effect on the parent if run in the c\ -hild.) 297.059 Tj -0 -208.8539 Td -(7019 buf[strlen\(buf\)-1] = 0; // chop \\n) 200.9517 Tj -0 -218.3473 Td -(7020 if\(chdir\(buf+3\) < 0\)) 135.4239 Tj -0 -227.8407 Td -(7021 printf\(2, "cannot cd %s\\n", buf+3\);) 209.6887 Tj -0 -237.334 Td -(7022 continue;) 87.3703 Tj -0 -246.8274 Td -(7023 }) 43.6851 Tj -0 -256.3207 Td -(7024 if\(fork1\(\) == 0\)) 109.2129 Tj -0 -265.8141 Td -(7025 runcmd\(parsecmd\(buf\)\);) 144.161 Tj -0 -275.3075 Td -(7026 wait\(\);) 69.8962 Tj -0 -284.8008 Td -(7027 }) 34.9481 Tj -0 -294.2942 Td -(7028 exit\(\);) 61.1592 Tj -0 -303.7875 Td -(7029 }) 26.2111 Tj -0 -313.2809 Td -(7030 ) 21.8426 Tj -0 -322.7743 Td -(7031 void) 39.3166 Tj -0 -332.2676 Td -(7032 panic\(char *s\)) 83.0018 Tj -0 -341.761 Td -(7033 {) 26.2111 Tj -0 -351.2543 Td -(7034 printf\(2, "%s\\n", s\);) 122.3184 Tj -0 -360.7477 Td -(7035 exit\(\);) 61.1592 Tj -0 -370.2411 Td -(7036 }) 26.2111 Tj -0 -379.7344 Td -(7037 ) 21.8426 Tj -0 -389.2278 Td -(7038 int) 34.9481 Tj -0 -398.7211 Td -(7039 fork1\(void\)) 69.8962 Tj -0 -408.2145 Td -(7040 {) 26.2111 Tj -0 -417.7079 Td -(7041 int pid;) 65.5277 Tj -0 -427.2012 Td -(7042 ) 21.8426 Tj -0 -436.6946 Td -(7043 pid = fork\(\);) 87.3703 Tj -0 -446.1879 Td -(7044 if\(pid == -1\)) 87.3703 Tj -0 -455.6813 Td -(7045 panic\("fork"\);) 100.4758 Tj -0 -465.1747 Td -(7046 return pid;) 78.6333 Tj -0 -474.668 Td -(7047 }) 26.2111 Tj -0 -484.1614 Td -(7048 ) 21.8426 Tj -0 -493.6547 Td -(7049 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 70) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sh.c Page 5) 152.898 Tj -0 -28.4801 Td -(7050 // Constructors) 87.3703 Tj -0 -37.9735 Td -(7051 ) 21.8426 Tj -0 -47.4668 Td -(7052 struct cmd*) 69.8962 Tj -0 -56.9602 Td -(7053 execcmd\(void\)) 78.6333 Tj -0 -66.4535 Td -(7054 {) 26.2111 Tj -0 -75.9469 Td -(7055 struct execcmd *cmd;) 117.9499 Tj -0 -85.4403 Td -(7056 ) 21.8426 Tj -0 -94.9336 Td -(7057 cmd = malloc\(sizeof\(*cmd\)\);) 148.5295 Tj -0 -104.427 Td -(7058 memset\(cmd, 0, sizeof\(*cmd\)\);) 157.2665 Tj -0 -113.9203 Td -(7059 cmd->type = EXEC;) 104.8443 Tj -0 -123.4137 Td -(7060 return \(struct cmd*\)cmd;) 135.4239 Tj -0 -132.9071 Td -(7061 }) 26.2111 Tj -0 -142.4004 Td -(7062 ) 21.8426 Tj -0 -151.8938 Td -(7063 struct cmd*) 69.8962 Tj -0 -161.3871 Td -(7064 redircmd\(struct cmd *subcmd, char *file, char *efile, int\ - mode, int fd\)) 332.0071 Tj -0 -170.8805 Td -(7065 {) 26.2111 Tj -0 -180.3739 Td -(7066 struct redircmd *cmd;) 122.3184 Tj -0 -189.8672 Td -(7067 ) 21.8426 Tj -0 -199.3606 Td -(7068 cmd = malloc\(sizeof\(*cmd\)\);) 148.5295 Tj -0 -208.8539 Td -(7069 memset\(cmd, 0, sizeof\(*cmd\)\);) 157.2665 Tj -0 -218.3473 Td -(7070 cmd->type = REDIR;) 109.2129 Tj -0 -227.8407 Td -(7071 cmd->cmd = subcmd;) 109.2129 Tj -0 -237.334 Td -(7072 cmd->file = file;) 104.8443 Tj -0 -246.8274 Td -(7073 cmd->efile = efile;) 113.5814 Tj -0 -256.3207 Td -(7074 cmd->mode = mode;) 104.8443 Tj -0 -265.8141 Td -(7075 cmd->fd = fd;) 87.3703 Tj -0 -275.3075 Td -(7076 return \(struct cmd*\)cmd;) 135.4239 Tj -0 -284.8008 Td -(7077 }) 26.2111 Tj -0 -294.2942 Td -(7078 ) 21.8426 Tj -0 -303.7875 Td -(7079 struct cmd*) 69.8962 Tj -0 -313.2809 Td -(7080 pipecmd\(struct cmd *left, struct cmd *right\)) 214.0572 Tj -0 -322.7743 Td -(7081 {) 26.2111 Tj -0 -332.2676 Td -(7082 struct pipecmd *cmd;) 117.9499 Tj -0 -341.761 Td -(7083 ) 21.8426 Tj -0 -351.2543 Td -(7084 cmd = malloc\(sizeof\(*cmd\)\);) 148.5295 Tj -0 -360.7477 Td -(7085 memset\(cmd, 0, sizeof\(*cmd\)\);) 157.2665 Tj -0 -370.2411 Td -(7086 cmd->type = PIPE;) 104.8443 Tj -0 -379.7344 Td -(7087 cmd->left = left;) 104.8443 Tj -0 -389.2278 Td -(7088 cmd->right = right;) 113.5814 Tj -0 -398.7211 Td -(7089 return \(struct cmd*\)cmd;) 135.4239 Tj -0 -408.2145 Td -(7090 }) 26.2111 Tj -0 -417.7079 Td -(7091 ) 21.8426 Tj -0 -427.2012 Td -(7092 ) 21.8426 Tj -0 -436.6946 Td -(7093 ) 21.8426 Tj -0 -446.1879 Td -(7094 ) 21.8426 Tj -0 -455.6813 Td -(7095 ) 21.8426 Tj -0 -465.1747 Td -(7096 ) 21.8426 Tj -0 -474.668 Td -(7097 ) 21.8426 Tj -0 -484.1614 Td -(7098 ) 21.8426 Tj -0 -493.6547 Td -(7099 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 70) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 78 78 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sh.c Page 6) 152.898 Tj -0 -28.4801 Td -(7100 struct cmd*) 69.8962 Tj -0 -37.9735 Td -(7101 listcmd\(struct cmd *left, struct cmd *right\)) 214.0572 Tj -0 -47.4668 Td -(7102 {) 26.2111 Tj -0 -56.9602 Td -(7103 struct listcmd *cmd;) 117.9499 Tj -0 -66.4535 Td -(7104 ) 21.8426 Tj -0 -75.9469 Td -(7105 cmd = malloc\(sizeof\(*cmd\)\);) 148.5295 Tj -0 -85.4403 Td -(7106 memset\(cmd, 0, sizeof\(*cmd\)\);) 157.2665 Tj -0 -94.9336 Td -(7107 cmd->type = LIST;) 104.8443 Tj -0 -104.427 Td -(7108 cmd->left = left;) 104.8443 Tj -0 -113.9203 Td -(7109 cmd->right = right;) 113.5814 Tj -0 -123.4137 Td -(7110 return \(struct cmd*\)cmd;) 135.4239 Tj -0 -132.9071 Td -(7111 }) 26.2111 Tj -0 -142.4004 Td -(7112 ) 21.8426 Tj -0 -151.8938 Td -(7113 struct cmd*) 69.8962 Tj -0 -161.3871 Td -(7114 backcmd\(struct cmd *subcmd\)) 139.7925 Tj -0 -170.8805 Td -(7115 {) 26.2111 Tj -0 -180.3739 Td -(7116 struct backcmd *cmd;) 117.9499 Tj -0 -189.8672 Td -(7117 ) 21.8426 Tj -0 -199.3606 Td -(7118 cmd = malloc\(sizeof\(*cmd\)\);) 148.5295 Tj -0 -208.8539 Td -(7119 memset\(cmd, 0, sizeof\(*cmd\)\);) 157.2665 Tj -0 -218.3473 Td -(7120 cmd->type = BACK;) 104.8443 Tj -0 -227.8407 Td -(7121 cmd->cmd = subcmd;) 109.2129 Tj -0 -237.334 Td -(7122 return \(struct cmd*\)cmd;) 135.4239 Tj -0 -246.8274 Td -(7123 }) 26.2111 Tj -0 -256.3207 Td -(7124 ) 21.8426 Tj -0 -265.8141 Td -(7125 ) 21.8426 Tj -0 -275.3075 Td -(7126 ) 21.8426 Tj -0 -284.8008 Td -(7127 ) 21.8426 Tj -0 -294.2942 Td -(7128 ) 21.8426 Tj -0 -303.7875 Td -(7129 ) 21.8426 Tj -0 -313.2809 Td -(7130 ) 21.8426 Tj -0 -322.7743 Td -(7131 ) 21.8426 Tj -0 -332.2676 Td -(7132 ) 21.8426 Tj -0 -341.761 Td -(7133 ) 21.8426 Tj -0 -351.2543 Td -(7134 ) 21.8426 Tj -0 -360.7477 Td -(7135 ) 21.8426 Tj -0 -370.2411 Td -(7136 ) 21.8426 Tj -0 -379.7344 Td -(7137 ) 21.8426 Tj -0 -389.2278 Td -(7138 ) 21.8426 Tj -0 -398.7211 Td -(7139 ) 21.8426 Tj -0 -408.2145 Td -(7140 ) 21.8426 Tj -0 -417.7079 Td -(7141 ) 21.8426 Tj -0 -427.2012 Td -(7142 ) 21.8426 Tj -0 -436.6946 Td -(7143 ) 21.8426 Tj -0 -446.1879 Td -(7144 ) 21.8426 Tj -0 -455.6813 Td -(7145 ) 21.8426 Tj -0 -465.1747 Td -(7146 ) 21.8426 Tj -0 -474.668 Td -(7147 ) 21.8426 Tj -0 -484.1614 Td -(7148 ) 21.8426 Tj -0 -493.6547 Td -(7149 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 71) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sh.c Page 7) 152.898 Tj -0 -28.4801 Td -(7150 // Parsing) 65.5277 Tj -0 -37.9735 Td -(7151 ) 21.8426 Tj -0 -47.4668 Td -(7152 char whitespace[] = " \\t\\r\\n\\v";) 161.635 Tj -0 -56.9602 Td -(7153 char symbols[] = "<|>&;\(\)";) 139.7925 Tj -0 -66.4535 Td -(7154 ) 21.8426 Tj -0 -75.9469 Td -(7155 int) 34.9481 Tj -0 -85.4403 Td -(7156 gettoken\(char **ps, char *es, char **q, char **eq\)) 240.2683 Tj -0 -94.9336 Td -(7157 {) 26.2111 Tj -0 -104.427 Td -(7158 char *s;) 65.5277 Tj -0 -113.9203 Td -(7159 int ret;) 65.5277 Tj -0 -123.4137 Td -(7160 ) 21.8426 Tj -0 -132.9071 Td -(7161 s = *ps;) 65.5277 Tj -0 -142.4004 Td -(7162 while\(s < es && strchr\(whitespace, *s\)\)) 200.9517 Tj -0 -151.8938 Td -(7163 s++;) 56.7907 Tj -0 -161.3871 Td -(7164 if\(q\)) 52.4222 Tj -0 -170.8805 Td -(7165 *q = s;) 69.8962 Tj -0 -180.3739 Td -(7166 ret = *s;) 69.8962 Tj -0 -189.8672 Td -(7167 switch\(*s\){) 78.6333 Tj -0 -199.3606 Td -(7168 case 0:) 61.1592 Tj -0 -208.8539 Td -(7169 break;) 65.5277 Tj -0 -218.3473 Td -(7170 case '|':) 69.8962 Tj -0 -227.8407 Td -(7171 case '\(':) 69.8962 Tj -0 -237.334 Td -(7172 case '\)':) 69.8962 Tj -0 -246.8274 Td -(7173 case ';':) 69.8962 Tj -0 -256.3207 Td -(7174 case '&':) 69.8962 Tj -0 -265.8141 Td -(7175 case '<':) 69.8962 Tj -0 -275.3075 Td -(7176 s++;) 56.7907 Tj -0 -284.8008 Td -(7177 break;) 65.5277 Tj -0 -294.2942 Td -(7178 case '>':) 69.8962 Tj -0 -303.7875 Td -(7179 s++;) 56.7907 Tj -0 -313.2809 Td -(7180 if\(*s == '>'\){) 100.4758 Tj -0 -322.7743 Td -(7181 ret = '+';) 91.7388 Tj -0 -332.2676 Td -(7182 s++;) 65.5277 Tj -0 -341.761 Td -(7183 }) 43.6851 Tj -0 -351.2543 Td -(7184 break;) 65.5277 Tj -0 -360.7477 Td -(7185 default:) 65.5277 Tj -0 -370.2411 Td -(7186 ret = 'a';) 83.0018 Tj -0 -379.7344 Td -(7187 while\(s < es && !strchr\(whitespace, *s\) && !strchr\(\ -symbols, *s\)\)) 318.9016 Tj -0 -389.2278 Td -(7188 s++;) 65.5277 Tj -0 -398.7211 Td -(7189 break;) 65.5277 Tj -0 -408.2145 Td -(7190 }) 34.9481 Tj -0 -417.7079 Td -(7191 if\(eq\)) 56.7907 Tj -0 -427.2012 Td -(7192 *eq = s;) 74.2647 Tj -0 -436.6946 Td -(7193 ) 21.8426 Tj -0 -446.1879 Td -(7194 while\(s < es && strchr\(whitespace, *s\)\)) 200.9517 Tj -0 -455.6813 Td -(7195 s++;) 56.7907 Tj -0 -465.1747 Td -(7196 *ps = s;) 65.5277 Tj -0 -474.668 Td -(7197 return ret;) 78.6333 Tj -0 -484.1614 Td -(7198 }) 26.2111 Tj -0 -493.6547 Td -(7199 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 71) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 79 79 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sh.c Page 8) 152.898 Tj -0 -28.4801 Td -(7200 int) 34.9481 Tj -0 -37.9735 Td -(7201 peek\(char **ps, char *es, char *toks\)) 183.4776 Tj -0 -47.4668 Td -(7202 {) 26.2111 Tj -0 -56.9602 Td -(7203 char *s;) 65.5277 Tj -0 -66.4535 Td -(7204 ) 21.8426 Tj -0 -75.9469 Td -(7205 s = *ps;) 65.5277 Tj -0 -85.4403 Td -(7206 while\(s < es && strchr\(whitespace, *s\)\)) 200.9517 Tj -0 -94.9336 Td -(7207 s++;) 56.7907 Tj -0 -104.427 Td -(7208 *ps = s;) 65.5277 Tj -0 -113.9203 Td -(7209 return *s && strchr\(toks, *s\);) 161.635 Tj -0 -123.4137 Td -(7210 }) 26.2111 Tj -0 -132.9071 Td -(7211 ) 21.8426 Tj -0 -142.4004 Td -(7212 struct cmd *parseline\(char**, char*\);) 183.4776 Tj -0 -151.8938 Td -(7213 struct cmd *parsepipe\(char**, char*\);) 183.4776 Tj -0 -161.3871 Td -(7214 struct cmd *parseexec\(char**, char*\);) 183.4776 Tj -0 -170.8805 Td -(7215 struct cmd *nulterminate\(struct cmd*\);) 187.8461 Tj -0 -180.3739 Td -(7216 ) 21.8426 Tj -0 -189.8672 Td -(7217 struct cmd*) 69.8962 Tj -0 -199.3606 Td -(7218 parsecmd\(char *s\)) 96.1073 Tj -0 -208.8539 Td -(7219 {) 26.2111 Tj -0 -218.3473 Td -(7220 char *es;) 69.8962 Tj -0 -227.8407 Td -(7221 struct cmd *cmd;) 100.4758 Tj -0 -237.334 Td -(7222 ) 21.8426 Tj -0 -246.8274 Td -(7223 es = s + strlen\(s\);) 113.5814 Tj -0 -256.3207 Td -(7224 cmd = parseline\(&s, es\);) 135.4239 Tj -0 -265.8141 Td -(7225 peek\(&s, es, ""\);) 104.8443 Tj -0 -275.3075 Td -(7226 if\(s != es\){) 83.0018 Tj -0 -284.8008 Td -(7227 printf\(2, "leftovers: %s\\n", s\);) 179.1091 Tj -0 -294.2942 Td -(7228 panic\("syntax"\);) 109.2129 Tj -0 -303.7875 Td -(7229 }) 34.9481 Tj -0 -313.2809 Td -(7230 nulterminate\(cmd\);) 109.2129 Tj -0 -322.7743 Td -(7231 return cmd;) 78.6333 Tj -0 -332.2676 Td -(7232 }) 26.2111 Tj -0 -341.761 Td -(7233 ) 21.8426 Tj -0 -351.2543 Td -(7234 struct cmd*) 69.8962 Tj -0 -360.7477 Td -(7235 parseline\(char **ps, char *es\)) 152.898 Tj -0 -370.2411 Td -(7236 {) 26.2111 Tj -0 -379.7344 Td -(7237 struct cmd *cmd;) 100.4758 Tj -0 -389.2278 Td -(7238 ) 21.8426 Tj -0 -398.7211 Td -(7239 cmd = parsepipe\(ps, es\);) 135.4239 Tj -0 -408.2145 Td -(7240 while\(peek\(ps, es, "&"\)\){) 139.7925 Tj -0 -417.7079 Td -(7241 gettoken\(ps, es, 0, 0\);) 139.7925 Tj -0 -427.2012 Td -(7242 cmd = backcmd\(cmd\);) 122.3184 Tj -0 -436.6946 Td -(7243 }) 34.9481 Tj -0 -446.1879 Td -(7244 if\(peek\(ps, es, ";"\)\){) 126.6869 Tj -0 -455.6813 Td -(7245 gettoken\(ps, es, 0, 0\);) 139.7925 Tj -0 -465.1747 Td -(7246 cmd = listcmd\(cmd, parseline\(ps, es\)\);) 205.3202 Tj -0 -474.668 Td -(7247 }) 34.9481 Tj -0 -484.1614 Td -(7248 return cmd;) 78.6333 Tj -0 -493.6547 Td -(7249 }) 26.2111 Tj -0 -522.1348 Td -(Sheet 72) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sh.c Page 9) 152.898 Tj -0 -28.4801 Td -(7250 struct cmd*) 69.8962 Tj -0 -37.9735 Td -(7251 parsepipe\(char **ps, char *es\)) 152.898 Tj -0 -47.4668 Td -(7252 {) 26.2111 Tj -0 -56.9602 Td -(7253 struct cmd *cmd;) 100.4758 Tj -0 -66.4535 Td -(7254 ) 21.8426 Tj -0 -75.9469 Td -(7255 cmd = parseexec\(ps, es\);) 135.4239 Tj -0 -85.4403 Td -(7256 if\(peek\(ps, es, "|"\)\){) 126.6869 Tj -0 -94.9336 Td -(7257 gettoken\(ps, es, 0, 0\);) 139.7925 Tj -0 -104.427 Td -(7258 cmd = pipecmd\(cmd, parsepipe\(ps, es\)\);) 205.3202 Tj -0 -113.9203 Td -(7259 }) 34.9481 Tj -0 -123.4137 Td -(7260 return cmd;) 78.6333 Tj -0 -132.9071 Td -(7261 }) 26.2111 Tj -0 -142.4004 Td -(7262 ) 21.8426 Tj -0 -151.8938 Td -(7263 struct cmd*) 69.8962 Tj -0 -161.3871 Td -(7264 parseredirs\(struct cmd *cmd, char **ps, char *es\)) 235.8998 Tj -0 -170.8805 Td -(7265 {) 26.2111 Tj -0 -180.3739 Td -(7266 int tok;) 65.5277 Tj -0 -189.8672 Td -(7267 char *q, *eq;) 87.3703 Tj -0 -199.3606 Td -(7268 ) 21.8426 Tj -0 -208.8539 Td -(7269 while\(peek\(ps, es, "<>"\)\){) 144.161 Tj -0 -218.3473 Td -(7270 tok = gettoken\(ps, es, 0, 0\);) 166.0035 Tj -0 -227.8407 Td -(7271 if\(gettoken\(ps, es, &q, &eq\) != 'a'\)) 196.5831 Tj -0 -237.334 Td -(7272 panic\("missing file for redirection"\);) 214.0572 Tj -0 -246.8274 Td -(7273 switch\(tok\){) 91.7388 Tj -0 -256.3207 Td -(7274 case '<':) 78.6333 Tj -0 -265.8141 Td -(7275 cmd = redircmd\(cmd, q, eq, O_RDONLY, 0\);) 222.7942 Tj -0 -275.3075 Td -(7276 break;) 74.2647 Tj -0 -284.8008 Td -(7277 case '>':) 78.6333 Tj -0 -294.2942 Td -(7278 cmd = redircmd\(cmd, q, eq, O_WRONLY|O_CREATE, 1\);) 262.1109 Tj -0 -303.7875 Td -(7279 break;) 74.2647 Tj -0 -313.2809 Td -(7280 case '+': // >>) 109.2129 Tj -0 -322.7743 Td -(7281 cmd = redircmd\(cmd, q, eq, O_WRONLY|O_CREATE, 1\);) 262.1109 Tj -0 -332.2676 Td -(7282 break;) 74.2647 Tj -0 -341.761 Td -(7283 }) 43.6851 Tj -0 -351.2543 Td -(7284 }) 34.9481 Tj -0 -360.7477 Td -(7285 return cmd;) 78.6333 Tj -0 -370.2411 Td -(7286 }) 26.2111 Tj -0 -379.7344 Td -(7287 ) 21.8426 Tj -0 -389.2278 Td -(7288 ) 21.8426 Tj -0 -398.7211 Td -(7289 ) 21.8426 Tj -0 -408.2145 Td -(7290 ) 21.8426 Tj -0 -417.7079 Td -(7291 ) 21.8426 Tj -0 -427.2012 Td -(7292 ) 21.8426 Tj -0 -436.6946 Td -(7293 ) 21.8426 Tj -0 -446.1879 Td -(7294 ) 21.8426 Tj -0 -455.6813 Td -(7295 ) 21.8426 Tj -0 -465.1747 Td -(7296 ) 21.8426 Tj -0 -474.668 Td -(7297 ) 21.8426 Tj -0 -484.1614 Td -(7298 ) 21.8426 Tj -0 -493.6547 Td -(7299 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 72) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Page: 80 80 -%%BeginPageSetup -%%PageOrientation: Landscape -pdfStartPage -180 rotate --612 -792 translate -0 0 612 792 re W -%%EndPageSetup -[] 0 d -1 i -0 j -0 J -10 M -1 w -/DeviceGray {} cs -[0] sc -/DeviceGray {} CS -[0] SC -false op -false OP -{} settransfer -0 0 612 792 re -W -q -q -[0.1 0 0 0.1 0 0] cm -q -180 3960 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 738.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sh.c Page 10) 157.2665 Tj -0 -28.4801 Td -(7300 struct cmd*) 69.8962 Tj -0 -37.9735 Td -(7301 parseblock\(char **ps, char *es\)) 157.2665 Tj -0 -47.4668 Td -(7302 {) 26.2111 Tj -0 -56.9602 Td -(7303 struct cmd *cmd;) 100.4758 Tj -0 -66.4535 Td -(7304 ) 21.8426 Tj -0 -75.9469 Td -(7305 if\(!peek\(ps, es, "\("\)\)) 126.6869 Tj -0 -85.4403 Td -(7306 panic\("parseblock"\);) 126.6869 Tj -0 -94.9336 Td -(7307 gettoken\(ps, es, 0, 0\);) 131.0554 Tj -0 -104.427 Td -(7308 cmd = parseline\(ps, es\);) 135.4239 Tj -0 -113.9203 Td -(7309 if\(!peek\(ps, es, "\)"\)\)) 126.6869 Tj -0 -123.4137 Td -(7310 panic\("syntax - missing \)"\);) 161.635 Tj -0 -132.9071 Td -(7311 gettoken\(ps, es, 0, 0\);) 131.0554 Tj -0 -142.4004 Td -(7312 cmd = parseredirs\(cmd, ps, es\);) 166.0035 Tj -0 -151.8938 Td -(7313 return cmd;) 78.6333 Tj -0 -161.3871 Td -(7314 }) 26.2111 Tj -0 -170.8805 Td -(7315 ) 21.8426 Tj -0 -180.3739 Td -(7316 struct cmd*) 69.8962 Tj -0 -189.8672 Td -(7317 parseexec\(char **ps, char *es\)) 152.898 Tj -0 -199.3606 Td -(7318 {) 26.2111 Tj -0 -208.8539 Td -(7319 char *q, *eq;) 87.3703 Tj -0 -218.3473 Td -(7320 int tok, argc;) 91.7388 Tj -0 -227.8407 Td -(7321 struct execcmd *cmd;) 117.9499 Tj -0 -237.334 Td -(7322 struct cmd *ret;) 100.4758 Tj -0 -246.8274 Td -(7323 ) 21.8426 Tj -0 -256.3207 Td -(7324 if\(peek\(ps, es, "\("\)\)) 122.3184 Tj -0 -265.8141 Td -(7325 return parseblock\(ps, es\);) 152.898 Tj -0 -275.3075 Td -(7326 ) 21.8426 Tj -0 -284.8008 Td -(7327 ret = execcmd\(\);) 100.4758 Tj -0 -294.2942 Td -(7328 cmd = \(struct execcmd*\)ret;) 148.5295 Tj -0 -303.7875 Td -(7329 ) 21.8426 Tj -0 -313.2809 Td -(7330 argc = 0;) 69.8962 Tj -0 -322.7743 Td -(7331 ret = parseredirs\(ret, ps, es\);) 166.0035 Tj -0 -332.2676 Td -(7332 while\(!peek\(ps, es, "|\)&;"\)\){) 157.2665 Tj -0 -341.761 Td -(7333 if\(\(tok=gettoken\(ps, es, &q, &eq\)\) == 0\)) 214.0572 Tj -0 -351.2543 Td -(7334 break;) 74.2647 Tj -0 -360.7477 Td -(7335 if\(tok != 'a'\)) 100.4758 Tj -0 -370.2411 Td -(7336 panic\("syntax"\);) 117.9499 Tj -0 -379.7344 Td -(7337 cmd->argv[argc] = q;) 126.6869 Tj -0 -389.2278 Td -(7338 cmd->eargv[argc] = eq;) 135.4239 Tj -0 -398.7211 Td -(7339 argc++;) 69.8962 Tj -0 -408.2145 Td -(7340 if\(argc >= MAXARGS\)) 122.3184 Tj -0 -417.7079 Td -(7341 panic\("too many args"\);) 148.5295 Tj -0 -427.2012 Td -(7342 ret = parseredirs\(ret, ps, es\);) 174.7406 Tj -0 -436.6946 Td -(7343 }) 34.9481 Tj -0 -446.1879 Td -(7344 cmd->argv[argc] = 0;) 117.9499 Tj -0 -455.6813 Td -(7345 cmd->eargv[argc] = 0;) 122.3184 Tj -0 -465.1747 Td -(7346 return ret;) 78.6333 Tj -0 -474.668 Td -(7347 }) 26.2111 Tj -0 -484.1614 Td -(7348 ) 21.8426 Tj -0 -493.6547 Td -(7349 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 73) 34.9481 Tj -Q -Q -q -180 500 5760 3460 re -W -/DeviceGray {} CS -[0] SC -/DeviceGray {} cs -[0] sc -q -[10 0 0 10 0 0] cm -[1 0 0 1 0 0] Tm -0 0 Td -[0 -0.9679 1 0 564.72 392.865] Tm -0 0 Td -/F8_0 8.7022 Tf -(Sep 3 00:44 2009 xv6/sh.c Page 11) 157.2665 Tj -0 -28.4801 Td -(7350 // NUL-terminate all the counted strings.) 200.9517 Tj -0 -37.9735 Td -(7351 struct cmd*) 69.8962 Tj -0 -47.4668 Td -(7352 nulterminate\(struct cmd *cmd\)) 148.5295 Tj -0 -56.9602 Td -(7353 {) 26.2111 Tj -0 -66.4535 Td -(7354 int i;) 56.7907 Tj -0 -75.9469 Td -(7355 struct backcmd *bcmd;) 122.3184 Tj -0 -85.4403 Td -(7356 struct execcmd *ecmd;) 122.3184 Tj -0 -94.9336 Td -(7357 struct listcmd *lcmd;) 122.3184 Tj -0 -104.427 Td -(7358 struct pipecmd *pcmd;) 122.3184 Tj -0 -113.9203 Td -(7359 struct redircmd *rcmd;) 126.6869 Tj -0 -123.4137 Td -(7360 ) 21.8426 Tj -0 -132.9071 Td -(7361 if\(cmd == 0\)) 83.0018 Tj -0 -142.4004 Td -(7362 return 0;) 78.6333 Tj -0 -151.8938 Td -(7363 ) 21.8426 Tj -0 -161.3871 Td -(7364 switch\(cmd->type\){) 109.2129 Tj -0 -170.8805 Td -(7365 case EXEC:) 74.2647 Tj -0 -180.3739 Td -(7366 ecmd = \(struct execcmd*\)cmd;) 161.635 Tj -0 -189.8672 Td -(7367 for\(i=0; ecmd->argv[i]; i++\)) 161.635 Tj -0 -199.3606 Td -(7368 *ecmd->eargv[i] = 0;) 135.4239 Tj -0 -208.8539 Td -(7369 break;) 65.5277 Tj -0 -218.3473 Td -(7370 ) 21.8426 Tj -0 -227.8407 Td -(7371 case REDIR:) 78.6333 Tj -0 -237.334 Td -(7372 rcmd = \(struct redircmd*\)cmd;) 166.0035 Tj -0 -246.8274 Td -(7373 nulterminate\(rcmd->cmd\);) 144.161 Tj -0 -256.3207 Td -(7374 *rcmd->efile = 0;) 113.5814 Tj -0 -265.8141 Td -(7375 break;) 65.5277 Tj -0 -275.3075 Td -(7376 ) 21.8426 Tj -0 -284.8008 Td -(7377 case PIPE:) 74.2647 Tj -0 -294.2942 Td -(7378 pcmd = \(struct pipecmd*\)cmd;) 161.635 Tj -0 -303.7875 Td -(7379 nulterminate\(pcmd->left\);) 148.5295 Tj -0 -313.2809 Td -(7380 nulterminate\(pcmd->right\);) 152.898 Tj -0 -322.7743 Td -(7381 break;) 65.5277 Tj -0 -332.2676 Td -(7382 ) 21.8426 Tj -0 -341.761 Td -(7383 case LIST:) 74.2647 Tj -0 -351.2543 Td -(7384 lcmd = \(struct listcmd*\)cmd;) 161.635 Tj -0 -360.7477 Td -(7385 nulterminate\(lcmd->left\);) 148.5295 Tj -0 -370.2411 Td -(7386 nulterminate\(lcmd->right\);) 152.898 Tj -0 -379.7344 Td -(7387 break;) 65.5277 Tj -0 -389.2278 Td -(7388 ) 21.8426 Tj -0 -398.7211 Td -(7389 case BACK:) 74.2647 Tj -0 -408.2145 Td -(7390 bcmd = \(struct backcmd*\)cmd;) 161.635 Tj -0 -417.7079 Td -(7391 nulterminate\(bcmd->cmd\);) 144.161 Tj -0 -427.2012 Td -(7392 break;) 65.5277 Tj -0 -436.6946 Td -(7393 }) 34.9481 Tj -0 -446.1879 Td -(7394 return cmd;) 78.6333 Tj -0 -455.6813 Td -(7395 }) 26.2111 Tj -0 -465.1747 Td -(7396 ) 21.8426 Tj -0 -474.668 Td -(7397 ) 21.8426 Tj -0 -484.1614 Td -(7398 ) 21.8426 Tj -0 -493.6547 Td -(7399 ) 21.8426 Tj -0 -522.1348 Td -(Sheet 73) 34.9481 Tj -Q -Q -Q -Q -showpage -%%PageTrailer -pdfEndPage -%%Trailer -end -%%DocumentSuppliedResources: -%%+ font APYGPQ+LucidaSans-Typewriter83 -%%EOF From ac090078c63c9b467fd723f6bb7f949c05e9b04b Mon Sep 17 00:00:00 2001 From: Robert Morris Date: Mon, 30 Aug 2010 10:13:49 -0400 Subject: [PATCH 4/5] xx --- defs.h | 2 +- main.c | 2 +- vm.c | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/defs.h b/defs.h index 0197e70..02da96f 100644 --- a/defs.h +++ b/defs.h @@ -155,7 +155,7 @@ void uartputc(int); void pminit(void); void ksegment(void); void kvmalloc(void); -void vminit(void); +void vmenable(void); pde_t* setupkvm(void); char* uva2ka(pde_t*, char*); int allocuvm(pde_t*, char*, uint); diff --git a/main.c b/main.c index c8aa53a..1a49bc6 100644 --- a/main.c +++ b/main.c @@ -67,7 +67,7 @@ mpmain(void) ksegment(); lapicinit(cpunum()); } - vminit(); // turn on paging + vmenable(); // turn on paging cprintf("cpu%d: starting\n", cpu->id); idtinit(); // load idt register xchg(&cpu->booted, 1); diff --git a/vm.c b/vm.c index 20afa28..262f079 100644 --- a/vm.c +++ b/vm.c @@ -369,11 +369,11 @@ kvmalloc(void) // Turn on paging. void -vminit(void) +vmenable(void) { uint cr0; - lcr3(PADDR(kpgdir)); + switchkvm(); // load kpgdir into cr3 cr0 = rcr0(); cr0 |= CR0_PG; lcr0(cr0); From 3c9ff073e09abf15f241aa1812e04d8587c9925d Mon Sep 17 00:00:00 2001 From: Robert Morris Date: Mon, 30 Aug 2010 11:17:54 -0400 Subject: [PATCH 5/5] oops ended up with 2x vm.c --- runoff.list | 1 - 1 file changed, 1 deletion(-) diff --git a/runoff.list b/runoff.list index f39ce18..3258398 100644 --- a/runoff.list +++ b/runoff.list @@ -21,7 +21,6 @@ spinlock.c proc.h proc.c swtch.S -vm.c kalloc.c vm.c